@auriel/peppertino 0.1.1 → 0.3.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 +136 -0
- package/README.md +343 -30
- package/build.js +27 -12
- package/dist/carousel.js +152 -0
- package/dist/carousel.js.map +7 -0
- package/dist/header.js +69 -0
- package/dist/header.js.map +7 -0
- package/dist/main.css +2780 -0
- package/dist/main.css.map +1 -0
- package/dist/modal.js +112 -0
- package/dist/modal.js.map +7 -0
- package/dist/peppertino.js +637 -0
- package/dist/peppertino.js.map +7 -0
- package/dist/select.js +99 -0
- package/dist/select.js.map +7 -0
- package/dist/tabs.js +79 -0
- package/dist/tabs.js.map +7 -0
- package/dist/validation.js +130 -0
- package/dist/validation.js.map +7 -0
- package/index.html +1137 -22
- package/package.json +1 -1
- package/src/js/carousel.js +148 -0
- package/src/js/header.js +43 -4
- package/src/js/modal.js +134 -0
- package/src/js/peppertino.js +9 -0
- package/src/js/select.js +103 -0
- package/src/js/tabs.js +94 -0
- package/src/js/validation.js +132 -0
- package/src/scss/base.scss +26 -6
- package/src/scss/button.scss +87 -20
- package/src/scss/card.scss +121 -0
- package/src/scss/carousel.scss +313 -0
- package/src/scss/footer.scss +224 -0
- package/src/scss/forms/fieldset.scss +127 -0
- package/src/scss/forms/form-instructions.scss +133 -0
- package/src/scss/forms/label.scss +115 -0
- package/src/scss/forms/text-field.scss +240 -0
- package/src/scss/forms/validation.scss +215 -0
- package/src/scss/forms.scss +8 -0
- package/src/scss/header.scss +27 -6
- package/src/scss/main.scss +7 -0
- package/src/scss/modal.scss +188 -0
- package/src/scss/section.scss +1 -1
- package/src/scss/select.scss +210 -0
- package/src/scss/tabs.scss +156 -0
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
// PeppertinoCSS — Carousel
|
|
2
|
+
//
|
|
3
|
+
// CSS-driven by default: scroll-snap + overflow-x handles all motion.
|
|
4
|
+
// JS shim (carousel.js) wires ARIA roles, live region, and exposes a small
|
|
5
|
+
// ppCarousel API — but it is strictly optional. Users can replace it entirely.
|
|
6
|
+
|
|
7
|
+
@use 'sass:map';
|
|
8
|
+
@use 'base' as *;
|
|
9
|
+
|
|
10
|
+
// ─── Root ─────────────────────────────────────────────────────────────────────
|
|
11
|
+
.pp-carousel {
|
|
12
|
+
position: relative;
|
|
13
|
+
width: 100%;
|
|
14
|
+
// Contain the overflow so prev/next controls sit outside the scroll track
|
|
15
|
+
overflow: hidden;
|
|
16
|
+
border-radius: 16px;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
// ─── Track ────────────────────────────────────────────────────────────────────
|
|
20
|
+
// The scrollable strip. Pure CSS scroll-snap — no JS scroll needed.
|
|
21
|
+
.pp-carousel__track {
|
|
22
|
+
display: flex;
|
|
23
|
+
overflow-x: auto;
|
|
24
|
+
scroll-snap-type: x mandatory;
|
|
25
|
+
scroll-behavior: smooth;
|
|
26
|
+
-webkit-overflow-scrolling: touch;
|
|
27
|
+
|
|
28
|
+
// Hide scrollbar visually; keep it functional for assistive pointer users
|
|
29
|
+
scrollbar-width: none;
|
|
30
|
+
&::-webkit-scrollbar { display: none; }
|
|
31
|
+
|
|
32
|
+
// Prevent layout thrash during scroll
|
|
33
|
+
will-change: scroll-position;
|
|
34
|
+
|
|
35
|
+
// pause CSS autoplay on hover / keyboard focus-within
|
|
36
|
+
&:hover,
|
|
37
|
+
&:focus-within {
|
|
38
|
+
animation-play-state: paused;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// ─── Slide ────────────────────────────────────────────────────────────────────
|
|
43
|
+
.pp-carousel__slide {
|
|
44
|
+
flex: 0 0 100%; // full-width by default
|
|
45
|
+
scroll-snap-align: start;
|
|
46
|
+
scroll-snap-stop: always; // prevent momentum skipping on iOS
|
|
47
|
+
position: relative;
|
|
48
|
+
min-height: 280px;
|
|
49
|
+
user-select: none;
|
|
50
|
+
|
|
51
|
+
// Content inside slides shouldn't be focusable while hidden
|
|
52
|
+
&[aria-hidden='true'] * { visibility: hidden; }
|
|
53
|
+
&[aria-hidden='false'] * { visibility: visible; }
|
|
54
|
+
&:not([aria-hidden]) * { visibility: visible; }
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
// ─── Slide variants — percentage widths ──────────────────────────────────────
|
|
58
|
+
// Use .pp-carousel--peek-2, --peek-3 on the root to show partial next slides
|
|
59
|
+
.pp-carousel--peek-2 .pp-carousel__slide { flex: 0 0 85%; }
|
|
60
|
+
.pp-carousel--peek-3 .pp-carousel__slide { flex: 0 0 72%; }
|
|
61
|
+
|
|
62
|
+
// ─── Slide media (image / video) ─────────────────────────────────────────────
|
|
63
|
+
.pp-carousel__media {
|
|
64
|
+
display: block;
|
|
65
|
+
width: 100%;
|
|
66
|
+
height: 100%;
|
|
67
|
+
object-fit: cover;
|
|
68
|
+
border-radius: inherit;
|
|
69
|
+
pointer-events: none;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
// ─── Slide caption ────────────────────────────────────────────────────────────
|
|
73
|
+
.pp-carousel__caption {
|
|
74
|
+
position: absolute;
|
|
75
|
+
inset: auto 0 0;
|
|
76
|
+
padding: spacing(6) spacing(6) spacing(5);
|
|
77
|
+
|
|
78
|
+
background: linear-gradient(
|
|
79
|
+
to top,
|
|
80
|
+
rgba(0, 0, 0, 0.65) 0%,
|
|
81
|
+
rgba(0, 0, 0, 0.2) 60%,
|
|
82
|
+
transparent 100%
|
|
83
|
+
);
|
|
84
|
+
border-radius: 0 0 16px 16px;
|
|
85
|
+
color: #fff;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.pp-carousel__caption-title {
|
|
89
|
+
font-size: font-size('xl');
|
|
90
|
+
font-weight: map.get($font-weights, 'semibold');
|
|
91
|
+
letter-spacing: -0.02em;
|
|
92
|
+
line-height: 1.25;
|
|
93
|
+
margin-bottom: spacing(1);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.pp-carousel__caption-body {
|
|
97
|
+
font-size: font-size('sm');
|
|
98
|
+
color: rgba(#fff, 0.75);
|
|
99
|
+
line-height: 1.5;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
// ─── Prev / Next controls ────────────────────────────────────────────────────
|
|
103
|
+
.pp-carousel__prev,
|
|
104
|
+
.pp-carousel__next {
|
|
105
|
+
position: absolute;
|
|
106
|
+
top: 50%;
|
|
107
|
+
transform: translateY(-50%);
|
|
108
|
+
z-index: z('raised');
|
|
109
|
+
|
|
110
|
+
display: flex;
|
|
111
|
+
align-items: center;
|
|
112
|
+
justify-content: center;
|
|
113
|
+
width: 36px;
|
|
114
|
+
height: 36px;
|
|
115
|
+
border-radius: 50%;
|
|
116
|
+
border: none;
|
|
117
|
+
cursor: pointer;
|
|
118
|
+
|
|
119
|
+
background: rgba(255, 255, 255, 0.85);
|
|
120
|
+
backdrop-filter: blur(8px) saturate(160%);
|
|
121
|
+
-webkit-backdrop-filter: blur(8px) saturate(160%);
|
|
122
|
+
box-shadow: $shadow-md;
|
|
123
|
+
color: $color-neutral-800;
|
|
124
|
+
transition:
|
|
125
|
+
background $transition-fast,
|
|
126
|
+
box-shadow $transition-fast,
|
|
127
|
+
opacity $transition-fast,
|
|
128
|
+
transform $transition-fast;
|
|
129
|
+
|
|
130
|
+
svg {
|
|
131
|
+
width: 18px;
|
|
132
|
+
height: 18px;
|
|
133
|
+
flex-shrink: 0;
|
|
134
|
+
stroke: currentColor;
|
|
135
|
+
fill: none;
|
|
136
|
+
stroke-width: 2;
|
|
137
|
+
stroke-linecap: round;
|
|
138
|
+
stroke-linejoin: round;
|
|
139
|
+
pointer-events: none;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
&:hover {
|
|
143
|
+
background: #fff;
|
|
144
|
+
box-shadow: $shadow-lg;
|
|
145
|
+
transform: translateY(-50%) scale(1.08);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
&:active {
|
|
149
|
+
transform: translateY(-50%) scale(0.96);
|
|
150
|
+
box-shadow: $shadow;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
&:focus-visible {
|
|
154
|
+
outline: 2px solid $color-primary;
|
|
155
|
+
outline-offset: 2px;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&:disabled,
|
|
159
|
+
&[aria-disabled='true'] {
|
|
160
|
+
opacity: 0.3;
|
|
161
|
+
pointer-events: none;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.pp-carousel__prev { left: spacing(3); }
|
|
166
|
+
.pp-carousel__next { right: spacing(3); }
|
|
167
|
+
|
|
168
|
+
// ─── Dots (pagination indicators) ────────────────────────────────────────────
|
|
169
|
+
.pp-carousel__dots {
|
|
170
|
+
display: flex;
|
|
171
|
+
align-items: center;
|
|
172
|
+
justify-content: center;
|
|
173
|
+
gap: spacing(2);
|
|
174
|
+
padding: spacing(4) 0 spacing(2);
|
|
175
|
+
list-style: none;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
.pp-carousel__dot {
|
|
179
|
+
display: block;
|
|
180
|
+
width: 6px;
|
|
181
|
+
height: 6px;
|
|
182
|
+
border-radius: 50%;
|
|
183
|
+
background: $color-neutral-300;
|
|
184
|
+
border: none;
|
|
185
|
+
cursor: pointer;
|
|
186
|
+
padding: 0;
|
|
187
|
+
transition:
|
|
188
|
+
background $transition-base,
|
|
189
|
+
width $transition-base,
|
|
190
|
+
border-radius $transition-base;
|
|
191
|
+
|
|
192
|
+
&:focus-visible {
|
|
193
|
+
outline: 2px solid $color-primary;
|
|
194
|
+
outline-offset: 2px;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
&.is-active,
|
|
198
|
+
&[aria-current='true'] {
|
|
199
|
+
background: $color-primary;
|
|
200
|
+
width: 20px;
|
|
201
|
+
border-radius: 3px;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
&:hover:not(.is-active):not([aria-current='true']) {
|
|
205
|
+
background: $color-neutral-500;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
// ─── Live region (screen-reader slide announcements) ─────────────────────────
|
|
210
|
+
.pp-carousel__announcer {
|
|
211
|
+
position: absolute;
|
|
212
|
+
width: 1px;
|
|
213
|
+
height: 1px;
|
|
214
|
+
padding: 0;
|
|
215
|
+
margin: -1px;
|
|
216
|
+
overflow: hidden;
|
|
217
|
+
clip: rect(0, 0, 0, 0);
|
|
218
|
+
white-space: nowrap;
|
|
219
|
+
border: 0;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
// ─── Autoplay toggle ─────────────────────────────────────────────────────────
|
|
223
|
+
.pp-carousel__autoplay {
|
|
224
|
+
position: absolute;
|
|
225
|
+
top: spacing(3);
|
|
226
|
+
right: spacing(3);
|
|
227
|
+
z-index: z('raised');
|
|
228
|
+
|
|
229
|
+
display: flex;
|
|
230
|
+
align-items: center;
|
|
231
|
+
justify-content: center;
|
|
232
|
+
width: 30px;
|
|
233
|
+
height: 30px;
|
|
234
|
+
border-radius: 50%;
|
|
235
|
+
border: none;
|
|
236
|
+
cursor: pointer;
|
|
237
|
+
|
|
238
|
+
background: rgba(255, 255, 255, 0.75);
|
|
239
|
+
backdrop-filter: blur(8px);
|
|
240
|
+
-webkit-backdrop-filter: blur(8px);
|
|
241
|
+
color: $color-neutral-700;
|
|
242
|
+
transition: background $transition-fast, color $transition-fast;
|
|
243
|
+
|
|
244
|
+
svg {
|
|
245
|
+
width: 14px;
|
|
246
|
+
height: 14px;
|
|
247
|
+
fill: currentColor;
|
|
248
|
+
pointer-events: none;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
&:hover { background: rgba(255, 255, 255, 0.95); color: $color-on-surface; }
|
|
252
|
+
|
|
253
|
+
&:focus-visible {
|
|
254
|
+
outline: 2px solid $color-primary;
|
|
255
|
+
outline-offset: 2px;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
// Icon swap: show pause icon when playing, play icon when paused
|
|
259
|
+
.pp-carousel--playing & .pp-carousel__autoplay-icon--play { display: none; }
|
|
260
|
+
.pp-carousel--playing & .pp-carousel__autoplay-icon--pause { display: block; }
|
|
261
|
+
.pp-carousel--paused & .pp-carousel__autoplay-icon--play { display: block; }
|
|
262
|
+
.pp-carousel--paused & .pp-carousel__autoplay-icon--pause { display: none; }
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
// ─── Dark variant ────────────────────────────────────────────────────────────
|
|
266
|
+
.pp-carousel--dark {
|
|
267
|
+
background: $color-neutral-900;
|
|
268
|
+
|
|
269
|
+
.pp-carousel__prev,
|
|
270
|
+
.pp-carousel__next {
|
|
271
|
+
background: rgba(0, 0, 0, 0.6);
|
|
272
|
+
color: #fff;
|
|
273
|
+
&:hover { background: rgba(0, 0, 0, 0.85); }
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.pp-carousel__dot {
|
|
277
|
+
background: $color-neutral-600;
|
|
278
|
+
&.is-active, &[aria-current='true'] { background: $color-primary-light; }
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.pp-carousel__autoplay {
|
|
282
|
+
background: rgba(0, 0, 0, 0.5);
|
|
283
|
+
color: rgba(#fff, 0.8);
|
|
284
|
+
&:hover { background: rgba(0, 0, 0, 0.8); color: #fff; }
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
// ─── Flush variant (no border-radius) ────────────────────────────────────────
|
|
289
|
+
.pp-carousel--flush {
|
|
290
|
+
border-radius: 0;
|
|
291
|
+
.pp-carousel__slide { border-radius: 0; }
|
|
292
|
+
.pp-carousel__caption { border-radius: 0; }
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
// ─── Responsive ───────────────────────────────────────────────────────────────
|
|
296
|
+
@media (max-width: 767px) {
|
|
297
|
+
// Controls move closer to edges on small screens
|
|
298
|
+
.pp-carousel__prev { left: spacing(2); }
|
|
299
|
+
.pp-carousel__next { right: spacing(2); }
|
|
300
|
+
|
|
301
|
+
.pp-carousel__prev,
|
|
302
|
+
.pp-carousel__next {
|
|
303
|
+
width: 32px;
|
|
304
|
+
height: 32px;
|
|
305
|
+
svg { width: 16px; height: 16px; }
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
// Peek variants collapse to near-full width on mobile
|
|
309
|
+
.pp-carousel--peek-2 .pp-carousel__slide,
|
|
310
|
+
.pp-carousel--peek-3 .pp-carousel__slide {
|
|
311
|
+
flex: 0 0 92%;
|
|
312
|
+
}
|
|
313
|
+
}
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
// PeppertinoCSS — Footer
|
|
2
|
+
|
|
3
|
+
@use 'sass:map';
|
|
4
|
+
@use 'base' as *;
|
|
5
|
+
|
|
6
|
+
// ─── Shell ────────────────────────────────────────────────────────────────────
|
|
7
|
+
.pp-footer {
|
|
8
|
+
width: 100%;
|
|
9
|
+
background: $color-neutral-50;
|
|
10
|
+
border-top: 1px solid $color-border;
|
|
11
|
+
padding: spacing(16) spacing(8) spacing(8);
|
|
12
|
+
font-family: $font-sans;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
// ─── Top section: brand + columns ────────────────────────────────────────────
|
|
16
|
+
.pp-footer__top {
|
|
17
|
+
display: grid;
|
|
18
|
+
grid-template-columns: 1fr repeat(3, auto);
|
|
19
|
+
gap: spacing(12);
|
|
20
|
+
align-items: start;
|
|
21
|
+
padding-bottom: spacing(10);
|
|
22
|
+
border-bottom: 1px solid $color-border;
|
|
23
|
+
|
|
24
|
+
@include respond-to('xl') {
|
|
25
|
+
grid-template-columns: 1fr repeat(4, auto);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// ─── Brand block ─────────────────────────────────────────────────────────────
|
|
30
|
+
.pp-footer__brand {
|
|
31
|
+
display: flex;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
gap: spacing(3);
|
|
34
|
+
max-width: 260px;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.pp-footer__logo {
|
|
38
|
+
font-size: font-size('lg');
|
|
39
|
+
font-weight: map.get($font-weights, 'semibold');
|
|
40
|
+
letter-spacing: -0.02em;
|
|
41
|
+
color: $color-on-surface;
|
|
42
|
+
text-decoration: none;
|
|
43
|
+
|
|
44
|
+
&:hover { color: $color-primary; }
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.pp-footer__tagline {
|
|
48
|
+
font-size: font-size('sm');
|
|
49
|
+
color: $color-neutral-500;
|
|
50
|
+
line-height: 1.6;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// ─── Nav column ──────────────────────────────────────────────────────────────
|
|
54
|
+
.pp-footer__col {
|
|
55
|
+
display: flex;
|
|
56
|
+
flex-direction: column;
|
|
57
|
+
gap: spacing(3);
|
|
58
|
+
min-width: 140px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.pp-footer__col-title {
|
|
62
|
+
font-size: font-size('xs');
|
|
63
|
+
font-weight: map.get($font-weights, 'semibold');
|
|
64
|
+
letter-spacing: 0.08em;
|
|
65
|
+
text-transform: uppercase;
|
|
66
|
+
color: $color-neutral-900;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.pp-footer__nav {
|
|
70
|
+
display: flex;
|
|
71
|
+
flex-direction: column;
|
|
72
|
+
gap: spacing(2);
|
|
73
|
+
list-style: none;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.pp-footer__nav-link {
|
|
77
|
+
font-size: font-size('sm');
|
|
78
|
+
color: $color-neutral-500;
|
|
79
|
+
text-decoration: none;
|
|
80
|
+
transition: color $transition-fast;
|
|
81
|
+
line-height: 1.5;
|
|
82
|
+
|
|
83
|
+
&:hover { color: $color-on-surface; }
|
|
84
|
+
&:focus-visible {
|
|
85
|
+
outline: 2px solid $color-primary;
|
|
86
|
+
outline-offset: 2px;
|
|
87
|
+
border-radius: 2px;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
// ─── Bottom bar ───────────────────────────────────────────────────────────────
|
|
92
|
+
.pp-footer__bottom {
|
|
93
|
+
display: flex;
|
|
94
|
+
align-items: center;
|
|
95
|
+
justify-content: space-between;
|
|
96
|
+
flex-wrap: wrap;
|
|
97
|
+
gap: spacing(4);
|
|
98
|
+
padding-top: spacing(8);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.pp-footer__legal {
|
|
102
|
+
font-size: font-size('xs');
|
|
103
|
+
color: $color-neutral-400;
|
|
104
|
+
line-height: 1.6;
|
|
105
|
+
|
|
106
|
+
a {
|
|
107
|
+
color: inherit;
|
|
108
|
+
text-decoration: underline;
|
|
109
|
+
text-underline-offset: 2px;
|
|
110
|
+
transition: color $transition-fast;
|
|
111
|
+
|
|
112
|
+
&:hover { color: $color-on-surface; }
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.pp-footer__social {
|
|
117
|
+
display: flex;
|
|
118
|
+
align-items: center;
|
|
119
|
+
gap: spacing(2);
|
|
120
|
+
list-style: none;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.pp-footer__social-link {
|
|
124
|
+
display: flex;
|
|
125
|
+
align-items: center;
|
|
126
|
+
justify-content: center;
|
|
127
|
+
width: 32px;
|
|
128
|
+
height: 32px;
|
|
129
|
+
border-radius: 50%;
|
|
130
|
+
border: 1px solid $color-border;
|
|
131
|
+
color: $color-neutral-500;
|
|
132
|
+
text-decoration: none;
|
|
133
|
+
transition:
|
|
134
|
+
color $transition-fast,
|
|
135
|
+
border-color $transition-fast,
|
|
136
|
+
background $transition-fast;
|
|
137
|
+
|
|
138
|
+
&:hover {
|
|
139
|
+
color: $color-on-surface;
|
|
140
|
+
border-color: $color-neutral-400;
|
|
141
|
+
background: $color-neutral-100;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
&:focus-visible {
|
|
145
|
+
outline: 2px solid $color-primary;
|
|
146
|
+
outline-offset: 2px;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
svg {
|
|
150
|
+
width: 16px;
|
|
151
|
+
height: 16px;
|
|
152
|
+
stroke: currentColor;
|
|
153
|
+
fill: none;
|
|
154
|
+
stroke-width: 2;
|
|
155
|
+
stroke-linecap: round;
|
|
156
|
+
stroke-linejoin: round;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
// ─── Gradient accent strip ────────────────────────────────────────────────────
|
|
161
|
+
.pp-footer--accent {
|
|
162
|
+
border-top: none;
|
|
163
|
+
position: relative;
|
|
164
|
+
|
|
165
|
+
&::before {
|
|
166
|
+
content: '';
|
|
167
|
+
display: block;
|
|
168
|
+
position: absolute;
|
|
169
|
+
top: 0;
|
|
170
|
+
left: 0;
|
|
171
|
+
right: 0;
|
|
172
|
+
height: 3px;
|
|
173
|
+
background: linear-gradient(90deg, $gradient-start, $gradient-end);
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
// ─── Dark variant ─────────────────────────────────────────────────────────────
|
|
178
|
+
.pp-footer--dark {
|
|
179
|
+
background: $color-neutral-900;
|
|
180
|
+
border-top-color: $color-neutral-700;
|
|
181
|
+
|
|
182
|
+
.pp-footer__logo { color: #fff; &:hover { color: $color-primary-light; } }
|
|
183
|
+
.pp-footer__tagline { color: $color-neutral-400; }
|
|
184
|
+
.pp-footer__col-title { color: #fff; }
|
|
185
|
+
.pp-footer__nav-link { color: $color-neutral-400; &:hover { color: #fff; } }
|
|
186
|
+
.pp-footer__legal { color: $color-neutral-600; a:hover { color: $color-neutral-300; } }
|
|
187
|
+
.pp-footer__social-link {
|
|
188
|
+
border-color: $color-neutral-700;
|
|
189
|
+
color: $color-neutral-400;
|
|
190
|
+
&:hover { border-color: $color-neutral-500; color: #fff; background: $color-neutral-800; }
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.pp-footer__top { border-bottom-color: $color-neutral-700; }
|
|
194
|
+
.pp-footer__bottom { border-top-color: $color-neutral-700; }
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
// ─── Responsive ───────────────────────────────────────────────────────────────
|
|
198
|
+
@media (max-width: 767px) {
|
|
199
|
+
.pp-footer {
|
|
200
|
+
padding: spacing(10) spacing(4) spacing(6);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
.pp-footer__top {
|
|
204
|
+
grid-template-columns: 1fr 1fr;
|
|
205
|
+
gap: spacing(8);
|
|
206
|
+
|
|
207
|
+
.pp-footer__brand {
|
|
208
|
+
grid-column: 1 / -1;
|
|
209
|
+
max-width: 100%;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.pp-footer__bottom {
|
|
214
|
+
flex-direction: column;
|
|
215
|
+
align-items: flex-start;
|
|
216
|
+
gap: spacing(4);
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
@media (max-width: 479px) {
|
|
221
|
+
.pp-footer__top {
|
|
222
|
+
grid-template-columns: 1fr;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
// PeppertinoCSS — Forms / Fieldset & Legend
|
|
2
|
+
|
|
3
|
+
@use 'sass:map';
|
|
4
|
+
@use '../base' as *;
|
|
5
|
+
|
|
6
|
+
// ─── Fieldset ─────────────────────────────────────────────────────────────────
|
|
7
|
+
.pp-fieldset,
|
|
8
|
+
fieldset.pp-fieldset {
|
|
9
|
+
display: flex;
|
|
10
|
+
flex-direction: column;
|
|
11
|
+
gap: spacing(4);
|
|
12
|
+
width: 100%;
|
|
13
|
+
padding: spacing(6);
|
|
14
|
+
margin: 0;
|
|
15
|
+
background: #fff;
|
|
16
|
+
border: 1px solid $color-border;
|
|
17
|
+
border-radius: 12px;
|
|
18
|
+
min-width: 0;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// ─── Legend ──────────────────────────────────────────────────────────────────
|
|
22
|
+
.pp-legend,
|
|
23
|
+
.pp-fieldset > legend {
|
|
24
|
+
float: left;
|
|
25
|
+
width: 100%;
|
|
26
|
+
padding: 0 0 spacing(4) 0;
|
|
27
|
+
margin-bottom: spacing(2);
|
|
28
|
+
border-bottom: 1px solid $color-border;
|
|
29
|
+
font-family: $font-sans;
|
|
30
|
+
font-size: font-size('sm');
|
|
31
|
+
font-weight: map.get($font-weights, 'semibold');
|
|
32
|
+
letter-spacing: 0.06em;
|
|
33
|
+
text-transform: uppercase;
|
|
34
|
+
color: $color-neutral-500;
|
|
35
|
+
line-height: 1.4;
|
|
36
|
+
|
|
37
|
+
& + * { clear: both; }
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// ─── Variants ────────────────────────────────────────────────────────────────
|
|
41
|
+
.pp-fieldset--ghost {
|
|
42
|
+
background: $color-neutral-50;
|
|
43
|
+
border-color: transparent;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.pp-fieldset--filled {
|
|
47
|
+
background: $color-neutral-100;
|
|
48
|
+
border-color: $color-neutral-200;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.pp-fieldset--primary {
|
|
52
|
+
border-color: rgba($color-primary, 0.35);
|
|
53
|
+
box-shadow: 0 0 0 3px rgba($color-primary, 0.06);
|
|
54
|
+
|
|
55
|
+
.pp-fieldset > legend,
|
|
56
|
+
.pp-legend {
|
|
57
|
+
color: $color-primary;
|
|
58
|
+
border-bottom-color: rgba($color-primary, 0.2);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.pp-fieldset--error {
|
|
63
|
+
border-color: rgba($color-error, 0.4);
|
|
64
|
+
box-shadow: 0 0 0 3px rgba($color-error, 0.06);
|
|
65
|
+
|
|
66
|
+
.pp-fieldset > legend,
|
|
67
|
+
.pp-legend {
|
|
68
|
+
color: $color-error;
|
|
69
|
+
border-bottom-color: rgba($color-error, 0.2);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.pp-fieldset[disabled],
|
|
74
|
+
.pp-fieldset[aria-disabled='true'] {
|
|
75
|
+
opacity: 0.5;
|
|
76
|
+
pointer-events: none;
|
|
77
|
+
cursor: not-allowed;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
// ─── Legend size modifiers ────────────────────────────────────────────────────
|
|
81
|
+
.pp-legend--sm {
|
|
82
|
+
font-size: font-size('xs');
|
|
83
|
+
padding-bottom: spacing(3);
|
|
84
|
+
margin-bottom: spacing(1);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.pp-legend--lg {
|
|
88
|
+
font-size: font-size('base');
|
|
89
|
+
font-weight: map.get($font-weights, 'bold');
|
|
90
|
+
letter-spacing: -0.01em;
|
|
91
|
+
text-transform: none;
|
|
92
|
+
padding-bottom: spacing(4);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.pp-legend--inline {
|
|
96
|
+
display: flex;
|
|
97
|
+
align-items: center;
|
|
98
|
+
gap: spacing(2);
|
|
99
|
+
|
|
100
|
+
svg,
|
|
101
|
+
[data-lucide] {
|
|
102
|
+
flex-shrink: 0;
|
|
103
|
+
width: 1em;
|
|
104
|
+
height: 1em;
|
|
105
|
+
stroke: currentColor;
|
|
106
|
+
fill: none;
|
|
107
|
+
stroke-width: 2;
|
|
108
|
+
stroke-linecap: round;
|
|
109
|
+
stroke-linejoin: round;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
// ─── Forced-colors ───────────────────────────────────────────────────────────
|
|
114
|
+
@media (forced-colors: active) {
|
|
115
|
+
.pp-fieldset,
|
|
116
|
+
fieldset.pp-fieldset {
|
|
117
|
+
border-color: ButtonText;
|
|
118
|
+
forced-color-adjust: auto;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.pp-legend,
|
|
122
|
+
.pp-fieldset > legend {
|
|
123
|
+
color: ButtonText;
|
|
124
|
+
border-bottom-color: ButtonText;
|
|
125
|
+
forced-color-adjust: auto;
|
|
126
|
+
}
|
|
127
|
+
}
|