@semanticus/semanticus-css 0.8.0 → 1.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.
Files changed (166) hide show
  1. package/NOTICE +16 -16
  2. package/README.md +128 -29
  3. package/dist/semanticus-no-utilities.css +11 -0
  4. package/dist/semanticus-semantics.css +3 -4
  5. package/dist/semanticus-utilities.css +11 -0
  6. package/dist/semanticus.css +4 -12
  7. package/dist/semanticus.palette.amber.css +1 -1
  8. package/dist/semanticus.palette.azure.css +1 -0
  9. package/dist/semanticus.palette.blue.css +1 -1
  10. package/dist/semanticus.palette.cyan.css +1 -1
  11. package/dist/semanticus.palette.fuchsia.css +1 -1
  12. package/dist/semanticus.palette.green.css +1 -1
  13. package/dist/semanticus.palette.grey.css +1 -1
  14. package/dist/semanticus.palette.indigo.css +1 -1
  15. package/dist/semanticus.palette.jade.css +1 -1
  16. package/dist/semanticus.palette.lime.css +1 -1
  17. package/dist/semanticus.palette.orange.css +1 -1
  18. package/dist/semanticus.palette.pink.css +1 -1
  19. package/dist/semanticus.palette.pumpkin.css +1 -1
  20. package/dist/semanticus.palette.purple.css +1 -1
  21. package/dist/semanticus.palette.red.css +1 -1
  22. package/dist/semanticus.palette.sand.css +1 -1
  23. package/dist/semanticus.palette.slate.css +1 -1
  24. package/dist/semanticus.palette.violet.css +1 -1
  25. package/dist/semanticus.palette.yellow.css +1 -1
  26. package/dist/semanticus.palette.zinc.css +1 -1
  27. package/dist/semanticus.size.pico.css +1 -1
  28. package/package.json +28 -16
  29. package/src/components/_card.css +84 -0
  30. package/src/components/_sidebar.css +49 -0
  31. package/src/components/modules.css +2 -0
  32. package/src/index.css +8 -10
  33. package/src/no-utilities.css +22 -0
  34. package/src/palettes/amber.css +28 -53
  35. package/src/palettes/azure.css +31 -0
  36. package/src/palettes/blue.css +28 -53
  37. package/src/palettes/cyan.css +28 -53
  38. package/src/palettes/fuchsia.css +28 -53
  39. package/src/palettes/green.css +28 -53
  40. package/src/palettes/grey.css +28 -53
  41. package/src/palettes/indigo.css +28 -53
  42. package/src/palettes/jade.css +28 -53
  43. package/src/palettes/lime.css +28 -53
  44. package/src/palettes/orange.css +28 -53
  45. package/src/palettes/pink.css +28 -53
  46. package/src/palettes/pumpkin.css +28 -53
  47. package/src/palettes/purple.css +28 -53
  48. package/src/palettes/red.css +28 -53
  49. package/src/palettes/sand.css +28 -53
  50. package/src/palettes/slate.css +28 -53
  51. package/src/palettes/violet.css +28 -53
  52. package/src/palettes/yellow.css +28 -53
  53. package/src/palettes/zinc.css +28 -53
  54. package/src/semantics/{_aria-busy.css → attributes/_aria-busy.css} +0 -3
  55. package/src/semantics/{_hidden.css → attributes/_hidden.css} +0 -3
  56. package/src/semantics/attributes/_popover.css +13 -0
  57. package/src/semantics/attributes/_role-group-search.css +137 -0
  58. package/src/semantics/{_role-toolbar.css → attributes/_role-toolbar.css} +2 -5
  59. package/src/semantics/{_role-tooltip.css → attributes/_role-tooltip.css} +6 -9
  60. package/src/semantics/elements/_abbr.css +5 -0
  61. package/src/semantics/elements/_address.css +7 -0
  62. package/src/semantics/elements/_article.css +3 -0
  63. package/src/semantics/elements/_aside.css +10 -0
  64. package/src/semantics/elements/_blockquote.css +18 -0
  65. package/src/semantics/elements/_body.css +5 -0
  66. package/src/semantics/{_button.css → elements/_button.css} +23 -26
  67. package/src/semantics/{_code.css → elements/_code.css} +11 -11
  68. package/src/semantics/elements/_del.css +3 -0
  69. package/src/semantics/{_details.css → elements/_details.css} +42 -43
  70. package/src/semantics/elements/_dialog.css +113 -0
  71. package/src/semantics/{_document.css → elements/_document.css} +10 -4
  72. package/src/semantics/{_embedded.css → elements/_embedded.css} +0 -3
  73. package/src/semantics/{_figure.css → elements/_figure.css} +0 -3
  74. package/src/semantics/elements/_footer.css +10 -0
  75. package/src/semantics/elements/_header.css +10 -0
  76. package/src/semantics/elements/_headings.css +24 -0
  77. package/src/semantics/elements/_hgroup.css +14 -0
  78. package/src/semantics/{_hr.css → elements/_hr.css} +1 -4
  79. package/src/semantics/{_input.css → elements/_input.css} +34 -38
  80. package/src/semantics/elements/_ins.css +4 -0
  81. package/src/semantics/elements/_links.css +61 -0
  82. package/src/semantics/elements/_lists.css +22 -0
  83. package/src/semantics/elements/_main.css +3 -0
  84. package/src/semantics/elements/_mark.css +6 -0
  85. package/src/semantics/{_nav.css → elements/_nav.css} +5 -8
  86. package/src/semantics/elements/_p.css +11 -0
  87. package/src/semantics/{_progress.css → elements/_progress.css} +5 -8
  88. package/src/semantics/elements/_section.css +4 -0
  89. package/src/semantics/elements/_small.css +3 -0
  90. package/src/semantics/elements/_strong.css +4 -0
  91. package/src/semantics/elements/_sub.css +7 -0
  92. package/src/semantics/elements/_sup.css +7 -0
  93. package/src/semantics/{_table.css → elements/_table.css} +10 -7
  94. package/src/semantics/{_type-checkbox-radio.css → elements/_type-checkbox-radio.css} +19 -22
  95. package/src/semantics/{_type-color.css → elements/_type-color.css} +2 -5
  96. package/src/semantics/{_type-date.css → elements/_type-date.css} +1 -4
  97. package/src/semantics/elements/_type-file.css +23 -0
  98. package/src/semantics/{_type-range.css → elements/_type-range.css} +11 -14
  99. package/src/semantics/elements/_type-search.css +30 -0
  100. package/src/semantics/index.css +2 -5
  101. package/src/semantics/modules.css +46 -37
  102. package/src/sizes/pico.css +21 -29
  103. package/src/utilities/_grid.css +306 -0
  104. package/src/utilities/_variables.css +27 -42
  105. package/src/utilities/borders/_border-radius.css +54 -79
  106. package/src/utilities/borders/_border-style.css +15 -5
  107. package/src/utilities/borders/_border-width.css +0 -28
  108. package/src/utilities/colors/_bg-colors.css +75 -0
  109. package/src/utilities/colors/_border-colors.css +17 -39
  110. package/src/utilities/colors/_subtle-colors.css +145 -0
  111. package/src/utilities/colors/_text-bg-colors.css +62 -0
  112. package/src/utilities/colors/_text-colors.css +32 -409
  113. package/src/utilities/effects/_focus-ring.css +33 -0
  114. package/src/utilities/effects/_shadows.css +0 -33
  115. package/src/utilities/index.css +16 -0
  116. package/src/utilities/layout/_misc.css +2 -5
  117. package/src/utilities/layout/{_grid.css → _ratio.css} +0 -19
  118. package/src/utilities/modules.css +9 -3
  119. package/src/utilities/sizing/_width.css +8 -0
  120. package/src/utilities/spacing/_gap.css +144 -144
  121. package/src/utilities/spacing/_margin.css +324 -324
  122. package/src/utilities/spacing/_padding.css +324 -324
  123. package/src/utilities/typography/_font-sizes.css +6 -6
  124. package/src/variables/_all.css +2 -20
  125. package/src/variables/_elements.css +29 -33
  126. package/src/variables/_theme.css +336 -0
  127. package/src/variants/_variables.css +24 -0
  128. package/src/variants/intent/_contrast.css +46 -0
  129. package/src/variants/intent/_danger.css +38 -0
  130. package/src/variants/intent/_info.css +38 -0
  131. package/src/variants/intent/_primary.css +38 -0
  132. package/src/variants/intent/_secondary.css +38 -0
  133. package/src/variants/intent/_success.css +38 -0
  134. package/src/variants/intent/_warning.css +38 -0
  135. package/src/variants/{_container.css → modifiers/_container.css} +3 -10
  136. package/src/variants/modifiers/_ghost.css +164 -0
  137. package/src/variants/modifiers/_striped.css +11 -0
  138. package/src/variants/modifiers/_subtle.css +133 -0
  139. package/src/variants/modules.css +12 -15
  140. package/src/_normalize.css +0 -214
  141. package/src/semantics/_article.css +0 -12
  142. package/src/semantics/_aside.css +0 -16
  143. package/src/semantics/_body.css +0 -8
  144. package/src/semantics/_dialog.css +0 -157
  145. package/src/semantics/_footer.css +0 -12
  146. package/src/semantics/_header.css +0 -12
  147. package/src/semantics/_links.css +0 -50
  148. package/src/semantics/_main.css +0 -10
  149. package/src/semantics/_role-group-search.css +0 -129
  150. package/src/semantics/_section.css +0 -9
  151. package/src/semantics/_type-file.css +0 -26
  152. package/src/semantics/_type-search.css +0 -34
  153. package/src/semantics/_typography.css +0 -146
  154. package/src/utilities/colors/_background-colors.css +0 -248
  155. package/src/variables/_colors.css +0 -366
  156. package/src/variables/_components.css +0 -318
  157. package/src/variables/_icons.css +0 -43
  158. package/src/variables/_layout.css +0 -128
  159. package/src/variants/_card.css +0 -45
  160. package/src/variants/_contained.css +0 -43
  161. package/src/variants/_contrast.css +0 -47
  162. package/src/variants/_ghost.css +0 -61
  163. package/src/variants/_panel.css +0 -18
  164. package/src/variants/_secondary.css +0 -35
  165. package/src/variants/_sidebar.css +0 -11
  166. package/src/variants/_striped.css +0 -10
