mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-21 23:34:31 +00:00
[i18n] g global namespace (#1843)
* Batch move global scope i18n to g. namespace * Minor fix * Update locale * Update locales [skip ci] * More moves * Regroup icon/color * nit * Fix component test --------- Co-authored-by: github-actions <github-actions@github.com>
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
</ul>
|
||||
<div class="flex gap-4 justify-end">
|
||||
<Button
|
||||
:label="$t('cancel')"
|
||||
:label="$t('g.cancel')"
|
||||
icon="pi pi-undo"
|
||||
severity="secondary"
|
||||
@click="onCancel"
|
||||
@@ -14,26 +14,26 @@
|
||||
/>
|
||||
<Button
|
||||
v-if="type === 'delete'"
|
||||
:label="$t('delete')"
|
||||
:label="$t('g.delete')"
|
||||
severity="danger"
|
||||
@click="onConfirm"
|
||||
icon="pi pi-trash"
|
||||
/>
|
||||
<Button
|
||||
v-else-if="type === 'overwrite'"
|
||||
:label="$t('overwrite')"
|
||||
:label="$t('g.overwrite')"
|
||||
severity="warn"
|
||||
@click="onConfirm"
|
||||
icon="pi pi-save"
|
||||
/>
|
||||
<template v-else-if="type === 'dirtyClose'">
|
||||
<Button
|
||||
:label="$t('no')"
|
||||
:label="$t('g.no')"
|
||||
severity="secondary"
|
||||
@click="onDeny"
|
||||
icon="pi pi-times"
|
||||
/>
|
||||
<Button :label="$t('save')" @click="onConfirm" icon="pi pi-save" />
|
||||
<Button :label="$t('g.save')" @click="onConfirm" icon="pi pi-save" />
|
||||
</template>
|
||||
<Button
|
||||
v-else-if="type === 'reinstall'"
|
||||
@@ -45,7 +45,7 @@
|
||||
<!-- Invalid - just show a close button. -->
|
||||
<Button
|
||||
v-else
|
||||
:label="$t('close')"
|
||||
:label="$t('g.close')"
|
||||
severity="primary"
|
||||
@click="onCancel"
|
||||
icon="pi pi-times"
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<div class="comfy-error-report">
|
||||
<Button
|
||||
v-show="!reportOpen"
|
||||
:label="$t('showReport')"
|
||||
:label="$t('g.showReport')"
|
||||
@click="showReport"
|
||||
text
|
||||
/>
|
||||
@@ -28,7 +28,7 @@
|
||||
/>
|
||||
<Button
|
||||
v-if="reportOpen"
|
||||
:label="$t('copyToClipboard')"
|
||||
:label="$t('g.copyToClipboard')"
|
||||
icon="pi pi-copy"
|
||||
@click="copyReportToClipboard"
|
||||
/>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
/>
|
||||
<label>{{ message }}</label>
|
||||
</FloatLabel>
|
||||
<Button @click="onConfirm">{{ $t('confirm') }}</Button>
|
||||
<Button @click="onConfirm">{{ $t('g.confirm') }}</Button>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
class="settings-search-box w-full mb-2"
|
||||
v-model:modelValue="searchQuery"
|
||||
@search="handleSearch"
|
||||
:placeholder="$t('searchSettings') + '...'"
|
||||
:placeholder="$t('g.searchSettings') + '...'"
|
||||
/>
|
||||
<Listbox
|
||||
v-model="activeCategory"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<Button
|
||||
@click="openGitHubIssues"
|
||||
:label="$t('findIssues')"
|
||||
:label="$t('g.findIssues')"
|
||||
severity="secondary"
|
||||
icon="pi pi-github"
|
||||
>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<template>
|
||||
<Button
|
||||
@click="reportIssue"
|
||||
:label="$t('reportIssue')"
|
||||
:label="$t('g.reportIssue')"
|
||||
:severity="submitted ? 'success' : 'secondary'"
|
||||
:icon="icon"
|
||||
:disabled="submitted"
|
||||
v-tooltip="$t('reportIssueTooltip')"
|
||||
v-tooltip="$t('g.reportIssueTooltip')"
|
||||
>
|
||||
</Button>
|
||||
</template>
|
||||
@@ -41,7 +41,7 @@ const reportIssue = async () => {
|
||||
submitted.value = true
|
||||
toast.add({
|
||||
severity: 'success',
|
||||
summary: t('reportSent'),
|
||||
summary: t('g.reportSent'),
|
||||
life: 3000
|
||||
})
|
||||
} finally {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<PanelTemplate value="About" class="about-container">
|
||||
<h2 class="text-2xl font-bold mb-2">{{ $t('about') }}</h2>
|
||||
<h2 class="text-2xl font-bold mb-2">{{ $t('g.about') }}</h2>
|
||||
<div class="space-y-2">
|
||||
<a
|
||||
v-for="badge in aboutPanelStore.badges"
|
||||
|
||||
@@ -7,7 +7,9 @@
|
||||
pt:text="w-full"
|
||||
>
|
||||
<div class="flex items-center justify-between">
|
||||
<div>{{ $t('currentUser') }}: {{ userStore.currentUser?.username }}</div>
|
||||
<div>
|
||||
{{ $t('g.currentUser') }}: {{ userStore.currentUser?.username }}
|
||||
</div>
|
||||
<Button icon="pi pi-sign-out" @click="logout" text />
|
||||
</div>
|
||||
</Message>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<template #header>
|
||||
<SearchBox
|
||||
v-model="filters['global'].value"
|
||||
:placeholder="$t('searchExtensions') + '...'"
|
||||
:placeholder="$t('g.searchExtensions') + '...'"
|
||||
/>
|
||||
<Message v-if="hasChanges" severity="info" pt:text="w-full">
|
||||
<ul>
|
||||
@@ -16,7 +16,7 @@
|
||||
</ul>
|
||||
<div class="flex justify-end">
|
||||
<Button
|
||||
:label="$t('reloadToApplyChanges')"
|
||||
:label="$t('g.reloadToApplyChanges')"
|
||||
@click="applyChanges"
|
||||
outlined
|
||||
severity="danger"
|
||||
@@ -30,7 +30,7 @@
|
||||
size="small"
|
||||
:filters="filters"
|
||||
>
|
||||
<Column field="name" :header="$t('extensionName')" sortable></Column>
|
||||
<Column field="name" :header="$t('g.extensionName')" sortable></Column>
|
||||
<Column
|
||||
:pt="{
|
||||
bodyCell: 'flex items-center justify-end'
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
:closable="true"
|
||||
@close="handleClose"
|
||||
>
|
||||
{{ $t('firstTimeUIMessage') }}
|
||||
{{ $t('g.firstTimeUIMessage') }}
|
||||
</Message>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<template #header>
|
||||
<SearchBox
|
||||
v-model="filters['global'].value"
|
||||
:placeholder="$t('searchKeybindings') + '...'"
|
||||
:placeholder="$t('g.searchKeybindings') + '...'"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -102,8 +102,8 @@
|
||||
</Dialog>
|
||||
<Button
|
||||
class="mt-4"
|
||||
:label="$t('reset')"
|
||||
v-tooltip="$t('resetKeybindingsTooltip')"
|
||||
:label="$t('g.reset')"
|
||||
v-tooltip="$t('g.resetKeybindingsTooltip')"
|
||||
icon="pi pi-trash"
|
||||
severity="danger"
|
||||
fluid
|
||||
|
||||
@@ -6,10 +6,10 @@
|
||||
@update:formValue="updateSettingValue"
|
||||
>
|
||||
<template #name-prefix>
|
||||
<Tag v-if="setting.experimental" :value="$t('experimental')" />
|
||||
<Tag v-if="setting.experimental" :value="$t('g.experimental')" />
|
||||
<Tag
|
||||
v-if="setting.deprecated"
|
||||
:value="$t('deprecated')"
|
||||
:value="$t('g.deprecated')"
|
||||
severity="danger"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
<NoResultsPlaceholder
|
||||
v-else
|
||||
icon="pi pi-search"
|
||||
:title="$t('noResultsFound')"
|
||||
:message="$t('searchFailedMessage')"
|
||||
:title="$t('g.noResultsFound')"
|
||||
:message="$t('g.searchFailedMessage')"
|
||||
/>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div>
|
||||
<h2 class="px-4">
|
||||
<i class="pi pi-cog"></i>
|
||||
<span>{{ $t('settings') }}</span>
|
||||
<span>{{ $t('g.settings') }}</span>
|
||||
</h2>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user