@aspect-ops/exon-ui 0.2.2 → 0.4.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 (67) hide show
  1. package/README.md +0 -45
  2. package/dist/components/BottomNav/BottomNavItem.svelte +4 -3
  3. package/dist/components/BottomNav/BottomNavItem.svelte.d.ts +2 -1
  4. package/dist/components/CTASection/CTASection.svelte +298 -0
  5. package/dist/components/CTASection/CTASection.svelte.d.ts +15 -0
  6. package/dist/components/CTASection/index.d.ts +2 -0
  7. package/dist/components/CTASection/index.js +1 -0
  8. package/dist/components/DoughnutChart/DoughnutChart.svelte +4 -4
  9. package/dist/components/FlexibleGrid/FlexibleGrid.svelte +118 -0
  10. package/dist/components/FlexibleGrid/FlexibleGrid.svelte.d.ts +7 -0
  11. package/dist/components/FlexibleGrid/README.md +212 -0
  12. package/dist/components/FlexibleGrid/index.d.ts +2 -0
  13. package/dist/components/FlexibleGrid/index.js +1 -0
  14. package/dist/components/GlobalHeader/GlobalHeader.svelte +806 -0
  15. package/dist/components/GlobalHeader/GlobalHeader.svelte.d.ts +3 -0
  16. package/dist/components/GlobalHeader/index.d.ts +2 -0
  17. package/dist/components/GlobalHeader/index.js +1 -0
  18. package/dist/components/Hero/Hero.svelte +306 -0
  19. package/dist/components/Hero/Hero.svelte.d.ts +18 -0
  20. package/dist/components/Hero/index.d.ts +2 -0
  21. package/dist/components/Hero/index.js +1 -0
  22. package/dist/components/HeroLeftAligned/HeroLeftAligned.svelte +182 -0
  23. package/dist/components/HeroLeftAligned/HeroLeftAligned.svelte.d.ts +8 -0
  24. package/dist/components/HeroLeftAligned/README.md +168 -0
  25. package/dist/components/HeroLeftAligned/index.d.ts +2 -0
  26. package/dist/components/HeroLeftAligned/index.js +1 -0
  27. package/dist/components/IconFeatureCard/IconFeatureCard.svelte +173 -0
  28. package/dist/components/IconFeatureCard/IconFeatureCard.svelte.d.ts +4 -0
  29. package/dist/components/IconFeatureCard/README.md +234 -0
  30. package/dist/components/IconFeatureCard/index.d.ts +2 -0
  31. package/dist/components/IconFeatureCard/index.js +1 -0
  32. package/dist/components/ImageTextCard/ImageTextCard.svelte +149 -0
  33. package/dist/components/ImageTextCard/ImageTextCard.svelte.d.ts +22 -0
  34. package/dist/components/ImageTextCard/README.md +177 -0
  35. package/dist/components/ImageTextCard/index.d.ts +2 -0
  36. package/dist/components/ImageTextCard/index.js +1 -0
  37. package/dist/components/LogoCloud/LogoCloud.svelte +333 -0
  38. package/dist/components/LogoCloud/LogoCloud.svelte.d.ts +20 -0
  39. package/dist/components/LogoCloud/index.d.ts +2 -0
  40. package/dist/components/LogoCloud/index.js +1 -0
  41. package/dist/components/ServiceCard/ServiceCard.svelte +359 -0
  42. package/dist/components/ServiceCard/ServiceCard.svelte.d.ts +16 -0
  43. package/dist/components/ServiceCard/index.d.ts +1 -0
  44. package/dist/components/ServiceCard/index.js +1 -0
  45. package/dist/components/Sidebar/SidebarGroup.svelte +1 -4
  46. package/dist/components/SplitSection/SplitSection.svelte +194 -0
  47. package/dist/components/SplitSection/SplitSection.svelte.d.ts +15 -0
  48. package/dist/components/SplitSection/index.d.ts +1 -0
  49. package/dist/components/SplitSection/index.js +1 -0
  50. package/dist/components/TestimonialCard/TestimonialCard.svelte +290 -0
  51. package/dist/components/TestimonialCard/TestimonialCard.svelte.d.ts +14 -0
  52. package/dist/components/TestimonialCard/index.d.ts +1 -0
  53. package/dist/components/TestimonialCard/index.js +1 -0
  54. package/dist/components/Timeline/Timeline.svelte +444 -0
  55. package/dist/components/Timeline/Timeline.svelte.d.ts +19 -0
  56. package/dist/components/Timeline/index.d.ts +2 -0
  57. package/dist/components/Timeline/index.js +1 -0
  58. package/dist/index.d.ts +23 -1
  59. package/dist/index.js +13 -1
  60. package/dist/types/index.d.ts +49 -1
  61. package/dist/types/layout.d.ts +20 -0
  62. package/package.json +9 -2
  63. package/dist/components/Mermaid/Mermaid.svelte +0 -320
  64. package/dist/components/Mermaid/Mermaid.svelte.d.ts +0 -38
  65. package/dist/components/Mermaid/index.d.ts +0 -1
  66. package/dist/components/Mermaid/index.js +0 -1
  67. package/dist/components/Mermaid/mermaid.d.ts +0 -21
