@volverjs/style 0.1.2-beta.9 → 0.1.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 (190) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +53 -46
  3. package/dist/components/vv-accordion-group.css +1 -0
  4. package/dist/components/vv-accordion.css +1 -1
  5. package/dist/components/vv-alert.css +1 -0
  6. package/dist/components/vv-avatar.css +1 -0
  7. package/dist/components/vv-badge.css +1 -1
  8. package/dist/components/vv-breadcrumb.css +1 -1
  9. package/dist/components/vv-button-group.css +1 -1
  10. package/dist/components/vv-button.css +1 -1
  11. package/dist/components/vv-card.css +1 -1
  12. package/dist/components/vv-checkbox-group.css +1 -0
  13. package/dist/components/vv-checkbox.css +1 -0
  14. package/dist/components/vv-dialog.css +1 -1
  15. package/dist/components/vv-dropdown.css +1 -1
  16. package/dist/components/vv-input-text.css +1 -1
  17. package/dist/components/vv-nav.css +1 -1
  18. package/dist/components/vv-progress.css +1 -1
  19. package/dist/components/vv-radio-group.css +1 -0
  20. package/dist/components/vv-radio.css +1 -0
  21. package/dist/components/vv-select.css +1 -1
  22. package/dist/components/vv-skeleton.css +1 -0
  23. package/dist/components/vv-tab.css +1 -0
  24. package/dist/components/vv-table.css +1 -1
  25. package/dist/components/vv-text.css +1 -1
  26. package/dist/components/vv-textarea.css +1 -1
  27. package/dist/components/vv-toast.css +1 -0
  28. package/dist/components/vv-tooltip.css +1 -0
  29. package/dist/components.css +1 -1
  30. package/dist/export.css +1 -1
  31. package/dist/props/background.css +1 -1
  32. package/dist/props/breakpoints.css +1 -0
  33. package/dist/props/colors.css +1 -1
  34. package/dist/props/effects.css +1 -1
  35. package/dist/props/filters.css +1 -1
  36. package/dist/props/input.css +1 -1
  37. package/dist/props/layout.css +1 -1
  38. package/dist/props/spacing.css +1 -1
  39. package/dist/props/transitions.css +1 -0
  40. package/dist/props.css +1 -1
  41. package/dist/themes/dark/components.css +1 -1
  42. package/dist/themes/dark/props.css +1 -1
  43. package/dist/themes/dark/volver.css +1 -1
  44. package/dist/utilities/backgrounds.css +1 -1
  45. package/dist/utilities/borders.css +1 -1
  46. package/dist/utilities/colors.css +1 -1
  47. package/dist/utilities/effects.css +1 -1
  48. package/dist/utilities/filters.css +1 -1
  49. package/dist/utilities/flexbox.css +1 -1
  50. package/dist/utilities/interactivity.css +1 -0
  51. package/dist/utilities/layout.css +1 -1
  52. package/dist/utilities/sizing.css +1 -1
  53. package/dist/utilities/spacing.css +1 -1
  54. package/dist/utilities/tables.css +1 -0
  55. package/dist/utilities/transforms.css +1 -0
  56. package/dist/utilities/transitions.css +1 -0
  57. package/dist/utilities/typography.css +1 -1
  58. package/dist/utilities.css +1 -1
  59. package/dist/volver.css +1 -1
  60. package/package.json +62 -36
  61. package/src/_config.scss +18 -11
  62. package/src/_context.scss +3 -3
  63. package/src/_preflight.scss +308 -247
  64. package/src/components/index.scss +26 -19
  65. package/src/components/vv-accordion-group.scss +13 -0
  66. package/src/components/vv-accordion.scss +3 -2
  67. package/src/components/vv-alert.scss +13 -0
  68. package/src/components/vv-avatar.scss +13 -0
  69. package/src/components/vv-badge.scss +3 -2
  70. package/src/components/vv-breadcrumb.scss +3 -2
  71. package/src/components/vv-button-group.scss +11 -10
  72. package/src/components/vv-button.scss +5 -8
  73. package/src/components/vv-card.scss +3 -2
  74. package/src/components/vv-checkbox-group.scss +13 -0
  75. package/src/components/{vv-input-checkbox.scss → vv-checkbox.scss} +7 -6
  76. package/src/components/vv-dialog.scss +3 -2
  77. package/src/components/vv-dropdown.scss +3 -2
  78. package/src/components/vv-input-text.scss +6 -5
  79. package/src/components/vv-nav.scss +3 -2
  80. package/src/components/vv-progress.scss +3 -2
  81. package/src/components/vv-radio-group.scss +13 -0
  82. package/src/components/{vv-input-radio.scss → vv-radio.scss} +6 -5
  83. package/src/components/vv-select.scss +6 -5
  84. package/src/components/vv-skeleton.scss +14 -0
  85. package/src/components/vv-tab.scss +13 -0
  86. package/src/components/vv-table.scss +3 -2
  87. package/src/components/vv-text.scss +3 -2
  88. package/src/components/vv-textarea.scss +6 -5
  89. package/src/components/vv-toast.scss +13 -0
  90. package/src/components/vv-tooltip.scss +33 -0
  91. package/src/export.scss +138 -27
  92. package/src/props/background.scss +1 -1
  93. package/src/props/borders.scss +1 -1
  94. package/src/props/breakpoints.scss +15 -0
  95. package/src/props/colors.scss +1 -1
  96. package/src/props/effects.scss +2 -1
  97. package/src/props/filters.scss +2 -1
  98. package/src/props/index.scss +13 -12
  99. package/src/props/input.scss +1 -1
  100. package/src/props/layout.scss +1 -1
  101. package/src/props/media.scss +1 -1
  102. package/src/props/sizing.scss +1 -1
  103. package/src/props/spacing.scss +2 -2
  104. package/src/props/{animation.scss → transitions.scss} +53 -2
  105. package/src/props/typography.scss +2 -2
  106. package/src/settings/_background.scss +6 -1
  107. package/src/settings/_breakpoints.scss +2 -0
  108. package/src/settings/_colors.scss +23 -4
  109. package/src/settings/_effects.scss +47 -2
  110. package/src/settings/_filters.scss +9 -0
  111. package/src/settings/_index.scss +43 -33
  112. package/src/settings/_input.scss +8 -6
  113. package/src/settings/_interactivity.scss +39 -0
  114. package/src/settings/_layout.scss +30 -10
  115. package/src/settings/_spacing.scss +1 -0
  116. package/src/settings/_tables.scss +11 -0
  117. package/src/settings/_transforms.scss +50 -0
  118. package/src/settings/_transitions.scss +44 -0
  119. package/src/settings/components/_vv-accordion-group.scss +5 -0
  120. package/src/settings/components/_vv-accordion.scss +49 -34
  121. package/src/settings/components/_vv-alert.scss +161 -0
  122. package/src/settings/components/_vv-avatar.scss +55 -0
  123. package/src/settings/components/_vv-badge.scss +43 -11
  124. package/src/settings/components/_vv-breadcrumb.scss +23 -15
  125. package/src/settings/components/_vv-button-group.scss +4 -0
  126. package/src/settings/components/_vv-button.scss +31 -26
  127. package/src/settings/components/_vv-card.scss +2 -2
  128. package/src/settings/components/{_vv-input-checkbox-group.scss → _vv-checkbox-group.scss} +2 -1
  129. package/src/settings/components/{_vv-input-checkbox.scss → _vv-checkbox.scss} +47 -12
  130. package/src/settings/components/_vv-dialog.scss +72 -90
  131. package/src/settings/components/_vv-input-text.scss +89 -43
  132. package/src/settings/components/_vv-nav.scss +98 -13
  133. package/src/settings/components/_vv-progress.scss +1 -1
  134. package/src/settings/components/_vv-radio-group.scss +3 -0
  135. package/src/settings/components/{_vv-input-radio.scss → _vv-radio.scss} +35 -6
  136. package/src/settings/components/_vv-select.scss +39 -48
  137. package/src/settings/components/_vv-skeleton.scss +22 -0
  138. package/src/settings/components/_vv-tab.scss +16 -0
  139. package/src/settings/components/_vv-table.scss +8 -1
  140. package/src/settings/components/_vv-text.scss +20 -0
  141. package/src/settings/components/_vv-textarea.scss +53 -28
  142. package/src/settings/components/_vv-toast.scss +259 -0
  143. package/src/settings/components/_vv-tooltip.scss +74 -0
  144. package/src/themes/dark/_context.scss +7 -4
  145. package/src/themes/dark/components/_vv-button.scss +2 -4
  146. package/src/themes/dark/components/index.scss +1 -2
  147. package/src/themes/dark/props/_background.scss +1 -1
  148. package/src/themes/dark/props/_colors.scss +1 -1
  149. package/src/themes/dark/props/_input.scss +15 -0
  150. package/src/themes/dark/props/index.scss +3 -2
  151. package/src/themes/dark/settings/_background.scss +5 -0
  152. package/src/themes/dark/settings/_colors.scss +22 -2
  153. package/src/themes/dark/settings/_index.scss +4 -4
  154. package/src/themes/dark/settings/_input.scss +8 -0
  155. package/src/themes/dark/settings/components/_vv-button.scss +9 -9
  156. package/src/themes/dark/volver.scss +2 -2
  157. package/src/tools/_breakpoints.scss +7 -7
  158. package/src/tools/_functions.scss +95 -37
  159. package/src/tools/_index.scss +3 -3
  160. package/src/tools/_mixins.scss +166 -35
  161. package/src/utilities/backgrounds.scss +15 -8
  162. package/src/utilities/borders.scss +22 -9
  163. package/src/utilities/colors.scss +9 -5
  164. package/src/utilities/effects.scss +23 -5
  165. package/src/utilities/filters.scss +15 -4
  166. package/src/utilities/flexbox.scss +15 -8
  167. package/src/utilities/grid.scss +17 -9
  168. package/src/utilities/index.scss +15 -12
  169. package/src/utilities/interactivity.scss +10 -0
  170. package/src/utilities/layout.scss +45 -28
  171. package/src/utilities/sizing.scss +23 -26
  172. package/src/utilities/spacing.scss +1 -1
  173. package/src/utilities/tables.scss +15 -0
  174. package/src/utilities/transforms.scss +111 -0
  175. package/src/utilities/transitions.scss +47 -0
  176. package/src/utilities/typography.scss +34 -17
  177. package/src/volver.scss +4 -4
  178. package/dist/components/vv-input-checkbox-group.css +0 -1
  179. package/dist/components/vv-input-checkbox.css +0 -1
  180. package/dist/components/vv-input-radio-group.css +0 -1
  181. package/dist/components/vv-input-radio.css +0 -1
  182. package/dist/props/animation.css +0 -1
  183. package/dist/utilities/animation.css +0 -1
  184. package/src/components/vv-input-checkbox-group.scss +0 -12
  185. package/src/components/vv-input-radio-group.scss +0 -12
  186. package/src/settings/_animation.scss +0 -9
  187. package/src/settings/components/_vv-input-radio-group.scss +0 -1
  188. package/src/themes/dark/components/_vv-input-checkbox.scss +0 -24
  189. package/src/themes/dark/settings/components/_vv-input-checkbox.scss +0 -26
  190. package/src/utilities/animation.scss +0 -8
