From d70120f6dd9c347d08f4fb1786be1272e781fa41 Mon Sep 17 00:00:00 2001 From: Po Chun Chiu <57251712+EiffelFly@users.noreply.github.com> Date: Mon, 5 Feb 2024 14:33:49 +0800 Subject: [PATCH] feat(pipeline-builder): unify the onEdit and onDelete item on both start and end operator (#936) Because - The delete and edit icon on start and end operator is inconsistent - close https://github.com/instill-ai/community/issues/548 This commit - unify the onEdit and onDelete item on both start and end operator --- .../FieldHead.tsx | 156 ++++++++---------- ...formInstillFormatToHumanReadableFormat.tsx | 4 + 2 files changed, 69 insertions(+), 91 deletions(-) diff --git a/packages/toolkit/src/lib/use-instill-form/components/start-operator-free-form-fields/FieldHead.tsx b/packages/toolkit/src/lib/use-instill-form/components/start-operator-free-form-fields/FieldHead.tsx index f0f84e7a91..50e4c1139e 100644 --- a/packages/toolkit/src/lib/use-instill-form/components/start-operator-free-form-fields/FieldHead.tsx +++ b/packages/toolkit/src/lib/use-instill-form/components/start-operator-free-form-fields/FieldHead.tsx @@ -1,4 +1,3 @@ -import * as React from "react"; import { useShallow } from "zustand/react/shallow"; import { FieldMode, @@ -7,13 +6,7 @@ import { Nullable, useInstillStore, } from "../../.."; -import { - Button, - Icons, - Popover, - Tag, - Tooltip, -} from "@instill-ai/design-system"; +import { Icons, Tag, Tooltip } from "@instill-ai/design-system"; import { ReferenceHintDataTypeTag, ReferenceHintTag, @@ -46,7 +39,6 @@ export const FieldHead = ({ disabledReferenceHint?: boolean; }) => { const { isOwner, currentVersion } = useInstillStore(useShallow(selector)); - const [open, setOpen] = React.useState(false); return (
- {title} -
-