feat: UI authTip to accessTip && worker / path return OK (#158)

This commit is contained in:
Dream Hunter
2024-04-23 12:50:20 +08:00
committed by GitHub
parent 58dcdc65f8
commit a3edb09305
8 changed files with 44 additions and 19 deletions

View File

@@ -29,24 +29,26 @@ const { t } = useI18n({
locale: localeCache.value || 'zh',
messages: {
en: {
auth: 'Admin Auth',
authTip: 'Please enter the correct auth code',
accessHeader: 'Admin Password',
accessTip: 'Please enter the admin password',
mails: 'Emails',
account: 'Account',
unknow: 'Mails with unknow receiver',
senderAccess: 'Sender Access Control',
sendBox: 'Send Box',
maintenance: 'Maintenance',
ok: 'OK',
},
zh: {
auth: 'Admin 授权',
authTip: '请输入正确的授权码',
accessHeader: 'Admin 密码',
accessTip: '请输入 Admin 密码',
mails: '邮件',
account: '账号',
unknow: '无收件人邮件',
senderAccess: '发件权限控制',
sendBox: '发件箱',
maintenance: '维护',
ok: '确定',
}
}
});
@@ -64,13 +66,13 @@ onMounted(async () => {
<n-modal v-model:show="showAdminAuth" :closable="false" :closeOnEsc="false" :maskClosable="false" preset="dialog"
title="Dialog">
<template #header>
<div>{{ t('auth') }}</div>
<div>{{ t('accessHeader') }}</div>
</template>
<p>{{ t('authTip') }}</p>
<p>{{ t('accessTip') }}</p>
<n-input v-model:value="adminAuth" type="textarea" :autosize="{ minRows: 3 }" />
<template #action>
<n-button @click="authFunc" size="small" tertiary round type="primary">
{{ t('auth') }}
<n-button @click="authFunc" type="primary">
{{ t('ok') }}
</n-button>
</template>
</n-modal>

View File

@@ -67,8 +67,8 @@ const { t } = useI18n({
logoutConfirm: 'Are you sure to logout?',
delteAccount: "Delete Account",
delteAccountConfirm: "Are you sure to delete your account and all emails for this account?",
auth: 'Auth',
authTip: 'Please enter the correct auth code',
accessHeader: 'Access Password',
accessTip: 'Please enter the correct password',
settings: 'Settings',
home: 'Home',
menu: 'Menu',
@@ -100,8 +100,8 @@ const { t } = useI18n({
logoutConfirm: '确定要登出吗?',
delteAccount: "删除账户",
delteAccountConfirm: "确定要删除你的账户和其中的所有邮件吗?",
auth: '授权',
authTip: '请输入正确的授权码',
accessHeader: '访问密码',
accessTip: '请输入站点访问密码',
settings: '设置',
home: '主页',
menu: '菜单',
@@ -513,15 +513,15 @@ onMounted(async () => {
<n-modal v-model:show="showAuth" :closable="false" :closeOnEsc="false" :maskClosable="false" preset="dialog"
title="Dialog">
<template #header>
<div>{{ t('auth') }}</div>
<div>{{ t('accessHeader') }}</div>
</template>
<p>{{ t('authTip') }}</p>
<p>{{ t('accessTip') }}</p>
<n-input v-model:value="auth" type="textarea" :autosize="{
minRows: 3
}" />
<template #action>
<n-button @click="authFunc" size="small" tertiary round type="primary">
{{ t('auth') }}
<n-button @click="authFunc" type="primary">
{{ t('ok') }}
</n-button>
</template>
</n-modal>