Skip to content

LLM-Driven Extraction of Unstructured Data — Built for API Deployments & ETL Pipeline Workflows

[FIX] Fix tiny action buttons in Prompt Studio modals (#1879)

Chandrasekharan M92374febbd7f
diff --git a/frontend/src/components/agency/prompt/Prompt.jsx b/frontend/src/components/agency/prompt/Prompt.jsx
index f24001d55..83940b5a8 100644
--- a/frontend/src/components/agency/prompt/Prompt.jsx
+++ b/frontend/src/components/agency/prompt/Prompt.jsx
@@ -88,10 +88,9 @@ function Prompt() {
<Button
size="small"
type="text"
+ icon={<MinusOutlined />}
onClick={() => setIsPromptOpen(false)}
- >
- <MinusOutlined />
- </Button>
+ />
</div>
</div>
<div className="wf-prompt-textarea">
@@ -122,10 +121,9 @@ function Prompt() {
<Button
size="small"
type="text"
+ icon={<EditOutlined />}
onClick={() => setIsPromptOpen(true)}
- >
- <EditOutlined />
- </Button>
+ />
</div>
</div>
)}
diff --git a/frontend/src/components/custom-tools/header-title/HeaderTitle.jsx b/frontend/src/components/custom-tools/header-title/HeaderTitle.jsx
index cdee23ef8..03b84b4a7 100644
--- a/frontend/src/components/custom-tools/header-title/HeaderTitle.jsx
+++ b/frontend/src/components/custom-tools/header-title/HeaderTitle.jsx
@@ -26,9 +26,7 @@ function HeaderTitle() {
<Typography.Text className="custom-tools-name" strong>
{details?.tool_name}
</Typography.Text>
- <Button size="small" type="text" disabled>
- <EditOutlined />
- </Button>
+ <Button size="small" type="text" icon={<EditOutlined />} disabled />
</div>
</div>
);
diff --git a/frontend/src/components/custom-tools/manage-docs-modal/ManageDocsModal.jsx b/frontend/src/components/custom-tools/manage-docs-modal/ManageDocsModal.jsx
index 29d7d533e..efd528510 100644
--- a/frontend/src/components/custom-tools/manage-docs-modal/ManageDocsModal.jsx
+++ b/frontend/src/components/custom-tools/manage-docs-modal/ManageDocsModal.jsx
@@ -382,19 +382,14 @@ function ManageDocsModal({
title: "Actions",
dataIndex: "reindex",
key: "reindex",
- width: 200,
+ width: 120,
},
{
- title: "",
- dataIndex: "delete",
- key: "delete",
- width: 30,
- },
- {
- title: "",
+ title: "Select Default",
dataIndex: "select",
key: "select",
- width: 30,
+ align: "center",
+ width: 120,
},
];
@@ -496,33 +491,29 @@ function ManageDocsModal({
</Tooltip>
)}
</div>
+ <ConfirmModal
+ handleConfirm={() => handleDelete(item?.document_id)}
+ content="The document will be permanently deleted."
+ >
+ <Tooltip title="Delete">
+ <Button
+ size="small"
+ icon={<DeleteOutlined />}
+ disabled={
+ isMultiPassExtractLoading ||
+ isSinglePassExtractLoading ||
+ indexDocs.includes(item?.document_id) ||
+ isUploading ||
+ isPublicSource
+ }
+ />
+ </Tooltip>
+ </ConfirmModal>
<div className="center">
{infoIndex(indexMessages?.[item?.document_name])}
</div>
</Space>
),
- delete: (
- <ConfirmModal
- handleConfirm={() => handleDelete(item?.document_id)}
- content="The document will be permanently deleted."
- >
- <Tooltip title="Delete">
- <Button
- size="small"
- className="display-flex-align-center"
- disabled={
- isMultiPassExtractLoading ||
- isSinglePassExtractLoading ||
- indexDocs.includes(item?.document_id) ||
- isUploading ||
- isPublicSource
- }
- >
- <DeleteOutlined className="manage-llm-pro-icon" />
- </Button>
- </Tooltip>
- </ConfirmModal>
- ),
select: (
<Radio
checked={selectedDoc?.document_id === item?.document_id}
diff --git a/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.css b/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.css
index 9047649d1..56cf5658e 100644
--- a/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.css
+++ b/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.css
@@ -1,9 +1,5 @@
/* Styles for ManageLlmProfiles */
-.manage-llm-pro-icon {
- font-size: 10px;
-}
-
.action-buttons-container {
display: flex;
align-items: center;
diff --git a/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.jsx b/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.jsx
index d3744584f..aab5e8558 100644
--- a/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.jsx
+++ b/frontend/src/components/custom-tools/manage-llm-profiles/ManageLlmProfiles.jsx
@@ -122,20 +122,16 @@ function ManageLlmProfiles() {
<Tooltip title="Copy Profile ID">
<Button
size="small"
- className="display-flex-align-center"
+ icon={<CopyOutlined />}
onClick={() => copyProfileId(item?.profile_id)}
- >
- <CopyOutlined classID="manage-llm-pro-icon" />
- </Button>
+ />
</Tooltip>
<Button
size="small"
- className="display-flex-align-center"
+ icon={<EditOutlined />}
disabled={isPublicSource}
onClick={() => handleEdit(item?.profile_id)}
- >
- <EditOutlined classID="manage-llm-pro-icon" />
- </Button>
+ />
<ConfirmModal
handleConfirm={() => handleDelete(item?.profile_id)}
content="The LLM profile will be permanently deleted."
@@ -148,13 +144,11 @@ function ManageLlmProfiles() {
>
<Button
size="small"
- className="display-flex-align-center"
+ icon={<DeleteOutlined />}
disabled={
isPublicSource || defaultLlmProfile === item?.profile_id
}
- >
- <DeleteOutlined classID="manage-llm-pro-icon" />
- </Button>
+ />
</Tooltip>
</ConfirmModal>
</div>
diff --git a/frontend/src/components/pipelines-or-deployments/notification-modal/DisplayNotifications.jsx b/frontend/src/components/pipelines-or-deployments/notification-modal/DisplayNotifications.jsx
index 60020a451..9754dd20a 100644
--- a/frontend/src/components/pipelines-or-deployments/notification-modal/DisplayNotifications.jsx
+++ b/frontend/src/components/pipelines-or-deployments/notification-modal/DisplayNotifications.jsx
@@ -48,10 +48,9 @@ function DisplayNotifications({
<Button
type="text"
size="small"
+ icon={<EditOutlined />}
onClick={() => handleEdit(record)}
- >
- <EditOutlined />
- </Button>
+ />
</Tooltip>
</Space>
<Space className="actions">
@@ -60,9 +59,7 @@ function DisplayNotifications({
handleConfirm={() => handleDelete(record?.id, record?.name)}
content="Are you sure you want to delete?"
>
- <Button type="text" size="small">
- <DeleteOutlined />
- </Button>
+ <Button type="text" size="small" icon={<DeleteOutlined />} />
</ConfirmModal>
</Tooltip>
</Space>
diff --git a/frontend/src/components/settings/platform/PlatformSettings.jsx b/frontend/src/components/settings/platform/PlatformSettings.jsx
index c7010fa9d..bdc996a6a 100644
--- a/frontend/src/components/settings/platform/PlatformSettings.jsx
+++ b/frontend/src/components/settings/platform/PlatformSettings.jsx
@@ -317,11 +317,10 @@ function PlatformSettings() {
>
<Button
size="small"
+ icon={<DeleteOutlined />}
disabled={keyDetails?.id === null}
loading={isDeletingIndex === keyIndex}
- >
- <DeleteOutlined />
- </Button>
+ />
</ConfirmModal>
</Col>
</Row>