Add suggested values for variable dropdown (#9437)
<img width="378" alt="Capture d’écran 2025-01-07 à 15 37 20" src="https://github.com/user-attachments/assets/c15abcac-684a-4c3b-ad12-62cf91afe927" /> Here is a first version: - simple fields have a suggested value - composite do not, but sub values of composite do - json, arrays or complex values do not
This commit is contained in:
@ -47,6 +47,7 @@ type MenuItemSelectProps = {
|
||||
disabled?: boolean;
|
||||
hovered?: boolean;
|
||||
hasSubMenu?: boolean;
|
||||
contextualText?: string;
|
||||
};
|
||||
|
||||
export const MenuItemSelect = ({
|
||||
@ -59,6 +60,7 @@ export const MenuItemSelect = ({
|
||||
disabled,
|
||||
hovered,
|
||||
hasSubMenu = false,
|
||||
contextualText,
|
||||
}: MenuItemSelectProps) => {
|
||||
const theme = useTheme();
|
||||
|
||||
@ -73,8 +75,13 @@ export const MenuItemSelect = ({
|
||||
aria-selected={selected}
|
||||
aria-disabled={disabled}
|
||||
>
|
||||
<MenuItemLeftContent LeftIcon={LeftIcon} text={text} />
|
||||
<MenuItemLeftContent
|
||||
LeftIcon={LeftIcon}
|
||||
text={text}
|
||||
contextualText={contextualText}
|
||||
/>
|
||||
{selected && needIconCheck && <IconCheck size={theme.icon.size.md} />}
|
||||
|
||||
{hasSubMenu && (
|
||||
<IconChevronRight
|
||||
size={theme.icon.size.sm}
|
||||
|
||||
Reference in New Issue
Block a user