@@ -1,11 +1,12 @@
1
- @import '../context';
1
+ @use '../context' as *;
2
2
 
3
3
  // background-color
4
4
  @include spread-map-into-utilities(
5
5
  $map: $colors,
6
6
  $class: bg,
7
7
  $attribute: background-color,
8
- $prop: color
8
+ $prop: color,
9
+ $zero-specificity: $zero-specificity-for-utilities
9
10
  );
10
11
 
11
12
  // color
@@ -13,7 +14,8 @@
13
14
  $map: $colors,
14
15
  $class: text,
15
16
  $attribute: color,
16
- $prop: color
17
+ $prop: color,
18
+ $zero-specificity: $zero-specificity-for-utilities
17
19
  );
18
20
 
19
21
  // text-decoration-color
@@ -21,7 +23,8 @@
21
23
  $map: $colors,
22
24
  $class: decoration,
23
25
  $attribute: text-decoration-color,
24
- $prop: color
26
+ $prop: color,
27
+ $zero-specificity: $zero-specificity-for-utilities
25
28
  );
26
29
 
27
30
  // border-color
@@ -29,5 +32,6 @@
29
32
  $map: $colors,
30
33
  $class: border,
31
34
  $attribute: border-color,
32
- $prop: color
35
+ $prop: color,
36
+ $zero-specificity: $zero-specificity-for-utilities
33
37
  );
