✨(component): 优化 switch 渲染逻辑和 text 描述边距
This commit is contained in:
parent
990bd4971c
commit
cc21bb1785
@ -85,6 +85,7 @@
|
|||||||
|
|
||||||
.layui-form-switch em {
|
.layui-form-switch em {
|
||||||
position: relative;
|
position: relative;
|
||||||
|
padding: 0 2px;
|
||||||
text-align: center !important;
|
text-align: center !important;
|
||||||
color: #999 !important;
|
color: #999 !important;
|
||||||
font-style: normal !important;
|
font-style: normal !important;
|
||||||
|
@ -75,7 +75,7 @@ const styles = computed(() => {
|
|||||||
'layui-switch-disabled': disabled,
|
'layui-switch-disabled': disabled,
|
||||||
}"
|
}"
|
||||||
>
|
>
|
||||||
<em>{{ isActive == true ? onswitchText : unswitchText }}</em>
|
<em v-if="onswitchText || unswitchText">{{ isActive == true ? onswitchText : unswitchText }}</em>
|
||||||
<span>
|
<span>
|
||||||
<div>
|
<div>
|
||||||
<template v-if="loading">
|
<template v-if="loading">
|
||||||
|
@ -55,7 +55,6 @@ const changeLocales = (lang: string, locales: any, merge: boolean) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const changeTheme = (theme: string) => {
|
const changeTheme = (theme: string) => {
|
||||||
|
|
||||||
const defaultPartial: Partial<Theme> = {
|
const defaultPartial: Partial<Theme> = {
|
||||||
mode: 1,
|
mode: 1,
|
||||||
brightness: 100,
|
brightness: 100,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user