@appartmint/mint 1.3.2 → 2.0.0
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/css/mint.css +3 -3
- package/dist/css/mint.css.map +1 -1
- package/dist/css/mint.min.css.map +1 -1
- package/dist/css/noscript.css +3 -3
- package/dist/css/noscript.css.map +1 -1
- package/dist/css/noscript.min.css.map +1 -1
- package/dist/js/imports/models/item.d.ts +4 -2
- package/dist/js/imports/models/item.d.ts.map +1 -1
- package/dist/js/imports/util/display.d.ts +1 -1
- package/dist/js/imports/util/display.d.ts.map +1 -1
- package/dist/js/imports/util/object.d.ts +2 -4
- package/dist/js/imports/util/object.d.ts.map +1 -1
- package/dist/js/index.js +1661 -1727
- package/dist/js/index.js.map +1 -1
- package/dist/js/index.min.js +1 -1
- package/dist/js/index.min.js.map +1 -1
- package/package.json +17 -60
- package/src/scss/imports/global/_animations.scss +1 -1
- package/src/scss/imports/global/_global.scss +7 -5
- package/src/scss/imports/global/_text.scss +5 -4
- package/src/scss/imports/util/_util.scss +55 -52
- package/src/scss/imports/util/_vars.scss +5 -2
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@appartmint/mint",
|
|
3
3
|
"author": "App Art Mint LLC",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "2.0.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "The front-end TS/SCSS framework of App Art Mint",
|
|
7
7
|
"keywords": [
|
|
@@ -26,82 +26,39 @@
|
|
|
26
26
|
"src/**/*.scss",
|
|
27
27
|
"dist/**/*.{css,js,d.ts,map}"
|
|
28
28
|
],
|
|
29
|
-
"directories": {
|
|
30
|
-
"dist": "dist",
|
|
31
|
-
"doc": "docs",
|
|
32
|
-
"src": "src",
|
|
33
|
-
"test": "test"
|
|
34
|
-
},
|
|
35
29
|
"publishConfig": {
|
|
36
30
|
"access": "public"
|
|
37
31
|
},
|
|
38
|
-
"config": {
|
|
39
|
-
"dirs": {
|
|
40
|
-
"doc": "docs",
|
|
41
|
-
"src": "src",
|
|
42
|
-
"scss": "scss",
|
|
43
|
-
"dist": "dist"
|
|
44
|
-
},
|
|
45
|
-
"webpack": "node_modules/@appartmint/config/dist/js/webpack.config.min.js"
|
|
46
|
-
},
|
|
47
32
|
"scripts": {
|
|
48
|
-
"upgrade": "npm up -D @appartmint/config && mint-config",
|
|
49
|
-
"prepare": "npm-run-all clean bundle",
|
|
50
33
|
"preversion": "npm i && npm run test",
|
|
51
34
|
"version": "git add -A",
|
|
52
|
-
"postversion": "git push && git push --tags &&
|
|
53
|
-
"
|
|
35
|
+
"postversion": "git push && git push --tags && gh release create v$npm_package_version --generate-notes",
|
|
36
|
+
"prepare": "npm-run-all clean bundle",
|
|
37
|
+
"clean": "rimraf dist doc",
|
|
54
38
|
"clear": "npm run clean",
|
|
55
39
|
"bundle": "npm-run-all build build:**",
|
|
56
|
-
"build": "
|
|
40
|
+
"build": "webpack --config src/config/webpack.config.js",
|
|
57
41
|
"build:prod": "cross-env NODE_ENV=production npm run build",
|
|
58
|
-
"build:index": "cross-env BUILD_MODE=index npm run build",
|
|
59
|
-
"build:index:prod": "cross-env NODE_ENV=production BUILD_MODE=index npm run build",
|
|
60
|
-
"build:config": "cross-env BUILD_MODE=config npm run build",
|
|
61
|
-
"build:config:prod": "cross-env NODE_ENV=production BUILD_MODE=config npm run build",
|
|
62
42
|
"build:tsdoc": "typedoc",
|
|
63
|
-
"build:sassdoc": "cross-var \"sassdoc $npm_package_config_dirs_src/$npm_package_config_dirs_scss -p > $npm_package_config_dirs_doc/sassdoc.json\"",
|
|
64
|
-
"serve": "cross-var webpack serve --config $npm_package_config_webpack",
|
|
65
43
|
"watch": "npm run build -- --watch",
|
|
66
44
|
"watch:prod": "cross-env NODE_ENV=production npm run watch",
|
|
67
45
|
"watch:tsdoc": "npm run build:tsdoc -- --watch",
|
|
68
|
-
"test": "echo-cli \"\\nRun tests here!\\n\""
|
|
69
|
-
"relink": "npm r -g @appartmint/mint && npm link",
|
|
70
|
-
"upgrade:config": "npm up -D @appartmint/config && mint-config"
|
|
46
|
+
"test": "echo-cli \"\\nRun tests here!\\n\""
|
|
71
47
|
},
|
|
72
48
|
"devDependencies": {
|
|
73
|
-
"@appartmint/config": "^0.7.0",
|
|
74
|
-
"@babel/core": "^7.19.6",
|
|
75
|
-
"@babel/preset-env": "^7.19.4",
|
|
76
|
-
"babel-loader": "^9.0.1",
|
|
77
|
-
"copy-webpack-plugin": "^11.0.0",
|
|
78
49
|
"cross-env": "^7.0.3",
|
|
79
|
-
"
|
|
80
|
-
"css-loader": "^6.7.1",
|
|
50
|
+
"css-loader": "^7.1.2",
|
|
81
51
|
"echo-cli": "^2.0.0",
|
|
82
|
-
"
|
|
83
|
-
"karma": "^6.4.1",
|
|
84
|
-
"karma-babel-preprocessor": "^8.0.2",
|
|
85
|
-
"karma-chrome-launcher": "^3.1.1",
|
|
86
|
-
"karma-jasmine": "^5.1.0",
|
|
87
|
-
"karma-phantomjs-launcher": "^1.0.4",
|
|
88
|
-
"karma-typescript-preprocessor": "^0.4.0",
|
|
89
|
-
"karma-webpack": "^5.0.0",
|
|
90
|
-
"mini-css-extract-plugin": "^2.6.1",
|
|
52
|
+
"mini-css-extract-plugin": "^2.9.2",
|
|
91
53
|
"npm-run-all": "^4.1.5",
|
|
92
|
-
"rimraf": "^
|
|
93
|
-
"sass": "^1.
|
|
94
|
-
"sass-loader": "^
|
|
95
|
-
"
|
|
96
|
-
"
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
"webpack-
|
|
101
|
-
"webpack-dev-server": "^4.11.1",
|
|
102
|
-
"webpack-lowercase-name": "^1.0.4",
|
|
103
|
-
"webpack-node-externals": "^3.0.0",
|
|
104
|
-
"webpack-remove-empty-scripts": "^1.0.1",
|
|
105
|
-
"webpack-shebang-plugin": "^1.1.8"
|
|
54
|
+
"rimraf": "^6.0.1",
|
|
55
|
+
"sass": "^1.83.1",
|
|
56
|
+
"sass-loader": "^16.0.4",
|
|
57
|
+
"ts-loader": "^9.5.1",
|
|
58
|
+
"typedoc": "^0.27.6",
|
|
59
|
+
"typescript": "^5.5.4",
|
|
60
|
+
"webpack": "^5.97.1",
|
|
61
|
+
"webpack-cli": "^6.0.1",
|
|
62
|
+
"webpack-remove-empty-scripts": "^1.0.4"
|
|
106
63
|
}
|
|
107
64
|
}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
/// Imports
|
|
2
|
+
@use 'sass:map';
|
|
3
|
+
@use 'sass:meta';
|
|
2
4
|
@use '../util' as *;
|
|
3
5
|
|
|
4
6
|
/// Global styles
|
|
@@ -52,7 +54,7 @@ app-root {
|
|
|
52
54
|
opacity: 0;
|
|
53
55
|
transition: opacity 750ms ease-in;
|
|
54
56
|
|
|
55
|
-
@if (type-of($root-bg-image) == 'string') {
|
|
57
|
+
@if (meta.type-of($root-bg-image) == 'string') {
|
|
56
58
|
&::before {
|
|
57
59
|
content: '';
|
|
58
60
|
position: absolute;
|
|
@@ -62,15 +64,15 @@ app-root {
|
|
|
62
64
|
height: 100%;
|
|
63
65
|
background-image: url($root-bg-image);
|
|
64
66
|
|
|
65
|
-
@if (type-of($root-bg-size) != 'null') {
|
|
67
|
+
@if (meta.type-of($root-bg-size) != 'null') {
|
|
66
68
|
background-size: $root-bg-size;
|
|
67
69
|
}
|
|
68
70
|
|
|
69
|
-
@if (type-of($root-bg-position) != 'null') {
|
|
71
|
+
@if (meta.type-of($root-bg-position) != 'null') {
|
|
70
72
|
background-position: $root-bg-position;
|
|
71
73
|
}
|
|
72
74
|
|
|
73
|
-
@if (type-of($root-bg-filter) != 'null') {
|
|
75
|
+
@if (meta.type-of($root-bg-filter) != 'null') {
|
|
74
76
|
filter: $root-bg-filter;
|
|
75
77
|
}
|
|
76
78
|
}
|
|
@@ -103,7 +105,7 @@ main {
|
|
|
103
105
|
width: 100%;
|
|
104
106
|
padding: 0.25rem;
|
|
105
107
|
|
|
106
|
-
@include fluid(padding, map
|
|
108
|
+
@include fluid(padding, map.get($break, xs) * 1px, map.get($break, sm) * 1px, 4px, 16px);
|
|
107
109
|
|
|
108
110
|
&+:not(#{prefix(partial-footer)}) {
|
|
109
111
|
height: 0;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
@charset 'utf-8';
|
|
6
6
|
|
|
7
7
|
/// Imports
|
|
8
|
+
@use 'sass:map';
|
|
8
9
|
@use '../util' as *;
|
|
9
10
|
|
|
10
11
|
/// Text Styles
|
|
@@ -34,17 +35,17 @@ p {
|
|
|
34
35
|
}
|
|
35
36
|
}
|
|
36
37
|
|
|
37
|
-
@each $tag in map
|
|
38
|
+
@each $tag in map.keys($font-size-mobile) {
|
|
38
39
|
#{$tag}, #{class($tag)} {
|
|
39
40
|
margin: 1rem 0;
|
|
40
|
-
font-size: min(map
|
|
41
|
+
font-size: min(map.get($font-size-tiny, $tag), map.get($font-size-mobile, $tag));
|
|
41
42
|
|
|
42
43
|
@include break(xs) {
|
|
43
|
-
font-size: map
|
|
44
|
+
font-size: map.get($font-size-mobile, $tag);
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
@include break(md) {
|
|
47
|
-
font-size: map
|
|
48
|
+
font-size: map.get($font-size-desktop, $tag);
|
|
48
49
|
}
|
|
49
50
|
}
|
|
50
51
|
}
|
|
@@ -5,7 +5,10 @@
|
|
|
5
5
|
|
|
6
6
|
/// Imports
|
|
7
7
|
@use 'sass:color';
|
|
8
|
+
@use 'sass:list';
|
|
9
|
+
@use 'sass:map';
|
|
8
10
|
@use 'sass:math';
|
|
11
|
+
@use 'sass:meta';
|
|
9
12
|
@use 'sass:string';
|
|
10
13
|
|
|
11
14
|
/// Library name
|
|
@@ -154,7 +157,7 @@ $bootstrap5: false !default;
|
|
|
154
157
|
/// @param {String} $base - the string to be prefixed
|
|
155
158
|
/// @return {String} - a prefixed string
|
|
156
159
|
@function prefix ($base) {
|
|
157
|
-
@if (type-of($base) != 'string') {
|
|
160
|
+
@if (meta.type-of($base) != 'string') {
|
|
158
161
|
@error 'The prefix function requires a string value.';
|
|
159
162
|
}
|
|
160
163
|
|
|
@@ -176,7 +179,7 @@ $bootstrap5: false !default;
|
|
|
176
179
|
/// @param {String} $base - the string to be prefixed
|
|
177
180
|
/// @return {String} - a prefixed string
|
|
178
181
|
@function css-prefix ($base) {
|
|
179
|
-
@if (type-of($base) != 'string') {
|
|
182
|
+
@if (meta.type-of($base) != 'string') {
|
|
180
183
|
@error 'The css-prefix function requires a string value.';
|
|
181
184
|
}
|
|
182
185
|
|
|
@@ -196,7 +199,7 @@ $bootstrap5: false !default;
|
|
|
196
199
|
/// @param {String} $base - the CSS-var to create a call for
|
|
197
200
|
/// @return {String} - a CSS-var call
|
|
198
201
|
@function css-var ($base) {
|
|
199
|
-
@if (type-of($base) != 'string') {
|
|
202
|
+
@if (meta.type-of($base) != 'string') {
|
|
200
203
|
@error 'The css-var function requires a string value.';
|
|
201
204
|
}
|
|
202
205
|
|
|
@@ -216,7 +219,7 @@ $bootstrap5: false !default;
|
|
|
216
219
|
/// @param {String} $base - the CSS-selector to negate
|
|
217
220
|
/// @return {String} - a negated CSS-selector
|
|
218
221
|
@function neg ($base) {
|
|
219
|
-
@if (type-of($base) != 'string') {
|
|
222
|
+
@if (meta.type-of($base) != 'string') {
|
|
220
223
|
@error 'The neg function requires a string value.';
|
|
221
224
|
}
|
|
222
225
|
|
|
@@ -232,7 +235,7 @@ $bootstrap5: false !default;
|
|
|
232
235
|
/// @param {String} $base - the name of the class
|
|
233
236
|
/// @return {String} - a class selector
|
|
234
237
|
@function class($base) {
|
|
235
|
-
@if (type-of($base) != 'string') {
|
|
238
|
+
@if (meta.type-of($base) != 'string') {
|
|
236
239
|
@error 'The class function requires a string value.';
|
|
237
240
|
}
|
|
238
241
|
|
|
@@ -249,11 +252,11 @@ $bootstrap5: false !default;
|
|
|
249
252
|
/// @param {String} $op - the comparison operator
|
|
250
253
|
/// @return {String} - an id selector
|
|
251
254
|
@function id ($base, $op: '=') {
|
|
252
|
-
@if (type-of($base) != 'string') {
|
|
255
|
+
@if (meta.type-of($base) != 'string') {
|
|
253
256
|
@error 'The id function requires a string value.';
|
|
254
257
|
}
|
|
255
258
|
|
|
256
|
-
@if (type-of($op) != 'string') {
|
|
259
|
+
@if (meta.type-of($op) != 'string') {
|
|
257
260
|
@error 'The controls function requires a string value for param 2.';
|
|
258
261
|
}
|
|
259
262
|
|
|
@@ -278,11 +281,11 @@ $bootstrap5: false !default;
|
|
|
278
281
|
/// @param {String} $op - the comparison operator
|
|
279
282
|
/// @return {String} - an aria-controls selector
|
|
280
283
|
@function controls ($id, $op: '=') {
|
|
281
|
-
@if (type-of($id) != 'string') {
|
|
284
|
+
@if (meta.type-of($id) != 'string') {
|
|
282
285
|
@error 'The controls function requires a string value for param 1.';
|
|
283
286
|
}
|
|
284
287
|
|
|
285
|
-
@if (type-of($op) != 'string') {
|
|
288
|
+
@if (meta.type-of($op) != 'string') {
|
|
286
289
|
@error 'The controls function requires a string value for param 2.';
|
|
287
290
|
}
|
|
288
291
|
|
|
@@ -302,7 +305,7 @@ $bootstrap5: false !default;
|
|
|
302
305
|
/// @param {Bool} $bool - the value of the selector
|
|
303
306
|
/// @return {String} - an aria-expanded selector
|
|
304
307
|
@function expanded ($bool) {
|
|
305
|
-
@if (type-of($bool) == 'string') {
|
|
308
|
+
@if (meta.type-of($bool) == 'string') {
|
|
306
309
|
$bool: string.to-lower-case($bool);
|
|
307
310
|
|
|
308
311
|
@if not($bool == 'true' or $bool == 'false') {
|
|
@@ -310,7 +313,7 @@ $bootstrap5: false !default;
|
|
|
310
313
|
}
|
|
311
314
|
}
|
|
312
315
|
|
|
313
|
-
@else if (type-of($bool) != 'bool') {
|
|
316
|
+
@else if (meta.type-of($bool) != 'bool') {
|
|
314
317
|
@error 'The expanded function requires a boolean value.';
|
|
315
318
|
}
|
|
316
319
|
|
|
@@ -326,7 +329,7 @@ $bootstrap5: false !default;
|
|
|
326
329
|
/// @param {Bool} $bool - the value of the selector
|
|
327
330
|
/// @return {String} - an aria-hidden selector
|
|
328
331
|
@function hidden ($bool) {
|
|
329
|
-
@if (type-of($bool) == 'string') {
|
|
332
|
+
@if (meta.type-of($bool) == 'string') {
|
|
330
333
|
$bool: string.to-lower-case($bool);
|
|
331
334
|
|
|
332
335
|
@if not($bool == 'true' or $bool == 'false') {
|
|
@@ -334,7 +337,7 @@ $bootstrap5: false !default;
|
|
|
334
337
|
}
|
|
335
338
|
}
|
|
336
339
|
|
|
337
|
-
@else if (type-of($bool) !='bool') {
|
|
340
|
+
@else if (meta.type-of($bool) !='bool') {
|
|
338
341
|
@error 'The hidden function requires a boolean value. Received: #{$bool}';
|
|
339
342
|
}
|
|
340
343
|
|
|
@@ -350,7 +353,7 @@ $bootstrap5: false !default;
|
|
|
350
353
|
/// @param {Number} $val - the number of ms to return
|
|
351
354
|
/// @return {Number} the number as ms
|
|
352
355
|
@function ms ($val) {
|
|
353
|
-
@if (type-of($val) != 'number') {
|
|
356
|
+
@if (meta.type-of($val) != 'number') {
|
|
354
357
|
@error 'The ms function requires a number value.';
|
|
355
358
|
}
|
|
356
359
|
|
|
@@ -366,7 +369,7 @@ $bootstrap5: false !default;
|
|
|
366
369
|
/// @param {Number} $val - the number of px to return
|
|
367
370
|
/// @return {Number} - the number as px
|
|
368
371
|
@function px ($val) {
|
|
369
|
-
@if (type-of($val) != 'number') {
|
|
372
|
+
@if (meta.type-of($val) != 'number') {
|
|
370
373
|
@error 'The px function requires a number value.';
|
|
371
374
|
}
|
|
372
375
|
|
|
@@ -382,7 +385,7 @@ $bootstrap5: false !default;
|
|
|
382
385
|
/// @param {Number} $val - the value to strip
|
|
383
386
|
/// @return {Number} - the number without units
|
|
384
387
|
@function strip-unit($val) {
|
|
385
|
-
@if (type-of($val) != 'number') {
|
|
388
|
+
@if (meta.type-of($val) != 'number') {
|
|
386
389
|
@error 'The strip-unit function requires a number value.';
|
|
387
390
|
}
|
|
388
391
|
|
|
@@ -401,7 +404,7 @@ $bootstrap5: false !default;
|
|
|
401
404
|
/// @throws {Error} - if the values are not numbers
|
|
402
405
|
/// @throws {Error} - if the divisor is 0
|
|
403
406
|
@function percent($dividend, $divisor, $padding: 0) {
|
|
404
|
-
@if (type-of($dividend) != 'number' or type-of($divisor) != 'number' or type-of($padding) != 'number') {
|
|
407
|
+
@if (meta.type-of($dividend) != 'number' or meta.type-of($divisor) != 'number' or meta.type-of($padding) != 'number') {
|
|
405
408
|
@error 'The percent function requires number parameters.';
|
|
406
409
|
}
|
|
407
410
|
|
|
@@ -425,11 +428,11 @@ $bootstrap5: false !default;
|
|
|
425
428
|
/// @param {Number} $key - the key of the delay to use
|
|
426
429
|
/// @return {Number} - the delay value as ms
|
|
427
430
|
@function delay($key) {
|
|
428
|
-
@if not(map
|
|
431
|
+
@if not(map.has-key($delay, $key)) {
|
|
429
432
|
@error 'The delay function requires one of the following values: #{map-keys($delay)}';
|
|
430
433
|
}
|
|
431
434
|
|
|
432
|
-
@return ms(map
|
|
435
|
+
@return ms(map.get($delay, $key));
|
|
433
436
|
}
|
|
434
437
|
|
|
435
438
|
/// Returns the requested breakpoint value as px
|
|
@@ -441,11 +444,11 @@ $bootstrap5: false !default;
|
|
|
441
444
|
/// @param {Number} $key - the key of the breakpoint to use
|
|
442
445
|
/// @return {Number} - the breakpoint value as px
|
|
443
446
|
@function break($key) {
|
|
444
|
-
@if not(map
|
|
447
|
+
@if not(map.has-key($break, $key)) {
|
|
445
448
|
@error 'The break function requires one of the following values: #{map-keys($break)}';
|
|
446
449
|
}
|
|
447
450
|
|
|
448
|
-
@return px(map
|
|
451
|
+
@return px(map.get($break, $key));
|
|
449
452
|
}
|
|
450
453
|
|
|
451
454
|
/// Creates a prefixed CSS var definition
|
|
@@ -458,7 +461,7 @@ $bootstrap5: false !default;
|
|
|
458
461
|
/// @param {Any} $val - the value of the CSS var
|
|
459
462
|
/// @output a prefixed CSS var definition
|
|
460
463
|
@mixin css-var ($key, $val) {
|
|
461
|
-
@if (type-of($key) != 'string') {
|
|
464
|
+
@if (meta.type-of($key) != 'string') {
|
|
462
465
|
@error 'The css-var mixin requires a string for the $key argument.';
|
|
463
466
|
}
|
|
464
467
|
|
|
@@ -479,7 +482,7 @@ $bootstrap5: false !default;
|
|
|
479
482
|
/// @param {String} $key2 - the key of the referenced CSS var
|
|
480
483
|
/// @output a prefixed CSS var reference
|
|
481
484
|
@mixin css-var-ref ($key1, $key2) {
|
|
482
|
-
@if (type-of($key1) != 'string' or type-of($key2) != 'string') {
|
|
485
|
+
@if (meta.type-of($key1) != 'string' or meta.type-of($key2) != 'string') {
|
|
483
486
|
@error 'The css-var-ref mixin requires string values for both parameters.';
|
|
484
487
|
}
|
|
485
488
|
|
|
@@ -498,11 +501,11 @@ $bootstrap5: false !default;
|
|
|
498
501
|
/// @param {String} $max - the key of the breakpoint to use with max-width
|
|
499
502
|
/// @output the provided content wrapped in a media query
|
|
500
503
|
@mixin break ($min, $max: null) {
|
|
501
|
-
@if not(map
|
|
504
|
+
@if not(map.has-key($break, $min) and (meta.type-of($max) == 'null' or map.has-key($break, $max))) {
|
|
502
505
|
@error 'The break mixin requires one or two of the following values: #{map-keys($break)}';
|
|
503
506
|
}
|
|
504
507
|
|
|
505
|
-
@if (map
|
|
508
|
+
@if (map.has-key($break, $max)) {
|
|
506
509
|
@media (min-width: break($min)) and (max-width: break($max)) {
|
|
507
510
|
@content;
|
|
508
511
|
}
|
|
@@ -516,11 +519,11 @@ $bootstrap5: false !default;
|
|
|
516
519
|
}
|
|
517
520
|
|
|
518
521
|
@mixin break-max ($max, $min: null) {
|
|
519
|
-
@if not(map
|
|
522
|
+
@if not(map.has-key($break, $max) and (meta.type-of($min) == 'null' or map.has-key($break, $min))) {
|
|
520
523
|
@error 'The break-max mixin requires one or two of the following values: #{map-keys($break)}';
|
|
521
524
|
}
|
|
522
525
|
|
|
523
|
-
@if (map
|
|
526
|
+
@if (map.has-key($break, $min)) {
|
|
524
527
|
@media (min-width: break($min)) and (max-width: break($max)) {
|
|
525
528
|
@content;
|
|
526
529
|
}
|
|
@@ -572,7 +575,7 @@ $bootstrap5: false !default;
|
|
|
572
575
|
/// @param {Any} $none - the inactive value of the property
|
|
573
576
|
/// @output utility selectors for the given property at each breakpoint
|
|
574
577
|
@mixin break-util ($prop, $val, $none: "none") {
|
|
575
|
-
@if (type-of($prop) !='string') {
|
|
578
|
+
@if (meta.type-of($prop) !='string') {
|
|
576
579
|
@error 'The break-util mixin requires a string for the $prop argument.';
|
|
577
580
|
}
|
|
578
581
|
|
|
@@ -607,7 +610,7 @@ $bootstrap5: false !default;
|
|
|
607
610
|
/// @include box-util(margin, 1rem, 0); // -> & {
|
|
608
611
|
///
|
|
609
612
|
@mixin box-util ($prop, $val) {
|
|
610
|
-
@if (type-of($prop) != 'string') {
|
|
613
|
+
@if (meta.type-of($prop) != 'string') {
|
|
611
614
|
@error 'The box-util mixin requires a string for the $prop argument.';
|
|
612
615
|
}
|
|
613
616
|
|
|
@@ -745,16 +748,16 @@ $bootstrap5: false !default;
|
|
|
745
748
|
/// @param {String} $max-size - the maximum value of the fluid property
|
|
746
749
|
/// @output the definitions for the property at different screen sizes
|
|
747
750
|
@mixin fluid ($prop, $min-vw, $max-vw, $min-size, $max-size) {
|
|
748
|
-
$u1: unit($min-vw);
|
|
749
|
-
$u2: unit($max-vw);
|
|
750
|
-
$u3: unit($min-size);
|
|
751
|
-
$u4: unit($max-size);
|
|
751
|
+
$u1: math.unit($min-vw);
|
|
752
|
+
$u2: math.unit($max-vw);
|
|
753
|
+
$u3: math.unit($min-size);
|
|
754
|
+
$u4: math.unit($max-size);
|
|
752
755
|
|
|
753
|
-
@if (type-of($prop) !='string') {
|
|
756
|
+
@if (meta.type-of($prop) !='string') {
|
|
754
757
|
@error 'The fluid mixin requires a string for the $prop argument.';
|
|
755
758
|
}
|
|
756
759
|
|
|
757
|
-
@if not(type-of($u1) == 'string' and type-of($u2) == 'string' and type-of($u3) == 'string' and type-of($u4) == 'string') {
|
|
760
|
+
@if not(meta.type-of($u1) == 'string' and meta.type-of($u2) == 'string' and meta.type-of($u3) == 'string' and meta.type-of($u4) == 'string') {
|
|
758
761
|
@error 'The fluid mixin requires numbers with units for the width and size arguments.';
|
|
759
762
|
}
|
|
760
763
|
|
|
@@ -787,11 +790,11 @@ $bootstrap5: false !default;
|
|
|
787
790
|
/// @param {Boolean} $alpha - whether to generate alpha variations
|
|
788
791
|
/// @output css variables for different shades of the source color
|
|
789
792
|
@mixin shades ($name, $color, $type: both, $number: 7, $amount: 10%, $alpha: false) {
|
|
790
|
-
@if (type-of($name) != 'string') {
|
|
793
|
+
@if (meta.type-of($name) != 'string') {
|
|
791
794
|
@error 'The shades mixin requires a string for the $name argument.';
|
|
792
795
|
}
|
|
793
796
|
|
|
794
|
-
@if (type-of($color) != 'color') {
|
|
797
|
+
@if (meta.type-of($color) != 'color') {
|
|
795
798
|
@error 'The shades mixin requires a color for the $color argument.';
|
|
796
799
|
}
|
|
797
800
|
|
|
@@ -799,11 +802,11 @@ $bootstrap5: false !default;
|
|
|
799
802
|
@error 'The shades mixin requires a string of "lighten", "darken", or "both" for the $type argument.';
|
|
800
803
|
}
|
|
801
804
|
|
|
802
|
-
@if (type-of($number) != 'number') {
|
|
805
|
+
@if (meta.type-of($number) != 'number') {
|
|
803
806
|
@error 'The shades mixin requires a number for the $number argument.';
|
|
804
807
|
}
|
|
805
808
|
|
|
806
|
-
@if (type-of($alpha) == 'string') {
|
|
809
|
+
@if (meta.type-of($alpha) == 'string') {
|
|
807
810
|
$bool: string.to-lower-case($bool);
|
|
808
811
|
|
|
809
812
|
@if not($bool == 'true' or $bool == 'false') {
|
|
@@ -811,7 +814,7 @@ $bootstrap5: false !default;
|
|
|
811
814
|
}
|
|
812
815
|
}
|
|
813
816
|
|
|
814
|
-
@else if (type-of($alpha) != 'bool') {
|
|
817
|
+
@else if (meta.type-of($alpha) != 'bool') {
|
|
815
818
|
@error 'The shades mixin requires a boolean value for the $alpha argument. Received: #{$bool}';
|
|
816
819
|
}
|
|
817
820
|
|
|
@@ -848,27 +851,27 @@ $bootstrap5: false !default;
|
|
|
848
851
|
@else {
|
|
849
852
|
@if ($type == lighten) {
|
|
850
853
|
@for $i from 0 through $number - 1 {
|
|
851
|
-
@include css-var(#{$name}-#{$i},
|
|
854
|
+
@include css-var(#{$name}-#{$i}, color.adjust($color, $lightness: $i * $amount));
|
|
852
855
|
}
|
|
853
856
|
}
|
|
854
857
|
|
|
855
858
|
@else if ($type == darken) {
|
|
856
859
|
@for $i from 0 through $number - 1 {
|
|
857
|
-
@include css-var(#{$name}-#{$i},
|
|
860
|
+
@include css-var(#{$name}-#{$i}, color.adjust($color, $lightness: $i * -$amount));
|
|
858
861
|
}
|
|
859
862
|
}
|
|
860
863
|
|
|
861
864
|
@else if ($type == both) {
|
|
862
|
-
$num-light: floor(math.div($number, 2));
|
|
865
|
+
$num-light: math.floor(math.div($number, 2));
|
|
863
866
|
|
|
864
867
|
@for $i from 0 through $num-light - 1 {
|
|
865
|
-
@include css-var(#{$name}-#{$i},
|
|
868
|
+
@include css-var(#{$name}-#{$i}, color.adjust($color, $lightness: ($num-light - $i) * $amount));
|
|
866
869
|
}
|
|
867
870
|
|
|
868
871
|
@include css-var(#{$name}-#{$num-light}, $color);
|
|
869
872
|
|
|
870
873
|
@for $i from $num-light + 1 through $number - 1 {
|
|
871
|
-
@include css-var(#{$name}-#{$i},
|
|
874
|
+
@include css-var(#{$name}-#{$i}, color.adjust($color, $lightness: ($i - $num-light) * -$amount));
|
|
872
875
|
}
|
|
873
876
|
}
|
|
874
877
|
}
|
|
@@ -877,24 +880,24 @@ $bootstrap5: false !default;
|
|
|
877
880
|
/// TODO: Document this
|
|
878
881
|
@mixin states ($states...) {
|
|
879
882
|
@each $state in $states {
|
|
880
|
-
@if (type-of($state) != 'string') {
|
|
883
|
+
@if (meta.type-of($state) != 'string') {
|
|
881
884
|
@error 'The states mixin requires a string for each state argument.';
|
|
882
885
|
}
|
|
883
886
|
}
|
|
884
887
|
|
|
885
|
-
@if (index($states, 'hover') != null) {
|
|
888
|
+
@if (list.index($states, 'hover') != null) {
|
|
886
889
|
&:hover {
|
|
887
890
|
@content;
|
|
888
891
|
}
|
|
889
892
|
}
|
|
890
893
|
|
|
891
|
-
@if (index($states, 'focus') != null) {
|
|
894
|
+
@if (list.index($states, 'focus') != null) {
|
|
892
895
|
&:focus-visible {
|
|
893
896
|
@content;
|
|
894
897
|
}
|
|
895
898
|
}
|
|
896
899
|
|
|
897
|
-
@if (index($states, 'active') != null) {
|
|
900
|
+
@if (list.index($states, 'active') != null) {
|
|
898
901
|
|
|
899
902
|
&:active,
|
|
900
903
|
&#{class(active)} {
|
|
@@ -902,19 +905,19 @@ $bootstrap5: false !default;
|
|
|
902
905
|
}
|
|
903
906
|
}
|
|
904
907
|
|
|
905
|
-
@if (index($states, 'visited') != null) {
|
|
908
|
+
@if (list.index($states, 'visited') != null) {
|
|
906
909
|
&:visited {
|
|
907
910
|
@content;
|
|
908
911
|
}
|
|
909
912
|
}
|
|
910
913
|
|
|
911
|
-
@if (index($states, 'disabled') != null) {
|
|
914
|
+
@if (list.index($states, 'disabled') != null) {
|
|
912
915
|
&:disabled {
|
|
913
916
|
@content;
|
|
914
917
|
}
|
|
915
918
|
}
|
|
916
919
|
|
|
917
|
-
@if (index($states, 'expanded') != null) {
|
|
920
|
+
@if (list.index($states, 'expanded') != null) {
|
|
918
921
|
&#{expanded(true)} {
|
|
919
922
|
@content;
|
|
920
923
|
}
|
|
@@ -4,6 +4,9 @@
|
|
|
4
4
|
/// @group Vars
|
|
5
5
|
@charset 'utf-8';
|
|
6
6
|
|
|
7
|
+
/// Imports
|
|
8
|
+
@use 'sass:color';
|
|
9
|
+
|
|
7
10
|
/// Global Colors
|
|
8
11
|
$bitcoin: #FF9900;
|
|
9
12
|
$ethereum: #3C3C3D;
|
|
@@ -45,8 +48,8 @@ $danger: #ff4d4d !default;
|
|
|
45
48
|
$warning: #ffaa22 !default;
|
|
46
49
|
$info: $brand !default;
|
|
47
50
|
|
|
48
|
-
$fore:
|
|
49
|
-
$back:
|
|
51
|
+
$fore: color.adjust($black, $lightness: 10%) !default;
|
|
52
|
+
$back: color.adjust($white, $lightness: -10%) !default;
|
|
50
53
|
|
|
51
54
|
/// Fonts
|
|
52
55
|
$font-primary: sans-serif !default;
|