@@ -1,15 +1,33 @@
1
- @import '../context';
1
+ @use '../context' as *;
2
2
 
3
3
  // box shadow
4
4
  @include spread-map-into-utilities(
5
5
  $map: $box-shadow,
6
6
  $class: shadow,
7
- $attribute: box-shadow
7
+ $attribute: box-shadow,
8
+ $zero-specificity: $zero-specificity-for-utilities
8
9
  );
9
10
 
10
- // blend mode
11
+ // opacity
11
12
  @include spread-map-into-utilities(
12
- $map: $blend-mode,
13
+ $map: $opacity,
14
+ $class: opacity,
15
+ $attribute: opacity,
16
+ $zero-specificity: $zero-specificity-for-utilities
17
+ );
18
+
19
+ // mix blend mode
20
+ @include spread-map-into-utilities(
21
+ $map: $mix-blend-mode,
13
22
  $class: mix-blend,
14
- $attribute: mix-blend-mode
23
+ $attribute: mix-blend-mode,
24
+ $zero-specificity: $zero-specificity-for-utilities
25
+ );
26
+
27
+ // background blend mode
28
+ @include spread-map-into-utilities(
29
+ $map: $background-blend-mode,
30
+ $class: bg-blend,
31
+ $attribute: background-blend-mode,
32
+ $zero-specificity: $zero-specificity-for-utilities
15
33
  );
