@xmachines/json-render-svelte 0.19.0-xm.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/LICENSE +201 -0
- package/README.md +155 -0
- package/dist/CatalogRenderer.svelte +59 -0
- package/dist/CatalogRenderer.svelte.d.ts +22 -0
- package/dist/CatalogRenderer.svelte.d.ts.map +1 -0
- package/dist/ConfirmDialog.svelte +98 -0
- package/dist/ConfirmDialog.svelte.d.ts +10 -0
- package/dist/ConfirmDialog.svelte.d.ts.map +1 -0
- package/dist/ConfirmDialogManager.svelte +15 -0
- package/dist/ConfirmDialogManager.svelte.d.ts +4 -0
- package/dist/ConfirmDialogManager.svelte.d.ts.map +1 -0
- package/dist/ElementRenderer.svelte +215 -0
- package/dist/ElementRenderer.svelte.d.ts +15 -0
- package/dist/ElementRenderer.svelte.d.ts.map +1 -0
- package/dist/JsonUIProvider.svelte +74 -0
- package/dist/JsonUIProvider.svelte.d.ts +39 -0
- package/dist/JsonUIProvider.svelte.d.ts.map +1 -0
- package/dist/Renderer.svelte +35 -0
- package/dist/Renderer.svelte.d.ts +19 -0
- package/dist/Renderer.svelte.d.ts.map +1 -0
- package/dist/RendererWithProvider.test.svelte +37 -0
- package/dist/RendererWithProvider.test.svelte.d.ts +14 -0
- package/dist/RendererWithProvider.test.svelte.d.ts.map +1 -0
- package/dist/RepeatChildren.svelte +51 -0
- package/dist/RepeatChildren.svelte.d.ts +13 -0
- package/dist/RepeatChildren.svelte.d.ts.map +1 -0
- package/dist/TestBoom.svelte +11 -0
- package/dist/TestBoom.svelte.d.ts +7 -0
- package/dist/TestBoom.svelte.d.ts.map +1 -0
- package/dist/TestButton.svelte +11 -0
- package/dist/TestButton.svelte.d.ts +9 -0
- package/dist/TestButton.svelte.d.ts.map +1 -0
- package/dist/TestContainer.svelte +19 -0
- package/dist/TestContainer.svelte.d.ts +11 -0
- package/dist/TestContainer.svelte.d.ts.map +1 -0
- package/dist/TestText.svelte +9 -0
- package/dist/TestText.svelte.d.ts +9 -0
- package/dist/TestText.svelte.d.ts.map +1 -0
- package/dist/catalog-types.d.ts +63 -0
- package/dist/catalog-types.d.ts.map +1 -0
- package/dist/catalog-types.js +1 -0
- package/dist/contexts/ActionProvider.svelte +375 -0
- package/dist/contexts/ActionProvider.svelte.d.ts +62 -0
- package/dist/contexts/ActionProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/DirectivesContextProvider.svelte +46 -0
- package/dist/contexts/DirectivesContextProvider.svelte.d.ts +21 -0
- package/dist/contexts/DirectivesContextProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/FunctionsContextProvider.svelte +44 -0
- package/dist/contexts/FunctionsContextProvider.svelte.d.ts +21 -0
- package/dist/contexts/FunctionsContextProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/RepeatScopeProvider.svelte +49 -0
- package/dist/contexts/RepeatScopeProvider.svelte.d.ts +26 -0
- package/dist/contexts/RepeatScopeProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/StateProvider.svelte +182 -0
- package/dist/contexts/StateProvider.svelte.d.ts +47 -0
- package/dist/contexts/StateProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/ValidationProvider.svelte +198 -0
- package/dist/contexts/ValidationProvider.svelte.d.ts +57 -0
- package/dist/contexts/ValidationProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/VisibilityProvider.svelte +82 -0
- package/dist/contexts/VisibilityProvider.svelte.d.ts +29 -0
- package/dist/contexts/VisibilityProvider.svelte.d.ts.map +1 -0
- package/dist/contexts/actions.test.js +156 -0
- package/dist/contexts/state.test.js +118 -0
- package/dist/contexts/visibility.test.js +71 -0
- package/dist/index.d.ts +19 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +31 -0
- package/dist/render-error.test.js +65 -0
- package/dist/renderer.d.ts +134 -0
- package/dist/renderer.d.ts.map +1 -0
- package/dist/renderer.js +145 -0
- package/dist/renderer.test.js +168 -0
- package/dist/schema.d.ts +57 -0
- package/dist/schema.d.ts.map +1 -0
- package/dist/schema.js +81 -0
- package/dist/streaming.svelte.d.ts +75 -0
- package/dist/streaming.svelte.d.ts.map +1 -0
- package/dist/streaming.svelte.js +404 -0
- package/dist/utils.svelte.d.ts +26 -0
- package/dist/utils.svelte.d.ts.map +1 -0
- package/dist/utils.svelte.js +92 -0
- package/dist/utils.test.js +307 -0
- package/package.json +71 -0
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { RenderErrorHandler, Spec, UIElement } from "@xmachines/json-render-core";
|
|
3
|
+
import {
|
|
4
|
+
resolveElementProps,
|
|
5
|
+
resolveBindings,
|
|
6
|
+
resolveActionParam,
|
|
7
|
+
evaluateVisibility,
|
|
8
|
+
isDevtoolsActive,
|
|
9
|
+
subscribeDevtoolsActive,
|
|
10
|
+
type PropResolutionContext,
|
|
11
|
+
} from "@xmachines/json-render-core";
|
|
12
|
+
import { onDestroy } from "svelte";
|
|
13
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
14
|
+
import type { EventHandle } from "./catalog-types.js";
|
|
15
|
+
import { getStateContext } from "./contexts/StateProvider.svelte";
|
|
16
|
+
import { getActionContext } from "./contexts/ActionProvider.svelte";
|
|
17
|
+
import { getRepeatScope } from "./contexts/RepeatScopeProvider.svelte";
|
|
18
|
+
import { getFunctions } from "./contexts/FunctionsContextProvider.svelte";
|
|
19
|
+
import { getDirectives } from "./contexts/DirectivesContextProvider.svelte";
|
|
20
|
+
import RepeatChildren from "./RepeatChildren.svelte";
|
|
21
|
+
import Self from "./ElementRenderer.svelte";
|
|
22
|
+
|
|
23
|
+
interface Props {
|
|
24
|
+
element: UIElement;
|
|
25
|
+
/** Spec key for this element. Used by the devtools picker. */
|
|
26
|
+
elementKey?: string;
|
|
27
|
+
spec: Spec;
|
|
28
|
+
registry: ComponentRegistry;
|
|
29
|
+
loading?: boolean;
|
|
30
|
+
fallback?: ComponentRenderer;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
let {
|
|
34
|
+
element,
|
|
35
|
+
elementKey,
|
|
36
|
+
spec,
|
|
37
|
+
registry,
|
|
38
|
+
loading = false,
|
|
39
|
+
fallback,
|
|
40
|
+
}: Props = $props();
|
|
41
|
+
|
|
42
|
+
// Reactive mirror of the devtools-active flag (for picker support).
|
|
43
|
+
let devtoolsActive = $state(isDevtoolsActive());
|
|
44
|
+
const unsubDevtools = subscribeDevtoolsActive(() => {
|
|
45
|
+
devtoolsActive = isDevtoolsActive();
|
|
46
|
+
});
|
|
47
|
+
onDestroy(unsubDevtools);
|
|
48
|
+
|
|
49
|
+
const stateCtx = getStateContext();
|
|
50
|
+
const actionCtx = getActionContext();
|
|
51
|
+
const repeatScope = getRepeatScope();
|
|
52
|
+
const functions = getFunctions();
|
|
53
|
+
const directives = getDirectives();
|
|
54
|
+
|
|
55
|
+
// Build context with repeat scope, $computed functions, and custom directives
|
|
56
|
+
let fullCtx = $derived<PropResolutionContext>(
|
|
57
|
+
repeatScope
|
|
58
|
+
? {
|
|
59
|
+
stateModel: stateCtx.state,
|
|
60
|
+
repeatItem: repeatScope.item,
|
|
61
|
+
repeatIndex: repeatScope.index,
|
|
62
|
+
repeatBasePath: repeatScope.basePath,
|
|
63
|
+
functions,
|
|
64
|
+
directives,
|
|
65
|
+
}
|
|
66
|
+
: { stateModel: stateCtx.state, functions, directives },
|
|
67
|
+
);
|
|
68
|
+
|
|
69
|
+
// Evaluate visibility
|
|
70
|
+
let isVisible = $derived(
|
|
71
|
+
element.visible === undefined
|
|
72
|
+
? true
|
|
73
|
+
: evaluateVisibility(element.visible, fullCtx),
|
|
74
|
+
);
|
|
75
|
+
|
|
76
|
+
// Resolve props and bindings
|
|
77
|
+
let rawProps = $derived(element.props as Record<string, unknown>);
|
|
78
|
+
let resolvedProps = $derived(resolveElementProps(rawProps, fullCtx));
|
|
79
|
+
let elementBindings = $derived(resolveBindings(rawProps, fullCtx));
|
|
80
|
+
|
|
81
|
+
// Create resolved element
|
|
82
|
+
let resolvedElement = $derived(
|
|
83
|
+
resolvedProps !== element.props
|
|
84
|
+
? { ...element, props: resolvedProps }
|
|
85
|
+
: element,
|
|
86
|
+
);
|
|
87
|
+
|
|
88
|
+
// Get the component renderer
|
|
89
|
+
let Component = $derived(registry[resolvedElement.type] ?? fallback);
|
|
90
|
+
|
|
91
|
+
// Create emit function
|
|
92
|
+
function emit(eventName: string): void {
|
|
93
|
+
const binding = element.on?.[eventName];
|
|
94
|
+
if (!binding) return;
|
|
95
|
+
|
|
96
|
+
const actionBindings = Array.isArray(binding) ? binding : [binding];
|
|
97
|
+
for (const b of actionBindings) {
|
|
98
|
+
if (!b.params) {
|
|
99
|
+
actionCtx.execute(b);
|
|
100
|
+
continue;
|
|
101
|
+
}
|
|
102
|
+
// Resolve all action params
|
|
103
|
+
const resolved: Record<string, unknown> = {};
|
|
104
|
+
for (const [key, val] of Object.entries(b.params)) {
|
|
105
|
+
resolved[key] = resolveActionParam(val, fullCtx);
|
|
106
|
+
}
|
|
107
|
+
actionCtx.execute({ ...b, params: resolved });
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
function on(eventName: string): EventHandle {
|
|
112
|
+
const binding = element.on?.[eventName];
|
|
113
|
+
if (!binding) {
|
|
114
|
+
return { emit: () => {}, shouldPreventDefault: false, bound: false };
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
const actionBindings = Array.isArray(binding) ? binding : [binding];
|
|
118
|
+
const shouldPreventDefault = actionBindings.some((b) => b.preventDefault);
|
|
119
|
+
return {
|
|
120
|
+
emit: () => emit(eventName),
|
|
121
|
+
shouldPreventDefault,
|
|
122
|
+
bound: true,
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
</script>
|
|
126
|
+
|
|
127
|
+
{#if isVisible && Component}
|
|
128
|
+
<svelte:boundary
|
|
129
|
+
onerror={(error) => {
|
|
130
|
+
// onRenderError is attached as a non-enumerable registry property
|
|
131
|
+
// (defineRegistry / createRenderer), not declared on ComponentRegistry.
|
|
132
|
+
const onRenderError = (
|
|
133
|
+
registry as { onRenderError?: RenderErrorHandler }
|
|
134
|
+
).onRenderError;
|
|
135
|
+
if (typeof onRenderError === 'function') {
|
|
136
|
+
onRenderError(error, resolvedElement.type);
|
|
137
|
+
} else {
|
|
138
|
+
console.error(
|
|
139
|
+
`[json-render] Rendering error in <${resolvedElement.type}>:`,
|
|
140
|
+
error,
|
|
141
|
+
);
|
|
142
|
+
}
|
|
143
|
+
}}>
|
|
144
|
+
{#if devtoolsActive && elementKey}
|
|
145
|
+
<span data-jr-key={elementKey} style="display:contents">
|
|
146
|
+
<Component
|
|
147
|
+
element={resolvedElement}
|
|
148
|
+
bindings={elementBindings}
|
|
149
|
+
{loading}
|
|
150
|
+
{on}
|
|
151
|
+
{emit}>
|
|
152
|
+
{#if resolvedElement.repeat}
|
|
153
|
+
<RepeatChildren
|
|
154
|
+
element={resolvedElement}
|
|
155
|
+
{spec}
|
|
156
|
+
{registry}
|
|
157
|
+
{loading}
|
|
158
|
+
{fallback} />
|
|
159
|
+
{:else if resolvedElement.children}
|
|
160
|
+
{#each resolvedElement.children as childKey (childKey)}
|
|
161
|
+
{#if spec.elements[childKey]}
|
|
162
|
+
<Self
|
|
163
|
+
element={spec.elements[childKey]}
|
|
164
|
+
elementKey={childKey}
|
|
165
|
+
{spec}
|
|
166
|
+
{registry}
|
|
167
|
+
{loading}
|
|
168
|
+
{fallback} />
|
|
169
|
+
{:else if !loading}
|
|
170
|
+
{console.warn(
|
|
171
|
+
`[json-render] Missing element "${childKey}" referenced as child of "${resolvedElement.type}". This element will not render.`,
|
|
172
|
+
)}
|
|
173
|
+
{/if}
|
|
174
|
+
{/each}
|
|
175
|
+
{/if}
|
|
176
|
+
</Component>
|
|
177
|
+
</span>
|
|
178
|
+
{:else}
|
|
179
|
+
<Component
|
|
180
|
+
element={resolvedElement}
|
|
181
|
+
bindings={elementBindings}
|
|
182
|
+
{loading}
|
|
183
|
+
{on}
|
|
184
|
+
{emit}>
|
|
185
|
+
{#if resolvedElement.repeat}
|
|
186
|
+
<RepeatChildren
|
|
187
|
+
element={resolvedElement}
|
|
188
|
+
{spec}
|
|
189
|
+
{registry}
|
|
190
|
+
{loading}
|
|
191
|
+
{fallback} />
|
|
192
|
+
{:else if resolvedElement.children}
|
|
193
|
+
{#each resolvedElement.children as childKey (childKey)}
|
|
194
|
+
{#if spec.elements[childKey]}
|
|
195
|
+
<Self
|
|
196
|
+
element={spec.elements[childKey]}
|
|
197
|
+
elementKey={childKey}
|
|
198
|
+
{spec}
|
|
199
|
+
{registry}
|
|
200
|
+
{loading}
|
|
201
|
+
{fallback} />
|
|
202
|
+
{:else if !loading}
|
|
203
|
+
{console.warn(
|
|
204
|
+
`[json-render] Missing element "${childKey}" referenced as child of "${resolvedElement.type}". This element will not render.`,
|
|
205
|
+
)}
|
|
206
|
+
{/if}
|
|
207
|
+
{/each}
|
|
208
|
+
{/if}
|
|
209
|
+
</Component>
|
|
210
|
+
{/if}
|
|
211
|
+
{#snippet failed()}
|
|
212
|
+
<!-- render nothing -->
|
|
213
|
+
{/snippet}
|
|
214
|
+
</svelte:boundary>
|
|
215
|
+
{/if}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { Spec, UIElement } from "@xmachines/json-render-core";
|
|
2
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
3
|
+
interface Props {
|
|
4
|
+
element: UIElement;
|
|
5
|
+
/** Spec key for this element. Used by the devtools picker. */
|
|
6
|
+
elementKey?: string;
|
|
7
|
+
spec: Spec;
|
|
8
|
+
registry: ComponentRegistry;
|
|
9
|
+
loading?: boolean;
|
|
10
|
+
fallback?: ComponentRenderer;
|
|
11
|
+
}
|
|
12
|
+
declare const ElementRenderer: import("svelte").Component<Props, {}, "">;
|
|
13
|
+
type ElementRenderer = ReturnType<typeof ElementRenderer>;
|
|
14
|
+
export default ElementRenderer;
|
|
15
|
+
//# sourceMappingURL=ElementRenderer.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ElementRenderer.svelte.d.ts","sourceRoot":"","sources":["../src/ElementRenderer.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAsB,IAAI,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAW7E,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAWxE,UAAU,KAAK;IACb,OAAO,EAAE,SAAS,CAAC;IACnB,8DAA8D;IAC9D,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,IAAI,CAAC;IACX,QAAQ,EAAE,iBAAiB,CAAC;IAC5B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,iBAAiB,CAAC;CAC9B;AAwKH,QAAA,MAAM,eAAe,2CAAwC,CAAC;AAC9D,KAAK,eAAe,GAAG,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC;AAC1D,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
import type { ComputedFunction, DirectiveDefinition } from "@xmachines/json-render-core";
|
|
3
|
+
/**
|
|
4
|
+
* Props for JSONUIProvider
|
|
5
|
+
*/
|
|
6
|
+
export interface JSONUIProviderProps {
|
|
7
|
+
/** Component registry (passed through for convenience; not used internally) */
|
|
8
|
+
registry?: ComponentRegistry;
|
|
9
|
+
/**
|
|
10
|
+
* External store (controlled mode). When provided, `initialState` and
|
|
11
|
+
* `onStateChange` are ignored.
|
|
12
|
+
*/
|
|
13
|
+
store?: StateStore;
|
|
14
|
+
/** Initial state model */
|
|
15
|
+
initialState?: Record<string, unknown>;
|
|
16
|
+
/** Action handlers */
|
|
17
|
+
handlers?: Record<string, ActionHandler>;
|
|
18
|
+
/** Navigation function */
|
|
19
|
+
navigate?: (path: string) => void;
|
|
20
|
+
/** Custom validation functions */
|
|
21
|
+
validationFunctions?: Record<
|
|
22
|
+
string,
|
|
23
|
+
(value: unknown, args?: Record<string, unknown>) => boolean
|
|
24
|
+
>;
|
|
25
|
+
/** Named functions for `$computed` expressions in props */
|
|
26
|
+
functions?: Record<string, ComputedFunction>;
|
|
27
|
+
/** Custom directives for user-defined `$`-prefixed dynamic values */
|
|
28
|
+
directives?: DirectiveDefinition[];
|
|
29
|
+
/** Callback when state changes (uncontrolled mode) */
|
|
30
|
+
onStateChange?: (changes: Array<{ path: string; value: unknown }>) => void;
|
|
31
|
+
/** Children snippet */
|
|
32
|
+
children: Snippet;
|
|
33
|
+
}
|
|
34
|
+
</script>
|
|
35
|
+
|
|
36
|
+
<script lang="ts">
|
|
37
|
+
import type { Snippet } from "svelte";
|
|
38
|
+
import type { ActionHandler, StateStore } from "@xmachines/json-render-core";
|
|
39
|
+
import StateProvider from "./contexts/StateProvider.svelte";
|
|
40
|
+
import VisibilityProvider from "./contexts/VisibilityProvider.svelte";
|
|
41
|
+
import ValidationProvider from "./contexts/ValidationProvider.svelte";
|
|
42
|
+
import ActionProvider from "./contexts/ActionProvider.svelte";
|
|
43
|
+
import FunctionsContextProvider from "./contexts/FunctionsContextProvider.svelte";
|
|
44
|
+
import DirectivesContextProvider from "./contexts/DirectivesContextProvider.svelte";
|
|
45
|
+
import ConfirmDialogManager from "./ConfirmDialogManager.svelte";
|
|
46
|
+
import type { ComponentRegistry } from "./renderer.js";
|
|
47
|
+
|
|
48
|
+
let {
|
|
49
|
+
store,
|
|
50
|
+
initialState = {},
|
|
51
|
+
handlers = {},
|
|
52
|
+
navigate,
|
|
53
|
+
validationFunctions = {},
|
|
54
|
+
functions,
|
|
55
|
+
directives,
|
|
56
|
+
onStateChange,
|
|
57
|
+
children,
|
|
58
|
+
}: JSONUIProviderProps = $props();
|
|
59
|
+
</script>
|
|
60
|
+
|
|
61
|
+
<StateProvider {store} {initialState} {onStateChange}>
|
|
62
|
+
<VisibilityProvider>
|
|
63
|
+
<ValidationProvider customFunctions={validationFunctions}>
|
|
64
|
+
<ActionProvider {handlers} {navigate}>
|
|
65
|
+
<FunctionsContextProvider {functions}>
|
|
66
|
+
<DirectivesContextProvider {directives}>
|
|
67
|
+
{@render children()}
|
|
68
|
+
<ConfirmDialogManager />
|
|
69
|
+
</DirectivesContextProvider>
|
|
70
|
+
</FunctionsContextProvider>
|
|
71
|
+
</ActionProvider>
|
|
72
|
+
</ValidationProvider>
|
|
73
|
+
</VisibilityProvider>
|
|
74
|
+
</StateProvider>
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { ComputedFunction, DirectiveDefinition } from "@xmachines/json-render-core";
|
|
2
|
+
/**
|
|
3
|
+
* Props for JSONUIProvider
|
|
4
|
+
*/
|
|
5
|
+
export interface JSONUIProviderProps {
|
|
6
|
+
/** Component registry (passed through for convenience; not used internally) */
|
|
7
|
+
registry?: ComponentRegistry;
|
|
8
|
+
/**
|
|
9
|
+
* External store (controlled mode). When provided, `initialState` and
|
|
10
|
+
* `onStateChange` are ignored.
|
|
11
|
+
*/
|
|
12
|
+
store?: StateStore;
|
|
13
|
+
/** Initial state model */
|
|
14
|
+
initialState?: Record<string, unknown>;
|
|
15
|
+
/** Action handlers */
|
|
16
|
+
handlers?: Record<string, ActionHandler>;
|
|
17
|
+
/** Navigation function */
|
|
18
|
+
navigate?: (path: string) => void;
|
|
19
|
+
/** Custom validation functions */
|
|
20
|
+
validationFunctions?: Record<string, (value: unknown, args?: Record<string, unknown>) => boolean>;
|
|
21
|
+
/** Named functions for `$computed` expressions in props */
|
|
22
|
+
functions?: Record<string, ComputedFunction>;
|
|
23
|
+
/** Custom directives for user-defined `$`-prefixed dynamic values */
|
|
24
|
+
directives?: DirectiveDefinition[];
|
|
25
|
+
/** Callback when state changes (uncontrolled mode) */
|
|
26
|
+
onStateChange?: (changes: Array<{
|
|
27
|
+
path: string;
|
|
28
|
+
value: unknown;
|
|
29
|
+
}>) => void;
|
|
30
|
+
/** Children snippet */
|
|
31
|
+
children: Snippet;
|
|
32
|
+
}
|
|
33
|
+
import type { Snippet } from "svelte";
|
|
34
|
+
import type { ActionHandler, StateStore } from "@xmachines/json-render-core";
|
|
35
|
+
import type { ComponentRegistry } from "./renderer.js";
|
|
36
|
+
declare const JsonUIProvider: import("svelte").Component<JSONUIProviderProps, {}, "">;
|
|
37
|
+
type JsonUIProvider = ReturnType<typeof JsonUIProvider>;
|
|
38
|
+
export default JsonUIProvider;
|
|
39
|
+
//# sourceMappingURL=JsonUIProvider.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"JsonUIProvider.svelte.d.ts","sourceRoot":"","sources":["../src/JsonUIProvider.svelte.ts"],"names":[],"mappings":"AAGE,OAAO,KAAK,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC/E;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,+EAA+E;IAC/E,QAAQ,CAAC,EAAE,iBAAiB,CAAC;IAC7B;;;OAGG;IACH,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,0BAA0B;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACvC,sBAAsB;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;IACzC,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,kCAAkC;IAClC,mBAAmB,CAAC,EAAE,MAAM,CAC1B,MAAM,EACN,CAAC,KAAK,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,OAAO,CAC5D,CAAC;IACF,2DAA2D;IAC3D,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC;IAC7C,qEAAqE;IACrE,UAAU,CAAC,EAAE,mBAAmB,EAAE,CAAC;IACnC,sDAAsD;IACtD,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,OAAO,CAAA;KAAE,CAAC,KAAK,IAAI,CAAC;IAC3E,uBAAuB;IACvB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAGH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,QAAQ,CAAC;AACtC,OAAO,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAQnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AA8CvD,QAAA,MAAM,cAAc,yDAAwC,CAAC;AAC7D,KAAK,cAAc,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AACxD,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
import type { Spec } from "@xmachines/json-render-core";
|
|
3
|
+
import ElementRenderer from "./ElementRenderer.svelte";
|
|
4
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Props for the Renderer component
|
|
8
|
+
*/
|
|
9
|
+
export interface RendererProps {
|
|
10
|
+
/** The UI spec to render */
|
|
11
|
+
spec: Spec | null;
|
|
12
|
+
/** Component registry */
|
|
13
|
+
registry: ComponentRegistry;
|
|
14
|
+
/** Whether the spec is currently loading/streaming */
|
|
15
|
+
loading?: boolean;
|
|
16
|
+
/** Fallback component for unknown types */
|
|
17
|
+
fallback?: ComponentRenderer;
|
|
18
|
+
}
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<script lang="ts">
|
|
22
|
+
let { spec, registry, loading = false, fallback }: RendererProps = $props();
|
|
23
|
+
|
|
24
|
+
let rootElement = $derived(spec?.root ? spec.elements[spec.root] : undefined);
|
|
25
|
+
</script>
|
|
26
|
+
|
|
27
|
+
{#if spec && rootElement}
|
|
28
|
+
<ElementRenderer
|
|
29
|
+
element={rootElement}
|
|
30
|
+
elementKey={spec.root}
|
|
31
|
+
{spec}
|
|
32
|
+
{registry}
|
|
33
|
+
{loading}
|
|
34
|
+
{fallback} />
|
|
35
|
+
{/if}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { Spec } from "@xmachines/json-render-core";
|
|
2
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Renderer component
|
|
5
|
+
*/
|
|
6
|
+
export interface RendererProps {
|
|
7
|
+
/** The UI spec to render */
|
|
8
|
+
spec: Spec | null;
|
|
9
|
+
/** Component registry */
|
|
10
|
+
registry: ComponentRegistry;
|
|
11
|
+
/** Whether the spec is currently loading/streaming */
|
|
12
|
+
loading?: boolean;
|
|
13
|
+
/** Fallback component for unknown types */
|
|
14
|
+
fallback?: ComponentRenderer;
|
|
15
|
+
}
|
|
16
|
+
declare const Renderer: import("svelte").Component<RendererProps, {}, "">;
|
|
17
|
+
type Renderer = ReturnType<typeof Renderer>;
|
|
18
|
+
export default Renderer;
|
|
19
|
+
//# sourceMappingURL=Renderer.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Renderer.svelte.d.ts","sourceRoot":"","sources":["../src/Renderer.svelte.ts"],"names":[],"mappings":"AAGE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAE1E;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,4BAA4B;IAC5B,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,yBAAyB;IACzB,QAAQ,EAAE,iBAAiB,CAAC;IAC5B,sDAAsD;IACtD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,2CAA2C;IAC3C,QAAQ,CAAC,EAAE,iBAAiB,CAAC;CAC9B;AAgBH,QAAA,MAAM,QAAQ,mDAAwC,CAAC;AACvD,KAAK,QAAQ,GAAG,UAAU,CAAC,OAAO,QAAQ,CAAC,CAAC;AAC5C,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Spec, ActionHandler } from "@xmachines/json-render-core";
|
|
3
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
4
|
+
import StateProvider from "./contexts/StateProvider.svelte";
|
|
5
|
+
import VisibilityProvider from "./contexts/VisibilityProvider.svelte";
|
|
6
|
+
import ValidationProvider from "./contexts/ValidationProvider.svelte";
|
|
7
|
+
import ActionProvider from "./contexts/ActionProvider.svelte";
|
|
8
|
+
import Renderer from "./Renderer.svelte";
|
|
9
|
+
|
|
10
|
+
interface Props {
|
|
11
|
+
spec: Spec | null;
|
|
12
|
+
registry: ComponentRegistry;
|
|
13
|
+
loading?: boolean;
|
|
14
|
+
fallback?: ComponentRenderer;
|
|
15
|
+
initialState?: Record<string, unknown>;
|
|
16
|
+
handlers?: Record<string, ActionHandler>;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
let {
|
|
20
|
+
spec,
|
|
21
|
+
registry,
|
|
22
|
+
loading = false,
|
|
23
|
+
fallback,
|
|
24
|
+
initialState = {},
|
|
25
|
+
handlers = {},
|
|
26
|
+
}: Props = $props();
|
|
27
|
+
</script>
|
|
28
|
+
|
|
29
|
+
<StateProvider {initialState}>
|
|
30
|
+
<VisibilityProvider>
|
|
31
|
+
<ValidationProvider>
|
|
32
|
+
<ActionProvider {handlers}>
|
|
33
|
+
<Renderer {spec} {registry} {loading} {fallback} />
|
|
34
|
+
</ActionProvider>
|
|
35
|
+
</ValidationProvider>
|
|
36
|
+
</VisibilityProvider>
|
|
37
|
+
</StateProvider>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Spec, ActionHandler } from "@xmachines/json-render-core";
|
|
2
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
3
|
+
interface Props {
|
|
4
|
+
spec: Spec | null;
|
|
5
|
+
registry: ComponentRegistry;
|
|
6
|
+
loading?: boolean;
|
|
7
|
+
fallback?: ComponentRenderer;
|
|
8
|
+
initialState?: Record<string, unknown>;
|
|
9
|
+
handlers?: Record<string, ActionHandler>;
|
|
10
|
+
}
|
|
11
|
+
declare const RendererWithProvider: import("svelte").Component<Props, {}, "">;
|
|
12
|
+
type RendererWithProvider = ReturnType<typeof RendererWithProvider>;
|
|
13
|
+
export default RendererWithProvider;
|
|
14
|
+
//# sourceMappingURL=RendererWithProvider.test.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RendererWithProvider.test.svelte.d.ts","sourceRoot":"","sources":["../src/RendererWithProvider.test.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAQxE,UAAU,KAAK;IACb,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,QAAQ,EAAE,iBAAiB,CAAC;IAC5B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,iBAAiB,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACvC,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;CAC1C;AAiCH,QAAA,MAAM,oBAAoB,2CAAwC,CAAC;AACnE,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,oBAAoB,CAAC,CAAC;AACpE,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Spec, UIElement } from "@xmachines/json-render-core";
|
|
3
|
+
import { getByPath } from "@xmachines/json-render-core";
|
|
4
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
5
|
+
import { getStateContext } from "./contexts/StateProvider.svelte";
|
|
6
|
+
import RepeatScopeProvider from "./contexts/RepeatScopeProvider.svelte";
|
|
7
|
+
import ElementRenderer from "./ElementRenderer.svelte";
|
|
8
|
+
|
|
9
|
+
interface Props {
|
|
10
|
+
element: UIElement;
|
|
11
|
+
spec: Spec;
|
|
12
|
+
registry: ComponentRegistry;
|
|
13
|
+
loading?: boolean;
|
|
14
|
+
fallback?: ComponentRenderer;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
let { element, spec, registry, loading = false, fallback }: Props = $props();
|
|
18
|
+
|
|
19
|
+
const stateCtx = getStateContext();
|
|
20
|
+
|
|
21
|
+
// Get items from state
|
|
22
|
+
let items = $derived(
|
|
23
|
+
(getByPath(stateCtx.state, element.repeat!.statePath) as
|
|
24
|
+
| unknown[]
|
|
25
|
+
| undefined) ?? [],
|
|
26
|
+
);
|
|
27
|
+
</script>
|
|
28
|
+
|
|
29
|
+
{#each items as itemValue, index (element.repeat?.key && typeof itemValue === "object" && itemValue !== null ? String((itemValue as any)[element.repeat.key] ?? index) : String(index))}
|
|
30
|
+
{@const basePath = `${element.repeat!.statePath}/${index}`}
|
|
31
|
+
|
|
32
|
+
{#if element.children}
|
|
33
|
+
<RepeatScopeProvider item={itemValue} {index} {basePath}>
|
|
34
|
+
{#each element.children as childKey (childKey)}
|
|
35
|
+
{#if spec.elements[childKey]}
|
|
36
|
+
<ElementRenderer
|
|
37
|
+
element={spec.elements[childKey]}
|
|
38
|
+
elementKey={childKey}
|
|
39
|
+
{spec}
|
|
40
|
+
{registry}
|
|
41
|
+
{loading}
|
|
42
|
+
{fallback} />
|
|
43
|
+
{:else if !loading}
|
|
44
|
+
{console.warn(
|
|
45
|
+
`[json-render] Missing element "${childKey}" referenced as child of "${element.type}". This element will not render.`,
|
|
46
|
+
)}
|
|
47
|
+
{/if}
|
|
48
|
+
{/each}
|
|
49
|
+
</RepeatScopeProvider>
|
|
50
|
+
{/if}
|
|
51
|
+
{/each}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Spec, UIElement } from "@xmachines/json-render-core";
|
|
2
|
+
import type { ComponentRegistry, ComponentRenderer } from "./renderer.js";
|
|
3
|
+
interface Props {
|
|
4
|
+
element: UIElement;
|
|
5
|
+
spec: Spec;
|
|
6
|
+
registry: ComponentRegistry;
|
|
7
|
+
loading?: boolean;
|
|
8
|
+
fallback?: ComponentRenderer;
|
|
9
|
+
}
|
|
10
|
+
declare const RepeatChildren: import("svelte").Component<Props, {}, "">;
|
|
11
|
+
type RepeatChildren = ReturnType<typeof RepeatChildren>;
|
|
12
|
+
export default RepeatChildren;
|
|
13
|
+
//# sourceMappingURL=RepeatChildren.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RepeatChildren.svelte.d.ts","sourceRoot":"","sources":["../src/RepeatChildren.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEzD,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAMxE,UAAU,KAAK;IACb,OAAO,EAAE,SAAS,CAAC;IACnB,IAAI,EAAE,IAAI,CAAC;IACX,QAAQ,EAAE,iBAAiB,CAAC;IAC5B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,iBAAiB,CAAC;CAC9B;AA0CH,QAAA,MAAM,cAAc,2CAAwC,CAAC;AAC7D,KAAK,cAAc,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AACxD,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
3
|
+
|
|
4
|
+
interface Props extends BaseComponentProps<Record<string, never>> {}
|
|
5
|
+
|
|
6
|
+
let { props }: Props = $props();
|
|
7
|
+
|
|
8
|
+
throw new Error("boom-svelte");
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<span class="test-boom">never rendered</span>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
2
|
+
interface Props extends BaseComponentProps<Record<string, never>> {
|
|
3
|
+
}
|
|
4
|
+
declare const TestBoom: import("svelte").Component<Props, {}, "">;
|
|
5
|
+
type TestBoom = ReturnType<typeof TestBoom>;
|
|
6
|
+
export default TestBoom;
|
|
7
|
+
//# sourceMappingURL=TestBoom.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestBoom.svelte.d.ts","sourceRoot":"","sources":["../src/TestBoom.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAG3D,UAAU,KAAM,SAAQ,kBAAkB,CAAC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;CAAG;AActE,QAAA,MAAM,QAAQ,2CAAwC,CAAC;AACvD,KAAK,QAAQ,GAAG,UAAU,CAAC,OAAO,QAAQ,CAAC,CAAC;AAC5C,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
3
|
+
|
|
4
|
+
interface Props extends BaseComponentProps<{ label?: string }> {}
|
|
5
|
+
|
|
6
|
+
let { props, emit, bindings, loading }: Props = $props();
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<button class="test-button" onclick={() => emit("press")}>
|
|
10
|
+
{props.label ?? "Button"}
|
|
11
|
+
</button>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
2
|
+
interface Props extends BaseComponentProps<{
|
|
3
|
+
label?: string;
|
|
4
|
+
}> {
|
|
5
|
+
}
|
|
6
|
+
declare const TestButton: import("svelte").Component<Props, {}, "">;
|
|
7
|
+
type TestButton = ReturnType<typeof TestButton>;
|
|
8
|
+
export default TestButton;
|
|
9
|
+
//# sourceMappingURL=TestButton.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestButton.svelte.d.ts","sourceRoot":"","sources":["../src/TestButton.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAG3D,UAAU,KAAM,SAAQ,kBAAkB,CAAC;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;CAAG;AAcnE,QAAA,MAAM,UAAU,2CAAwC,CAAC;AACzD,KAAK,UAAU,GAAG,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC;AAChD,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from "svelte";
|
|
3
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
4
|
+
|
|
5
|
+
interface Props extends BaseComponentProps<{ title?: string }> {
|
|
6
|
+
children?: Snippet;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
let { props, children, emit, bindings, loading }: Props = $props();
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<div class="test-container" data-loading={loading}>
|
|
13
|
+
{#if props.title}
|
|
14
|
+
<h2>{props.title}</h2>
|
|
15
|
+
{/if}
|
|
16
|
+
{#if children}
|
|
17
|
+
{@render children()}
|
|
18
|
+
{/if}
|
|
19
|
+
</div>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Snippet } from "svelte";
|
|
2
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
3
|
+
interface Props extends BaseComponentProps<{
|
|
4
|
+
title?: string;
|
|
5
|
+
}> {
|
|
6
|
+
children?: Snippet;
|
|
7
|
+
}
|
|
8
|
+
declare const TestContainer: import("svelte").Component<Props, {}, "">;
|
|
9
|
+
type TestContainer = ReturnType<typeof TestContainer>;
|
|
10
|
+
export default TestContainer;
|
|
11
|
+
//# sourceMappingURL=TestContainer.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestContainer.svelte.d.ts","sourceRoot":"","sources":["../src/TestContainer.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,QAAQ,CAAC;AACtC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAG3D,UAAU,KAAM,SAAQ,kBAAkB,CAAC;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;IAC5D,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAoBH,QAAA,MAAM,aAAa,2CAAwC,CAAC;AAC5D,KAAK,aAAa,GAAG,UAAU,CAAC,OAAO,aAAa,CAAC,CAAC;AACtD,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
3
|
+
|
|
4
|
+
interface Props extends BaseComponentProps<{ text?: string }> {}
|
|
5
|
+
|
|
6
|
+
let { props, emit, bindings, loading }: Props = $props();
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<span class="test-text">{props.text ?? ""}</span>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { BaseComponentProps } from "./catalog-types.js";
|
|
2
|
+
interface Props extends BaseComponentProps<{
|
|
3
|
+
text?: string;
|
|
4
|
+
}> {
|
|
5
|
+
}
|
|
6
|
+
declare const TestText: import("svelte").Component<Props, {}, "">;
|
|
7
|
+
type TestText = ReturnType<typeof TestText>;
|
|
8
|
+
export default TestText;
|
|
9
|
+
//# sourceMappingURL=TestText.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestText.svelte.d.ts","sourceRoot":"","sources":["../src/TestText.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAG3D,UAAU,KAAM,SAAQ,kBAAkB,CAAC;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;CAAG;AAYlE,QAAA,MAAM,QAAQ,2CAAwC,CAAC;AACvD,KAAK,QAAQ,GAAG,UAAU,CAAC,OAAO,QAAQ,CAAC,CAAC;AAC5C,eAAe,QAAQ,CAAC"}
|