fix: display label identifier field input in Show Page (#3063)
* fix: display label identifier field input in Show Page Fixes #3003 * Cleaned a bit after comments --------- Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
This commit is contained in:
@ -14,7 +14,7 @@ import { MenuItem } from '@/ui/navigation/menu-item/components/MenuItem';
|
||||
|
||||
type SettingsObjectFieldActiveActionDropdownProps = {
|
||||
isCustomField?: boolean;
|
||||
onDisable: () => void;
|
||||
onDisable?: () => void;
|
||||
onEdit: () => void;
|
||||
scopeKey: string;
|
||||
};
|
||||
@ -35,7 +35,7 @@ export const SettingsObjectFieldActiveActionDropdown = ({
|
||||
};
|
||||
|
||||
const handleDisable = () => {
|
||||
onDisable();
|
||||
onDisable?.();
|
||||
closeDropdown();
|
||||
};
|
||||
|
||||
@ -53,11 +53,13 @@ export const SettingsObjectFieldActiveActionDropdown = ({
|
||||
LeftIcon={isCustomField ? IconPencil : IconEye}
|
||||
onClick={handleEdit}
|
||||
/>
|
||||
<MenuItem
|
||||
text="Disable"
|
||||
LeftIcon={IconArchive}
|
||||
onClick={handleDisable}
|
||||
/>
|
||||
{!!onDisable && (
|
||||
<MenuItem
|
||||
text="Disable"
|
||||
LeftIcon={IconArchive}
|
||||
onClick={handleDisable}
|
||||
/>
|
||||
)}
|
||||
</DropdownMenuItemsContainer>
|
||||
</DropdownMenu>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user