@@ -1,22 +1,33 @@
1
- @import '../context';
1
+ @use '../context' as *;
2
2
 
3
3
  // blur
4
4
  @include spread-map-into-utilities(
5
5
  $map: $blur,
6
6
  $class: blur,
7
- $attribute: filter
7
+ $attribute: filter,
8
+ $zero-specificity: $zero-specificity-for-utilities
8
9
  );
9
10
 
10
11
  // brightness
11
12
  @include spread-map-into-utilities(
12
13
  $map: $brightness,
13
14
  $class: brightness,
14
- $attribute: filter
15
+ $attribute: filter,
16
+ $zero-specificity: $zero-specificity-for-utilities
17
+ );
18
+
19
+ // saturation
20
+ @include spread-map-into-utilities(
21
+ $map: $saturation,
22
+ $class: saturate,
23
+ $attribute: filter,
24
+ $zero-specificity: $zero-specificity-for-utilities
15
25
  );
16
26
 
17
27
  // backdrop blur
18
28
  @include spread-map-into-utilities(
19
29
  $map: $blur,
20
30
  $class: backdrop-blur,
21
- $attribute: backdrop-filter
31
+ $attribute: backdrop-filter,
32
+ $zero-specificity: $zero-specificity-for-utilities
22
33
  );
@@ -1,12 +1,13 @@
1
1
  @use 'sass:map';
2
- @import '../context';
2
+ @use '../context' as *;
3
3
 
4
4
  // flex direction
5
5
  @include spread-map-into-utilities(
6
6
  $map: $flex-direction,
7
7
  $class: flex,
8
8
  $attribute: flex-direction,
9
- $bps: $breakpoints
9
+ $bps: $breakpoints,
10
+ $zero-specificity: $zero-specificity-for-utilities
10
11
  );
11
12
 
12
13
  // flex wrap
@@ -14,7 +15,8 @@
14
15
  $map: $flex-wrap,
15
16
  $class: flex,
16
17
  $attribute: flex-wrap,
17
- $bps: $breakpoints
18
+ $bps: $breakpoints,
19
+ $zero-specificity: $zero-specificity-for-utilities
18
20
  );
19
21
 
20
22
  // flex
@@ -22,7 +24,8 @@
22
24
  $map: $flex,
23
25
  $class: flex,
24
26
  $attribute: flex,