@@ -0,0 +1,212 @@
1
+ # FlexibleGrid Component
2
+
3
+ A dynamic, responsive grid component that allows you to create custom grid layouts with flexible column spans and customizable cells.
4
+
5
+ ## Features
6
+
7
+ - **Flexible Column Spans**: Each cell can span 1-12 columns
8
+ - **Customizable Styling**: Background colors, text colors, and custom classes per cell and row
9
+ - **Responsive**: Automatically adjusts to mobile devices (6 columns on small screens)
10
+ - **Design Tokens**: Supports Exon UI spacing tokens (xs, sm, md, lg, xl, 2xl, 3xl)
11
+ - **Custom Gaps**: Use design tokens or custom CSS values
12
+ - **Hover Effects**: Smooth scale transition on hover
13
+
14
+ ## Installation
15
+
16
+ ```bash
17
+ npm install @aspect-ops/exon-ui
18
+ ```
19
+
20
+ ## Basic Usage
21
+
22
+ ```svelte
23
+ <script lang="ts">
24
+ import { FlexibleGrid } from '@aspect-ops/exon-ui';
25
+ import type { FlexibleGridRow } from '@aspect-ops/exon-ui';
26
+
27
+ const rows: FlexibleGridRow[] = [
28
+ {
29
+ cells: [
30
+ { span: 6, content: 'Half Width' },
31
+ { span: 6, content: 'Half Width' }
32
+ ]
33
+ },
34
+ {
35
+ cells: [
36
+ { span: 4, content: '1/3 Width' },
37
+ { span: 4, content: '1/3 Width' },
38
+ { span: 4, content: '1/3 Width' }
39
+ ]
40
+ },
41
+ {
42
+ cells: [{ span: 12, content: 'Full Width' }]
43
+ }
44
+ ];
45
+ </script>
46
+
47
+ <FlexibleGrid {rows} />
48
+ ```
49
+
50
+ ## Advanced Usage
51
+
52
+ ```svelte
53
+ <script lang="ts">
54
+ import { FlexibleGrid } from '@aspect-ops/exon-ui';
55
+ import type { FlexibleGridRow } from '@aspect-ops/exon-ui';
56
+
57
+ const customRows: FlexibleGridRow[] = [
58
+ {
59
+ cells: [
60
+ {
61
+ span: 8,
62
+ content: '<strong>Main Content</strong>',
63
+ bgColor: '#4654A3',
64
+ textColor: 'white'
65
+ },
66
+ {
67
+ span: 4,
68
+ content: 'Sidebar',
69
+ bgColor: '#FF3131',
70
+ textColor: 'white',
71
+ class: 'custom-cell'
72
+ }
73
+ ],
74
+ class: 'custom-row'
75
+ }
76
+ ];
77
+ </script>
78
+
79
+ <FlexibleGrid
80
+ rows={customRows}
81
+ gap="md"
82
+ cellHeight="120px"
83
+ defaultBgColor="#6B7A99"
84
+ defaultTextColor="white"
85
+ columns={12}
86
+ class="my-custom-grid"
87
+ />
88
+ ```
89
+
90
+ ## Props
91
+
92
+ | Prop | Type | Default | Description |
93
+ | ------------------ | ------------------------ | ------------ | ------------------------------------------------------------------------ |
94
+ | `rows` | `FlexibleGridRow[]` | **Required** | Array of row objects containing cells |
95
+ | `gap` | `SpacingToken \| string` | `'xs'` | Gap between cells and rows (supports design tokens or custom CSS values) |
96
+ | `cellHeight` | `string` | `'80px'` | Default height for all cells |
97
+ | `defaultBgColor` | `string` | `'#6B7A99'` | Default background color for cells |
98
+ | `defaultTextColor` | `string` | `'white'` | Default text color for cells |
99
+ | `columns` | `number` | `12` | Total number of columns in the grid |
100
+ | `class` | `string` | `''` | Additional CSS classes for the grid container |
101
+
102
+ ## Type Definitions
103
+
104
+ ### FlexibleGridCell
105
+
106
+ ```typescript
107
+ interface FlexibleGridCell {
108
+ span: number; // How many columns to span (1-12)
109
+ content: string; // Content to display (can use HTML)
110
+ bgColor?: string; // Optional background color
111
+ textColor?: string; // Optional text color
112
+ class?: string; // Optional custom classes
113
+ }
114
+ ```
115
+
116
+ ### FlexibleGridRow
117
+
118
+ ```typescript
119
+ interface FlexibleGridRow {
120
+ cells: FlexibleGridCell[];
121
+ class?: string; // Optional custom classes for the row
122
+ }
123
+ ```
124
+
125
+ ## Spacing Tokens
126
+
127
+ The `gap` prop accepts the following design tokens:
128
+
129
+ - `xs` - 0.25rem (4px)
130
+ - `sm` - 0.5rem (8px)
131
+ - `md` - 1rem (16px)
132
+ - `lg` - 1.5rem (24px)
133
+ - `xl` - 2rem (32px)
134
+ - `2xl` - 3rem (48px)
135
+ - `3xl` - 4rem (64px)
136
+
137
+ Or you can use any custom CSS value like `'10px'`, `'1.5rem'`, etc.
138
+
139
+ ## Responsive Behavior
140
+
141
+ - **Desktop/Tablet (>768px)**: 12-column grid
142
+ - **Mobile (480-768px)**: Cells maintain height with adjusted font size
143
+ - **Small Mobile (<480px)**: 6-column grid with reduced cell height and font size
144
+
145
+ ## Accessibility
146
+
147
+ - Cells have hover effects with smooth transitions
148
+ - Supports keyboard navigation (inherits from native HTML)
149
+ - Content can include semantic HTML for better accessibility
150
+
151
+ ## Examples
152
+
153
+ ### Dashboard Layout
154
+
155
+ ```svelte
156
+ <script lang="ts">
157
+ const dashboardRows = [
158
+ {
159
+ cells: [{ span: 12, content: '<h2>Dashboard Header</h2>', bgColor: '#270949' }]
160
+ },
161
+ {
162
+ cells: [
163
+ { span: 3, content: 'Stat 1', bgColor: '#4654A3' },
164
+ { span: 3, content: 'Stat 2', bgColor: '#4654A3' },
165
+ { span: 3, content: 'Stat 3', bgColor: '#4654A3' },
166
+ { span: 3, content: 'Stat 4', bgColor: '#4654A3' }
167
+ ]
168
+ },
169
+ {
170
+ cells: [
171
+ { span: 8, content: 'Main Chart', bgColor: '#FF3131' },
172
+ { span: 4, content: 'Summary', bgColor: '#6B7A99' }
173
+ ]
174
+ }
175
+ ];
176
+ </script>
177
+
178
+ <FlexibleGrid rows={dashboardRows} gap="md" cellHeight="150px" />
179
+ ```
180
+
181
+ ### Content Layout
182
+
183
+ ```svelte
184
+ <script lang="ts">
185
+ const contentRows = [
186
+ {
187
+ cells: [
188
+ { span: 9, content: 'Article Content', cellHeight: '300px' },
189
+ { span: 3, content: 'Sidebar Widgets' }
190
+ ]
191
+ },
192
+ {
193
+ cells: [
194
+ { span: 4, content: 'Related 1' },
195
+ { span: 4, content: 'Related 2' },
196
+ { span: 4, content: 'Related 3' }
197
+ ]
198
+ }
199
+ ];
200
+ </script>
201
+
202
+ <FlexibleGrid rows={contentRows} gap="lg" />
203
+ ```
204
+
205
+ ## Browser Support
206
+
207
+ - Modern browsers (Chrome, Firefox, Safari, Edge)
208
+ - IE11+ (with polyfills for CSS Grid)
209
+
210
+ ## License
211
+
212
+ MIT
@@ -0,0 +1,2 @@
1
+ export { default as FlexibleGrid } from './FlexibleGrid.svelte';
2
+ export type { FlexibleGridCell, FlexibleGridRow, FlexibleGridProps } from '../../types/index.js';
@@ -0,0 +1 @@
1
+ export { default as FlexibleGrid } from './FlexibleGrid.svelte';