@repobit/dex-system-design 0.21.2 → 0.22.1
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.md +19 -0
- package/package.json +4 -2
- package/src/components/Button/Button.js +7 -2
- package/src/components/Button/button.css.js +30 -0
- package/src/components/accordion/accordion-bg.stories.js +341 -171
- package/src/components/accordion/accordion.stories.js +345 -0
- package/src/components/anchor/anchor.stories.js +134 -76
- package/src/components/back/back.css.js +1 -1
- package/src/components/back/back.stories.js +301 -63
- package/src/components/badge/badge.js +4 -7
- package/src/components/badge/badge.stories.js +89 -96
- package/src/components/breadcrumb/breadcrumb.stories.js +167 -3
- package/src/components/cards/card.stories.js +153 -3
- package/src/components/display/display.css.js +7 -10
- package/src/components/display/display.js +14 -2
- package/src/components/display/display.stories.js +213 -219
- package/src/components/divider/divider.stories.js +337 -30
- package/src/components/footer/footer-lp.stories.js +346 -3
- package/src/components/footer/footer.js +0 -3
- package/src/components/footer/footer.stories.js +267 -4
- package/src/components/header/header.css.js +1 -1
- package/src/components/header/header.js +77 -56
- package/src/components/header/header.stories.js +298 -22
- package/src/components/heading/heading.css.js +1 -1
- package/src/components/heading/heading.stories.js +355 -113
- package/src/components/image/image.css.js +146 -98
- package/src/components/image/image.js +13 -2
- package/src/components/image/image.stories.js +546 -160
- package/src/components/input/custom-form.stories.js +209 -12
- package/src/components/link/link.css.js +2 -2
- package/src/components/link/link.stories.js +383 -53
- package/src/components/paragraph/paragraph.css.js +1 -1
- package/src/components/paragraph/paragraph.stories.js +365 -157
- package/src/components/picture/picture.css.js +209 -0
- package/src/components/picture/picture.js +16 -2
- package/src/components/picture/picture.stories.js +525 -180
- package/src/components/pricing-cards/new-pricing-card.js +19 -4
- package/src/components/pricing-cards/new-pricing-card.stories.js +422 -0
- package/src/components/pricing-cards/new-pricing.css.js +8 -0
- package/src/components/pricing-cards/pricing-card-actions.js +49 -9
- package/src/components/pricing-cards/pricing-card-container.css.js +1 -1
- package/src/components/pricing-cards/pricing-card-header.css.js +73 -63
- package/src/components/pricing-cards/pricing-card-header.js +44 -10
- package/src/components/pricing-cards/pricing-card-pricing.js +63 -64
- package/src/components/pricing-cards/pricing-card.css.js +7 -15
- package/src/components/pricing-cards/pricing-card.js +353 -270
- package/src/components/pricing-cards/pricing-card.stories.js +3 -3
- package/src/tokens/fonts.stories.js +335 -8
- package/src/tokens/spacing.stories.js +701 -34
- package/src/tokens/tokens-grid.stories.js +897 -48
- package/src/tokens/typography.stories.js +980 -38
- package/src/components/accordion/accordion-light.stories.js +0 -241
|
@@ -1,83 +1,932 @@
|
|
|
1
1
|
import { html } from 'lit';
|
|
2
2
|
|
|
3
3
|
export default {
|
|
4
|
-
title: 'Design Tokens/Grid',
|
|
4
|
+
title : 'Design Tokens/Grid System',
|
|
5
|
+
tags : ['autodocs'],
|
|
5
6
|
parameters: {
|
|
6
7
|
layout: 'fullscreen',
|
|
8
|
+
docs : {
|
|
9
|
+
description: {
|
|
10
|
+
component: `
|
|
11
|
+
# Grid System
|
|
12
|
+
|
|
13
|
+
A responsive, mobile-first grid system based on CSS Grid with semantic classes and design tokens.
|
|
14
|
+
|
|
15
|
+
## Overview
|
|
16
|
+
|
|
17
|
+
The grid system provides a flexible layout foundation using CSS Grid Layout. It supports responsive design, fixed and fluid columns, and consistent spacing through design tokens.
|
|
18
|
+
|
|
19
|
+
## Core Concepts
|
|
20
|
+
|
|
21
|
+
### 1. Container
|
|
22
|
+
The outermost wrapper that centers content and sets maximum width.
|
|
23
|
+
|
|
24
|
+
### 2. Row
|
|
25
|
+
Horizontal containers that hold columns. Uses CSS Grid for layout.
|
|
26
|
+
|
|
27
|
+
### 3. Column
|
|
28
|
+
Content containers that span across the grid. Can be fixed or fluid.
|
|
29
|
+
|
|
30
|
+
## Usage
|
|
31
|
+
|
|
32
|
+
### Basic Grid Structure
|
|
33
|
+
\`\`\`html
|
|
34
|
+
<div class="grid-container">
|
|
35
|
+
<div class="grid-row">
|
|
36
|
+
<div class="grid-col">
|
|
37
|
+
<!-- Column content -->
|
|
38
|
+
</div>
|
|
39
|
+
<div class="grid-col">
|
|
40
|
+
<!-- Column content -->
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
\`\`\`
|
|
45
|
+
|
|
46
|
+
### Fixed Width Columns
|
|
47
|
+
\`\`\`html
|
|
48
|
+
<div class="grid-container">
|
|
49
|
+
<div class="grid-row">
|
|
50
|
+
<div class="col-6">
|
|
51
|
+
<!-- 50% width column -->
|
|
52
|
+
</div>
|
|
53
|
+
<div class="col-6">
|
|
54
|
+
<!-- 50% width column -->
|
|
55
|
+
</div>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
\`\`\`
|
|
59
|
+
|
|
60
|
+
### Responsive Grid
|
|
61
|
+
\`\`\`html
|
|
62
|
+
<div class="grid-container">
|
|
63
|
+
<div class="grid-row">
|
|
64
|
+
<div class="col-12 col-md-8 col-lg-6">
|
|
65
|
+
<!-- Responsive column -->
|
|
66
|
+
</div>
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
\`\`\`
|
|
70
|
+
|
|
71
|
+
## Grid Classes Reference
|
|
72
|
+
|
|
73
|
+
### Container Classes
|
|
74
|
+
| Class | Description | CSS Equivalent |
|
|
75
|
+
|-------|-------------|----------------|
|
|
76
|
+
| \`.grid-container\` | Centers content with max-width | \`max-width: var(--container-max-width)\` |
|
|
77
|
+
| \`.container-fluid\` | Full-width container | \`width: 100%\` |
|
|
78
|
+
|
|
79
|
+
### Row Classes
|
|
80
|
+
| Class | Description | CSS Equivalent |
|
|
81
|
+
|-------|-------------|----------------|
|
|
82
|
+
| \`.grid-row\` | Grid container row | \`display: grid; grid-template-columns: repeat(auto-fit, minmax(min-content, 1fr))\` |
|
|
83
|
+
| \`.row-gap-sm\` | Small row gap | \`row-gap: var(--space-sm)\` |
|
|
84
|
+
| \`.row-gap-md\` | Medium row gap | \`row-gap: var(--space-md)\` |
|
|
85
|
+
| \`.row-gap-lg\` | Large row gap | \`row-gap: var(--space-lg)\` |
|
|
86
|
+
|
|
87
|
+
### Column Classes
|
|
88
|
+
#### Fluid Columns
|
|
89
|
+
| Class | Description | Behavior |
|
|
90
|
+
|-------|-------------|----------|
|
|
91
|
+
| \`.grid-col\` | Auto-sizing column | Fills available space equally |
|
|
92
|
+
| \`.col-auto\` | Content-based width | Width based on content size |
|
|
93
|
+
|
|
94
|
+
#### Fixed Columns (12-column grid)
|
|
95
|
+
| Class | Width | Columns |
|
|
96
|
+
|-------|-------|---------|
|
|
97
|
+
| \`.col-1\` | 8.33% | 1 of 12 |
|
|
98
|
+
| \`.col-2\` | 16.66% | 2 of 12 |
|
|
99
|
+
| \`.col-3\` | 25% | 3 of 12 |
|
|
100
|
+
| \`.col-4\` | 33.33% | 4 of 12 |
|
|
101
|
+
| \`.col-5\` | 41.66% | 5 of 12 |
|
|
102
|
+
| \`.col-6\` | 50% | 6 of 12 |
|
|
103
|
+
| \`.col-7\` | 58.33% | 7 of 12 |
|
|
104
|
+
| \`.col-8\` | 66.66% | 8 of 12 |
|
|
105
|
+
| \`.col-9\` | 75% | 9 of 12 |
|
|
106
|
+
| \`.col-10\` | 83.33% | 10 of 12 |
|
|
107
|
+
| \`.col-11\` | 91.66% | 11 of 12 |
|
|
108
|
+
| \`.col-12\` | 100% | 12 of 12 |
|
|
109
|
+
|
|
110
|
+
#### Responsive Columns
|
|
111
|
+
| Class | Breakpoint | Description |
|
|
112
|
+
|-------|------------|-------------|
|
|
113
|
+
| \`.col-sm-*\` | ≥576px | Small devices |
|
|
114
|
+
| \`.col-md-*\` | ≥768px | Medium devices |
|
|
115
|
+
| \`.col-lg-*\` | ≥992px | Large devices |
|
|
116
|
+
| \`.col-xl-*\` | ≥1200px | Extra large devices |
|
|
117
|
+
|
|
118
|
+
## Design Tokens
|
|
119
|
+
|
|
120
|
+
The grid system uses CSS custom properties for consistent spacing and sizing:
|
|
121
|
+
|
|
122
|
+
\`\`\`css
|
|
123
|
+
:root {
|
|
124
|
+
/* Container */
|
|
125
|
+
--container-max-width: 1200px;
|
|
126
|
+
--container-padding: var(--space-lg);
|
|
127
|
+
|
|
128
|
+
/* Grid */
|
|
129
|
+
--grid-columns: 12;
|
|
130
|
+
--grid-gap: var(--space-md);
|
|
131
|
+
|
|
132
|
+
/* Breakpoints */
|
|
133
|
+
--breakpoint-sm: 576px;
|
|
134
|
+
--breakpoint-md: 768px;
|
|
135
|
+
--breakpoint-lg: 992px;
|
|
136
|
+
--breakpoint-xl: 1200px;
|
|
137
|
+
}
|
|
138
|
+
\`\`\`
|
|
139
|
+
|
|
140
|
+
## Examples
|
|
141
|
+
|
|
142
|
+
### Equal Width Columns
|
|
143
|
+
\`\`\`html
|
|
144
|
+
<div class="grid-container">
|
|
145
|
+
<div class="grid-row">
|
|
146
|
+
<div class="grid-col">Column 1</div>
|
|
147
|
+
<div class="grid-col">Column 2</div>
|
|
148
|
+
<div class="grid-col">Column 3</div>
|
|
149
|
+
</div>
|
|
150
|
+
</div>
|
|
151
|
+
\`\`\`
|
|
152
|
+
|
|
153
|
+
### Mixed Fixed and Fluid
|
|
154
|
+
\`\`\`html
|
|
155
|
+
<div class="grid-container">
|
|
156
|
+
<div class="grid-row">
|
|
157
|
+
<div class="col-4">Fixed 33%</div>
|
|
158
|
+
<div class="grid-col">Fluid remaining</div>
|
|
159
|
+
</div>
|
|
160
|
+
</div>
|
|
161
|
+
\`\`\`
|
|
162
|
+
|
|
163
|
+
### Nested Grids
|
|
164
|
+
\`\`\`html
|
|
165
|
+
<div class="grid-container">
|
|
166
|
+
<div class="grid-row">
|
|
167
|
+
<div class="col-8">
|
|
168
|
+
<div class="grid-row">
|
|
169
|
+
<div class="col-6">Nested 50%</div>
|
|
170
|
+
<div class="col-6">Nested 50%</div>
|
|
171
|
+
</div>
|
|
172
|
+
</div>
|
|
173
|
+
<div class="col-4">Sidebar</div>
|
|
174
|
+
</div>
|
|
175
|
+
</div>
|
|
176
|
+
\`\`\`
|
|
177
|
+
|
|
178
|
+
### Responsive Layout
|
|
179
|
+
\`\`\`html
|
|
180
|
+
<div class="grid-container">
|
|
181
|
+
<div class="grid-row">
|
|
182
|
+
<div class="col-12 col-md-8 col-lg-6">
|
|
183
|
+
Content adjusts based on screen size
|
|
184
|
+
</div>
|
|
185
|
+
<div class="col-12 col-md-4 col-lg-6">
|
|
186
|
+
Sidebar adjusts accordingly
|
|
187
|
+
</div>
|
|
188
|
+
</div>
|
|
189
|
+
</div>
|
|
190
|
+
\`\`\`
|
|
191
|
+
|
|
192
|
+
## Best Practices
|
|
193
|
+
|
|
194
|
+
### 1. Always Use Container
|
|
195
|
+
Wrap your grid in a container for proper centering and padding:
|
|
196
|
+
\`\`\`html
|
|
197
|
+
<!-- Good ✅ -->
|
|
198
|
+
<div class="grid-container">
|
|
199
|
+
<div class="grid-row">...</div>
|
|
200
|
+
</div>
|
|
201
|
+
|
|
202
|
+
<!-- Bad ❌ -->
|
|
203
|
+
<div class="grid-row">...</div>
|
|
204
|
+
\`\`\`
|
|
205
|
+
|
|
206
|
+
### 2. Column Sum Should Equal 12 (for fixed grids)
|
|
207
|
+
\`\`\`html
|
|
208
|
+
<!-- Good ✅ -->
|
|
209
|
+
<div class="col-8">...</div>
|
|
210
|
+
<div class="col-4">...</div>
|
|
211
|
+
<!-- Total: 12 -->
|
|
212
|
+
|
|
213
|
+
<!-- Bad ❌ -->
|
|
214
|
+
<div class="col-7">...</div>
|
|
215
|
+
<div class="col-6">...</div>
|
|
216
|
+
<!-- Total: 13, will wrap -->
|
|
217
|
+
\`\`\`
|
|
218
|
+
|
|
219
|
+
### 3. Use Semantic Class Names
|
|
220
|
+
\`\`\`html
|
|
221
|
+
<!-- Good ✅ -->
|
|
222
|
+
<div class="grid-col">Main Content</div>
|
|
223
|
+
<div class="col-4">Sidebar</div>
|
|
224
|
+
|
|
225
|
+
<!-- Avoid ❌ -->
|
|
226
|
+
<div style="grid-column: span 8;">Main Content</div>
|
|
227
|
+
\`\`\`
|
|
228
|
+
|
|
229
|
+
### 4. Responsive Considerations
|
|
230
|
+
- Test on multiple screen sizes
|
|
231
|
+
- Use responsive column classes
|
|
232
|
+
- Consider mobile-first approach
|
|
233
|
+
- Ensure touch targets are adequate
|
|
234
|
+
|
|
235
|
+
## Browser Support
|
|
236
|
+
|
|
237
|
+
CSS Grid is supported in:
|
|
238
|
+
- Chrome 57+
|
|
239
|
+
- Firefox 52+
|
|
240
|
+
- Safari 10.1+
|
|
241
|
+
- Edge 16+
|
|
242
|
+
|
|
243
|
+
For older browsers, consider using feature detection with \`@supports\`:
|
|
244
|
+
\`\`\`css
|
|
245
|
+
@supports (display: grid) {
|
|
246
|
+
.grid-row {
|
|
247
|
+
display: grid;
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
@supports not (display: grid) {
|
|
252
|
+
.grid-row {
|
|
253
|
+
display: flex;
|
|
254
|
+
flex-wrap: wrap;
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
\`\`\`
|
|
258
|
+
|
|
259
|
+
## Performance
|
|
260
|
+
|
|
261
|
+
- CSS Grid has excellent performance in modern browsers
|
|
262
|
+
- Avoid deeply nested grids when possible
|
|
263
|
+
- Use \`grid-auto-flow: dense\` for complex layouts
|
|
264
|
+
- Consider \`will-change: transform\` for animated grids
|
|
265
|
+
|
|
266
|
+
## Accessibility
|
|
267
|
+
|
|
268
|
+
- Maintain logical source order
|
|
269
|
+
- Ensure proper heading hierarchy within grids
|
|
270
|
+
- Test keyboard navigation
|
|
271
|
+
- Verify screen reader announcements
|
|
272
|
+
- Maintain sufficient color contrast
|
|
273
|
+
`
|
|
274
|
+
}
|
|
275
|
+
}
|
|
7
276
|
},
|
|
277
|
+
|
|
8
278
|
argTypes: {
|
|
9
|
-
backgroundColor: {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
279
|
+
backgroundColor: {
|
|
280
|
+
control : 'color',
|
|
281
|
+
description: 'Background color for container',
|
|
282
|
+
table : {
|
|
283
|
+
type : { summary: 'string' },
|
|
284
|
+
defaultValue: { summary: '#f4f4f4' }
|
|
285
|
+
}
|
|
286
|
+
},
|
|
287
|
+
padding: {
|
|
288
|
+
control : 'text',
|
|
289
|
+
description: 'Padding for container and columns',
|
|
290
|
+
table : {
|
|
291
|
+
type : { summary: 'string' },
|
|
292
|
+
defaultValue: { summary: 'var(--space-md)' }
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
gutter: {
|
|
296
|
+
control : 'text',
|
|
297
|
+
description: 'Gap between columns',
|
|
298
|
+
table : {
|
|
299
|
+
type : { summary: 'string' },
|
|
300
|
+
defaultValue: { summary: 'var(--grid-gap, var(--space-md))' }
|
|
301
|
+
}
|
|
302
|
+
},
|
|
303
|
+
colBg1: {
|
|
304
|
+
control : 'color',
|
|
305
|
+
description: 'Background color for first column',
|
|
306
|
+
table : {
|
|
307
|
+
type : { summary: 'string' },
|
|
308
|
+
defaultValue: { summary: '#bbb' }
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
colBg2: {
|
|
312
|
+
control : 'color',
|
|
313
|
+
description: 'Background color for second column',
|
|
314
|
+
table : {
|
|
315
|
+
type : { summary: 'string' },
|
|
316
|
+
defaultValue: { summary: '#999' }
|
|
317
|
+
}
|
|
318
|
+
},
|
|
319
|
+
maxWidth: {
|
|
320
|
+
control : 'text',
|
|
321
|
+
description: 'Maximum width of container',
|
|
322
|
+
table : {
|
|
323
|
+
type : { summary: 'string' },
|
|
324
|
+
defaultValue: { summary: 'var(--container-max-width, 1200px)' }
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
}
|
|
15
328
|
};
|
|
16
329
|
|
|
17
|
-
|
|
18
|
-
<
|
|
19
|
-
|
|
330
|
+
const Template = (args) => html`
|
|
331
|
+
<style>
|
|
332
|
+
:root {
|
|
333
|
+
--container-max-width: 1200px;
|
|
334
|
+
--grid-gap: var(--space-md);
|
|
335
|
+
--space-md: 1.5rem;
|
|
336
|
+
--space-lg: 2rem;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
.story-container {
|
|
340
|
+
padding: 2rem;
|
|
341
|
+
background: #f8f9fa;
|
|
342
|
+
min-height: 100vh;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
.grid-container {
|
|
346
|
+
max-width: ${args.maxWidth};
|
|
347
|
+
margin: 0 auto;
|
|
348
|
+
padding: ${args.padding};
|
|
349
|
+
background: ${args.backgroundColor};
|
|
350
|
+
border-radius: 8px;
|
|
351
|
+
border: 2px solid #dee2e6;
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
.grid-row {
|
|
355
|
+
display: grid;
|
|
356
|
+
grid-template-columns: repeat(auto-fit, minmax(min-content, 1fr));
|
|
357
|
+
gap: ${args.gutter};
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
.grid-col {
|
|
361
|
+
min-height: 100px;
|
|
362
|
+
display: flex;
|
|
363
|
+
align-items: center;
|
|
364
|
+
justify-content: center;
|
|
365
|
+
border-radius: 4px;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
.col-6 {
|
|
369
|
+
grid-column: span 6;
|
|
370
|
+
min-height: 100px;
|
|
371
|
+
display: flex;
|
|
372
|
+
align-items: center;
|
|
373
|
+
justify-content: center;
|
|
374
|
+
border-radius: 4px;
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
.col-4 {
|
|
378
|
+
grid-column: span 4;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
.col-8 {
|
|
382
|
+
grid-column: span 8;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
.col-12 {
|
|
386
|
+
grid-column: span 12;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
.info-panel {
|
|
390
|
+
background: white;
|
|
391
|
+
padding: 1.5rem;
|
|
392
|
+
border-radius: 8px;
|
|
393
|
+
margin-bottom: 2rem;
|
|
394
|
+
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
.info-title {
|
|
398
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
399
|
+
font-size: 1.25rem;
|
|
400
|
+
font-weight: 600;
|
|
401
|
+
margin: 0 0 1rem 0;
|
|
402
|
+
color: #212529;
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
.info-grid {
|
|
406
|
+
display: grid;
|
|
407
|
+
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
|
|
408
|
+
gap: 1rem;
|
|
409
|
+
margin-top: 1rem;
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
.info-item {
|
|
413
|
+
padding: 1rem;
|
|
414
|
+
background: #f8f9fa;
|
|
415
|
+
border-radius: 4px;
|
|
416
|
+
border-left: 4px solid #007bff;
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
.info-label {
|
|
420
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
421
|
+
font-weight: 600;
|
|
422
|
+
color: #495057;
|
|
423
|
+
margin: 0 0 0.25rem 0;
|
|
424
|
+
font-size: 0.9rem;
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
.info-value {
|
|
428
|
+
font-family: var(--font-family-mono, monospace);
|
|
429
|
+
color: #6c757d;
|
|
430
|
+
margin: 0;
|
|
431
|
+
font-size: 0.85rem;
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
.code-block {
|
|
435
|
+
background: #1a1a1a;
|
|
436
|
+
color: #f8f8f2;
|
|
437
|
+
padding: 1.5rem;
|
|
438
|
+
border-radius: 4px;
|
|
439
|
+
font-family: var(--font-family-mono, monospace);
|
|
440
|
+
font-size: 0.85rem;
|
|
441
|
+
line-height: 1.5;
|
|
442
|
+
overflow-x: auto;
|
|
443
|
+
margin-top: 1rem;
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
.code-comment { color: #6272a4; }
|
|
447
|
+
.code-class { color: #50fa7b; }
|
|
448
|
+
.code-property { color: #f1fa8c; }
|
|
449
|
+
.code-value { color: #ff79c6; }
|
|
450
|
+
</style>
|
|
451
|
+
|
|
452
|
+
<div class="story-container">
|
|
453
|
+
<div class="info-panel">
|
|
454
|
+
<h3 class="info-title">Grid System Configuration</h3>
|
|
455
|
+
<div class="info-grid">
|
|
456
|
+
<div class="info-item">
|
|
457
|
+
<p class="info-label">Container Max Width</p>
|
|
458
|
+
<p class="info-value">${args.maxWidth}</p>
|
|
459
|
+
</div>
|
|
460
|
+
<div class="info-item">
|
|
461
|
+
<p class="info-label">Container Padding</p>
|
|
462
|
+
<p class="info-value">${args.padding}</p>
|
|
463
|
+
</div>
|
|
464
|
+
<div class="info-item">
|
|
465
|
+
<p class="info-label">Grid Gutter</p>
|
|
466
|
+
<p class="info-value">${args.gutter}</p>
|
|
467
|
+
</div>
|
|
468
|
+
</div>
|
|
469
|
+
</div>
|
|
470
|
+
|
|
471
|
+
<div class="grid-container">
|
|
472
|
+
<div class="grid-row" style="gap: ${args.gutter};">
|
|
473
|
+
<div class="grid-col" style="background: ${args.colBg1}; padding: ${args.padding};">
|
|
474
|
+
.grid-col (auto width)
|
|
475
|
+
</div>
|
|
476
|
+
<div class="grid-col" style="background: ${args.colBg2}; padding: ${args.padding};">
|
|
477
|
+
.grid-col (auto width)
|
|
478
|
+
</div>
|
|
479
|
+
</div>
|
|
480
|
+
</div>
|
|
481
|
+
|
|
482
|
+
<div class="code-block">
|
|
483
|
+
<span class="code-comment">HTML Structure:</span><br>
|
|
484
|
+
<<span class="code-class">div</span> <span class="code-property">class</span>=<span class="code-value">"grid-container"</span>><br>
|
|
485
|
+
<<span class="code-class">div</span> <span class="code-property">class</span>=<span class="code-value">"grid-row"</span>><br>
|
|
486
|
+
<<span class="code-class">div</span> <span class="code-property">class</span>=<span class="code-value">"grid-col"</span>>Column 1</<span class="code-class">div</span>><br>
|
|
487
|
+
<<span class="code-class">div</span> <span class="code-property">class</span>=<span class="code-value">"grid-col"</span>>Column 2</<span class="code-class">div</span>><br>
|
|
488
|
+
</<span class="code-class">div</span>><br>
|
|
489
|
+
</<span class="code-class">div</span>>
|
|
490
|
+
</div>
|
|
20
491
|
</div>
|
|
21
492
|
`;
|
|
493
|
+
|
|
494
|
+
export const GridContainer = Template.bind({});
|
|
22
495
|
GridContainer.args = {
|
|
23
496
|
backgroundColor: '#f4f4f4',
|
|
24
|
-
padding: '
|
|
497
|
+
padding : 'var(--space-lg)',
|
|
498
|
+
gutter : 'var(--space-md)',
|
|
499
|
+
colBg1 : '#bbb',
|
|
500
|
+
colBg2 : '#999',
|
|
501
|
+
maxWidth : 'var(--container-max-width, 1200px)'
|
|
502
|
+
};
|
|
503
|
+
GridContainer.storyName = 'Basic Grid';
|
|
504
|
+
GridContainer.parameters = {
|
|
505
|
+
docs: {
|
|
506
|
+
description: {
|
|
507
|
+
story: 'Basic grid container with auto-sizing columns. Demonstrates the foundational grid structure with container, row, and columns.'
|
|
508
|
+
}
|
|
509
|
+
}
|
|
25
510
|
};
|
|
26
|
-
GridContainer.storyName = 'Container';
|
|
27
511
|
|
|
28
|
-
export const
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
512
|
+
export const FixedColumns = (args) => html`
|
|
513
|
+
<style>
|
|
514
|
+
.demo-container {
|
|
515
|
+
padding: 2rem;
|
|
516
|
+
background: #f8f9fa;
|
|
517
|
+
min-height: 100vh;
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
.grid-container {
|
|
521
|
+
max-width: ${args.maxWidth};
|
|
522
|
+
margin: 0 auto;
|
|
523
|
+
padding: ${args.padding};
|
|
524
|
+
background: white;
|
|
525
|
+
border-radius: 8px;
|
|
526
|
+
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
.grid-row {
|
|
530
|
+
display: grid;
|
|
531
|
+
grid-template-columns: repeat(12, 1fr);
|
|
532
|
+
gap: ${args.gutter};
|
|
533
|
+
margin-bottom: 2rem;
|
|
534
|
+
}
|
|
535
|
+
|
|
536
|
+
.col {
|
|
537
|
+
min-height: 80px;
|
|
538
|
+
display: flex;
|
|
539
|
+
align-items: center;
|
|
540
|
+
justify-content: center;
|
|
541
|
+
border-radius: 4px;
|
|
542
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
543
|
+
font-weight: 600;
|
|
544
|
+
color: white;
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
.col-1 { grid-column: span 1; background: #007bff; }
|
|
548
|
+
.col-2 { grid-column: span 2; background: #6f42c1; }
|
|
549
|
+
.col-3 { grid-column: span 3; background: #e83e8c; }
|
|
550
|
+
.col-4 { grid-column: span 4; background: #fd7e14; }
|
|
551
|
+
.col-5 { grid-column: span 5; background: #20c997; }
|
|
552
|
+
.col-6 { grid-column: span 6; background: #17a2b8; }
|
|
553
|
+
.col-7 { grid-column: span 7; background: #ffc107; color: #212529; }
|
|
554
|
+
.col-8 { grid-column: span 8; background: #dc3545; }
|
|
555
|
+
.col-9 { grid-column: span 9; background: #343a40; }
|
|
556
|
+
.col-10 { grid-column: span 10; background: #28a745; }
|
|
557
|
+
.col-11 { grid-column: span 11; background: #6c757d; }
|
|
558
|
+
.col-12 { grid-column: span 12; background: #6610f2; }
|
|
559
|
+
|
|
560
|
+
.grid-example {
|
|
561
|
+
margin-bottom: 3rem;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
.example-title {
|
|
565
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
566
|
+
font-size: 1.1rem;
|
|
567
|
+
font-weight: 600;
|
|
568
|
+
margin: 0 0 1rem 0;
|
|
569
|
+
color: #212529;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
.example-description {
|
|
573
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
574
|
+
color: #6c757d;
|
|
575
|
+
margin: 0 0 1.5rem 0;
|
|
576
|
+
font-size: 0.9rem;
|
|
577
|
+
}
|
|
578
|
+
</style>
|
|
579
|
+
|
|
580
|
+
<div class="demo-container">
|
|
581
|
+
<div class="grid-container">
|
|
582
|
+
<div class="grid-example">
|
|
583
|
+
<h3 class="example-title">12-Column Grid System</h3>
|
|
584
|
+
<p class="example-description">All available fixed-width column classes:</p>
|
|
585
|
+
<div class="grid-row">
|
|
586
|
+
${[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12].map(num => html`
|
|
587
|
+
<div class="col col-1">.col-1</div>
|
|
588
|
+
`)}
|
|
589
|
+
</div>
|
|
590
|
+
|
|
591
|
+
<div class="grid-row">
|
|
592
|
+
<div class="col col-6">.col-6 (50%)</div>
|
|
593
|
+
<div class="col col-6">.col-6 (50%)</div>
|
|
594
|
+
</div>
|
|
595
|
+
|
|
596
|
+
<div class="grid-row">
|
|
597
|
+
<div class="col col-4">.col-4 (33%)</div>
|
|
598
|
+
<div class="col col-4">.col-4 (33%)</div>
|
|
599
|
+
<div class="col col-4">.col-4 (33%)</div>
|
|
600
|
+
</div>
|
|
601
|
+
|
|
602
|
+
<div class="grid-row">
|
|
603
|
+
<div class="col col-8">.col-8 (66%)</div>
|
|
604
|
+
<div class="col col-4">.col-4 (33%)</div>
|
|
605
|
+
</div>
|
|
606
|
+
|
|
607
|
+
<div class="grid-row">
|
|
608
|
+
<div class="col col-3">.col-3 (25%)</div>
|
|
609
|
+
<div class="col col-6">.col-6 (50%)</div>
|
|
610
|
+
<div class="col col-3">.col-3 (25%)</div>
|
|
611
|
+
</div>
|
|
36
612
|
</div>
|
|
37
613
|
</div>
|
|
38
614
|
</div>
|
|
39
615
|
`;
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
616
|
+
FixedColumns.args = {
|
|
617
|
+
padding : 'var(--space-lg)',
|
|
618
|
+
gutter : 'var(--space-sm)',
|
|
619
|
+
maxWidth: 'var(--container-max-width, 1200px)'
|
|
620
|
+
};
|
|
621
|
+
FixedColumns.storyName = 'Fixed Columns';
|
|
622
|
+
FixedColumns.parameters = {
|
|
623
|
+
docs: {
|
|
624
|
+
description: {
|
|
625
|
+
story: 'Fixed-width column system based on a 12-column grid. Demonstrates all available column classes from .col-1 to .col-12.'
|
|
626
|
+
}
|
|
627
|
+
}
|
|
44
628
|
};
|
|
45
|
-
GridRowCol.storyName = 'Row + Col (auto)';
|
|
46
629
|
|
|
47
|
-
export const
|
|
48
|
-
<
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
630
|
+
export const ResponsiveGrid = () => html`
|
|
631
|
+
<style>
|
|
632
|
+
.responsive-demo {
|
|
633
|
+
padding: 2rem;
|
|
634
|
+
background: #f8f9fa;
|
|
635
|
+
min-height: 100vh;
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
.grid-container {
|
|
639
|
+
max-width: 1200px;
|
|
640
|
+
margin: 0 auto;
|
|
641
|
+
padding: 2rem;
|
|
642
|
+
background: white;
|
|
643
|
+
border-radius: 8px;
|
|
644
|
+
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
645
|
+
}
|
|
646
|
+
|
|
647
|
+
.grid-row {
|
|
648
|
+
display: grid;
|
|
649
|
+
gap: 1rem;
|
|
650
|
+
margin-bottom: 2rem;
|
|
651
|
+
}
|
|
652
|
+
|
|
653
|
+
.col {
|
|
654
|
+
padding: 1.5rem;
|
|
655
|
+
border-radius: 6px;
|
|
656
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
657
|
+
font-weight: 600;
|
|
658
|
+
display: flex;
|
|
659
|
+
align-items: center;
|
|
660
|
+
justify-content: center;
|
|
661
|
+
text-align: center;
|
|
662
|
+
min-height: 120px;
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
.col-1 { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; }
|
|
666
|
+
.col-2 { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); color: white; }
|
|
667
|
+
.col-3 { background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%); color: white; }
|
|
668
|
+
|
|
669
|
+
.breakpoint-info {
|
|
670
|
+
display: grid;
|
|
671
|
+
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
|
|
672
|
+
gap: 1rem;
|
|
673
|
+
margin-bottom: 2rem;
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
.breakpoint-card {
|
|
677
|
+
padding: 1rem;
|
|
678
|
+
background: #f8f9fa;
|
|
679
|
+
border-radius: 6px;
|
|
680
|
+
border-left: 4px solid #007bff;
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
.breakpoint-title {
|
|
684
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
685
|
+
font-weight: 600;
|
|
686
|
+
margin: 0 0 0.5rem 0;
|
|
687
|
+
color: #212529;
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
.breakpoint-desc {
|
|
691
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
692
|
+
color: #6c757d;
|
|
693
|
+
margin: 0;
|
|
694
|
+
font-size: 0.9rem;
|
|
695
|
+
}
|
|
696
|
+
|
|
697
|
+
.device-preview {
|
|
698
|
+
position: relative;
|
|
699
|
+
border: 2px solid #dee2e6;
|
|
700
|
+
border-radius: 12px;
|
|
701
|
+
padding: 1rem;
|
|
702
|
+
margin: 1rem 0;
|
|
703
|
+
background: #f8f9fa;
|
|
704
|
+
}
|
|
705
|
+
|
|
706
|
+
.device-label {
|
|
707
|
+
position: absolute;
|
|
708
|
+
top: -12px;
|
|
709
|
+
left: 1rem;
|
|
710
|
+
background: #007bff;
|
|
711
|
+
color: white;
|
|
712
|
+
padding: 2px 8px;
|
|
713
|
+
border-radius: 4px;
|
|
714
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
715
|
+
font-size: 0.8rem;
|
|
716
|
+
font-weight: 600;
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
.responsive-code {
|
|
720
|
+
background: #1a1a1a;
|
|
721
|
+
color: #f8f8f2;
|
|
722
|
+
padding: 1.5rem;
|
|
723
|
+
border-radius: 6px;
|
|
724
|
+
font-family: var(--font-family-mono, monospace);
|
|
725
|
+
font-size: 0.85rem;
|
|
726
|
+
line-height: 1.5;
|
|
727
|
+
margin-top: 2rem;
|
|
728
|
+
}
|
|
729
|
+
</style>
|
|
730
|
+
|
|
731
|
+
<div class="responsive-demo">
|
|
732
|
+
<div class="grid-container">
|
|
733
|
+
<h3 style="font-family: var(--font-family-sans, sans-serif); margin: 0 0 2rem 0;">Responsive Grid System</h3>
|
|
734
|
+
|
|
735
|
+
<div class="breakpoint-info">
|
|
736
|
+
<div class="breakpoint-card">
|
|
737
|
+
<h4 class="breakpoint-title">Mobile First</h4>
|
|
738
|
+
<p class="breakpoint-desc">Columns stack vertically by default on small screens</p>
|
|
739
|
+
</div>
|
|
740
|
+
<div class="breakpoint-card">
|
|
741
|
+
<h4 class="breakpoint-title">Tablet (≥768px)</h4>
|
|
742
|
+
<p class="breakpoint-desc">Use .col-md-* classes for tablet layouts</p>
|
|
743
|
+
</div>
|
|
744
|
+
<div class="breakpoint-card">
|
|
745
|
+
<h4 class="breakpoint-title">Desktop (≥992px)</h4>
|
|
746
|
+
<p class="breakpoint-desc">Use .col-lg-* classes for desktop layouts</p>
|
|
747
|
+
</div>
|
|
748
|
+
</div>
|
|
749
|
+
|
|
750
|
+
<div class="device-preview">
|
|
751
|
+
<div class="device-label">Mobile (Stacked)</div>
|
|
752
|
+
<div class="grid-row">
|
|
753
|
+
<div class="col col-12" style="background: #007bff; color: white;">.col-12 (100%)</div>
|
|
754
|
+
<div class="col col-12" style="background: #28a745; color: white;">.col-12 (100%)</div>
|
|
755
|
+
</div>
|
|
52
756
|
</div>
|
|
53
|
-
|
|
54
|
-
|
|
757
|
+
|
|
758
|
+
<div class="device-preview">
|
|
759
|
+
<div class="device-label">Tablet (2 Columns)</div>
|
|
760
|
+
<div class="grid-row" style="grid-template-columns: repeat(2, 1fr);">
|
|
761
|
+
<div class="col col-1">.col-md-6</div>
|
|
762
|
+
<div class="col col-2">.col-md-6</div>
|
|
763
|
+
</div>
|
|
764
|
+
</div>
|
|
765
|
+
|
|
766
|
+
<div class="device-preview">
|
|
767
|
+
<div class="device-label">Desktop (3 Columns)</div>
|
|
768
|
+
<div class="grid-row" style="grid-template-columns: repeat(3, 1fr);">
|
|
769
|
+
<div class="col col-1">.col-lg-4</div>
|
|
770
|
+
<div class="col col-2">.col-lg-4</div>
|
|
771
|
+
<div class="col col-3">.col-lg-4</div>
|
|
772
|
+
</div>
|
|
773
|
+
</div>
|
|
774
|
+
|
|
775
|
+
<div class="responsive-code">
|
|
776
|
+
<span style="color: #6272a4;">/* Responsive column example */</span><br>
|
|
777
|
+
<div class="col-12 col-md-6 col-lg-4"><br>
|
|
778
|
+
<span style="color: #6272a4;"><!-- Stacked on mobile, 2 columns on tablet, 3 columns on desktop --></span><br>
|
|
779
|
+
</div>
|
|
55
780
|
</div>
|
|
56
781
|
</div>
|
|
57
782
|
</div>
|
|
58
783
|
`;
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
784
|
+
ResponsiveGrid.storyName = 'Responsive Grid';
|
|
785
|
+
ResponsiveGrid.parameters = {
|
|
786
|
+
docs: {
|
|
787
|
+
description: {
|
|
788
|
+
story: 'Responsive grid system with mobile-first approach. Shows how columns adapt to different screen sizes using responsive classes.'
|
|
789
|
+
}
|
|
790
|
+
}
|
|
63
791
|
};
|
|
64
|
-
FixedColumns.storyName = 'Coloane fixe (.col-6)';
|
|
65
792
|
|
|
66
|
-
export const GutterExample = (
|
|
67
|
-
<
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
793
|
+
export const GutterExample = (args) => html`
|
|
794
|
+
<style>
|
|
795
|
+
.gutter-demo {
|
|
796
|
+
padding: 2rem;
|
|
797
|
+
background: #f8f9fa;
|
|
798
|
+
min-height: 100vh;
|
|
799
|
+
}
|
|
800
|
+
|
|
801
|
+
.grid-container {
|
|
802
|
+
max-width: 1200px;
|
|
803
|
+
margin: 0 auto;
|
|
804
|
+
padding: 2rem;
|
|
805
|
+
background: white;
|
|
806
|
+
border-radius: 8px;
|
|
807
|
+
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
.gutter-visualization {
|
|
811
|
+
display: grid;
|
|
812
|
+
grid-template-columns: repeat(2, 1fr);
|
|
813
|
+
gap: 2rem;
|
|
814
|
+
margin-bottom: 3rem;
|
|
815
|
+
}
|
|
816
|
+
|
|
817
|
+
.gutter-example {
|
|
818
|
+
padding: 1.5rem;
|
|
819
|
+
border-radius: 6px;
|
|
820
|
+
border: 2px solid #dee2e6;
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
.example-title {
|
|
824
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
825
|
+
font-weight: 600;
|
|
826
|
+
margin: 0 0 1rem 0;
|
|
827
|
+
color: #212529;
|
|
828
|
+
}
|
|
829
|
+
|
|
830
|
+
.grid-row-demo {
|
|
831
|
+
display: grid;
|
|
832
|
+
grid-template-columns: repeat(2, 1fr);
|
|
833
|
+
margin: 1rem 0;
|
|
834
|
+
}
|
|
835
|
+
|
|
836
|
+
.grid-col-demo {
|
|
837
|
+
background: #007bff;
|
|
838
|
+
color: white;
|
|
839
|
+
padding: 1rem;
|
|
840
|
+
border-radius: 4px;
|
|
841
|
+
font-family: var(--font-family-sans, sans-serif);
|
|
842
|
+
text-align: center;
|
|
843
|
+
}
|
|
844
|
+
|
|
845
|
+
.no-gap { gap: 0; }
|
|
846
|
+
.gap-sm { gap: var(--space-sm); }
|
|
847
|
+
.gap-md { gap: var(--space-md); }
|
|
848
|
+
.gap-lg { gap: var(--space-lg); }
|
|
849
|
+
|
|
850
|
+
.gutter-preview {
|
|
851
|
+
height: 60px;
|
|
852
|
+
background: repeating-linear-gradient(
|
|
853
|
+
90deg,
|
|
854
|
+
#dee2e6,
|
|
855
|
+
#dee2e6 1px,
|
|
856
|
+
transparent 1px,
|
|
857
|
+
transparent calc(${args.gutter} - 1px)
|
|
858
|
+
);
|
|
859
|
+
margin: 1rem 0;
|
|
860
|
+
border-radius: 4px;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
.gutter-value {
|
|
864
|
+
font-family: var(--font-family-mono, monospace);
|
|
865
|
+
background: #f8f9fa;
|
|
866
|
+
padding: 0.5rem;
|
|
867
|
+
border-radius: 4px;
|
|
868
|
+
margin: 0.5rem 0;
|
|
869
|
+
}
|
|
870
|
+
</style>
|
|
871
|
+
|
|
872
|
+
<div class="gutter-demo">
|
|
873
|
+
<div class="grid-container">
|
|
874
|
+
<h3 style="font-family: var(--font-family-sans, sans-serif); margin: 0 0 2rem 0;">Grid Gutter System</h3>
|
|
875
|
+
|
|
876
|
+
<div class="gutter-visualization">
|
|
877
|
+
<div class="gutter-example">
|
|
878
|
+
<h4 class="example-title">No Gutter</h4>
|
|
879
|
+
<div class="grid-row-demo no-gap">
|
|
880
|
+
<div class="grid-col-demo">Column 1</div>
|
|
881
|
+
<div class="grid-col-demo">Column 2</div>
|
|
882
|
+
</div>
|
|
883
|
+
<div class="gutter-value">gap: 0</div>
|
|
884
|
+
</div>
|
|
885
|
+
|
|
886
|
+
<div class="gutter-example">
|
|
887
|
+
<h4 class="example-title">Small Gutter</h4>
|
|
888
|
+
<div class="grid-row-demo gap-sm">
|
|
889
|
+
<div class="grid-col-demo">Column 1</div>
|
|
890
|
+
<div class="grid-col-demo">Column 2</div>
|
|
891
|
+
</div>
|
|
892
|
+
<div class="gutter-value">gap: var(--space-sm)</div>
|
|
893
|
+
</div>
|
|
894
|
+
|
|
895
|
+
<div class="gutter-example">
|
|
896
|
+
<h4 class="example-title">Medium Gutter (Default)</h4>
|
|
897
|
+
<div class="grid-row-demo gap-md">
|
|
898
|
+
<div class="grid-col-demo">Column 1</div>
|
|
899
|
+
<div class="grid-col-demo">Column 2</div>
|
|
900
|
+
</div>
|
|
901
|
+
<div class="gutter-value">gap: var(--space-md)</div>
|
|
902
|
+
</div>
|
|
903
|
+
|
|
904
|
+
<div class="gutter-example">
|
|
905
|
+
<h4 class="example-title">Large Gutter</h4>
|
|
906
|
+
<div class="grid-row-demo gap-lg">
|
|
907
|
+
<div class="grid-col-demo">Column 1</div>
|
|
908
|
+
<div class="grid-col-demo">Column 2</div>
|
|
909
|
+
</div>
|
|
910
|
+
<div class="gutter-value">gap: var(--space-lg)</div>
|
|
911
|
+
</div>
|
|
71
912
|
</div>
|
|
72
|
-
|
|
73
|
-
|
|
913
|
+
|
|
914
|
+
<div style="background: #f8f9fa; padding: 1.5rem; border-radius: 6px; margin-top: 2rem;">
|
|
915
|
+
<h4 style="font-family: var(--font-family-sans, sans-serif); margin: 0 0 1rem 0;">Current Gutter Preview</h4>
|
|
916
|
+
<div class="gutter-preview"></div>
|
|
917
|
+
<div class="gutter-value">Current gutter value: ${args.gutter}</div>
|
|
74
918
|
</div>
|
|
75
919
|
</div>
|
|
76
920
|
</div>
|
|
77
921
|
`;
|
|
78
922
|
GutterExample.args = {
|
|
79
|
-
gutter: '
|
|
80
|
-
colBg1: '#e0e0e0',
|
|
81
|
-
colBg2: '#d0d0d0',
|
|
923
|
+
gutter: 'var(--space-md)'
|
|
82
924
|
};
|
|
83
|
-
GutterExample.storyName = '
|
|
925
|
+
GutterExample.storyName = 'Grid Gutter';
|
|
926
|
+
GutterExample.parameters = {
|
|
927
|
+
docs: {
|
|
928
|
+
description: {
|
|
929
|
+
story: 'Grid gutter (gap) system demonstrating different spacing options between columns. Shows visual comparison of no gutter, small, medium, and large gutters.'
|
|
930
|
+
}
|
|
931
|
+
}
|
|
932
|
+
};
|