25
- $bps: $breakpoints
27
+ $bps: $breakpoints,
28
+ $zero-specificity: $zero-specificity-for-utilities
26
29
  );
27
30
 
28
31
  // flex grow
@@ -45,7 +48,8 @@
45
48
  $map: $order,
46
49
  $class: order,
47
50
  $attribute: order,
48
- $bps: $breakpoints
51
+ $bps: $breakpoints,
52
+ $zero-specificity: $zero-specificity-for-utilities
49
53
  );
50
54
 
51
55
  // gap
@@ -99,7 +103,8 @@
99
103
  $map: $justify-align-content,
100
104
  $class: $class,
101
105
  $attribute: $attribute,
102
- $bps: $breakpoints
106
+ $bps: $breakpoints,
107
+ $zero-specificity: $zero-specificity-for-utilities
103
108
  );
104
109
  }
105
110
 
@@ -109,7 +114,8 @@
109
114
  $map: $justify-align-items,
110
115
  $class: $class,
111
116
  $attribute: $attribute,
112
- $bps: $breakpoints
117
+ $bps: $breakpoints,
118
+ $zero-specificity: $zero-specificity-for-utilities
113
119
  );
114
120
  }
115
121
 
@@ -119,6 +125,7 @@
119
125
  $map: $justify-align-self,
120
126
  $class: $class,
121
127
  $attribute: $attribute,
122
- $bps: $breakpoints
128
+ $bps: $breakpoints,
129
+ $zero-specificity: $zero-specificity-for-utilities
123
130
  );
124
131
  }
@@ -1,12 +1,13 @@
1
1
  @use 'sass:map';
2
- @import '../context';
2
+ @use '../context' as *;
3
3
 
4
4
  // grid template columns
5
5
  @include spread-map-into-utilities(
6
6
  $map: $grid-template-columns,
7
7
  $class: grid-cols,
8
8
  $attribute: grid-template-columns,
9
- $bps: $breakpoints
9
+ $bps: $breakpoints,
10
+ $zero-specificity: $zero-specificity-for-utilities
10
11
  );
11
12
 
12
13
  // grid column
@@ -14,7 +15,8 @@
14
15
  $map: $grid-column,
15
16
  $class: col,
16
17
  $attribute: grid-column,
17
- $bps: $breakpoints
18
+ $bps: $breakpoints,
19
+ $zero-specificity: $zero-specificity-for-utilities
18
20
  );
19
21
 
20
22
  // grid column start/end
@@ -25,7 +27,8 @@
25
27
  $map: $grid-column-start-end,
26
28
  $class: $class,
27
29
  $attribute: $attribute,
28
- $bps: $breakpoints
30
+ $bps: $breakpoints,
31
+ $zero-specificity: $zero-specificity-for-utilities
29
32
  );
30
33
  }
31
34
 
@@ -34,7 +37,8 @@
34
37
  $map: $grid-template-rows,
35
38
  $class: grid-rows,
36
39
  $attribute: grid-template-rows,
37
- $bps: $breakpoints
40
+ $bps: $breakpoints,
41
+ $zero-specificity: $zero-specificity-for-utilities
38
42
  );
39
43
 
40
44
  // grid row
@@ -42,7 +46,8 @@
42
46
  $map: $grid-row,
43
47
  $class: row,
44
48
  $attribute: grid-row,
45
- $bps: $breakpoints
49
+ $bps: $breakpoints,
50
+ $zero-specificity: $zero-specificity-for-utilities
46
51
  );
47
52
 
48
53
  // grid row start/end
@@ -51,7 +56,8 @@
51
56
  $map: $grid-row-start-end,
52
57
  $class: $class,
53
58
  $attribute: $attribute,
54
- $bps: $breakpoints
59
+ $bps: $breakpoints,
60
+ $zero-specificity: $zero-specificity-for-utilities
55
61
  );
56
62
  }
57
63
 
@@ -60,7 +66,8 @@
60
66
  $map: $grid-auto-flow,
61
67
  $class: grid-flow,
62
68
  $attribute: grid-auto-flow,
63
- $bps: $breakpoints
69
+ $bps: $breakpoints,
70
+ $zero-specificity: $zero-specificity-for-utilities
64
71
  );
