Device manager - current session context menu (#9386)
* add destructive option and close on interaction options * add kebab context menu wrapper * use kebab context menu in current device section * use named export * lint * sessionman tests
This commit is contained in:
parent
8b54be6f48
commit
776ffa4764
14 changed files with 468 additions and 108 deletions
|
@ -39,6 +39,7 @@ interface IOptionListProps {
|
|||
|
||||
interface IOptionProps extends React.ComponentProps<typeof MenuItem> {
|
||||
iconClassName?: string;
|
||||
isDestructive?: boolean;
|
||||
}
|
||||
|
||||
interface ICheckboxProps extends React.ComponentProps<typeof MenuItemCheckbox> {
|
||||
|
@ -112,12 +113,14 @@ export const IconizedContextMenuOption: React.FC<IOptionProps> = ({
|
|||
className,
|
||||
iconClassName,
|
||||
children,
|
||||
isDestructive,
|
||||
...props
|
||||
}) => {
|
||||
return <MenuItem
|
||||
{...props}
|
||||
className={classNames(className, {
|
||||
mx_IconizedContextMenu_item: true,
|
||||
mx_IconizedContextMenu_itemDestructive: isDestructive,
|
||||
})}
|
||||
label={label}
|
||||
>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue