@matteusan/himig 1.5.0 → 1.7.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/README.md +2 -2
- package/_index.scss +5 -23
- package/ms-badge/_badge-base.scss +1 -1
- package/ms-badge/_badge-extend.scss +1 -1
- package/ms-badge/_badge-styles.scss +1 -1
- package/ms-button/_button-base.scss +1 -1
- package/ms-button/_button-extend.scss +1 -1
- package/ms-button/_button-mixins.scss +1 -1
- package/ms-button/_button-styles.scss +26 -26
- package/ms-card/_card-base.scss +3 -3
- package/ms-card/_card-extend.scss +1 -1
- package/ms-card/_card-styles.scss +6 -1
- package/ms-card/_card-theme.scss +8 -3
- package/ms-form-field/_form-field-base.scss +6 -2
- package/ms-form-field/_form-field-extend.scss +1 -1
- package/ms-form-field/_form-field-styles.scss +15 -11
- package/ms-form-field/_form-field-theme.scss +20 -8
- package/ms-link/_link-base.scss +1 -1
- package/ms-link/_link-extend.scss +1 -1
- package/ms-link/_link-styles.scss +1 -1
- package/ms-link/_link-theme.scss +4 -4
- package/ms-list/_list-base.scss +1 -1
- package/ms-list/_list-extend.scss +1 -1
- package/ms-list/_list-styles.scss +1 -1
- package/ms-select-field/_select-field-base.scss +1 -1
- package/ms-select-field/_select-field-extend.scss +1 -1
- package/ms-select-field/_select-field-styles.scss +18 -10
- package/ms-select-field/_select-field-theme.scss +16 -8
- package/ms-tick-field/_tick-field-base.scss +1 -1
- package/ms-tick-field/_tick-field-extend.scss +1 -1
- package/ms-tick-field/_tick-field-styles.scss +3 -14
- package/ms-tick-field/_tick-field-theme.scss +5 -0
- package/ms-utils/_color-utils.scss +1 -1
- package/ms-utils/_consts.scss +1 -1
- package/ms-utils/_layout-utils.scss +1 -1
- package/ms-utils/_struct-utils.scss +1 -1
- package/ms-utils/_typography-utils.scss +1 -1
- package/ms-utils/_util-helpers.scss +1 -1
- package/package.json +11 -3
- package/pintig/README.md +0 -2
- package/pintig/_index.scss +0 -77
- package/pintig/breakpoint/_breakpoint-sentro.scss +0 -53
- package/pintig/breakpoint/_index.scss +0 -23
- package/pintig/color/_color-constants.scss +0 -33
- package/pintig/color/_color-setters.scss +0 -75
- package/pintig/color/_color-utils.scss +0 -62
- package/pintig/color/_color-validators.scss +0 -59
- package/pintig/color/_index.scss +0 -25
- package/pintig/component/_component-extend.scss +0 -56
- package/pintig/component/_index.scss +0 -23
- package/pintig/component/component-base.ts +0 -81
- package/pintig/component/component-properties.ts +0 -25
- package/pintig/component/index.ts +0 -29
- package/pintig/component/types/ms-component.d.ts +0 -24
- package/pintig/index.ts +0 -29
- package/pintig/package.json +0 -15
- package/pintig/sprite/_index.scss +0 -23
- package/pintig/sprite/_sprite-mixins.scss +0 -29
- package/pintig/struct/_index.scss +0 -24
- package/pintig/struct/_struct-setters.scss +0 -98
- package/pintig/struct/_struct-utils.scss +0 -218
- package/pintig/struct/_struct-validators.scss +0 -57
- package/pintig/theme/_index.scss +0 -30
- package/pintig/theme/_theme-get.scss +0 -41
- package/pintig/theme/_theme-keys.scss +0 -43
- package/pintig/theme/_theme-merge.scss +0 -46
- package/pintig/theme/_theme-properties.scss +0 -61
- package/pintig/theme/_theme-setters.scss +0 -167
- package/pintig/theme/_theme-tokens.scss +0 -57
- package/pintig/tokens/_index.scss +0 -23
- package/pintig/tokens/_token-data.scss +0 -249
- package/pintig/tokens/_token-methods.scss +0 -118
- package/pintig/tools/_index.scss +0 -27
- package/pintig/tools/_tools-color.scss +0 -79
- package/pintig/tools/_tools-helpers.scss +0 -30
- package/pintig/tools/_tools-sentro.scss +0 -52
- package/pintig/tools/_tools-string.scss +0 -45
- package/pintig/tools/_tools-validation.scss +0 -71
- package/pintig/typography/_index.scss +0 -24
- package/pintig/typography/_typography-setters.scss +0 -78
- package/pintig/typography/_typography-utils.scss +0 -76
- package/pintig/typography/_typography-validators.scss +0 -47
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
// SOFTWARE.
|
|
21
21
|
//---------------------------------------------------
|
|
22
22
|
|
|
23
|
-
@use '
|
|
23
|
+
@use 'pkg:@matteusan/pintig';
|
|
24
24
|
@use 'sass:list';
|
|
25
25
|
@use 'tick-field-base' as base;
|
|
26
26
|
@use 'tick-field-theme' as theme;
|
|
@@ -42,19 +42,8 @@
|
|
|
42
42
|
ink: pintig.theme-get($color, 'ink'),
|
|
43
43
|
border: pintig.theme-get($color, 'border'),
|
|
44
44
|
));
|
|
45
|
-
@include pintig.struct-apply('tick-field',
|
|
46
|
-
|
|
47
|
-
padding: pintig.theme-get($struct, 'padding'),
|
|
48
|
-
gap: pintig.theme-get($struct, 'gap'),
|
|
49
|
-
border-width: pintig.theme-get($struct, 'border-width'),
|
|
50
|
-
border-style: pintig.theme-get($struct, 'border-style'),
|
|
51
|
-
));
|
|
52
|
-
@include pintig.typography-bind('tick-field', (
|
|
53
|
-
family: pintig.theme-get($typography, 'family'),
|
|
54
|
-
size: pintig.theme-get($typography, 'size'),
|
|
55
|
-
weight: pintig.theme-get($typography, 'weight'),
|
|
56
|
-
line-height: pintig.theme-get($typography, 'line-height'),
|
|
57
|
-
));
|
|
45
|
+
@include pintig.struct-apply('tick-field', $struct);
|
|
46
|
+
@include pintig.typography-bind('tick-field', $typography);
|
|
58
47
|
@include pintig.typography-bind('tick-field-helper', (
|
|
59
48
|
family: pintig.theme-get($typography, 'family'),
|
|
60
49
|
size: pintig.theme-get($typography, 'size', 'helper'),
|
package/ms-utils/_consts.scss
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@matteusan/himig",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "Matteu's personal design system for building user interfaces.",
|
|
5
5
|
"repository": "https://github.com/MatteuSan/himig",
|
|
6
6
|
"author": "Matteu <matteugt@gmail.com>",
|
|
@@ -8,8 +8,16 @@
|
|
|
8
8
|
"publishConfig": {
|
|
9
9
|
"access": "public"
|
|
10
10
|
},
|
|
11
|
+
"exports": {
|
|
12
|
+
".": {
|
|
13
|
+
"sass": "./_index.scss"
|
|
14
|
+
},
|
|
15
|
+
"./**/*.scss": {
|
|
16
|
+
"sass": "./**/*.scss"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
11
19
|
"dependencies": {
|
|
12
|
-
"@matteusan/pintig": "1.
|
|
13
|
-
"@matteusan/sentro": "
|
|
20
|
+
"@matteusan/pintig": "^1.0",
|
|
21
|
+
"@matteusan/sentro": "^1.2.2"
|
|
14
22
|
}
|
|
15
23
|
}
|
package/pintig/README.md
DELETED
package/pintig/_index.scss
DELETED
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
$module-mode: false !default;
|
|
24
|
-
$test-mode: $module-mode !default;
|
|
25
|
-
$vue-mode: $test-mode !default;
|
|
26
|
-
$validation: if($vue-mode == true, false, true);
|
|
27
|
-
$expressive-inks: false !default;
|
|
28
|
-
|
|
29
|
-
/// @type map
|
|
30
|
-
/// @description helper variable for inheriting values for all color properties
|
|
31
|
-
$color-inherit-template: (
|
|
32
|
-
fill: inherit,
|
|
33
|
-
ink: inherit,
|
|
34
|
-
border: inherit
|
|
35
|
-
);
|
|
36
|
-
|
|
37
|
-
/// @type map
|
|
38
|
-
/// @description helper variable for inheriting values for all struct properties
|
|
39
|
-
$struct-inherit-template: (
|
|
40
|
-
width: inherit,
|
|
41
|
-
height: inherit,
|
|
42
|
-
radius: inherit,
|
|
43
|
-
padding: inherit,
|
|
44
|
-
margin: inherit,
|
|
45
|
-
gap: inherit,
|
|
46
|
-
border-width: inherit,
|
|
47
|
-
border-style: inherit,
|
|
48
|
-
shadow: inherit
|
|
49
|
-
);
|
|
50
|
-
|
|
51
|
-
/// @type map
|
|
52
|
-
/// @description helper variable for inheriting values for all typography properties
|
|
53
|
-
$type-inherit-template: (
|
|
54
|
-
family: inherit,
|
|
55
|
-
size: inherit,
|
|
56
|
-
weight: inherit,
|
|
57
|
-
line-height: inherit
|
|
58
|
-
);
|
|
59
|
-
|
|
60
|
-
@use 'node_modules/@matteusan/sentro' with (
|
|
61
|
-
$prefix: 'ms',
|
|
62
|
-
$context: 'theme',
|
|
63
|
-
$token-validation: $validation,
|
|
64
|
-
$key-validation: $validation,
|
|
65
|
-
$breakpoint-validation: $validation,
|
|
66
|
-
);
|
|
67
|
-
|
|
68
|
-
@forward 'tokens';
|
|
69
|
-
@forward 'theme' with ($expressive-inks: $expressive-inks);
|
|
70
|
-
@forward 'tools';
|
|
71
|
-
@forward 'breakpoint' as breakpoint-*;
|
|
72
|
-
|
|
73
|
-
@forward 'color' as color-*;
|
|
74
|
-
@forward 'struct' as struct-*;
|
|
75
|
-
@forward 'sprite' as sprite-*;
|
|
76
|
-
@forward 'typography' as typography-*;
|
|
77
|
-
@forward 'component' as component-*;
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@use '../tools';
|
|
24
|
-
@use 'node_modules/@matteusan/sentro';
|
|
25
|
-
@use 'sass:map';
|
|
26
|
-
@use 'sass:meta';
|
|
27
|
-
|
|
28
|
-
$_registry: ();
|
|
29
|
-
|
|
30
|
-
@mixin config($map: (), $breakpoints...) {
|
|
31
|
-
@if not tools.is-empty($map) {
|
|
32
|
-
@each $key, $value in $map {
|
|
33
|
-
$_registry: map.set($_registry, $key, $value) !global;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
@if meta.keywords($breakpoints) {
|
|
37
|
-
@each $key, $value in meta.keywords($breakpoints) {
|
|
38
|
-
$_registry: map.set($_registry, $key, $value) !global;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
@include sentro.breakpoint-config($map, $breakpoints...);
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
@mixin create($query) {
|
|
45
|
-
@include sentro.breakpoint-create($query) {
|
|
46
|
-
@content;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/// @access protected
|
|
51
|
-
@function registry-get() {
|
|
52
|
-
@return $_registry;
|
|
53
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@forward 'breakpoint-sentro';
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
$fill-default-opacity: 0%;
|
|
24
|
-
$fill-hover-opacity: 20%;
|
|
25
|
-
$fill-focus-opacity: 20%;
|
|
26
|
-
$fill-active-opacity: 33%;
|
|
27
|
-
|
|
28
|
-
$border-default-opacity: 0%;
|
|
29
|
-
$border-hover-opacity: 2%;
|
|
30
|
-
$border-focus-opacity: 2%;
|
|
31
|
-
$border-active-opacity: 3.3%;
|
|
32
|
-
|
|
33
|
-
$outline-focus-opacity: 50%;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@use '../theme';
|
|
24
|
-
@use '../tools';
|
|
25
|
-
@use 'sass:map';
|
|
26
|
-
@use 'sass:list';
|
|
27
|
-
|
|
28
|
-
@use 'color-utils' as util;
|
|
29
|
-
@use 'color-validators' as validator;
|
|
30
|
-
|
|
31
|
-
@mixin _base($component, $theme, $settings: ()) {
|
|
32
|
-
$_init-settings: (intent: 'create');
|
|
33
|
-
$_settings: map.merge($_init-settings, $settings);
|
|
34
|
-
|
|
35
|
-
/// @type string
|
|
36
|
-
$intent: map.get($_settings, 'intent');
|
|
37
|
-
|
|
38
|
-
$fill: theme.theme-get($theme, 'fill');
|
|
39
|
-
$ink: theme.theme-get($theme, 'ink');
|
|
40
|
-
$border: theme.theme-get($theme, 'border');
|
|
41
|
-
|
|
42
|
-
@if not tools.is-type($theme, 'map') {
|
|
43
|
-
@error '$theme is expecting a map. Map was not given.';
|
|
44
|
-
} @else {
|
|
45
|
-
@include validator.validate-color-props(map.keys($theme)) {
|
|
46
|
-
@if $fill {
|
|
47
|
-
@include util.fill($component, $fill, $intent);
|
|
48
|
-
}
|
|
49
|
-
@if $ink {
|
|
50
|
-
@include util.ink($component, $ink, $intent);
|
|
51
|
-
}
|
|
52
|
-
@if $border {
|
|
53
|
-
@include util.border($component, $border, $intent);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
/// Mixin that applies color styles to a component.
|
|
60
|
-
/// @param {string} $component
|
|
61
|
-
/// @param {map<string, string>} $theme
|
|
62
|
-
/// @return {void} void.
|
|
63
|
-
@mixin apply($component, $theme) {
|
|
64
|
-
@include _base($component, $theme);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
/// Mixin that binds color styles to a component with existing keys.
|
|
68
|
-
/// @param {string} $component
|
|
69
|
-
/// @param {map<string, string>} $theme
|
|
70
|
-
/// @return {void} void.
|
|
71
|
-
@mixin bind($component, $theme) {
|
|
72
|
-
@include _base($component, $theme, (
|
|
73
|
-
'intent': bind
|
|
74
|
-
));
|
|
75
|
-
}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@use '../theme';
|
|
24
|
-
|
|
25
|
-
/// Mixin for applying background colors.
|
|
26
|
-
/// @param {string} $component
|
|
27
|
-
/// @param {token|color} $color
|
|
28
|
-
/// @param {string} $intent
|
|
29
|
-
/// @return {void} background color styles.
|
|
30
|
-
@mixin fill($component, $color, $intent: 'create') {
|
|
31
|
-
@include theme.property(
|
|
32
|
-
background-color,
|
|
33
|
-
('#{$component}-fill', $color),
|
|
34
|
-
$intent
|
|
35
|
-
);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/// Mixin for applying text colors.
|
|
39
|
-
/// @param {string} $component
|
|
40
|
-
/// @param {token|color} $color
|
|
41
|
-
/// @param {string} $intent
|
|
42
|
-
/// @return {void} text color styles.
|
|
43
|
-
@mixin ink($component, $color, $intent: 'create') {
|
|
44
|
-
@include theme.property(
|
|
45
|
-
color,
|
|
46
|
-
('#{$component}-ink', $color),
|
|
47
|
-
$intent
|
|
48
|
-
);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
/// Mixin for applying border colors.
|
|
52
|
-
/// @param {string} $component
|
|
53
|
-
/// @param {token|color} $color
|
|
54
|
-
/// @param {string} $intent
|
|
55
|
-
/// @return {void} border color styles.
|
|
56
|
-
@mixin border($component, $color, $intent: 'create') {
|
|
57
|
-
@include theme.property(
|
|
58
|
-
border-color,
|
|
59
|
-
('#{$component}-border', $color),
|
|
60
|
-
$intent
|
|
61
|
-
);
|
|
62
|
-
}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@use 'sass:list';
|
|
24
|
-
|
|
25
|
-
/// Valid component props
|
|
26
|
-
/// @access private
|
|
27
|
-
$_valid-props: ('fill', 'ink', 'border');
|
|
28
|
-
$_valid-colors: (
|
|
29
|
-
inherit,
|
|
30
|
-
currentColor,
|
|
31
|
-
transparent,
|
|
32
|
-
rgba(0, 0, 0, 0),
|
|
33
|
-
rgba(0 0 0 / 0)
|
|
34
|
-
);
|
|
35
|
-
|
|
36
|
-
/// Validates a set of color props.
|
|
37
|
-
/// @param {map} $props
|
|
38
|
-
/// @access protected
|
|
39
|
-
@mixin validate-color-props($props) {
|
|
40
|
-
@each $prop in $props {
|
|
41
|
-
@if _is-color-prop($prop) { }
|
|
42
|
-
}
|
|
43
|
-
@content;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
/// Validates a color query.
|
|
47
|
-
/// @access private
|
|
48
|
-
@function _is-valid-color($color) {
|
|
49
|
-
//
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
/// Validates a color prop.
|
|
53
|
-
/// @access private
|
|
54
|
-
@function _is-color-prop($query) {
|
|
55
|
-
@if not list.index($_valid-props, $query) {
|
|
56
|
-
@error 'Invalid color prop: #{$query}. Expecting a valid color prop: #{$_valid-props}.';
|
|
57
|
-
}
|
|
58
|
-
@return true;
|
|
59
|
-
}
|
package/pintig/color/_index.scss
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@forward 'color-constants';
|
|
24
|
-
@forward 'color-setters';
|
|
25
|
-
@forward 'color-utils';
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@use 'sass:list';
|
|
24
|
-
@use 'sass:string';
|
|
25
|
-
@use '../tools';
|
|
26
|
-
|
|
27
|
-
@mixin extend($component-name, $extension) {
|
|
28
|
-
$_extensions: tools.str-split($extension, '.');
|
|
29
|
-
$_sanitized-extension: '';
|
|
30
|
-
|
|
31
|
-
@each $ext in $_extensions {
|
|
32
|
-
@if list.index($_extensions, $ext) == 1 {
|
|
33
|
-
@if string.slice($ext, 1, 3) == 'is-' {
|
|
34
|
-
$_sanitized-extension: $_sanitized-extension + string.slice($ext, 4);
|
|
35
|
-
} @else {
|
|
36
|
-
$_sanitized-extension: $_sanitized-extension + $ext;
|
|
37
|
-
}
|
|
38
|
-
} @else if list.index($_extensions, $ext) == list.length($_extensions) {
|
|
39
|
-
@if string.slice($ext, 1, 3) == 'is-' {
|
|
40
|
-
$_sanitized-extension: $_sanitized-extension + '.#{$ext}';
|
|
41
|
-
} @else {
|
|
42
|
-
$_sanitized-extension: $_sanitized-extension + '.is-#{$ext}';
|
|
43
|
-
}
|
|
44
|
-
} @else {
|
|
45
|
-
@if string.slice($ext, 1, 3) == 'is-' {
|
|
46
|
-
$_sanitized-extension: $_sanitized-extension + '.#{$ext}';
|
|
47
|
-
} @else {
|
|
48
|
-
$_sanitized-extension: $_sanitized-extension + '.is-#{$ext}';
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.ms-#{$component-name}.is-#{$_sanitized-extension} {
|
|
54
|
-
@content;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
//---------------------------------------------------
|
|
2
|
-
// Copyright (c) 2024 MatteuSan
|
|
3
|
-
//
|
|
4
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
|
-
// of this software and associated documentation files (the "Software"), to deal
|
|
6
|
-
// in the Software without restriction, including without limitation the rights
|
|
7
|
-
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
8
|
-
// copies of the Software, and to permit persons to whom the Software is
|
|
9
|
-
// furnished to do so, subject to the following conditions:
|
|
10
|
-
//
|
|
11
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
// copies or substantial portions of the Software.
|
|
13
|
-
//
|
|
14
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
16
|
-
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
17
|
-
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
18
|
-
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
19
|
-
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
20
|
-
// SOFTWARE.
|
|
21
|
-
//---------------------------------------------------
|
|
22
|
-
|
|
23
|
-
@forward 'component-extend';
|