ep-craft 0.1.2 → 0.1.4

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 (160) hide show
  1. package/dist/components/button/EpButton.vue.d.ts +7 -7
  2. package/dist/components/button/button.d.ts +4 -4
  3. package/dist/components/button/index.d.ts +2 -4
  4. package/dist/components/button/index.js +4 -6
  5. package/dist/index.css +1 -2
  6. package/dist/resolver.js +9 -12
  7. package/package.json +4 -2
  8. package/theme-chalk/src/affix.scss +7 -0
  9. package/theme-chalk/src/alert.scss +115 -0
  10. package/theme-chalk/src/anchor-link.scss +45 -0
  11. package/theme-chalk/src/anchor.scss +93 -0
  12. package/theme-chalk/src/aside.scss +8 -0
  13. package/theme-chalk/src/autocomplete.scss +95 -0
  14. package/theme-chalk/src/avatar-group.scss +25 -0
  15. package/theme-chalk/src/avatar.scss +55 -0
  16. package/theme-chalk/src/backtop.scss +29 -0
  17. package/theme-chalk/src/badge.scss +58 -0
  18. package/theme-chalk/src/base.scss +3 -0
  19. package/theme-chalk/src/breadcrumb-item.scss +58 -0
  20. package/theme-chalk/src/breadcrumb.scss +9 -0
  21. package/theme-chalk/src/button-group.scss +133 -0
  22. package/theme-chalk/src/button.scss +374 -0
  23. package/theme-chalk/src/calendar.scss +94 -0
  24. package/theme-chalk/src/card.scss +49 -0
  25. package/theme-chalk/src/carousel-item.scss +58 -0
  26. package/theme-chalk/src/carousel.scss +195 -0
  27. package/theme-chalk/src/cascader-panel.scss +150 -0
  28. package/theme-chalk/src/cascader.scss +289 -0
  29. package/theme-chalk/src/check-tag.scss +60 -0
  30. package/theme-chalk/src/checkbox-button.scss +142 -0
  31. package/theme-chalk/src/checkbox-group.scss +7 -0
  32. package/theme-chalk/src/checkbox.scss +300 -0
  33. package/theme-chalk/src/col.scss +56 -0
  34. package/theme-chalk/src/collapse-item.scss +72 -0
  35. package/theme-chalk/src/collapse-transition.scss +1 -0
  36. package/theme-chalk/src/collapse.scss +29 -0
  37. package/theme-chalk/src/color/index.scss +20 -0
  38. package/theme-chalk/src/color-picker-panel.scss +294 -0
  39. package/theme-chalk/src/color-picker.scss +165 -0
  40. package/theme-chalk/src/common/popup.scss +47 -0
  41. package/theme-chalk/src/common/transition.scss +125 -0
  42. package/theme-chalk/src/common/var.scss +1748 -0
  43. package/theme-chalk/src/config-provider.scss +0 -0
  44. package/theme-chalk/src/container.scss +14 -0
  45. package/theme-chalk/src/dark/css-vars.scss +45 -0
  46. package/theme-chalk/src/dark/var.scss +224 -0
  47. package/theme-chalk/src/date-picker/date-picker.scss +121 -0
  48. package/theme-chalk/src/date-picker/date-range-picker.scss +165 -0
  49. package/theme-chalk/src/date-picker/date-table.scss +164 -0
  50. package/theme-chalk/src/date-picker/month-table.scss +112 -0
  51. package/theme-chalk/src/date-picker/picker-panel.scss +152 -0
  52. package/theme-chalk/src/date-picker/picker.scss +217 -0
  53. package/theme-chalk/src/date-picker/time-picker.scss +90 -0
  54. package/theme-chalk/src/date-picker/time-range-picker.scss +33 -0
  55. package/theme-chalk/src/date-picker/time-spinner.scss +115 -0
  56. package/theme-chalk/src/date-picker/utils.scss +14 -0
  57. package/theme-chalk/src/date-picker/year-table.scss +108 -0
  58. package/theme-chalk/src/date-picker-panel.scss +34 -0
  59. package/theme-chalk/src/date-picker.scss +0 -0
  60. package/theme-chalk/src/descriptions-item.scss +77 -0
  61. package/theme-chalk/src/descriptions.scss +151 -0
  62. package/theme-chalk/src/dialog.scss +207 -0
  63. package/theme-chalk/src/display.scss +12 -0
  64. package/theme-chalk/src/divider.scss +48 -0
  65. package/theme-chalk/src/drawer.scss +251 -0
  66. package/theme-chalk/src/dropdown-item.scss +0 -0
  67. package/theme-chalk/src/dropdown-menu.scss +0 -0
  68. package/theme-chalk/src/dropdown.scss +208 -0
  69. package/theme-chalk/src/empty.scss +49 -0
  70. package/theme-chalk/src/footer.scss +12 -0
  71. package/theme-chalk/src/form-item.scss +246 -0
  72. package/theme-chalk/src/form.scss +28 -0
  73. package/theme-chalk/src/header.scss +12 -0
  74. package/theme-chalk/src/icon.scss +41 -0
  75. package/theme-chalk/src/image-viewer.scss +161 -0
  76. package/theme-chalk/src/image.scss +49 -0
  77. package/theme-chalk/src/index.scss +116 -0
  78. package/theme-chalk/src/infinite-scroll.scss +0 -0
  79. package/theme-chalk/src/input-number.scss +192 -0
  80. package/theme-chalk/src/input-otp.scss +191 -0
  81. package/theme-chalk/src/input-tag.scss +249 -0
  82. package/theme-chalk/src/input.scss +541 -0
  83. package/theme-chalk/src/link.scss +90 -0
  84. package/theme-chalk/src/loading.scss +104 -0
  85. package/theme-chalk/src/main.scss +14 -0
  86. package/theme-chalk/src/mention.scss +88 -0
  87. package/theme-chalk/src/menu-item-group.scss +0 -0
  88. package/theme-chalk/src/menu-item.scss +0 -0
  89. package/theme-chalk/src/menu.scss +376 -0
  90. package/theme-chalk/src/message-box.scss +220 -0
  91. package/theme-chalk/src/message.scss +123 -0
  92. package/theme-chalk/src/mixins/_button.scss +240 -0
  93. package/theme-chalk/src/mixins/_col.scss +41 -0
  94. package/theme-chalk/src/mixins/_var.scss +67 -0
  95. package/theme-chalk/src/mixins/config.scss +5 -0
  96. package/theme-chalk/src/mixins/function.scss +99 -0
  97. package/theme-chalk/src/mixins/mixins.scss +257 -0
  98. package/theme-chalk/src/mixins/utils.scss +39 -0
  99. package/theme-chalk/src/notification.scss +109 -0
  100. package/theme-chalk/src/option-group.scss +33 -0
  101. package/theme-chalk/src/option.scss +71 -0
  102. package/theme-chalk/src/overlay.scss +17 -0
  103. package/theme-chalk/src/page-header.scss +60 -0
  104. package/theme-chalk/src/pagination.scss +235 -0
  105. package/theme-chalk/src/popconfirm.scss +17 -0
  106. package/theme-chalk/src/popover.scss +61 -0
  107. package/theme-chalk/src/popper.scss +117 -0
  108. package/theme-chalk/src/progress.scss +179 -0
  109. package/theme-chalk/src/radio-button.scss +165 -0
  110. package/theme-chalk/src/radio-group.scss +9 -0
  111. package/theme-chalk/src/radio.scss +220 -0
  112. package/theme-chalk/src/rate.scss +121 -0
  113. package/theme-chalk/src/reset.scss +99 -0
  114. package/theme-chalk/src/result.scss +57 -0
  115. package/theme-chalk/src/row.scss +34 -0
  116. package/theme-chalk/src/scrollbar.scss +97 -0
  117. package/theme-chalk/src/segmented.scss +186 -0
  118. package/theme-chalk/src/select-dropdown-v2.scss +1 -0
  119. package/theme-chalk/src/select-dropdown.scss +57 -0
  120. package/theme-chalk/src/select-v2.scss +4 -0
  121. package/theme-chalk/src/select.scss +269 -0
  122. package/theme-chalk/src/skeleton-item.scss +83 -0
  123. package/theme-chalk/src/skeleton.scss +44 -0
  124. package/theme-chalk/src/slider.scss +212 -0
  125. package/theme-chalk/src/space.scss +20 -0
  126. package/theme-chalk/src/spinner.scss +43 -0
  127. package/theme-chalk/src/splitter-panel.scss +8 -0
  128. package/theme-chalk/src/splitter.scss +148 -0
  129. package/theme-chalk/src/statistic.scss +35 -0
  130. package/theme-chalk/src/step.scss +320 -0
  131. package/theme-chalk/src/steps.scss +22 -0
  132. package/theme-chalk/src/sub-menu.scss +0 -0
  133. package/theme-chalk/src/switch.scss +294 -0
  134. package/theme-chalk/src/tab-pane.scss +0 -0
  135. package/theme-chalk/src/table-column.scss +100 -0
  136. package/theme-chalk/src/table-v2.scss +239 -0
  137. package/theme-chalk/src/table.scss +698 -0
  138. package/theme-chalk/src/tabs.scss +699 -0
  139. package/theme-chalk/src/tag.scss +195 -0
  140. package/theme-chalk/src/text.scss +51 -0
  141. package/theme-chalk/src/time-picker.scss +5 -0
  142. package/theme-chalk/src/time-select.scss +37 -0
  143. package/theme-chalk/src/timeline-item.scss +135 -0
  144. package/theme-chalk/src/timeline.scss +101 -0
  145. package/theme-chalk/src/tooltip.scss +0 -0
  146. package/theme-chalk/src/tour.scss +187 -0
  147. package/theme-chalk/src/transfer.scss +201 -0
  148. package/theme-chalk/src/tree-select.scss +41 -0
  149. package/theme-chalk/src/tree.scss +134 -0
  150. package/theme-chalk/src/upload.scss +660 -0
  151. package/theme-chalk/src/var.scss +87 -0
  152. package/theme-chalk/src/virtual-list.scss +40 -0
  153. package/dist/components/button/EpButton.vue.js +0 -171
  154. package/dist/components/button/EpButton2.vue.js +0 -4
  155. package/dist/components/button/button.js +0 -95
  156. package/dist/node_modules/@ctrl/tinycolor/dist/module/conversion.js +0 -134
  157. package/dist/node_modules/@ctrl/tinycolor/dist/module/css-color-names.js +0 -153
  158. package/dist/node_modules/@ctrl/tinycolor/dist/module/format-input.js +0 -77
  159. package/dist/node_modules/@ctrl/tinycolor/dist/module/index.js +0 -354
  160. package/dist/node_modules/@ctrl/tinycolor/dist/module/util.js +0 -32