65
72
 
66
73
  // grid auto rows/columns
@@ -71,6 +78,7 @@
71
78
  $map: $grid-auto-rows-columns,
72
79
  $class: $class,
73
80
  $attribute: $attribute,
74
- $bps: $breakpoints
81
+ $bps: $breakpoints,
82
+ $zero-specificity: $zero-specificity-for-utilities
75
83
  );
76
84
  }
@@ -1,12 +1,15 @@
1
- @import 'animation';
2
- @import 'backgrounds';
3
- @import 'borders';
4
- @import 'colors';
5
- @import 'effects';
6
- @import 'filters';
7
- @import 'flexbox';
8
- @import 'grid';
9
- @import 'layout';
10
- @import 'sizing';
11
- @import 'spacing';
12
- @import 'typography';
1
+ @forward 'backgrounds';
2
+ @forward 'borders';
3
+ @forward 'colors';
4
+ @forward 'effects';
5
+ @forward 'filters';
6
+ @forward 'flexbox';
7
+ @forward 'grid';
8
+ @forward 'interactivity';
9
+ @forward 'layout';
10
+ @forward 'sizing';
11
+ @forward 'spacing';
12
+ @forward 'tables';
13
+ @forward 'transitions';
14
+ @forward 'typography';
15
+ @forward 'transforms';
@@ -0,0 +1,10 @@
1
+ @use 'sass:map';
2
+ @use '../context' as *;
3
+
4
+ // grid template columns
5
+ @include spread-map-into-utilities(
6
+ $map: $cursor,
7
+ $class: cursor,
8
+ $attribute: cursor,
9
+ $zero-specificity: $zero-specificity-for-utilities
10
+ );
@@ -1,5 +1,5 @@
1
1
  @use 'sass:map';
2
- @import '../context';
2
+ @use '../context' as *;
3
3
 
4
4
  // aspect
5
5
  @include spread-map-into-utilities(
@@ -7,7 +7,8 @@
7
7
  $class: aspect,
8
8
  $attribute: aspect-ratio,
9
9
  $prop: aspect,
10
- $bps: $breakpoints
10
+ $bps: $breakpoints,
11
+ $zero-specificity: $zero-specificity-for-utilities
11
12
  );
12
13
 
13
14
  // container
@@ -16,7 +17,7 @@
16
17
 
