修复透明度覆盖影响设置问题,优化样式

This commit is contained in:
eoao
2025-06-06 00:23:31 +08:00
parent a787ee6404
commit 6446e1aa34
15 changed files with 179 additions and 147 deletions
@@ -289,7 +289,7 @@ function htmlToText(email) {
function cleanSpace(text) {
return text
.replace(/[\u200B-\u200F\uFEFF]/g, '') // 移除零宽空格、ZWNJ、ZWJ、LRM、RLM、BOM
.replace(/[\u200B-\u200F\uFEFF\u034F\u200B-\u200F\u00A0\u3000]/g, '') // 移除零宽空格
.replace(/\s+/g, ' ') // 多空白合并成一个空格
.trim();
}
@@ -705,10 +705,7 @@ function loadData() {
}
&:hover {
box-shadow: inset 1px 0 0 rgb(218, 220, 224),
inset -1px 0 0 rgb(218, 220, 224),
0 1px 2px 0 rgba(60, 64, 67, 0.3),
0 1px 3px 1px rgba(60, 64, 67, 0.15);
background-color: #F2F6FC;
z-index: 0;
}
@@ -75,6 +75,7 @@ function initEditor() {
mobile: {
toolbar: 'fullscreen bold emoticons forecolor fontsize | alignleft aligncenter alignright alignjustify | outdent indent | bullist numlist | link image | table code preview ',
},
font_size_formats: '8pt 10pt 12pt 14pt 16pt 18pt 24pt 36pt',
emoticons_search: false,
language: 'zh_CN',
language_url: '/tinymce/langs/zh_CN.js',
+1 -1
View File
@@ -127,7 +127,7 @@ const noLoading = ref(false)
const loading = ref(false)
const followLoading = ref(false);
const verifyShow = ref(false)
let turnstileId = false
let turnstileId = null
let verifyToken = ''
const addForm = reactive({
email: '',
+2 -2
View File
@@ -69,8 +69,8 @@ const route = useRoute();
.title {
margin: 15px 10px;
height: 50px;
border-radius: 6px;
height: 45px;
border-radius: 8px;
display: flex;
position: relative;
font-size: 16px;
+6
View File
@@ -4,8 +4,14 @@ import {loginUserInfo} from "@/request/my.js";
export const useUserStore = defineStore('user', {
state: () => ({
user: {},
refreshList: 0,
}),
actions: {
refreshUserList() {
loginUserInfo().then(user => {
this.refreshList ++
})
},
refreshUserInfo() {
loginUserInfo().then(user => {
this.user = user
+2 -1
View File
@@ -122,7 +122,7 @@ const registerLoading = ref(false)
suffix.value = domainList[0]
const verifyShow = ref(false)
let verifyToken = ''
let turnstileId = ''
let turnstileId = null
window.onTurnstileSuccess = (token) => {
@@ -268,6 +268,7 @@ function submitRegister() {
registerForm.password = ''
registerForm.confirmPassword = ''
registerLoading.value = false
turnstileId = null
verifyToken = ''
ElMessage({
message: '注册成功',
+10
View File
@@ -99,11 +99,13 @@ import {roleAdd, roleDelete, rolePermTree, roleRoleList, roleSet, roleSetDef} fr
import {ElMessage, ElMessageBox} from "element-plus";
import loading from '@/components/loading/index.vue';
import {useRoleStore} from "@/store/role.js";
import {useUserStore} from "@/store/user.js";
defineOptions({
name: 'role'
})
const userStore = useUserStore();
const roleStore = useRoleStore();
const roleFormShow = ref(false)
const treeList = reactive([])
@@ -175,6 +177,7 @@ function delRole(role) {
plain: true
})
getRoleList()
userStore.refreshUserList()
roleStore.refreshSelect()
})
});
@@ -218,6 +221,13 @@ function setRole() {
type: "success",
plain: true
})
const names = roles.value.map(role => role.name)
if (!names.includes(params.name)) {
roleStore.refreshSelect()
}
roleFormShow.value = false
getRoleList()
}).finally(() => {
+2 -2
View File
@@ -297,7 +297,7 @@
</template>
<script setup>
import {defineOptions, nextTick, onMounted, reactive, ref} from "vue";
import {defineOptions, onMounted, reactive, ref} from "vue";
import {physicsDeleteAll, setBackground, settingQuery, settingSet} from "@/request/setting.js";
import {ElMessage, ElMessageBox} from "element-plus";
import {useSettingStore} from "@/store/setting.js";
@@ -353,7 +353,7 @@ onMounted(() => {
})
function doOpacityChange() {
const form = {...setting.value}
const form = {}
form.loginOpacity = loginOpacity.value
editSetting(form,true)
}
+17 -1
View File
@@ -239,12 +239,14 @@ import {tzDayjs} from "@/utils/day.js";
import {useSettingStore} from "@/store/setting.js";
import {isEmail} from "@/utils/verify-utils.js";
import {useRoleStore} from "@/store/role.js";
import {useUserStore} from "@/store/user.js";
defineOptions({
name: 'user'
})
const roleStore = useRoleStore()
const userStore = useUserStore()
const settingStore = useSettingStore()
const filteredValue = ['normal', 'del']
const filters = [{text: '正常', value: 'normal'}, {text: '删除', value: 'del'}]
@@ -314,6 +316,10 @@ watch(() => roleStore.refresh, () => {
})
})
watch(() => userStore.refreshList, () => {
getUserList(false)
})
getUserList()
const filterItem = reactive({
@@ -631,7 +637,7 @@ function search() {
function updatePwd() {
if (userForm.password.length < 6) {
if (!userForm.password) {
ElMessage({
message: '密码不能为空',
type: 'error',
@@ -754,6 +760,16 @@ function adjustWidth() {
.el-message-box__message {
word-break: break-all;
}
.el-table-filter__bottom {
button:last-child {
display: none;
}
}
.el-table-filter__content {
min-width: 0;
}
</style>
<style lang="scss" scoped>
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+2 -2
View File
@@ -6,8 +6,8 @@
<title></title>
<link rel="icon" href="/assets/favicon-C5dAZutX.svg" type="image/svg+xml">
<script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script>
<script type="module" crossorigin src="/assets/index-DWsyDqKg.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-DeM-iAnI.css">
<script type="module" crossorigin src="/assets/index-zSxipgrR.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-CH_TBBJw.css">
</head>
<body>
<div id="loading-first">
-2
View File
@@ -38,7 +38,6 @@ const requirePerms = [
'/user/setPwd',
'/user/setStatus',
'/user/setType',
'/user/star',
'/user/list',
'/user/resetSendCount',
'/user/add'
@@ -61,7 +60,6 @@ const premKey = {
'user:set-pwd': ['/user/setPwd'],
'user:set-status': ['/user/setStatus'],
'user:set-type': ['/user/setType'],
'user:star': ['/user/star'],
'user:delete': ['/user/delete'],
'sys-email:query': ['/sys-email/list'],
'sys-email:delete': ['/sys-email/delete'],
+4 -1
View File
@@ -81,13 +81,14 @@ const initService = {
(11, '用户删除', 'user:delete', 6, 2, 7),
(12, '用户收藏', 'user:star', 6, 2, 5),
(13, '权限控制', '', 0, 1, 5),
(30, '身份添加', 'role:add', 13, 2, -1),
(14, '身份查看', 'role:query', 13, 2, 0),
(15, '身份修改', 'role:set', 13, 2, 1),
(16, '身份删除', 'role:delete', 13, 2, 2),
(17, '系统设置', '', 0, 1, 6),
(18, '设置查看', 'setting:query', 17, 2, 0),
(19, '设置修改', 'setting:set', 17, 2, 1),
(20, '物理清空', 'seting:clear', 17, 2, 2),
(20, '物理清空', 'setting:clean', 17, 2, 2),
(21, '邮箱侧栏', '', 0, 0, 1),
(22, '邮箱查看', 'account:query', 21, 2, 0),
(23, '邮箱添加', 'account:add', 21, 2, 1),
@@ -100,6 +101,8 @@ const initService = {
`).run();
}
await c.env.db.prepare(`UPDATE perm SET perm_key = 'setting:clean' WHERE perm_key = 'seting:clear'`).run();
await c.env.db.prepare(`DELETE FROM perm WHERE perm_key = 'user:star'`).run();
// 创建 role 表并插入默认身份
await c.env.db.prepare(`
CREATE TABLE IF NOT EXISTS role (