@nuvoui/core 1.2.5 → 1.2.6
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/dist/nuvoui.css +21899 -22748
- 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 +81 -47
- package/src/styles/abstracts/_functions.scss +21 -61
- package/src/styles/base/_base.scss +67 -59
- package/src/styles/base/_reset.scss +11 -8
- package/src/styles/index.scss +28 -10
- package/src/styles/layouts/_container.scss +1 -2
- package/src/styles/layouts/_flex.scss +442 -154
- package/src/styles/layouts/_grid.scss +145 -75
- package/src/styles/mixins-map.scss +1085 -1
- package/src/styles/themes/_theme.scss +127 -91
- package/src/styles/utilities/_alignment.scss +40 -13
- package/src/styles/utilities/_animations.scss +165 -105
- package/src/styles/utilities/_backdrop-filters.scss +111 -83
- package/src/styles/utilities/_borders.scss +329 -143
- package/src/styles/utilities/_colors.scss +24 -25
- package/src/styles/utilities/_container-queries.scss +7 -7
- package/src/styles/utilities/_cursor.scss +10 -17
- package/src/styles/utilities/_display.scss +234 -85
- package/src/styles/utilities/_helpers.scss +5 -5
- package/src/styles/utilities/_media-queries.scss +24 -27
- package/src/styles/utilities/_opacity.scss +15 -31
- package/src/styles/utilities/_position.scss +129 -66
- package/src/styles/utilities/_shadows.scss +23 -29
- package/src/styles/utilities/_sizing.scss +269 -108
- package/src/styles/utilities/_spacing.scss +254 -156
- package/src/styles/utilities/_tooltips.scss +35 -31
- package/src/styles/utilities/_transforms.scss +179 -156
- package/src/styles/utilities/_transitions.scss +134 -68
- package/src/styles/utilities/_typography.scss +341 -127
- package/src/styles/utilities/_z-index.scss +79 -49
- package/src/styles/abstracts/_index.scss +0 -1
- package/src/styles/base/_index.scss +0 -2
- package/src/styles/layouts/_index.scss +0 -3
- package/src/styles/themes/_index.scss +0 -1
- package/src/styles/utilities/_index.scss +0 -23
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuvoui/core",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.6",
|
|
4
4
|
"description": "NuvoUI is a human-friendly SCSS framework designed for simplicity, and modern responsive designs.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "AALA IT Solutions",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"prebuild": "npm run clean",
|
|
42
42
|
"build": "npm run build:scss && npm run build:minify",
|
|
43
43
|
"dev": "sass src/styles/index.scss:dist/nuvoui.css --watch",
|
|
44
|
-
"prepublishOnly": "npm run
|
|
44
|
+
"prepublishOnly": "npm run format && npm run build"
|
|
45
45
|
},
|
|
46
46
|
"repository": {
|
|
47
47
|
"type": "git",
|
|
@@ -5,13 +5,25 @@
|
|
|
5
5
|
$generate-utility-classes: true !default;
|
|
6
6
|
$enable-dark-mode: true !default;
|
|
7
7
|
$enable-rtl: true !default;
|
|
8
|
-
$enable-debugger: false !default;
|
|
8
|
+
$enable-debugger: false !default;
|
|
9
9
|
$enable-reduced-motion: true !default; // todo: pending
|
|
10
10
|
$enable-container-queries: false !default; // todo: pending
|
|
11
11
|
|
|
12
|
+
// if just a number passed, it will be assumed as px
|
|
13
|
+
$default-unit: px !default;
|
|
14
|
+
|
|
12
15
|
// Text
|
|
13
|
-
$base-size: 16 !default;
|
|
14
|
-
$font-family:
|
|
16
|
+
$base-size: 16 !default;
|
|
17
|
+
$font-family:
|
|
18
|
+
system-ui,
|
|
19
|
+
-apple-system,
|
|
20
|
+
"BlinkMacSystemFont",
|
|
21
|
+
"Segoe UI",
|
|
22
|
+
"Roboto",
|
|
23
|
+
"Oxygen",
|
|
24
|
+
"Ubuntu",
|
|
25
|
+
"Cantarell",
|
|
26
|
+
sans-serif !default;
|
|
15
27
|
|
|
16
28
|
// Global variables that might be used across different modules
|
|
17
29
|
$column-count: 12 !default; // todo: pending
|
|
@@ -37,7 +49,8 @@ $color-primitives: (
|
|
|
37
49
|
"pink": #ec4899,
|
|
38
50
|
) !default;
|
|
39
51
|
|
|
40
|
-
|
|
52
|
+
// Add item here to include in the theme
|
|
53
|
+
$theme-tokens: ("background", "foreground", "surface", "border", "text-default", "text-muted") !default;
|
|
41
54
|
|
|
42
55
|
// Default theme config (can be overridden)
|
|
43
56
|
$light-theme: (
|
|
@@ -45,8 +58,8 @@ $light-theme: (
|
|
|
45
58
|
"foreground": #1a1a1a,
|
|
46
59
|
"surface": #fff,
|
|
47
60
|
"border": #e5e7eb,
|
|
48
|
-
"text-
|
|
49
|
-
"text-
|
|
61
|
+
"text-default": #1a1a1a,
|
|
62
|
+
"text-muted": #4b5563,
|
|
50
63
|
) !default;
|
|
51
64
|
|
|
52
65
|
$dark-theme: (
|
|
@@ -54,8 +67,8 @@ $dark-theme: (
|
|
|
54
67
|
"foreground": #f1f1f1,
|
|
55
68
|
"surface": #2e2e2e,
|
|
56
69
|
"border": #2e2e2e,
|
|
57
|
-
"text-
|
|
58
|
-
"text-
|
|
70
|
+
"text-default": #f1f1f1,
|
|
71
|
+
"text-muted": #a3a3a3,
|
|
59
72
|
) !default;
|
|
60
73
|
|
|
61
74
|
$shadow-colors: (
|
|
@@ -85,55 +98,76 @@ $grid-item-sizes: (
|
|
|
85
98
|
|
|
86
99
|
// _variables.scss
|
|
87
100
|
$font-sizes: (
|
|
88
|
-
"xs": 0.75rem,
|
|
89
|
-
|
|
90
|
-
"
|
|
91
|
-
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
"
|
|
95
|
-
|
|
101
|
+
"xs": 0.75rem,
|
|
102
|
+
// 12px
|
|
103
|
+
"sm": 0.875rem,
|
|
104
|
+
// 14px
|
|
105
|
+
"md": 1rem,
|
|
106
|
+
// 16px
|
|
107
|
+
"lg": 1.25rem,
|
|
108
|
+
// 20px
|
|
109
|
+
"xl": 1.5rem,
|
|
110
|
+
// 24px
|
|
111
|
+
"2xl": 1.75rem,
|
|
112
|
+
// 28px
|
|
113
|
+
"3xl": 2rem,
|
|
114
|
+
// 32px
|
|
115
|
+
"4xl": 2.5rem, // 40px
|
|
96
116
|
) !default;
|
|
97
117
|
|
|
98
118
|
// Updated spacing map
|
|
99
119
|
$spacings: (
|
|
100
120
|
0: 0,
|
|
101
|
-
1: 0.25rem,
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
121
|
+
1: 0.25rem,
|
|
122
|
+
// 4px
|
|
123
|
+
2: 0.5rem,
|
|
124
|
+
// 8px
|
|
125
|
+
3: 0.75rem,
|
|
126
|
+
// 12px
|
|
127
|
+
4: 1rem,
|
|
128
|
+
// 16px
|
|
129
|
+
5: 1.25rem,
|
|
130
|
+
// 20px
|
|
131
|
+
6: 1.5rem,
|
|
132
|
+
// 24px
|
|
133
|
+
8: 2rem,
|
|
134
|
+
// 32px
|
|
135
|
+
10: 2.5rem,
|
|
136
|
+
// 40px
|
|
137
|
+
12: 3rem,
|
|
138
|
+
// 48px
|
|
139
|
+
16: 4rem,
|
|
140
|
+
// 64px
|
|
141
|
+
20: 5rem,
|
|
142
|
+
// 80px
|
|
143
|
+
24: 6rem,
|
|
144
|
+
// 96px
|
|
145
|
+
32: 8rem,
|
|
146
|
+
// 128px
|
|
147
|
+
40: 10rem,
|
|
148
|
+
// 160px
|
|
149
|
+
48: 12rem,
|
|
150
|
+
// 192px
|
|
151
|
+
56: 14rem,
|
|
152
|
+
// 224px
|
|
153
|
+
64: 16rem, // 256px
|
|
154
|
+
) !default;
|
|
119
155
|
|
|
120
156
|
$percentages: (0, 5, 10, 20, 25, 30, 40, 50, 60, 70, 75, 80, 90, 100) !default;
|
|
121
157
|
|
|
122
|
-
|
|
123
|
-
// if just a number passed, it will be assumed as px
|
|
124
|
-
$default-unit: px !default;
|
|
125
|
-
|
|
126
158
|
// Common border width values that are most useful
|
|
127
159
|
$border-widths: (0, 1, 2, 4, 8) !default;
|
|
128
160
|
|
|
129
161
|
// Common border radius values that are most useful
|
|
130
162
|
$border-radii: (
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
) !default;
|
|
163
|
+
"xs": 0.25rem,
|
|
164
|
+
"sm": 0.375rem,
|
|
165
|
+
"md": 0.5rem,
|
|
166
|
+
"lg": 0.75rem,
|
|
167
|
+
"xl": 1rem,
|
|
168
|
+
"2xl": 1.25rem,
|
|
169
|
+
"full": 9999px,
|
|
170
|
+
"none": 0,
|
|
171
|
+
) !default;
|
|
172
|
+
|
|
173
|
+
$parent-selector: "" !default;
|
|
@@ -13,18 +13,21 @@
|
|
|
13
13
|
@return $string;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
@function get-breakpoint-value($bp) {
|
|
17
|
-
@if map.has-key($breakpoints, $bp) {
|
|
18
|
-
@return map.get($breakpoints, $bp);
|
|
16
|
+
@function get-breakpoint-value($bp, $debug: false) {
|
|
17
|
+
@if map.has-key($breakpoints, #{$bp}) {
|
|
18
|
+
@return map.get($breakpoints, #{$bp});
|
|
19
19
|
} @else if meta.type-of($bp) == number {
|
|
20
20
|
@return $bp;
|
|
21
21
|
} @else {
|
|
22
|
-
@
|
|
22
|
+
@error 'Invalid breakpoint: #{$bp}';
|
|
23
23
|
@return null;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
@function strip-unit($value) {
|
|
28
|
+
@if meta.type-of($value) != number {
|
|
29
|
+
@error "strip-unit() requires a number";
|
|
30
|
+
}
|
|
28
31
|
@return math.div($value, ($value * 0 + 1));
|
|
29
32
|
}
|
|
30
33
|
|
|
@@ -38,83 +41,40 @@
|
|
|
38
41
|
}
|
|
39
42
|
}
|
|
40
43
|
|
|
41
|
-
@function get-unit($value) {
|
|
42
|
-
$value-str: #{$value};
|
|
43
|
-
|
|
44
|
-
// Relative length units
|
|
45
|
-
@if string.index($value-str, "em") {
|
|
46
|
-
@return "em";
|
|
47
|
-
} @else if string.index($value-str, "rem") {
|
|
48
|
-
@return "rem";
|
|
49
|
-
} @else if string.index($value-str, "%") {
|
|
50
|
-
@return "%";
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
// Viewport units
|
|
54
|
-
@else if string.index($value-str, "vw") {
|
|
55
|
-
@return "vw";
|
|
56
|
-
} @else if string.index($value-str, "vh") {
|
|
57
|
-
@return "vh";
|
|
58
|
-
} @else if string.index($value-str, "vmin") {
|
|
59
|
-
@return "vmin";
|
|
60
|
-
} @else if string.index($value-str, "vmax") {
|
|
61
|
-
@return "vmax";
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
// Absolute length units
|
|
65
|
-
@else if string.index($value-str, "px") {
|
|
66
|
-
@return "px";
|
|
67
|
-
} @else if string.index($value-str, "cm") {
|
|
68
|
-
@return "cm";
|
|
69
|
-
} @else if string.index($value-str, "mm") {
|
|
70
|
-
@return "mm";
|
|
71
|
-
} @else if string.index($value-str, "in") {
|
|
72
|
-
@return "in";
|
|
73
|
-
} @else if string.index($value-str, "pt") {
|
|
74
|
-
@return "pt";
|
|
75
|
-
} @else if string.index($value-str, "pc") {
|
|
76
|
-
@return "pc";
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
// Return empty string if no unit found
|
|
80
|
-
@return "";
|
|
81
|
-
}
|
|
82
|
-
|
|
83
44
|
/**
|
|
84
45
|
* Ensures a value has a unit, adding $default-unit if none exists
|
|
85
46
|
* @param {Number|String} $val - The value to check
|
|
86
47
|
* @return {String} - The value with units
|
|
87
48
|
*/
|
|
88
|
-
@function fix-units($val, $unit: $default-unit) {
|
|
89
|
-
|
|
90
|
-
@if meta.type-of($val) != number and meta.type-of($val) != string{
|
|
49
|
+
@function fix-units($val, $unit: $default-unit, $debug: null) {
|
|
50
|
+
@if meta.type-of($val) != number and meta.type-of($val) != string {
|
|
91
51
|
@error "fix-units() requires a number or string value";
|
|
92
52
|
@return null;
|
|
93
53
|
}
|
|
94
54
|
|
|
95
55
|
@if meta.type-of($val) == number {
|
|
96
|
-
@if
|
|
97
|
-
@return
|
|
56
|
+
@if math.is-unitless($val) {
|
|
57
|
+
@return $val + $unit;
|
|
98
58
|
}
|
|
99
59
|
@return $val;
|
|
100
60
|
}
|
|
101
61
|
|
|
102
62
|
$val: strip-quotes($val);
|
|
103
63
|
|
|
104
|
-
@if $val == auto or $val == inherit or $val == initial or
|
|
105
|
-
|
|
106
|
-
@return string.unquote($val);
|
|
64
|
+
@if $val == auto or $val == inherit or $val == initial or $val == "min-content" or $val == "max-content" or $val == "fit-content" {
|
|
65
|
+
@return #{$val};
|
|
107
66
|
}
|
|
108
67
|
|
|
109
|
-
@if string.index($val, "px") or string.index($val, "em") or string.index($val, "rem") or
|
|
110
|
-
|
|
111
|
-
string.index($val, "vmin") or string.index($val, "vmax") {
|
|
112
|
-
@return string.unquote($val);
|
|
68
|
+
@if string.index($val, "px") or string.index($val, "em") or string.index($val, "rem") or string.index($val, "%") or string.index($val, "vh") or string.index($val, "vw") or string.index($val, "vmin") or string.index($val, "vmax") {
|
|
69
|
+
@return #{$val};
|
|
113
70
|
}
|
|
114
71
|
|
|
115
|
-
@
|
|
116
|
-
|
|
72
|
+
@if $debug {
|
|
73
|
+
@debug "fix-units() value: " + $val;
|
|
74
|
+
}
|
|
117
75
|
|
|
76
|
+
@return string.unquote($val + $unit);
|
|
77
|
+
}
|
|
118
78
|
|
|
119
79
|
@function strip-quotes($string) {
|
|
120
80
|
@if meta.type-of($string) == string {
|
|
@@ -150,5 +110,5 @@
|
|
|
150
110
|
$index: string.index($string, $delimiter);
|
|
151
111
|
}
|
|
152
112
|
|
|
153
|
-
@return list.append($result, str-trim($string));
|
|
113
|
+
@return list.append($result, str-trim($string));
|
|
154
114
|
}
|
|
@@ -1,104 +1,111 @@
|
|
|
1
|
-
@use
|
|
1
|
+
@use "sass:map";
|
|
2
2
|
|
|
3
3
|
/* Import variables */
|
|
4
|
-
@use
|
|
5
|
-
@use
|
|
6
|
-
|
|
4
|
+
@use "../abstracts/config" as *;
|
|
5
|
+
@use "../utilities/media-queries" as media;
|
|
6
|
+
|
|
7
7
|
:root {
|
|
8
8
|
--font-family-base: #{$font-family};
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
// Base typography styles
|
|
12
12
|
html {
|
|
13
|
-
font-size: $base-size;
|
|
13
|
+
font-size: $base-size;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
body {
|
|
16
|
+
body#{$parent-selector} {
|
|
17
17
|
font-family: var(--font-family-base);
|
|
18
18
|
font-weight: 400;
|
|
19
19
|
line-height: 1.5;
|
|
20
|
-
color: var(--text-
|
|
20
|
+
color: var(--text-default);
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
// Headings
|
|
24
|
-
h1,
|
|
24
|
+
#{$parent-selector} h1,
|
|
25
|
+
#{$parent-selector} h2,
|
|
26
|
+
#{$parent-selector} h3,
|
|
27
|
+
#{$parent-selector} h4,
|
|
28
|
+
#{$parent-selector} h5,
|
|
29
|
+
#{$parent-selector} h6 {
|
|
25
30
|
margin-bottom: 0.5em;
|
|
26
31
|
font-family: var(--font-family-heading);
|
|
27
32
|
font-weight: 700;
|
|
28
33
|
line-height: 1.2;
|
|
29
34
|
}
|
|
30
35
|
|
|
31
|
-
h1 {
|
|
32
|
-
font-size: map.get($font-sizes,
|
|
36
|
+
#{$parent-selector} h1 {
|
|
37
|
+
font-size: map.get($font-sizes, "4xl");
|
|
33
38
|
}
|
|
34
39
|
|
|
35
|
-
h2 {
|
|
36
|
-
font-size: map.get($font-sizes,
|
|
40
|
+
#{$parent-selector} h2 {
|
|
41
|
+
font-size: map.get($font-sizes, "3xl");
|
|
37
42
|
}
|
|
38
43
|
|
|
39
|
-
h3 {
|
|
40
|
-
font-size: map.get($font-sizes,
|
|
44
|
+
#{$parent-selector} h3 {
|
|
45
|
+
font-size: map.get($font-sizes, "2xl");
|
|
41
46
|
}
|
|
42
47
|
|
|
43
|
-
h4 {
|
|
44
|
-
font-size: map.get($font-sizes,
|
|
48
|
+
#{$parent-selector} h4 {
|
|
49
|
+
font-size: map.get($font-sizes, "xl");
|
|
45
50
|
}
|
|
46
51
|
|
|
47
|
-
h5 {
|
|
48
|
-
font-size: map.get($font-sizes,
|
|
52
|
+
#{$parent-selector} h5 {
|
|
53
|
+
font-size: map.get($font-sizes, "lg");
|
|
49
54
|
}
|
|
50
55
|
|
|
51
|
-
h6 {
|
|
52
|
-
font-size: map.get($font-sizes,
|
|
56
|
+
#{$parent-selector} h6 {
|
|
57
|
+
font-size: map.get($font-sizes, "base");
|
|
53
58
|
}
|
|
54
59
|
|
|
55
60
|
// Paragraphs
|
|
56
|
-
p {
|
|
61
|
+
#{$parent-selector} p {
|
|
57
62
|
margin-bottom: 1rem;
|
|
58
63
|
}
|
|
59
64
|
|
|
60
65
|
// Small text
|
|
61
|
-
small {
|
|
62
|
-
font-size: map.get($font-sizes,
|
|
66
|
+
#{$parent-selector} small {
|
|
67
|
+
font-size: map.get($font-sizes, "sm");
|
|
63
68
|
}
|
|
64
69
|
|
|
65
70
|
// Buttons
|
|
66
|
-
button {
|
|
71
|
+
#{$parent-selector} button {
|
|
67
72
|
padding: 0.5rem 1rem;
|
|
68
73
|
border: 0;
|
|
69
74
|
border-radius: 0.25rem;
|
|
70
75
|
font-family: var(--font-family-base);
|
|
71
76
|
cursor: pointer;
|
|
72
|
-
transition:
|
|
73
|
-
|
|
77
|
+
transition:
|
|
78
|
+
background-color 0.2s ease-in-out,
|
|
79
|
+
color 0.2s ease-in-out;
|
|
80
|
+
|
|
74
81
|
&:focus {
|
|
75
82
|
outline: none;
|
|
76
83
|
}
|
|
77
84
|
|
|
78
85
|
&:disabled {
|
|
79
|
-
background-color: #
|
|
80
|
-
color: #
|
|
86
|
+
background-color: #e0e0e0; // Disabled button color
|
|
87
|
+
color: #a0a0a0; // Disabled text color
|
|
81
88
|
cursor: not-allowed;
|
|
82
89
|
}
|
|
83
90
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
background-color: var(--button-bg-color, #
|
|
87
|
-
color: var(--button-text-color, #
|
|
88
|
-
|
|
91
|
+
// Default styling when no bg-* class is present
|
|
92
|
+
&:not([class*="bg-"]) {
|
|
93
|
+
background-color: var(--button-bg-color, #007bff); // Default button color
|
|
94
|
+
color: var(--button-text-color, #fff);
|
|
95
|
+
|
|
89
96
|
&:hover {
|
|
90
|
-
background-color: var(--button-bg-color-hover, #
|
|
97
|
+
background-color: var(--button-bg-color-hover, #0056b3);
|
|
91
98
|
}
|
|
92
99
|
}
|
|
93
100
|
}
|
|
94
101
|
|
|
95
102
|
// Inputs
|
|
96
|
-
input[type="text"],
|
|
97
|
-
input[type="email"],
|
|
98
|
-
input[type="password"],
|
|
99
|
-
input[type="number"],
|
|
100
|
-
input[type="search"],
|
|
101
|
-
textarea {
|
|
103
|
+
#{$parent-selector} input[type="text"],
|
|
104
|
+
#{$parent-selector} input[type="email"],
|
|
105
|
+
#{$parent-selector} input[type="password"],
|
|
106
|
+
#{$parent-selector} input[type="number"],
|
|
107
|
+
#{$parent-selector} input[type="search"],
|
|
108
|
+
#{$parent-selector} textarea {
|
|
102
109
|
padding: 0.5rem;
|
|
103
110
|
border: 1px solid var(--border);
|
|
104
111
|
border-radius: 0.25rem;
|
|
@@ -113,13 +120,13 @@ textarea {
|
|
|
113
120
|
}
|
|
114
121
|
|
|
115
122
|
// Checkboxes and Radio Buttons
|
|
116
|
-
input[type="checkbox"],
|
|
117
|
-
input[type="radio"] {
|
|
123
|
+
#{$parent-selector} input[type="checkbox"],
|
|
124
|
+
#{$parent-selector} input[type="radio"] {
|
|
118
125
|
margin-right: 0.5rem; // Space between input and label
|
|
119
126
|
}
|
|
120
127
|
|
|
121
128
|
// Selects
|
|
122
|
-
select {
|
|
129
|
+
#{$parent-selector} select {
|
|
123
130
|
padding: 0.5rem;
|
|
124
131
|
border: 1px solid var(--border);
|
|
125
132
|
border-radius: 0.25rem;
|
|
@@ -134,7 +141,7 @@ select {
|
|
|
134
141
|
}
|
|
135
142
|
|
|
136
143
|
// Blockquotes
|
|
137
|
-
blockquote {
|
|
144
|
+
#{$parent-selector} blockquote {
|
|
138
145
|
margin: 1rem 0;
|
|
139
146
|
padding: 0.5rem 1rem;
|
|
140
147
|
border-left: 4px solid var(--border);
|
|
@@ -142,33 +149,34 @@ blockquote {
|
|
|
142
149
|
}
|
|
143
150
|
|
|
144
151
|
// Horizontal Rule
|
|
145
|
-
hr {
|
|
152
|
+
#{$parent-selector} hr {
|
|
146
153
|
border: none;
|
|
147
154
|
border-top: 1px solid var(--border);
|
|
148
155
|
margin: 1rem 0;
|
|
149
156
|
}
|
|
150
157
|
|
|
151
158
|
// Images
|
|
152
|
-
img {
|
|
159
|
+
#{$parent-selector} img {
|
|
153
160
|
max-width: 100%; // Responsive images
|
|
154
161
|
height: auto;
|
|
155
162
|
}
|
|
156
163
|
|
|
157
164
|
// Figures and Captions
|
|
158
|
-
figure {
|
|
165
|
+
#{$parent-selector} figure {
|
|
159
166
|
margin: 1rem 0;
|
|
160
167
|
}
|
|
161
168
|
|
|
162
|
-
figcaption {
|
|
169
|
+
#{$parent-selector} figcaption {
|
|
163
170
|
font-size: 0.875rem; // Smaller font for captions
|
|
164
|
-
color: var(--text-
|
|
171
|
+
color: var(--text-muted, #666); // Optional secondary text color
|
|
165
172
|
}
|
|
166
173
|
|
|
167
174
|
// Links
|
|
168
|
-
a {
|
|
175
|
+
#{$parent-selector} a {
|
|
169
176
|
transition: color 0.2s ease-in-out;
|
|
170
177
|
|
|
171
|
-
&:not([class*="text-"]){
|
|
178
|
+
&:not([class*="text-"]) {
|
|
179
|
+
// document: if no hover or normal text provided it will use the default link color
|
|
172
180
|
color: var(--link-color);
|
|
173
181
|
|
|
174
182
|
&:hover {
|
|
@@ -178,12 +186,12 @@ a {
|
|
|
178
186
|
}
|
|
179
187
|
|
|
180
188
|
// Labels
|
|
181
|
-
label[for] {
|
|
189
|
+
#{$parent-selector} label[for] {
|
|
182
190
|
cursor: pointer;
|
|
183
191
|
}
|
|
184
192
|
|
|
185
193
|
// todo: add to doc
|
|
186
|
-
.sr-only {
|
|
194
|
+
#{$parent-selector} .sr-only {
|
|
187
195
|
position: absolute !important;
|
|
188
196
|
width: 1px !important;
|
|
189
197
|
height: 1px !important;
|
|
@@ -195,16 +203,16 @@ label[for] {
|
|
|
195
203
|
border: 0 !important;
|
|
196
204
|
}
|
|
197
205
|
|
|
198
|
-
code {
|
|
199
|
-
font-family:
|
|
200
|
-
background-color: #f8f8f8;
|
|
201
|
-
color: #d63384;
|
|
206
|
+
#{$parent-selector} code {
|
|
207
|
+
font-family: "Courier New", Courier, monospace;
|
|
208
|
+
background-color: #f8f8f8;
|
|
209
|
+
color: #d63384;
|
|
202
210
|
padding: 2px 6px;
|
|
203
211
|
border-radius: 3px;
|
|
204
212
|
white-space: nowrap;
|
|
205
213
|
|
|
206
214
|
@include media.dark-mode {
|
|
207
|
-
background-color: #333;
|
|
208
|
-
color: #f8f8f2;
|
|
215
|
+
background-color: #333;
|
|
216
|
+
color: #f8f8f2;
|
|
209
217
|
}
|
|
210
218
|
}
|
|
@@ -9,7 +9,6 @@
|
|
|
9
9
|
padding: 0;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
|
|
13
12
|
// Remove default margin and padding
|
|
14
13
|
body,
|
|
15
14
|
h1,
|
|
@@ -27,7 +26,7 @@ dd {
|
|
|
27
26
|
padding: 0;
|
|
28
27
|
}
|
|
29
28
|
|
|
30
|
-
// Prevent font size inflation
|
|
29
|
+
// Prevent font size inflation
|
|
31
30
|
html {
|
|
32
31
|
-moz-text-size-adjust: none; /* stylelint-disable-line */
|
|
33
32
|
-webkit-text-size-adjust: none; /* stylelint-disable-line */
|
|
@@ -50,8 +49,13 @@ body {
|
|
|
50
49
|
}
|
|
51
50
|
|
|
52
51
|
// Set shorter line heights on headings and interactive elements
|
|
53
|
-
h1,
|
|
54
|
-
|
|
52
|
+
h1,
|
|
53
|
+
h2,
|
|
54
|
+
h3,
|
|
55
|
+
h4,
|
|
56
|
+
button,
|
|
57
|
+
input,
|
|
58
|
+
label {
|
|
55
59
|
line-height: 1.1;
|
|
56
60
|
}
|
|
57
61
|
|
|
@@ -91,8 +95,8 @@ select {
|
|
|
91
95
|
}
|
|
92
96
|
|
|
93
97
|
// Remove list styles on ul, ol elements with a list role, which suggests default styling will be removed
|
|
94
|
-
ul[role=
|
|
95
|
-
ol[role=
|
|
98
|
+
ul[role="list"],
|
|
99
|
+
ol[role="list"] {
|
|
96
100
|
list-style: none;
|
|
97
101
|
margin: 0;
|
|
98
102
|
padding: 0;
|
|
@@ -100,7 +104,7 @@ ol[role='list'] {
|
|
|
100
104
|
// Modern properties
|
|
101
105
|
padding-inline-start: 0; // Replaces padding-left
|
|
102
106
|
margin-block: 0; // Replaces margin-top/bottom
|
|
103
|
-
|
|
107
|
+
|
|
104
108
|
& > li {
|
|
105
109
|
margin: 0;
|
|
106
110
|
padding: 0;
|
|
@@ -125,7 +129,6 @@ textarea:not([rows]) {
|
|
|
125
129
|
scroll-margin-block: 5ex;
|
|
126
130
|
}
|
|
127
131
|
|
|
128
|
-
|
|
129
132
|
// Remove all animations and transitions for people that prefer not to see them
|
|
130
133
|
@media (prefers-reduced-motion: reduce) {
|
|
131
134
|
*,
|
package/src/styles/index.scss
CHANGED
|
@@ -1,16 +1,34 @@
|
|
|
1
|
-
|
|
2
|
-
@forward "abstracts";
|
|
1
|
+
@forward "abstracts/config";
|
|
2
|
+
@forward "abstracts/functions";
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
@forward "base";
|
|
4
|
+
@forward "base/reset";
|
|
5
|
+
@forward "base/base";
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
@forward "
|
|
7
|
+
@forward "layouts/container";
|
|
8
|
+
@forward "layouts/flex";
|
|
9
|
+
@forward "layouts/grid";
|
|
9
10
|
|
|
10
|
-
|
|
11
|
-
@forward "
|
|
11
|
+
@forward "utilities/opacity";
|
|
12
|
+
@forward "utilities/helpers";
|
|
13
|
+
@forward "utilities/alignment";
|
|
14
|
+
@forward "utilities/backdrop-filters";
|
|
15
|
+
@forward "utilities/borders";
|
|
16
|
+
@forward "utilities/colors";
|
|
17
|
+
@forward "utilities/container-queries";
|
|
18
|
+
@forward "utilities/cursor";
|
|
19
|
+
@forward "utilities/display";
|
|
20
|
+
@forward "utilities/shadows";
|
|
21
|
+
@forward "utilities/sizing";
|
|
22
|
+
@forward "utilities/tooltips";
|
|
23
|
+
@forward "utilities/transforms";
|
|
24
|
+
@forward "utilities/transitions";
|
|
25
|
+
@forward "utilities/typography";
|
|
26
|
+
@forward "utilities/z-index";
|
|
27
|
+
@forward "utilities/spacing";
|
|
28
|
+
@forward "utilities/media-queries";
|
|
29
|
+
@forward "utilities/animations";
|
|
30
|
+
@forward "utilities/position";
|
|
12
31
|
|
|
13
|
-
|
|
14
|
-
@forward "utilities";
|
|
32
|
+
@forward "themes/theme";
|
|
15
33
|
|
|
16
34
|
@forward "./mixins-map";
|