Skip to content

Commit cf2a137

Browse files
authored
style: Optimize some internationalization styles (#7689)
1 parent 42c30f3 commit cf2a137

File tree

6 files changed

+44
-18
lines changed

6 files changed

+44
-18
lines changed

frontend/src/App.vue

+8
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ import { GlobalStore } from '@/store';
1010
import zhCn from 'element-plus/es/locale/lang/zh-cn';
1111
import zhTw from 'element-plus/es/locale/lang/zh-tw';
1212
import en from 'element-plus/es/locale/lang/en';
13+
import ja from 'element-plus/es/locale/lang/ja';
14+
import ms from 'element-plus/es/locale/lang/ms';
15+
import ptBR from 'element-plus/es/locale/lang/pt-br';
16+
import ru from 'element-plus/es/locale/lang/ru';
1317
import { useTheme } from '@/hooks/use-theme';
1418
useTheme();
1519
@@ -22,6 +26,10 @@ const i18nLocale = computed(() => {
2226
if (globalStore.language === 'zh') return zhCn;
2327
if (globalStore.language === 'tw') return zhTw;
2428
if (globalStore.language === 'en') return en;
29+
if (globalStore.language === 'ja') return ja;
30+
if (globalStore.language === 'ms') return ms;
31+
if (globalStore.language === 'ru') return ru;
32+
if (globalStore.language === 'pt-br') return ptBR;
2533
return zhCn;
2634
});
2735

frontend/src/lang/modules/ja.ts

+5-4
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,8 @@ const message = {
452452
remote: 'リモート',
453453
remoteDB: 'リモートサーバー|リモートサーバー',
454454
manageRemoteDB: 'リモートDB',
455-
createRemoteDB: 'bind @.lower:database.remotedb',
456-
unBindRemoteDB: 'unbind @.lower:database.remotedb',
455+
createRemoteDB: 'リモートサーバーを追加',
456+
unBindRemoteDB: 'リモートサーバーのバインドを解除',
457457
unBindForce: '強制バインド',
458458
unBindForceHelper: '結合プロセス中にすべてのエラーを無視して、最終操作が成功するようにします',
459459
unBindRemoteHelper:
@@ -1137,7 +1137,7 @@ const message = {
11371137
clamLog: '@:toolbox.clam.clamconfログ',
11381138
freshClam: 'フレッシュクラム',
11391139
freshClamLog: '@:toolbox.clam.freshclamログ',
1140-
alertHelper: 'Professionalバージョンは、スケジュールされたスキャンとSMSアラートをサポートしています',
1140+
alertHelper: 'プロフェッショナル版は、定期スキャンとSMSアラート機能をサポートしています',
11411141
alertTitle: 'ウイルススキャンタスク({0}」感染したファイルアラートが検出されました',
11421142
},
11431143
},
@@ -1678,7 +1678,8 @@ const message = {
16781678
},
16791679
license: {
16801680
community: '無料',
1681-
pro: 'Pro',
1681+
oss: '無料',
1682+
pro: '専門',
16821683
trial: 'トライアル',
16831684
office: '正式',
16841685
trialInfo: 'バージョン',

frontend/src/views/container/container/terminal/index.vue

+4-4
Original file line numberDiff line numberDiff line change
@@ -20,21 +20,21 @@
2020
prop="command"
2121
:rules="Rules.requiredInput"
2222
>
23-
<el-checkbox style="width: 100px" border v-model="form.isCustom" @change="onChangeCommand">
23+
<el-checkbox style="width: 180px" border v-model="form.isCustom" @change="onChangeCommand">
2424
{{ $t('container.custom') }}
2525
</el-checkbox>
26-
<el-input style="width: calc(100% - 100px)" clearable v-model="form.command" />
26+
<el-input style="width: calc(100% - 180px)" clearable v-model="form.command" />
2727
</el-form-item>
2828
<el-form-item
2929
v-if="!form.isCustom"
3030
:label="$t('container.command')"
3131
prop="command"
3232
:rules="Rules.requiredSelect"
3333
>
34-
<el-checkbox style="width: 100px" border v-model="form.isCustom" @change="onChangeCommand">
34+
<el-checkbox style="width: 180px" border v-model="form.isCustom" @change="onChangeCommand">
3535
{{ $t('container.custom') }}
3636
</el-checkbox>
37-
<el-select style="width: calc(100% - 100px)" filterable clearable v-model="form.command">
37+
<el-select style="width: calc(100% - 180px)" filterable clearable v-model="form.command">
3838
<el-option value="/bin/ash" label="/bin/ash" />
3939
<el-option value="/bin/bash" label="/bin/bash" />
4040
<el-option value="/bin/sh" label="/bin/sh" />

frontend/src/views/database/mysql/conn/index.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@
8181
prop="password"
8282
>
8383
<el-input
84-
style="width: calc(100% - 147px)"
84+
style="width: calc(100% - 167px)"
8585
type="password"
8686
show-password
8787
clearable

frontend/src/views/home/index.vue

+25-8
Original file line numberDiff line numberDiff line change
@@ -169,13 +169,20 @@
169169
<el-col :xs="24" :sm="24" :md="8" :lg="8" :xl="8">
170170
<CardWithHeader :header="$t('home.systemInfo')">
171171
<template #body>
172-
<el-scrollbar>
173-
<el-descriptions :column="1" class="h-systemInfo" border>
172+
<div class="h-systemInfo">
173+
<el-descriptions :column="1" border>
174174
<el-descriptions-item class-name="system-content" label-class-name="system-label">
175175
<template #label>
176176
<span>{{ $t('home.hostname') }}</span>
177177
</template>
178-
{{ baseInfo.hostname }}
178+
<el-tooltip
179+
v-if="baseInfo.hostname.length > 30"
180+
:content="baseInfo.hostname"
181+
placement="bottom"
182+
>
183+
{{ baseInfo.hostname.substring(0, 27) + '...' }}
184+
</el-tooltip>
185+
<span v-else>{{ baseInfo.hostname }}</span>
179186
</el-descriptions-item>
180187
<el-descriptions-item class-name="system-content" label-class-name="system-label">
181188
<template #label>
@@ -191,7 +198,14 @@
191198
<template #label>
192199
<span>{{ $t('home.kernelVersion') }}</span>
193200
</template>
194-
{{ baseInfo.kernelVersion }}
201+
<el-tooltip
202+
v-if="baseInfo.kernelVersion.length > 30"
203+
:content="baseInfo.kernelVersion"
204+
placement="bottom"
205+
>
206+
{{ baseInfo.kernelVersion.substring(0, 27) + '...' }}
207+
</el-tooltip>
208+
<span v-else>{{ baseInfo.kernelVersion }}</span>
195209
</el-descriptions-item>
196210
<el-descriptions-item class-name="system-content" label-class-name="system-label">
197211
<template #label>
@@ -232,7 +246,7 @@
232246
{{ loadUpTime(currentInfo.uptime) }}
233247
</el-descriptions-item>
234248
</el-descriptions>
235-
</el-scrollbar>
249+
</div>
236250
</template>
237251
</CardWithHeader>
238252

@@ -681,7 +695,8 @@ onBeforeUnmount(() => {
681695
682696
.h-systemInfo {
683697
margin-left: 18px;
684-
height: 276px;
698+
height: 296px;
699+
overflow: auto;
685700
}
686701
@-moz-document url-prefix() {
687702
.h-systemInfo {
@@ -695,8 +710,10 @@ onBeforeUnmount(() => {
695710
color: var(--panel-text-color);
696711
border: none !important;
697712
background: none !important;
698-
width: fit-content !important;
699-
white-space: nowrap !important;
713+
max-width: 150px !important;
714+
white-space: nowrap;
715+
overflow: hidden;
716+
text-overflow: ellipsis;
700717
}
701718
702719
.system-content {

frontend/src/views/website/website/config/basic/other/index.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
22
<el-row :gutter="20" v-loading="loading">
3-
<el-col :xs="24" :sm="18" :md="8" :lg="8" :xl="8">
3+
<el-col :xs="24" :sm="18" :md="9" :lg="9" :xl="9">
44
<el-form ref="websiteForm" label-position="right" label-width="150px" :model="form" :rules="rules">
55
<el-form-item :label="$t('website.primaryDomain')" prop="primaryDomain">
66
<el-input v-model="form.primaryDomain"></el-input>

0 commit comments

Comments
 (0)