mirror of
https://github.com/AstrBotDevs/AstrBot
synced 2026-07-16 01:40:15 +08:00
fix: port IME enter fix and Firecrawl tool name from master
# Conflicts: # dashboard/src/components/chat/ChatInput.vue
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* Auto-generated MDI subset – 274 icons */
|
||||
/* Auto-generated MDI subset – 260 icons */
|
||||
/* Do not edit manually. Run: pnpm run subset-icons */
|
||||
|
||||
@font-face {
|
||||
@@ -220,6 +220,10 @@
|
||||
content: "\F0765";
|
||||
}
|
||||
|
||||
.mdi-circle-outline::before {
|
||||
content: "\F0766";
|
||||
}
|
||||
|
||||
.mdi-circle-small::before {
|
||||
content: "\F09DF";
|
||||
}
|
||||
@@ -244,10 +248,6 @@
|
||||
content: "\F0167";
|
||||
}
|
||||
|
||||
.mdi-code-braces::before {
|
||||
content: "\F0169";
|
||||
}
|
||||
|
||||
.mdi-code-json::before {
|
||||
content: "\F0626";
|
||||
}
|
||||
@@ -416,10 +416,6 @@
|
||||
content: "\F022E";
|
||||
}
|
||||
|
||||
.mdi-file-delimited-outline::before {
|
||||
content: "\F0EA5";
|
||||
}
|
||||
|
||||
.mdi-file-document::before {
|
||||
content: "\F0219";
|
||||
}
|
||||
@@ -440,10 +436,6 @@
|
||||
content: "\F021C";
|
||||
}
|
||||
|
||||
.mdi-file-music-outline::before {
|
||||
content: "\F0E2A";
|
||||
}
|
||||
|
||||
.mdi-file-outline::before {
|
||||
content: "\F0224";
|
||||
}
|
||||
@@ -464,14 +456,6 @@
|
||||
content: "\F0A4D";
|
||||
}
|
||||
|
||||
.mdi-file-upload-outline::before {
|
||||
content: "\F0A4E";
|
||||
}
|
||||
|
||||
.mdi-file-video-outline::before {
|
||||
content: "\F0E2C";
|
||||
}
|
||||
|
||||
.mdi-file-word-box::before {
|
||||
content: "\F022D";
|
||||
}
|
||||
@@ -484,14 +468,6 @@
|
||||
content: "\F0236";
|
||||
}
|
||||
|
||||
.mdi-flash::before {
|
||||
content: "\F0241";
|
||||
}
|
||||
|
||||
.mdi-flash-off::before {
|
||||
content: "\F0243";
|
||||
}
|
||||
|
||||
.mdi-folder::before {
|
||||
content: "\F024B";
|
||||
}
|
||||
@@ -616,38 +592,10 @@
|
||||
content: "\F0318";
|
||||
}
|
||||
|
||||
.mdi-language-css3::before {
|
||||
content: "\F031C";
|
||||
}
|
||||
|
||||
.mdi-language-html5::before {
|
||||
content: "\F031D";
|
||||
}
|
||||
|
||||
.mdi-language-java::before {
|
||||
content: "\F0B37";
|
||||
}
|
||||
|
||||
.mdi-language-javascript::before {
|
||||
content: "\F031E";
|
||||
}
|
||||
|
||||
.mdi-language-markdown::before {
|
||||
content: "\F0354";
|
||||
}
|
||||
|
||||
.mdi-language-markdown-outline::before {
|
||||
content: "\F0F5B";
|
||||
}
|
||||
|
||||
.mdi-language-python::before {
|
||||
content: "\F0320";
|
||||
}
|
||||
|
||||
.mdi-language-typescript::before {
|
||||
content: "\F06E6";
|
||||
}
|
||||
|
||||
.mdi-layers-outline::before {
|
||||
content: "\F09FE";
|
||||
}
|
||||
@@ -908,10 +856,6 @@
|
||||
content: "\F167A";
|
||||
}
|
||||
|
||||
.mdi-send::before {
|
||||
content: "\F048A";
|
||||
}
|
||||
|
||||
.mdi-server::before {
|
||||
content: "\F048B";
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -100,7 +100,11 @@
|
||||
"passwordLowercase": "Password must include at least one lowercase letter",
|
||||
"passwordDigit": "Password must include at least one digit",
|
||||
"passwordMatch": "Passwords do not match",
|
||||
"usernameMinLength": "Username must be at least 3 characters"
|
||||
"usernameMinLength": "Username must be at least 3 characters",
|
||||
"strengthWeak": "Weak",
|
||||
"strengthFair": "Fair",
|
||||
"strengthGood": "Good",
|
||||
"strengthStrong": "Strong"
|
||||
},
|
||||
"actions": {
|
||||
"save": "Save Changes",
|
||||
|
||||
@@ -100,7 +100,11 @@
|
||||
"passwordLowercase": "密码必须包含至少一个小写字母",
|
||||
"passwordDigit": "密码必须包含至少一个数字",
|
||||
"passwordMatch": "两次输入的密码不一致",
|
||||
"usernameMinLength": "用户名长度至少3位"
|
||||
"usernameMinLength": "用户名长度至少3位",
|
||||
"strengthWeak": "弱",
|
||||
"strengthFair": "一般",
|
||||
"strengthGood": "好",
|
||||
"strengthStrong": "强"
|
||||
},
|
||||
"actions": {
|
||||
"save": "保存修改",
|
||||
|
||||
@@ -145,6 +145,48 @@ const usernameRules = computed(() => [
|
||||
t("core.header.accountDialog.validation.usernameMinLength"),
|
||||
]);
|
||||
|
||||
// 密码强度校验
|
||||
const passwordChecks = computed(() => [
|
||||
{
|
||||
key: "minLength",
|
||||
label: t("core.header.accountDialog.validation.passwordMinLength"),
|
||||
pass: newPassword.value.length >= 12,
|
||||
},
|
||||
{
|
||||
key: "uppercase",
|
||||
label: t("core.header.accountDialog.validation.passwordUppercase"),
|
||||
pass: /[A-Z]/.test(newPassword.value),
|
||||
},
|
||||
{
|
||||
key: "lowercase",
|
||||
label: t("core.header.accountDialog.validation.passwordLowercase"),
|
||||
pass: /[a-z]/.test(newPassword.value),
|
||||
},
|
||||
{
|
||||
key: "digit",
|
||||
label: t("core.header.accountDialog.validation.passwordDigit"),
|
||||
pass: /\d/.test(newPassword.value),
|
||||
},
|
||||
]);
|
||||
const passwordStrengthPercent = computed(() => {
|
||||
const passed = passwordChecks.value.filter((c) => c.pass).length;
|
||||
return (passed / passwordChecks.value.length) * 100;
|
||||
});
|
||||
const passwordStrengthColor = computed(() => {
|
||||
const pct = passwordStrengthPercent.value;
|
||||
if (pct <= 25) return "error";
|
||||
if (pct <= 50) return "warning";
|
||||
if (pct <= 75) return "info";
|
||||
return "success";
|
||||
});
|
||||
const passwordStrengthText = computed(() => {
|
||||
const pct = passwordStrengthPercent.value;
|
||||
if (pct <= 25) return t("core.header.accountDialog.validation.strengthWeak");
|
||||
if (pct <= 50) return t("core.header.accountDialog.validation.strengthFair");
|
||||
if (pct <= 75) return t("core.header.accountDialog.validation.strengthGood");
|
||||
return t("core.header.accountDialog.validation.strengthStrong");
|
||||
});
|
||||
|
||||
// 显示密码相关
|
||||
const showPassword = ref(false);
|
||||
const showNewPassword = ref(false);
|
||||
@@ -1179,6 +1221,40 @@ const isChristmas = computed(() => {
|
||||
@click:append-inner="showNewPassword = !showNewPassword"
|
||||
/>
|
||||
|
||||
<!-- 密码强度指示器 -->
|
||||
<div v-if="newPassword.length > 0" class="mb-4">
|
||||
<v-progress-linear
|
||||
:model-value="passwordStrengthPercent"
|
||||
:color="passwordStrengthColor"
|
||||
height="6"
|
||||
rounded
|
||||
class="mb-2"
|
||||
/>
|
||||
<div class="d-flex align-center mb-2">
|
||||
<span
|
||||
class="text-caption font-weight-medium"
|
||||
:class="`text-${passwordStrengthColor}`"
|
||||
>
|
||||
{{ passwordStrengthText }}
|
||||
</span>
|
||||
</div>
|
||||
<div class="password-checklist">
|
||||
<div
|
||||
v-for="check in passwordChecks"
|
||||
:key="check.key"
|
||||
class="d-flex align-center mb-1"
|
||||
:class="check.pass ? 'text-success' : 'text-medium-emphasis'"
|
||||
>
|
||||
<v-icon
|
||||
:icon="check.pass ? 'mdi-check-circle' : 'mdi-circle-outline'"
|
||||
size="small"
|
||||
class="mr-1"
|
||||
/>
|
||||
<span class="text-caption">{{ check.label }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<v-text-field
|
||||
v-model="confirmPassword"
|
||||
:append-inner-icon="showConfirmPassword ? 'mdi-eye-off' : 'mdi-eye'"
|
||||
|
||||
Reference in New Issue
Block a user