@nuvoui/core 1.3.0 → 1.3.1
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/dist/nuvoui.css +230 -922
- package/dist/nuvoui.css.map +1 -1
- package/dist/nuvoui.min.css +1 -1
- package/dist/nuvoui.min.css.map +1 -1
- package/package.json +2 -2
- package/src/styles/abstracts/_config.scss +25 -2
- package/src/styles/abstracts/_functions.scss +16 -5
- package/src/styles/base/_base.scss +2 -2
- package/src/styles/base/_reset.scss +0 -2
- package/src/styles/build.scss +3 -0
- package/src/styles/layouts/_container.scss +8 -1
- package/src/styles/layouts/_flex.scss +125 -207
- package/src/styles/layouts/_grid.scss +16 -29
- package/src/styles/themes/_theme.scss +10 -10
- package/src/styles/utilities/_alignment.scss +2 -1
- package/src/styles/utilities/_animations.scss +20 -32
- package/src/styles/utilities/_backdrop-filters.scss +7 -11
- package/src/styles/utilities/_borders.scss +3 -5
- package/src/styles/utilities/_container-queries.scss +17 -21
- package/src/styles/utilities/_cursor.scss +2 -1
- package/src/styles/utilities/_display.scss +17 -37
- package/src/styles/utilities/_helpers.scss +1 -0
- package/src/styles/utilities/_media-queries.scss +3 -5
- package/src/styles/utilities/_opacity.scss +52 -67
- package/src/styles/utilities/_position.scss +104 -132
- package/src/styles/utilities/_shadows.scss +9 -14
- package/src/styles/utilities/_sizing.scss +1 -1
- package/src/styles/utilities/_spacing.scss +143 -205
- package/src/styles/utilities/_tooltips.scss +203 -200
- package/src/styles/utilities/_transforms.scss +9 -11
- package/src/styles/utilities/_transitions.scss +8 -10
- package/src/styles/utilities/_typography.scss +17 -22
- package/src/styles/utilities/_z-index.scss +12 -19
|
@@ -4,138 +4,110 @@
|
|
|
4
4
|
@use "../abstracts/config" as VAR;
|
|
5
5
|
@use "../abstracts/functions" as FN;
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
* - space-y-{size}: Vertical space between children
|
|
62
|
-
*
|
|
63
|
-
* @responsive
|
|
64
|
-
* All spacing classes support responsive variants using @breakpoint suffix:
|
|
65
|
-
* - p-4@md: 1rem padding on medium screens and up
|
|
66
|
-
* - mt-8@lg: 2rem top margin on large screens
|
|
67
|
-
* - gap-2@xl: 0.5rem gap on extra large screens
|
|
68
|
-
*
|
|
69
|
-
* @customization
|
|
70
|
-
* Spacing values are defined in the $spacings map in variables.scss
|
|
71
|
-
* Typically follows a scale where higher numbers mean more spacing
|
|
72
|
-
*
|
|
73
|
-
* @see flex, grid, display
|
|
74
|
-
*/
|
|
7
|
+
// @component Spacing
|
|
8
|
+
// @description Controls element margins, padding, gaps, and spacing between children
|
|
9
|
+
// @example
|
|
10
|
+
// <!-- Padding -->
|
|
11
|
+
// <div class="p-4">All sides padding</div>
|
|
12
|
+
// <div class="px-4 py-2">Horizontal and vertical padding</div>
|
|
13
|
+
// <div class="pt-2 pb-4">Top and bottom padding</div>
|
|
14
|
+
// <!-- Margins -->
|
|
15
|
+
// <div class="m-4">All sides margin</div>
|
|
16
|
+
// <div class="mt-4">Top margin only</div>
|
|
17
|
+
// <div class="mx-auto">Horizontally centered</div>
|
|
18
|
+
// <!-- Gap (for flex/grid containers) -->
|
|
19
|
+
// <div class="flex gap-4">
|
|
20
|
+
// <div>Item 1</div>
|
|
21
|
+
// <div>Item 2</div>
|
|
22
|
+
// </div>
|
|
23
|
+
// <!-- Responsive spacing -->
|
|
24
|
+
// <div class="p-2 p-4@md p-6@lg">
|
|
25
|
+
// Padding increases at each breakpoint
|
|
26
|
+
// </div>
|
|
27
|
+
// <!-- Child spacing -->
|
|
28
|
+
// <div class="space-y-4">
|
|
29
|
+
// <div>First child</div>
|
|
30
|
+
// <div>Second child (margin-top: 1rem)</div>
|
|
31
|
+
// <div>Third child (margin-top: 1rem)</div>
|
|
32
|
+
// </div>
|
|
33
|
+
// @classes
|
|
34
|
+
// Padding:
|
|
35
|
+
// - p-{size}: Padding on all sides
|
|
36
|
+
// - px-{size}: Horizontal padding (left and right)
|
|
37
|
+
// - py-{size}: Vertical padding (top and bottom)
|
|
38
|
+
// - pt-{size}, pr-{size}, pb-{size}, pl-{size}: Individual side padding
|
|
39
|
+
// Margin:
|
|
40
|
+
// - m-{size}: Margin on all sides
|
|
41
|
+
// - mx-{size}: Horizontal margin (left and right)
|
|
42
|
+
// - my-{size}: Vertical margin (top and bottom)
|
|
43
|
+
// - mt-{size}, mr-{size}, mb-{size}, ml-{size}: Individual side margin
|
|
44
|
+
// - mx-auto, ml-auto, mr-auto: Auto margin for alignment
|
|
45
|
+
// Gap:
|
|
46
|
+
// - gap-{size}: Gap between flex/grid children (all directions)
|
|
47
|
+
// - gap-x-{size}: Horizontal gap between children (column-gap)
|
|
48
|
+
// - gap-y-{size}: Vertical gap between children (row-gap)
|
|
49
|
+
// Child Spacing:
|
|
50
|
+
// - space-x-{size}: Horizontal space between children
|
|
51
|
+
// - space-y-{size}: Vertical space between children
|
|
52
|
+
// @responsive
|
|
53
|
+
// All spacing classes support responsive variants using @breakpoint suffix:
|
|
54
|
+
// - p-4@md: 1rem padding on medium screens and up
|
|
55
|
+
// - mt-8@lg: 2rem top margin on large screens
|
|
56
|
+
// - gap-2@xl: 0.5rem gap on extra large screens
|
|
57
|
+
// @customization
|
|
58
|
+
// Spacing values are defined in the $spacings map in variables.scss
|
|
59
|
+
// Typically follows a scale where higher numbers mean more spacing
|
|
60
|
+
// @see flex, grid, display
|
|
75
61
|
|
|
76
62
|
// -----------------------------------------------
|
|
77
63
|
// PADDING MIXINS
|
|
78
64
|
// -----------------------------------------------
|
|
79
65
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
* @param {Number|String} $val - Padding value
|
|
84
|
-
*/
|
|
66
|
+
// @mixin p
|
|
67
|
+
// @description Sets padding on all sides
|
|
68
|
+
// @param {Number|String} $val - Padding value
|
|
85
69
|
@mixin p($val) {
|
|
86
70
|
padding: FN.fix-units($val);
|
|
87
71
|
}
|
|
88
72
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
* @param {Number|String} $val - Padding value
|
|
93
|
-
*/
|
|
73
|
+
// @mixin px
|
|
74
|
+
// @description Sets horizontal padding (left and right)
|
|
75
|
+
// @param {Number|String} $val - Padding value
|
|
94
76
|
@mixin px($val) {
|
|
95
77
|
padding-inline: FN.fix-units($val);
|
|
96
78
|
}
|
|
97
79
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
* @param {Number|String} $val - Padding value
|
|
102
|
-
*/
|
|
80
|
+
// @mixin py
|
|
81
|
+
// @description Sets vertical padding (top and bottom)
|
|
82
|
+
// @param {Number|String} $val - Padding value
|
|
103
83
|
@mixin py($val) {
|
|
104
84
|
padding-block: FN.fix-units($val);
|
|
105
85
|
}
|
|
106
86
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
* @param {Number|String} $val - Padding value
|
|
111
|
-
*/
|
|
87
|
+
// @mixin pt
|
|
88
|
+
// @description Sets padding-top
|
|
89
|
+
// @param {Number|String} $val - Padding value
|
|
112
90
|
@mixin pt($val) {
|
|
113
91
|
padding-top: FN.fix-units($val);
|
|
114
92
|
}
|
|
115
93
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
* @param {Number|String} $val - Padding value
|
|
120
|
-
*/
|
|
94
|
+
// @mixin pr
|
|
95
|
+
// @description Sets padding-right
|
|
96
|
+
// @param {Number|String} $val - Padding value
|
|
121
97
|
@mixin pr($val) {
|
|
122
98
|
padding-right: FN.fix-units($val);
|
|
123
99
|
}
|
|
124
100
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
* @param {Number|String} $val - Padding value
|
|
129
|
-
*/
|
|
101
|
+
// @mixin pb
|
|
102
|
+
// @description Sets padding-bottom
|
|
103
|
+
// @param {Number|String} $val - Padding value
|
|
130
104
|
@mixin pb($val) {
|
|
131
105
|
padding-bottom: FN.fix-units($val);
|
|
132
106
|
}
|
|
133
107
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
* @param {Number|String} $val - Padding value
|
|
138
|
-
*/
|
|
108
|
+
// @mixin pl
|
|
109
|
+
// @description Sets padding-left
|
|
110
|
+
// @param {Number|String} $val - Padding value
|
|
139
111
|
@mixin pl($val) {
|
|
140
112
|
padding-left: FN.fix-units($val);
|
|
141
113
|
}
|
|
@@ -144,91 +116,71 @@
|
|
|
144
116
|
// MARGIN MIXINS
|
|
145
117
|
// -----------------------------------------------
|
|
146
118
|
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
* @param {Number|String} $val - Margin value
|
|
151
|
-
*/
|
|
119
|
+
// @mixin m
|
|
120
|
+
// @description Sets margin on all sides
|
|
121
|
+
// @param {Number|String} $val - Margin value
|
|
152
122
|
@mixin m($val) {
|
|
153
123
|
margin: FN.fix-units($val);
|
|
154
124
|
}
|
|
155
125
|
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
* @param {Number|String} $val - Margin value
|
|
160
|
-
*/
|
|
126
|
+
// @mixin mx
|
|
127
|
+
// @description Sets horizontal margin (left and right)
|
|
128
|
+
// @param {Number|String} $val - Margin value
|
|
161
129
|
@mixin mx($val) {
|
|
162
130
|
margin-inline: FN.fix-units($val);
|
|
163
131
|
}
|
|
164
132
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
* @param {Number|String} $val - Margin value
|
|
169
|
-
*/
|
|
133
|
+
// @mixin my
|
|
134
|
+
// @description Sets vertical margin (top and bottom)
|
|
135
|
+
// @param {Number|String} $val - Margin value
|
|
170
136
|
@mixin my($val) {
|
|
171
137
|
$val: FN.fix-units($val);
|
|
172
138
|
|
|
173
139
|
margin-block: FN.fix-units($val);
|
|
174
140
|
}
|
|
175
141
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
* @param {Number|String} $val - Margin value
|
|
180
|
-
*/
|
|
142
|
+
// @mixin mt
|
|
143
|
+
// @description Sets margin-top
|
|
144
|
+
// @param {Number|String} $val - Margin value
|
|
181
145
|
@mixin mt($val) {
|
|
182
146
|
margin-top: FN.fix-units($val, VAR.$default-unit);
|
|
183
147
|
}
|
|
184
148
|
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
* @param {Number|String} $val - Margin value
|
|
189
|
-
*/
|
|
149
|
+
// @mixin mr
|
|
150
|
+
// @description Sets margin-right
|
|
151
|
+
// @param {Number|String} $val - Margin value
|
|
190
152
|
@mixin mr($val) {
|
|
191
153
|
margin-right: FN.fix-units($val);
|
|
192
154
|
}
|
|
193
155
|
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
* @param {Number|String} $val - Margin value
|
|
198
|
-
*/
|
|
156
|
+
// @mixin mb
|
|
157
|
+
// @description Sets margin-bottom
|
|
158
|
+
// @param {Number|String} $val - Margin value
|
|
199
159
|
@mixin mb($val) {
|
|
200
160
|
margin-bottom: FN.fix-units($val);
|
|
201
161
|
}
|
|
202
162
|
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
* @param {Number|String} $val - Margin value
|
|
207
|
-
*/
|
|
163
|
+
// @mixin ml
|
|
164
|
+
// @description Sets margin-left
|
|
165
|
+
// @param {Number|String} $val - Margin value
|
|
208
166
|
@mixin ml($val) {
|
|
209
167
|
margin-left: FN.fix-units($val);
|
|
210
168
|
}
|
|
211
169
|
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
* @description Sets margin-left to auto
|
|
215
|
-
*/
|
|
170
|
+
// @mixin ml-auto
|
|
171
|
+
// @description Sets margin-left to auto
|
|
216
172
|
@mixin ml-auto {
|
|
217
173
|
margin-left: auto;
|
|
218
174
|
}
|
|
219
175
|
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
* @description Sets margin-right to auto
|
|
223
|
-
*/
|
|
176
|
+
// @mixin mr-auto
|
|
177
|
+
// @description Sets margin-right to auto
|
|
224
178
|
@mixin mr-auto {
|
|
225
179
|
margin-right: auto;
|
|
226
180
|
}
|
|
227
181
|
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
* @description Centers element horizontally using auto margins
|
|
231
|
-
*/
|
|
182
|
+
// @mixin mx-auto
|
|
183
|
+
// @description Centers element horizontally using auto margins
|
|
232
184
|
@mixin mx-auto {
|
|
233
185
|
@include ml-auto;
|
|
234
186
|
@include mr-auto;
|
|
@@ -238,22 +190,18 @@
|
|
|
238
190
|
// INSET MIXINS
|
|
239
191
|
// -----------------------------------------------
|
|
240
192
|
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
* @param {Number|String} $val - Inset value
|
|
245
|
-
*/
|
|
193
|
+
// @mixin inset
|
|
194
|
+
// @description Sets all inset properties (top, right, bottom, left)
|
|
195
|
+
// @param {Number|String} $val - Inset value
|
|
246
196
|
@mixin inset($val) {
|
|
247
197
|
$val: FN.fix-units($val);
|
|
248
198
|
|
|
249
199
|
inset: FN.fix-units($val);
|
|
250
200
|
}
|
|
251
201
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
* @param {Number|String} $val - Inset value
|
|
256
|
-
*/
|
|
202
|
+
// @mixin inset-x
|
|
203
|
+
// @description Sets horizontal inset properties (left and right)
|
|
204
|
+
// @param {Number|String} $val - Inset value
|
|
257
205
|
@mixin inset-x($val) {
|
|
258
206
|
$val: FN.fix-units($val);
|
|
259
207
|
|
|
@@ -261,11 +209,9 @@
|
|
|
261
209
|
right: $val;
|
|
262
210
|
}
|
|
263
211
|
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
* @param {Number|String} $val - Inset value
|
|
268
|
-
*/
|
|
212
|
+
// @mixin inset-y
|
|
213
|
+
// @description Sets vertical inset properties (top and bottom)
|
|
214
|
+
// @param {Number|String} $val - Inset value
|
|
269
215
|
@mixin inset-y($val) {
|
|
270
216
|
$val: FN.fix-units($val);
|
|
271
217
|
|
|
@@ -273,27 +219,21 @@
|
|
|
273
219
|
bottom: $val;
|
|
274
220
|
}
|
|
275
221
|
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
* @description Sets all inset properties to auto
|
|
279
|
-
*/
|
|
222
|
+
// @mixin inset-auto
|
|
223
|
+
// @description Sets all inset properties to auto
|
|
280
224
|
@mixin inset-auto {
|
|
281
225
|
inset: auto;
|
|
282
226
|
}
|
|
283
227
|
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
* @description Sets horizontal inset properties to auto
|
|
287
|
-
*/
|
|
228
|
+
// @mixin inset-x-auto
|
|
229
|
+
// @description Sets horizontal inset properties to auto
|
|
288
230
|
@mixin inset-x-auto {
|
|
289
231
|
left: auto;
|
|
290
232
|
right: auto;
|
|
291
233
|
}
|
|
292
234
|
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
* @description Sets vertical inset properties to auto
|
|
296
|
-
*/
|
|
235
|
+
// @mixin inset-y-auto
|
|
236
|
+
// @description Sets vertical inset properties to auto
|
|
297
237
|
@mixin inset-y-auto {
|
|
298
238
|
top: auto;
|
|
299
239
|
bottom: auto;
|
|
@@ -303,22 +243,18 @@
|
|
|
303
243
|
// SPACING MIXINS
|
|
304
244
|
// -----------------------------------------------
|
|
305
245
|
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
* @param {Number|String} $i - Space amount
|
|
310
|
-
*/
|
|
246
|
+
// @mixin space-y
|
|
247
|
+
// @description Adds vertical spacing between direct children
|
|
248
|
+
// @param {Number|String} $i - Space amount
|
|
311
249
|
@mixin space-y($i) {
|
|
312
250
|
& > * + * {
|
|
313
251
|
margin-top: FN.fix-units($i);
|
|
314
252
|
}
|
|
315
253
|
}
|
|
316
254
|
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
* @param {Number|String} $i - Space amount
|
|
321
|
-
*/
|
|
255
|
+
// @mixin space-x
|
|
256
|
+
// @description Adds horizontal spacing between direct children
|
|
257
|
+
// @param {Number|String} $i - Space amount
|
|
322
258
|
@mixin space-x($i) {
|
|
323
259
|
& > * + * {
|
|
324
260
|
margin-left: FN.fix-units($i);
|
|
@@ -329,34 +265,36 @@
|
|
|
329
265
|
// GAP MIXINS
|
|
330
266
|
// -----------------------------------------------
|
|
331
267
|
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
* @param {Number|String} $val - Gap value
|
|
336
|
-
*/
|
|
268
|
+
// @mixin gap
|
|
269
|
+
// @description Sets gap between grid/flex children
|
|
270
|
+
// @param {Number|String} $val - Gap value
|
|
337
271
|
@mixin gap($val) {
|
|
338
|
-
|
|
272
|
+
$val: FN.fix-units($val);
|
|
273
|
+
|
|
274
|
+
gap: $val;
|
|
275
|
+
|
|
276
|
+
--flex-gap: #{$val};
|
|
339
277
|
}
|
|
340
278
|
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
* @param {Number|String} $val - Gap value
|
|
345
|
-
*/
|
|
279
|
+
// @mixin gap-x
|
|
280
|
+
// @description Sets horizontal gap between grid/flex children
|
|
281
|
+
// @param {Number|String} $val - Gap value
|
|
346
282
|
@mixin gap-x($val) {
|
|
347
|
-
|
|
283
|
+
$val: FN.fix-units($val);
|
|
284
|
+
|
|
285
|
+
column-gap: $val;
|
|
286
|
+
|
|
287
|
+
--flex-gap: #{$val};
|
|
348
288
|
}
|
|
349
289
|
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
* @param {Number|String} $val - Gap value
|
|
354
|
-
*/
|
|
290
|
+
// @mixin gap-y
|
|
291
|
+
// @description Sets vertical gap between grid/flex children
|
|
292
|
+
// @param {Number|String} $val - Gap value
|
|
355
293
|
@mixin gap-y($val) {
|
|
356
294
|
row-gap: FN.fix-units($val);
|
|
357
295
|
}
|
|
358
296
|
|
|
359
|
-
@if
|
|
297
|
+
@if FN.feature-enabled("spacing") {
|
|
360
298
|
// -----------------------------------------------
|
|
361
299
|
// AUTO MARGIN UTILITY CLASSES
|
|
362
300
|
// -----------------------------------------------
|