Skip to content

Commit 486ee21

Browse files
fix(ui): add missing fontSize to SelectContext in Combobox and Autocomplete
PR #27379 added fontSize as a required property to SelectContext but only updated select.tsx. This adds the missing fontSize property to combobox.tsx and autocomplete.tsx to fix the TypeScript build error (TS2741) that is currently blocking CI on all open PRs.
1 parent 12ce3b6 commit 486ee21

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

openmetadata-ui-core-components/src/main/resources/ui/src/components/base/autocomplete/autocomplete.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,10 @@ export const AutocompleteBase = ({
415415

416416
useResizeObserver({ ref: triggerRef, onResize, box: 'border-box' });
417417

418-
const selectContextValue = useMemo(() => ({ size: 'sm' as const }), []);
418+
const selectContextValue = useMemo(
419+
() => ({ fontSize: 'md' as const, size: 'sm' as const }),
420+
[]
421+
);
419422

420423
const autocompleteContextValue = useMemo(
421424
() => ({

openmetadata-ui-core-components/src/main/resources/ui/src/components/base/select/combobox.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,7 @@ export const ComboBox = ({
139139
placeholder = 'Search',
140140
shortcut = true,
141141
size = 'sm',
142+
fontSize = 'md',
142143
children,
143144
items,
144145
shortcutClassName,
@@ -165,7 +166,7 @@ export const ComboBox = ({
165166
});
166167

167168
return (
168-
<SelectContext.Provider value={{ size }}>
169+
<SelectContext.Provider value={{ fontSize, size }}>
169170
<AriaComboBox menuTrigger="focus" {...otherProps}>
170171
{(state) => (
171172
<div className="tw:flex tw:flex-col tw:gap-1.5">

0 commit comments

Comments
 (0)