@vertesia/fusion-ux 1.3.0 → 1.4.0-dev.20260615.042033Z

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 (126) hide show
  1. package/LICENSE +198 -10
  2. package/lib/fusion-fragment/ChartRenderer.d.ts.map +1 -0
  3. package/lib/{esm/fusion-fragment → fusion-fragment}/ChartRenderer.js +8 -6
  4. package/lib/fusion-fragment/ChartRenderer.js.map +1 -0
  5. package/lib/{types/fusion-fragment → fusion-fragment}/FieldRenderer.d.ts +1 -1
  6. package/lib/fusion-fragment/FieldRenderer.d.ts.map +1 -0
  7. package/lib/{esm/fusion-fragment → fusion-fragment}/FieldRenderer.js +14 -8
  8. package/lib/fusion-fragment/FieldRenderer.js.map +1 -0
  9. package/lib/{types/fusion-fragment → fusion-fragment}/FusionFragmentContext.d.ts +3 -3
  10. package/lib/fusion-fragment/FusionFragmentContext.d.ts.map +1 -0
  11. package/lib/{esm/fusion-fragment → fusion-fragment}/FusionFragmentContext.js +2 -2
  12. package/lib/fusion-fragment/FusionFragmentContext.js.map +1 -0
  13. package/lib/fusion-fragment/FusionFragmentHandler.d.ts.map +1 -0
  14. package/lib/{esm/fusion-fragment → fusion-fragment}/FusionFragmentHandler.js +7 -14
  15. package/lib/fusion-fragment/FusionFragmentHandler.js.map +1 -0
  16. package/lib/fusion-fragment/FusionFragmentRenderer.d.ts.map +1 -0
  17. package/lib/{esm/fusion-fragment → fusion-fragment}/FusionFragmentRenderer.js +2 -2
  18. package/lib/fusion-fragment/FusionFragmentRenderer.js.map +1 -0
  19. package/lib/{types/fusion-fragment → fusion-fragment}/SectionRenderer.d.ts +1 -1
  20. package/lib/fusion-fragment/SectionRenderer.d.ts.map +1 -0
  21. package/lib/{esm/fusion-fragment → fusion-fragment}/SectionRenderer.js +12 -5
  22. package/lib/fusion-fragment/SectionRenderer.js.map +1 -0
  23. package/lib/fusion-fragment/TableRenderer.d.ts.map +1 -0
  24. package/lib/{esm/fusion-fragment → fusion-fragment}/TableRenderer.js +9 -7
  25. package/lib/fusion-fragment/TableRenderer.js.map +1 -0
  26. package/lib/{types/fusion-fragment → fusion-fragment}/index.d.ts +4 -4
  27. package/lib/fusion-fragment/index.d.ts.map +1 -0
  28. package/lib/{esm/fusion-fragment → fusion-fragment}/index.js +4 -4
  29. package/lib/fusion-fragment/index.js.map +1 -0
  30. package/lib/{types/index.d.ts → index.d.ts} +4 -4
  31. package/lib/index.d.ts.map +1 -0
  32. package/lib/{esm/index.js → index.js} +4 -4
  33. package/lib/index.js.map +1 -0
  34. package/lib/{types/render → render}/index.d.ts +1 -1
  35. package/lib/render/index.d.ts.map +1 -0
  36. package/lib/{esm/render → render}/index.js +1 -1
  37. package/lib/render/index.js.map +1 -0
  38. package/lib/render/textPreview.d.ts.map +1 -0
  39. package/lib/{esm/render → render}/textPreview.js +12 -9
  40. package/lib/render/textPreview.js.map +1 -0
  41. package/lib/types.d.ts.map +1 -0
  42. package/lib/types.js.map +1 -0
  43. package/lib/validation/formatErrors.d.ts.map +1 -0
  44. package/lib/{esm/validation → validation}/formatErrors.js +1 -1
  45. package/lib/validation/formatErrors.js.map +1 -0
  46. package/lib/validation/fuzzyMatch.d.ts.map +1 -0
  47. package/lib/{esm/validation → validation}/fuzzyMatch.js +3 -4
  48. package/lib/validation/fuzzyMatch.js.map +1 -0
  49. package/lib/validation/index.d.ts +8 -0
  50. package/lib/validation/index.d.ts.map +1 -0
  51. package/lib/validation/index.js +8 -0
  52. package/lib/validation/index.js.map +1 -0
  53. package/lib/{types/validation → validation}/schemas.d.ts +1 -1
  54. package/lib/validation/schemas.d.ts.map +1 -0
  55. package/lib/{esm/validation → validation}/schemas.js +25 -25
  56. package/lib/validation/schemas.js.map +1 -0
  57. package/lib/validation/validateTemplate.d.ts.map +1 -0
  58. package/lib/{esm/validation → validation}/validateTemplate.js +23 -21
  59. package/lib/validation/validateTemplate.js.map +1 -0
  60. package/lib/vertesia-fusion-ux.js +1 -1
  61. package/lib/vertesia-fusion-ux.js.map +1 -1
  62. package/package.json +23 -35
  63. package/src/fusion-fragment/ChartRenderer.tsx +95 -96
  64. package/src/fusion-fragment/FieldRenderer.tsx +173 -174
  65. package/src/fusion-fragment/FusionFragmentContext.tsx +31 -37
  66. package/src/fusion-fragment/FusionFragmentHandler.tsx +214 -223
  67. package/src/fusion-fragment/FusionFragmentRenderer.tsx +102 -107
  68. package/src/fusion-fragment/SectionRenderer.tsx +174 -169
  69. package/src/fusion-fragment/TableRenderer.tsx +175 -171
  70. package/src/fusion-fragment/index.ts +11 -11
  71. package/src/index.ts +42 -45
  72. package/src/render/index.ts +3 -3
  73. package/src/render/textPreview.ts +183 -186
  74. package/src/types.ts +174 -174
  75. package/src/validation/formatErrors.ts +86 -86
  76. package/src/validation/fuzzyMatch.ts +69 -77
  77. package/src/validation/index.ts +3 -3
  78. package/src/validation/schemas.ts +120 -120
  79. package/src/validation/validateTemplate.ts +225 -226
  80. package/lib/esm/fusion-fragment/ChartRenderer.js.map +0 -1
  81. package/lib/esm/fusion-fragment/FieldRenderer.js.map +0 -1
  82. package/lib/esm/fusion-fragment/FusionFragmentContext.js.map +0 -1
  83. package/lib/esm/fusion-fragment/FusionFragmentHandler.js.map +0 -1
  84. package/lib/esm/fusion-fragment/FusionFragmentRenderer.js.map +0 -1
  85. package/lib/esm/fusion-fragment/SectionRenderer.js.map +0 -1
  86. package/lib/esm/fusion-fragment/TableRenderer.js.map +0 -1
  87. package/lib/esm/fusion-fragment/index.js.map +0 -1
  88. package/lib/esm/index.js.map +0 -1
  89. package/lib/esm/render/index.js.map +0 -1
  90. package/lib/esm/render/textPreview.js.map +0 -1
  91. package/lib/esm/types.js.map +0 -1
  92. package/lib/esm/validation/formatErrors.js.map +0 -1
  93. package/lib/esm/validation/fuzzyMatch.js.map +0 -1
  94. package/lib/esm/validation/index.js +0 -8
  95. package/lib/esm/validation/index.js.map +0 -1
  96. package/lib/esm/validation/schemas.js.map +0 -1
  97. package/lib/esm/validation/validateTemplate.js.map +0 -1
  98. package/lib/tsconfig.tsbuildinfo +0 -1
  99. package/lib/types/fusion-fragment/ChartRenderer.d.ts.map +0 -1
  100. package/lib/types/fusion-fragment/FieldRenderer.d.ts.map +0 -1
  101. package/lib/types/fusion-fragment/FusionFragmentContext.d.ts.map +0 -1
  102. package/lib/types/fusion-fragment/FusionFragmentHandler.d.ts.map +0 -1
  103. package/lib/types/fusion-fragment/FusionFragmentRenderer.d.ts.map +0 -1
  104. package/lib/types/fusion-fragment/SectionRenderer.d.ts.map +0 -1
  105. package/lib/types/fusion-fragment/TableRenderer.d.ts.map +0 -1
  106. package/lib/types/fusion-fragment/index.d.ts.map +0 -1
  107. package/lib/types/index.d.ts.map +0 -1
  108. package/lib/types/render/index.d.ts.map +0 -1
  109. package/lib/types/render/textPreview.d.ts.map +0 -1
  110. package/lib/types/types.d.ts.map +0 -1
  111. package/lib/types/validation/formatErrors.d.ts.map +0 -1
  112. package/lib/types/validation/fuzzyMatch.d.ts.map +0 -1
  113. package/lib/types/validation/index.d.ts +0 -8
  114. package/lib/types/validation/index.d.ts.map +0 -1
  115. package/lib/types/validation/schemas.d.ts.map +0 -1
  116. package/lib/types/validation/validateTemplate.d.ts.map +0 -1
  117. /package/lib/{types/fusion-fragment → fusion-fragment}/ChartRenderer.d.ts +0 -0
  118. /package/lib/{types/fusion-fragment → fusion-fragment}/FusionFragmentHandler.d.ts +0 -0
  119. /package/lib/{types/fusion-fragment → fusion-fragment}/FusionFragmentRenderer.d.ts +0 -0
  120. /package/lib/{types/fusion-fragment → fusion-fragment}/TableRenderer.d.ts +0 -0
  121. /package/lib/{types/render → render}/textPreview.d.ts +0 -0
  122. /package/lib/{types/types.d.ts → types.d.ts} +0 -0
  123. /package/lib/{esm/types.js → types.js} +0 -0
  124. /package/lib/{types/validation → validation}/formatErrors.d.ts +0 -0
  125. /package/lib/{types/validation → validation}/fuzzyMatch.d.ts +0 -0
  126. /package/lib/{types/validation → validation}/validateTemplate.d.ts +0 -0
