From 48a887320179f0c9967765baa1e0662faf333d95 Mon Sep 17 00:00:00 2001 From: illia-prokopchuk <78905712+illia-prokopchuk@users.noreply.github.com> Date: Mon, 14 Oct 2024 14:45:15 +0300 Subject: [PATCH] Fix [UI] UI small fixes `1.7.x` (#2808) --- package.json | 2 +- src/common/Input/Input.js | 2 +- src/components/ActionBar/ActionBar.js | 2 +- src/components/FeatureStore/FeatureVectors/FeatureVectors.js | 4 ++-- src/components/FunctionsPage/Functions.js | 4 ++-- src/components/Project/project.utils.js | 3 +-- src/components/ProjectSettings/projectSettings.scss | 2 +- .../AddToFeatureVectorPopUp/AddToFeatureVectorPopUp.js | 4 ++-- .../CreateFeatureVectorPopUp/CreateFeatureVectorPopUp.js | 4 ++-- src/scss/main.scss | 5 ++++- 10 files changed, 17 insertions(+), 15 deletions(-) diff --git a/package.json b/package.json index c6760c1f6..8d47fc404 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "final-form-arrays": "^3.1.0", "fs-extra": "^10.0.0", "identity-obj-proxy": "^3.0.0", - "iguazio.dashboard-react-controls": "2.2.1", + "iguazio.dashboard-react-controls": "2.2.2-1.7.x", "is-wsl": "^1.1.0", "js-base64": "^2.5.2", "js-yaml": "^4.1.0", diff --git a/src/common/Input/Input.js b/src/common/Input/Input.js index 9d5ec7b3e..ed9837d7a 100644 --- a/src/common/Input/Input.js +++ b/src/common/Input/Input.js @@ -240,7 +240,7 @@ const Input = React.forwardRef( type, value: typedValue }} - style={floatingLabel ? {} : { paddingLeft: `${labelWidth + 16}px` }} + style={floatingLabel ? {} : { paddingLeft: `${labelWidth + 16}px`, paddingRight: tip ? '25px' : '0px' }} /> {label && (
diff --git a/src/components/ActionBar/ActionBar.js b/src/components/ActionBar/ActionBar.js index f70f9baa7..6408559c9 100644 --- a/src/components/ActionBar/ActionBar.js +++ b/src/components/ActionBar/ActionBar.js @@ -340,7 +340,7 @@ const ActionBar = ({ /> )) )} - {autoRefreshIsEnabled && } + {autoRefreshIsEnabled && } {withRefreshButton && ( refresh(formState)} id="refresh"> diff --git a/src/components/FeatureStore/FeatureVectors/FeatureVectors.js b/src/components/FeatureStore/FeatureVectors/FeatureVectors.js index de0b80ade..c5400331a 100644 --- a/src/components/FeatureStore/FeatureVectors/FeatureVectors.js +++ b/src/components/FeatureStore/FeatureVectors/FeatureVectors.js @@ -40,7 +40,7 @@ import { featureVectorsActionCreator, searchFeatureVectorItem } from './featureVectors.util' -import { DANGER_BUTTON, LABEL_BUTTON } from 'igz-controls/constants' +import { DANGER_BUTTON, TERTIARY_BUTTON } from 'igz-controls/constants' import { checkTabIsValid, handleApplyDetailsChanges } from '../featureStore.util' import { createFeatureVectorsRowData } from '../../../utils/createFeatureStoreContent' import { getFeatureVectorIdentifier } from '../../../utils/getUniqueIdentifier' @@ -204,7 +204,7 @@ const FeatureVectors = ({ header: 'Delete feature vector?', message: `Are you sure you want to delete the feature vector "${featureVector.name}"?. You cannot restore a feature vector after deleting it.`, btnCancelLabel: 'Cancel', - btnCancelVariant: LABEL_BUTTON, + btnCancelVariant: TERTIARY_BUTTON, btnConfirmLabel: 'Delete', btnConfirmVariant: DANGER_BUTTON, rejectHandler: () => setConfirmData(null), diff --git a/src/components/FunctionsPage/Functions.js b/src/components/FunctionsPage/Functions.js index 1626acd21..b93060326 100644 --- a/src/components/FunctionsPage/Functions.js +++ b/src/components/FunctionsPage/Functions.js @@ -56,7 +56,7 @@ import { import createFunctionsRowData from '../../utils/createFunctionsRowData' import functionsActions from '../../actions/functions' import jobsActions from '../../actions/jobs' -import { DANGER_BUTTON, LABEL_BUTTON } from 'igz-controls/constants' +import { DANGER_BUTTON, TERTIARY_BUTTON } from 'igz-controls/constants' import { getFunctionIdentifier } from '../../utils/getUniqueIdentifier' import { getFunctionNuclioLogs, getFunctionLogs } from '../../utils/getFunctionLogs' import { isBackgroundTaskRunning } from '../../utils/poll.util' @@ -365,7 +365,7 @@ const Functions = ({ header: 'Delete function?', message: `You try to delete function "${func.name}". Deleted functions cannot be restored.`, btnCancelLabel: 'Cancel', - btnCancelVariant: LABEL_BUTTON, + btnCancelVariant: TERTIARY_BUTTON, btnConfirmLabel: 'Delete', btnConfirmVariant: DANGER_BUTTON, rejectHandler: () => setConfirmData(null), diff --git a/src/components/Project/project.utils.js b/src/components/Project/project.utils.js index 64aedd200..551dccea7 100644 --- a/src/components/Project/project.utils.js +++ b/src/components/Project/project.utils.js @@ -86,8 +86,7 @@ export const generateCreateNewOptions = ( handler: () => { openRegisterModelModal() }, - // TODO: remove hidden in 1.4 - hidden: true + hidden: !isDemoMode }, { label: 'Register Dataset', diff --git a/src/components/ProjectSettings/projectSettings.scss b/src/components/ProjectSettings/projectSettings.scss index ebdd02dc7..6e22fd4c4 100644 --- a/src/components/ProjectSettings/projectSettings.scss +++ b/src/components/ProjectSettings/projectSettings.scss @@ -31,7 +31,7 @@ padding: 0 15px; flex: 0 0 auto; width: 50%; - min-width: 500px; + min-width: 650px; } } diff --git a/src/elements/AddToFeatureVectorPopUp/AddToFeatureVectorPopUp.js b/src/elements/AddToFeatureVectorPopUp/AddToFeatureVectorPopUp.js index e5cf3d2a9..57d1a5d69 100644 --- a/src/elements/AddToFeatureVectorPopUp/AddToFeatureVectorPopUp.js +++ b/src/elements/AddToFeatureVectorPopUp/AddToFeatureVectorPopUp.js @@ -29,7 +29,7 @@ import { Button, PopUpDialog } from 'igz-controls/components' import { parseFeatureTemplate } from '../../utils/parseFeatureTemplate' import { generateProjectsList } from '../../utils/projects' -import { LABEL_BUTTON, PRIMARY_BUTTON } from 'igz-controls/constants' +import { TERTIARY_BUTTON, PRIMARY_BUTTON } from 'igz-controls/constants' import { setFeaturesPanelData, setTablePanelOpen } from '../../reducers/tableReducer' import { ReactComponent as AddCircle } from 'igz-controls/images/add-circle.svg' @@ -244,7 +244,7 @@ const AddToFeatureVectorPopUp = ({