17
18
  @each $breakpoint, $value in $breakpoints {
18
19
  @if $value > 0 {
19
- @include media-breakpoint-up($breakpoint) {
20
+ @include media-breakpoint-up($breakpoint, $breakpoints) {
20
21
  max-width: $value;
21
22
  }
22
23
  }
@@ -34,79 +35,87 @@
34
35
  $map: $columns,
35
36
  $class: columns,
36
37
  $attribute: column-count,
37
- $bps: $breakpoints
38
+ $bps: $breakpoints,
39
+ $zero-specificity: $zero-specificity-for-utilities
38
40
  );
39
41
 
40
42
  // break-after
41
43
  @include spread-map-into-utilities(
42
44
  $map: $break-after,
43
45
  $class: break-after,
44
- $attribute: break-after
46
+ $attribute: break-after,
47
+ $zero-specificity: $zero-specificity-for-utilities
45
48
  );
46
49
 
47
50
  // break-before
48
51
  @include spread-map-into-utilities(
49
52
  $map: $break-before,
50
53
  $class: break-before,
51
- $attribute: break-before
54
+ $attribute: break-before,
55
+ $zero-specificity: $zero-specificity-for-utilities
52
56
  );
53
57
 
54
58
  // break-inside
55
59
  @include spread-map-into-utilities(
56
60
  $map: $break-inside,
57
61
  $class: break-inside,
58
- $attribute: break-inside
62
+ $attribute: break-inside,
63
+ $zero-specificity: $zero-specificity-for-utilities
59
64
  );
60
65
 
61
66
  // display
62
67
  @include spread-map-into-utilities(
63
68
  $map: $display-without-breakpoints,
64
- $attribute: display
69
+ $attribute: display,
70
+ $zero-specificity: $zero-specificity-for-utilities
65
71
  );
66
72
 
67
73
  @include spread-map-into-utilities(
68
74
  $map: $display-with-breakpoints,
69
75
  $attribute: display,
70
- $bps: $breakpoints
76
+ $bps: $breakpoints,
77
+ $zero-specificity: $zero-specificity-for-utilities
71
78
  );
72
79
 
73
80
  // object-fit
74
81
  @include spread-map-into-utilities(
75
82
  $map: $object-fit,
76
83
  $class: object,
77
- $attribute: object-fit
84
+ $attribute: object-fit,
85
+ $zero-specificity: $zero-specificity-for-utilities
78
86
  );
79
87
 
80
88
  // object-position
81
89
  @include spread-map-into-utilities(
82
90
  $map: $object-position,
83
91
  $class: object,
84
- $attribute: object-position
92
+ $attribute: object-position,
93
+ $zero-specificity: $zero-specificity-for-utilities
85
94
  );
86
95
 
87
96
  // overflow
88
- @each $overflow in (auto, hidden, clip, visible, scroll) {
89
- %overflow-#{$overflow} {
90
- overflow: #{$overflow};
97
+ @each $key, $value in $overflow {
98
+ %overflow-#{$key} {
99
+ overflow: #{$value};
91
100
  }
92
101
 
93
102
  @include wrap-with-where(
94
- $selector: '.overflow-#{$overflow}',
103
+ $selector: '.overflow-#{$key}',
95
104
  $enabled: $zero-specificity-for-utilities
96
105
  ) {
97
- @extend %overflow-#{$overflow};
106
+ @extend %overflow-#{$key};
98
107
  }
99
108
 
100
109
  @each $prefix in (x, y) {
101
- %overflow-#{$prefix}-#{$overflow} {
102
- overflow-#{$prefix}: #{$overflow};
110
+ %overflow-#{$prefix}-#{$key} {
111
+ overflow-#{$prefix}: #{$value};
103
112
  }
104
113
 
105
114
  @include wrap-with-where(
106
- $selector: '.overflow-#{$prefix}-#{$overflow}',
115
+ $selector: '.overflow-#{$prefix}-#{$key}',
107
116
  $enabled: $zero-specificity-for-utilities
108
117
  ) {
109
- @extend %overflow-#{$prefix}-#{$overflow};
118
+ @extend %overflow-#{$prefix}-#{$key};
110
119
  }
111
120
  }
112
121
  }
@@ -115,22 +124,29 @@
115
124
  @include spread-map-into-utilities(
116
125
  $map: $position,
117
126
  $attribute: position,
118
- $bps: $breakpoints
127
+ $bps: $breakpoints,
128
+ $zero-specificity: $zero-specificity-for-utilities
119
129
  );
120
130
 
121
131
  // visibility
122
132
  @include spread-map-into-utilities(
123
133
  $map: $visibility,
124
134
  $attribute: visibility,
125
- $bps: $breakpoints
135
+ $bps: $breakpoints,
136
+ $zero-specificity: $zero-specificity-for-utilities
126
137
  );
127
138
 
128
139
  // top / right / bottom / left