@@ -3,202 +3,206 @@
3
3
  * Renders a table with columns and row data
4
4
  */
5
5
 
6
- import { useMemo, type ReactElement } from 'react';
6
+ import { type ReactElement, useMemo } from 'react';
7
7
  import type { ColumnTemplate } from '../types.js';
8
8
 
9
9
  const styles = {
10
- container: {
11
- width: '100%',
12
- overflowX: 'auto' as const,
13
- },
14
- table: {
15
- width: '100%',
16
- borderCollapse: 'collapse' as const,
17
- fontSize: '13px',
18
- },
19
- thead: {
20
- backgroundColor: 'var(--gray-3, #f3f4f6)',
21
- },
22
- th: {
23
- padding: '10px 12px',
24
- textAlign: 'left' as const,
25
- fontWeight: 600,
26
- fontSize: '11px',
27
- textTransform: 'uppercase' as const,
28
- letterSpacing: '0.5px',
29
- color: 'var(--gray-11, #6b7280)',
30
- borderBottom: '2px solid var(--gray-5, #e5e7eb)',
31
- },
32
- td: {
33
- padding: '10px 12px',
34
- borderBottom: '1px solid var(--gray-4, #e5e7eb)',
35
- fontFamily: 'var(--font-mono, ui-monospace, monospace)',
36
- fontVariantNumeric: 'tabular-nums' as const,
37
- },
38
- trHover: {
39
- backgroundColor: 'var(--gray-2, #f9fafb)',
40
- },
41
- empty: {
42
- padding: '20px',
43
- textAlign: 'center' as const,
44
- color: 'var(--gray-10, #9ca3af)',
45
- fontStyle: 'italic' as const,
46
- },
47
- highlight: {
48
- success: { color: 'var(--green-11, #15803d)' },
49
- warning: { color: 'var(--yellow-11, #ca8a04)' },
50
- error: { color: 'var(--red-11, #dc2626)' },
51
- info: { color: 'var(--blue-11, #2563eb)' },
52
- },
10
+ container: {
11
+ width: '100%',
12
+ overflowX: 'auto' as const,
13
+ },
14
+ table: {
15
+ width: '100%',
16
+ borderCollapse: 'collapse' as const,
17
+ fontSize: '13px',
18
+ },
19
+ thead: {
20
+ backgroundColor: 'var(--gray-3, #f3f4f6)',
21
+ },
22
+ th: {
23
+ padding: '10px 12px',
24
+ textAlign: 'left' as const,
25
+ fontWeight: 600,
26
+ fontSize: '11px',
27
+ textTransform: 'uppercase' as const,
28
+ letterSpacing: '0.5px',
29
+ color: 'var(--gray-11, #6b7280)',
30
+ borderBottom: '2px solid var(--gray-5, #e5e7eb)',
31
+ },
32
+ td: {
33
+ padding: '10px 12px',
34
+ borderBottom: '1px solid var(--gray-4, #e5e7eb)',
35
+ fontFamily: 'var(--font-mono, ui-monospace, monospace)',
36
+ fontVariantNumeric: 'tabular-nums' as const,
37
+ },
38
+ trHover: {
39
+ backgroundColor: 'var(--gray-2, #f9fafb)',
40
+ },
41
+ empty: {
42
+ padding: '20px',
43
+ textAlign: 'center' as const,
44
+ color: 'var(--gray-10, #9ca3af)',
45
+ fontStyle: 'italic' as const,
46
+ },
47
+ highlight: {
48
+ success: { color: 'var(--green-11, #15803d)' },
49
+ warning: { color: 'var(--yellow-11, #ca8a04)' },
50
+ error: { color: 'var(--red-11, #dc2626)' },
51
+ info: { color: 'var(--blue-11, #2563eb)' },
52
+ },
53
53
  };
