@auriel/peppertino 0.4.0 → 0.6.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/CHANGELOG.txt +242 -136
- package/LICENSE +21 -21
- package/MIGRATION.md +52 -0
- package/README.md +773 -622
- package/agents/peppertino/SKILL.md +76 -0
- package/agents/peppertino/accordion.md +134 -0
- package/agents/peppertino/alert.md +116 -0
- package/agents/peppertino/badge.md +74 -0
- package/agents/peppertino/base.md +252 -0
- package/agents/peppertino/button.md +65 -0
- package/agents/peppertino/card.md +82 -0
- package/agents/peppertino/carousel.md +147 -0
- package/agents/peppertino/catalog.md +81 -0
- package/agents/peppertino/dark-mode.md +152 -0
- package/agents/peppertino/footer.md +109 -0
- package/agents/peppertino/forms-fieldset.md +85 -0
- package/agents/peppertino/forms-form-instructions.md +94 -0
- package/agents/peppertino/forms-label.md +110 -0
- package/agents/peppertino/forms-text-field.md +134 -0
- package/agents/peppertino/forms-validation.md +153 -0
- package/agents/peppertino/gradient.md +41 -0
- package/agents/peppertino/header.md +105 -0
- package/agents/peppertino/modal.md +123 -0
- package/agents/peppertino/section.md +56 -0
- package/agents/peppertino/select.md +110 -0
- package/agents/peppertino/switch.md +72 -0
- package/agents/peppertino/table.md +69 -0
- package/agents/peppertino/tabs.md +115 -0
- package/agents/peppertino/toast.md +96 -0
- package/agents/peppertino/tooltip.md +111 -0
- package/agents/peppertino/typography.md +118 -0
- package/agents/peppertino/utilities.md +194 -0
- package/agents/skill.md +65 -0
- package/build.js +53 -53
- package/dist/accordion.js +41 -4
- package/dist/accordion.js.map +2 -2
- package/dist/alert.js +26 -0
- package/dist/alert.js.map +7 -0
- package/dist/carousel.js +4 -0
- package/dist/carousel.js.map +2 -2
- package/dist/header.js +1 -0
- package/dist/header.js.map +2 -2
- package/dist/main.css +3610 -1343
- package/dist/main.css.map +1 -1
- package/dist/main.min.css +1 -0
- package/dist/modal.js +2 -0
- package/dist/modal.js.map +2 -2
- package/dist/peppertino.js +244 -15
- package/dist/peppertino.js.map +3 -3
- package/dist/select.js +2 -4
- package/dist/select.js.map +2 -2
- package/dist/switch.js +29 -0
- package/dist/switch.js.map +7 -0
- package/dist/tabs.js +27 -7
- package/dist/tabs.js.map +2 -2
- package/dist/theme.js +47 -0
- package/dist/theme.js.map +7 -0
- package/dist/toast.js +69 -0
- package/dist/toast.js.map +7 -0
- package/dist/validation.js.map +1 -1
- package/icon.svg +4 -0
- package/index.html +2172 -1902
- package/package.json +28 -26
- package/scripts/hex-to-hsl.mjs +75 -0
- package/scripts/lint-bem.mjs +53 -0
- package/scripts/lint-colors.mjs +87 -0
- package/site.webmanifest +18 -0
- package/src/js/accordion.js +105 -61
- package/src/js/alert.js +28 -0
- package/src/js/carousel.js +153 -148
- package/src/js/header.js +85 -84
- package/src/js/modal.js +138 -134
- package/src/js/peppertino.js +15 -11
- package/src/js/select.js +101 -103
- package/src/js/switch.js +28 -0
- package/src/js/tabs.js +104 -94
- package/src/js/theme.js +47 -0
- package/src/js/toast.js +79 -0
- package/src/js/validation.js +132 -132
- package/src/scss/accordion.scss +190 -156
- package/src/scss/activity.scss +17 -0
- package/src/scss/alert.scss +203 -204
- package/src/scss/badge.scss +90 -0
- package/src/scss/base.scss +511 -305
- package/src/scss/button.scss +119 -121
- package/src/scss/card.scss +121 -121
- package/src/scss/carousel.scss +303 -313
- package/src/scss/code-block.scss +22 -0
- package/src/scss/counter.scss +5 -0
- package/src/scss/dark-mode.scss +514 -474
- package/src/scss/duration.scss +26 -0
- package/src/scss/folder.scss +27 -0
- package/src/scss/footer.scss +224 -224
- package/src/scss/forms/fieldset.scss +127 -127
- package/src/scss/forms/form-instructions.scss +133 -133
- package/src/scss/forms/label.scss +115 -115
- package/src/scss/forms/text-field.scss +240 -240
- package/src/scss/forms/validation.scss +215 -215
- package/src/scss/forms.scss +8 -8
- package/src/scss/gradient.scss +11 -11
- package/src/scss/gravity-letters.scss +7 -0
- package/src/scss/header.scss +257 -238
- package/src/scss/helpers/color.scss +9 -0
- package/src/scss/helpers/flex.scss +14 -0
- package/src/scss/helpers/index.scss +6 -0
- package/src/scss/helpers/layout.scss +14 -0
- package/src/scss/helpers/spacing.scss +14 -0
- package/src/scss/helpers/typography.scss +11 -0
- package/src/scss/helpers/visibility.scss +9 -0
- package/src/scss/main.scss +49 -20
- package/src/scss/modal.scss +188 -188
- package/src/scss/model-picker.scss +5 -0
- package/src/scss/notification.scss +5 -0
- package/src/scss/orb.scss +7 -0
- package/src/scss/otp.scss +5 -0
- package/src/scss/pill-nav.scss +10 -0
- package/src/scss/prompt.scss +28 -0
- package/src/scss/rail.scss +7 -0
- package/src/scss/reactions.scss +5 -0
- package/src/scss/reset.scss +84 -84
- package/src/scss/response.scss +11 -0
- package/src/scss/reveal.scss +5 -0
- package/src/scss/scroll-progress.scss +4 -0
- package/src/scss/search-results.scss +13 -0
- package/src/scss/section.scss +87 -79
- package/src/scss/select.scss +210 -210
- package/src/scss/sidebar.scss +8 -0
- package/src/scss/status.scss +5 -0
- package/src/scss/step-list.scss +13 -0
- package/src/scss/switch.scss +121 -0
- package/src/scss/table.scss +89 -89
- package/src/scss/tabs.scss +156 -156
- package/src/scss/task-list.scss +18 -0
- package/src/scss/theme-picker.scss +5 -0
- package/src/scss/toast.scss +170 -0
- package/src/scss/tooltip.scss +126 -0
- package/src/scss/typography.scss +58 -58
- package/src/scss/utilities.scss +243 -243
- package/src/scss/voice-note.scss +5 -0
package/src/scss/utilities.scss
CHANGED
|
@@ -1,243 +1,243 @@
|
|
|
1
|
-
// PeppertinoCSS — Utilities
|
|
2
|
-
// Margin, padding, display, visibility, flex, grid helpers
|
|
3
|
-
|
|
4
|
-
@use 'sass:map';
|
|
5
|
-
@use 'sass:string';
|
|
6
|
-
@use 'base' as *;
|
|
7
|
-
|
|
8
|
-
// ─── Display ──────────────────────────────────────────────────────────────────
|
|
9
|
-
.d-block { display: block; }
|
|
10
|
-
.d-inline { display: inline; }
|
|
11
|
-
.d-inline-block { display: inline-block; }
|
|
12
|
-
.d-flex { display: flex; }
|
|
13
|
-
.d-inline-flex { display: inline-flex; }
|
|
14
|
-
.d-grid { display: grid; }
|
|
15
|
-
.d-inline-grid { display: inline-grid; }
|
|
16
|
-
.d-none { display: none; }
|
|
17
|
-
.d-contents { display: contents; }
|
|
18
|
-
|
|
19
|
-
// ─── Visibility ───────────────────────────────────────────────────────────────
|
|
20
|
-
.visible { visibility: visible; }
|
|
21
|
-
.invisible { visibility: hidden; }
|
|
22
|
-
.sr-only {
|
|
23
|
-
position: absolute;
|
|
24
|
-
width: 1px;
|
|
25
|
-
height: 1px;
|
|
26
|
-
padding: 0;
|
|
27
|
-
margin: -1px;
|
|
28
|
-
overflow: hidden;
|
|
29
|
-
clip: rect(0, 0, 0, 0);
|
|
30
|
-
white-space: nowrap;
|
|
31
|
-
border-width: 0;
|
|
32
|
-
}
|
|
33
|
-
.not-sr-only {
|
|
34
|
-
position: static;
|
|
35
|
-
width: auto;
|
|
36
|
-
height: auto;
|
|
37
|
-
padding: 0;
|
|
38
|
-
margin: 0;
|
|
39
|
-
overflow: visible;
|
|
40
|
-
clip: auto;
|
|
41
|
-
white-space: normal;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
// ─── Opacity ──────────────────────────────────────────────────────────────────
|
|
45
|
-
.opacity-0 { opacity: 0; }
|
|
46
|
-
.opacity-25 { opacity: 0.25; }
|
|
47
|
-
.opacity-50 { opacity: 0.5; }
|
|
48
|
-
.opacity-75 { opacity: 0.75; }
|
|
49
|
-
.opacity-100 { opacity: 1; }
|
|
50
|
-
|
|
51
|
-
// ─── Spacing helpers — generate .m-*, .mt-*, .mx-*, .p-*, etc. ───────────────
|
|
52
|
-
// Keys: 0 1 2 3 4 5 6 8 10 12 16 20 24 32 + auto
|
|
53
|
-
// Sides: (none)=all, t=top, b=bottom, l=left, r=right, x=horizontal, y=vertical
|
|
54
|
-
|
|
55
|
-
$_sides: (
|
|
56
|
-
'': '',
|
|
57
|
-
't': '-top',
|
|
58
|
-
'b': '-bottom',
|
|
59
|
-
'l': '-left',
|
|
60
|
-
'r': '-right',
|
|
61
|
-
);
|
|
62
|
-
|
|
63
|
-
@each $abbr, $prop in $_sides {
|
|
64
|
-
@each $key, $value in $spacing {
|
|
65
|
-
.m#{$abbr}-#{$key} { margin#{$prop}: $value; }
|
|
66
|
-
.p#{$abbr}-#{$key} { padding#{$prop}: $value; }
|
|
67
|
-
}
|
|
68
|
-
.m#{$abbr}-auto { margin#{$prop}: auto; }
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
// x / y axes
|
|
72
|
-
@each $key, $value in $spacing {
|
|
73
|
-
.mx-#{$key} { margin-left: $value; margin-right: $value; }
|
|
74
|
-
.my-#{$key} { margin-top: $value; margin-bottom: $value; }
|
|
75
|
-
.px-#{$key} { padding-left: $value; padding-right: $value; }
|
|
76
|
-
.py-#{$key} { padding-top: $value; padding-bottom: $value; }
|
|
77
|
-
}
|
|
78
|
-
.mx-auto { margin-left: auto; margin-right: auto; }
|
|
79
|
-
.my-auto { margin-top: auto; margin-bottom: auto; }
|
|
80
|
-
|
|
81
|
-
// ─── Gap ──────────────────────────────────────────────────────────────────────
|
|
82
|
-
@each $key, $value in $spacing {
|
|
83
|
-
.gap-#{$key} { gap: $value; }
|
|
84
|
-
.gap-x-#{$key} { column-gap: $value; }
|
|
85
|
-
.gap-y-#{$key} { row-gap: $value; }
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
// ─── Flex helpers ─────────────────────────────────────────────────────────────
|
|
89
|
-
.flex-row { flex-direction: row; }
|
|
90
|
-
.flex-row-reverse { flex-direction: row-reverse; }
|
|
91
|
-
.flex-col { flex-direction: column; }
|
|
92
|
-
.flex-col-reverse { flex-direction: column-reverse; }
|
|
93
|
-
|
|
94
|
-
.flex-wrap { flex-wrap: wrap; }
|
|
95
|
-
.flex-nowrap { flex-wrap: nowrap; }
|
|
96
|
-
.flex-wrap-reverse { flex-wrap: wrap-reverse; }
|
|
97
|
-
|
|
98
|
-
.flex-1 { flex: 1 1 0%; }
|
|
99
|
-
.flex-auto { flex: 1 1 auto; }
|
|
100
|
-
.flex-none { flex: none; }
|
|
101
|
-
.flex-shrink-0 { flex-shrink: 0; }
|
|
102
|
-
.flex-grow { flex-grow: 1; }
|
|
103
|
-
.flex-grow-0 { flex-grow: 0; }
|
|
104
|
-
|
|
105
|
-
// Justify content
|
|
106
|
-
.justify-start { justify-content: flex-start; }
|
|
107
|
-
.justify-end { justify-content: flex-end; }
|
|
108
|
-
.justify-center { justify-content: center; }
|
|
109
|
-
.justify-between { justify-content: space-between; }
|
|
110
|
-
.justify-around { justify-content: space-around; }
|
|
111
|
-
.justify-evenly { justify-content: space-evenly; }
|
|
112
|
-
|
|
113
|
-
// Align items
|
|
114
|
-
.items-start { align-items: flex-start; }
|
|
115
|
-
.items-end { align-items: flex-end; }
|
|
116
|
-
.items-center { align-items: center; }
|
|
117
|
-
.items-baseline { align-items: baseline; }
|
|
118
|
-
.items-stretch { align-items: stretch; }
|
|
119
|
-
|
|
120
|
-
// Align self
|
|
121
|
-
.self-auto { align-self: auto; }
|
|
122
|
-
.self-start { align-self: flex-start; }
|
|
123
|
-
.self-end { align-self: flex-end; }
|
|
124
|
-
.self-center { align-self: center; }
|
|
125
|
-
.self-stretch { align-self: stretch; }
|
|
126
|
-
|
|
127
|
-
// ─── Grid helpers ─────────────────────────────────────────────────────────────
|
|
128
|
-
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
|
|
129
|
-
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
130
|
-
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
|
131
|
-
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
|
|
132
|
-
.grid-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
|
|
133
|
-
.grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
|
|
134
|
-
.grid-cols-12 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
|
|
135
|
-
|
|
136
|
-
.grid-rows-1 { grid-template-rows: repeat(1, minmax(0, 1fr)); }
|
|
137
|
-
.grid-rows-2 { grid-template-rows: repeat(2, minmax(0, 1fr)); }
|
|
138
|
-
.grid-rows-3 { grid-template-rows: repeat(3, minmax(0, 1fr)); }
|
|
139
|
-
.grid-rows-4 { grid-template-rows: repeat(4, minmax(0, 1fr)); }
|
|
140
|
-
|
|
141
|
-
// Col span
|
|
142
|
-
.col-span-1 { grid-column: span 1 / span 1; }
|
|
143
|
-
.col-span-2 { grid-column: span 2 / span 2; }
|
|
144
|
-
.col-span-3 { grid-column: span 3 / span 3; }
|
|
145
|
-
.col-span-4 { grid-column: span 4 / span 4; }
|
|
146
|
-
.col-span-6 { grid-column: span 6 / span 6; }
|
|
147
|
-
.col-span-full { grid-column: 1 / -1; }
|
|
148
|
-
|
|
149
|
-
// Row span
|
|
150
|
-
.row-span-1 { grid-row: span 1 / span 1; }
|
|
151
|
-
.row-span-2 { grid-row: span 2 / span 2; }
|
|
152
|
-
.row-span-3 { grid-row: span 3 / span 3; }
|
|
153
|
-
.row-span-full { grid-row: 1 / -1; }
|
|
154
|
-
|
|
155
|
-
// ─── Width ────────────────────────────────────────────────────────────────────
|
|
156
|
-
.w-full { width: 100%; }
|
|
157
|
-
.w-screen { width: 100vw; }
|
|
158
|
-
.w-auto { width: auto; }
|
|
159
|
-
.w-fit { width: fit-content; }
|
|
160
|
-
.w-min { width: min-content; }
|
|
161
|
-
.w-max { width: max-content; }
|
|
162
|
-
.w-half { width: 50%; }
|
|
163
|
-
|
|
164
|
-
// ─── Height ───────────────────────────────────────────────────────────────────
|
|
165
|
-
.h-full { height: 100%; }
|
|
166
|
-
.h-screen { height: 100vh; }
|
|
167
|
-
.h-auto { height: auto; }
|
|
168
|
-
.h-fit { height: fit-content; }
|
|
169
|
-
|
|
170
|
-
// ─── Overflow ─────────────────────────────────────────────────────────────────
|
|
171
|
-
.overflow-auto { overflow: auto; }
|
|
172
|
-
.overflow-hidden { overflow: hidden; }
|
|
173
|
-
.overflow-visible { overflow: visible; }
|
|
174
|
-
.overflow-scroll { overflow: scroll; }
|
|
175
|
-
.overflow-x-auto { overflow-x: auto; }
|
|
176
|
-
.overflow-y-auto { overflow-y: auto; }
|
|
177
|
-
.overflow-x-hidden { overflow-x: hidden; }
|
|
178
|
-
.overflow-y-hidden { overflow-y: hidden; }
|
|
179
|
-
|
|
180
|
-
// ─── Position ─────────────────────────────────────────────────────────────────
|
|
181
|
-
.static { position: static; }
|
|
182
|
-
.relative { position: relative; }
|
|
183
|
-
.absolute { position: absolute; }
|
|
184
|
-
.fixed { position: fixed; }
|
|
185
|
-
.sticky { position: sticky; }
|
|
186
|
-
|
|
187
|
-
// ─── Z-index ──────────────────────────────────────────────────────────────────
|
|
188
|
-
@each $key, $value in $z {
|
|
189
|
-
.z-#{$key} { z-index: $value; }
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
// ─── Border radius ────────────────────────────────────────────────────────────
|
|
193
|
-
@each $key, $value in $radius {
|
|
194
|
-
.rounded-#{$key} { border-radius: $value; }
|
|
195
|
-
}
|
|
196
|
-
.rounded { border-radius: map.get($radius, 'base'); }
|
|
197
|
-
|
|
198
|
-
// ─── Box shadow ───────────────────────────────────────────────────────────────
|
|
199
|
-
.shadow-none { box-shadow: none; }
|
|
200
|
-
.shadow-sm { box-shadow: $shadow-sm; }
|
|
201
|
-
.shadow { box-shadow: $shadow; }
|
|
202
|
-
.shadow-md { box-shadow: $shadow-md; }
|
|
203
|
-
.shadow-lg { box-shadow: $shadow-lg; }
|
|
204
|
-
.shadow-xl { box-shadow: $shadow-xl; }
|
|
205
|
-
|
|
206
|
-
// ─── Pointer / cursor ────────────────────────────────────────────────────────
|
|
207
|
-
.cursor-default { cursor: default; }
|
|
208
|
-
.cursor-pointer { cursor: pointer; }
|
|
209
|
-
.cursor-not-allowed { cursor: not-allowed; }
|
|
210
|
-
.cursor-grab { cursor: grab; }
|
|
211
|
-
.cursor-text { cursor: text; }
|
|
212
|
-
|
|
213
|
-
.pointer-events-none { pointer-events: none; }
|
|
214
|
-
.pointer-events-auto { pointer-events: auto; }
|
|
215
|
-
|
|
216
|
-
// ─── User select ─────────────────────────────────────────────────────────────
|
|
217
|
-
.select-none { user-select: none; }
|
|
218
|
-
.select-text { user-select: text; }
|
|
219
|
-
.select-all { user-select: all; }
|
|
220
|
-
.select-auto { user-select: auto; }
|
|
221
|
-
|
|
222
|
-
// ─── Responsive display helpers ──────────────────────────────────────────────
|
|
223
|
-
// .sm-d-none, .md-d-flex, .xl-d-grid, .w2xl-d-none (2xl → w2xl, digit prefix invalid)
|
|
224
|
-
$_bp-aliases: (
|
|
225
|
-
'sm': 'sm',
|
|
226
|
-
'md': 'md',
|
|
227
|
-
'lg': 'lg',
|
|
228
|
-
'xl': 'xl',
|
|
229
|
-
'2xl': 'w2xl',
|
|
230
|
-
);
|
|
231
|
-
|
|
232
|
-
@each $bp, $alias in $_bp-aliases {
|
|
233
|
-
$val: map.get($breakpoints, $bp);
|
|
234
|
-
@media (min-width: $val) {
|
|
235
|
-
.#{$alias}-d-none { display: none; }
|
|
236
|
-
.#{$alias}-d-block { display: block; }
|
|
237
|
-
.#{$alias}-d-flex { display: flex; }
|
|
238
|
-
.#{$alias}-d-grid { display: grid; }
|
|
239
|
-
.#{$alias}-d-inline { display: inline; }
|
|
240
|
-
.#{$alias}-d-inline-flex { display: inline-flex; }
|
|
241
|
-
.#{$alias}-d-inline-block { display: inline-block; }
|
|
242
|
-
}
|
|
243
|
-
}
|
|
1
|
+
// PeppertinoCSS — Utilities
|
|
2
|
+
// Margin, padding, display, visibility, flex, grid helpers
|
|
3
|
+
|
|
4
|
+
@use 'sass:map';
|
|
5
|
+
@use 'sass:string';
|
|
6
|
+
@use 'base' as *;
|
|
7
|
+
|
|
8
|
+
// ─── Display ──────────────────────────────────────────────────────────────────
|
|
9
|
+
.d-block { display: block; }
|
|
10
|
+
.d-inline { display: inline; }
|
|
11
|
+
.d-inline-block { display: inline-block; }
|
|
12
|
+
.d-flex { display: flex; }
|
|
13
|
+
.d-inline-flex { display: inline-flex; }
|
|
14
|
+
.d-grid { display: grid; }
|
|
15
|
+
.d-inline-grid { display: inline-grid; }
|
|
16
|
+
.d-none { display: none; }
|
|
17
|
+
.d-contents { display: contents; }
|
|
18
|
+
|
|
19
|
+
// ─── Visibility ───────────────────────────────────────────────────────────────
|
|
20
|
+
.visible { visibility: visible; }
|
|
21
|
+
.invisible { visibility: hidden; }
|
|
22
|
+
.sr-only {
|
|
23
|
+
position: absolute;
|
|
24
|
+
width: 1px;
|
|
25
|
+
height: 1px;
|
|
26
|
+
padding: 0;
|
|
27
|
+
margin: -1px;
|
|
28
|
+
overflow: hidden;
|
|
29
|
+
clip: rect(0, 0, 0, 0);
|
|
30
|
+
white-space: nowrap;
|
|
31
|
+
border-width: 0;
|
|
32
|
+
}
|
|
33
|
+
.not-sr-only {
|
|
34
|
+
position: static;
|
|
35
|
+
width: auto;
|
|
36
|
+
height: auto;
|
|
37
|
+
padding: 0;
|
|
38
|
+
margin: 0;
|
|
39
|
+
overflow: visible;
|
|
40
|
+
clip: auto;
|
|
41
|
+
white-space: normal;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// ─── Opacity ──────────────────────────────────────────────────────────────────
|
|
45
|
+
.opacity-0 { opacity: 0; }
|
|
46
|
+
.opacity-25 { opacity: 0.25; }
|
|
47
|
+
.opacity-50 { opacity: 0.5; }
|
|
48
|
+
.opacity-75 { opacity: 0.75; }
|
|
49
|
+
.opacity-100 { opacity: 1; }
|
|
50
|
+
|
|
51
|
+
// ─── Spacing helpers — generate .m-*, .mt-*, .mx-*, .p-*, etc. ───────────────
|
|
52
|
+
// Keys: 0 1 2 3 4 5 6 8 10 12 16 20 24 32 + auto
|
|
53
|
+
// Sides: (none)=all, t=top, b=bottom, l=left, r=right, x=horizontal, y=vertical
|
|
54
|
+
|
|
55
|
+
$_sides: (
|
|
56
|
+
'': '',
|
|
57
|
+
't': '-top',
|
|
58
|
+
'b': '-bottom',
|
|
59
|
+
'l': '-left',
|
|
60
|
+
'r': '-right',
|
|
61
|
+
);
|
|
62
|
+
|
|
63
|
+
@each $abbr, $prop in $_sides {
|
|
64
|
+
@each $key, $value in $spacing {
|
|
65
|
+
.m#{$abbr}-#{$key} { margin#{$prop}: $value; }
|
|
66
|
+
.p#{$abbr}-#{$key} { padding#{$prop}: $value; }
|
|
67
|
+
}
|
|
68
|
+
.m#{$abbr}-auto { margin#{$prop}: auto; }
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// x / y axes
|
|
72
|
+
@each $key, $value in $spacing {
|
|
73
|
+
.mx-#{$key} { margin-left: $value; margin-right: $value; }
|
|
74
|
+
.my-#{$key} { margin-top: $value; margin-bottom: $value; }
|
|
75
|
+
.px-#{$key} { padding-left: $value; padding-right: $value; }
|
|
76
|
+
.py-#{$key} { padding-top: $value; padding-bottom: $value; }
|
|
77
|
+
}
|
|
78
|
+
.mx-auto { margin-left: auto; margin-right: auto; }
|
|
79
|
+
.my-auto { margin-top: auto; margin-bottom: auto; }
|
|
80
|
+
|
|
81
|
+
// ─── Gap ──────────────────────────────────────────────────────────────────────
|
|
82
|
+
@each $key, $value in $spacing {
|
|
83
|
+
.gap-#{$key} { gap: $value; }
|
|
84
|
+
.gap-x-#{$key} { column-gap: $value; }
|
|
85
|
+
.gap-y-#{$key} { row-gap: $value; }
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// ─── Flex helpers ─────────────────────────────────────────────────────────────
|
|
89
|
+
.flex-row { flex-direction: row; }
|
|
90
|
+
.flex-row-reverse { flex-direction: row-reverse; }
|
|
91
|
+
.flex-col { flex-direction: column; }
|
|
92
|
+
.flex-col-reverse { flex-direction: column-reverse; }
|
|
93
|
+
|
|
94
|
+
.flex-wrap { flex-wrap: wrap; }
|
|
95
|
+
.flex-nowrap { flex-wrap: nowrap; }
|
|
96
|
+
.flex-wrap-reverse { flex-wrap: wrap-reverse; }
|
|
97
|
+
|
|
98
|
+
.flex-1 { flex: 1 1 0%; }
|
|
99
|
+
.flex-auto { flex: 1 1 auto; }
|
|
100
|
+
.flex-none { flex: none; }
|
|
101
|
+
.flex-shrink-0 { flex-shrink: 0; }
|
|
102
|
+
.flex-grow { flex-grow: 1; }
|
|
103
|
+
.flex-grow-0 { flex-grow: 0; }
|
|
104
|
+
|
|
105
|
+
// Justify content
|
|
106
|
+
.justify-start { justify-content: flex-start; }
|
|
107
|
+
.justify-end { justify-content: flex-end; }
|
|
108
|
+
.justify-center { justify-content: center; }
|
|
109
|
+
.justify-between { justify-content: space-between; }
|
|
110
|
+
.justify-around { justify-content: space-around; }
|
|
111
|
+
.justify-evenly { justify-content: space-evenly; }
|
|
112
|
+
|
|
113
|
+
// Align items
|
|
114
|
+
.items-start { align-items: flex-start; }
|
|
115
|
+
.items-end { align-items: flex-end; }
|
|
116
|
+
.items-center { align-items: center; }
|
|
117
|
+
.items-baseline { align-items: baseline; }
|
|
118
|
+
.items-stretch { align-items: stretch; }
|
|
119
|
+
|
|
120
|
+
// Align self
|
|
121
|
+
.self-auto { align-self: auto; }
|
|
122
|
+
.self-start { align-self: flex-start; }
|
|
123
|
+
.self-end { align-self: flex-end; }
|
|
124
|
+
.self-center { align-self: center; }
|
|
125
|
+
.self-stretch { align-self: stretch; }
|
|
126
|
+
|
|
127
|
+
// ─── Grid helpers ─────────────────────────────────────────────────────────────
|
|
128
|
+
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
|
|
129
|
+
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
130
|
+
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
|
131
|
+
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
|
|
132
|
+
.grid-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
|
|
133
|
+
.grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
|
|
134
|
+
.grid-cols-12 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
|
|
135
|
+
|
|
136
|
+
.grid-rows-1 { grid-template-rows: repeat(1, minmax(0, 1fr)); }
|
|
137
|
+
.grid-rows-2 { grid-template-rows: repeat(2, minmax(0, 1fr)); }
|
|
138
|
+
.grid-rows-3 { grid-template-rows: repeat(3, minmax(0, 1fr)); }
|
|
139
|
+
.grid-rows-4 { grid-template-rows: repeat(4, minmax(0, 1fr)); }
|
|
140
|
+
|
|
141
|
+
// Col span
|
|
142
|
+
.col-span-1 { grid-column: span 1 / span 1; }
|
|
143
|
+
.col-span-2 { grid-column: span 2 / span 2; }
|
|
144
|
+
.col-span-3 { grid-column: span 3 / span 3; }
|
|
145
|
+
.col-span-4 { grid-column: span 4 / span 4; }
|
|
146
|
+
.col-span-6 { grid-column: span 6 / span 6; }
|
|
147
|
+
.col-span-full { grid-column: 1 / -1; }
|
|
148
|
+
|
|
149
|
+
// Row span
|
|
150
|
+
.row-span-1 { grid-row: span 1 / span 1; }
|
|
151
|
+
.row-span-2 { grid-row: span 2 / span 2; }
|
|
152
|
+
.row-span-3 { grid-row: span 3 / span 3; }
|
|
153
|
+
.row-span-full { grid-row: 1 / -1; }
|
|
154
|
+
|
|
155
|
+
// ─── Width ────────────────────────────────────────────────────────────────────
|
|
156
|
+
.w-full { width: 100%; }
|
|
157
|
+
.w-screen { width: 100vw; }
|
|
158
|
+
.w-auto { width: auto; }
|
|
159
|
+
.w-fit { width: fit-content; }
|
|
160
|
+
.w-min { width: min-content; }
|
|
161
|
+
.w-max { width: max-content; }
|
|
162
|
+
.w-half { width: 50%; }
|
|
163
|
+
|
|
164
|
+
// ─── Height ───────────────────────────────────────────────────────────────────
|
|
165
|
+
.h-full { height: 100%; }
|
|
166
|
+
.h-screen { height: 100vh; }
|
|
167
|
+
.h-auto { height: auto; }
|
|
168
|
+
.h-fit { height: fit-content; }
|
|
169
|
+
|
|
170
|
+
// ─── Overflow ─────────────────────────────────────────────────────────────────
|
|
171
|
+
.overflow-auto { overflow: auto; }
|
|
172
|
+
.overflow-hidden { overflow: hidden; }
|
|
173
|
+
.overflow-visible { overflow: visible; }
|
|
174
|
+
.overflow-scroll { overflow: scroll; }
|
|
175
|
+
.overflow-x-auto { overflow-x: auto; }
|
|
176
|
+
.overflow-y-auto { overflow-y: auto; }
|
|
177
|
+
.overflow-x-hidden { overflow-x: hidden; }
|
|
178
|
+
.overflow-y-hidden { overflow-y: hidden; }
|
|
179
|
+
|
|
180
|
+
// ─── Position ─────────────────────────────────────────────────────────────────
|
|
181
|
+
.static { position: static; }
|
|
182
|
+
.relative { position: relative; }
|
|
183
|
+
.absolute { position: absolute; }
|
|
184
|
+
.fixed { position: fixed; }
|
|
185
|
+
.sticky { position: sticky; }
|
|
186
|
+
|
|
187
|
+
// ─── Z-index ──────────────────────────────────────────────────────────────────
|
|
188
|
+
@each $key, $value in $z {
|
|
189
|
+
.z-#{$key} { z-index: $value; }
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
// ─── Border radius ────────────────────────────────────────────────────────────
|
|
193
|
+
@each $key, $value in $radius {
|
|
194
|
+
.rounded-#{$key} { border-radius: $value; }
|
|
195
|
+
}
|
|
196
|
+
.rounded { border-radius: map.get($radius, 'base'); }
|
|
197
|
+
|
|
198
|
+
// ─── Box shadow ───────────────────────────────────────────────────────────────
|
|
199
|
+
.shadow-none { box-shadow: none; }
|
|
200
|
+
.shadow-sm { box-shadow: $shadow-sm; }
|
|
201
|
+
.shadow { box-shadow: $shadow; }
|
|
202
|
+
.shadow-md { box-shadow: $shadow-md; }
|
|
203
|
+
.shadow-lg { box-shadow: $shadow-lg; }
|
|
204
|
+
.shadow-xl { box-shadow: $shadow-xl; }
|
|
205
|
+
|
|
206
|
+
// ─── Pointer / cursor ────────────────────────────────────────────────────────
|
|
207
|
+
.cursor-default { cursor: default; }
|
|
208
|
+
.cursor-pointer { cursor: pointer; }
|
|
209
|
+
.cursor-not-allowed { cursor: not-allowed; }
|
|
210
|
+
.cursor-grab { cursor: grab; }
|
|
211
|
+
.cursor-text { cursor: text; }
|
|
212
|
+
|
|
213
|
+
.pointer-events-none { pointer-events: none; }
|
|
214
|
+
.pointer-events-auto { pointer-events: auto; }
|
|
215
|
+
|
|
216
|
+
// ─── User select ─────────────────────────────────────────────────────────────
|
|
217
|
+
.select-none { user-select: none; }
|
|
218
|
+
.select-text { user-select: text; }
|
|
219
|
+
.select-all { user-select: all; }
|
|
220
|
+
.select-auto { user-select: auto; }
|
|
221
|
+
|
|
222
|
+
// ─── Responsive display helpers ──────────────────────────────────────────────
|
|
223
|
+
// .sm-d-none, .md-d-flex, .xl-d-grid, .w2xl-d-none (2xl → w2xl, digit prefix invalid)
|
|
224
|
+
$_bp-aliases: (
|
|
225
|
+
'sm': 'sm',
|
|
226
|
+
'md': 'md',
|
|
227
|
+
'lg': 'lg',
|
|
228
|
+
'xl': 'xl',
|
|
229
|
+
'2xl': 'w2xl',
|
|
230
|
+
);
|
|
231
|
+
|
|
232
|
+
@each $bp, $alias in $_bp-aliases {
|
|
233
|
+
$val: map.get($breakpoints, $bp);
|
|
234
|
+
@media (min-width: $val) {
|
|
235
|
+
.#{$alias}-d-none { display: none; }
|
|
236
|
+
.#{$alias}-d-block { display: block; }
|
|
237
|
+
.#{$alias}-d-flex { display: flex; }
|
|
238
|
+
.#{$alias}-d-grid { display: grid; }
|
|
239
|
+
.#{$alias}-d-inline { display: inline; }
|
|
240
|
+
.#{$alias}-d-inline-flex { display: inline-flex; }
|
|
241
|
+
.#{$alias}-d-inline-block { display: inline-block; }
|
|
242
|
+
}
|
|
243
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
// Standalone component; Peppertino tokens are optional.
|
|
2
|
+
.pp-voice-note { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; padding: 1rem; border: 1px solid var(--pp-border, hsl(240 5% 84%)); border-radius: 1rem; background: var(--pp-bg-card, #fff); }
|
|
3
|
+
.pp-voice-note audio { max-width: 100%; }
|
|
4
|
+
|
|
5
|
+
.pp-voice-note :focus-visible, .pp-voice-note:focus-visible { outline: 2px solid var(--pp-primary, hsl(355 100% 39%)); outline-offset: 3px; }
|