Skip to content

Commit 50e1b84

Browse files
fix: align save/cancel buttons with input fields in MUI theme propert… (kubeflow#2447)
* fix: align save/cancel buttons with input fields in MUI theme properties section Signed-off-by: Harshwardhan Patil <harshpat@redhat.com> * remove verticalAlign since precedence is taken by alignContent Signed-off-by: Harshwardhan Patil <harshpat@redhat.com> --------- Signed-off-by: Harshwardhan Patil <harshpat@redhat.com>
1 parent da2dfa9 commit 50e1b84

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

clients/ui/frontend/src/app/pages/modelRegistry/screens/components/ModelPropertiesTableRow.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import {
1111
} from '@patternfly/react-core';
1212
import { CheckIcon, ExternalLinkAltIcon, TimesIcon } from '@patternfly/react-icons';
1313
import { KeyValuePair, EitherNotBoth } from 'mod-arch-core';
14+
import { useThemeContext } from 'mod-arch-kubeflow';
1415
import FormFieldset from '~/app/pages/modelRegistry/screens/components/FormFieldset';
1516
import { isValidHttpUrl } from '~/app/pages/modelRegistry/screens/utils';
1617
import useDeletePropertiesModalAvailability from '~/app/hooks/useDeletePropertiesModalAvailability';
@@ -53,6 +54,7 @@ const ModelPropertiesTableRow: React.FC<ModelPropertiesTableRowProps> = ({
5354
showInlineAlerts = false,
5455
}) => {
5556
const { key, value } = keyValuePair;
57+
const { isMUITheme } = useThemeContext();
5658

5759
const [unsavedKey, setUnsavedKey] = React.useState(key);
5860
const [unsavedValue, setUnsavedValue] = React.useState(value);
@@ -204,7 +206,11 @@ const ModelPropertiesTableRow: React.FC<ModelPropertiesTableRowProps> = ({
204206
)}
205207
</Td>
206208
{!isArchive && (
207-
<Td isActionCell width={10}>
209+
<Td
210+
isActionCell
211+
width={10}
212+
style={isMUITheme && isEditing ? { alignContent: 'start' } : undefined}
213+
>
208214
{isEditing ? (
209215
<ActionList isIconList>
210216
<ActionListItem>

0 commit comments

Comments
 (0)