54
54
 
55
55
  export interface TableRendererProps {
56
- columns: ColumnTemplate[];
57
- rows: Record<string, unknown>[];
56
+ columns: ColumnTemplate[];
57
+ rows: Record<string, unknown>[];
58
58
  }
59
59
 
60
60
  /**
61
61
  * Format a cell value according to column format
62
62
  */
63
63
  function formatCellValue(value: unknown, column: ColumnTemplate): string {
64
- if (value === null || value === undefined) {
65
- return '—';
66
- }
67
-
68
- switch (column.format) {
69
- case 'number': {
70
- const num = typeof value === 'number' ? value : parseFloat(String(value));
71
- if (isNaN(num)) return String(value);
72
- return new Intl.NumberFormat('en-US', {
73
- minimumFractionDigits: 0,
74
- maximumFractionDigits: column.decimals ?? 2,
75
- }).format(num);
64
+ if (value === null || value === undefined) {
65
+ return '—';
76
66
  }
77
67
 
78
- case 'currency': {
79
- const num = typeof value === 'number' ? value : parseFloat(String(value));
80
- if (isNaN(num)) return String(value);
81
- return new Intl.NumberFormat('en-US', {
82
- style: 'currency',
83
- currency: column.currency || 'USD',
84
- minimumFractionDigits: column.decimals ?? 0,
85
- maximumFractionDigits: column.decimals ?? 0,
86
- }).format(num);
87
- }
68
+ switch (column.format) {
69
+ case 'number': {
70
+ const num = typeof value === 'number' ? value : parseFloat(String(value));
71
+ if (Number.isNaN(num)) return String(value);
72
+ return new Intl.NumberFormat('en-US', {
73
+ minimumFractionDigits: 0,
74
+ maximumFractionDigits: column.decimals ?? 2,
75
+ }).format(num);
76
+ }
88
77
 
89
- case 'percent': {
90
- const num = typeof value === 'number' ? value : parseFloat(String(value));
91
- if (isNaN(num)) return String(value);
92
- const pct = num < 1 && num > -1 && num !== 0 ? num * 100 : num;
93
- return `${pct.toFixed(column.decimals ?? 1)}%`;
94
- }
78
+ case 'currency': {
79
+ const num = typeof value === 'number' ? value : parseFloat(String(value));
80
+ if (Number.isNaN(num)) return String(value);
81
+ return new Intl.NumberFormat('en-US', {
82
+ style: 'currency',
83
+ currency: column.currency || 'USD',
84
+ minimumFractionDigits: column.decimals ?? 0,
85
+ maximumFractionDigits: column.decimals ?? 0,
86
+ }).format(num);
87
+ }
95
88
 
96
- case 'date': {
97
- const date = value instanceof Date ? value : new Date(String(value));
98
- if (isNaN(date.getTime())) return String(value);
99
- return new Intl.DateTimeFormat('en-US', {
100
- year: 'numeric',
101
- month: 'short',
102
- day: 'numeric',
103
- }).format(date);
104
- }
89
+ case 'percent': {
90
+ const num = typeof value === 'number' ? value : parseFloat(String(value));
91
+ if (Number.isNaN(num)) return String(value);
92
+ const pct = num < 1 && num > -1 && num !== 0 ? num * 100 : num;
93
+ return `${pct.toFixed(column.decimals ?? 1)}%`;
94
+ }
95
+
96
+ case 'date': {
97
+ const date = value instanceof Date ? value : new Date(String(value));
98
+ if (Number.isNaN(date.getTime())) return String(value);
99
+ return new Intl.DateTimeFormat('en-US', {
100
+ year: 'numeric',
101
+ month: 'short',
102
+ day: 'numeric',
103
+ }).format(date);
104
+ }
105
105
 
106
- case 'boolean':
107
- return value ? 'Yes' : 'No';
106
+ case 'boolean':
107
+ return value ? 'Yes' : 'No';
108
108
 
109
- default:
110
- return String(value);
111
- }
109
+ default:
110
+ return String(value);
111
+ }
112
112
  }
113
113
 
114
114
  /**
115
115
  * TableRenderer component
116
116
  */
117
117
  export function TableRenderer({ columns, rows }: TableRendererProps): ReactElement {
118
- const alignmentStyle = useMemo(() => {
119
- return columns.reduce((acc, col) => {
120
- acc[col.key] = col.align || (
121
- col.format === 'number' || col.format === 'currency' || col.format === 'percent'
122
- ? 'right'
123
- : 'left'
124
- );
125
- return acc;
126
- }, {} as Record<string, string>);
127
- }, [columns]);
118
+ const alignmentStyle = useMemo(() => {
119
+ return columns.reduce(
120
+ (acc, col) => {
121
+ acc[col.key] =
122
+ col.align ||
123
+ (col.format === 'number' || col.format === 'currency' || col.format === 'percent'
124
+ ? 'right'
125
+ : 'left');
126
+ return acc;
127
+ },
128
+ {} as Record<string, string>,
129
+ );
130
+ }, [columns]);
128
131
 
129
- if (rows.length === 0) {
130
- return (
131
- <div style={styles.container}>
132
- <table style={styles.table}>
133
- <thead style={styles.thead}>
134
- <tr>
135
- {columns.map((col) => (
136
- <th
137
- key={col.key}
138
- style={{
139
- ...styles.th,
140
- textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
141
- width: col.width,
142
- }}
143
- >
144
- {col.header}
145
- </th>
146
- ))}
147
- </tr>
148
- </thead>
149
- <tbody>
150
- <tr>
151
- <td colSpan={columns.length} style={styles.empty}>
152
- No data available
153
- </td>
154
- </tr>
155
- </tbody>
156
- </table>
157
- </div>
158
- );
159
- }
132
+ if (rows.length === 0) {
133
+ return (
134
+ <div style={styles.container}>
135
+ <table style={styles.table}>
136
+ <thead style={styles.thead}>
137
+ <tr>
138
+ {columns.map((col) => (
139
+ <th
140
+ key={col.key}
141
+ style={{
142
+ ...styles.th,
143
+ textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
144
+ width: col.width,
145
+ }}
146
+ >
147
+ {col.header}
148
+ </th>
149
+ ))}
150
+ </tr>
151
+ </thead>
152
+ <tbody>
153
+ <tr>
154
+ <td colSpan={columns.length} style={styles.empty}>
155
+ No data available
156
+ </td>
157
+ </tr>
158
+ </tbody>
159
+ </table>
160
+ </div>
161
+ );
162
+ }
160
163
 
161
- return (
162
- <div style={styles.container}>
163
- <table style={styles.table}>
164
- <thead style={styles.thead}>
165
- <tr>
166
- {columns.map((col) => (
167
- <th
168
- key={col.key}
169
- style={{
170
- ...styles.th,
171
- textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
172
- width: col.width,
173
- }}
174
- >
175
- {col.header}
176
- </th>
177
- ))}
178
- </tr>
179
- </thead>
180
- <tbody>
181
- {rows.map((row, rowIndex) => (
182
- <tr key={rowIndex}>
183
- {columns.map((col) => {
184
- const value = row[col.key];
185
- const formatted = formatCellValue(value, col);
186
- const cellStyle = {
187
- ...styles.td,
188
- textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
189
- ...(col.highlight ? styles.highlight[col.highlight] : {}),
190
- };
164
+ return (
165
+ <div style={styles.container}>
166
+ <table style={styles.table}>
167
+ <thead style={styles.thead}>
168
+ <tr>
169
+ {columns.map((col) => (
170
+ <th
171
+ key={col.key}
172
+ style={{
173
+ ...styles.th,
174
+ textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
175
+ width: col.width,
176
+ }}
177
+ >
178
+ {col.header}
179
+ </th>
180
+ ))}
181
+ </tr>
182
+ </thead>
183
+ <tbody>
184
+ {rows.map((row, rowIndex) => (
185
+ // biome-ignore lint/suspicious/noArrayIndexKey: list order is stable for this render
186
+ <tr key={rowIndex}>
187
+ {columns.map((col) => {
188
+ const value = row[col.key];
189
+ const formatted = formatCellValue(value, col);
190
+ const cellStyle = {
191
+ ...styles.td,
192
+ textAlign: alignmentStyle[col.key] as 'left' | 'center' | 'right',
193
+ ...(col.highlight ? styles.highlight[col.highlight] : {}),
194
+ };
191
195
 
192
- return (
193
- <td key={col.key} style={cellStyle}>
194
- {formatted}
195
- </td>
196
- );
197
- })}
198
- </tr>
199
- ))}
200
- </tbody>
201
- </table>
202
- </div>
203
- );
196
+ return (
197
+ <td key={col.key} style={cellStyle}>
198
+ {formatted}
199
+ </td>
200
+ );
201
+ })}
202
+ </tr>
203
+ ))}
204
+ </tbody>
205
+ </table>
206
+ </div>
207
+ );
204
208
  }
@@ -2,19 +2,19 @@
2
2
  * FusionFragment component exports
3
3
  */
4
4
 
5
- export { FusionFragmentRenderer } from './FusionFragmentRenderer.js';
6
- export { SectionRenderer } from './SectionRenderer.js';
7
- export { FieldRenderer } from './FieldRenderer.js';
8
- export { TableRenderer, type TableRendererProps } from './TableRenderer.js';
9
5
  export { ChartRenderer, type ChartRendererProps } from './ChartRenderer.js';
6
+ export { FieldRenderer } from './FieldRenderer.js';
10
7
  export {
11
- FusionFragmentProvider,
12
- useFusionFragmentContext,
13
- useFusionFragmentContextSafe,
14
- type FusionFragmentProviderProps,
8
+ FusionFragmentProvider,
9
+ type FusionFragmentProviderProps,
10
+ useFusionFragmentContext,
11
+ useFusionFragmentContextSafe,
15
12
  } from './FusionFragmentContext.js';
16
13
  export {
17
- FusionFragmentHandler,
18
- createFusionFragmentCodeBlockRenderer,
19
- type FusionFragmentHandlerProps,
14
+ createFusionFragmentCodeBlockRenderer,
15
+ FusionFragmentHandler,
16
+ type FusionFragmentHandlerProps,
20
17
  } from './FusionFragmentHandler.js';
18
+ export { FusionFragmentRenderer } from './FusionFragmentRenderer.js';
19
+ export { SectionRenderer } from './SectionRenderer.js';
20
+ export { TableRenderer, type TableRendererProps } from './TableRenderer.js';
package/src/index.ts CHANGED
@@ -36,54 +36,51 @@
36
36
  * @packageDocumentation
37
37
  */
38
38
 
39
- // Types
40
- export type {
41
- FragmentTemplate,
42
- SectionTemplate,
43
- FieldTemplate,
44
- ColumnTemplate,
45
- ChartTemplate,
46
- VegaLiteSpec,
47
- ValidationResult,
48
- ValidationError,
49
- FusionFragmentRendererProps,
50
- SectionRendererProps,
51
- FieldRendererProps,
52
- FusionFragmentContextValue,
53
- ValidateFusionFragmentInput,
54
- } from './types.js';
55
-
56
39
  // Components
57
40
  export {
58
- FusionFragmentRenderer,
59
- SectionRenderer,
60
- FieldRenderer,
61
- FusionFragmentProvider,
62
- FusionFragmentHandler,
63
- useFusionFragmentContext,
64
- useFusionFragmentContextSafe,
65
- createFusionFragmentCodeBlockRenderer,
66
- type FusionFragmentProviderProps,
67
- type FusionFragmentHandlerProps,
41
+ createFusionFragmentCodeBlockRenderer,
42
+ FieldRenderer,
43
+ FusionFragmentHandler,
44
+ type FusionFragmentHandlerProps,
45
+ FusionFragmentProvider,
46
+ type FusionFragmentProviderProps,
47
+ FusionFragmentRenderer,
48
+ SectionRenderer,
49
+ useFusionFragmentContext,
50
+ useFusionFragmentContextSafe,
68
51
  } from './fusion-fragment/index.js';
69
-
70
- // Validation utilities
71
- export {
72
- validateTemplate,
73
- parseAndValidateTemplate,
74
- FragmentTemplateSchema,
75
- SectionTemplateSchema,
76
- FieldTemplateSchema,
77
- findClosestKey,
78
- findSimilarKeys,
79
- formatValidationErrors,
80
- formatValidationSuccess,
81
- formatAvailableKeys,
82
- } from './validation/index.js';
83
-
84
52
  // Render utilities (text preview only - image rendering is in apps/tools)
85
53
  export {
86
- generateTextPreview,
87
- generateSampleData,
88
- generateCompactPreview,
54
+ generateCompactPreview,
55
+ generateSampleData,
56
+ generateTextPreview,
89
57
  } from './render/index.js';
58
+ // Types
59
+ export type {
60
+ ChartTemplate,
61
+ ColumnTemplate,
62
+ FieldRendererProps,
63
+ FieldTemplate,
64
+ FragmentTemplate,
65
+ FusionFragmentContextValue,
66
+ FusionFragmentRendererProps,
67
+ SectionRendererProps,
68
+ SectionTemplate,
69
+ ValidateFusionFragmentInput,
70
+ ValidationError,
71
+ ValidationResult,
72
+ VegaLiteSpec,
73
+ } from './types.js';
74
+ // Validation utilities
75
+ export {
76
+ FieldTemplateSchema,
77
+ FragmentTemplateSchema,
78
+ findClosestKey,
79
+ findSimilarKeys,
80
+ formatAvailableKeys,
81
+ formatValidationErrors,
82
+ formatValidationSuccess,
83
+ parseAndValidateTemplate,
84
+ SectionTemplateSchema,
85
+ validateTemplate,
86
+ } from './validation/index.js';
@@ -10,7 +10,7 @@
10
10
  */
11
11
 
12
12
  export {
13
- generateTextPreview,
14
- generateSampleData,
15
- generateCompactPreview,
13
+ generateCompactPreview,
14
+ generateSampleData,
15
+ generateTextPreview,
16
16
  } from './textPreview.js';