@nuvoui/core 1.2.0 → 1.2.2
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/README.md +96 -73
- package/dist/nuvoui.css +3924 -545
- 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 +1 -1
- package/src/styles/abstracts/_config.scss +18 -36
- package/src/styles/layouts/_container.scss +6 -3
- package/src/styles/layouts/_flex.scss +169 -153
- package/src/styles/layouts/_grid.scss +69 -67
- package/src/styles/mixins-map.scss +1 -913
- package/src/styles/themes/_theme.scss +96 -94
- package/src/styles/utilities/_alignment.scss +12 -10
- package/src/styles/utilities/_animations.scss +58 -1
- package/src/styles/utilities/_borders.scss +219 -193
- package/src/styles/utilities/_colors.scss +3 -3
- package/src/styles/utilities/_container-queries.scss +13 -11
- package/src/styles/utilities/_display.scss +57 -55
- package/src/styles/utilities/_media-queries.scss +22 -3
- package/src/styles/utilities/_opacity.scss +49 -43
- package/src/styles/utilities/_position.scss +76 -30
- package/src/styles/utilities/_shadows.scss +105 -99
- package/src/styles/utilities/_sizing.scss +53 -51
- package/src/styles/utilities/_spacing.scss +172 -108
- package/src/styles/utilities/_transforms.scss +221 -0
- package/src/styles/utilities/_transitions.scss +81 -75
- package/src/styles/utilities/_typography.scss +141 -67
|
@@ -32,65 +32,67 @@
|
|
|
32
32
|
@mixin w-screen { & { width: 100vw; } }
|
|
33
33
|
@mixin h-screen { & { height: 100dvh; } }
|
|
34
34
|
|
|
35
|
-
|
|
36
|
-
.
|
|
35
|
+
@if VAR.$generate-utility-classes {
|
|
36
|
+
.w-screen { @include w-screen; }
|
|
37
|
+
.h-screen { @include h-screen; }
|
|
37
38
|
|
|
38
|
-
// Width utilities need :not(.flex) to avoid conflicts with flex child sizing
|
|
39
|
-
:not(.flex)>.w-auto { @include w-auto; }
|
|
40
|
-
:not(.flex)>.w-full { @include w-full; }
|
|
39
|
+
// Width utilities need :not(.flex) to avoid conflicts with flex child sizing
|
|
40
|
+
:not(.flex)>.w-auto { @include w-auto; }
|
|
41
|
+
:not(.flex)>.w-full { @include w-full; }
|
|
41
42
|
|
|
42
|
-
.h-auto { @include h-auto; }
|
|
43
|
-
.h-full { @include h-full; }
|
|
44
|
-
.min-w-full { @include min-w-full; }
|
|
45
|
-
.max-w-full { @include max-w-full; }
|
|
46
|
-
.min-h-full { @include min-h-full; }
|
|
47
|
-
.max-h-full { @include max-h-full; }
|
|
43
|
+
.h-auto { @include h-auto; }
|
|
44
|
+
.h-full { @include h-full; }
|
|
45
|
+
.min-w-full { @include min-w-full; }
|
|
46
|
+
.max-w-full { @include max-w-full; }
|
|
47
|
+
.min-h-full { @include min-h-full; }
|
|
48
|
+
.max-h-full { @include max-h-full; }
|
|
48
49
|
|
|
49
|
-
// Percentage widths
|
|
50
|
-
@each $i in VAR.$percentages {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
}
|
|
50
|
+
// Percentage widths
|
|
51
|
+
@each $i in VAR.$percentages {
|
|
52
|
+
.w-#{$i}p { @include width-percent($i); }
|
|
53
|
+
.h-#{$i}p { @include height-percent($i); }
|
|
54
|
+
.min-w-#{$i}p { @include min-width-percent($i); }
|
|
55
|
+
.min-h-#{$i}p { @include min-height-percent($i); }
|
|
56
|
+
.max-w-#{$i}p { @include max-width-percent($i); }
|
|
57
|
+
.max-h-#{$i}p { @include max-height-percent($i); }
|
|
58
|
+
}
|
|
58
59
|
|
|
59
|
-
// Generate utilities from spacing map
|
|
60
|
-
@each $key, $value in VAR.$spacings {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}
|
|
60
|
+
// Generate utilities from spacing map
|
|
61
|
+
@each $key, $value in VAR.$spacings {
|
|
62
|
+
.w-#{$key} { @include width($value); }
|
|
63
|
+
.h-#{$key} { @include height($value); }
|
|
64
|
+
.min-w-#{$key} { @include min-width($value); }
|
|
65
|
+
.min-h-#{$key} { @include min-height($value); }
|
|
66
|
+
.max-w-#{$key} { @include max-width($value); }
|
|
67
|
+
.max-h-#{$key} { @include max-height($value); }
|
|
68
|
+
}
|
|
68
69
|
|
|
69
|
-
// Pixel widths based on spacing scale
|
|
70
|
-
@each $breakpoint, $width in VAR.$breakpoints {
|
|
70
|
+
// Pixel widths based on spacing scale
|
|
71
|
+
@each $breakpoint, $width in VAR.$breakpoints {
|
|
71
72
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
73
|
+
.w-#{$breakpoint} { @include width($width); }
|
|
74
|
+
.min-w-#{$breakpoint} { @include min-width($width); }
|
|
75
|
+
.max-w-#{$breakpoint} { @include max-width($width); }
|
|
75
76
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
77
|
+
@include MQ.media-up ($breakpoint) {
|
|
78
|
+
// Generate utilities from spacing map
|
|
79
|
+
@each $i in VAR.$percentages {
|
|
80
|
+
.w-#{$i}p\@#{$breakpoint} { @include width-percent($i); }
|
|
81
|
+
.h-#{$i}p\@#{$breakpoint} { @include height-percent($i); }
|
|
82
|
+
.min-w-#{$i}p\@#{$breakpoint} { @include min-width-percent($i); }
|
|
83
|
+
.min-h-#{$i}p\@#{$breakpoint} { @include min-height-percent($i); }
|
|
84
|
+
.max-w-#{$i}p\@#{$breakpoint} { @include max-width-percent($i); }
|
|
85
|
+
.max-h-#{$i}p\@#{$breakpoint} { @include max-height-percent($i); }
|
|
86
|
+
}
|
|
86
87
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
88
|
+
@each $key, $value in VAR.$spacings {
|
|
89
|
+
.w-#{$key}\@#{$breakpoint} { @include width($value); }
|
|
90
|
+
.h-#{$key}\@#{$breakpoint} { @include height($value); }
|
|
91
|
+
.min-w-#{$key}\@#{$breakpoint} { @include min-width($value); }
|
|
92
|
+
.min-h-#{$key}\@#{$breakpoint} { @include min-height($value); }
|
|
93
|
+
.max-w-#{$key}\@#{$breakpoint} { @include max-width($value); }
|
|
94
|
+
.max-h-#{$key}\@#{$breakpoint} { @include max-height($value); }
|
|
95
|
+
}
|
|
94
96
|
}
|
|
95
97
|
}
|
|
96
98
|
}
|
|
@@ -126,9 +126,11 @@
|
|
|
126
126
|
*/
|
|
127
127
|
@mixin px($val) {
|
|
128
128
|
$val: format-unit-value($val);
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
129
|
+
|
|
130
|
+
& {
|
|
131
|
+
padding-left: $val;
|
|
132
|
+
padding-right: $val;
|
|
133
|
+
}
|
|
132
134
|
}
|
|
133
135
|
|
|
134
136
|
/**
|
|
@@ -138,38 +140,64 @@
|
|
|
138
140
|
*/
|
|
139
141
|
@mixin py($val) {
|
|
140
142
|
$val: format-unit-value($val);
|
|
141
|
-
|
|
142
|
-
padding-top: $val;
|
|
143
|
-
padding-bottom: $val;
|
|
144
|
-
}
|
|
145
143
|
|
|
144
|
+
& {
|
|
145
|
+
padding-top: $val;
|
|
146
|
+
padding-bottom: $val;
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
146
150
|
/**
|
|
147
151
|
* @mixin pt
|
|
148
152
|
* @description Sets padding-top
|
|
149
153
|
* @param {Number|String} $val - Padding value
|
|
150
154
|
*/
|
|
151
|
-
@mixin pt($val) {
|
|
155
|
+
@mixin pt($val) {
|
|
156
|
+
& {
|
|
157
|
+
$val: format-unit-value($val);
|
|
158
|
+
|
|
159
|
+
padding-top: $val;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
152
162
|
|
|
153
163
|
/**
|
|
154
164
|
* @mixin pr
|
|
155
165
|
* @description Sets padding-right
|
|
156
166
|
* @param {Number|String} $val - Padding value
|
|
157
167
|
*/
|
|
158
|
-
@mixin pr($val) {
|
|
168
|
+
@mixin pr($val) {
|
|
169
|
+
& {
|
|
170
|
+
$val: format-unit-value($val);
|
|
171
|
+
|
|
172
|
+
padding-right: $val;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
159
175
|
|
|
160
176
|
/**
|
|
161
177
|
* @mixin pb
|
|
162
178
|
* @description Sets padding-bottom
|
|
163
179
|
* @param {Number|String} $val - Padding value
|
|
164
180
|
*/
|
|
165
|
-
@mixin pb($val) {
|
|
181
|
+
@mixin pb($val) {
|
|
182
|
+
& {
|
|
183
|
+
$val: format-unit-value($val);
|
|
184
|
+
|
|
185
|
+
padding-bottom: $val;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
166
188
|
|
|
167
189
|
/**
|
|
168
190
|
* @mixin pl
|
|
169
191
|
* @description Sets padding-left
|
|
170
192
|
* @param {Number|String} $val - Padding value
|
|
171
193
|
*/
|
|
172
|
-
@mixin pl($val) {
|
|
194
|
+
@mixin pl($val) {
|
|
195
|
+
& {
|
|
196
|
+
$val: format-unit-value($val);
|
|
197
|
+
|
|
198
|
+
padding-left: $val;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
173
201
|
|
|
174
202
|
// -----------------------------------------------
|
|
175
203
|
// MARGIN MIXINS
|
|
@@ -180,7 +208,13 @@
|
|
|
180
208
|
* @description Sets margin on all sides
|
|
181
209
|
* @param {Number|String} $val - Margin value
|
|
182
210
|
*/
|
|
183
|
-
@mixin m($val) {
|
|
211
|
+
@mixin m($val) {
|
|
212
|
+
& {
|
|
213
|
+
$val: format-unit-value($val);
|
|
214
|
+
|
|
215
|
+
margin: $val;
|
|
216
|
+
}
|
|
217
|
+
}
|
|
184
218
|
|
|
185
219
|
/**
|
|
186
220
|
* @mixin mx
|
|
@@ -189,9 +223,11 @@
|
|
|
189
223
|
*/
|
|
190
224
|
@mixin mx($val) {
|
|
191
225
|
$val: format-unit-value($val);
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
226
|
+
|
|
227
|
+
& {
|
|
228
|
+
margin-left: $val;
|
|
229
|
+
margin-right: $val;
|
|
230
|
+
}
|
|
195
231
|
}
|
|
196
232
|
|
|
197
233
|
/**
|
|
@@ -202,8 +238,10 @@
|
|
|
202
238
|
@mixin my($val) {
|
|
203
239
|
$val: format-unit-value($val);
|
|
204
240
|
|
|
205
|
-
|
|
206
|
-
|
|
241
|
+
&{
|
|
242
|
+
margin-top: $val;
|
|
243
|
+
margin-bottom: $val;
|
|
244
|
+
}
|
|
207
245
|
}
|
|
208
246
|
|
|
209
247
|
/**
|
|
@@ -211,40 +249,64 @@
|
|
|
211
249
|
* @description Sets margin-top
|
|
212
250
|
* @param {Number|String} $val - Margin value
|
|
213
251
|
*/
|
|
214
|
-
@mixin mt($val) {
|
|
252
|
+
@mixin mt($val) {
|
|
253
|
+
& {
|
|
254
|
+
$val: format-unit-value($val);
|
|
255
|
+
|
|
256
|
+
margin-top: $val;
|
|
257
|
+
}
|
|
258
|
+
}
|
|
215
259
|
|
|
216
260
|
/**
|
|
217
261
|
* @mixin mr
|
|
218
262
|
* @description Sets margin-right
|
|
219
263
|
* @param {Number|String} $val - Margin value
|
|
220
264
|
*/
|
|
221
|
-
@mixin mr($val) {
|
|
265
|
+
@mixin mr($val) {
|
|
266
|
+
& {
|
|
267
|
+
$val: format-unit-value($val);
|
|
268
|
+
|
|
269
|
+
margin-right: $val;
|
|
270
|
+
}
|
|
271
|
+
}
|
|
222
272
|
|
|
223
273
|
/**
|
|
224
274
|
* @mixin mb
|
|
225
275
|
* @description Sets margin-bottom
|
|
226
276
|
* @param {Number|String} $val - Margin value
|
|
227
277
|
*/
|
|
228
|
-
@mixin mb($val) {
|
|
278
|
+
@mixin mb($val) {
|
|
279
|
+
& {
|
|
280
|
+
$val: format-unit-value($val);
|
|
281
|
+
|
|
282
|
+
margin-bottom: $val;
|
|
283
|
+
}
|
|
284
|
+
}
|
|
229
285
|
|
|
230
286
|
/**
|
|
231
287
|
* @mixin ml
|
|
232
288
|
* @description Sets margin-left
|
|
233
289
|
* @param {Number|String} $val - Margin value
|
|
234
290
|
*/
|
|
235
|
-
@mixin ml($val) {
|
|
291
|
+
@mixin ml($val) {
|
|
292
|
+
& {
|
|
293
|
+
$val: format-unit-value($val);
|
|
294
|
+
|
|
295
|
+
margin-left: $val;
|
|
296
|
+
}
|
|
297
|
+
}
|
|
236
298
|
|
|
237
299
|
/**
|
|
238
300
|
* @mixin ml-auto
|
|
239
301
|
* @description Sets margin-left to auto
|
|
240
302
|
*/
|
|
241
|
-
@mixin ml-auto { margin-left: auto; }
|
|
303
|
+
@mixin ml-auto { & { margin-left: auto; } }
|
|
242
304
|
|
|
243
305
|
/**
|
|
244
306
|
* @mixin mr-auto
|
|
245
307
|
* @description Sets margin-right to auto
|
|
246
308
|
*/
|
|
247
|
-
@mixin mr-auto { margin-right: auto; }
|
|
309
|
+
@mixin mr-auto { & { margin-right: auto; } }
|
|
248
310
|
|
|
249
311
|
/**
|
|
250
312
|
* @mixin mx-auto
|
|
@@ -308,91 +370,93 @@
|
|
|
308
370
|
*/
|
|
309
371
|
@mixin gap-y($val) { $val: format-unit-value($val); row-gap: $val; }
|
|
310
372
|
|
|
311
|
-
|
|
312
|
-
//
|
|
313
|
-
//
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
.
|
|
317
|
-
.
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
//
|
|
321
|
-
//
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
//
|
|
327
|
-
//
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
}
|
|
357
|
-
|
|
373
|
+
@if $generate-utility-classes {
|
|
374
|
+
// -----------------------------------------------
|
|
375
|
+
// AUTO MARGIN UTILITY CLASSES
|
|
376
|
+
// -----------------------------------------------
|
|
377
|
+
|
|
378
|
+
.mx-auto { @include mx-auto; }
|
|
379
|
+
.ml-auto { @include ml-auto; }
|
|
380
|
+
.mr-auto { @include mr-auto; }
|
|
381
|
+
|
|
382
|
+
// -----------------------------------------------
|
|
383
|
+
// GAP AUTO CLASS
|
|
384
|
+
// -----------------------------------------------
|
|
385
|
+
|
|
386
|
+
.gap-auto { gap: auto; }
|
|
387
|
+
|
|
388
|
+
// -----------------------------------------------
|
|
389
|
+
// SPACING CLASSES
|
|
390
|
+
// -----------------------------------------------
|
|
391
|
+
|
|
392
|
+
@each $key, $value in $spacings {
|
|
393
|
+
// Padding classes
|
|
394
|
+
.p-#{$key} { @include p($value); }
|
|
395
|
+
.px-#{$key} { @include px($value); }
|
|
396
|
+
.py-#{$key} { @include py($value); }
|
|
397
|
+
.pt-#{$key} { @include pt($value); }
|
|
398
|
+
.pr-#{$key} { @include pr($value); }
|
|
399
|
+
.pb-#{$key} { @include pb($value); }
|
|
400
|
+
.pl-#{$key} { @include pl($value); }
|
|
401
|
+
|
|
402
|
+
// Margin classes
|
|
403
|
+
.m-#{$key} { @include m($value); }
|
|
404
|
+
.mx-#{$key} { @include mx($value); }
|
|
405
|
+
.my-#{$key} { @include my($value); }
|
|
406
|
+
.mt-#{$key} { @include mt($value); }
|
|
407
|
+
.mr-#{$key} { @include mr($value); }
|
|
408
|
+
.mb-#{$key} { @include mb($value); }
|
|
409
|
+
.ml-#{$key} { @include ml($value); }
|
|
410
|
+
|
|
411
|
+
// Gap classes
|
|
412
|
+
.gap-#{$key} { @include gap($value); }
|
|
413
|
+
.gap-x-#{$key} { @include gap-x($value); }
|
|
414
|
+
.gap-y-#{$key} { @include gap-y($value); }
|
|
415
|
+
|
|
416
|
+
// Space classes
|
|
417
|
+
.space-x-#{$key} { @include space-x($value); }
|
|
418
|
+
.space-y-#{$key} { @include space-y($value); }
|
|
419
|
+
}
|
|
358
420
|
|
|
359
|
-
// -----------------------------------------------
|
|
360
|
-
// RESPONSIVE SPACING CLASSES
|
|
361
|
-
// -----------------------------------------------
|
|
362
421
|
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
422
|
+
// -----------------------------------------------
|
|
423
|
+
// RESPONSIVE SPACING CLASSES
|
|
424
|
+
// -----------------------------------------------
|
|
425
|
+
|
|
426
|
+
@each $breakpoint, $width in $breakpoints {
|
|
427
|
+
@media (min-width: #{$width}) {
|
|
428
|
+
.mx-auto\@#{$breakpoint} { @include mx-auto; }
|
|
429
|
+
.ml-auto\@#{$breakpoint} { @include ml-auto; }
|
|
430
|
+
.mr-auto\@#{$breakpoint} { @include mr-auto; }
|
|
431
|
+
|
|
432
|
+
// Generate utilities from spacing map
|
|
433
|
+
@each $key, $value in $spacings {
|
|
434
|
+
// Padding classes
|
|
435
|
+
.p-#{$key}\@#{$breakpoint} { @include p($value); }
|
|
436
|
+
.px-#{$key}\@#{$breakpoint} { @include px($value); }
|
|
437
|
+
.py-#{$key}\@#{$breakpoint} { @include py($value); }
|
|
438
|
+
.pt-#{$key}\@#{$breakpoint} { @include pt($value); }
|
|
439
|
+
.pr-#{$key}\@#{$breakpoint} { @include pr($value); }
|
|
440
|
+
.pb-#{$key}\@#{$breakpoint} { @include pb($value); }
|
|
441
|
+
.pl-#{$key}\@#{$breakpoint} { @include pl($value); }
|
|
442
|
+
|
|
443
|
+
// Margin classes
|
|
444
|
+
.m-#{$key}\@#{$breakpoint} { @include m($value); }
|
|
445
|
+
.mx-#{$key}\@#{$breakpoint} { @include mx($value); }
|
|
446
|
+
.my-#{$key}\@#{$breakpoint} { @include my($value); }
|
|
447
|
+
.mt-#{$key}\@#{$breakpoint} { @include mt($value); }
|
|
448
|
+
.mr-#{$key}\@#{$breakpoint} { @include mr($value); }
|
|
449
|
+
.mb-#{$key}\@#{$breakpoint} { @include mb($value); }
|
|
450
|
+
.ml-#{$key}\@#{$breakpoint} { @include ml($value); }
|
|
451
|
+
|
|
452
|
+
.gap-#{$key}\@#{$breakpoint} { gap: $value; }
|
|
453
|
+
.gap-x-#{$key}\@#{$breakpoint} { column-gap: $value; }
|
|
454
|
+
.gap-y-#{$key}\@#{$breakpoint} { row-gap: $value; }
|
|
455
|
+
|
|
456
|
+
// Space classes
|
|
457
|
+
.space-x-#{$key}\@#{$breakpoint} { @include space-x($value); }
|
|
458
|
+
.space-y-#{$key}\@#{$breakpoint} { @include space-y($value); }
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
}
|
|
398
462
|
}
|