vdesign-ui 0.2.1 → 0.2.3

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.
Files changed (107) hide show
  1. package/dist/components/actionbar/style.less +8 -12
  2. package/dist/components/actionbar-cell/index.js +7 -0
  3. package/dist/components/{actionbar/actionbar-cell → actionbar-cell}/index.vue +4 -0
  4. package/dist/components/{actions-cell/actions → actions}/index.vue +6 -6
  5. package/dist/components/{actions-cell/actions → actions}/style.less +38 -41
  6. package/dist/components/activityviews/index.vue +76 -28
  7. package/dist/components/activityviews/style.less +59 -45
  8. package/dist/components/badge/style.less +22 -34
  9. package/dist/components/button/index.vue +4 -0
  10. package/dist/components/button/style.less +82 -87
  11. package/dist/components/calendar/index.vue +1 -1
  12. package/dist/components/calendar/style.less +24 -53
  13. package/dist/components/checkbox/index.vue +5 -1
  14. package/dist/components/checkbox/style.less +30 -32
  15. package/dist/components/checkbox-group/index.js +7 -0
  16. package/dist/components/{checkbox/checkbox-group → checkbox-group}/index.vue +1 -2
  17. package/dist/components/common/state/index.vue +1 -48
  18. package/dist/components/common/state/style.less +48 -0
  19. package/dist/components/data-list/style.less +81 -82
  20. package/dist/components/datetime-picker/style.less +12 -12
  21. package/dist/components/dialog/index.vue +9 -1
  22. package/dist/components/dialog/style.less +27 -31
  23. package/dist/components/divider/style.less +1 -1
  24. package/dist/components/dropdown/index.vue +6 -1
  25. package/dist/components/dropdown/style.less +117 -125
  26. package/dist/components/empty/index.vue +35 -20
  27. package/dist/components/empty/style.less +33 -36
  28. package/dist/components/footer/style.less +6 -7
  29. package/dist/components/footnav/index.vue +1 -1
  30. package/dist/components/footnav/style.less +5 -5
  31. package/dist/components/{footnav/footnav-item → footnav-item}/index.vue +7 -1
  32. package/dist/components/{footnav/footnav-item → footnav-item}/style.less +2 -2
  33. package/dist/components/headnav/index.vue +5 -1
  34. package/dist/components/headnav/style.less +54 -58
  35. package/dist/components/icon/style.less +4 -4
  36. package/dist/components/input/index.vue +4 -0
  37. package/dist/components/input/style.less +88 -101
  38. package/dist/components/list/index.vue +5 -0
  39. package/dist/components/list/style.less +45 -52
  40. package/dist/components/loading/style.less +25 -27
  41. package/dist/components/mixins/languageMixin.js +7 -4
  42. package/dist/components/mixins/outlineConfigPlugin.js +1 -1
  43. package/dist/components/mixins/themeMixin.js +29 -15
  44. package/dist/components/noticebar/index.vue +7 -1
  45. package/dist/components/noticebar/style.less +125 -129
  46. package/dist/components/overlay/index.vue +34 -11
  47. package/dist/components/pagebreak/style.less +18 -19
  48. package/dist/components/popover/index.vue +2 -1
  49. package/dist/components/popover/style.less +39 -39
  50. package/dist/components/popup/index.js +7 -0
  51. package/dist/components/popup/index.vue +243 -0
  52. package/dist/components/radio/index.js +1 -1
  53. package/dist/components/radio/index.vue +1 -1
  54. package/dist/components/radio/style.less +35 -43
  55. package/dist/components/radio-group/index.js +6 -0
  56. package/dist/components/{radio/radio-group → radio-group}/index.vue +1 -1
  57. package/dist/components/result/completed-dark.png +0 -0
  58. package/dist/components/result/completed.png +0 -0
  59. package/dist/components/result/error-dark.png +0 -0
  60. package/dist/components/result/error.png +0 -0
  61. package/dist/components/result/index.vue +1 -2
  62. package/dist/components/result/style.less +22 -20
  63. package/dist/components/result/wait-dark.png +0 -0
  64. package/dist/components/result/wait.png +0 -0
  65. package/dist/components/{input/search → search}/index.vue +4 -0
  66. package/dist/components/selector/index.vue +4 -0
  67. package/dist/components/selector/style.less +96 -100
  68. package/dist/components/skeleton/index.vue +156 -92
  69. package/dist/components/skeleton/style.less +112 -107
  70. package/dist/components/slider/index.vue +1 -1
  71. package/dist/components/slider/style.less +41 -37
  72. package/dist/components/step/style.less +3 -4
  73. package/dist/components/step-item/index.vue +12 -3
  74. package/dist/components/step-item/style.less +61 -60
  75. package/dist/components/{input/stepper → stepper}/index.vue +5 -1
  76. package/dist/components/switch/style.less +8 -8
  77. package/dist/components/tab/index.js +7 -0
  78. package/dist/components/tabs/index.vue +4 -0
  79. package/dist/components/tabs/style.less +97 -105
  80. package/dist/components/tag/style.less +35 -35
  81. package/dist/components/title/index.vue +4 -0
  82. package/dist/components/title/style.less +164 -170
  83. package/dist/components/toast/index.js +9 -3
  84. package/dist/components/toast/style.less +8 -8
  85. package/dist/components/upload/index.vue +4 -0
  86. package/dist/components/upload/style.less +22 -31
  87. package/dist/components/utils/env.js +2 -0
  88. package/dist/token.css +1278 -1278
  89. package/dist/vdesign-ui.common.js +1315 -1076
  90. package/dist/vdesign-ui.css +1 -1
  91. package/dist/vdesign-ui.umd.js +1315 -1076
  92. package/dist/vdesign-ui.umd.min.js +3 -3
  93. package/package.json +1 -1
  94. package/dist/components/checkbox/checkbox-group/index.js +0 -8
  95. package/dist/components/radio/assist.js +0 -34
  96. package/dist/components/radio/style.css +0 -213
  97. package/dist/img/completed-dark.4183a8a8.png +0 -0
  98. package/dist/img/error-dark.b80857da.png +0 -0
  99. package/dist/img/wait-dark.6aa28731.png +0 -0
  100. /package/dist/components/{actions-cell/actions → actions}/index.js +0 -0
  101. /package/dist/components/{footnav/footnav-item → footnav-item}/index.js +0 -0
  102. /package/dist/components/{input/password → password}/index.js +0 -0
  103. /package/dist/components/{input/password → password}/index.vue +0 -0
  104. /package/dist/components/{input/search → search}/index.js +0 -0
  105. /package/dist/components/{input/stepper → stepper}/index.js +0 -0
  106. /package/dist/components/{tabs/tab → tab}/index.vue +0 -0
  107. /package/dist/components/{checkbox → utils}/assist.js +0 -0
