@agile-team/wl-skills-ui 1.8.12 → 1.8.13
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/CHANGELOG.md +8 -0
- package/README.md +4 -2
- package/package.json +1 -1
- package/skills/vendors/jh-components/SKILL.md +3 -3
- package/standards/ui/03-form.md +24 -0
- package/styles/element/_form.scss +21 -1
- package/styles/vendors/_base-components.scss +9 -16
- package/styles/vendors/_jh-ui.scss +23 -6
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,14 @@ All notable changes to **@agile-team/wl-skills-ui** will be documented in this f
|
|
|
4
4
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
|
|
6
6
|
|
|
7
|
+
## [1.8.13] - 2026-05-21
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **表单间距统一**:label 与右侧 Element Plus / jh-* 单行控件间距统一为 `--wk-form-label-control-gap: 16px`,避免 22px / 26px / 28px 混杂。
|
|
12
|
+
- **表单高度统一**:input / select / date-picker / cascader / input-number / autocomplete 等单行控件统一为 `--wk-form-control-height: 26px`,textarea 不强制固定高度。
|
|
13
|
+
- **label 冒号统一**:屏蔽 `@jhlc/jh-ui` 的 `.has-colon .com-text::after` 冒号注入,picker / select / input label 不再出现有的带冒号、有的不带冒号。
|
|
14
|
+
|
|
7
15
|
## [1.8.9] - 2026-05-17
|
|
8
16
|
|
|
9
17
|
### Improved
|
package/README.md
CHANGED
|
@@ -198,7 +198,7 @@ yarn add @agile-team/wl-skills-ui
|
|
|
198
198
|
| 依赖 | 推荐版本 | 备注 |
|
|
199
199
|
|---|---|---|
|
|
200
200
|
| `element-plus` | **`2.2.6-prod.3`** | 集团 jh- 定制版;EP 2.3.0 起引入 `.el-input__wrapper`,与 jh-ui 3.x 不兼容 |
|
|
201
|
-
| `@jhlc/jh-ui` | **`3.1.0`** | SCSS 皮肤包,`.com-text` label 包裹 + `.has-colon`
|
|
201
|
+
| `@jhlc/jh-ui` | **`3.1.0`** | SCSS 皮肤包,`.com-text` label 包裹 + `.has-colon` 冒号注入(wl-skills-ui 已统一屏蔽表单冒号) |
|
|
202
202
|
| `@agile-team/wl-skills-ui` | `^1.7.0` | 已对齐上述组合的 DOM 假设 |
|
|
203
203
|
|
|
204
204
|
三种识别方式,任选其一:
|
|
@@ -213,8 +213,10 @@ yarn add @agile-team/wl-skills-ui
|
|
|
213
213
|
|
|
214
214
|
## 版本亮点
|
|
215
215
|
|
|
216
|
-
当前 v1.8.
|
|
216
|
+
当前 v1.8.13:
|
|
217
217
|
|
|
218
|
+
- **表单密度统一**:label 与右侧控件间距统一 16px,单行 input / select / picker / jh-* 控件高度统一 26px
|
|
219
|
+
- **label 冒号统一**:屏蔽 jh-ui `.has-colon .com-text::after` 冒号注入,picker / select / input 不再有的带冒号、有的不带冒号
|
|
218
220
|
- **loading 遮罩质感优化**:BaseTable / AG Grid 的 v-loading 由灰色蒙层改为毛玻璃半透明(backdrop-filter),数据切换无感
|
|
219
221
|
- **R027** 检测业务代码硬编码 `.el-loading-mask` 背景色 → 提示删除,由包统一覆盖
|
|
220
222
|
- **R025** 语义合规:`options:[]` 退化检测 → 升级 `renderTagSlot` / `renderDictClassifyTag`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agile-team/wl-skills-ui",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.13",
|
|
4
4
|
"description": "企业级 UI 风格对齐框架 — Vue + Element Plus 项目通用化妆/原生双模式(tokens / element / vendors / layouts / runtime / scanner / fixer / skills)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./es/index.js",
|
|
@@ -29,8 +29,8 @@ applyTo: "**/*.vue"
|
|
|
29
29
|
|
|
30
30
|
项目同时安装 `@jhlc/jh-ui` 与 `element-plus@2.2.x` 时,输入控件 DOM 为 `.el-input > .el-input__inner`(**无 `.el-input__wrapper`**,EP 2.3.0 起才引入),表单 label 文本被包成 `<span class="com-text">`,并由 `.has-colon .com-text::after` 注入冒号。`_jh-ui.scss` 已精准覆盖:
|
|
31
31
|
|
|
32
|
-
- label `.com-text` 单行省略 + has-colon
|
|
33
|
-
- EP 2.2.x `.el-input__inner`
|
|
32
|
+
- label `.com-text` 单行省略 + has-colon 冒号屏蔽
|
|
33
|
+
- EP 2.2.x `.el-input__inner` 26px 高度、圆角 / focus / error 三态
|
|
34
34
|
- jh-select / jh-date-picker 的 `.el-select.is-focus` / `.el-input.is-focus` 兼容
|
|
35
35
|
- 必填星号在 inline-flex label 下显式声明颜色
|
|
36
36
|
|
|
@@ -38,7 +38,7 @@ applyTo: "**/*.vue"
|
|
|
38
38
|
|
|
39
39
|
- ❌ 在 jh-ui 项目里用 `.el-input__wrapper.is-focus` —— EP 2.2.x 没有 `__wrapper`,规则永不生效。
|
|
40
40
|
- ❌ 直接给 `.el-form-item__label` 写 `text-overflow: ellipsis` —— jh-ui 把它设为 `inline-flex`,文本在 `.com-text` 里,省略不会触发。
|
|
41
|
-
- ❌ 给 `.el-form-item__label` 加 `padding-right` 期望腾出冒号位 ——
|
|
41
|
+
- ❌ 给 `.el-form-item__label` 加 `padding-right` 期望腾出冒号位 —— 表单 label 不强制冒号,`.has-colon .com-text::after` 已由 `_jh-ui.scss` 统一屏蔽。
|
|
42
42
|
- ❌ 在不确定 EP 版本的情况下下笔修复 —— 必须先跑 `wl_ui_detect_skin` 或 `wl-ui check` 看 I005 结果。
|
|
43
43
|
|
|
44
44
|
## Diagnose
|
package/standards/ui/03-form.md
CHANGED
|
@@ -56,6 +56,30 @@ date-picker 默认宽度固定,在 grid 布局中需撑满列宽:
|
|
|
56
56
|
|
|
57
57
|
---
|
|
58
58
|
|
|
59
|
+
## 规则:label 与控件间距、单行控件高度必须统一
|
|
60
|
+
|
|
61
|
+
左侧 label 与右侧输入、选择、日期、数字输入、级联、自动完成等单行控件的横向间距统一为:
|
|
62
|
+
|
|
63
|
+
```scss
|
|
64
|
+
--wk-form-label-control-gap: 16px;
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
单行表单控件高度统一为:
|
|
68
|
+
|
|
69
|
+
```scss
|
|
70
|
+
--wk-form-control-height: 26px;
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
textarea 不强制 26px 高度,只继承统一圆角、字体和状态样式。
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## 规则:表单 label 不强制冒号
|
|
78
|
+
|
|
79
|
+
Element Plus 原生控件、picker 类控件和 jh-* 封装控件的 label 后不强制追加 `:`。`@jhlc/jh-ui` 的 `.has-colon .com-text::after` 冒号注入由 wl-skills-ui 统一屏蔽,避免 input / select / picker 之间出现有的带冒号、有的不带冒号。
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
59
83
|
## 布局标准
|
|
60
84
|
|
|
61
85
|
### 搜索区(列表页顶部)
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
html body {
|
|
4
4
|
--wk-form-control-radius: var(--el-border-radius-base, 6px);
|
|
5
|
+
--wk-form-control-height: 26px;
|
|
6
|
+
--wk-form-label-control-gap: 16px;
|
|
7
|
+
--wk-form-label-line-height: 22px;
|
|
5
8
|
}
|
|
6
9
|
|
|
7
10
|
html body .el-form-item--small {
|
|
@@ -14,6 +17,9 @@ html body .is-error.el-form-item--small {
|
|
|
14
17
|
}
|
|
15
18
|
|
|
16
19
|
// ── 全局输入框圆角统一(6px,与搜索区保持一致)──────────────────────────────
|
|
20
|
+
html body .el-form:not(.el-form--label-top) .el-form-item__label {
|
|
21
|
+
padding-right: var(--wk-form-label-control-gap) !important;
|
|
22
|
+
}
|
|
17
23
|
html body .el-input__wrapper,
|
|
18
24
|
html body .el-select__wrapper,
|
|
19
25
|
html body .el-select .el-select__wrapper,
|
|
@@ -21,7 +27,21 @@ html body .el-date-editor.el-input__wrapper,
|
|
|
21
27
|
html body .el-date-editor .el-input__wrapper,
|
|
22
28
|
html body .el-input-number .el-input__wrapper,
|
|
23
29
|
html body .el-cascader .el-input__wrapper,
|
|
24
|
-
html body .el-autocomplete .el-input__wrapper
|
|
30
|
+
html body .el-autocomplete .el-input__wrapper {
|
|
31
|
+
height: var(--wk-form-control-height) !important;
|
|
32
|
+
min-height: var(--wk-form-control-height) !important;
|
|
33
|
+
border-radius: var(--wk-form-control-radius) !important;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
html body .el-input__inner,
|
|
37
|
+
html body .el-select__selected-item,
|
|
38
|
+
html body .el-date-editor .el-input__inner,
|
|
39
|
+
html body .el-input-number .el-input__inner,
|
|
40
|
+
html body .el-cascader .el-input__inner,
|
|
41
|
+
html body .el-autocomplete .el-input__inner {
|
|
42
|
+
height: calc(var(--wk-form-control-height) - 2px) !important;
|
|
43
|
+
line-height: calc(var(--wk-form-control-height) - 2px) !important;
|
|
44
|
+
}
|
|
25
45
|
html body .el-textarea__inner {
|
|
26
46
|
border-radius: var(--wk-form-control-radius) !important;
|
|
27
47
|
}
|
|
@@ -181,14 +181,13 @@
|
|
|
181
181
|
|
|
182
182
|
// ── 状态标签 — 精致小标签(GitHub/Linear label 风格)────────────────────────
|
|
183
183
|
// 实色填充 + 轻柔圆角 + 克制字号
|
|
184
|
-
.ag-cell .el-tag
|
|
185
|
-
.el-table .el-tag {
|
|
184
|
+
.ag-cell .el-tag {
|
|
186
185
|
display: inline-flex !important;
|
|
187
186
|
align-items: center !important;
|
|
188
187
|
justify-content: center !important;
|
|
189
|
-
height:
|
|
188
|
+
height: 20px !important;
|
|
190
189
|
line-height: 1 !important;
|
|
191
|
-
padding: 0
|
|
190
|
+
padding: 0 8px !important;
|
|
192
191
|
font-size: 11px !important;
|
|
193
192
|
font-weight: 600 !important;
|
|
194
193
|
border-radius: 4px !important;
|
|
@@ -197,7 +196,7 @@
|
|
|
197
196
|
flex-shrink: 0;
|
|
198
197
|
|
|
199
198
|
&.el-tag--danger {
|
|
200
|
-
|
|
199
|
+
background: var(--el-color-danger) !important;
|
|
201
200
|
color: #fff !important;
|
|
202
201
|
}
|
|
203
202
|
|
|
@@ -221,12 +220,6 @@
|
|
|
221
220
|
background: var(--el-color-primary) !important;
|
|
222
221
|
color: #fff !important;
|
|
223
222
|
}
|
|
224
|
-
>span,
|
|
225
|
-
.el-tag__content,
|
|
226
|
-
* {
|
|
227
|
-
font-size: inherit !important;
|
|
228
|
-
line-height: inherit !important;
|
|
229
|
-
}
|
|
230
223
|
}
|
|
231
224
|
|
|
232
225
|
// ── 数值型徽标(考核基数/评分等)────────────────────────────────────────────
|
|
@@ -521,13 +514,13 @@ html body .el-form.el-form--label-left .el-form-item__label,
|
|
|
521
514
|
html body .el-form.el-form--label-right .el-form-item__label {
|
|
522
515
|
align-items: baseline !important;
|
|
523
516
|
font-size: 12px !important;
|
|
524
|
-
line-height: 22px !important;
|
|
517
|
+
line-height: var(--wk-form-label-line-height, 22px) !important;
|
|
525
518
|
}
|
|
526
519
|
|
|
527
520
|
html body .el-form.el-form--label-left .el-form-item__label>.com-text,
|
|
528
521
|
html body .el-form.el-form--label-right .el-form-item__label>.com-text {
|
|
529
522
|
font-size: 12px !important;
|
|
530
|
-
line-height: 22px !important;
|
|
523
|
+
line-height: var(--wk-form-label-line-height, 22px) !important;
|
|
531
524
|
}
|
|
532
525
|
|
|
533
526
|
.el-form-item.is-required:not(.is-no-asterisk)>.el-form-item__label::before,
|
|
@@ -537,7 +530,7 @@ html body .el-form.el-form--label-right .el-form-item.is-required:not(.is-no-ast
|
|
|
537
530
|
color: var(--el-color-danger, #f56c6c) !important;
|
|
538
531
|
font-size: 12px !important;
|
|
539
532
|
font-weight: 400 !important;
|
|
540
|
-
line-height: 22px !important;
|
|
533
|
+
line-height: var(--wk-form-label-line-height, 22px) !important;
|
|
541
534
|
display: inline-block !important;
|
|
542
535
|
margin-right: 2px !important;
|
|
543
536
|
vertical-align: baseline !important;
|
|
@@ -552,7 +545,7 @@ html body .el-form.el-form--label-right .el-form-item.is-required:not(.is-no-ast
|
|
|
552
545
|
color: var(--el-color-danger, #f56c6c) !important;
|
|
553
546
|
font-size: 12px !important;
|
|
554
547
|
font-weight: 400 !important;
|
|
555
|
-
line-height: 22px !important;
|
|
548
|
+
line-height: var(--wk-form-label-line-height, 22px) !important;
|
|
556
549
|
display: inline-block !important;
|
|
557
550
|
margin-right: 2px !important;
|
|
558
551
|
vertical-align: baseline !important;
|
|
@@ -579,7 +572,7 @@ html body .el-form.el-form--label-right .el-form-item.is-required:not(.is-no-ast
|
|
|
579
572
|
color: var(--el-color-danger, #f56c6c) !important;
|
|
580
573
|
font-size: 12px !important;
|
|
581
574
|
font-weight: 400 !important;
|
|
582
|
-
line-height: 22px !important;
|
|
575
|
+
line-height: var(--wk-form-label-line-height, 22px) !important;
|
|
583
576
|
display: inline-block !important;
|
|
584
577
|
margin-left: 2px !important;
|
|
585
578
|
vertical-align: baseline !important;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
// `.el-form-item__label` 自身是 `display: inline-flex`。
|
|
11
11
|
// → 直接在 label 上写 ellipsis 不生效,必须落到 `.com-text`。
|
|
12
12
|
// 2. `.has-colon .el-form-item__label .com-text::after` 注入冒号。
|
|
13
|
-
// →
|
|
13
|
+
// → wl-skills-ui 统一隐藏冒号,避免 picker / select / input label 风格不一致。
|
|
14
14
|
// 3. 输入控件 DOM 为 `.el-input > .el-input__inner`(无 `.el-input__wrapper`)。
|
|
15
15
|
// → focus / error 必须命中 `.el-input__inner`,
|
|
16
16
|
// `.el-input__wrapper.is-focus` 这类 EP 2.6+ 规则在这里不生效。
|
|
@@ -44,17 +44,28 @@
|
|
|
44
44
|
vertical-align: middle;
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
// has-colon 模式下,.com-text::after 注入冒号,
|
|
48
|
-
// 给一点 padding 避免冒号被 ellipsis 裁掉
|
|
49
47
|
.has-colon .el-form-item__label > .com-text,
|
|
50
48
|
.has-colon .el-form-item__label .com-text {
|
|
51
|
-
padding-right:
|
|
49
|
+
padding-right: 0;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.has-colon .el-form-item__label>.com-text::after,
|
|
53
|
+
.has-colon .el-form-item__label .com-text::after {
|
|
54
|
+
content: "" !important;
|
|
55
|
+
display: none !important;
|
|
52
56
|
}
|
|
53
57
|
|
|
54
58
|
// 2) Element Plus 2.2.x 输入控件统一圆角(无 .el-input__wrapper)
|
|
55
59
|
.el-input > .el-input__inner,
|
|
56
|
-
.el-
|
|
57
|
-
.el-
|
|
60
|
+
.el-date-editor>.el-input__inner,
|
|
61
|
+
.el-select .el-input>.el-input__inner {
|
|
62
|
+
height: var(--wk-form-control-height, 26px);
|
|
63
|
+
line-height: var(--wk-form-control-height, 26px);
|
|
64
|
+
border-radius: var(--el-border-radius-base);
|
|
65
|
+
transition: box-shadow 0.15s ease, border-color 0.15s ease;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.el-textarea>.el-textarea__inner {
|
|
58
69
|
border-radius: var(--el-border-radius-base);
|
|
59
70
|
transition: box-shadow 0.15s ease, border-color 0.15s ease;
|
|
60
71
|
}
|
|
@@ -85,6 +96,12 @@
|
|
|
85
96
|
// 保留 jh-ui 自身 margin-bottom、has-tip 间距,不覆盖;
|
|
86
97
|
// 仅对齐内部输入控件圆角,避免在 wrapper 内 fallback 成方角。
|
|
87
98
|
.com-input > .el-input > .el-input__inner,
|
|
99
|
+
.com-input>.el-select .el-input>.el-input__inner,
|
|
100
|
+
.com-input>.el-date-editor>.el-input__inner {
|
|
101
|
+
height: var(--wk-form-control-height, 26px);
|
|
102
|
+
line-height: var(--wk-form-control-height, 26px);
|
|
103
|
+
border-radius: var(--el-border-radius-base);
|
|
104
|
+
}
|
|
88
105
|
.com-input > .el-textarea > .el-textarea__inner,
|
|
89
106
|
.com-textarea > .el-textarea > .el-textarea__inner {
|
|
90
107
|
border-radius: var(--el-border-radius-base);
|