@@ -1,214 +0,0 @@
1
- /*! modern-normalize v3.0.1 | MIT License | https://github.com/sindresorhus/modern-normalize */
2
-
3
- /*
4
- Document
5
- ========
6
- */
7
-
8
- /**
9
- Use a better box model (opinionated).
10
- */
11
-
12
- *,
13
- ::before,
14
- ::after {
15
- box-sizing: border-box;
16
- }
17
-
18
- html {
19
- /* Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3) */
20
- font-family:
21
- system-ui,
22
- 'Segoe UI',
23
- Roboto,
24
- Helvetica,
25
- Arial,
26
- sans-serif,
27
- 'Apple Color Emoji',
28
- 'Segoe UI Emoji';
29
- line-height: 1.15; /* 1. Correct the line height in all browsers. */
30
- -webkit-text-size-adjust: 100%; /* 2. Prevent adjustments of font size after orientation changes in iOS. */
31
- tab-size: 4; /* 3. Use a more readable tab size (opinionated). */
32
- }
33
-
34
- /*
35
- Sections
36
- ========
37
- */
38
-
39
- body {
40
- margin: 0; /* Remove the margin in all browsers. */
41
- }
42
-
43
- /*
44
- Text-level semantics
45
- ====================
46
- */
47
-
48
- /**
49
- Add the correct font weight in Chrome and Safari.
50
- */
51
-
52
- b,
53
- strong {
54
- font-weight: bolder;
55
- }
56
-
57
- /**
58
- 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
59
- 2. Correct the odd 'em' font sizing in all browsers.
60
- */
61
-
62
- code,
63
- kbd,
64
- samp,
65
- pre {
66
- font-family:
67
- ui-monospace,
68
- SFMono-Regular,
69
- Consolas,
70
- 'Liberation Mono',
71
- Menlo,
72
- monospace; /* 1 */
73
-
74
- font-size: 1em; /* 2 */
75
- }
76
-
77
- /**
78
- Add the correct font size in all browsers.
79
- */
80
-
81
- small {
82
- font-size: 80%;
83
- }
84
-
85
- /**
86
- Prevent 'sub' and 'sup' elements from affecting the line height in all browsers.
87
- */
88
-
89
- sub,
90
- sup {
91
- font-size: 75%;
92
- line-height: 0;
93
- position: relative;
94
- vertical-align: baseline;
95
- }
96
-
97
- sub {
98
- bottom: -0.25em;
99
- }
100
-
101
- sup {
102
- top: -0.5em;
103
- }
104
-
105
- /*
106
- Tabular data
107
- ============
108
- */
109
-
110
- /**
111
- Correct table border color inheritance in Chrome and Safari. (https://issues.chromium.org/issues/40615503, https://bugs.webkit.org/show_bug.cgi?id=195016)
112
- */
113
-
114
- table {
115
- border-color: currentcolor;
116
- }
117
-
118
- /*
119
- Forms
120
- =====
121
- */
122
-
123
- /**
124
- 1. Change the font styles in all browsers.
125
- 2. Remove the margin in Firefox and Safari.
126
- */
127
-
128
- button,
129
- input,
130
- optgroup,
131
- select,
132
- textarea {
133
- font-family: inherit; /* 1 */
134
- font-size: 100%; /* 1 */
135
- line-height: 1.15; /* 1 */
136
- margin: 0; /* 2 */
137
- }
138
-
139
- /**
140
- Correct the inability to style clickable types in iOS and Safari.
141
- */
142
-
143
- button,
144
- [type='button'],
145
- [type='reset'],
146
- [type='submit'] {
147
- -webkit-appearance: button;
148
- }
149
-
150
- /**
151
- Remove the padding so developers are not caught out when they zero out 'fieldset' elements in all browsers.
152
- */
153
-
154
- legend {
155
- padding: 0;
156
- }
157
-
158
- /**
159
- Add the correct vertical alignment in Chrome and Firefox.
160
- */
161
-
162
- progress {
163
- vertical-align: baseline;
164
- }
165
-
166
- /**
167
- Correct the cursor style of increment and decrement buttons in Safari.
168
- */
169
-
170
- ::-webkit-inner-spin-button,
171
- ::-webkit-outer-spin-button {
172
- height: auto;
173
- }
174
-
175
- /**
176
- 1. Correct the odd appearance in Chrome and Safari.
177
- 2. Correct the outline style in Safari.
178
- */
179
-
180
- [type='search'] {
181
- -webkit-appearance: textfield; /* 1 */
182
- outline-offset: -2px; /* 2 */
183
- }
184
-
185
- /**
186
- Remove the inner padding in Chrome and Safari on macOS.
187
- */
188
-
189
- ::-webkit-search-decoration {
190
- -webkit-appearance: none;
191
- }
192
-
193
- /**
194
- 1. Correct the inability to style clickable types in iOS and Safari.
195
- 2. Change font properties to 'inherit' in Safari.
196
- */
197
-
198
- ::-webkit-file-upload-button {
199
- -webkit-appearance: button; /* 1 */
200
- font: inherit; /* 2 */
201
- }
202
-
203
- /*
204
- Interactive
205
- ===========
206
- */
207
-
208
- /*
209
- Add the correct display in Chrome and Safari.
210
- */
211
-
212
- summary {
213
- display: list-item;
214
- }
@@ -1,12 +0,0 @@
1
- /**
2
- * Article fills up the available width, and stretches to fill the available height.
3
- * Stacks its children vertically.
4
- */
5
- article {
6
- --block-spacing-vertical: calc(var(--spacing) * var(--responsive-multiplier));
7
- --block-spacing-horizontal: calc(var(--spacing) * var(--responsive-multiplier));
8
-
9
- width: 100%;
10
- padding-block: var(--block-spacing-vertical);
11
- padding-inline: var(--block-spacing-horizontal);
12
- }
@@ -1,16 +0,0 @@
1
- /**
2
- * Aside its width changes according to certain breakpoints,
3
- * and its height grows to fill the available space,
4
- * and stacks its children in a column with space between them (like a <nav> would).
5
- * In case of a single child, this child will fill the entire height.
6
- */
7
- aside {
8
- padding-inline: var(--block-spacing-horizontal);
9
- width: var(--sidebar-width) !important;
10
-
11
- :where(ol, ul, li) {
12
- align-items: stretch !important;
13
- display: flex;
14
- flex-direction: column;
15
- }
16
- }
@@ -1,8 +0,0 @@
1
- /**
2
- * Body fills up the available width, and has the same height as the viewport.
3
- * Stacks its children vertically.
4
- */
5
- body {
6
- width: 100%;
7
- min-height: 100svh;
8
- }
@@ -1,157 +0,0 @@
1
- /**
2
- * Modal (<dialog>)
3
- */
4
-
5
- /* Prevent body scroll and interaction when modal is open */
6
- /* Uses :has() for automatic detection - no classes needed */
7
- /* Accounts for both [open] attribute (JS) and :target (CSS-only) */
8
- body:has(dialog[open]),
9
- body:has(dialog:target) {
10
- overflow: hidden;
11
- pointer-events: none;
12
- touch-action: none;
13
-
14
- & dialog[open],
15
- & dialog:target {
16
- pointer-events: auto;
17
- touch-action: auto;
18
- }
19
- }
20
-
21
- dialog {
22
- display: flex;
23
- z-index: 999;
24
- position: fixed;
25
- top: 0;
26
- right: 0;
27
- bottom: 0;
28
- left: 0;
29
- align-items: center;
30
- justify-content: center;
31
- width: inherit;
32
- min-width: 100%;
33
- height: inherit;
34
- min-height: 100%;
35
- padding: 0;
36
- border: 0;
37
- backdrop-filter: var(--modal-overlay-backdrop-filter);
38
- background-color: var(--modal-overlay-bg);
39
- color: var(--color-text);
40
-
41
- /* Modal content box - styled like a card */
42
- /* Works with: <dialog><article>...</article></dialog> */
43
- & > article {
44
- position: relative;
45
- width: 100%;
46
- max-height: calc(100vh - var(--spacing) * 2);
47
- margin: var(--spacing);
48
- padding: var(--block-spacing-vertical) var(--block-spacing-horizontal);
49
- overflow: auto;
50
- border-radius: var(--border-radius);
51
- background: var(--card-bg);
52
- box-shadow: var(--card-shadow);
53
-
54
- @media (--breakpoint-sm) {
55
- max-width: 510px;
56
- }
57
-
58
- @media (--breakpoint-md) {
59
- max-width: 700px;
60
- }
61
-
62
- /* Header styling */
63
- & > header {
64
- width: calc(100% + var(--block-spacing-horizontal) * 2);
65
- margin: calc(var(--block-spacing-vertical) * -1) calc(var(--block-spacing-horizontal) * -1) var(--block-spacing-vertical);
66
- padding: calc(var(--block-spacing-vertical) * 0.66) var(--block-spacing-horizontal);
67
- background-color: var(--card-section-bg);
68
- border-bottom: var(--border-width) solid var(--card-border);
69
- border-top-right-radius: var(--border-radius);
70
- border-top-left-radius: var(--border-radius);
71
-
72
- & > * {
73
- margin-bottom: 0;
74
- }
75
- }
76
-
77
- /* Footer styling */
78
- & > footer {
79
- width: calc(100% + var(--block-spacing-horizontal) * 2);
80
- margin: var(--block-spacing-vertical) calc(var(--block-spacing-horizontal) * -1) calc(var(--block-spacing-vertical) * -1);
81
- padding: calc(var(--block-spacing-vertical) * 0.66) var(--block-spacing-horizontal);
82
- background-color: var(--card-section-bg);
83
- border-top: var(--border-width) solid var(--card-border);
84
- border-bottom-right-radius: var(--border-radius);
85
- border-bottom-left-radius: var(--border-radius);
86
- text-align: right;
87
-
88
- & :where(button, [role=button]) {
89
- margin-bottom: 0;
90
-
91
- &:not(:first-of-type) {
92
- margin-left: calc(var(--spacing) * 0.5);
93
- }
94
- }
95
- }
96
-
97
- /* Close button styling */
98
- & :is(a, button)[rel=prev]:not([role=button]) {
99
- margin: 0;
100
- padding: 0;
101
- position: absolute;
102
- display: block;
103
- width: 1rem;
104
- height: 1rem;
105
- top: calc(var(--block-spacing-vertical) * .66);
106
- right: var(--block-spacing-horizontal);
107
- border: none;
108
- border-radius: 0;
109
- background-image: var(--icon-close);
110
- background-position: center;
111
- background-size: auto 1rem;
112
- background-repeat: no-repeat;
113
- background-color: transparent;
114
- box-shadow: none;
115
- opacity: 0.5;
116
- transition: opacity var(--transition);
117
-
118
- &:hover {
119
- opacity: 1;
120
- }
121
- }
122
- }
123
-
124
- /* Hidden state */
125
- &:not([open]),
126
- &[open=false] {
127
- display: none;
128
- }
129
-
130
- /* CSS-only modal triggering using :target pseudo-class */
131
- /* When dialog is targeted via anchor link (e.g., <a href="#modal-id">) */
132
- &:target {
133
- display: flex;
134
- }
135
- }
136
-
137
- /* Opening animation using @starting-style (Chrome 117+, Firefox 129+, Safari 17.4+) */
138
- /* Gracefully degrades to instant appearance in unsupported browsers */
139
- dialog {
140
- transition: opacity 0.2s ease-in-out, backdrop-filter 0.2s ease-in-out;
141
- }
142
-
143
- dialog > article {
144
- transition: opacity 0.2s ease-in-out, transform 0.2s ease-in-out;
145
- }
146
-
147
- @starting-style {
148
- dialog {
149
- backdrop-filter: none;
150
- background-color: transparent;
151
- }
152
-
153
- dialog > article {
154
- opacity: 0;
155
- transform: translateY(-20px);
156
- }
157
- }
@@ -1,12 +0,0 @@
1
- /**
2
- * Footer
3
- */
4
- footer {
5
- --typography-spacing-vertical: 0;
6
- --typography-headings-top: 0;
7
- --block-spacing-vertical: calc(var(--spacing) * var(--responsive-multiplier));
8
- --block-spacing-horizontal: calc(var(--spacing) * var(--responsive-multiplier));
9
-
10
- width: 100%;
11
- padding-block: var(--block-spacing-vertical);
12
- }
@@ -1,12 +0,0 @@
1
- /**
2
- * Header
3
- */
4
- header {
5
- --typography-spacing-vertical: 0;
6
- --typography-headings-top: 0;
7
- --block-spacing-vertical: calc(var(--spacing) * var(--responsive-multiplier));
8
- --block-spacing-horizontal: calc(var(--spacing) * var(--responsive-multiplier));
9
-
10
- width: 100%;
11
- padding-block: var(--block-spacing-vertical);
12
- }
@@ -1,50 +0,0 @@
1
- /**
2
- * Link
3
- */
4
- :where(a:not([role=button])),
5
- [role=link] {
6
- --color-text: rgb(var(--color-primary-rgb));
7
- --color-background: transparent;
8
- --underline: var(--color-primary-underline);
9
- outline: none;
10
- background-color: var(--color-background);
11
- color: var(--color-text);
12
- text-decoration: var(--text-decoration);
13
- text-decoration-color: var(--underline);
14
- text-underline-offset: 0.125em;
15
- transition: background-color var(--transition), color var(--transition), text-decoration var(--transition), box-shadow var(--transition);
16
- }
17
-
18
- :where(a:not([role=button])),
19
- [role=link] {
20
- &:is([aria-current]:not([aria-current=false]), :hover, :active, :focus) {
21
- --color-text: var(--color-primary-hover);
22
- --underline: var(--color-primary-hover-underline);
23
- --text-decoration: underline;
24
- }
25
-
26
- &:focus-visible {
27
- box-shadow: 0 0 0 var(--outline-width) var(--color-primary-focus);
28
- }
29
- }
30
-
31
- a[role=button] {
32
- display: inline-block;
33
- }
34
-
35
- aside {
36
- nav {
37
- a:not([role=button]), [role=link] {
38
- display: block !important;
39
- width: 100%;
40
- }
41
- }
42
- }
43
-
44
- nav {
45
- a:not([role=button]), [role=link] {
46
- &:not(:hover) {
47
- text-decoration: none;
48
- }
49
- }
50
- }
@@ -1,10 +0,0 @@
1
- /**
2
- * Main fills up the available width, and has a height defined by its content.
3
- * Stacks its children vertically.
4
- */
5
- main {
6
- --block-spacing-vertical: calc(var(--spacing) * var(--responsive-multiplier));
7
- --block-spacing-horizontal: calc(var(--spacing) * var(--responsive-multiplier));
8
-
9
- width: 100%;
10
- }
@@ -1,129 +0,0 @@
1
- /**
2
- * Group ([role="group"], [role="search"])
3
- */
4
- [role="search"],
5
- [role="group"] {
6
- display: inline-flex;
7
- position: relative;
8
- width: 100%;
9
- margin-bottom: var(--spacing);
10
- border-radius: var(--border-radius);
11
- box-shadow: var(--group-shadow, 0 0 0 rgba(0, 0, 0, 0));
12
- vertical-align: middle;
13
- transition: box-shadow var(--transition);
14
-
15
- & > *:not(details),
16
- & input:not([type="checkbox"], [type="radio"]),
17
- & select {
18
- position: relative;
19
- flex: 1 1 auto;
20
- margin-bottom: 0;
21
-
22
- &:not(:first-child) {
23
- margin-left: calc(var(--border-width) * -1);
24
- border-top-left-radius: 0;
25
- border-bottom-left-radius: 0;
26
- }
27
-
28
- &:not(:last-child) {
29
- border-top-right-radius: 0;
30
- border-bottom-right-radius: 0;
31
- }
32
-
33
- &:focus {
34
- z-index: 2;
35
- }
36
- }
37
-
38
- & button,
39
- & [type="submit"],
40
- & [type="reset"],
41
- & [type="button"],
42
- & [role="button"] {
43
- width: auto;
44
- }
45
-
46
- /* Details dropdown inside group */
47
- & > details {
48
- position: relative;
49
- margin-bottom: 0;
50
- /* Constrain details height to just the button, not the dropdown menu */
51
- height: calc(1rem * var(--line-height) + var(--form-element-spacing-vertical) * 2 + var(--border-width) * 2);
52
- overflow: visible;
53
-
54
- &:not(:first-child) {
55
- margin-left: calc(var(--border-width) * -1);
56
-
57
- & > summary {
58
- border-top-left-radius: 0;
59
- border-bottom-left-radius: 0;
60
- }
61
- }
62
-
63
- &:not(:last-child) > summary {
64
- border-top-right-radius: 0;
65
- border-bottom-right-radius: 0;
66
- }
67
-
68
- & > summary:focus {
69
- z-index: 2;
70
- }
71
-
72
- /* Ensure consistent height with other form elements in the group */
73
- & > summary[role="button"] {
74
- display: flex;
75
- align-items: center;
76
- height: 100%;
77
-
78
- &::after {
79
- height: calc(1rem * var(--line-height, 1.5));
80
- }
81
- }
82
- }
83
- }
84
-
85
- @supports selector(:has(*)) {
86
- [role="search"],
87
- [role="group"] {
88
- &:has(button:focus, [type="submit"]:focus, [type="button"]:focus, [role="button"]:focus) {
89
- --group-shadow: var(--group-shadow-focus-with-button);
90
-
91
- & input:not([type="checkbox"], [type="radio"]),
92
- & select {
93
- border-color: transparent;
94
- }
95
- }
96
-
97
- &:has(input:not([type="submit"], [type="button"]):focus, select:focus) {
98
- --group-shadow: var(--group-shadow-focus-with-input);
99
-
100
- & button,
101
- & [type="submit"],
102
- & [type="button"],
103
- & [role="button"] {
104
- --button-shadow: 0 0 0 var(--border-width) var(--color-primary-border);
105
- --button-shadow-hover: 0 0 0 var(--border-width) var(--color-primary-hover-border);
106
- }
107
- }
108
-
109
- & button:focus,
110
- & [type="submit"]:focus,
111
- & [type="reset"]:focus,
112
- & [type="button"]:focus,
113
- & [role="button"]:focus {
114
- box-shadow: none;
115
- }
116
- }
117
- }
118
-
119
- [role="search"] {
120
- & > :first-child {
121
- border-top-left-radius: 5rem;
122
- border-bottom-left-radius: 5rem;
123
- }
124
-
125
- & > :last-child {
126
- border-top-right-radius: 5rem;
127
- border-bottom-right-radius: 5rem;
128
- }
129
- }
@@ -1,9 +0,0 @@
1
- /**
2
- * Section
3
- */
4
- section {
5
- --block-spacing-vertical: calc(var(--spacing) * var(--responsive-multiplier));
6
- --block-spacing-horizontal: calc(var(--spacing) * var(--responsive-multiplier));
7
-
8
- margin-bottom: var(--block-spacing-vertical);
9
- }
@@ -1,26 +0,0 @@
1
- /**
2
- * Input type file
3
- */
4
- [type=file] {
5
- --color-text: var(--color-text-muted);
6
- margin-left: calc(var(--outline-width) * -1);
7
- padding: calc(var(--form-element-spacing-vertical) * 0.5) 0;
8
- padding-left: var(--outline-width);
9
- border: 0;
10
- border-radius: 0;
11
- background: none;
12
-
13
- &::file-selector-button {
14
- margin-right: calc(var(--spacing) / 2);
15
- padding: calc(var(--form-element-spacing-vertical) * 0.5) var(--form-element-spacing-horizontal);
16
- }
17
-
18
- &:is(:hover, :active, :focus)::file-selector-button {
19
- --color-background: var(--color-secondary-hover-bg);
20
- --border-color: var(--color-secondary-hover-border);
21
- }
22
-
23
- &:focus::file-selector-button {
24
- --shadow-lg: var(--button-shadow-hover, 0 0 0 rgba(0, 0, 0, 0)), 0 0 0 var(--outline-width) var(--color-secondary-focus);
25
- }
26
- }
@@ -1,34 +0,0 @@
1
- /**
2
- * Input type search
3
- *
4
- */
5
- input:not([type=checkbox], [type=radio], [type=range], [type=file])[type=search] {
6
- padding-inline-start: calc(var(--form-element-spacing-horizontal) + 1.75rem);
7
- background-image: var(--icon-search);
8
- background-position: left calc(var(--form-element-spacing-horizontal) + 0.125rem) center;
9
- background-size: 1rem auto;
10
- background-repeat: no-repeat;
11
-
12
- &[aria-invalid] {
13
- padding-inline-start: calc(var(--form-element-spacing-horizontal) + 1.75rem);
14
- /* Using calc with var to workaround LightningCSS minification bug with 3-value syntax */
15
- background-position: left calc(var(--form-element-spacing-horizontal) * 0 + 1.125rem) center, right calc(var(--form-element-spacing-horizontal) * 0 + 0.75rem) center;
16
- }
17
-
18
- &[aria-invalid=false] {
19
- background-image: var(--icon-search), var(--icon-valid);
20
- }
21
-
22
- &[aria-invalid=true] {
23
- background-image: var(--icon-search), var(--icon-invalid);
24
- }
25
- }
26
-
27
- [dir=rtl] input:not([type=checkbox], [type=radio], [type=range], [type=file])[type=search] {
28
- background-position: right calc(var(--form-element-spacing-horizontal) * 0 + 1.125rem) center;
29
-
30
- &[aria-invalid] {
31
- /* Using calc with var to workaround LightningCSS minification bug with 3-value syntax */
32
- background-position: right calc(var(--form-element-spacing-horizontal) * 0 + 1.125rem) center, left calc(var(--form-element-spacing-horizontal) * 0 + 0.75rem) center;
33
- }
34
- }