@@ -2,67 +2,70 @@
2
2
 
3
3
  .@{silder-prefix-cls} {
4
4
 
5
- &__wrap{
5
+ &__wrap {
6
6
  position: relative;
7
7
  margin: 7px 0;
8
- height: calc(var(--height-slider-track) * 1px);
9
- background-color: var(--color-slider-track-default);
10
- border-radius: calc(var(--radius-slider-track) * 1px);
11
- &--demonstration{
12
- height: calc(var(--height-slider-mark_track) * 1px);
13
- border-radius: calc(var(--radius-slider-mark_track) * 1px);
8
+ height: var(--height-slider-track);
9
+ background-color: var(--color-slider-track-default);
10
+ border-radius: var(--radius-slider-track);
11
+
12
+ &--demonstration {
13
+ height: var(--height-slider-mark_track);
14
+ border-radius: var(--radius-slider-mark_track);
14
15
  }
15
16
  }
16
- &__bar{
17
+
18
+ &__bar {
17
19
  position: absolute;
18
20
  top: 0;
19
- height: calc(var(--height-slider-track) * 1px);
21
+ height: var(--height-slider-track);
20
22
  background-color: var(--color-slider-track-focus);
21
- border-radius: calc(var(--radius-slider-track) * 1px);
22
-
23
+ border-radius: var(--radius-slider-track);
23
24
 
24
- &--demonstration{
25
- height: calc(var(--height-slider-mark_track) * 1px);
25
+ &--demonstration {
26
+ height: var(--height-slider-mark_track);
26
27
  }
27
28
  }
28
- &__button{
29
+
30
+ &__button {
29
31
  position: absolute;
30
32
  left: 0;
31
33
  top: 50%;
32
34
  transform: translate3d(-50%, -50%, 0);
33
35
  cursor: grab;
34
36
  border-radius: 50%;
35
- width: calc(var(--width-slider-handle) * 1px);
36
- height: calc(var(--width-slider-handle) * 1px);
37
+ width: var(--width-slider-handle);
38
+ height: var(--width-slider-handle);
37
39
  background-color: var(--color-slider-handle-bg);
38
- border: calc(var(--width-slider-handle_border) * 1px) solid var(--color-slider-handle_border-default);
40
+ border: var(--width-slider-handle_border) solid var(--color-slider-handle_border-default);
39
41
 
40
- &--demonstration{
41
- width: calc(var(--width-slider-mark_handle) * 1px);
42
- height: calc(var(--height-slider-mark_handle) * 1px);
43
- border-radius: calc(var(--radius-slider-mark_handle) * 1px);
44
- border: calc(var(--width-slider-mark_handle_border) * 1px) solid var(--color-slider-handle_border-default);
42
+ &--demonstration {
43
+ width: var(--width-slider-mark_handle);
44
+ height: var(--height-slider-mark_handle);
45
+ border-radius: var(--radius-slider-mark_handle);
46
+ border: var(--width-slider-mark_handle_border) solid var(--color-slider-handle_border-default);
45
47
  }
46
48
 
47
- &--active{
49
+ &--active {
48
50
  border-color: var(--color-slider-handle_border-focus);
49
51
  }
50
52
  }
51
53
 
52
- &__marks{
54
+ &__marks {
53
55
  display: flex;
54
56
  justify-content: space-between;
55
- margin-block-start: calc(var(--spacing-slider-margin_bottom) * 1px);
56
- font-size: calc(var(--en-single-f-a-r-fontSize) * 1px);
57
+ margin-top: var(--spacing-slider-margin_bottom);
58
+ font-size: var(--en-single-f-a-r-fontSize);
57
59
  font-weight: var(--en-single-f-a-r-fontWeight);
58
60
  color: var(--color-slider-mark-text);
59
61
 
60
- &--top{
61
- margin-block-start: 0;
62
- margin-block-end: calc(var(--spacing-slider-margin_bottom) * 1px);
62
+ &--top {
63
+ margin-top: 0;
64
+ margin-bottom: var(--spacing-slider-margin_bottom);
63
65
  }
64
- &--active{
65
- font-size: calc(var(--en-single-f-d-s-fontSize) * 1px);
66
+
67
+ &--active {
68
+ font-size: var(--en-single-f-d-s-fontSize);
66
69
  font-weight: var(--en-single-f-d-s-fontWeight);
67
70
  }
68
71
 
@@ -71,25 +74,26 @@
71
74
  }
72
75
  }
73
76
 
74
- &__dots{
77
+ &__dots {
75
78
  position: absolute;
76
79
  width: 1px;
77
80
  height: 3px;
78
81
  border-radius: 4px;
79
82
  background-color: #fff;
80
83
  top: 50%;
81
- transform: translate(-50%,-50%);
82
- &--active{
84
+ transform: translate(-50%, -50%);
85
+
86
+ &--active {
83
87
  height: 5px;
84
88
  }
85
89
  }
86
90
 
87
- &__tips{
91
+ &__tips {
88
92
  position: absolute;
89
93
  left: 50%;
90
- top: calc((var(--height-slider-mark_handle) + 8) * -1px );
94
+ top: calc(-1 * var(--height-slider-mark_handle) - 8px);
91
95
  transform: translateX(-50%);
92
- font-size: calc(var(--en-single-f-d-s-fontSize) * 1px);
96
+ font-size: var(--en-single-f-d-s-fontSize);
93
97
  font-weight: var(--en-single-f-d-s-fontWeight);
94
98
  color: var(--color-slider-mark-text-focus);
95
99
  }
@@ -38,13 +38,12 @@
38
38
  display: flex;
39
39
  flex-direction: column;
40
40
  flex-wrap: nowrap;
41
- padding-block-start: calc(var(--spacing-steps-vertical-padding_x) * 1px);
42
- padding-block-end: calc(var(--spacing-steps-vertical-padding_x) * 1px);
41
+ padding-block-start: var(--spacing-steps-vertical-padding_x);
42
+ padding-block-end: var(--spacing-steps-vertical-padding_x);
43
43
 
44
44
  .vd-step-item {
45
45
 
46
46
  &:last-child {
47
-
48
47
  .vd-step-u-line {
49
48
  display: none;
50
49
  }
@@ -56,4 +55,4 @@
56
55
  display: flex;
57
56
  justify-content: space-between;
58
57
  }
59
- }
58
+ }
@@ -29,8 +29,14 @@
29
29
  </template>
30
30
 
31
31
  <script>
32
+ import VdIcon from '../icon';
33
+ import { inBrowser } from '../utils/env';
34
+
32
35
  export default {
33
36
  name: 'vd-step-item',
37
+ components: {
38
+ VdIcon
39
+ },
34
40
  props: {
35
41
  // 索引名称
36
42
  name: {
@@ -78,9 +84,11 @@ export default {
78
84
  }
79
85
  },
80
86
  mounted() {
81
- const theme = document.querySelector('html').getAttribute('theme')
82
- this.currentTheme = theme ? theme : this.currentTheme
83
- this.observeThemeChange()
87
+ if (inBrowser) {
88
+ const theme = document.querySelector('html').getAttribute('theme');
89
+ this.currentTheme = theme || this.currentTheme;
90
+ this.observeThemeChange();
91
+ }
84
92
  },
85
93
  watch: {
86
94
  // 监听父组件参数
@@ -94,6 +102,7 @@ export default {
94
102
  },
95
103
  methods: {
96
104
  observeThemeChange() {
105
+ if (!inBrowser) return; // SSR 环境中不执行
97
106
  const observer = new MutationObserver(mutations => {
98
107
  mutations.forEach(mutation => {
99
108
  if (mutation.type === 'attributes' && mutation.attributeName === 'theme') {
@@ -8,7 +8,7 @@
8
8
  width: 100%;
9
9
  display: flex;
10
10
  justify-content: center;
11
- padding-block-start: calc((var(--spacing-steps-horizontal-padding_x) + var(--icon-steps-size) + var(--spacing-steps-horizontal_icon-margin_bottom)) * 1px);
11
+ padding-block-start: calc(var(--spacing-steps-horizontal-padding_x) + var(--icon-steps-size) + var(--spacing-steps-horizontal_icon-margin_bottom));
12
12
 
13
13
  .vd-step-u-dot {
14
14
  position: absolute;
@@ -19,19 +19,19 @@
19
19
  justify-content: center;
20
20
  align-items: center;
21
21
  color: inherit;
22
- width: calc(var(--icon-steps-size) * 1px);
23
- height: calc(var(--icon-steps-size) * 1px);
24
- inset-block-start: calc(var(--spacing-steps-horizontal-padding_x) * 1px);
22
+ width: var(--icon-steps-size);
23
+ height: var(--icon-steps-size);
24
+ inset-block-start: var(--spacing-steps-horizontal-padding_x);
25
25
 
26
26
  .vd-iconfont {
27
27
  color: inherit;
28
- font-size: calc(var(--icon-steps-size) * 1px);
28
+ font-size: var(--icon-steps-size);
29
29
  }
30
30
 
31
31
  &::before {
32
32
  content: "";
33
- width: calc(var(--icon-steps-size) * 0.5px);
34
- height: calc(var(--icon-steps-size) * 0.5px);
33
+ width: calc(var(--icon-steps-size) * 0.5);
34
+ height: calc(var(--icon-steps-size) * 0.5);
35
35
  border-radius: 999em;
36
36
  overflow: hidden;
37
37
  background-color: var(--bg-color-1);
@@ -42,17 +42,17 @@
42
42
 
43
43
  .vd-step-u-line {
44
44
  position: absolute;
45
- inset-block-start: calc((var(--spacing-steps-horizontal-padding_x) + var(--icon-steps-size)/2) * 1px);
45
+ inset-block-start: calc(var(--spacing-steps-horizontal-padding_x) + var(--icon-steps-size)/2);
46
46
  inset-inline-end: 0;
47
47
  z-index: 1;
48
48
  width: 100%;
49
- height: calc(var(--height-steps-border-default) * 1px);
49
+ height: var(--height-steps-border-default);
50
50
  background: linear-gradient(to left,
51
51
  transparent 0%,
52
52
  transparent 50%,
53
53
  var(--color-steps-border-default) 50%,
54
54
  var(--color-steps-border-default) 100%);
55
- background-size: 5px calc(var(--height-steps-border-default) * 1px);
55
+ background-size: 5px var(--height-steps-border-default);
56
56
  background-repeat: repeat-x;
57
57
  }
58
58
 
@@ -62,9 +62,9 @@
62
62
  text-align: center;
63
63
  // not_started
64
64
  color: var(--color-steps-text-not_started);
65
- font-size: calc(var(--en-multi-f-c-r-fontSize) * 1px);
65
+ font-size: var(--en-multi-f-c-r-fontSize);
66
66
  font-weight: var(--en-multi-f-c-r-fontWeight);
67
- line-height: calc(var(--en-multi-f-c-r-lineHeight) * 1px);
67
+ line-height: var(--en-multi-f-c-r-lineHeight);
68
68
 
69
69
  &__title {
70
70
  overflow: hidden;
@@ -80,9 +80,9 @@
80
80
  -webkit-line-clamp: 3;
81
81
  // description_text
82
82
  color: var(--color-steps-description_text);
83
- font-size: calc(var(--en-multi-f-b-r-fontSize) * 1px);
83
+ font-size: var(--en-multi-f-b-r-fontSize);
84
84
  font-weight: var(--en-multi-f-b-r-fontWeight);
85
- line-height: calc(var(--en-multi-f-b-r-lineHeight) * 1px);
85
+ line-height: var(--en-multi-f-b-r-lineHeight);
86
86
  }
87
87
  }
88
88
 
@@ -90,9 +90,9 @@
90
90
 
91
91
  .vd-step-u-text {
92
92
  color: var(--color-steps-text-complete);
93
- font-size: calc(var(--en-multi-f-c-r-fontSize) * 1px);
93
+ font-size: var(--en-multi-f-c-r-fontSize);
94
94
  font-weight: var(--en-multi-f-c-r-fontWeight);
95
- line-height: calc(var(--en-multi-f-c-r-lineHeight) * 1px);
95
+ line-height: var(--en-multi-f-c-r-lineHeight);
96
96
  }
97
97
 
98
98
  .vd-step-u-dot {
@@ -102,7 +102,7 @@
102
102
  }
103
103
 
104
104
  .vd-step-u-line {
105
- height: calc(var(--height-steps-border-hover) * 1px);
105
+ height: var(--height-steps-border-hover);
106
106
  background: var(--color-steps-border-hover);
107
107
  }
108
108
  }
@@ -115,9 +115,9 @@
115
115
 
116
116
  .vd-step-u-text {
117
117
  color: var(--color-steps-text-afoot);
118
- font-size: calc(var(--en-multi-f-c-s-fontSize) * 1px);
118
+ font-size: var(--en-multi-f-c-s-fontSize);
119
119
  font-weight: var(--en-multi-f-c-s-fontWeight);
120
- line-height: calc(var(--en-multi-f-c-s-lineHeight) * 1px);
120
+ line-height: var(--en-multi-f-c-s-lineHeight);
121
121
  }
122
122
 
123
123
  .vd-step-u-line::after {
@@ -126,7 +126,7 @@
126
126
  inset-block-start: 0;
127
127
  inset-inline-start: 0;
128
128
  width: 50%;
129
- height: calc(var(--height-steps-border-hover) * 1px);
129
+ height: var(--height-steps-border-hover);
130
130
  background: var(--color-steps-border-hover);
131
131
  }
132
132
  }
@@ -139,9 +139,9 @@
139
139
 
140
140
  .vd-step-u-text {
141
141
  color: var(--color-steps-text-warning);
142
- font-size: calc(var(--en-multi-f-c-s-fontSize) * 1px);
142
+ font-size: var(--en-multi-f-c-s-fontSize);
143
143
  font-weight: var(--en-multi-f-c-s-fontWeight);
144
- line-height: calc(var(--en-multi-f-c-s-lineHeight) * 1px);
144
+ line-height: var(--en-multi-f-c-s-lineHeight);
145
145
  }
146
146
 
147
147
  .vd-step-u-line::after {
@@ -150,7 +150,7 @@
150
150
  inset-block-start: 0;
151
151
  inset-inline-start: 0;
152
152
  width: 50%;
153
- height: calc(var(--height-steps-border-hover) * 1px);
153
+ height: var(--height-steps-border-hover);
154
154
  background: var(--color-steps-border-hover);
155
155
  }
156
156
  }
@@ -159,33 +159,33 @@
159
159
  // vertical
160
160
  &.vd-step-vertical {
161
161
  width: 100%;
162
- padding-inline-start: calc((var(--spacing-steps-vertical-padding_y) + var(--icon-steps-size) + var(--spacing-steps-vertical_icon-margin_right)) * 1px);
162
+ padding-inline-start: calc(var(--spacing-steps-vertical-padding_y) + var(--icon-steps-size) + var(--spacing-steps-vertical_icon-margin_right));
163
163
 
164
164
  &:not(:last-child) {
165
- padding-block-end: calc(var(--spacing-steps-vertical_description_text-margin_bottom) * 1px);
165
+ padding-block-end: var(--spacing-steps-vertical_description_text-margin_bottom);
166
166
  }
167
167
 
168
168
  .vd-step-u-dot {
169
169
  position: absolute;
170
170
  inset-block-start: 0;
171
- inset-inline-start: calc(var(--spacing-steps-vertical-padding_y) * 1px);
171
+ inset-inline-start: var(--spacing-steps-vertical-padding_y);
172
172
  z-index: 2;
173
173
  display: flex;
174
174
  justify-content: center;
175
175
  align-items: center;
176
176
  color: inherit;
177
- width: calc(var(--icon-steps-size) * 1px);
178
- height: calc(var(--icon-steps-size) * 1px);
177
+ width: var(--icon-steps-size);
178
+ height: var(--icon-steps-size);
179
179
 
180
180
  .vd-iconfont {
181
181
  color: inherit;
182
- font-size: calc(var(--icon-steps-size) * 1px);
182
+ font-size: var(--icon-steps-size);
183
183
  }
184
184
 
185
185
  &::before {
186
186
  content: "";
187
- width: calc(var(--icon-steps-size) * 0.5px);
188
- height: calc(var(--icon-steps-size) * 0.5px);
187
+ width: calc(var(--icon-steps-size) * 0.5);
188
+ height: calc(var(--icon-steps-size) * 0.5);
189
189
  border-radius: 999em;
190
190
  overflow: hidden;
191
191
  background-color: var(--bg-color-1);
@@ -197,9 +197,9 @@
197
197
  .vd-step-u-line {
198
198
  position: absolute;
199
199
  z-index: 1;
200
- inset-block-start: calc((var(--icon-steps-size)/2) * 1px);
201
- inset-inline-start: calc((var(--spacing-steps-vertical-padding_y) + var(--icon-steps-size)/2) * 1px);
202
- width: calc(var(--height-steps-border-default) * 1px);
200
+ inset-block-start: calc(var(--icon-steps-size)/2);
201
+ inset-inline-start: calc(var(--spacing-steps-vertical-padding_y) + var(--icon-steps-size)/2);
202
+ width: var(--height-steps-border-default);
203
203
  height: 100%;
204
204
  background: linear-gradient(to bottom,
205
205
  transparent 0%,
@@ -216,9 +216,9 @@
216
216
  text-align: start;
217
217
  // not_started
218
218
  color: var(--color-steps-text-not_started);
219
- font-size: calc(var(--en-multi-f-c-r-fontSize) * 1px);
219
+ font-size: var(--en-multi-f-c-r-fontSize);
220
220
  font-weight: var(--en-multi-f-c-r-fontWeight);
221
- line-height: calc(var(--en-multi-f-c-r-lineHeight) * 1px);
221
+ line-height: var(--en-multi-f-c-r-lineHeight);
222
222
 
223
223
  &__title {
224
224
  overflow: hidden;
@@ -234,19 +234,20 @@
234
234
  -webkit-line-clamp: 3;
235
235
  // description_text
236
236
  color: var(--color-steps-description_text);
237
- font-size: calc(var(--en-multi-f-b-r-fontSize) * 1px);
237
+ font-size: var(--en-multi-f-b-r-fontSize);
238
238
  font-weight: var(--en-multi-f-b-r-fontWeight);
239
- line-height: calc(var(--en-multi-f-b-r-lineHeight) * 1px);
239
+ line-height: var(--en-multi-f-b-r-lineHeight);
240
240
  }
241
241
  }
242
242
 
243
+
243
244
  &.vd-step-active {
244
245
 
245
246
  .vd-step-u-text {
246
247
  color: var(--color-steps-text-complete);
247
- font-size: calc(var(--en-multi-f-c-r-fontSize) * 1px);
248
+ font-size: var(--en-multi-f-c-r-fontSize);
248
249
  font-weight: var(--en-multi-f-c-r-fontWeight);
249
- line-height: calc(var(--en-multi-f-c-r-lineHeight) * 1px);
250
+ line-height: var(--en-multi-f-c-r-lineHeight);
250
251
  }
251
252
 
252
253
  .vd-step-u-dot {
@@ -262,29 +263,29 @@
262
263
  inset-block-start: 0;
263
264
  inset-inline-start: 0;
264
265
  height: 100%;
265
- width: calc(var(--height-steps-border-default) * 1px);
266
+ width: var(--height-steps-border-default);
266
267
  background: var(--color-steps-border-hover);
267
268
  }
268
269
 
269
270
  // 复杂 css 条件,但:has兼容性不够
270
271
  &:not(:has(+ :is(.vd-step-active, .vd-step-afoot, .vd-step-warning))) {
271
272
  .vd-step-u-line::after {
272
- height: 50%;
273
+ height: 50% !important;
273
274
  }
274
275
  }
275
276
  }
276
277
 
277
278
 
278
- &.vd-step-afoot {
279
- .u-line::after {
279
+ &.vd-step-warning {
280
+ .vd-step-u-line::after {
280
281
  height: 100%;
281
282
  }
282
283
 
283
284
  .vd-step-u-text {
284
- color: var(--color-steps-text-afoot);
285
- font-size: calc(var(--en-multi-f-c-s-fontSize) * 1px);
285
+ color: var(--color-steps-text-warning);
286
+ font-size: var(--en-multi-f-c-s-fontSize);
286
287
  font-weight: var(--en-multi-f-c-s-fontWeight);
287
- line-height: calc(var(--en-multi-f-c-s-lineHeight) * 1px);
288
+ line-height: var(--en-multi-f-c-s-lineHeight);
288
289
  }
289
290
 
290
291
  .vd-step-u-dot::before {
@@ -298,16 +299,17 @@
298
299
  }
299
300
  }
300
301
 
301
- &.vd-step-warning {
302
- .vd-step-u-line::after {
302
+
303
+ &.vd-step-afoot {
304
+ .u-line::after {
303
305
  height: 100%;
304
306
  }
305
307
 
306
308
  .vd-step-u-text {
307
- color: var(--color-steps-text-warning);
308
- font-size: calc(var(--en-multi-f-c-s-fontSize) * 1px);
309
+ color: var(--color-steps-text-afoot);
310
+ font-size: var(--en-multi-f-c-s-fontSize);
309
311
  font-weight: var(--en-multi-f-c-s-fontWeight);
310
- line-height: calc(var(--en-multi-f-c-s-lineHeight) * 1px);
312
+ line-height: var(--en-multi-f-c-s-lineHeight);
311
313
  }
312
314
 
313
315
  .vd-step-u-dot::before {
@@ -328,25 +330,24 @@
328
330
  width: 100%;
329
331
  display: flex;
330
332
  justify-content: center;
331
- padding-top: calc(var(--spacing-steps-basic-padding_top) * 1px);
332
- padding-bottom: calc(var(--spacing-steps-basic-padding_bottom) * 1px);
333
- margin-inline-start: calc(var(--spacing-steps-basic-padding_y) * 1px);
333
+ padding-top: var(--spacing-steps-basic-padding_top);
334
+ padding-bottom: var(--spacing-steps-basic-padding_bottom);
335
+ margin-inline-start: var(--spacing-steps-basic-padding_y);
334
336
 
335
337
  &:last-child {
336
- margin-inline-end: calc(var(--spacing-steps-basic-padding_y) * 1px);
338
+ margin-inline-end: var(--spacing-steps-basic-padding_y);
337
339
  }
338
340
 
339
341
  .vd-step-u-line {
340
342
  width: 100%;
341
- height: calc(var(--height-steps-basic-default) * 1px);
342
- border-radius: calc(var(--radius-steps-basic) * 1px);
343
+ height: var(--height-steps-basic-default);
344
+ border-radius: var(--radius-steps-basic);
343
345
  background: var(--color-steps-basic-default);
344
346
  }
345
347
 
346
348
  &.vd-step-active {
347
-
348
349
  .vd-step-u-line {
349
- height: calc(var(--height-steps-basic-hover) * 1px);
350
+ height: var(--height-steps-basic-hover);
350
351
  background: var(--color-steps-basic-hover);
351
352
  }
352
353
  }
@@ -19,11 +19,15 @@
19
19
  </template>
20
20
 
21
21
  <script>
22
- import languageMixin from '@p/components/mixins/languageMixin.js';
22
+ import VdButton from '../button';
23
+ import languageMixin from '../mixins/languageMixin.js';
23
24
 
24
25
  const prefixCls = 'vd-stepper';
25
26
  export default {
26
27
  mixins: [languageMixin],
28
+ components: {
29
+ VdButton,
30
+ },
27
31
  name: 'vd-stepper',
28
32
  props: {
29
33
  value: null,
@@ -4,21 +4,21 @@
4
4
  display: inline-block;
5
5
  position: relative;
6
6
  box-sizing: border-box;
7
- width: calc(var(--width-switch-bg) * 1px);
8
- height: calc(var(--height-switch-bg) * 1px);
9
- border-radius: calc(var(--radius-switch-bg) * 1px);
7
+ width: var(--width-switch-bg);
8
+ height: var(--height-switch-bg);
9
+ border-radius: var(--radius-switch-bg);
10
10
  background: var(--color-switch-off_bg-default);
11
11
  cursor: pointer;
12
12
 
13
13
  &-round {
14
14
  box-sizing: border-box;
15
15
  position: absolute;
16
- top: calc(var(--height-switch-bg) * -0.5px);
16
+ top: calc(var(--height-switch-bg) * -0.5);
17
17
  left: 0;
18
18
  transition: transform .3s;
19
- width: calc(var(--height-switch-button) * 1px);
20
- height: calc(var(--height-switch-button) * 1px);
21
- border-radius: calc(var(--radius-switch-button) * 1px);
19
+ width: var(--height-switch-button);
20
+ height: var(--height-switch-button);
21
+ border-radius: var(--radius-switch-button);
22
22
  border: 1px solid var(--color-switch-off_button_border-default);
23
23
  background: var(--color-switch-off_button_bg-default);
24
24
  }
@@ -28,7 +28,7 @@
28
28
  background: var(--color-switch-on_bg-default);
29
29
 
30
30
  .@{prefix}-round {
31
- transform: translateX(calc(var(--height-switch-button) * 1px));
31
+ transform: translateX(var(--height-switch-button));
32
32
  background: var(--color-switch-on_button_bg-default);
33
33
  }
34
34
  }
@@ -0,0 +1,7 @@
1
+ import Tab from './index.vue';
2
+
3
+ Tab.install = function (Vue) {
4
+ Vue.component(Tab.name, Tab);
5
+ };
6
+
7
+ export default Tab;
@@ -20,9 +20,13 @@
20
20
  </template>
21
21
 
22
22
  <script>
23
+ import VdIcon from "../icon";
23
24
  const prefixCls = "vd-tabs";
24
25
  export default {
25
26
  name: "vd-tabs",
27
+ components: {
28
+ VdIcon,
29
+ },
26
30
  props: {
27
31
  value: [String, Number],
28
32
  tabsType: {