@@ -0,0 +1,142 @@
1
+ @use 'sass:map';
2
+
3
+ @use 'common/var' as *;
4
+ @use 'mixins/mixins' as *;
5
+ @use 'mixins/var' as *;
6
+ @use 'mixins/button' as *;
7
+
8
+ @include b(checkbox-button) {
9
+ @include set-component-css-var('checkbox-button', $checkbox-button);
10
+ }
11
+
12
+ @include b(checkbox-button) {
13
+ position: relative;
14
+ display: inline-block;
15
+
16
+ @include e(inner) {
17
+ display: inline-block;
18
+ line-height: 1;
19
+ font-weight: getCssVar('checkbox-font-weight');
20
+ white-space: nowrap;
21
+ vertical-align: middle;
22
+ cursor: pointer;
23
+ background: var(
24
+ #{getCssVarName('button-bg-color')},
25
+ map.get($button, 'bg-color')
26
+ );
27
+ outline: getCssVar('border');
28
+ color: var(
29
+ #{getCssVarName('button-text-color')},
30
+ map.get($button, 'text-color')
31
+ );
32
+ -webkit-appearance: none;
33
+ text-align: center;
34
+ box-sizing: border-box;
35
+ margin: 0;
36
+ position: relative;
37
+ transition: getCssVar('transition-all');
38
+ user-select: none;
39
+
40
+ @include button-size(
41
+ map.get($button-padding-vertical, 'default') - $button-border-width,
42
+ map.get($button-padding-horizontal, 'default') - $button-border-width,
43
+ map.get($button-font-size, 'default'),
44
+ 0
45
+ );
46
+
47
+ &:hover {
48
+ color: getCssVar('color-primary');
49
+ }
50
+
51
+ & [class*='#{$namespace}-icon-'] {
52
+ line-height: 0.9;
53
+
54
+ & + span {
55
+ margin-left: 5px;
56
+ }
57
+ }
58
+ }
59
+
60
+ @include e(original) {
61
+ opacity: 0;
62
+ outline: none;
63
+ position: absolute;
64
+ margin: 0;
65
+ z-index: -1;
66
+ }
67
+
68
+ &.is-checked {
69
+ & .#{$namespace}-checkbox-button__inner {
70
+ color: getCssVar('checkbox-button-checked-text-color');
71
+ background-color: getCssVar('checkbox-button-checked-bg-color');
72
+ border-color: getCssVar('checkbox-button-checked-border-color');
73
+ box-shadow: -1px 0 0 0 getCssVar('color-primary-light-7');
74
+ }
75
+ &:first-child .#{$namespace}-checkbox-button__inner {
76
+ border-left-color: getCssVar('checkbox-button-checked-border-color');
77
+ }
78
+ }
79
+
80
+ &.is-disabled {
81
+ & .#{$namespace}-checkbox-button__inner {
82
+ color: getCssVar('disabled-text-color');
83
+ cursor: not-allowed;
84
+ background-image: none;
85
+ background-color: var(
86
+ #{getCssVarName('button-disabled-bg-color')},
87
+ map.get($button, 'disabled-bg-color')
88
+ );
89
+ border-color: var(
90
+ #{getCssVarName('button-disabled-border-color')},
91
+ map.get($button, 'disabled-border-color')
92
+ );
93
+ box-shadow: none;
94
+ }
95
+ &:first-child .#{$namespace}-checkbox-button__inner {
96
+ border-left-color: var(
97
+ #{getCssVarName('button-disabled-border-color')},
98
+ map.get($button, 'disabled-border-color')
99
+ );
100
+ }
101
+
102
+ @include when(checked) {
103
+ .#{$namespace}-checkbox-button__inner {
104
+ background-color: getCssVar('checkbox-button-disabled-checked-fill');
105
+ }
106
+ }
107
+ }
108
+
109
+ &:first-child {
110
+ .#{$namespace}-checkbox-button__inner {
111
+ border-top-left-radius: getCssVar('border-radius-base');
112
+ border-bottom-left-radius: getCssVar('border-radius-base');
113
+ box-shadow: none !important;
114
+ }
115
+ }
116
+
117
+ &.is-focus {
118
+ & .#{$namespace}-checkbox-button__inner {
119
+ border-color: getCssVar('checkbox-button-checked-border-color');
120
+ }
121
+ }
122
+
123
+ &:last-child {
124
+ .#{$namespace}-checkbox-button__inner {
125
+ border-top-right-radius: getCssVar('border-radius-base');
126
+ border-bottom-right-radius: getCssVar('border-radius-base');
127
+ }
128
+ }
129
+
130
+ @each $size in (large, small) {
131
+ @include m($size) {
132
+ .#{$namespace}-checkbox-button__inner {
133
+ @include button-size(
134
+ map.get($button-padding-vertical, $size) - $button-border-width,
135
+ map.get($button-padding-horizontal, $size) - $button-border-width,
136
+ map.get($button-font-size, $size),
137
+ 0
138
+ );
139
+ }
140
+ }
141
+ }
142
+ }
@@ -0,0 +1,7 @@
1
+ @use 'common/var' as *;
2
+ @use 'mixins/mixins' as *;
3
+
4
+ @include b(checkbox-group) {
5
+ font-size: 0;
6
+ line-height: 0;
7
+ }
@@ -0,0 +1,300 @@
1
+ @use 'sass:map';
2
+
3
+ @use 'common/var' as *;
4
+ @use 'mixins/mixins' as *;
5
+ @use 'mixins/var' as *;
6
+ @use 'mixins/_button';
7
+
8
+ $checkbox-height: () !default;
9
+ $checkbox-height: map.merge($common-component-size, $checkbox-height);
10
+
11
+ $checkbox-bordered-input-height: () !default;
12
+ $checkbox-bordered-input-height: map.merge(
13
+ (
14
+ 'large': 14px,
15
+ 'default': 12px,
16
+ 'small': 12px,
17
+ ),
18
+ $checkbox-bordered-input-height
19
+ );
20
+
21
+ $checkbox-font-size: () !default;
22
+ $checkbox-font-size: map.merge(
23
+ (
24
+ 'large': 14px,
25
+ 'small': 12px,
26
+ ),
27
+ $checkbox-font-size
28
+ );
29
+
30
+ $checkbox-bordered-input-width: () !default;
31
+ $checkbox-bordered-input-width: map.merge(
32
+ $checkbox-bordered-input-height,
33
+ $checkbox-bordered-input-width
34
+ );
35
+
36
+ @include b(checkbox) {
37
+ @include set-component-css-var('checkbox', $checkbox);
38
+ }
39
+
40
+ @include b(checkbox) {
41
+ color: getCssVar('checkbox-text-color');
42
+ font-weight: getCssVar('checkbox-font-weight');
43
+ font-size: getCssVar('font-size', 'base');
44
+ position: relative;
45
+ cursor: pointer;
46
+ display: inline-flex;
47
+ align-items: center;
48
+ white-space: nowrap;
49
+ user-select: none;
50
+ margin-right: 30px;
51
+ height: getCssVarWithDefault(
52
+ 'checkbox-height',
53
+ map.get($checkbox-height, 'default')
54
+ );
55
+
56
+ @include when(disabled) {
57
+ cursor: not-allowed;
58
+ }
59
+
60
+ @include when(bordered) {
61
+ padding: 0
62
+ map.get($checkbox-bordered-padding-right, 'default')-$border-width 0
63
+ map.get($checkbox-bordered-padding-left, 'default')-$border-width;
64
+ border-radius: getCssVar('border-radius-base');
65
+ border: getCssVar('border');
66
+ box-sizing: border-box;
67
+
68
+ &.is-checked {
69
+ border-color: getCssVar('color-primary');
70
+ }
71
+
72
+ &.is-disabled {
73
+ border-color: getCssVar('border-color-lighter');
74
+ }
75
+
76
+ @each $size in (large, small) {
77
+ &.#{$namespace}-checkbox--#{$size} {
78
+ padding: 0
79
+ map.get($checkbox-bordered-padding-right, $size)-$border-width
80
+ 0
81
+ map.get($checkbox-bordered-padding-left, $size)-$border-width;
82
+
83
+ border-radius: map.get($button-border-radius, $size);
84
+
85
+ .#{$namespace}-checkbox__label {
86
+ font-size: map.get($button-font-size, $size);
87
+ }
88
+
89
+ .#{$namespace}-checkbox__inner {
90
+ height: map.get($checkbox-bordered-input-height, $size);
91
+ width: map.get($checkbox-bordered-input-width, $size);
92
+ }
93
+ }
94
+ }
95
+
96
+ &.#{$namespace}-checkbox--small {
97
+ .#{$namespace}-checkbox__inner {
98
+ &::after {
99
+ height: 6px;
100
+ width: 2px;
101
+ }
102
+ }
103
+ }
104
+ }
105
+
106
+ input:focus-visible {
107
+ & + .#{$namespace}-checkbox__inner {
108
+ outline: 2px solid getCssVar('checkbox-input-border-color-hover');
109
+ outline-offset: 1px;
110
+ border-radius: getCssVar('checkbox-border-radius');
111
+ }
112
+ }
113
+
114
+ @include e(input) {
115
+ white-space: nowrap;
116
+ cursor: pointer;
117
+ outline: none;
118
+ display: inline-flex;
119
+ position: relative;
120
+
121
+ @include when(disabled) {
122
+ .#{$namespace}-checkbox__inner {
123
+ background-color: getCssVar('checkbox-disabled-input-fill');
124
+ border-color: getCssVar('checkbox-disabled-border-color');
125
+ cursor: not-allowed;
126
+
127
+ &::after {
128
+ cursor: not-allowed;
129
+ border-color: getCssVar('checkbox-disabled-icon-color');
130
+ will-change: transform;
131
+ }
132
+ }
133
+
134
+ &.is-checked {
135
+ .#{$namespace}-checkbox__inner {
136
+ background-color: getCssVar('checkbox-disabled-checked-input-fill');
137
+ border-color: getCssVar(
138
+ 'checkbox-disabled-checked-input-border-color'
139
+ );
140
+
141
+ &::after {
142
+ border-color: getCssVar('checkbox-disabled-checked-icon-color');
143
+ }
144
+ }
145
+ }
146
+
147
+ &.is-indeterminate {
148
+ .#{$namespace}-checkbox__inner {
149
+ background-color: getCssVar('checkbox-disabled-checked-input-fill');
150
+ border-color: getCssVar(
151
+ 'checkbox-disabled-checked-input-border-color'
152
+ );
153
+
154
+ &::before {
155
+ background-color: getCssVar('checkbox-disabled-checked-icon-color');
156
+ border-color: getCssVar('checkbox-disabled-checked-icon-color');
157
+ }
158
+ }
159
+ }
160
+
161
+ & + span.#{$namespace}-checkbox__label {
162
+ color: getCssVar('disabled-text-color');
163
+ cursor: not-allowed;
164
+ }
165
+ }
166
+
167
+ @include when(checked) {
168
+ .#{$namespace}-checkbox__inner {
169
+ background-color: getCssVar('checkbox-checked-bg-color');
170
+ border-color: getCssVar('checkbox-checked-input-border-color');
171
+
172
+ &::after {
173
+ transform: translate(-45%, -60%) rotate(45deg) scaleY(1);
174
+ border-color: getCssVar('checkbox-checked-icon-color');
175
+ }
176
+ }
177
+
178
+ & + .#{$namespace}-checkbox__label {
179
+ color: getCssVar('checkbox-checked-text-color');
180
+ }
181
+ }
182
+ @include when(focus) {
183
+ // Visually distinguish when focus
184
+ &:not(.is-checked) {
185
+ .#{$namespace}-checkbox__original:not(:focus-visible) {
186
+ border-color: getCssVar('checkbox-input-border-color-hover');
187
+ }
188
+ }
189
+ }
190
+ @include when(indeterminate) {
191
+ .#{$namespace}-checkbox__inner {
192
+ background-color: getCssVar('checkbox-checked-bg-color');
193
+ border-color: getCssVar('checkbox-checked-input-border-color');
194
+
195
+ &::before {
196
+ content: '';
197
+ position: absolute;
198
+ display: block;
199
+ background-color: getCssVar('checkbox-checked-icon-color');
200
+ height: 2px;
201
+ transform: scale(0.5);
202
+ left: 0;
203
+ right: 0;
204
+ top: 5px;
205
+ }
206
+
207
+ &::after {
208
+ display: none;
209
+ }
210
+ }
211
+ }
212
+ }
213
+ @include e(inner) {
214
+ display: inline-block;
215
+ position: relative;
216
+ border: getCssVar('checkbox-input-border');
217
+ border-radius: getCssVar('checkbox-border-radius');
218
+ box-sizing: border-box;
219
+ width: getCssVar('checkbox-input-width');
220
+ height: getCssVar('checkbox-input-height');
221
+ background-color: getCssVar('checkbox-bg-color');
222
+ z-index: getCssVar('index-normal');
223
+ transition:
224
+ border-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46),
225
+ background-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46),
226
+ outline 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46);
227
+
228
+ &:hover {
229
+ border-color: getCssVar('checkbox-input-border-color-hover');
230
+ }
231
+
232
+ &::after {
233
+ box-sizing: content-box;
234
+ content: '';
235
+ border: 1px solid transparent;
236
+ border-left: 0;
237
+ border-top: 0;
238
+ height: 7px;
239
+ left: 50%;
240
+ position: absolute;
241
+ top: 50%;
242
+ transform: translate(-45%, -60%) rotate(45deg) scaleY(0);
243
+ width: 3px;
244
+ transition: transform 0.15s ease-in 0.05s;
245
+ transform-origin: center;
246
+ }
247
+ }
248
+
249
+ @include e(original) {
250
+ opacity: 0;
251
+ outline: none;
252
+ position: absolute;
253
+ margin: 0;
254
+ width: 0;
255
+ height: 0;
256
+ z-index: -1;
257
+ }
258
+
259
+ @include e(label) {
260
+ display: inline-block;
261
+ padding-left: 8px;
262
+ line-height: 1;
263
+ font-size: getCssVar('checkbox-font-size');
264
+ }
265
+
266
+ @each $size in (large, small) {
267
+ &.#{$namespace}-checkbox--#{$size} {
268
+ height: map.get($checkbox-height, $size);
269
+ @include e(label) {
270
+ font-size: map.get($checkbox-font-size, $size);
271
+ }
272
+ @include e(inner) {
273
+ width: map.get($checkbox-font-size, $size);
274
+ height: map.get($checkbox-font-size, $size);
275
+ }
276
+ }
277
+ }
278
+
279
+ &.#{$namespace}-checkbox--small {
280
+ @include e(input) {
281
+ @include when(indeterminate) {
282
+ @include e(inner) {
283
+ &::before {
284
+ top: 4px;
285
+ }
286
+ }
287
+ }
288
+ }
289
+ @include e(inner) {
290
+ &::after {
291
+ width: 2px;
292
+ height: 6px;
293
+ }
294
+ }
295
+ }
296
+
297
+ &:last-of-type {
298
+ margin-right: 0;
299
+ }
300
+ }
@@ -0,0 +1,56 @@
1
+ @use 'sass:math';
2
+
3
+ @use 'common/var' as *;
4
+ @use 'mixins/mixins' as *;
5
+ @use 'mixins/_col' as *;
6
+
7
+ [class*='#{$namespace}-col-'] {
8
+ box-sizing: border-box;
9
+ @include when(guttered) {
10
+ display: block;
11
+ min-height: 1px;
12
+ }
13
+ }
14
+
15
+ @for $i from 0 through 24 {
16
+ .#{$namespace}-col-#{$i} {
17
+ @if $i == 0 {
18
+ display: none;
19
+ } @else {
20
+ display: block;
21
+ }
22
+ max-width: (math.div(1, 24) * $i * 100) * 1%;
23
+ flex: 0 0 (math.div(1, 24) * $i * 100) * 1%;
24
+ @include when(guttered) {
25
+ @if $i == 0 {
26
+ display: none;
27
+ } @else {
28
+ display: block;
29
+ }
30
+ }
31
+ }
32
+
33
+ .#{$namespace}-col-offset-#{$i} {
34
+ margin-left: (math.div(1, 24) * $i * 100) * 1%;
35
+ }
36
+
37
+ .#{$namespace}-col-pull-#{$i} {
38
+ position: relative;
39
+ right: (math.div(1, 24) * $i * 100) * 1%;
40
+ }
41
+
42
+ .#{$namespace}-col-push-#{$i} {
43
+ position: relative;
44
+ left: (math.div(1, 24) * $i * 100) * 1%;
45
+ }
46
+ }
47
+
48
+ @include col-size(xs);
49
+
50
+ @include col-size(sm);
51
+
52
+ @include col-size(md);
53
+
54
+ @include col-size(lg);
55
+
56
+ @include col-size(xl);
@@ -0,0 +1,72 @@
1
+ @use 'mixins/mixins' as *;
2
+ @use 'mixins/var' as *;
3
+ @use 'common/var' as *;
4
+
5
+ @include b(collapse-item) {
6
+ @include when(disabled) {
7
+ .#{$namespace}-collapse-item__header {
8
+ color: getCssVar('text-color-disabled');
9
+ cursor: not-allowed;
10
+ }
11
+ }
12
+
13
+ @include e(header) {
14
+ width: 100%;
15
+ padding: 0;
16
+ border: none;
17
+ display: flex;
18
+ align-items: center;
19
+ min-height: getCssVar('collapse-header-height');
20
+ line-height: getCssVar('collapse-header-height');
21
+ background-color: getCssVar('collapse-header-bg-color');
22
+ color: getCssVar('collapse-header-text-color');
23
+ cursor: pointer;
24
+ border-bottom: 1px solid getCssVar('collapse-border-color');
25
+ font-size: getCssVar('collapse-header-font-size');
26
+ font-weight: 500;
27
+ transition: border-bottom-color getCssVar('transition-duration');
28
+ outline: none;
29
+ box-sizing: border-box;
30
+
31
+ @include e(arrow) {
32
+ transition: transform getCssVar('transition-duration');
33
+ font-weight: 300;
34
+
35
+ @include when(active) {
36
+ transform: rotate(90deg);
37
+ }
38
+ }
39
+
40
+ @include e(title) {
41
+ text-align: left;
42
+ flex: auto;
43
+ }
44
+
45
+ &.focusing:focus:not(:hover) {
46
+ color: getCssVar('color-primary');
47
+ }
48
+
49
+ @include when(active) {
50
+ border-bottom-color: transparent;
51
+ }
52
+ }
53
+
54
+ @include e(wrap) {
55
+ will-change: height;
56
+ background-color: getCssVar('collapse-content-bg-color');
57
+ overflow: hidden;
58
+ box-sizing: border-box;
59
+ border-bottom: 1px solid getCssVar('collapse-border-color');
60
+ }
61
+
62
+ @include e(content) {
63
+ padding-bottom: 25px;
64
+ font-size: getCssVar('collapse-content-font-size');
65
+ color: getCssVar('collapse-content-text-color');
66
+ line-height: 1.769230769230769;
67
+ }
68
+
69
+ &:last-child {
70
+ margin-bottom: -1px;
71
+ }
72
+ }
@@ -0,0 +1 @@
1
+ @use 'common/transition';
@@ -0,0 +1,29 @@
1
+ @use 'mixins/mixins' as *;
2
+ @use 'mixins/var' as *;
3
+ @use 'common/var' as *;
4
+
5
+ @include b(collapse) {
6
+ @include set-component-css-var('collapse', $collapse);
7
+
8
+ border-top: 1px solid getCssVar('collapse-border-color');
9
+ border-bottom: 1px solid getCssVar('collapse-border-color');
10
+ }
11
+
12
+ .#{$namespace}-collapse-icon-position {
13
+ &-left {
14
+ .#{$namespace}-collapse-item__ {
15
+ &header {
16
+ gap: 8px;
17
+ }
18
+ &title {
19
+ order: 1;
20
+ }
21
+ }
22
+ }
23
+
24
+ &-right {
25
+ .#{$namespace}-collapse-item__header {
26
+ padding-right: 8px;
27
+ }
28
+ }
29
+ }
@@ -0,0 +1,20 @@
1
+ @use 'sass:color';
2
+ @use 'sass:string';
3
+
4
+ @function rgb2hex($color) {
5
+ @return string.unquote('#' + #{string.slice(color.ie-hex-str($color), 4)});
6
+ }
7
+
8
+ // rgba color above solid color
9
+ @function mix-overlay-color($upper, $lower) {
10
+ $opacity: color.alpha($upper);
11
+
12
+ $red: color.channel($upper, 'red', $space: rgb) * $opacity +
13
+ color.channel($lower, 'red', $space: rgb) * (1 - $opacity);
14
+ $green: color.channel($upper, 'green', $space: rgb) * $opacity +
15
+ color.channel($lower, 'green', $space: rgb) * (1 - $opacity);
16
+ $blue: color.channel($upper, 'blue', $space: rgb) * $opacity +
17
+ color.channel($lower, 'blue', $space: rgb) * (1 - $opacity);
18
+
19
+ @return rgb2hex(rgb($red, $green, $blue));
20
+ }