Skip to content

Commit

Permalink
Fix UI (#250)
Browse files Browse the repository at this point in the history
  • Loading branch information
sheepzh committed Dec 25, 2023
1 parent 1ebf82d commit 633bde5
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/app/components/limit/table/column/operation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { defineComponent, h } from "vue"
import { t } from "@app/locale"
import optionService from "@service/option-service"
import { judgeVerificationRequired, processVerification } from "./common"
import { locale } from "@i18n"

const label = t(msg => msg.limit.item.operation)
const deleteButtonText = t(msg => msg.button.delete)
Expand Down Expand Up @@ -42,6 +43,14 @@ async function handleModify(row: timer.limit.Item, callback: () => void) {
}
}

const LOCALE_WIDTH: { [locale in timer.Locale]: number } = {
en: 200,
zh_CN: 200,
ja: 200,
zh_TW: 200,
pt_PT: 250,
}

const _default = defineComponent({
emits: {
rowDelete: (_row: timer.limit.Item, _cond: string) => true,
Expand All @@ -51,7 +60,7 @@ const _default = defineComponent({
return () => h(ElTableColumn, {
prop: 'operations',
label,
width: 200,
width: LOCALE_WIDTH[locale],
align: 'center',
}, {
default: ({ row }: { row: timer.limit.Item }) => [
Expand Down

0 comments on commit 633bde5

Please sign in to comment.