@manohub/ui 0.10.5 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +155 -155
- package/dist/components/form/index.js +8 -1
- package/dist/components/input/bordered.d.ts +15 -0
- package/dist/components/input/bordered.js +8 -0
- package/dist/components/input/index.d.ts +82 -31
- package/dist/components/input/index.js +16 -6
- package/dist/components/input/number-input.d.ts +239 -0
- package/dist/components/input/number-input.js +240 -0
- package/dist/components/select/index.d.ts +19 -0
- package/dist/components/select/index.js +10 -0
- package/dist/components/select/select-tree.d.ts +11 -0
- package/dist/components/select/select-tree.js +6 -0
- package/dist/components/select/select-trigger.d.ts +17 -0
- package/dist/components/select/select-trigger.js +9 -0
- package/dist/components/table/index.d.ts +85 -10
- package/dist/components/table/index.js +38 -9
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -0
- package/dist/styles/components/avatar.css +131 -131
- package/dist/styles/components/avatar.tokens.css +24 -24
- package/dist/styles/components/badge.css +266 -266
- package/dist/styles/components/badge.tokens.css +24 -24
- package/dist/styles/components/button.css +460 -460
- package/dist/styles/components/capsule.css +128 -128
- package/dist/styles/components/capsule.tokens.css +27 -27
- package/dist/styles/components/card.css +198 -198
- package/dist/styles/components/checkbox.css +145 -145
- package/dist/styles/components/checkbox.tokens.css +26 -26
- package/dist/styles/components/code-block.css +216 -216
- package/dist/styles/components/code-block.tokens.css +40 -40
- package/dist/styles/components/collapse.css +62 -62
- package/dist/styles/components/collapse.tokens.css +20 -20
- package/dist/styles/components/dialog.css +158 -158
- package/dist/styles/components/dialog.tokens.css +24 -24
- package/dist/styles/components/divider.css +75 -75
- package/dist/styles/components/divider.tokens.css +22 -22
- package/dist/styles/components/drawer.css +143 -143
- package/dist/styles/components/drawer.tokens.css +22 -22
- package/dist/styles/components/filter.css +29 -29
- package/dist/styles/components/form.css +456 -425
- package/dist/styles/components/form.tokens.css +19 -15
- package/dist/styles/components/input.css +659 -538
- package/dist/styles/components/input.tokens.css +43 -43
- package/dist/styles/components/layout.css +200 -200
- package/dist/styles/components/list-view.css +244 -244
- package/dist/styles/components/loading.css +76 -76
- package/dist/styles/components/loading.tokens.css +23 -23
- package/dist/styles/components/nav.css +48 -48
- package/dist/styles/components/notice.css +153 -153
- package/dist/styles/components/notice.tokens.css +17 -17
- package/dist/styles/components/notification.css +159 -159
- package/dist/styles/components/notification.tokens.css +37 -37
- package/dist/styles/components/page.css +473 -473
- package/dist/styles/components/pagination.css +303 -303
- package/dist/styles/components/pagination.tokens.css +32 -32
- package/dist/styles/components/panel.css +77 -77
- package/dist/styles/components/query-state.css +88 -88
- package/dist/styles/components/radio.css +271 -271
- package/dist/styles/components/radio.tokens.css +26 -26
- package/dist/styles/components/search.css +34 -34
- package/dist/styles/components/select.css +326 -326
- package/dist/styles/components/select.tokens.css +44 -44
- package/dist/styles/components/skeleton.css +60 -60
- package/dist/styles/components/skeleton.tokens.css +27 -27
- package/dist/styles/components/steps.css +205 -205
- package/dist/styles/components/steps.tokens.css +44 -44
- package/dist/styles/components/switch.css +165 -165
- package/dist/styles/components/switch.tokens.css +26 -26
- package/dist/styles/components/tabbar.css +235 -235
- package/dist/styles/components/tabbar.tokens.css +30 -30
- package/dist/styles/components/table.css +510 -504
- package/dist/styles/components/table.tokens.css +44 -44
- package/dist/styles/components/tag.css +127 -127
- package/dist/styles/components/tag.tokens.css +24 -24
- package/dist/styles/components/toast.css +185 -185
- package/dist/styles/components/toast.tokens.css +26 -26
- package/dist/styles/components/tooltip.css +89 -89
- package/dist/styles/components/tooltip.tokens.css +25 -25
- package/dist/styles/components/tree.css +173 -173
- package/dist/styles/components/upload.css +151 -151
- package/dist/styles/components/upload.tokens.css +27 -27
- package/dist/styles/index.css +153 -153
- package/dist/styles/operations/collapse.css +84 -84
- package/dist/styles/operations/popup.css +193 -193
- package/dist/styles/operations/tabs.css +82 -82
- package/package.json +62 -62
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* collapse —— 单件令牌(**基础值**)。
|
|
3
|
-
*
|
|
4
|
-
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
-
*
|
|
6
|
-
* ## 抽出说明
|
|
7
|
-
* 本文件从面文件里抽出(原先混写在 `collapse.css` 顶部):这些是**基础值**,锚在
|
|
8
|
-
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
-
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
-
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
-
*
|
|
12
|
-
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
-
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
-
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
-
*/
|
|
16
|
-
[data-manohub-ui] {
|
|
17
|
-
/* 单件几何(只服务本件,故写在这里;跨件令牌才进 theme/) */
|
|
18
|
-
--ui-collapse-header-gap: var(--ui-space-2); /* 标题位与尾部间距 8px(规范实测) */
|
|
19
|
-
--ui-collapse-header-min-height: var(--ui-row-height); /* 头行最小高 = 行高档,保证可点区高度 */
|
|
20
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* collapse —— 单件令牌(**基础值**)。
|
|
3
|
+
*
|
|
4
|
+
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
+
*
|
|
6
|
+
* ## 抽出说明
|
|
7
|
+
* 本文件从面文件里抽出(原先混写在 `collapse.css` 顶部):这些是**基础值**,锚在
|
|
8
|
+
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
+
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
+
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
+
*
|
|
12
|
+
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
+
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
+
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
+
*/
|
|
16
|
+
[data-manohub-ui] {
|
|
17
|
+
/* 单件几何(只服务本件,故写在这里;跨件令牌才进 theme/) */
|
|
18
|
+
--ui-collapse-header-gap: var(--ui-space-2); /* 标题位与尾部间距 8px(规范实测) */
|
|
19
|
+
--ui-collapse-header-min-height: var(--ui-row-height); /* 头行最小高 = 行高档,保证可点区高度 */
|
|
20
|
+
}
|
|
@@ -1,158 +1,158 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Dialog —— 对话框皮肤(与操作层并列组合:`class="mh-popup mh-dialog"`)。
|
|
3
|
-
*
|
|
4
|
-
* 出处:`@aihub/theme` 的 `playground/components/dialog.css` 与 `src/components/dialog.css`
|
|
5
|
-
* (面板 520 / 大档 760 / 圆角 16 / 软投影;页头 16 上内距 + 24 行高、内容内距 24、底栏 0/24/16;
|
|
6
|
-
* **三段之间无分割线**(规范 2026-09-17 按反馈撤除了页头 border-bottom 与底栏 border-top);
|
|
7
|
-
* 关闭件 20×20;真实遮罩按 Mask01 黑 45% —— 用户裁定,浅灰 25% + 模糊只留给静态样张)。
|
|
8
|
-
*
|
|
9
|
-
* 行为全在原生与操作层:`<dialog>` 由浏览器给模态语义、Esc 关闭、焦点陷阱与 `::backdrop`;
|
|
10
|
-
* 开合与定位归 `styles/operations/popup.css`(它认 `[open]`)。本件只给面。
|
|
11
|
-
*
|
|
12
|
-
* **类名与面文件名同根**:`.mh-dialog*`(元素走 `__`),一律 `mh-` 前缀。
|
|
13
|
-
|
|
14
|
-
*
|
|
15
|
-
* 边界(有意不做):规范的 `.popconfirm`(气泡确认)不在本件 —— 它是「浮层 + 按钮族」的组合用法
|
|
16
|
-
* (`class="mh-popup mh-card"` + 按钮),不需要新的面;尺寸 220/r10 那组值也不值得为它单开一族。
|
|
17
|
-
*/
|
|
18
|
-
.mh-dialog {
|
|
19
|
-
/* 三段式列布局:页头 / 底栏由内容定高(`flex: none`),内容区吃掉剩余高度。
|
|
20
|
-
与 `Drawer` 同构(那边一直是这么写的)—— 本件此前漏了这一层,表现为
|
|
21
|
-
**高度受控时底栏不贴底**(body 只有内容高,剩余空间全留在 footer 之后)。
|
|
22
|
-
不设高度时零影响:列容器无高度约束 ⇒ body 高 = 内容高(与改前逐像素一致)。
|
|
23
|
-
⚠️ 加 `display: flex` 会以作者源压过 UA 的 `dialog:not([open]) { display: none }`,
|
|
24
|
-
收起态靠操作层 `operations/popup.css` 的 `:is(… dialog.mh-popup:not([open]))` 兜住
|
|
25
|
-
(特异性 0-3-0,高于本行)—— **那条兜底不能删**。 */
|
|
26
|
-
display: flex;
|
|
27
|
-
flex-direction: column;
|
|
28
|
-
/**
|
|
29
|
-
* **`margin: auto` 必须写**(靠 `inset: 0` + `margin: auto` 居中)。
|
|
30
|
-
*
|
|
31
|
-
* 不能依赖 UA 那条 `dialog { margin: auto }`:作者源无条件压过 UA 源(与特异性无关),
|
|
32
|
-
* 而**几乎每个宿主的 reset 都有 `* { margin: 0 }`**(Tailwind preflight / 本仓 ui reset 都会发下),
|
|
33
|
-
* 一旦命中就把 UA 的 `auto` 归零 ⇒ 弹窗**贴上贴左**(`inset: 0` + 无 margin 的必然结果)。
|
|
34
|
-
* 2026-09-30 实测:在 `apps/skill`(还带 Tailwind)里 `getComputedStyle` 读到 `margin: 0px`、
|
|
35
|
-
* `rect = (0, 0)`;显式补 `auto` 后立刻回到 `(432, 43)` 的精确居中。
|
|
36
|
-
*
|
|
37
|
-
* 与 `Drawer` 那条 `margin: 0` 是**同一件事的两面**:那边要贴侧、必须把 `auto` 归零,
|
|
38
|
-
* 这边要居中、必须把 `auto` 写实 —— 两边都**不能交给 UA**。`Toast` 同(它也显式归零)。
|
|
39
|
-
*/
|
|
40
|
-
margin: auto;
|
|
41
|
-
width: var(--ui-dialog-width);
|
|
42
|
-
max-width: var(--ui-dialog-width);
|
|
43
|
-
padding: 0; /* UA 给 <dialog> 的内距一律归零:内距由页头 / 内容 / 底栏各自拥有 */
|
|
44
|
-
border: none; /* 专页面板无描边(撤除卡片自带的 1px 边) */
|
|
45
|
-
border-radius: var(--ui-dialog-radius);
|
|
46
|
-
background: var(--ui-base-100);
|
|
47
|
-
/* 规范 0 0 40px rgba(0,0,0,.04) → 本仓「卡片环境光」令牌(同族几何、色取本仓基准,不新造字面量) */
|
|
48
|
-
box-shadow: var(--ui-shadow-card);
|
|
49
|
-
color: var(--ui-base-content);
|
|
50
|
-
}
|
|
51
|
-
.mh-dialog--lg {
|
|
52
|
-
width: var(--ui-dialog-width-lg);
|
|
53
|
-
max-width: var(--ui-dialog-width-lg);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/* 真浮层遮罩:`<dialog>` 进 top layer 时才生成 ::backdrop(静态档不生成,对本面无影响) */
|
|
57
|
-
.mh-dialog::backdrop {
|
|
58
|
-
background: var(--ui-dialog-mask);
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/* 页头:标题左、关闭位右(标题行框 24 —— 16 + 24 + 内容上距 24 = 规范页面正文起点 64) */
|
|
62
|
-
.mh-dialog__header {
|
|
63
|
-
display: flex;
|
|
64
|
-
align-items: center;
|
|
65
|
-
justify-content: space-between;
|
|
66
|
-
gap: var(--ui-space-2);
|
|
67
|
-
flex: none; /* 高度受控时不被压缩(同 Drawer) */
|
|
68
|
-
padding: var(--ui-space-4) var(--ui-space-6) 0;
|
|
69
|
-
font-size: var(--ui-font-heading); /* 规范 16px */
|
|
70
|
-
line-height: var(--ui-line-heading);
|
|
71
|
-
font-weight: var(--ui-weight-medium);
|
|
72
|
-
color: var(--ui-base-content);
|
|
73
|
-
}
|
|
74
|
-
/* 语义档(`tone`):标题左侧一个**带圈语义图标**(图标位没有底色圆,故取带圈族 —— 见
|
|
75
|
-
`@manohub/icon` 的「两族」口径),颜色按档取语义色 —— 缺省(不传 tone)不渲染,故不影响既有外观。
|
|
76
|
-
取色口径与 `Notice` 同一张表(success / warning 取 -strong 档,否则浅底上对比度不足)。 */
|
|
77
|
-
.mh-dialog__tone-icon {
|
|
78
|
-
flex: none;
|
|
79
|
-
width: var(--ui-font-icon);
|
|
80
|
-
height: var(--ui-font-icon);
|
|
81
|
-
color: var(--mh-dialog-tone-color, var(--ui-primary));
|
|
82
|
-
}
|
|
83
|
-
.mh-dialog--info {
|
|
84
|
-
--mh-dialog-tone-color: var(--ui-info);
|
|
85
|
-
}
|
|
86
|
-
.mh-dialog--success {
|
|
87
|
-
--mh-dialog-tone-color: var(--ui-success-strong);
|
|
88
|
-
}
|
|
89
|
-
.mh-dialog--warning {
|
|
90
|
-
--mh-dialog-tone-color: var(--ui-warning-strong);
|
|
91
|
-
}
|
|
92
|
-
.mh-dialog--error {
|
|
93
|
-
--mh-dialog-tone-color: var(--ui-error);
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
/* 标题位(插槽版也走这个类,两路渲染同一份排版) */
|
|
97
|
-
.mh-dialog__title {
|
|
98
|
-
flex: 1 1 auto; /* 撑满中段:语义图标在左、关闭位在右(`space-between` 下三者的正确落位) */
|
|
99
|
-
min-width: 0;
|
|
100
|
-
overflow: hidden;
|
|
101
|
-
text-overflow: ellipsis;
|
|
102
|
-
white-space: nowrap;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.mh-dialog__close {
|
|
106
|
-
display: inline-flex;
|
|
107
|
-
align-items: center;
|
|
108
|
-
justify-content: center;
|
|
109
|
-
flex: none;
|
|
110
|
-
width: var(--ui-dialog-close-size);
|
|
111
|
-
height: var(--ui-dialog-close-size);
|
|
112
|
-
margin: calc(-1 * var(--ui-space-1)); /* 热区比字形大,但视觉上仍与标题同基线 */
|
|
113
|
-
padding: 0;
|
|
114
|
-
border: none;
|
|
115
|
-
border-radius: var(--ui-radius-sm);
|
|
116
|
-
background: transparent;
|
|
117
|
-
color: var(--ui-base-content-muted);
|
|
118
|
-
cursor: pointer;
|
|
119
|
-
transition: background-color 0.15s ease, color 0.15s ease;
|
|
120
|
-
}
|
|
121
|
-
.mh-dialog__close:hover,
|
|
122
|
-
.mh-dialog__close.is-hover {
|
|
123
|
-
background: var(--ui-base-200);
|
|
124
|
-
color: var(--ui-base-content);
|
|
125
|
-
}
|
|
126
|
-
.mh-dialog__close:focus-visible {
|
|
127
|
-
outline: 2px solid var(--ui-primary);
|
|
128
|
-
outline-offset: 2px;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
/* 内容区(内距 24;三段之间无分割线,交界间距只由三段内距单一拥有)
|
|
132
|
-
`flex: 1 1 auto` + `min-height: 0`:吃掉页头与底栏之外的全部高度(含 `panelHeight` /
|
|
133
|
-
消费方经 style 给的高度),超出即**本段**滚动 —— 页头与底栏因此永远可见。 */
|
|
134
|
-
.mh-dialog__body {
|
|
135
|
-
flex: 1 1 auto;
|
|
136
|
-
min-height: 0;
|
|
137
|
-
overflow-y: auto;
|
|
138
|
-
padding: var(--ui-space-6);
|
|
139
|
-
font-size: var(--ui-font-body);
|
|
140
|
-
line-height: var(--ui-line-body);
|
|
141
|
-
color: var(--ui-base-content);
|
|
142
|
-
}
|
|
143
|
-
/* 首尾孩子不吃外边距:正文里的 <p> 自带 UA margin,会与内容内距叠成一块大空档 */
|
|
144
|
-
.mh-dialog__body > :first-child {
|
|
145
|
-
margin-top: 0;
|
|
146
|
-
}
|
|
147
|
-
.mh-dialog__body > :last-child {
|
|
148
|
-
margin-bottom: 0;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
/* 底栏:按钮右对齐(按钮的面归按钮族)、间距 8、下内距 16 */
|
|
152
|
-
.mh-dialog__footer {
|
|
153
|
-
display: flex;
|
|
154
|
-
justify-content: flex-end;
|
|
155
|
-
gap: var(--ui-space-2);
|
|
156
|
-
flex: none; /* 高度受控时贴底且不被压缩(同 Drawer) */
|
|
157
|
-
padding: 0 var(--ui-space-6) var(--ui-space-4);
|
|
158
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Dialog —— 对话框皮肤(与操作层并列组合:`class="mh-popup mh-dialog"`)。
|
|
3
|
+
*
|
|
4
|
+
* 出处:`@aihub/theme` 的 `playground/components/dialog.css` 与 `src/components/dialog.css`
|
|
5
|
+
* (面板 520 / 大档 760 / 圆角 16 / 软投影;页头 16 上内距 + 24 行高、内容内距 24、底栏 0/24/16;
|
|
6
|
+
* **三段之间无分割线**(规范 2026-09-17 按反馈撤除了页头 border-bottom 与底栏 border-top);
|
|
7
|
+
* 关闭件 20×20;真实遮罩按 Mask01 黑 45% —— 用户裁定,浅灰 25% + 模糊只留给静态样张)。
|
|
8
|
+
*
|
|
9
|
+
* 行为全在原生与操作层:`<dialog>` 由浏览器给模态语义、Esc 关闭、焦点陷阱与 `::backdrop`;
|
|
10
|
+
* 开合与定位归 `styles/operations/popup.css`(它认 `[open]`)。本件只给面。
|
|
11
|
+
*
|
|
12
|
+
* **类名与面文件名同根**:`.mh-dialog*`(元素走 `__`),一律 `mh-` 前缀。
|
|
13
|
+
|
|
14
|
+
*
|
|
15
|
+
* 边界(有意不做):规范的 `.popconfirm`(气泡确认)不在本件 —— 它是「浮层 + 按钮族」的组合用法
|
|
16
|
+
* (`class="mh-popup mh-card"` + 按钮),不需要新的面;尺寸 220/r10 那组值也不值得为它单开一族。
|
|
17
|
+
*/
|
|
18
|
+
.mh-dialog {
|
|
19
|
+
/* 三段式列布局:页头 / 底栏由内容定高(`flex: none`),内容区吃掉剩余高度。
|
|
20
|
+
与 `Drawer` 同构(那边一直是这么写的)—— 本件此前漏了这一层,表现为
|
|
21
|
+
**高度受控时底栏不贴底**(body 只有内容高,剩余空间全留在 footer 之后)。
|
|
22
|
+
不设高度时零影响:列容器无高度约束 ⇒ body 高 = 内容高(与改前逐像素一致)。
|
|
23
|
+
⚠️ 加 `display: flex` 会以作者源压过 UA 的 `dialog:not([open]) { display: none }`,
|
|
24
|
+
收起态靠操作层 `operations/popup.css` 的 `:is(… dialog.mh-popup:not([open]))` 兜住
|
|
25
|
+
(特异性 0-3-0,高于本行)—— **那条兜底不能删**。 */
|
|
26
|
+
display: flex;
|
|
27
|
+
flex-direction: column;
|
|
28
|
+
/**
|
|
29
|
+
* **`margin: auto` 必须写**(靠 `inset: 0` + `margin: auto` 居中)。
|
|
30
|
+
*
|
|
31
|
+
* 不能依赖 UA 那条 `dialog { margin: auto }`:作者源无条件压过 UA 源(与特异性无关),
|
|
32
|
+
* 而**几乎每个宿主的 reset 都有 `* { margin: 0 }`**(Tailwind preflight / 本仓 ui reset 都会发下),
|
|
33
|
+
* 一旦命中就把 UA 的 `auto` 归零 ⇒ 弹窗**贴上贴左**(`inset: 0` + 无 margin 的必然结果)。
|
|
34
|
+
* 2026-09-30 实测:在 `apps/skill`(还带 Tailwind)里 `getComputedStyle` 读到 `margin: 0px`、
|
|
35
|
+
* `rect = (0, 0)`;显式补 `auto` 后立刻回到 `(432, 43)` 的精确居中。
|
|
36
|
+
*
|
|
37
|
+
* 与 `Drawer` 那条 `margin: 0` 是**同一件事的两面**:那边要贴侧、必须把 `auto` 归零,
|
|
38
|
+
* 这边要居中、必须把 `auto` 写实 —— 两边都**不能交给 UA**。`Toast` 同(它也显式归零)。
|
|
39
|
+
*/
|
|
40
|
+
margin: auto;
|
|
41
|
+
width: var(--ui-dialog-width);
|
|
42
|
+
max-width: var(--ui-dialog-width);
|
|
43
|
+
padding: 0; /* UA 给 <dialog> 的内距一律归零:内距由页头 / 内容 / 底栏各自拥有 */
|
|
44
|
+
border: none; /* 专页面板无描边(撤除卡片自带的 1px 边) */
|
|
45
|
+
border-radius: var(--ui-dialog-radius);
|
|
46
|
+
background: var(--ui-base-100);
|
|
47
|
+
/* 规范 0 0 40px rgba(0,0,0,.04) → 本仓「卡片环境光」令牌(同族几何、色取本仓基准,不新造字面量) */
|
|
48
|
+
box-shadow: var(--ui-shadow-card);
|
|
49
|
+
color: var(--ui-base-content);
|
|
50
|
+
}
|
|
51
|
+
.mh-dialog--lg {
|
|
52
|
+
width: var(--ui-dialog-width-lg);
|
|
53
|
+
max-width: var(--ui-dialog-width-lg);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
/* 真浮层遮罩:`<dialog>` 进 top layer 时才生成 ::backdrop(静态档不生成,对本面无影响) */
|
|
57
|
+
.mh-dialog::backdrop {
|
|
58
|
+
background: var(--ui-dialog-mask);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* 页头:标题左、关闭位右(标题行框 24 —— 16 + 24 + 内容上距 24 = 规范页面正文起点 64) */
|
|
62
|
+
.mh-dialog__header {
|
|
63
|
+
display: flex;
|
|
64
|
+
align-items: center;
|
|
65
|
+
justify-content: space-between;
|
|
66
|
+
gap: var(--ui-space-2);
|
|
67
|
+
flex: none; /* 高度受控时不被压缩(同 Drawer) */
|
|
68
|
+
padding: var(--ui-space-4) var(--ui-space-6) 0;
|
|
69
|
+
font-size: var(--ui-font-heading); /* 规范 16px */
|
|
70
|
+
line-height: var(--ui-line-heading);
|
|
71
|
+
font-weight: var(--ui-weight-medium);
|
|
72
|
+
color: var(--ui-base-content);
|
|
73
|
+
}
|
|
74
|
+
/* 语义档(`tone`):标题左侧一个**带圈语义图标**(图标位没有底色圆,故取带圈族 —— 见
|
|
75
|
+
`@manohub/icon` 的「两族」口径),颜色按档取语义色 —— 缺省(不传 tone)不渲染,故不影响既有外观。
|
|
76
|
+
取色口径与 `Notice` 同一张表(success / warning 取 -strong 档,否则浅底上对比度不足)。 */
|
|
77
|
+
.mh-dialog__tone-icon {
|
|
78
|
+
flex: none;
|
|
79
|
+
width: var(--ui-font-icon);
|
|
80
|
+
height: var(--ui-font-icon);
|
|
81
|
+
color: var(--mh-dialog-tone-color, var(--ui-primary));
|
|
82
|
+
}
|
|
83
|
+
.mh-dialog--info {
|
|
84
|
+
--mh-dialog-tone-color: var(--ui-info);
|
|
85
|
+
}
|
|
86
|
+
.mh-dialog--success {
|
|
87
|
+
--mh-dialog-tone-color: var(--ui-success-strong);
|
|
88
|
+
}
|
|
89
|
+
.mh-dialog--warning {
|
|
90
|
+
--mh-dialog-tone-color: var(--ui-warning-strong);
|
|
91
|
+
}
|
|
92
|
+
.mh-dialog--error {
|
|
93
|
+
--mh-dialog-tone-color: var(--ui-error);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/* 标题位(插槽版也走这个类,两路渲染同一份排版) */
|
|
97
|
+
.mh-dialog__title {
|
|
98
|
+
flex: 1 1 auto; /* 撑满中段:语义图标在左、关闭位在右(`space-between` 下三者的正确落位) */
|
|
99
|
+
min-width: 0;
|
|
100
|
+
overflow: hidden;
|
|
101
|
+
text-overflow: ellipsis;
|
|
102
|
+
white-space: nowrap;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.mh-dialog__close {
|
|
106
|
+
display: inline-flex;
|
|
107
|
+
align-items: center;
|
|
108
|
+
justify-content: center;
|
|
109
|
+
flex: none;
|
|
110
|
+
width: var(--ui-dialog-close-size);
|
|
111
|
+
height: var(--ui-dialog-close-size);
|
|
112
|
+
margin: calc(-1 * var(--ui-space-1)); /* 热区比字形大,但视觉上仍与标题同基线 */
|
|
113
|
+
padding: 0;
|
|
114
|
+
border: none;
|
|
115
|
+
border-radius: var(--ui-radius-sm);
|
|
116
|
+
background: transparent;
|
|
117
|
+
color: var(--ui-base-content-muted);
|
|
118
|
+
cursor: pointer;
|
|
119
|
+
transition: background-color 0.15s ease, color 0.15s ease;
|
|
120
|
+
}
|
|
121
|
+
.mh-dialog__close:hover,
|
|
122
|
+
.mh-dialog__close.is-hover {
|
|
123
|
+
background: var(--ui-base-200);
|
|
124
|
+
color: var(--ui-base-content);
|
|
125
|
+
}
|
|
126
|
+
.mh-dialog__close:focus-visible {
|
|
127
|
+
outline: 2px solid var(--ui-primary);
|
|
128
|
+
outline-offset: 2px;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/* 内容区(内距 24;三段之间无分割线,交界间距只由三段内距单一拥有)
|
|
132
|
+
`flex: 1 1 auto` + `min-height: 0`:吃掉页头与底栏之外的全部高度(含 `panelHeight` /
|
|
133
|
+
消费方经 style 给的高度),超出即**本段**滚动 —— 页头与底栏因此永远可见。 */
|
|
134
|
+
.mh-dialog__body {
|
|
135
|
+
flex: 1 1 auto;
|
|
136
|
+
min-height: 0;
|
|
137
|
+
overflow-y: auto;
|
|
138
|
+
padding: var(--ui-space-6);
|
|
139
|
+
font-size: var(--ui-font-body);
|
|
140
|
+
line-height: var(--ui-line-body);
|
|
141
|
+
color: var(--ui-base-content);
|
|
142
|
+
}
|
|
143
|
+
/* 首尾孩子不吃外边距:正文里的 <p> 自带 UA margin,会与内容内距叠成一块大空档 */
|
|
144
|
+
.mh-dialog__body > :first-child {
|
|
145
|
+
margin-top: 0;
|
|
146
|
+
}
|
|
147
|
+
.mh-dialog__body > :last-child {
|
|
148
|
+
margin-bottom: 0;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/* 底栏:按钮右对齐(按钮的面归按钮族)、间距 8、下内距 16 */
|
|
152
|
+
.mh-dialog__footer {
|
|
153
|
+
display: flex;
|
|
154
|
+
justify-content: flex-end;
|
|
155
|
+
gap: var(--ui-space-2);
|
|
156
|
+
flex: none; /* 高度受控时贴底且不被压缩(同 Drawer) */
|
|
157
|
+
padding: 0 var(--ui-space-6) var(--ui-space-4);
|
|
158
|
+
}
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* dialog —— 单件令牌(**基础值**)。
|
|
3
|
-
*
|
|
4
|
-
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
-
*
|
|
6
|
-
* ## 抽出说明
|
|
7
|
-
* 本文件从面文件里抽出(原先混写在 `dialog.css` 顶部):这些是**基础值**,锚在
|
|
8
|
-
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
-
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
-
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
-
*
|
|
12
|
-
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
-
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
-
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
-
*/
|
|
16
|
-
[data-manohub-ui] {
|
|
17
|
-
/* 单件令牌 */
|
|
18
|
-
--ui-dialog-width: 520px; /* 规范标准宽 */
|
|
19
|
-
--ui-dialog-width-lg: 760px;
|
|
20
|
-
--ui-dialog-radius: 16px; /* 规范 r16(本仓圆角刻度最大 8,故按实测给) */
|
|
21
|
-
--ui-dialog-close-size: 28px; /* 关闭件的点击热区(字形 14 居中) */
|
|
22
|
-
/* 规范 Mask01 黑 45%(用户 2026-09-15 裁定:真实遮罩用黑透明;浅灰 25% + blur 是专页样张特征) */
|
|
23
|
-
--ui-dialog-mask: rgba(0, 0, 0, 0.45);
|
|
24
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* dialog —— 单件令牌(**基础值**)。
|
|
3
|
+
*
|
|
4
|
+
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
+
*
|
|
6
|
+
* ## 抽出说明
|
|
7
|
+
* 本文件从面文件里抽出(原先混写在 `dialog.css` 顶部):这些是**基础值**,锚在
|
|
8
|
+
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
+
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
+
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
+
*
|
|
12
|
+
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
+
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
+
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
+
*/
|
|
16
|
+
[data-manohub-ui] {
|
|
17
|
+
/* 单件令牌 */
|
|
18
|
+
--ui-dialog-width: 520px; /* 规范标准宽 */
|
|
19
|
+
--ui-dialog-width-lg: 760px;
|
|
20
|
+
--ui-dialog-radius: 16px; /* 规范 r16(本仓圆角刻度最大 8,故按实测给) */
|
|
21
|
+
--ui-dialog-close-size: 28px; /* 关闭件的点击热区(字形 14 居中) */
|
|
22
|
+
/* 规范 Mask01 黑 45%(用户 2026-09-15 裁定:真实遮罩用黑透明;浅灰 25% + blur 是专页样张特征) */
|
|
23
|
+
--ui-dialog-mask: rgba(0, 0, 0, 0.45);
|
|
24
|
+
}
|
|
@@ -1,75 +1,75 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Divider —— 分隔线(水平 / 垂直 × 实线 / 虚线 × 可带中段文字)。
|
|
3
|
-
*
|
|
4
|
-
* 出处:设计稿《MH后台-0911》内容区**用了 44 处** 1px 分隔线,取值统一:
|
|
5
|
-
* - 水平:`0:2128 > 标题区 > 直线 2` = 1200×1(筛选区与页头带之间);
|
|
6
|
-
* - 垂直:`0:3920 > 直线 2备份` = 1×708(树栏与主栏之间);
|
|
7
|
-
* - 色:`#e6e6e6` = `--ui-base-300`(与页头下边线、表格线、卡片描边同源 —— 实线只有这一条「线」色)。
|
|
8
|
-
* 虚线档另按**线型档**走 `--ui-line-dashed`(= `base-400`,见 `@manohub/theme` 的 `default/colors.css`
|
|
9
|
-
* 头「三条口径」第 2 条):同样粗细下虚线的墨迹只有实线的一半,取实线色会整条发虚。
|
|
10
|
-
*
|
|
11
|
-
* **为什么单独成件**:这条线在业务里被自绘了 44 次(`border-bottom: 1px solid #e6e6e6` 一类),
|
|
12
|
-
* 于是「线色改一处漏一处」必然发生。收进一件后,改线色/改粗细只需要动本文件。
|
|
13
|
-
*
|
|
14
|
-
* 与 `Panel` / `Card` / `Table` 的关系:那三件的框线**是它们自己的边界**(写在各件的面里),
|
|
15
|
-
* 不由本件承担;本件服务的是**内容之间**的分隔。
|
|
16
|
-
*
|
|
17
|
-
* 垂直档的高度:`align-self: stretch` 走父容器的拉伸(父级是 flex 行时即整行高),
|
|
18
|
-
* 父级没有确定高度时退到 `min-height: 1em`。**不写 `height: 100%`** —— 那要求父级先有高度,
|
|
19
|
-
* 在 auto 高度的行内会塌成 0。
|
|
20
|
-
*/
|
|
21
|
-
.mh-divider {
|
|
22
|
-
box-sizing: border-box;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
/* ===== 水平档(分隔上下内容)===== */
|
|
26
|
-
.mh-divider--horizontal {
|
|
27
|
-
width: 100%;
|
|
28
|
-
border-top: 1px solid var(--ui-divider-line);
|
|
29
|
-
}
|
|
30
|
-
/* 虚线档**连同线色一起换**:只写 `border-top-style: dashed` 会让虚线仍吃实线色 `base-300`,
|
|
31
|
-
同一个分隔位上线型不同、深浅也不同(2026-09-30 实测发现 —— 当时只改了「带中段文字」那条路径)。 */
|
|
32
|
-
.mh-divider--horizontal.mh-divider--dashed {
|
|
33
|
-
border-top: 1px dashed var(--ui-line-dashed);
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/* 带中段文字:整条改成 flex 行,线由两根 `.mh-divider__line` 承担(左固定 24px、右吃剩余) */
|
|
37
|
-
.mh-divider--horizontal.mh-divider--with-label {
|
|
38
|
-
display: flex;
|
|
39
|
-
align-items: center;
|
|
40
|
-
gap: var(--ui-divider-label-gap);
|
|
41
|
-
border-top: 0;
|
|
42
|
-
font-size: var(--ui-font-caption);
|
|
43
|
-
line-height: var(--ui-line-caption);
|
|
44
|
-
color: var(--ui-divider-label-color);
|
|
45
|
-
}
|
|
46
|
-
.mh-divider__line {
|
|
47
|
-
flex: 1 1 auto;
|
|
48
|
-
height: 1px;
|
|
49
|
-
background: var(--ui-divider-line);
|
|
50
|
-
}
|
|
51
|
-
/* 左段固定宽(24):文字靠近左侧时观感更稳,也让长文字不会把左段挤没 */
|
|
52
|
-
.mh-divider__line--start {
|
|
53
|
-
flex: 0 0 auto;
|
|
54
|
-
width: var(--ui-space-6);
|
|
55
|
-
}
|
|
56
|
-
.mh-divider--dashed .mh-divider__line {
|
|
57
|
-
height: 0;
|
|
58
|
-
border-top: 1px dashed var(--ui-line-dashed);
|
|
59
|
-
}
|
|
60
|
-
.mh-divider__label {
|
|
61
|
-
flex: 0 0 auto;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/* ===== 垂直档(分隔左右内容)===== */
|
|
65
|
-
.mh-divider--vertical {
|
|
66
|
-
display: inline-block;
|
|
67
|
-
width: 1px;
|
|
68
|
-
min-height: 1em;
|
|
69
|
-
align-self: stretch;
|
|
70
|
-
border-left: 1px solid var(--ui-divider-line);
|
|
71
|
-
vertical-align: middle;
|
|
72
|
-
}
|
|
73
|
-
.mh-divider--vertical.mh-divider--dashed {
|
|
74
|
-
border-left: 1px dashed var(--ui-line-dashed);
|
|
75
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Divider —— 分隔线(水平 / 垂直 × 实线 / 虚线 × 可带中段文字)。
|
|
3
|
+
*
|
|
4
|
+
* 出处:设计稿《MH后台-0911》内容区**用了 44 处** 1px 分隔线,取值统一:
|
|
5
|
+
* - 水平:`0:2128 > 标题区 > 直线 2` = 1200×1(筛选区与页头带之间);
|
|
6
|
+
* - 垂直:`0:3920 > 直线 2备份` = 1×708(树栏与主栏之间);
|
|
7
|
+
* - 色:`#e6e6e6` = `--ui-base-300`(与页头下边线、表格线、卡片描边同源 —— 实线只有这一条「线」色)。
|
|
8
|
+
* 虚线档另按**线型档**走 `--ui-line-dashed`(= `base-400`,见 `@manohub/theme` 的 `default/colors.css`
|
|
9
|
+
* 头「三条口径」第 2 条):同样粗细下虚线的墨迹只有实线的一半,取实线色会整条发虚。
|
|
10
|
+
*
|
|
11
|
+
* **为什么单独成件**:这条线在业务里被自绘了 44 次(`border-bottom: 1px solid #e6e6e6` 一类),
|
|
12
|
+
* 于是「线色改一处漏一处」必然发生。收进一件后,改线色/改粗细只需要动本文件。
|
|
13
|
+
*
|
|
14
|
+
* 与 `Panel` / `Card` / `Table` 的关系:那三件的框线**是它们自己的边界**(写在各件的面里),
|
|
15
|
+
* 不由本件承担;本件服务的是**内容之间**的分隔。
|
|
16
|
+
*
|
|
17
|
+
* 垂直档的高度:`align-self: stretch` 走父容器的拉伸(父级是 flex 行时即整行高),
|
|
18
|
+
* 父级没有确定高度时退到 `min-height: 1em`。**不写 `height: 100%`** —— 那要求父级先有高度,
|
|
19
|
+
* 在 auto 高度的行内会塌成 0。
|
|
20
|
+
*/
|
|
21
|
+
.mh-divider {
|
|
22
|
+
box-sizing: border-box;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/* ===== 水平档(分隔上下内容)===== */
|
|
26
|
+
.mh-divider--horizontal {
|
|
27
|
+
width: 100%;
|
|
28
|
+
border-top: 1px solid var(--ui-divider-line);
|
|
29
|
+
}
|
|
30
|
+
/* 虚线档**连同线色一起换**:只写 `border-top-style: dashed` 会让虚线仍吃实线色 `base-300`,
|
|
31
|
+
同一个分隔位上线型不同、深浅也不同(2026-09-30 实测发现 —— 当时只改了「带中段文字」那条路径)。 */
|
|
32
|
+
.mh-divider--horizontal.mh-divider--dashed {
|
|
33
|
+
border-top: 1px dashed var(--ui-line-dashed);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/* 带中段文字:整条改成 flex 行,线由两根 `.mh-divider__line` 承担(左固定 24px、右吃剩余) */
|
|
37
|
+
.mh-divider--horizontal.mh-divider--with-label {
|
|
38
|
+
display: flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
gap: var(--ui-divider-label-gap);
|
|
41
|
+
border-top: 0;
|
|
42
|
+
font-size: var(--ui-font-caption);
|
|
43
|
+
line-height: var(--ui-line-caption);
|
|
44
|
+
color: var(--ui-divider-label-color);
|
|
45
|
+
}
|
|
46
|
+
.mh-divider__line {
|
|
47
|
+
flex: 1 1 auto;
|
|
48
|
+
height: 1px;
|
|
49
|
+
background: var(--ui-divider-line);
|
|
50
|
+
}
|
|
51
|
+
/* 左段固定宽(24):文字靠近左侧时观感更稳,也让长文字不会把左段挤没 */
|
|
52
|
+
.mh-divider__line--start {
|
|
53
|
+
flex: 0 0 auto;
|
|
54
|
+
width: var(--ui-space-6);
|
|
55
|
+
}
|
|
56
|
+
.mh-divider--dashed .mh-divider__line {
|
|
57
|
+
height: 0;
|
|
58
|
+
border-top: 1px dashed var(--ui-line-dashed);
|
|
59
|
+
}
|
|
60
|
+
.mh-divider__label {
|
|
61
|
+
flex: 0 0 auto;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* ===== 垂直档(分隔左右内容)===== */
|
|
65
|
+
.mh-divider--vertical {
|
|
66
|
+
display: inline-block;
|
|
67
|
+
width: 1px;
|
|
68
|
+
min-height: 1em;
|
|
69
|
+
align-self: stretch;
|
|
70
|
+
border-left: 1px solid var(--ui-divider-line);
|
|
71
|
+
vertical-align: middle;
|
|
72
|
+
}
|
|
73
|
+
.mh-divider--vertical.mh-divider--dashed {
|
|
74
|
+
border-left: 1px dashed var(--ui-line-dashed);
|
|
75
|
+
}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* divider —— 单件令牌(**基础值**)。
|
|
3
|
-
*
|
|
4
|
-
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
-
*
|
|
6
|
-
* ## 抽出说明
|
|
7
|
-
* 本文件从面文件里抽出(原先混写在 `divider.css` 顶部):这些是**基础值**,锚在
|
|
8
|
-
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
-
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
-
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
-
*
|
|
12
|
-
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
-
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
-
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
-
*/
|
|
16
|
-
[data-manohub-ui] {
|
|
17
|
-
/* 单件令牌 */
|
|
18
|
-
--ui-divider-line: var(--ui-base-300); /* **实线**档的线色(与卡片描边、表格线同源)——
|
|
19
|
-
虚线档不用它:虚线走线型档 `--ui-line-dashed`(`base-400`),在面文件的修饰符块里直接取 */
|
|
20
|
-
--ui-divider-label-gap: var(--ui-space-3); /* 中段文字与两侧线的距离 12 */
|
|
21
|
-
--ui-divider-label-color: var(--ui-base-content-subtle);
|
|
22
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* divider —— 单件令牌(**基础值**)。
|
|
3
|
+
*
|
|
4
|
+
* 本件自己的几何 / 尺寸 / 色彩槽位;只服务本件,故不随主题进 `@manohub/theme`。
|
|
5
|
+
*
|
|
6
|
+
* ## 抽出说明
|
|
7
|
+
* 本文件从面文件里抽出(原先混写在 `divider.css` 顶部):这些是**基础值**,锚在
|
|
8
|
+
* `[data-manohub-ui]` —— 跨包唯一作用域锚,由入口层无条件写在应用容器上,因此**任何落在
|
|
9
|
+
* 容器里的分件都取得到值**,不再依赖「声明在某个组件根类上」这条脆弱假设
|
|
10
|
+
* (历史症状:跨件消费的 `--ui-*-group-*` 取不到值,组内间距变 0)。
|
|
11
|
+
*
|
|
12
|
+
* ⚠️ `.mh-<件>--<档>` 这类**档位改写**留在面文件的修饰符块里 —— 它们靠「同一元素上两个
|
|
13
|
+
* 选择器改写同一个令牌」生效,搬到本文件会让档位失效。
|
|
14
|
+
* ⚠️ 新增组件要登记两处:本文件 + `src/styles/index.css`(见其文件头「五处齐备」)。
|
|
15
|
+
*/
|
|
16
|
+
[data-manohub-ui] {
|
|
17
|
+
/* 单件令牌 */
|
|
18
|
+
--ui-divider-line: var(--ui-base-300); /* **实线**档的线色(与卡片描边、表格线同源)——
|
|
19
|
+
虚线档不用它:虚线走线型档 `--ui-line-dashed`(`base-400`),在面文件的修饰符块里直接取 */
|
|
20
|
+
--ui-divider-label-gap: var(--ui-space-3); /* 中段文字与两侧线的距离 12 */
|
|
21
|
+
--ui-divider-label-color: var(--ui-base-content-subtle);
|
|
22
|
+
}
|