129
- @each $size, $value in map.merge($spacing, $spacing-dynamic) {
130
- // check if value is not a map (spacing-dynamic)
131
- $var: var(--spacing-#{$size});
132
- @if type-of($value) != 'map' {
133
- $var: var(--spacing-#{$size}, #{$value});
140
+ @each $size,
141
+ $value in map.merge($placement, map.merge($spacing, $spacing-dynamic))
142
+ {
143
+ $var: $value;
144
+ @if not map-has-key($placement, $size) {
145
+ // check if value is not a map (spacing-dynamic)
146
+ $var: var(--spacing-#{$size});
147
+ @if type-of($value) != 'map' {
148
+ $var: var(--spacing-#{$size}, #{$value});
149
+ }
134
150
  }
135
151
 
136
152
  // all
@@ -185,5 +201,6 @@
185
201
  $map: $z-index,
186
202
  $class: z,
187
203
  $attribute: z-index,
188
- $prop: z
204
+ $prop: z,
205
+ $zero-specificity: $zero-specificity-for-utilities
189
206
  );
@@ -1,27 +1,18 @@
1
1
  @use 'sass:map';
2
- @import '../context';
2
+ @use '../context' as *;
3
3
 
4
4
  // width / height / max-width / max-height
5
- @each $dimension,
6
- $attr in(w: width, h: height, max-w: max-width, max-h: max-height)
5
+ @each $class,
6
+ $attribute in(w: width, h: height, max-w: max-width, max-h: max-height)
7
7
  {
8
- @each $size, $value in map.merge($spacing, $spacing-dynamic) {
9
- // check if value is not a map (spacing-dynamic)
10
- $var: var(--spacing-#{$size});
11
- @if type-of($value) != 'map' {
12
- $var: var(--spacing-#{$size}, #{$value});
13
- }
14
-
15
- %#{$dimension}-#{$size} {
16
- #{$attr}: #{$var};
17
- }
18
- @include wrap-with-where(
19
- $selector: '.#{$dimension}-#{$size}',
20
- $enabled: $zero-specificity-for-utilities
21
- ) {
22
- @extend %#{$dimension}-#{$size};
23
- }
24
- }
8
+ @include spread-map-into-utilities(
9
+ $map: map.merge($spacing, $spacing-dynamic),
10
+ $class: $class,
11
+ $attribute: $attribute,
12
+ $bps: $breakpoints,
13
+ $prop: spacing,
14
+ $zero-specificity: $zero-specificity-for-utilities
15
+ );
25
16
  }
26
17
 
27
18
  @include spread-map-into-utilities(
@@ -29,7 +20,8 @@
29
20
  $class: w,
30
21
  $attribute: width,
31
22
  $bps: $breakpoints,
32
- $prop: w
23
+ $prop: w,
24
+ $zero-specificity: $zero-specificity-for-utilities
33
25
  );
34
26
 
35
27
  @include spread-map-into-utilities(
@@ -37,19 +29,22 @@
37
29
  $class: h,
38
30
  $attribute: height,
39
31
  $bps: $breakpoints,
40
- $prop: h
32
+ $prop: h,
33
+ $zero-specificity: $zero-specificity-for-utilities
41
34
  );
42
35
 
43
36
  @include spread-map-into-utilities(
44
37
  $map: $max-width,
45
38
  $class: max-w,
46
- $attribute: max-width
39
+ $attribute: max-width,
40
+ $zero-specificity: $zero-specificity-for-utilities
47
41
  );
48
42
 
49
43
  @include spread-map-into-utilities(
50
44
  $map: $max-height,
51
45
  $class: max-h,
52
- $attribute: max-height
46
+ $attribute: max-height,
47
+ $zero-specificity: $zero-specificity-for-utilities
53
48
  );
54
49
 
55
50
  @each $breakpoint, $breakpoint-value in $breakpoints {
@@ -70,11 +65,13 @@
70
65
  @include spread-map-into-utilities(
71
66
  $map: $min-width,
72
67
  $class: min-w,
73
- $attribute: min-width
68
+ $attribute: min-width,
69
+ $zero-specificity: $zero-specificity-for-utilities
74
70
  );
75
71
 
76
72
  @include spread-map-into-utilities(
77
73
  $map: $min-height,
78
74
  $class: min-h,
79
- $attribute: min-height
75
+ $attribute: min-height,
76
+ $zero-specificity: $zero-specificity-for-utilities
80
77
  );
@@ -1,5 +1,5 @@
1
1
  @use 'sass:map';
2
- @import '../context';
2
+ @use '../context' as *;
3
3
 
4
4
  @each $prefix, $prop in (m: margin, p: padding, n: margin) {
5
5
  @each $size, $value in map.merge($spacing, $spacing-dynamic) {
@@ -0,0 +1,15 @@
1
+ @import '../context';
2
+
3
+ // border-collapse
4
+ @include spread-map-into-utilities(
5
+ $map: $border-collapse,
6
+ $class: border,
7
+ $attribute: border-collapse
8
+ );
9
+
10
+ // table-layout
11
+ @include spread-map-into-utilities(
12
+ $map: $table-layout,
13
+ $class: table,
14
+ $attribute: table-layout
15
+ );