@pipelex/mthds-form 0.34.0 → 0.35.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/dist/{chunk-5RV3ASMO.js → chunk-TD62R3P6.js} +348 -190
- package/dist/chunk-TD62R3P6.js.map +1 -0
- package/dist/{chunk-XYS5KCXB.js → chunk-XLTYIIUY.js} +127 -10
- package/dist/chunk-XLTYIIUY.js.map +1 -0
- package/dist/{field-renderer-BYN6YrU-.d.ts → field-presentation-D5BkBSjX.d.ts} +49 -9
- package/dist/generative/headless/index.d.ts +36 -2
- package/dist/generative/headless/index.js +2 -1
- package/dist/generative/index.d.ts +27 -19
- package/dist/generative/index.js +31 -30
- package/dist/generative/index.js.map +1 -1
- package/dist/layout-sample.mthds +85 -0
- package/dist/react/index.d.ts +49 -61
- package/dist/react/index.js +1 -1
- package/dist/styles.css +1 -1
- package/package.json +3 -2
- package/dist/chunk-5RV3ASMO.js.map +0 -1
- package/dist/chunk-XYS5KCXB.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { ReactNode, RefObject, Ref } from 'react';
|
|
3
3
|
import { FileRunField, RunField } from './core/descriptor.js';
|
|
4
4
|
import { FileFormat } from './core/file-formats.js';
|
|
@@ -51,7 +51,7 @@ interface FilePickerEntryProps {
|
|
|
51
51
|
* "Choose from your team's files": a full-width row with a folder icon, under
|
|
52
52
|
* the field's own controls.
|
|
53
53
|
*/
|
|
54
|
-
declare function FilePickerEntry({ onOpen, label, disabled, ref, id }: FilePickerEntryProps):
|
|
54
|
+
declare function FilePickerEntry({ onOpen, label, disabled, ref, id }: FilePickerEntryProps): react.JSX.Element;
|
|
55
55
|
interface FilePickerProps {
|
|
56
56
|
/** The host's list, and how its rows draw. */
|
|
57
57
|
source: FilePickerSource;
|
|
@@ -106,7 +106,7 @@ interface FilePickerProps {
|
|
|
106
106
|
* the field as it was: only Use writes. The sheet's state lives in its body,
|
|
107
107
|
* which mounts when it opens, so it always opens on a fresh choice.
|
|
108
108
|
*/
|
|
109
|
-
declare function FilePicker({ open, onOpenChange, returnFocusTo, onCloseAutoFocus, disabled, ...props }: FilePickerProps):
|
|
109
|
+
declare function FilePicker({ open, onOpenChange, returnFocusTo, onCloseAutoFocus, disabled, ...props }: FilePickerProps): react.JSX.Element;
|
|
110
110
|
|
|
111
111
|
/** The serializable value of a file field. URL is what the runner sends. */
|
|
112
112
|
interface FileValue {
|
|
@@ -138,7 +138,7 @@ interface FileFieldProps {
|
|
|
138
138
|
onDropFile?: (file: File) => void | PromiseLike<UploadedFile | void>;
|
|
139
139
|
/**
|
|
140
140
|
* Whether the link input is offered, `true` when absent. `false` removes the
|
|
141
|
-
* "
|
|
141
|
+
* "Paste a link instead" toggle and the input behind it, and says nothing about
|
|
142
142
|
* which values are valid. With no `onDropFile` either, the control throws.
|
|
143
143
|
*/
|
|
144
144
|
allowUrl?: boolean;
|
|
@@ -167,9 +167,9 @@ interface FileFieldProps {
|
|
|
167
167
|
disabled?: boolean;
|
|
168
168
|
}
|
|
169
169
|
/** Document variant: a file shown as a PDF preview (or chip for other docs). */
|
|
170
|
-
declare function DocumentField(props: FileFieldProps):
|
|
170
|
+
declare function DocumentField(props: FileFieldProps): react.JSX.Element;
|
|
171
171
|
/** Image variant: a file shown as a real image preview. */
|
|
172
|
-
declare function ImageField(props: FileFieldProps):
|
|
172
|
+
declare function ImageField(props: FileFieldProps): react.JSX.Element;
|
|
173
173
|
|
|
174
174
|
/**
|
|
175
175
|
* The moves a host makes to a list's rows, and what a move does to an id.
|
|
@@ -227,7 +227,7 @@ interface FieldEnv {
|
|
|
227
227
|
onDropFile?: (id: string, file: File) => void | PromiseLike<UploadedFile | void>;
|
|
228
228
|
/**
|
|
229
229
|
* Whether a file field offers a link input, the way in that needs no upload.
|
|
230
|
-
* `true` when absent; `false` hides the "
|
|
230
|
+
* `true` when absent; `false` hides the "Paste a link instead" toggle and the
|
|
231
231
|
* input behind it on every file field.
|
|
232
232
|
*
|
|
233
233
|
* It governs that input and nothing else. A file value is a URL whichever way
|
|
@@ -317,6 +317,46 @@ interface FieldRendererProps {
|
|
|
317
317
|
* Object and list fields recurse back through here, so the whole form is one
|
|
318
318
|
* data-driven tree with no per-type branching anywhere else.
|
|
319
319
|
*/
|
|
320
|
-
declare function FieldRenderer({ field, value, onChange, id, error, env }: FieldRendererProps):
|
|
320
|
+
declare function FieldRenderer({ field, value, onChange, id, error, env }: FieldRendererProps): react.JSX.Element;
|
|
321
321
|
|
|
322
|
-
|
|
322
|
+
/**
|
|
323
|
+
* How a field's LABEL chrome, and the enum values a person reads, should read.
|
|
324
|
+
* What a control stores never changes.
|
|
325
|
+
*
|
|
326
|
+
* - `studio` (default): the field's name verbatim in mono, with its concept
|
|
327
|
+
* pill. The name IS the identifier a builder writes in the `.mthds` file, so
|
|
328
|
+
* showing it exactly - and typed - is the point. An enum value is shown as its
|
|
329
|
+
* code for the same reason: it has to match the bundle and the JSON the
|
|
330
|
+
* builder reads next.
|
|
331
|
+
* - `app`: the field's name as a human question in sans, no concept pill. Inside
|
|
332
|
+
* a method app, `full_name` and `native.Text` are implementation detail; the
|
|
333
|
+
* person filling the form has never seen the method's source. An enum value
|
|
334
|
+
* follows the label and reads as words, worded by the kernel's rule
|
|
335
|
+
* (`enumValueLabeler` in the core entry).
|
|
336
|
+
*
|
|
337
|
+
* An enum value is the only value the two presentations show differently. A
|
|
338
|
+
* number, a text, a date and every other value render the same in both.
|
|
339
|
+
*
|
|
340
|
+
* The chrome around a value follows it too: in `app` the optional mark, a
|
|
341
|
+
* list's count and a file's formats are set in the page's face rather than in
|
|
342
|
+
* mono, an empty list is its Add button, and a description that restates its
|
|
343
|
+
* label is left out (`shownDescription`). See docs/architecture.md, "The
|
|
344
|
+
* chrome in `app`".
|
|
345
|
+
*
|
|
346
|
+
* Deliberately a context rather than a prop or a `FieldEnv` flag: only the
|
|
347
|
+
* components that own label chrome or an enum value's wording read it -
|
|
348
|
+
* `FieldShell`, `ObjectField`, `BooleanField`, `ListField`, `EnumField`, the
|
|
349
|
+
* result view and the generative layer's choice controls (`Select`, `Radio`,
|
|
350
|
+
* `Segmented`) - plus the controls whose own chrome follows it: the file
|
|
351
|
+
* control, whose card hides a storage reference in `app`, the date and number
|
|
352
|
+
* inputs, and a list's drop area. Threading a prop would have meant editing
|
|
353
|
+
* every field control and both recursive containers.
|
|
354
|
+
*/
|
|
355
|
+
type FieldPresentation = 'studio' | 'app';
|
|
356
|
+
declare function FieldPresentationProvider({ presentation, children, }: {
|
|
357
|
+
presentation: FieldPresentation;
|
|
358
|
+
children: ReactNode;
|
|
359
|
+
}): react.JSX.Element;
|
|
360
|
+
declare function useFieldPresentation(): FieldPresentation;
|
|
361
|
+
|
|
362
|
+
export { DocumentField as D, type FieldEnv as F, ImageField as I, type RowMove as R, type UploadedFile as U, type FieldPresentation as a, type FilePickerSource as b, FieldPresentationProvider as c, FieldRenderer as d, type FieldRendererProps as e, FilePicker as f, FilePickerEntry as g, type FilePickerEntryProps as h, type FilePickerProps as i, type FileValue as j, useFieldPresentation as u };
|
|
@@ -1547,7 +1547,12 @@ interface ResultBriefOptions {
|
|
|
1547
1547
|
}
|
|
1548
1548
|
/** The brief for an INPUT page: the form a run is started from. */
|
|
1549
1549
|
declare function inputBrief(subject: BriefSubject, fields: readonly RunField[], { frame, style, result }?: InputBriefOptions): DesignerBrief;
|
|
1550
|
-
/**
|
|
1550
|
+
/**
|
|
1551
|
+
* The brief for a RESULT page: what one run produced, laid out. With no run to
|
|
1552
|
+
* read, `state` is left `undefined` and the brief carries no sample: it is then
|
|
1553
|
+
* for the method's `layout_sample.design_from_written_sample` entry, which
|
|
1554
|
+
* writes one itself.
|
|
1555
|
+
*/
|
|
1551
1556
|
declare function resultBrief(subject: BriefSubject, field: RunField, state: unknown, { frame, style }?: ResultBriefOptions): DesignerBrief;
|
|
1552
1557
|
|
|
1553
1558
|
/**
|
|
@@ -1655,6 +1660,35 @@ declare function absoluteHatchPath(spec: Spec, key: string, path: string, parent
|
|
|
1655
1660
|
*/
|
|
1656
1661
|
declare function payloadToState(field: RunField, payload: unknown): unknown;
|
|
1657
1662
|
|
|
1663
|
+
/**
|
|
1664
|
+
* What a designer's written sample holds, read against the descriptor.
|
|
1665
|
+
*
|
|
1666
|
+
* When a result page is designed with no run to read, the method's second
|
|
1667
|
+
* entry (`layout_sample.design_from_written_sample`) has a model invent one
|
|
1668
|
+
* state of the result and designs from that. The text comes out of the run's
|
|
1669
|
+
* working memory under `written_sample`, and this is the check of it: what it
|
|
1670
|
+
* parses to, and everything it holds that the method's own description of its
|
|
1671
|
+
* result does not allow. Nothing here blocks a layout, which the two checks
|
|
1672
|
+
* judge on its own terms. A host reads the problems to decide whether the
|
|
1673
|
+
* sample is good enough to store beside the layout and to draw a page from.
|
|
1674
|
+
*/
|
|
1675
|
+
/** What a written sample parsed to and what is wrong with it; no problems means it may be used. */
|
|
1676
|
+
interface WrittenSample {
|
|
1677
|
+
/** The sample as parsed, whatever it holds; absent when the text is no JSON at all. */
|
|
1678
|
+
state: unknown;
|
|
1679
|
+
/** Every disagreement with the descriptor, one a line. */
|
|
1680
|
+
problems: string[];
|
|
1681
|
+
}
|
|
1682
|
+
/**
|
|
1683
|
+
* Parse a written sample, a code fence around it tolerated, and compare it
|
|
1684
|
+
* with the descriptor of the result: known members only, kinds that match
|
|
1685
|
+
* within the limits the method states, and what a sample must leave out
|
|
1686
|
+
* absent. It never throws, and it asks for no
|
|
1687
|
+
* member to be present: a sample that says less than the method can is still
|
|
1688
|
+
* one a page draws from.
|
|
1689
|
+
*/
|
|
1690
|
+
declare function writtenSampleOf(field: RunField, text: string): WrittenSample;
|
|
1691
|
+
|
|
1658
1692
|
/**
|
|
1659
1693
|
* A spec with its provenance - the shape every fixture takes, whoever produced
|
|
1660
1694
|
* it, so a story renders any of them without knowing which it holds.
|
|
@@ -1736,4 +1770,4 @@ declare function fixtureLabel(fixture: Provenance & Pick<SpecFixture, 'repairs'>
|
|
|
1736
1770
|
/** The fixture a story asks for, or a loud failure: a story must never render a page it did not name. */
|
|
1737
1771
|
declare function findFixture(fixtures: readonly SpecFixture[], pipeRef: string, id: string): SpecFixture;
|
|
1738
1772
|
|
|
1739
|
-
export { type BriefSubject, COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, type ComponentRendering, type CriticLoop, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, type DesignerAction, type DesignerBrief, type DesignerCatalog, type DesignerCatalogOptions, type DesignerComponent, type DesignerPathEntry, type DesignerStyle, FRAMES, FRAME_COMPONENTS, type Frame, type GenerativeSpec, ICON_NAMES, INPUTS_ROOT, type InputBriefOptions, type LayoutCheck, type LayoutDescriptor, type LayoutVerdict, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, type Producer, type ProductComponentName, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, type ResultBriefOptions, type SpecFixture, type SpecProblem, type SpecVerdict, type ValidationCatalog, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog };
|
|
1773
|
+
export { type BriefSubject, COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, type ComponentRendering, type CriticLoop, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, type DesignerAction, type DesignerBrief, type DesignerCatalog, type DesignerCatalogOptions, type DesignerComponent, type DesignerPathEntry, type DesignerStyle, FRAMES, FRAME_COMPONENTS, type Frame, type GenerativeSpec, ICON_NAMES, INPUTS_ROOT, type InputBriefOptions, type LayoutCheck, type LayoutDescriptor, type LayoutVerdict, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, type Producer, type ProductComponentName, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, type ResultBriefOptions, type SpecFixture, type SpecProblem, type SpecVerdict, type ValidationCatalog, type WrittenSample, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog, writtenSampleOf };
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
export { COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, FRAMES, FRAME_COMPONENTS, ICON_NAMES, INPUTS_ROOT, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog } from '../../chunk-
|
|
1
|
+
export { COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, FRAMES, FRAME_COMPONENTS, ICON_NAMES, INPUTS_ROOT, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog, writtenSampleOf } from '../../chunk-XLTYIIUY.js';
|
|
2
2
|
import '../../chunk-QQK6Y55E.js';
|
|
3
3
|
import '../../chunk-PNNWNRPG.js';
|
|
4
4
|
import '../../chunk-TF4RTKLH.js';
|
|
5
5
|
import '../../chunk-V3OV2XQT.js';
|
|
6
|
+
import '../../chunk-GKV77RAS.js';
|
|
6
7
|
//# sourceMappingURL=index.js.map
|
|
7
8
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
export { BriefSubject, COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, ComponentRendering, CriticLoop, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, DesignerAction, DesignerBrief, DesignerCatalog, DesignerCatalogOptions, DesignerComponent, DesignerPathEntry, DesignerStyle, FRAMES, FRAME_COMPONENTS, Frame, GenerativeSpec, ICON_NAMES, INPUTS_ROOT, InputBriefOptions, LayoutCheck, LayoutDescriptor, LayoutVerdict, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, Producer, ProductComponentName, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, ResultBriefOptions, SpecFixture, SpecProblem, SpecVerdict, ValidationCatalog, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog } from './headless/index.js';
|
|
1
|
+
export { BriefSubject, COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, ComponentRendering, CriticLoop, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, DesignerAction, DesignerBrief, DesignerCatalog, DesignerCatalogOptions, DesignerComponent, DesignerPathEntry, DesignerStyle, FRAMES, FRAME_COMPONENTS, Frame, GenerativeSpec, ICON_NAMES, INPUTS_ROOT, InputBriefOptions, LayoutCheck, LayoutDescriptor, LayoutVerdict, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, Producer, ProductComponentName, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, ResultBriefOptions, SpecFixture, SpecProblem, SpecVerdict, ValidationCatalog, WrittenSample, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog, writtenSampleOf } from './headless/index.js';
|
|
2
2
|
import * as _json_render_core from '@json-render/core';
|
|
3
3
|
import { Spec, StateStore, StateModel, ValidationConfig } from '@json-render/core';
|
|
4
4
|
export { Spec, StateModel, StateStore, createStateStore } from '@json-render/core';
|
|
5
|
-
import * as
|
|
5
|
+
import * as react from 'react';
|
|
6
6
|
import * as _json_render_react from '@json-render/react';
|
|
7
7
|
import { Components, Renderer, useFieldValidation } from '@json-render/react';
|
|
8
|
+
import { F as FieldEnv, a as FieldPresentation } from '../field-presentation-D5BkBSjX.js';
|
|
8
9
|
import { B as BrandManifest } from '../manifest-D3DLyNEv.js';
|
|
9
10
|
export { b as brandManifestSchema } from '../manifest-D3DLyNEv.js';
|
|
10
11
|
import * as zod_v4_core from 'zod/v4/core';
|
|
11
12
|
import * as zod from 'zod';
|
|
12
13
|
import { RunField } from '../core/descriptor.js';
|
|
13
|
-
import { F as FieldEnv } from '../field-renderer-BYN6YrU-.js';
|
|
14
14
|
export { seedInputs } from '../core/seed.js';
|
|
15
15
|
import '../styles-Bn8byNdo.js';
|
|
16
|
-
import '../core/contracts.js';
|
|
17
|
-
import 'mthds/protocol';
|
|
18
16
|
import '../core/file-formats.js';
|
|
19
17
|
import '../core/sources.js';
|
|
18
|
+
import '../core/contracts.js';
|
|
19
|
+
import 'mthds/protocol';
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* How a page tells its host that one of its elements failed to render.
|
|
@@ -98,8 +98,8 @@ interface DescriptorScope {
|
|
|
98
98
|
declare function useDescriptorScope(): DescriptorScope;
|
|
99
99
|
declare function DescriptorProvider({ scope, children, }: {
|
|
100
100
|
scope: DescriptorScope;
|
|
101
|
-
children:
|
|
102
|
-
}):
|
|
101
|
+
children: react.ReactNode;
|
|
102
|
+
}): react.JSX.Element;
|
|
103
103
|
/**
|
|
104
104
|
* Exported for the round-trip test only, not from the entry's index: the pair
|
|
105
105
|
* is only correct together, so a test that could see just one half of it would
|
|
@@ -736,7 +736,7 @@ declare const generativeRenderers: Components<_json_render_core.Catalog<{
|
|
|
736
736
|
}>>;
|
|
737
737
|
|
|
738
738
|
/** What a page renders through: this entry's registry unless a host brings its own. */
|
|
739
|
-
type PageRegistry =
|
|
739
|
+
type PageRegistry = react.ComponentProps<typeof Renderer>['registry'];
|
|
740
740
|
interface GenerativePageProps {
|
|
741
741
|
/** The layout to render; `null` while a stream has produced nothing yet. */
|
|
742
742
|
spec: Spec | null;
|
|
@@ -763,6 +763,14 @@ interface GenerativePageProps {
|
|
|
763
763
|
* brand components may omit it.
|
|
764
764
|
*/
|
|
765
765
|
brand?: BrandManifest;
|
|
766
|
+
/**
|
|
767
|
+
* How the kernel's own controls and results on the page read: `app` unless
|
|
768
|
+
* a host says otherwise. A produced page is a product page, its own fields
|
|
769
|
+
* already wear the app's labels, and the kernel's under the studio's mono
|
|
770
|
+
* names and concept pills read as a builder's form dropped into it. A host
|
|
771
|
+
* previewing a layout for a builder may pass `studio`.
|
|
772
|
+
*/
|
|
773
|
+
presentation?: FieldPresentation;
|
|
766
774
|
/**
|
|
767
775
|
* Called once for each element that throws while rendering, with the error
|
|
768
776
|
* and the element's component type. json-render drops such an element from
|
|
@@ -784,7 +792,7 @@ interface GenerativePageProps {
|
|
|
784
792
|
* kernel's readiness is computed from, and generation is nowhere in the
|
|
785
793
|
* request path: a layout is a data file, and this renders it.
|
|
786
794
|
*/
|
|
787
|
-
declare function GenerativePage({ spec, store, scope, onRun, loading, registry, brand, onElementError, }: GenerativePageProps):
|
|
795
|
+
declare function GenerativePage({ spec, store, scope, onRun, loading, registry, brand, presentation, onElementError, }: GenerativePageProps): react.JSX.Element;
|
|
788
796
|
/** The store's current state, re-rendering on every change. For a receipt beside a page. */
|
|
789
797
|
declare function useStoreSnapshot(store: StateStore): StateModel;
|
|
790
798
|
|
|
@@ -810,8 +818,8 @@ declare const generativeRegistry: _json_render_react.ComponentRegistry;
|
|
|
810
818
|
*/
|
|
811
819
|
declare function RevealPanel({ open, children }: {
|
|
812
820
|
open: () => void;
|
|
813
|
-
children:
|
|
814
|
-
}):
|
|
821
|
+
children: react.ReactNode;
|
|
822
|
+
}): react.JSX.Element;
|
|
815
823
|
/** What `useCheckedField` gives a control: json-render's field validation, and where the focus goes. */
|
|
816
824
|
type CheckedField = ReturnType<typeof useFieldValidation> & {
|
|
817
825
|
/**
|
|
@@ -851,21 +859,21 @@ declare function useCheckedField(path: string, config: ValidationConfig | undefi
|
|
|
851
859
|
*/
|
|
852
860
|
interface ResultSlot {
|
|
853
861
|
/** What to paint. Nothing is painted at all while this is absent or `null`. */
|
|
854
|
-
content:
|
|
862
|
+
content: react.ReactNode;
|
|
855
863
|
/** The heading above it. "Result" unless the host names it. */
|
|
856
864
|
title?: string;
|
|
857
865
|
}
|
|
858
866
|
declare function ResultSlotProvider({ slot, children, }: {
|
|
859
867
|
slot: ResultSlot | null;
|
|
860
|
-
children:
|
|
861
|
-
}):
|
|
868
|
+
children: react.ReactNode;
|
|
869
|
+
}): react.JSX.Element;
|
|
862
870
|
/** The slot the nearest page provides, or `null` on a page with no result yet. */
|
|
863
871
|
declare function useResultSlot(): ResultSlot | null;
|
|
864
872
|
|
|
865
873
|
declare function BrandProvider({ manifest, children, }: {
|
|
866
874
|
manifest: BrandManifest;
|
|
867
|
-
children:
|
|
868
|
-
}):
|
|
875
|
+
children: react.ReactNode;
|
|
876
|
+
}): react.JSX.Element;
|
|
869
877
|
declare function useBrand(): BrandManifest;
|
|
870
878
|
|
|
871
879
|
interface BrandBarProps {
|
|
@@ -876,7 +884,7 @@ interface BrandBarProps {
|
|
|
876
884
|
/** A short code at the end of the bar, such as the pipe's. */
|
|
877
885
|
tag?: string | null;
|
|
878
886
|
}
|
|
879
|
-
declare function BrandBar({ app, links, tag }: BrandBarProps):
|
|
887
|
+
declare function BrandBar({ app, links, tag }: BrandBarProps): react.JSX.Element;
|
|
880
888
|
|
|
881
889
|
/**
|
|
882
890
|
* What a host's compose-then-result frame tells the frame components of a
|
|
@@ -899,8 +907,8 @@ interface FrameHost {
|
|
|
899
907
|
}
|
|
900
908
|
declare function FrameHostProvider({ host, children, }: {
|
|
901
909
|
host: FrameHost;
|
|
902
|
-
children:
|
|
903
|
-
}):
|
|
910
|
+
children: react.ReactNode;
|
|
911
|
+
}): react.JSX.Element;
|
|
904
912
|
declare function useFrameHost(): FrameHost;
|
|
905
913
|
|
|
906
914
|
export { BrandBar, type BrandBarProps, BrandManifest, BrandProvider, type CheckedField, DescriptorProvider, type DescriptorScope, type ElementErrorHandler, type ElementErrorInfo, type FrameHost, FrameHostProvider, GenerativePage, type GenerativePageProps, type PageRegistry, type ResultSlot, ResultSlotProvider, RevealPanel, domIdFor, generativeRegistry, generativeRenderers, pathFromDomId, useBrand, useCheckedField, useDescriptorScope, useFrameHost, useResultSlot, useStoreSnapshot };
|
package/dist/generative/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { cn, headingClass, checkedAccentClass, focusOutlineClass, useResolveUrl, panelSurfaceClass, panelFlatShadowClass, linkTextClass, actionShadowClass, panelRaisedShadowClass, fieldControlClass, useFieldPresentation, useFieldStrings, fieldLabel, ResultRoot, ResultField, FieldRenderer, enumLabeler, ToggleGroup, ToggleGroupItem, selectedFillStrongClass, Switch, Select, SelectTrigger, SelectValue, SelectContent, SelectItem, selectedBorderClass, selectedFillClass, isThenable } from '../chunk-
|
|
3
|
-
import { baseCatalog, catalog, frameComponents, shareAmount, INPUTS_ROOT, joinPath, resultFieldAtPath, segmentsUnder, RESULT_ROOT, inputFieldAtPath, definitionChain, unwrapped } from '../chunk-
|
|
4
|
-
export { COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, FRAMES, FRAME_COMPONENTS, ICON_NAMES, INPUTS_ROOT, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog } from '../chunk-
|
|
2
|
+
import { cn, headingClass, checkedAccentClass, focusOutlineClass, useResolveUrl, panelSurfaceClass, panelFlatShadowClass, linkTextClass, actionShadowClass, panelRaisedShadowClass, fieldControlClass, useFieldPresentation, useFieldStrings, fieldLabel, ResultRoot, ResultField, FieldRenderer, enumLabeler, ToggleGroup, ToggleGroupItem, selectedFillStrongClass, Switch, Select, SelectTrigger, SelectValue, SelectContent, SelectItem, selectedBorderClass, selectedFillClass, isThenable, FieldPresentationProvider } from '../chunk-TD62R3P6.js';
|
|
3
|
+
import { baseCatalog, catalog, frameComponents, shareAmount, INPUTS_ROOT, joinPath, resultFieldAtPath, segmentsUnder, RESULT_ROOT, inputFieldAtPath, definitionChain, unwrapped } from '../chunk-XLTYIIUY.js';
|
|
4
|
+
export { COMPONENT_NAMES, COMPONENT_RENDERINGS, COMPOSER_COMPONENTS, CUSTOM_COMPONENTS, DESIGNER_BRIEF_CONCEPT, DESIGNER_CATALOG_CONCEPT, FRAMES, FRAME_COMPONENTS, ICON_NAMES, INPUTS_ROOT, METRIC_FORMATS, PICKED_SHADCN, PRODUCT_COMPONENTS, PROMPT_HASH, REPAIR_ATTEMPTS, RESULT_COMPONENTS, RESULT_ROOT, absoluteHatchPath, catalog, componentNamesFor, designerCatalog, fieldAtSegments, findFixture, fixtureId, fixtureLabel, formatProblems, frameCatalog, inputBrief, inputFieldAtPath, isDelegatedInput, isDelegatedResult, joinPath, jsonlLines, layoutCheck, layoutCheckProblems, layoutFits, layoutProblems, payloadToState, promptHashSubject, repeatBasePathOf, resultBrief, resultFieldAtPath, seedLine, segmentsUnder, specFromJsonl, specToJsonl, validateAgainstCatalog, writtenSampleOf } from '../chunk-XLTYIIUY.js';
|
|
5
5
|
import '../chunk-4VAO6BDE.js';
|
|
6
6
|
export { seedInputs } from '../chunk-AURDKAIC.js';
|
|
7
7
|
import '../chunk-L23R3JNQ.js';
|
|
@@ -929,11 +929,11 @@ function Stack({
|
|
|
929
929
|
}
|
|
930
930
|
var COLUMNS = {
|
|
931
931
|
1: "grid-cols-1",
|
|
932
|
-
2: "
|
|
933
|
-
3: "
|
|
934
|
-
4: "
|
|
935
|
-
5: "
|
|
936
|
-
6: "
|
|
932
|
+
2: "@lg:grid-cols-2",
|
|
933
|
+
3: "@lg:grid-cols-2 @5xl:grid-cols-3",
|
|
934
|
+
4: "@lg:grid-cols-2 @5xl:grid-cols-4",
|
|
935
|
+
5: "@lg:grid-cols-2 @5xl:grid-cols-5",
|
|
936
|
+
6: "@lg:grid-cols-2 @5xl:grid-cols-6"
|
|
937
937
|
};
|
|
938
938
|
function Grid({
|
|
939
939
|
props,
|
|
@@ -1172,7 +1172,7 @@ function Textarea({
|
|
|
1172
1172
|
] });
|
|
1173
1173
|
}
|
|
1174
1174
|
var NATIVE_CHECK = cn("size-4 shrink-0", checkedAccentClass, focusOutlineClass);
|
|
1175
|
-
var NATIVE_CHECK_ROW = "flex items-center gap-2 text-sm max-
|
|
1175
|
+
var NATIVE_CHECK_ROW = "flex items-center gap-2 text-sm @max-lg:min-h-11";
|
|
1176
1176
|
function Radio({
|
|
1177
1177
|
props,
|
|
1178
1178
|
bindings,
|
|
@@ -1189,7 +1189,7 @@ function Radio({
|
|
|
1189
1189
|
"aria-describedby": field.describedBy,
|
|
1190
1190
|
children: [
|
|
1191
1191
|
/* @__PURE__ */ jsx("legend", { className: LABEL, children: props.label }),
|
|
1192
|
-
/* @__PURE__ */ jsx("div", { className: "space-y-2 max-
|
|
1192
|
+
/* @__PURE__ */ jsx("div", { className: "space-y-2 @max-lg:space-y-0", children: (props.options ?? []).map((option, index, options) => /* @__PURE__ */ jsxs("label", { className: NATIVE_CHECK_ROW, children: [
|
|
1193
1193
|
/* @__PURE__ */ jsx(
|
|
1194
1194
|
"input",
|
|
1195
1195
|
{
|
|
@@ -1253,7 +1253,7 @@ function Switch2({
|
|
|
1253
1253
|
const id = useControlId(props.name);
|
|
1254
1254
|
const field = useBoundField(props.checked, bindings?.checked, false, props, id);
|
|
1255
1255
|
return /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
|
|
1256
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 max-
|
|
1256
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 @max-lg:py-2.5", children: [
|
|
1257
1257
|
/* @__PURE__ */ jsx(
|
|
1258
1258
|
Switch,
|
|
1259
1259
|
{
|
|
@@ -1498,9 +1498,9 @@ function Metric({ props }) {
|
|
|
1498
1498
|
] });
|
|
1499
1499
|
}
|
|
1500
1500
|
var SPLIT_COLUMNS = {
|
|
1501
|
-
"1:1": "
|
|
1502
|
-
"1:2": "
|
|
1503
|
-
"2:1": "
|
|
1501
|
+
"1:1": "@lg:grid-cols-[minmax(0,1fr)_minmax(0,1fr)]",
|
|
1502
|
+
"1:2": "@lg:grid-cols-[minmax(0,1fr)_minmax(0,2fr)]",
|
|
1503
|
+
"2:1": "@lg:grid-cols-[minmax(0,2fr)_minmax(0,1fr)]"
|
|
1504
1504
|
};
|
|
1505
1505
|
var SPLIT_GAP = { md: "gap-4", lg: "gap-6", xl: "gap-8" };
|
|
1506
1506
|
function Split({
|
|
@@ -1533,11 +1533,11 @@ function Tabs({ props, children }) {
|
|
|
1533
1533
|
setChosen({ value: tab.value, occurrence });
|
|
1534
1534
|
};
|
|
1535
1535
|
return /* @__PURE__ */ jsxs(TabsPrimitive.Root, { value, onValueChange: choose, className: "w-full", children: [
|
|
1536
|
-
/* @__PURE__ */ jsx(TabsPrimitive.List, { className: "inline-flex h-10 items-center justify-start rounded-md bg-muted p-1 text-muted-foreground max-
|
|
1536
|
+
/* @__PURE__ */ jsx(TabsPrimitive.List, { className: "inline-flex h-10 items-center justify-start rounded-md bg-muted p-1 text-muted-foreground @max-lg:h-auto @max-lg:flex-wrap", children: tabs.map((tab, index) => /* @__PURE__ */ jsx(
|
|
1537
1537
|
TabsPrimitive.Trigger,
|
|
1538
1538
|
{
|
|
1539
1539
|
value: String(index),
|
|
1540
|
-
className: "inline-flex items-center justify-center rounded-sm px-3 py-1.5 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-hidden data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm max-
|
|
1540
|
+
className: "inline-flex items-center justify-center rounded-sm px-3 py-1.5 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-hidden data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm @max-lg:min-h-11 @max-lg:min-w-11",
|
|
1541
1541
|
children: tab.label
|
|
1542
1542
|
},
|
|
1543
1543
|
index
|
|
@@ -1732,7 +1732,7 @@ function Segmented({ props, bindings, emit }) {
|
|
|
1732
1732
|
value: option,
|
|
1733
1733
|
variant: "outline",
|
|
1734
1734
|
size: "sm",
|
|
1735
|
-
className: "rounded-full px-3.5 data-[state=on]:border-primary data-[state=on]:bg-primary data-[state=on]:text-primary-foreground max-
|
|
1735
|
+
className: "rounded-full px-3.5 data-[state=on]:border-primary data-[state=on]:bg-primary data-[state=on]:text-primary-foreground @max-lg:h-11 @max-lg:min-w-11",
|
|
1736
1736
|
children: labelOf(option)
|
|
1737
1737
|
},
|
|
1738
1738
|
`${index}-${option}`
|
|
@@ -1888,7 +1888,7 @@ function Composer({ props, children, emit }) {
|
|
|
1888
1888
|
"h1",
|
|
1889
1889
|
{
|
|
1890
1890
|
className: cn(
|
|
1891
|
-
"text-[32px] leading-[1.1] text-balance text-foreground
|
|
1891
|
+
"text-[32px] leading-[1.1] text-balance text-foreground @lg:text-[38px] @lg:leading-[1.08]",
|
|
1892
1892
|
headingClass(700, true)
|
|
1893
1893
|
),
|
|
1894
1894
|
children: props.headline
|
|
@@ -1900,20 +1900,20 @@ function Composer({ props, children, emit }) {
|
|
|
1900
1900
|
"div",
|
|
1901
1901
|
{
|
|
1902
1902
|
"data-style-panel": "",
|
|
1903
|
-
className: cn(RADIUS, panelSurfaceClass, panelFlatShadowClass, "p-7 max-
|
|
1903
|
+
className: cn(RADIUS, panelSurfaceClass, panelFlatShadowClass, "p-7 @max-lg:p-5"),
|
|
1904
1904
|
children: [
|
|
1905
1905
|
/* @__PURE__ */ jsx(
|
|
1906
1906
|
"div",
|
|
1907
1907
|
{
|
|
1908
1908
|
className: cn(
|
|
1909
1909
|
"grid gap-8",
|
|
1910
|
-
two && "
|
|
1910
|
+
two && "@lg:block @lg:columns-2 @lg:gap-x-10 @lg:[&>*+*]:mt-8 @lg:[&>*>h2]:break-after-avoid @lg:[&>*>*:not(h2)]:break-inside-avoid"
|
|
1911
1911
|
),
|
|
1912
1912
|
children
|
|
1913
1913
|
}
|
|
1914
1914
|
),
|
|
1915
|
-
/* @__PURE__ */ jsxs("div", { className: "sticky bottom-0 z-[2] -mx-7 -mb-7 mt-7 flex items-center justify-between gap-4 rounded-b-[calc(var(--radius,0.5rem)*1.5)] border-t border-border [background-color:var(--panel-fill,var(--card,hsl(0_0%_100%)))] px-7 pt-[18px] pb-7 max-
|
|
1916
|
-
/* @__PURE__ */ jsxs("div", { className: "flex min-w-0 flex-col gap-1 text-sm text-muted-foreground max-
|
|
1915
|
+
/* @__PURE__ */ jsxs("div", { className: "sticky bottom-0 z-[2] -mx-7 -mb-7 mt-7 flex items-center justify-between gap-4 rounded-b-[calc(var(--radius,0.5rem)*1.5)] border-t border-border [background-color:var(--panel-fill,var(--card,hsl(0_0%_100%)))] px-7 pt-[18px] pb-7 @max-lg:-mx-5 @max-lg:-mb-5 @max-lg:flex-col-reverse @max-lg:items-stretch @max-lg:px-5 @max-lg:pb-5", children: [
|
|
1916
|
+
/* @__PURE__ */ jsxs("div", { className: "flex min-w-0 flex-col gap-1 text-sm text-muted-foreground @max-lg:items-center @max-lg:text-center", children: [
|
|
1917
1917
|
waitsFor ? /* @__PURE__ */ jsx("p", { id: waitsForId, children: waitsFor }) : null,
|
|
1918
1918
|
host.eta ? /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-2", children: [
|
|
1919
1919
|
/* @__PURE__ */ jsx(Clock, { className: "size-4", "aria-hidden": "true" }),
|
|
@@ -1945,7 +1945,7 @@ function Composer({ props, children, emit }) {
|
|
|
1945
1945
|
]
|
|
1946
1946
|
}
|
|
1947
1947
|
),
|
|
1948
|
-
props.notes && props.notes.length > 0 ? /* @__PURE__ */ jsx("ul", { className: "grid gap-x-8 gap-y-2.5 px-1
|
|
1948
|
+
props.notes && props.notes.length > 0 ? /* @__PURE__ */ jsx("ul", { className: "grid gap-x-8 gap-y-2.5 px-1 @lg:grid-cols-2", children: props.notes.map((note, index) => /* @__PURE__ */ jsxs("li", { className: "flex items-start gap-2.5 text-sm text-muted-foreground", children: [
|
|
1949
1949
|
/* @__PURE__ */ jsx("span", { "aria-hidden": "true", className: linkTextClass, children: "\u2713" }),
|
|
1950
1950
|
/* @__PURE__ */ jsx("span", { className: "min-w-0", children: note })
|
|
1951
1951
|
] }, index)) }) : null
|
|
@@ -1961,14 +1961,14 @@ function FieldGroup({ props, children }) {
|
|
|
1961
1961
|
}
|
|
1962
1962
|
function ResultHeader({ props }) {
|
|
1963
1963
|
const host = useFrameHost();
|
|
1964
|
-
return /* @__PURE__ */ jsxs("div", { className: "flex items-start justify-between gap-6 max-
|
|
1964
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex items-start justify-between gap-6 @max-lg:flex-col", children: [
|
|
1965
1965
|
/* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
|
|
1966
1966
|
props.eyebrow ? /* @__PURE__ */ jsx("p", { className: cn("mb-1.5 text-[13px] font-semibold", linkTextClass), children: props.eyebrow }) : null,
|
|
1967
1967
|
/* @__PURE__ */ jsx(
|
|
1968
1968
|
"h1",
|
|
1969
1969
|
{
|
|
1970
1970
|
className: cn(
|
|
1971
|
-
"text-[28px] leading-[1.12] text-balance text-foreground
|
|
1971
|
+
"text-[28px] leading-[1.12] text-balance text-foreground @lg:text-[32px]",
|
|
1972
1972
|
headingClass(700, true)
|
|
1973
1973
|
),
|
|
1974
1974
|
children: props.title
|
|
@@ -1982,7 +1982,7 @@ function ResultHeader({ props }) {
|
|
|
1982
1982
|
type: "button",
|
|
1983
1983
|
onClick: () => host.onAction?.(label),
|
|
1984
1984
|
className: cn(
|
|
1985
|
-
"inline-flex min-h-11 items-center rounded-[var(--radius,0.5rem)] px-4 text-sm font-semibold
|
|
1985
|
+
"inline-flex min-h-11 items-center rounded-[var(--radius,0.5rem)] px-4 text-sm font-semibold @lg:min-h-9",
|
|
1986
1986
|
focusOutlineClass,
|
|
1987
1987
|
i === 0 ? "bg-primary text-primary-foreground" : "border border-border bg-background text-foreground"
|
|
1988
1988
|
),
|
|
@@ -2459,6 +2459,7 @@ function GenerativePage({
|
|
|
2459
2459
|
loading,
|
|
2460
2460
|
registry = generativeRegistry,
|
|
2461
2461
|
brand,
|
|
2462
|
+
presentation = "app",
|
|
2462
2463
|
onElementError
|
|
2463
2464
|
}) {
|
|
2464
2465
|
const { inputs, result, env, idPrefix } = scope;
|
|
@@ -2513,7 +2514,7 @@ function GenerativePage({
|
|
|
2513
2514
|
}
|
|
2514
2515
|
};
|
|
2515
2516
|
});
|
|
2516
|
-
const page = /* @__PURE__ */ jsx(DescriptorProvider, { scope: stableScope, children: /* @__PURE__ */ jsx(PlacedInputsProvider, { spec, children: /* @__PURE__ */ jsx(
|
|
2517
|
+
const page = /* @__PURE__ */ jsx(FieldPresentationProvider, { presentation, children: /* @__PURE__ */ jsx(DescriptorProvider, { scope: stableScope, children: /* @__PURE__ */ jsx(PlacedInputsProvider, { spec, children: /* @__PURE__ */ jsx(
|
|
2517
2518
|
JSONUIProvider,
|
|
2518
2519
|
{
|
|
2519
2520
|
registry: pageRegistry,
|
|
@@ -2522,7 +2523,7 @@ function GenerativePage({
|
|
|
2522
2523
|
validationFunctions: CHECKED_FIELD_FUNCTIONS,
|
|
2523
2524
|
children: /* @__PURE__ */ jsx(ReportingContext.Provider, { value: reporting, children: /* @__PURE__ */ jsxs(CheckedFieldsContext.Provider, { value: checkedFields, children: [
|
|
2524
2525
|
/* @__PURE__ */ jsx(ValidationBridge, { into: validation, fields: checkedFields }),
|
|
2525
|
-
/* @__PURE__ */ jsx(
|
|
2526
|
+
/* @__PURE__ */ jsx("div", { className: "@container w-full", children: /* @__PURE__ */ jsx(
|
|
2526
2527
|
RootBoundary,
|
|
2527
2528
|
{
|
|
2528
2529
|
type: rootType,
|
|
@@ -2532,10 +2533,10 @@ function GenerativePage({
|
|
|
2532
2533
|
spec,
|
|
2533
2534
|
children: /* @__PURE__ */ jsx(Renderer, { spec, registry: pageRegistry, loading })
|
|
2534
2535
|
}
|
|
2535
|
-
)
|
|
2536
|
+
) })
|
|
2536
2537
|
] }) })
|
|
2537
2538
|
}
|
|
2538
|
-
) }) });
|
|
2539
|
+
) }) }) });
|
|
2539
2540
|
return brand ? /* @__PURE__ */ jsx(BrandProvider, { manifest: brand, children: page }) : page;
|
|
2540
2541
|
}
|
|
2541
2542
|
function ValidationBridge({
|