@wot-ui/ui 2.0.4 → 2.0.6
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 +27 -0
- package/components/wd-checkbox/index.scss +1 -1
- package/components/wd-circle/index.scss +1 -1
- package/components/wd-config-provider/types.ts +22 -0
- package/components/wd-config-provider/wd-config-provider.vue +2 -2
- package/components/wd-curtain/index.scss +6 -3
- package/components/wd-datetime-picker/index.scss +6 -3
- package/components/wd-dialog/index.scss +9 -7
- package/components/wd-dialog/wd-dialog.vue +10 -14
- package/components/wd-form-item/wd-form-item.vue +5 -0
- package/{styles/iconfont → components/wd-icon}/iconfont.scss +7 -9
- package/components/wd-icon/iconfont.ttf +0 -0
- package/components/wd-icon/index.scss +1 -1
- package/components/wd-input/index.scss +16 -15
- package/components/wd-notify/index.scss +1 -2
- package/components/wd-table-column/wd-table-column.vue +15 -22
- package/components/wd-tag/wd-tag.vue +2 -2
- package/locale/lang/ar-SA.ts +0 -6
- package/locale/lang/de-DE.ts +0 -6
- package/locale/lang/en-US.ts +0 -6
- package/locale/lang/es-ES.ts +0 -6
- package/locale/lang/fr-FR.ts +0 -6
- package/locale/lang/ja-JP.ts +0 -6
- package/locale/lang/ko-KR.ts +0 -6
- package/locale/lang/pt-PT.ts +0 -6
- package/locale/lang/ru-RU.ts +0 -6
- package/locale/lang/th-TH.ts +0 -6
- package/locale/lang/tr-TR.ts +0 -6
- package/locale/lang/ug-CN.ts +0 -6
- package/locale/lang/vi-VN.ts +0 -1
- package/locale/lang/zh-CN.ts +0 -6
- package/locale/lang/zh-HK.ts +0 -1
- package/locale/lang/zh-TW.ts +0 -1
- package/package.json +1 -1
- package/styles/variable.scss +1 -1
- package/web-types.json +1 -1
package/changelog.md
CHANGED
|
@@ -1,6 +1,33 @@
|
|
|
1
1
|
# 更新日志
|
|
2
2
|
|
|
3
3
|
|
|
4
|
+
### [2.0.6](https://github.com/wot-ui/wot-ui/compare/v2.0.5...v2.0.6) (2026-05-12)
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
### ✏️ Documentation | 文档
|
|
8
|
+
|
|
9
|
+
* ✏️ 更新 Sass 版本要求,添加运行时警告处理说明 ([#35](https://github.com/wot-ui/wot-ui/issues/35)) ([268cd0e](https://github.com/wot-ui/wot-ui/commit/268cd0e744707ce29209ef38c4f260114dd92a33))
|
|
10
|
+
* ✏️ 更新深色模式和主题变量引入说明,增加代码示例 ([20aeb4d](https://github.com/wot-ui/wot-ui/commit/20aeb4d71f6993f37f38893b8e26294e5cb58180))
|
|
11
|
+
* ✏️ 新增 v1 迁移到 v2 的文档 ([4cafe19](https://github.com/wot-ui/wot-ui/commit/4cafe19ee3be75f9b08062ee74c6d5feffe7fa51))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### 🐛 Bug Fixes | Bug 修复
|
|
15
|
+
|
|
16
|
+
* 🐛 更新 Dialog 组件关闭逻辑,支持通过点击关闭按钮触发关闭操作并返回相应的 action ([#26](https://github.com/wot-ui/wot-ui/issues/26)) ([0aabf55](https://github.com/wot-ui/wot-ui/commit/0aabf55aa9c8c4e42cf761ea023e0d0117dc1a93))
|
|
17
|
+
* 🐛 简化 cellConfigs 计算逻辑,移除不必要的可见性判断,修复微信小程序编译异常的问题 ([5a64e53](https://github.com/wot-ui/wot-ui/commit/5a64e531e0d40857cd8bb2c637414840d2e8f525)), closes [#34](https://github.com/wot-ui/wot-ui/issues/34)
|
|
18
|
+
* 🐛 将 wd-tag 组件默认插槽内容的承载元素从 text 更改为 view ([#39](https://github.com/wot-ui/wot-ui/issues/39)) ([b72a2be](https://github.com/wot-ui/wot-ui/commit/b72a2bef01c60c8ba8ba14a6b838b660e9f52205)), closes [#25](https://github.com/wot-ui/wot-ui/issues/25)
|
|
19
|
+
* 🐛 修复 ConfigProvider 中 Input 组件变量丢失的问题 ([#37](https://github.com/wot-ui/wot-ui/issues/37)) ([66ddace](https://github.com/wot-ui/wot-ui/commit/66ddace1f5bfd69cd23a8cead460263e2d63ee94)), closes [#36](https://github.com/wot-ui/wot-ui/issues/36)
|
|
20
|
+
* 🐛 修复 Dialog 覆盖 Popup 样式权重较低导致被其他 Popup 覆盖的问题 ([#22](https://github.com/wot-ui/wot-ui/issues/22)) ([9f0fc52](https://github.com/wot-ui/wot-ui/commit/9f0fc52d8d0f9adf3812b08d8a34c45fd3ba6965)), closes [#21](https://github.com/wot-ui/wot-ui/issues/21)
|
|
21
|
+
* 🐛 修复 FormItem label 属性不生效 ([#38](https://github.com/wot-ui/wot-ui/issues/38)) ([fdbcf93](https://github.com/wot-ui/wot-ui/commit/fdbcf935357b9ccbe4e6390551f2eca0f82c1cad)), closes [#30](https://github.com/wot-ui/wot-ui/issues/30)
|
|
22
|
+
* 🐛 修复日期时间选择器在 ios26 微信小程序端区域选择切换时高度坍缩的问题 ([#41](https://github.com/wot-ui/wot-ui/issues/41)) ([e6de48d](https://github.com/wot-ui/wot-ui/commit/e6de48d76c68db7f4faddda0477e2fe0a060c9f5))
|
|
23
|
+
|
|
24
|
+
### [2.0.5](https://github.com/wot-ui/wot-ui/compare/v2.0.4...v2.0.5) (2026-04-27)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
### ✏️ Documentation | 文档
|
|
28
|
+
|
|
29
|
+
* ✏️ 更新深色模式和主题变量引入说明,增加代码示例 ([#19](https://github.com/wot-ui/wot-ui/issues/19)) ([abb7a1b](https://github.com/wot-ui/wot-ui/commit/abb7a1bfdbaab7e2b16b6cde5fd529d043461996))
|
|
30
|
+
|
|
4
31
|
### [2.0.4](https://github.com/wot-ui/wot-ui/compare/v2.0.3...v2.0.4) (2026-04-24)
|
|
5
32
|
|
|
6
33
|
### [2.0.3](https://github.com/wot-ui/wot-ui/compare/v2.0.2...v2.0.3) (2026-04-23)
|
|
@@ -18,7 +18,7 @@ $checkbox-button-font-size: var(--wot-checkbox-button-font-size, $typography-bod
|
|
|
18
18
|
$checkbox-button-line-height: var(--wot-checkbox-button-line-height, $typography-body-line-height-size-main) !default; // 按钮模式行高
|
|
19
19
|
$checkbox-button-bg: var(--wot-checkbox-button-bg, $filled-bottom) !default; // 按钮模式背景颜色
|
|
20
20
|
$checkbox-button-bg-checked: var(--wot-checkbox-button-bg-checked, $filled-oppo) !default; // 按钮模式选中状态背景颜色
|
|
21
|
-
$checkbox-button-icon-size: var(--wot-checkbox-icon-size, $n-10) !default; // 按钮模式图标尺寸
|
|
21
|
+
$checkbox-button-icon-size: var(--wot-checkbox-button-icon-size, $n-10) !default; // 按钮模式图标尺寸
|
|
22
22
|
$checkbox-button-min-width: var(--wot-checkbox-button-min-width, calc(74 * #{$n-1})) !default; // 按钮模式最小宽
|
|
23
23
|
$checkbox-button-max-width: var(--wot-checkbox-button-max-width, calc(148 * #{$n-1})) !default; // 按钮模式最大宽
|
|
24
24
|
$checkbox-button-border-radius: var(--wot-checkbox-button-border-radius, $radius-main) !default; // 按钮圆角大小
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
// 圆环文字颜色
|
|
5
5
|
$circle-text-color: var(--wot-circle-text-color, currentColor) !default;
|
|
6
6
|
// 圆环文字字号
|
|
7
|
-
$circle-text-font-size: var(--wot-circle-text-size, $typography-title-size-large) !default;
|
|
7
|
+
$circle-text-font-size: var(--wot-circle-text-font-size, $typography-title-size-large) !default;
|
|
8
8
|
// 圆环文字行高
|
|
9
9
|
$circle-text-line-height: var(--wot-circle-text-line-height, $typography-title-line-height-size-large) !default;
|
|
10
10
|
|
|
@@ -105,6 +105,7 @@ export type baseThemeVars = {
|
|
|
105
105
|
fontWeightMedium?: string
|
|
106
106
|
fontWeightRegular?: string
|
|
107
107
|
fontWeightSemibold?: string
|
|
108
|
+
fontWeightThin?: string
|
|
108
109
|
fontWeightUltraLight?: string
|
|
109
110
|
grape1?: string
|
|
110
111
|
grape10?: string
|
|
@@ -1138,6 +1139,24 @@ export type inputNumberThemeVars = {
|
|
|
1138
1139
|
inputNumberInputWidth?: string // 输入框宽度
|
|
1139
1140
|
}
|
|
1140
1141
|
|
|
1142
|
+
export type inputThemeVars = {
|
|
1143
|
+
inputBg?: string // 输入框背景色
|
|
1144
|
+
inputCountColor?: string // 输入框字数统计颜色
|
|
1145
|
+
inputCountFontSize?: string // 输入框字数统计字号
|
|
1146
|
+
inputCountLineHeight?: string // 输入框字数统计行高
|
|
1147
|
+
inputCountMargin?: string // 输入框字数统计间距
|
|
1148
|
+
inputDisabledColor?: string // 输入框禁用颜色
|
|
1149
|
+
inputErrorColor?: string // 输入框错误颜色
|
|
1150
|
+
inputIconColor?: string // 输入框图标颜色
|
|
1151
|
+
inputIconFontSize?: string // 输入框图标字号
|
|
1152
|
+
inputIconMargin?: string // 输入框图标间距
|
|
1153
|
+
inputInnerColor?: string // 输入框文字颜色
|
|
1154
|
+
inputInnerFontSize?: string // 输入框内字号
|
|
1155
|
+
inputInnerHeight?: string // 输入框内高度
|
|
1156
|
+
inputInnerPlaceholderColor?: string // 输入框占位符颜色
|
|
1157
|
+
inputPadding?: string // 输入框内边距
|
|
1158
|
+
}
|
|
1159
|
+
|
|
1141
1160
|
export type keyboardThemeVars = {
|
|
1142
1161
|
keyboardBg?: string // 键盘背景色
|
|
1143
1162
|
keyboardCloseColor?: string // 关闭按钮文字颜色
|
|
@@ -1245,6 +1264,7 @@ export type notifyThemeVars = {
|
|
|
1245
1264
|
notifyFloatingMarginHorizontal?: string // floating 变体左右间距
|
|
1246
1265
|
notifyFloatingMarginVertical?: string // floating 变体上下间距
|
|
1247
1266
|
notifyFloatingRadius?: string // floating 变体圆角
|
|
1267
|
+
notifyFloatingShadow?: string // floating 变体阴影
|
|
1248
1268
|
notifyFontSize?: string // 通知文字字号
|
|
1249
1269
|
notifyIconSize?: string // 图标尺寸
|
|
1250
1270
|
notifyIconSpacing?: string // 图标间距
|
|
@@ -1749,6 +1769,7 @@ export type tabbarThemeVars = {
|
|
|
1749
1769
|
tabbarHeight?: string // 高度
|
|
1750
1770
|
tabbarRoundMarginHorizontal?: string // round 变体水平外边距
|
|
1751
1771
|
tabbarRoundRadius?: string // round 变体圆角
|
|
1772
|
+
tabbarRoundShadow?: string // round 变体阴影
|
|
1752
1773
|
tabbarZIndex?: string // 固定定位层级
|
|
1753
1774
|
}
|
|
1754
1775
|
|
|
@@ -2027,6 +2048,7 @@ export type ConfigProviderThemeVars = baseThemeVars &
|
|
|
2027
2048
|
indexAnchorThemeVars &
|
|
2028
2049
|
indexBarThemeVars &
|
|
2029
2050
|
inputNumberThemeVars &
|
|
2051
|
+
inputThemeVars &
|
|
2030
2052
|
keyboardThemeVars &
|
|
2031
2053
|
loadingThemeVars &
|
|
2032
2054
|
loadmoreThemeVars &
|
|
@@ -35,7 +35,7 @@ const themeClass = computed(() => {
|
|
|
35
35
|
return `wot-theme-${props.theme} ${props.customClass}`
|
|
36
36
|
})
|
|
37
37
|
|
|
38
|
-
const
|
|
38
|
+
const themeValue = computed(() => props.theme)
|
|
39
39
|
|
|
40
40
|
const themeStyle = computed(() => {
|
|
41
41
|
if (hooksProvider !== None) {
|
|
@@ -51,7 +51,7 @@ const rootStyle = computed(() => {
|
|
|
51
51
|
})
|
|
52
52
|
|
|
53
53
|
linkChildren({
|
|
54
|
-
theme,
|
|
54
|
+
theme: themeValue,
|
|
55
55
|
themeStyle
|
|
56
56
|
})
|
|
57
57
|
</script>
|
|
@@ -11,10 +11,13 @@ $curtain-content-close-size: var(--wot-curtain-content-close-size, $n-32) !defau
|
|
|
11
11
|
$curtain-content-close-inset: var(--wot-curtain-content-close-inset, $spacing-extra-loose) !default;
|
|
12
12
|
|
|
13
13
|
:deep() {
|
|
14
|
+
.wd-popup.wd-curtain {
|
|
15
|
+
background: transparent;
|
|
16
|
+
overflow-y: visible;
|
|
17
|
+
}
|
|
18
|
+
|
|
14
19
|
@include b(curtain) {
|
|
15
20
|
border-radius: $curtain-content-radius;
|
|
16
|
-
overflow-y: visible !important;
|
|
17
|
-
background: transparent;
|
|
18
21
|
font-size: 0;
|
|
19
22
|
|
|
20
23
|
@include e(content) {
|
|
@@ -93,4 +96,4 @@ $curtain-content-close-inset: var(--wot-curtain-content-close-inset, $spacing-ex
|
|
|
93
96
|
}
|
|
94
97
|
}
|
|
95
98
|
}
|
|
96
|
-
}
|
|
99
|
+
}
|
|
@@ -57,6 +57,7 @@ $datetime-picker-range-separator-height: var(--wot-datetime-picker-range-separat
|
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
@include e(wraper) {
|
|
60
|
+
position: relative;
|
|
60
61
|
padding-bottom: var(--window-bottom);
|
|
61
62
|
}
|
|
62
63
|
|
|
@@ -121,13 +122,15 @@ $datetime-picker-range-separator-height: var(--wot-datetime-picker-range-separat
|
|
|
121
122
|
}
|
|
122
123
|
|
|
123
124
|
@include e(hidden) {
|
|
125
|
+
position: absolute;
|
|
126
|
+
top: 0;
|
|
127
|
+
left: 0;
|
|
128
|
+
right: 0;
|
|
124
129
|
visibility: hidden;
|
|
125
|
-
|
|
126
|
-
height: 0;
|
|
130
|
+
pointer-events: none;
|
|
127
131
|
}
|
|
128
132
|
|
|
129
133
|
@include e(show) {
|
|
130
134
|
visibility: visible;
|
|
131
|
-
height: auto;
|
|
132
135
|
}
|
|
133
136
|
}
|
|
@@ -89,8 +89,10 @@ $dialog-action-text-button-padding: var(--wot-dialog-action-text-button-padding,
|
|
|
89
89
|
$dialog-action-text-border: var(--wot-dialog-action-text-border, $stroke-light) !default;
|
|
90
90
|
|
|
91
91
|
|
|
92
|
-
:deep(
|
|
93
|
-
|
|
92
|
+
:deep() {
|
|
93
|
+
.wd-popup.wd-dialog {
|
|
94
|
+
background: transparent;
|
|
95
|
+
}
|
|
94
96
|
}
|
|
95
97
|
|
|
96
98
|
@include b(dialog) {
|
|
@@ -108,14 +110,14 @@ $dialog-action-text-border: var(--wot-dialog-action-text-border, $stroke-light)
|
|
|
108
110
|
width: 100%;
|
|
109
111
|
height: auto;
|
|
110
112
|
border-radius: $dialog-img-border-radius;
|
|
111
|
-
|
|
113
|
+
|
|
112
114
|
&+.wd-dialog__title {
|
|
113
|
-
margin-top: $dialog-body-element-spacing-large;
|
|
115
|
+
margin-top: $dialog-body-element-spacing-large;
|
|
114
116
|
}
|
|
115
117
|
|
|
116
118
|
&+.wd-dialog__content {
|
|
117
|
-
margin-top: $dialog-body-element-spacing-large;
|
|
118
|
-
|
|
119
|
+
margin-top: $dialog-body-element-spacing-large;
|
|
120
|
+
|
|
119
121
|
.wd-dialog__body.is-prompt & {
|
|
120
122
|
margin-top: $dialog-body-element-spacing;
|
|
121
123
|
}
|
|
@@ -278,4 +280,4 @@ $dialog-action-text-border: var(--wot-dialog-action-text-border, $stroke-light)
|
|
|
278
280
|
color: $dialog-close-icon-color;
|
|
279
281
|
}
|
|
280
282
|
|
|
281
|
-
}
|
|
283
|
+
}
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
:root-portal="rootPortal"
|
|
12
12
|
>
|
|
13
13
|
<view :class="rootClass">
|
|
14
|
-
<wd-icon v-if="dialogState.showClose" custom-class="wd-dialog__close" name="close" @click="toggleModal('
|
|
14
|
+
<wd-icon v-if="dialogState.showClose" custom-class="wd-dialog__close" name="close" @click="toggleModal('close')"></wd-icon>
|
|
15
15
|
<slot name="header" />
|
|
16
16
|
<view :class="bodyClass">
|
|
17
17
|
<slot name="image">
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
</slot>
|
|
54
54
|
</view>
|
|
55
55
|
</view>
|
|
56
|
-
<slot name="actions" :confirm="() => toggleModal('confirm')" :cancel="() => toggleModal('cancel')" :close="() => toggleModal('
|
|
56
|
+
<slot name="actions" :confirm="() => toggleModal('confirm')" :cancel="() => toggleModal('cancel')" :close="() => toggleModal('close')">
|
|
57
57
|
<view
|
|
58
58
|
:class="`wd-dialog__actions ${dialogState.actionLayout === 'vertical' ? 'wd-dialog__actions--vertical' : ''} ${
|
|
59
59
|
dialogState.actionLayout === 'vertical' || showCancelButton || (dialogState.actions && dialogState.actions.length > 1)
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
v-for="(btn, index) in customActions"
|
|
67
67
|
:key="index"
|
|
68
68
|
v-bind="getActionButtonProps(btn)"
|
|
69
|
-
@click="handleAction(btn
|
|
69
|
+
@click="handleAction(btn)"
|
|
70
70
|
@getuserinfo="(e: any) => handleOpenTypeEvent(btn, 'onGetuserinfo', e)"
|
|
71
71
|
@contact="(e: any) => handleOpenTypeEvent(btn, 'onContact', e)"
|
|
72
72
|
@getphonenumber="(e: any) => handleOpenTypeEvent(btn, 'onGetphonenumber', e)"
|
|
@@ -268,7 +268,7 @@ const textareaPropsWithoutModelValue = computed(() => {
|
|
|
268
268
|
/**
|
|
269
269
|
* 自定义 actions 按钮列表(当 theme 为 text 时强制 variant 为 text)
|
|
270
270
|
*/
|
|
271
|
-
const customActions = computed(() => {
|
|
271
|
+
const customActions = computed<DialogAction[]>(() => {
|
|
272
272
|
if (!dialogState.actions || !dialogState.actions.length) return []
|
|
273
273
|
return dialogState.actions.map((action) => {
|
|
274
274
|
if (dialogState.theme === 'text') {
|
|
@@ -403,7 +403,7 @@ watch(
|
|
|
403
403
|
* 点击操作
|
|
404
404
|
* @param action
|
|
405
405
|
*/
|
|
406
|
-
function toggleModal(action: 'confirm' | 'cancel' | 'modal') {
|
|
406
|
+
function toggleModal(action: 'confirm' | 'cancel' | 'modal' | 'close') {
|
|
407
407
|
if (action === 'modal' && !dialogState.closeOnClickModal) {
|
|
408
408
|
return
|
|
409
409
|
}
|
|
@@ -433,9 +433,10 @@ function toggleModal(action: 'confirm' | 'cancel' | 'modal') {
|
|
|
433
433
|
action: action
|
|
434
434
|
})
|
|
435
435
|
break
|
|
436
|
-
|
|
436
|
+
case 'modal':
|
|
437
|
+
case 'close':
|
|
437
438
|
handleCancel({
|
|
438
|
-
action:
|
|
439
|
+
action: action
|
|
439
440
|
})
|
|
440
441
|
break
|
|
441
442
|
}
|
|
@@ -446,20 +447,15 @@ function toggleModal(action: 'confirm' | 'cancel' | 'modal') {
|
|
|
446
447
|
* @param action 按钮配置
|
|
447
448
|
* @param index 索引
|
|
448
449
|
*/
|
|
449
|
-
function handleAction(action:
|
|
450
|
+
function handleAction(action: DialogAction) {
|
|
450
451
|
if (action.disabled || action.loading) return
|
|
451
452
|
|
|
452
|
-
// 如果提供了点击回调
|
|
453
453
|
if (isFunction(action.click)) {
|
|
454
454
|
action.click()
|
|
455
455
|
}
|
|
456
456
|
|
|
457
|
-
// 默认关闭弹窗,除非显式指定不关闭(暂未支持 preventClose 属性,默认关闭)
|
|
458
|
-
// 也可以扩展:如果 click 返回 false,则不关闭
|
|
459
457
|
handleConfirm({
|
|
460
|
-
action: 'confirm',
|
|
461
|
-
// 为了兼容,这里仍返回 confirm 或者是 context?
|
|
462
|
-
// 稍微 hack 一下,actions 场景下通常用户自己在 click 里处理了业务,这里主要是利用 confirm 回调来关闭
|
|
458
|
+
action: 'confirm',
|
|
463
459
|
value: inputVal.value
|
|
464
460
|
})
|
|
465
461
|
}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
:custom-style="customStyle"
|
|
5
5
|
:use-title-slot="!!$slots.title"
|
|
6
6
|
:title="title"
|
|
7
|
+
:label="label"
|
|
7
8
|
:title-width="formItemTitleWidth"
|
|
8
9
|
:prefix-icon="prefixIcon"
|
|
9
10
|
:icon-size="iconSize"
|
|
@@ -29,6 +30,10 @@
|
|
|
29
30
|
<slot name="title"></slot>
|
|
30
31
|
</template>
|
|
31
32
|
|
|
33
|
+
<template #label v-if="$slots.label">
|
|
34
|
+
<slot name="label"></slot>
|
|
35
|
+
</template>
|
|
36
|
+
|
|
32
37
|
<slot>
|
|
33
38
|
<text v-if="showPlaceholder" class="wd-form-item__placeholder">{{ placeholder }}</text>
|
|
34
39
|
<text v-else-if="isDef(value)">{{ value }}</text>
|
|
@@ -1,25 +1,23 @@
|
|
|
1
1
|
@font-face {
|
|
2
2
|
font-family: "wd-icons";
|
|
3
3
|
/* Project id 5024693 */
|
|
4
|
-
src: url('
|
|
4
|
+
src: url('https://at.alicdn.com/t/c/font_5024693_esasb18zrbp.eot?t=1773909649753');
|
|
5
5
|
/* IE9 */
|
|
6
|
-
src: url('
|
|
6
|
+
src: url('https://at.alicdn.com/t/c/font_5024693_esasb18zrbp.eot?t=1773909649753#iefix') format('embedded-opentype'),
|
|
7
7
|
/* IE6-IE8 */
|
|
8
|
-
url('
|
|
9
|
-
url('
|
|
10
|
-
url('
|
|
8
|
+
url('https://at.alicdn.com/t/c/font_5024693_esasb18zrbp.woff?t=1773909649753') format('woff'),
|
|
9
|
+
url('https://at.alicdn.com/t/c/font_5024693_esasb18zrbp.ttf?t=1773909649753') format('truetype'),
|
|
10
|
+
url('https://at.alicdn.com/t/c/font_5024693_esasb18zrbp.svg?t=1773909649753#wd-icons') format('svg');
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
/* #ifdef APP-PLUS || H5 */
|
|
14
|
-
/*
|
|
15
14
|
@font-face {
|
|
16
15
|
font-family: 'wd-icons';
|
|
17
16
|
src:
|
|
18
|
-
url('./
|
|
17
|
+
url('./iconfont.ttf') format('truetype');
|
|
19
18
|
font-weight: normal;
|
|
20
19
|
font-style: normal;
|
|
21
|
-
}
|
|
22
|
-
*/
|
|
20
|
+
}
|
|
23
21
|
/* #endif */
|
|
24
22
|
|
|
25
23
|
.wd-icon-expand:before {
|
|
Binary file
|
|
@@ -1,35 +1,36 @@
|
|
|
1
1
|
@use '../../styles/mixin/mixin.scss'as *;
|
|
2
2
|
@use '../../styles/variable.scss'as *;
|
|
3
|
+
|
|
3
4
|
// 输入框内边距
|
|
4
|
-
$input-padding: var(--wot-input-padding, $padding-loose $padding-loose);
|
|
5
|
+
$input-padding: var(--wot-input-padding, $padding-loose $padding-loose) !default;
|
|
5
6
|
// 输入框背景色
|
|
6
|
-
$input-bg: var(--wot-input-bg, $filled-oppo);
|
|
7
|
+
$input-bg: var(--wot-input-bg, $filled-oppo) !default;
|
|
7
8
|
// 输入框内高度
|
|
8
|
-
$input-inner-height: var(--wot-input-inner-height, $n-20);
|
|
9
|
+
$input-inner-height: var(--wot-input-inner-height, $n-20) !default;
|
|
9
10
|
// 输入框内字号
|
|
10
|
-
$input-inner-font-size: var(--wot-input-inner-font-size, $typography-body-size-main);
|
|
11
|
+
$input-inner-font-size: var(--wot-input-inner-font-size, $typography-body-size-main) !default;
|
|
11
12
|
// 输入框文字颜色
|
|
12
|
-
$input-inner-color: var(--wot-input-inner-color, $text-main);
|
|
13
|
+
$input-inner-color: var(--wot-input-inner-color, $text-main) !default;
|
|
13
14
|
// 输入框占位符颜色
|
|
14
|
-
$input-inner-placeholder-color: var(--wot-input-inner-placeholder-color, $text-placeholder);
|
|
15
|
+
$input-inner-placeholder-color: var(--wot-input-inner-placeholder-color, $text-placeholder) !default;
|
|
15
16
|
// 输入框禁用颜色
|
|
16
|
-
$input-disabled-color: var(--wot-input-disabled-color, $text-disabled);
|
|
17
|
+
$input-disabled-color: var(--wot-input-disabled-color, $text-disabled) !default;
|
|
17
18
|
// 输入框图标颜色
|
|
18
|
-
$input-icon-color: var(--wot-input-icon-color, $icon-secondary);
|
|
19
|
+
$input-icon-color: var(--wot-input-icon-color, $icon-secondary) !default;
|
|
19
20
|
// 输入框图标字号
|
|
20
|
-
$input-icon-font-size: var(--wot-input-icon-font-size, $n-18);
|
|
21
|
+
$input-icon-font-size: var(--wot-input-icon-font-size, $n-18) !default;
|
|
21
22
|
// 输入框图标间距
|
|
22
|
-
$input-icon-margin: var(--wot-input-icon-margin, $spacing-tight);
|
|
23
|
+
$input-icon-margin: var(--wot-input-icon-margin, $spacing-tight) !default;
|
|
23
24
|
// 输入框字数统计间距
|
|
24
|
-
$input-count-margin: var(--wot-input-count-margin, $spacing-extra-loose);
|
|
25
|
+
$input-count-margin: var(--wot-input-count-margin, $spacing-extra-loose) !default;
|
|
25
26
|
// 输入框字数统计颜色
|
|
26
|
-
$input-count-color: var(--wot-input-count-color, $text-auxiliary);
|
|
27
|
+
$input-count-color: var(--wot-input-count-color, $text-auxiliary) !default;
|
|
27
28
|
// 输入框字数统计字号
|
|
28
|
-
$input-count-font-size: var(--wot-input-count-font-size, $typography-body-size-main);
|
|
29
|
+
$input-count-font-size: var(--wot-input-count-font-size, $typography-body-size-main) !default;
|
|
29
30
|
// 输入框字数统计行高
|
|
30
|
-
$input-count-line-height: var(--wot-input-count-line-height, $typography-body-line-height-size-main);
|
|
31
|
+
$input-count-line-height: var(--wot-input-count-line-height, $typography-body-line-height-size-main) !default;
|
|
31
32
|
// 输入框错误颜色
|
|
32
|
-
$input-error-color: var(--wot-input-error-color, $danger-main);
|
|
33
|
+
$input-error-color: var(--wot-input-error-color, $danger-main) !default;
|
|
33
34
|
|
|
34
35
|
@include b(input) {
|
|
35
36
|
position: relative;
|
|
@@ -41,8 +41,7 @@ $notify-floating-margin-horizontal: var(--wot-notify-floating-margin-horizontal,
|
|
|
41
41
|
// floating 变体上下间距
|
|
42
42
|
$notify-floating-margin-vertical: var(--wot-notify-floating-margin-vertical, $spacing-loose) !default;
|
|
43
43
|
// floating 变体阴影
|
|
44
|
-
$notify-floating-shadow: var(--wot-notify-floating-shadow,
|
|
45
|
-
0 12px 48px 16px rgba(39, 43, 59, 0.03), 0 9px 28px 8px rgba(39, 43, 59, 0.05), 0 5px 12px 4px rgba(39, 43, 59, 0.06)) !default;
|
|
44
|
+
$notify-floating-shadow: var(--wot-notify-floating-shadow, 0 12px 48px 16px rgba(39, 43, 59, 0.03), 0 9px 28px 8px rgba(39, 43, 59, 0.05), 0 5px 12px 4px rgba(39, 43, 59, 0.06)) !default;
|
|
46
45
|
|
|
47
46
|
// 通知类型配置映射
|
|
48
47
|
$notify-types: ("primary": ("bg": $notify-primary-bg,
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<view class="wd-table-column">
|
|
3
3
|
<view v-for="config in cellConfigs" :key="config.rowIndex" :class="config.class" :style="config.style" @click="handleRowClick(config.rowIndex)">
|
|
4
|
-
<
|
|
5
|
-
|
|
6
|
-
<text :class="['wd-table__value', { 'is-ellipsis': ellipsis }]" v-else>{{ config.value }}</text>
|
|
7
|
-
</template>
|
|
4
|
+
<slot name="value" v-if="$slots.value" :row="getScope(config.rowIndex)" :index="config.rowIndex"></slot>
|
|
5
|
+
<text :class="['wd-table__value', { 'is-ellipsis': ellipsis }]" v-else>{{ config.value }}</text>
|
|
8
6
|
</view>
|
|
9
7
|
</view>
|
|
10
8
|
</template>
|
|
@@ -92,7 +90,7 @@ const isLastColumn = computed(() => {
|
|
|
92
90
|
* @returns 每行单元格的渲染配置数组
|
|
93
91
|
*/
|
|
94
92
|
const cellConfigs = computed(() => {
|
|
95
|
-
const configs: Array<{ rowIndex: number; value: any; class: any; style: string
|
|
93
|
+
const configs: Array<{ rowIndex: number; value: any; class: any; style: string }> = []
|
|
96
94
|
const data = isDef(table.value) && Array.isArray(table.value.props.data) ? table.value.props.data : []
|
|
97
95
|
if (data.length === 0) return configs
|
|
98
96
|
|
|
@@ -111,7 +109,8 @@ const cellConfigs = computed(() => {
|
|
|
111
109
|
|
|
112
110
|
for (let rowIndex = range.start; rowIndex <= range.end; rowIndex++) {
|
|
113
111
|
const span = getSpanResult(rowIndex)
|
|
114
|
-
const
|
|
112
|
+
const isHidden = span.rowspan === 0 || span.colspan === 0
|
|
113
|
+
if (isHidden) continue
|
|
115
114
|
|
|
116
115
|
const cls = [
|
|
117
116
|
'wd-table__cell',
|
|
@@ -120,27 +119,22 @@ const cellConfigs = computed(() => {
|
|
|
120
119
|
'is-border': borderVal,
|
|
121
120
|
'is-fixed': isFixed,
|
|
122
121
|
'is-shadow': isLast && hasScrollLeft,
|
|
123
|
-
'is-hidden': hidden,
|
|
124
122
|
'is-last': isLastCol
|
|
125
123
|
},
|
|
126
124
|
`is-${align}`
|
|
127
125
|
]
|
|
128
126
|
|
|
129
127
|
const style: CSSProperties = {}
|
|
130
|
-
if (
|
|
131
|
-
style['
|
|
128
|
+
if (span.colspan > 1) {
|
|
129
|
+
style['grid-column'] = `${colStart} / span ${span.colspan}`
|
|
132
130
|
} else {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
style['grid-row'] = `${rowStart} / span ${span.rowspan}`
|
|
141
|
-
} else {
|
|
142
|
-
style['grid-row'] = `${rowStart}`
|
|
143
|
-
}
|
|
131
|
+
style['grid-column'] = `${colStart}`
|
|
132
|
+
}
|
|
133
|
+
const rowStart = rowIndex + 1
|
|
134
|
+
if (span.rowspan > 1) {
|
|
135
|
+
style['grid-row'] = `${rowStart} / span ${span.rowspan}`
|
|
136
|
+
} else {
|
|
137
|
+
style['grid-row'] = `${rowStart}`
|
|
144
138
|
}
|
|
145
139
|
if (isFixed && left) {
|
|
146
140
|
style['left'] = left
|
|
@@ -150,8 +144,7 @@ const cellConfigs = computed(() => {
|
|
|
150
144
|
rowIndex,
|
|
151
145
|
value: data[rowIndex]?.[propKey],
|
|
152
146
|
class: cls,
|
|
153
|
-
style: objToStyle(style)
|
|
154
|
-
visible: !hidden
|
|
147
|
+
style: objToStyle(style)
|
|
155
148
|
})
|
|
156
149
|
}
|
|
157
150
|
return configs
|
|
@@ -22,9 +22,9 @@
|
|
|
22
22
|
<slot name="icon" v-if="$slots.icon || icon">
|
|
23
23
|
<wd-icon :name="icon" custom-class="wd-tag__icon" />
|
|
24
24
|
</slot>
|
|
25
|
-
<
|
|
25
|
+
<view class="wd-tag__text" :style="textStyle" v-if="$slots.default">
|
|
26
26
|
<slot />
|
|
27
|
-
</
|
|
27
|
+
</view>
|
|
28
28
|
<view class="wd-tag__close" v-if="closable" @click.stop="handleClose">
|
|
29
29
|
<wd-icon name="close" custom-class="wd-tag__close-icon"></wd-icon>
|
|
30
30
|
</view>
|
package/locale/lang/ar-SA.ts
CHANGED
|
@@ -68,12 +68,6 @@ export default {
|
|
|
68
68
|
confirm: 'تأكيد',
|
|
69
69
|
cancel: 'إلغاء'
|
|
70
70
|
},
|
|
71
|
-
messageBox: {
|
|
72
|
-
inputPlaceholder: 'الرجاء إدخال المعلومات',
|
|
73
|
-
confirm: 'تأكيد',
|
|
74
|
-
cancel: 'إلغاء',
|
|
75
|
-
inputNoValidate: 'الرجاء التأكد من إدخال المعلومات الصحيحة'
|
|
76
|
-
},
|
|
77
71
|
dialog: {
|
|
78
72
|
inputPlaceholder: 'الرجاء إدخال المعلومات',
|
|
79
73
|
confirm: 'تأكيد',
|
package/locale/lang/de-DE.ts
CHANGED
|
@@ -68,12 +68,6 @@ export default {
|
|
|
68
68
|
confirm: 'OK',
|
|
69
69
|
cancel: 'Stornieren'
|
|
70
70
|
},
|
|
71
|
-
messageBox: {
|
|
72
|
-
inputPlaceholder: 'Bitte geben Sie Informationen ein',
|
|
73
|
-
confirm: 'OK',
|
|
74
|
-
cancel: 'Stornieren',
|
|
75
|
-
inputNoValidate: 'Bitte geben Sie gültige Informationen ein'
|
|
76
|
-
},
|
|
77
71
|
dialog: {
|
|
78
72
|
inputPlaceholder: 'Bitte geben Sie Informationen ein',
|
|
79
73
|
confirm: 'OK',
|
package/locale/lang/en-US.ts
CHANGED
|
@@ -68,12 +68,6 @@ export default {
|
|
|
68
68
|
confirm: 'OK',
|
|
69
69
|
cancel: 'Cancel'
|
|
70
70
|
},
|
|
71
|
-
messageBox: {
|
|
72
|
-
inputPlaceholder: 'Please input information',
|
|
73
|
-
confirm: 'OK',
|
|
74
|
-
cancel: 'Cancel',
|
|
75
|
-
inputNoValidate: 'Please ensure you input correct information'
|
|
76
|
-
},
|
|
77
71
|
dialog: {
|
|
78
72
|
inputPlaceholder: 'Please input information',
|
|
79
73
|
confirm: 'OK',
|
package/locale/lang/es-ES.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: 'Error al Cargar',
|
|
65
65
|
retry: 'Reintentar'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: 'Por favor ingrese información',
|
|
69
|
-
confirm: 'Confirmar',
|
|
70
|
-
cancel: 'Cancelar',
|
|
71
|
-
inputNoValidate: 'Por favor ingrese información válida'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: 'Por favor ingrese información',
|
|
75
69
|
confirm: 'Confirmar',
|
package/locale/lang/fr-FR.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: 'Échec du chargement',
|
|
65
65
|
retry: 'Réessayer'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: 'Veuillez entrer des informations',
|
|
69
|
-
confirm: 'Confirmer',
|
|
70
|
-
cancel: 'Annuler',
|
|
71
|
-
inputNoValidate: 'Veuillez entrer des informations valides'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: 'Veuillez entrer des informations',
|
|
75
69
|
confirm: 'Confirmer',
|
package/locale/lang/ja-JP.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: '読み込みエラー',
|
|
65
65
|
retry: '再試行'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: '入力してください',
|
|
69
|
-
confirm: '確認',
|
|
70
|
-
cancel: 'キャンセル',
|
|
71
|
-
inputNoValidate: '無効なデータが入力されました'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: '入力してください',
|
|
75
69
|
confirm: '確認',
|
package/locale/lang/ko-KR.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: '로딩 오류',
|
|
65
65
|
retry: '재시도'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: '정보를 입력해주세요',
|
|
69
|
-
confirm: '확인',
|
|
70
|
-
cancel: '취소',
|
|
71
|
-
inputNoValidate: '유효한 정보를 입력해주세요'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: '정보를 입력해주세요',
|
|
75
69
|
confirm: '확인',
|
package/locale/lang/pt-PT.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: 'Falha ao carregar',
|
|
65
65
|
retry: 'Clique para tentar novamente'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: 'Por favor insira',
|
|
69
|
-
confirm: 'Confirmar',
|
|
70
|
-
cancel: 'Cancelar',
|
|
71
|
-
inputNoValidate: 'Dados inseridos inválidos'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: 'Por favor insira',
|
|
75
69
|
confirm: 'Confirmar',
|
package/locale/lang/ru-RU.ts
CHANGED
|
@@ -64,12 +64,6 @@ export default {
|
|
|
64
64
|
error: 'Ошибка загрузки',
|
|
65
65
|
retry: 'Повторить'
|
|
66
66
|
},
|
|
67
|
-
messageBox: {
|
|
68
|
-
inputPlaceholder: 'Введите, пожалуйста',
|
|
69
|
-
confirm: 'Ок',
|
|
70
|
-
cancel: 'Отмена',
|
|
71
|
-
inputNoValidate: 'Неверные данные'
|
|
72
|
-
},
|
|
73
67
|
dialog: {
|
|
74
68
|
inputPlaceholder: 'Введите, пожалуйста',
|
|
75
69
|
confirm: 'Ок',
|