Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

chore: button style and text (#11924)

Liu Ji592bdce6f67a
diff --git a/frontend/src/components/IssueV1/components/Panel/IssueReviewActionPanel.vue b/frontend/src/components/IssueV1/components/Panel/IssueReviewActionPanel.vue
index 592ad1e751..30495f6426 100644
--- a/frontend/src/components/IssueV1/components/Panel/IssueReviewActionPanel.vue
+++ b/frontend/src/components/IssueV1/components/Panel/IssueReviewActionPanel.vue
@@ -70,10 +70,10 @@
<template #trigger>
<NButton
:disabled="confirmErrors.length > 0"
- v-bind="issueReviewActionButtonProps(action)"
+ v-bind="confirmButtonProps"
@click="handleClickConfirm"
>
- {{ issueReviewActionDisplayName(action) }}
+ {{ $t("common.confirm") }}
</NButton>
</template>
<template #default>
@@ -176,6 +176,15 @@ const confirmErrors = computed(() => {
return errors;
});
+const confirmButtonProps = computed(() => {
+ if (!props.action) return {};
+ const p = issueReviewActionButtonProps(props.action);
+ if (p.type === "default") {
+ p.type = "primary";
+ }
+ return p;
+});
+
const handleClickConfirm = (e: MouseEvent) => {
const button = e.target as HTMLElement;
const { left, top, width, height } = button.getBoundingClientRect();
diff --git a/frontend/src/components/IssueV1/components/Panel/IssueStatusActionPanel.vue b/frontend/src/components/IssueV1/components/Panel/IssueStatusActionPanel.vue
index 371195f708..250ff9c94b 100644
--- a/frontend/src/components/IssueV1/components/Panel/IssueStatusActionPanel.vue
+++ b/frontend/src/components/IssueV1/components/Panel/IssueStatusActionPanel.vue
@@ -65,10 +65,10 @@
<template #trigger>
<NButton
:disabled="confirmErrors.length > 0"
- v-bind="issueStatusActionButtonProps(action)"
+ v-bind="confirmButtonProps"
@click="handleConfirm(action, comment)"
>
- {{ issueStatusActionDisplayName(action) }}
+ {{ $t("common.confirm") }}
</NButton>
</template>
<template #default>
@@ -147,6 +147,15 @@ const confirmErrors = computed(() => {
return errors;
});
+const confirmButtonProps = computed(() => {
+ if (!props.action) return {};
+ const p = issueStatusActionButtonProps(props.action);
+ if (p.type === "default") {
+ p.type = "primary";
+ }
+ return p;
+});
+
const handleConfirm = async (
action: IssueStatusAction,
comment: string | undefined