@webstudio-is/react-sdk 0.50.0 → 0.52.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/app/custom-components/image.js +2 -4
- package/lib/app/custom-components/shared/remix-link.js +7 -23
- package/lib/cjs/app/custom-components/{image.cjs → image.js} +1 -3
- package/lib/cjs/app/custom-components/shared/{remix-link.cjs → remix-link.js} +6 -22
- package/lib/cjs/components/__generated__/{link.props.cjs → link.props.js} +6 -6
- package/lib/cjs/components/{blockquote.cjs → blockquote.js} +2 -1
- package/lib/cjs/components/{blockquote.ws.cjs → blockquote.ws.js} +57 -35
- package/lib/cjs/components/{body.cjs → body.js} +2 -1
- package/lib/cjs/components/{body.ws.cjs → body.ws.js} +30 -46
- package/lib/cjs/components/{bold.cjs → bold.js} +2 -1
- package/lib/cjs/components/{bold.ws.cjs → bold.ws.js} +6 -1
- package/lib/cjs/components/{box.ws.cjs → box.ws.js} +11 -4
- package/lib/cjs/components/{button.cjs → button.js} +2 -1
- package/lib/cjs/components/{button.ws.cjs → button.ws.js} +6 -1
- package/lib/cjs/components/{code.cjs → code.js} +1 -0
- package/lib/cjs/components/{code.ws.cjs → code.ws.js} +31 -25
- package/lib/cjs/components/{form.cjs → form.js} +2 -1
- package/lib/cjs/components/{form.ws.cjs → form.ws.js} +8 -8
- package/lib/cjs/components/{heading.ws.cjs → heading.ws.js} +11 -1
- package/lib/cjs/components/{image.cjs → image.js} +2 -1
- package/lib/cjs/components/{image.ws.cjs → image.ws.js} +15 -11
- package/lib/cjs/components/{input.cjs → input.js} +2 -1
- package/lib/cjs/components/{input.ws.cjs → input.ws.js} +6 -1
- package/lib/cjs/components/{italic.cjs → italic.js} +2 -1
- package/lib/cjs/components/{italic.ws.cjs → italic.ws.js} +8 -4
- package/lib/cjs/components/{link-block.cjs → link-block.js} +3 -1
- package/lib/cjs/components/{link-block.ws.cjs → link-block.ws.js} +13 -9
- package/lib/cjs/components/{link.cjs → link.js} +15 -6
- package/lib/cjs/components/{link.ws.cjs → link.ws.js} +21 -10
- package/lib/cjs/components/{list-item.cjs → list-item.js} +2 -1
- package/lib/cjs/components/{list-item.ws.cjs → list-item.ws.js} +6 -1
- package/lib/cjs/components/{list.ws.cjs → list.ws.js} +29 -10
- package/lib/cjs/components/{paragraph.cjs → paragraph.js} +2 -1
- package/lib/cjs/components/{paragraph.ws.cjs → paragraph.ws.js} +6 -1
- package/lib/cjs/components/{rich-text-link.ws.cjs → rich-text-link.ws.js} +5 -2
- package/lib/cjs/components/{separator.cjs → separator.js} +2 -1
- package/lib/cjs/components/{separator.ws.cjs → separator.ws.js} +27 -11
- package/lib/cjs/components/{span.cjs → span.js} +2 -1
- package/lib/cjs/components/{span.ws.cjs → span.ws.js} +6 -1
- package/lib/cjs/components/{subscript.cjs → subscript.js} +2 -1
- package/lib/cjs/components/{subscript.ws.cjs → subscript.ws.js} +6 -1
- package/lib/cjs/components/{superscript.cjs → superscript.js} +2 -1
- package/lib/cjs/components/{superscript.ws.cjs → superscript.ws.js} +6 -1
- package/lib/cjs/components/{text-block.cjs → text-block.js} +2 -1
- package/lib/cjs/components/{text-block.ws.cjs → text-block.ws.js} +9 -5
- package/lib/cjs/{context.cjs → context.js} +2 -1
- package/lib/cjs/css/css.js +64 -0
- package/lib/cjs/css/global-rules.js +37 -0
- package/lib/cjs/css/{index.cjs → index.js} +3 -1
- package/lib/cjs/css/normalize-type-check.js +26 -0
- package/lib/cjs/css/normalize.js +358 -0
- package/lib/cjs/css/presets.js +61 -0
- package/lib/cjs/css/style-rules.js +62 -0
- package/lib/cjs/package.json +1 -0
- package/lib/cjs/{props.cjs → props.js} +43 -2
- package/lib/cjs/pubsub/{create.cjs → create.js} +6 -35
- package/lib/cjs/pubsub/raf-queue.js +45 -0
- package/lib/cjs/tree/{create-elements-tree.cjs → create-elements-tree.js} +8 -1
- package/lib/cjs/tree/{root.cjs → root.js} +1 -0
- package/lib/cjs/tree/{webstudio-component.cjs → webstudio-component.js} +1 -0
- package/lib/components/__generated__/link-block.props.js +5 -5
- package/lib/components/__generated__/link.props.js +6 -6
- package/lib/components/__generated__/rich-text-link.props.js +5 -5
- package/lib/components/blockquote.js +2 -1
- package/lib/components/blockquote.ws.js +57 -35
- package/lib/components/body.js +2 -1
- package/lib/components/body.ws.js +30 -46
- package/lib/components/bold.js +2 -1
- package/lib/components/bold.ws.js +7 -2
- package/lib/components/box.ws.js +22 -4
- package/lib/components/button.js +2 -1
- package/lib/components/button.ws.js +7 -2
- package/lib/components/code.js +1 -0
- package/lib/components/code.ws.js +31 -25
- package/lib/components/form.js +2 -1
- package/lib/components/form.ws.js +8 -8
- package/lib/components/heading.ws.js +11 -1
- package/lib/components/image.js +2 -1
- package/lib/components/image.ws.js +15 -11
- package/lib/components/input.js +2 -1
- package/lib/components/input.ws.js +7 -2
- package/lib/components/italic.js +2 -1
- package/lib/components/italic.ws.js +9 -5
- package/lib/components/link-block.js +3 -1
- package/lib/components/link-block.ws.js +13 -9
- package/lib/components/link.js +15 -6
- package/lib/components/link.ws.js +22 -11
- package/lib/components/list-item.js +2 -1
- package/lib/components/list-item.ws.js +6 -1
- package/lib/components/list.ws.js +29 -10
- package/lib/components/paragraph.js +2 -1
- package/lib/components/paragraph.ws.js +6 -1
- package/lib/components/rich-text-link.ws.js +6 -3
- package/lib/components/separator.js +2 -1
- package/lib/components/separator.ws.js +27 -11
- package/lib/components/span.js +2 -1
- package/lib/components/span.ws.js +7 -2
- package/lib/components/subscript.js +2 -1
- package/lib/components/subscript.ws.js +6 -1
- package/lib/components/superscript.js +2 -1
- package/lib/components/superscript.ws.js +6 -1
- package/lib/components/text-block.js +2 -1
- package/lib/components/text-block.ws.js +10 -6
- package/lib/context.js +2 -1
- package/lib/css/css.js +44 -0
- package/lib/css/get-browser-style.js +3 -1
- package/lib/css/global-rules.js +20 -0
- package/lib/css/index.js +3 -1
- package/lib/css/normalize-type-check.js +3 -0
- package/lib/css/normalize.js +338 -0
- package/lib/css/presets.js +41 -0
- package/lib/css/style-rules.js +42 -0
- package/lib/props.js +43 -2
- package/lib/pubsub/create.js +6 -25
- package/lib/pubsub/raf-queue.js +25 -0
- package/lib/tree/create-elements-tree.js +8 -1
- package/lib/tree/root.js +1 -0
- package/lib/tree/webstudio-component.js +1 -0
- package/lib/types/app/custom-components/image.d.ts +6 -0
- package/lib/types/app/custom-components/index.d.ts +26 -0
- package/lib/types/app/custom-components/link-block.d.ts +6 -0
- package/lib/types/app/custom-components/link.d.ts +6 -0
- package/lib/types/app/custom-components/rich-text-link.d.ts +6 -0
- package/lib/types/app/custom-components/shared/remix-link.d.ts +10 -0
- package/lib/types/app/handle-request.server.d.ts +2 -0
- package/lib/types/app/index.d.ts +3 -0
- package/lib/types/app/params.d.ts +5 -0
- package/lib/types/app/root.d.ts +8 -0
- package/lib/types/components/__generated__/blockquote.props.d.ts +2 -0
- package/lib/types/components/__generated__/body.props.d.ts +2 -0
- package/lib/types/components/__generated__/bold.props.d.ts +2 -0
- package/lib/types/components/__generated__/box.props.d.ts +2 -0
- package/lib/types/components/__generated__/button.props.d.ts +2 -0
- package/lib/types/components/__generated__/code.props.d.ts +2 -0
- package/lib/types/components/__generated__/form.props.d.ts +2 -0
- package/lib/types/components/__generated__/fragment.props.d.ts +2 -0
- package/lib/types/components/__generated__/heading.props.d.ts +2 -0
- package/lib/types/components/__generated__/image.props.d.ts +2 -0
- package/lib/types/components/__generated__/input.props.d.ts +2 -0
- package/lib/types/components/__generated__/italic.props.d.ts +2 -0
- package/lib/types/components/__generated__/link-block.props.d.ts +2 -0
- package/lib/types/components/__generated__/link.props.d.ts +2 -0
- package/lib/types/components/__generated__/list-item.props.d.ts +2 -0
- package/lib/types/components/__generated__/list.props.d.ts +2 -0
- package/lib/types/components/__generated__/paragraph.props.d.ts +2 -0
- package/lib/types/components/__generated__/rich-text-link.props.d.ts +2 -0
- package/lib/types/components/__generated__/separator.props.d.ts +2 -0
- package/lib/types/components/__generated__/slot.props.d.ts +2 -0
- package/lib/types/components/__generated__/span.props.d.ts +2 -0
- package/lib/types/components/__generated__/subscript.props.d.ts +2 -0
- package/lib/types/components/__generated__/superscript.props.d.ts +2 -0
- package/lib/types/components/__generated__/text-block.props.d.ts +2 -0
- package/lib/types/components/blockquote.d.ts +3 -0
- package/lib/types/components/blockquote.stories.d.ts +5 -0
- package/lib/types/components/blockquote.ws.d.ts +3 -0
- package/lib/types/components/body.d.ts +3 -0
- package/lib/types/components/body.stories.d.ts +6 -0
- package/lib/types/components/body.ws.d.ts +3 -0
- package/lib/types/components/bold.d.ts +3 -0
- package/lib/types/components/bold.stories.d.ts +5 -0
- package/lib/types/components/bold.ws.d.ts +3 -0
- package/lib/types/components/box.d.ts +7 -0
- package/lib/types/components/box.stories.d.ts +9 -0
- package/lib/types/components/box.ws.d.ts +3 -0
- package/lib/types/components/button.d.ts +7 -0
- package/lib/types/components/button.stories.d.ts +9 -0
- package/lib/types/components/button.ws.d.ts +3 -0
- package/lib/types/components/code.d.ts +9 -0
- package/lib/types/components/code.stories.d.ts +11 -0
- package/lib/types/components/code.ws.d.ts +3 -0
- package/lib/types/components/component-meta.d.ts +605 -0
- package/lib/types/components/components-utils.d.ts +34 -0
- package/lib/types/components/components.d.ts +31 -0
- package/lib/types/components/form.d.ts +3 -0
- package/lib/types/components/form.stories.d.ts +5 -0
- package/lib/types/components/form.ws.d.ts +3 -0
- package/lib/types/components/fragment.d.ts +6 -0
- package/lib/types/components/fragment.ws.d.ts +3 -0
- package/lib/types/components/heading.d.ts +7 -0
- package/lib/types/components/heading.stories.d.ts +9 -0
- package/lib/types/components/heading.ws.d.ts +3 -0
- package/lib/types/components/image.d.ts +3 -0
- package/lib/types/components/image.stories.d.ts +5 -0
- package/lib/types/components/image.ws.d.ts +3 -0
- package/lib/types/components/index.d.ts +17 -0
- package/lib/types/components/input.d.ts +3 -0
- package/lib/types/components/input.stories.d.ts +5 -0
- package/lib/types/components/input.ws.d.ts +3 -0
- package/lib/types/components/italic.d.ts +3 -0
- package/lib/types/components/italic.stories.d.ts +5 -0
- package/lib/types/components/italic.ws.d.ts +3 -0
- package/lib/types/components/link-block.d.ts +3 -0
- package/lib/types/components/link-block.stories.d.ts +13 -0
- package/lib/types/components/link-block.ws.d.ts +3 -0
- package/lib/types/components/link.d.ts +9 -0
- package/lib/types/components/link.stories.d.ts +13 -0
- package/lib/types/components/link.ws.d.ts +3 -0
- package/lib/types/components/list-item.d.ts +3 -0
- package/lib/types/components/list-item.stories.d.ts +5 -0
- package/lib/types/components/list-item.ws.d.ts +3 -0
- package/lib/types/components/list.d.ts +9 -0
- package/lib/types/components/list.stories.d.ts +9 -0
- package/lib/types/components/list.ws.d.ts +3 -0
- package/lib/types/components/paragraph.d.ts +3 -0
- package/lib/types/components/paragraph.stories.d.ts +5 -0
- package/lib/types/components/paragraph.ws.d.ts +3 -0
- package/lib/types/components/rich-text-link.d.ts +2 -0
- package/lib/types/components/rich-text-link.stories.d.ts +13 -0
- package/lib/types/components/rich-text-link.ws.d.ts +3 -0
- package/lib/types/components/separator.d.ts +3 -0
- package/lib/types/components/separator.stories.d.ts +5 -0
- package/lib/types/components/separator.ws.d.ts +3 -0
- package/lib/types/components/slot.d.ts +6 -0
- package/lib/types/components/slot.stories.d.ts +9 -0
- package/lib/types/components/slot.ws.d.ts +3 -0
- package/lib/types/components/span.d.ts +3 -0
- package/lib/types/components/span.stories.d.ts +5 -0
- package/lib/types/components/span.ws.d.ts +3 -0
- package/lib/types/components/subscript.d.ts +3 -0
- package/lib/types/components/subscript.stories.d.ts +5 -0
- package/lib/types/components/subscript.ws.d.ts +3 -0
- package/lib/types/components/superscript.d.ts +3 -0
- package/lib/types/components/superscript.stories.d.ts +5 -0
- package/lib/types/components/superscript.ws.d.ts +3 -0
- package/lib/types/components/text-block.d.ts +3 -0
- package/lib/types/components/text-block.stories.d.ts +5 -0
- package/lib/types/components/text-block.ws.d.ts +3 -0
- package/lib/types/context.d.ts +9 -0
- package/lib/types/css/css.d.ts +10 -0
- package/lib/types/css/get-browser-style.d.ts +2 -0
- package/lib/types/css/global-rules.d.ts +44 -0
- package/lib/types/css/index.d.ts +4 -0
- package/lib/types/css/normalize-type-check.d.ts +1 -0
- package/lib/types/css/normalize.d.ts +2429 -0
- package/lib/types/css/presets.d.ts +38 -0
- package/lib/types/css/style-rules.d.ts +248 -0
- package/lib/types/css/style-rules.test.d.ts +1 -0
- package/lib/types/index.d.ts +9 -0
- package/lib/types/props.d.ts +97 -0
- package/lib/types/props.test.d.ts +1 -0
- package/lib/types/pubsub/create.d.ts +28 -0
- package/lib/types/pubsub/index.d.ts +1 -0
- package/lib/types/pubsub/raf-queue.d.ts +1 -0
- package/lib/types/tree/create-elements-tree.d.ts +16 -0
- package/lib/types/tree/index.d.ts +3 -0
- package/lib/types/tree/root.d.ts +25 -0
- package/lib/types/tree/session-storage-polyfill.d.ts +2 -0
- package/lib/types/tree/webstudio-component.d.ts +15 -0
- package/package.json +20 -19
- package/src/app/custom-components/image.tsx +4 -7
- package/src/app/custom-components/shared/remix-link.tsx +12 -48
- package/src/components/__generated__/link-block.props.ts +5 -5
- package/src/components/__generated__/link.props.ts +6 -6
- package/src/components/__generated__/rich-text-link.props.ts +5 -5
- package/src/components/blockquote.tsx +1 -1
- package/src/components/blockquote.ws.tsx +63 -36
- package/src/components/body.tsx +1 -1
- package/src/components/body.ws.tsx +39 -47
- package/src/components/bold.tsx +1 -1
- package/src/components/bold.ws.tsx +10 -2
- package/src/components/box.ws.ts +28 -5
- package/src/components/button.tsx +1 -1
- package/src/components/button.ws.tsx +10 -2
- package/src/components/code.tsx +1 -1
- package/src/components/code.ws.tsx +36 -28
- package/src/components/component-meta.ts +4 -1
- package/src/components/form.tsx +1 -1
- package/src/components/form.ws.tsx +11 -9
- package/src/components/heading.ws.tsx +16 -0
- package/src/components/image.tsx +1 -1
- package/src/components/image.ws.tsx +19 -12
- package/src/components/input.tsx +1 -1
- package/src/components/input.ws.tsx +10 -2
- package/src/components/italic.tsx +1 -1
- package/src/components/italic.ws.tsx +12 -6
- package/src/components/link-block.tsx +1 -0
- package/src/components/link-block.ws.tsx +16 -10
- package/src/components/link.tsx +14 -6
- package/src/components/link.ws.tsx +25 -12
- package/src/components/list-item.tsx +1 -1
- package/src/components/list-item.ws.tsx +8 -0
- package/src/components/list.tsx +2 -0
- package/src/components/list.ws.tsx +32 -11
- package/src/components/paragraph.tsx +1 -1
- package/src/components/paragraph.ws.tsx +8 -0
- package/src/components/rich-text-link.ws.tsx +6 -3
- package/src/components/separator.tsx +1 -1
- package/src/components/separator.ws.tsx +33 -12
- package/src/components/span.tsx +1 -1
- package/src/components/span.ws.tsx +10 -2
- package/src/components/subscript.tsx +1 -1
- package/src/components/subscript.ws.tsx +8 -0
- package/src/components/superscript.tsx +1 -1
- package/src/components/superscript.ws.tsx +8 -0
- package/src/components/text-block.tsx +1 -1
- package/src/components/text-block.ws.tsx +14 -7
- package/src/context.tsx +4 -1
- package/src/css/css.ts +57 -0
- package/src/css/get-browser-style.ts +6 -1
- package/src/css/global-rules.ts +29 -0
- package/src/css/index.ts +3 -1
- package/src/css/normalize-type-check.ts +13 -0
- package/src/css/normalize.ts +519 -0
- package/src/css/presets.ts +42 -0
- package/src/css/style-rules.test.ts +147 -0
- package/src/css/style-rules.ts +66 -0
- package/src/props.test.ts +95 -0
- package/src/props.ts +59 -5
- package/src/pubsub/create.ts +7 -38
- package/src/pubsub/raf-queue.ts +31 -0
- package/src/tree/create-elements-tree.tsx +7 -2
- package/src/tree/root.ts +2 -0
- package/src/tree/webstudio-component.tsx +1 -0
- package/lib/cjs/css/categories.cjs +0 -250
- package/lib/css/categories.js +0 -230
- package/src/css/categories.ts +0 -254
- package/lib/cjs/app/custom-components/{index.cjs → index.js} +0 -0
- package/lib/cjs/app/custom-components/{link-block.cjs → link-block.js} +0 -0
- package/lib/cjs/app/custom-components/{link.cjs → link.js} +0 -0
- package/lib/cjs/app/custom-components/{rich-text-link.cjs → rich-text-link.js} +0 -0
- package/lib/cjs/app/{handle-request.server.cjs → handle-request.server.js} +0 -0
- package/lib/cjs/app/{index.cjs → index.js} +0 -0
- package/lib/cjs/app/{params.cjs → params.js} +0 -0
- package/lib/cjs/app/{root.cjs → root.js} +0 -0
- package/lib/cjs/components/__generated__/{blockquote.props.cjs → blockquote.props.js} +0 -0
- package/lib/cjs/components/__generated__/{body.props.cjs → body.props.js} +0 -0
- package/lib/cjs/components/__generated__/{bold.props.cjs → bold.props.js} +0 -0
- package/lib/cjs/components/__generated__/{box.props.cjs → box.props.js} +0 -0
- package/lib/cjs/components/__generated__/{button.props.cjs → button.props.js} +0 -0
- package/lib/cjs/components/__generated__/{code.props.cjs → code.props.js} +0 -0
- package/lib/cjs/components/__generated__/{form.props.cjs → form.props.js} +0 -0
- package/lib/cjs/components/__generated__/{fragment.props.cjs → fragment.props.js} +0 -0
- package/lib/cjs/components/__generated__/{heading.props.cjs → heading.props.js} +0 -0
- package/lib/cjs/components/__generated__/{image.props.cjs → image.props.js} +0 -0
- package/lib/cjs/components/__generated__/{input.props.cjs → input.props.js} +0 -0
- package/lib/cjs/components/__generated__/{italic.props.cjs → italic.props.js} +0 -0
- package/lib/cjs/components/__generated__/{link-block.props.cjs → link-block.props.js} +5 -5
- package/lib/cjs/components/__generated__/{list-item.props.cjs → list-item.props.js} +0 -0
- package/lib/cjs/components/__generated__/{list.props.cjs → list.props.js} +0 -0
- package/lib/cjs/components/__generated__/{paragraph.props.cjs → paragraph.props.js} +0 -0
- package/lib/cjs/components/__generated__/{rich-text-link.props.cjs → rich-text-link.props.js} +5 -5
- /package/lib/cjs/components/__generated__/{separator.props.cjs → separator.props.js} +0 -0
- /package/lib/cjs/components/__generated__/{slot.props.cjs → slot.props.js} +0 -0
- /package/lib/cjs/components/__generated__/{span.props.cjs → span.props.js} +0 -0
- /package/lib/cjs/components/__generated__/{subscript.props.cjs → subscript.props.js} +0 -0
- /package/lib/cjs/components/__generated__/{superscript.props.cjs → superscript.props.js} +0 -0
- /package/lib/cjs/components/__generated__/{text-block.props.cjs → text-block.props.js} +0 -0
- /package/lib/cjs/components/{box.cjs → box.js} +0 -0
- /package/lib/cjs/components/{component-meta.cjs → component-meta.js} +0 -0
- /package/lib/cjs/components/{components-utils.cjs → components-utils.js} +0 -0
- /package/lib/cjs/components/{components.cjs → components.js} +0 -0
- /package/lib/cjs/components/{fragment.cjs → fragment.js} +0 -0
- /package/lib/cjs/components/{fragment.ws.cjs → fragment.ws.js} +0 -0
- /package/lib/cjs/components/{heading.cjs → heading.js} +0 -0
- /package/lib/cjs/components/{index.cjs → index.js} +0 -0
- /package/lib/cjs/components/{list.cjs → list.js} +0 -0
- /package/lib/cjs/components/{rich-text-link.cjs → rich-text-link.js} +0 -0
- /package/lib/cjs/components/{slot.cjs → slot.js} +0 -0
- /package/lib/cjs/components/{slot.ws.cjs → slot.ws.js} +0 -0
- /package/lib/cjs/css/{get-browser-style.cjs → get-browser-style.js} +0 -0
- /package/lib/cjs/{index.cjs → index.js} +0 -0
- /package/lib/cjs/pubsub/{index.cjs → index.js} +0 -0
- /package/lib/cjs/tree/{index.cjs → index.js} +0 -0
- /package/lib/cjs/tree/{session-storage-polyfill.cjs → session-storage-polyfill.js} +0 -0
|
@@ -0,0 +1,605 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import type { FunctionComponent } from "react";
|
|
3
|
+
import type { IconProps } from "@webstudio-is/icons";
|
|
4
|
+
import type { Style } from "@webstudio-is/css-data";
|
|
5
|
+
import type { htmlTags as HtmlTags } from "html-tags";
|
|
6
|
+
type PresetStyle = Partial<Record<HtmlTags, Style>>;
|
|
7
|
+
declare const WsComponentPropsMeta: z.ZodObject<{
|
|
8
|
+
props: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodObject<{
|
|
9
|
+
control: z.ZodLiteral<"number">;
|
|
10
|
+
type: z.ZodLiteral<"number">;
|
|
11
|
+
defaultValue: z.ZodOptional<z.ZodNumber>;
|
|
12
|
+
label: z.ZodOptional<z.ZodString>;
|
|
13
|
+
description: z.ZodOptional<z.ZodString>;
|
|
14
|
+
required: z.ZodBoolean;
|
|
15
|
+
}, "strip", z.ZodTypeAny, {
|
|
16
|
+
description?: string | undefined;
|
|
17
|
+
label?: string | undefined;
|
|
18
|
+
defaultValue?: number | undefined;
|
|
19
|
+
type: "number";
|
|
20
|
+
required: boolean;
|
|
21
|
+
control: "number";
|
|
22
|
+
}, {
|
|
23
|
+
description?: string | undefined;
|
|
24
|
+
label?: string | undefined;
|
|
25
|
+
defaultValue?: number | undefined;
|
|
26
|
+
type: "number";
|
|
27
|
+
required: boolean;
|
|
28
|
+
control: "number";
|
|
29
|
+
}>, z.ZodObject<{
|
|
30
|
+
control: z.ZodLiteral<"range">;
|
|
31
|
+
type: z.ZodLiteral<"number">;
|
|
32
|
+
defaultValue: z.ZodOptional<z.ZodNumber>;
|
|
33
|
+
label: z.ZodOptional<z.ZodString>;
|
|
34
|
+
description: z.ZodOptional<z.ZodString>;
|
|
35
|
+
required: z.ZodBoolean;
|
|
36
|
+
}, "strip", z.ZodTypeAny, {
|
|
37
|
+
description?: string | undefined;
|
|
38
|
+
label?: string | undefined;
|
|
39
|
+
defaultValue?: number | undefined;
|
|
40
|
+
type: "number";
|
|
41
|
+
required: boolean;
|
|
42
|
+
control: "range";
|
|
43
|
+
}, {
|
|
44
|
+
description?: string | undefined;
|
|
45
|
+
label?: string | undefined;
|
|
46
|
+
defaultValue?: number | undefined;
|
|
47
|
+
type: "number";
|
|
48
|
+
required: boolean;
|
|
49
|
+
control: "range";
|
|
50
|
+
}>, z.ZodObject<{
|
|
51
|
+
control: z.ZodLiteral<"text">;
|
|
52
|
+
type: z.ZodLiteral<"string">;
|
|
53
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
54
|
+
rows: z.ZodOptional<z.ZodNumber>;
|
|
55
|
+
label: z.ZodOptional<z.ZodString>;
|
|
56
|
+
description: z.ZodOptional<z.ZodString>;
|
|
57
|
+
required: z.ZodBoolean;
|
|
58
|
+
}, "strip", z.ZodTypeAny, {
|
|
59
|
+
description?: string | undefined;
|
|
60
|
+
label?: string | undefined;
|
|
61
|
+
defaultValue?: string | undefined;
|
|
62
|
+
rows?: number | undefined;
|
|
63
|
+
type: "string";
|
|
64
|
+
required: boolean;
|
|
65
|
+
control: "text";
|
|
66
|
+
}, {
|
|
67
|
+
description?: string | undefined;
|
|
68
|
+
label?: string | undefined;
|
|
69
|
+
defaultValue?: string | undefined;
|
|
70
|
+
rows?: number | undefined;
|
|
71
|
+
type: "string";
|
|
72
|
+
required: boolean;
|
|
73
|
+
control: "text";
|
|
74
|
+
}>, z.ZodObject<{
|
|
75
|
+
control: z.ZodLiteral<"color">;
|
|
76
|
+
type: z.ZodLiteral<"string">;
|
|
77
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
78
|
+
label: z.ZodOptional<z.ZodString>;
|
|
79
|
+
description: z.ZodOptional<z.ZodString>;
|
|
80
|
+
required: z.ZodBoolean;
|
|
81
|
+
}, "strip", z.ZodTypeAny, {
|
|
82
|
+
description?: string | undefined;
|
|
83
|
+
label?: string | undefined;
|
|
84
|
+
defaultValue?: string | undefined;
|
|
85
|
+
type: "string";
|
|
86
|
+
required: boolean;
|
|
87
|
+
control: "color";
|
|
88
|
+
}, {
|
|
89
|
+
description?: string | undefined;
|
|
90
|
+
label?: string | undefined;
|
|
91
|
+
defaultValue?: string | undefined;
|
|
92
|
+
type: "string";
|
|
93
|
+
required: boolean;
|
|
94
|
+
control: "color";
|
|
95
|
+
}>, z.ZodObject<{
|
|
96
|
+
control: z.ZodLiteral<"boolean">;
|
|
97
|
+
type: z.ZodLiteral<"boolean">;
|
|
98
|
+
defaultValue: z.ZodOptional<z.ZodBoolean>;
|
|
99
|
+
label: z.ZodOptional<z.ZodString>;
|
|
100
|
+
description: z.ZodOptional<z.ZodString>;
|
|
101
|
+
required: z.ZodBoolean;
|
|
102
|
+
}, "strip", z.ZodTypeAny, {
|
|
103
|
+
description?: string | undefined;
|
|
104
|
+
label?: string | undefined;
|
|
105
|
+
defaultValue?: boolean | undefined;
|
|
106
|
+
type: "boolean";
|
|
107
|
+
required: boolean;
|
|
108
|
+
control: "boolean";
|
|
109
|
+
}, {
|
|
110
|
+
description?: string | undefined;
|
|
111
|
+
label?: string | undefined;
|
|
112
|
+
defaultValue?: boolean | undefined;
|
|
113
|
+
type: "boolean";
|
|
114
|
+
required: boolean;
|
|
115
|
+
control: "boolean";
|
|
116
|
+
}>, z.ZodObject<{
|
|
117
|
+
control: z.ZodLiteral<"radio">;
|
|
118
|
+
type: z.ZodLiteral<"string">;
|
|
119
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
120
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
121
|
+
label: z.ZodOptional<z.ZodString>;
|
|
122
|
+
description: z.ZodOptional<z.ZodString>;
|
|
123
|
+
required: z.ZodBoolean;
|
|
124
|
+
}, "strip", z.ZodTypeAny, {
|
|
125
|
+
description?: string | undefined;
|
|
126
|
+
label?: string | undefined;
|
|
127
|
+
defaultValue?: string | undefined;
|
|
128
|
+
options: string[];
|
|
129
|
+
type: "string";
|
|
130
|
+
required: boolean;
|
|
131
|
+
control: "radio";
|
|
132
|
+
}, {
|
|
133
|
+
description?: string | undefined;
|
|
134
|
+
label?: string | undefined;
|
|
135
|
+
defaultValue?: string | undefined;
|
|
136
|
+
options: string[];
|
|
137
|
+
type: "string";
|
|
138
|
+
required: boolean;
|
|
139
|
+
control: "radio";
|
|
140
|
+
}>, z.ZodObject<{
|
|
141
|
+
control: z.ZodLiteral<"inline-radio">;
|
|
142
|
+
type: z.ZodLiteral<"string">;
|
|
143
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
144
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
145
|
+
label: z.ZodOptional<z.ZodString>;
|
|
146
|
+
description: z.ZodOptional<z.ZodString>;
|
|
147
|
+
required: z.ZodBoolean;
|
|
148
|
+
}, "strip", z.ZodTypeAny, {
|
|
149
|
+
description?: string | undefined;
|
|
150
|
+
label?: string | undefined;
|
|
151
|
+
defaultValue?: string | undefined;
|
|
152
|
+
options: string[];
|
|
153
|
+
type: "string";
|
|
154
|
+
required: boolean;
|
|
155
|
+
control: "inline-radio";
|
|
156
|
+
}, {
|
|
157
|
+
description?: string | undefined;
|
|
158
|
+
label?: string | undefined;
|
|
159
|
+
defaultValue?: string | undefined;
|
|
160
|
+
options: string[];
|
|
161
|
+
type: "string";
|
|
162
|
+
required: boolean;
|
|
163
|
+
control: "inline-radio";
|
|
164
|
+
}>, z.ZodObject<{
|
|
165
|
+
control: z.ZodLiteral<"select">;
|
|
166
|
+
type: z.ZodLiteral<"string">;
|
|
167
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
168
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
169
|
+
label: z.ZodOptional<z.ZodString>;
|
|
170
|
+
description: z.ZodOptional<z.ZodString>;
|
|
171
|
+
required: z.ZodBoolean;
|
|
172
|
+
}, "strip", z.ZodTypeAny, {
|
|
173
|
+
description?: string | undefined;
|
|
174
|
+
label?: string | undefined;
|
|
175
|
+
defaultValue?: string | undefined;
|
|
176
|
+
options: string[];
|
|
177
|
+
type: "string";
|
|
178
|
+
required: boolean;
|
|
179
|
+
control: "select";
|
|
180
|
+
}, {
|
|
181
|
+
description?: string | undefined;
|
|
182
|
+
label?: string | undefined;
|
|
183
|
+
defaultValue?: string | undefined;
|
|
184
|
+
options: string[];
|
|
185
|
+
type: "string";
|
|
186
|
+
required: boolean;
|
|
187
|
+
control: "select";
|
|
188
|
+
}>, z.ZodObject<{
|
|
189
|
+
control: z.ZodLiteral<"multi-select">;
|
|
190
|
+
type: z.ZodLiteral<"string[]">;
|
|
191
|
+
defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
192
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
193
|
+
label: z.ZodOptional<z.ZodString>;
|
|
194
|
+
description: z.ZodOptional<z.ZodString>;
|
|
195
|
+
required: z.ZodBoolean;
|
|
196
|
+
}, "strip", z.ZodTypeAny, {
|
|
197
|
+
description?: string | undefined;
|
|
198
|
+
label?: string | undefined;
|
|
199
|
+
defaultValue?: string[] | undefined;
|
|
200
|
+
options: string[];
|
|
201
|
+
type: "string[]";
|
|
202
|
+
required: boolean;
|
|
203
|
+
control: "multi-select";
|
|
204
|
+
}, {
|
|
205
|
+
description?: string | undefined;
|
|
206
|
+
label?: string | undefined;
|
|
207
|
+
defaultValue?: string[] | undefined;
|
|
208
|
+
options: string[];
|
|
209
|
+
type: "string[]";
|
|
210
|
+
required: boolean;
|
|
211
|
+
control: "multi-select";
|
|
212
|
+
}>, z.ZodObject<{
|
|
213
|
+
control: z.ZodLiteral<"check">;
|
|
214
|
+
type: z.ZodLiteral<"string[]">;
|
|
215
|
+
defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
216
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
217
|
+
label: z.ZodOptional<z.ZodString>;
|
|
218
|
+
description: z.ZodOptional<z.ZodString>;
|
|
219
|
+
required: z.ZodBoolean;
|
|
220
|
+
}, "strip", z.ZodTypeAny, {
|
|
221
|
+
description?: string | undefined;
|
|
222
|
+
label?: string | undefined;
|
|
223
|
+
defaultValue?: string[] | undefined;
|
|
224
|
+
options: string[];
|
|
225
|
+
type: "string[]";
|
|
226
|
+
required: boolean;
|
|
227
|
+
control: "check";
|
|
228
|
+
}, {
|
|
229
|
+
description?: string | undefined;
|
|
230
|
+
label?: string | undefined;
|
|
231
|
+
defaultValue?: string[] | undefined;
|
|
232
|
+
options: string[];
|
|
233
|
+
type: "string[]";
|
|
234
|
+
required: boolean;
|
|
235
|
+
control: "check";
|
|
236
|
+
}>, z.ZodObject<{
|
|
237
|
+
control: z.ZodLiteral<"inline-check">;
|
|
238
|
+
type: z.ZodLiteral<"string[]">;
|
|
239
|
+
defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
240
|
+
options: z.ZodArray<z.ZodString, "many">;
|
|
241
|
+
label: z.ZodOptional<z.ZodString>;
|
|
242
|
+
description: z.ZodOptional<z.ZodString>;
|
|
243
|
+
required: z.ZodBoolean;
|
|
244
|
+
}, "strip", z.ZodTypeAny, {
|
|
245
|
+
description?: string | undefined;
|
|
246
|
+
label?: string | undefined;
|
|
247
|
+
defaultValue?: string[] | undefined;
|
|
248
|
+
options: string[];
|
|
249
|
+
type: "string[]";
|
|
250
|
+
required: boolean;
|
|
251
|
+
control: "inline-check";
|
|
252
|
+
}, {
|
|
253
|
+
description?: string | undefined;
|
|
254
|
+
label?: string | undefined;
|
|
255
|
+
defaultValue?: string[] | undefined;
|
|
256
|
+
options: string[];
|
|
257
|
+
type: "string[]";
|
|
258
|
+
required: boolean;
|
|
259
|
+
control: "inline-check";
|
|
260
|
+
}>, z.ZodObject<{
|
|
261
|
+
control: z.ZodLiteral<"file-image">;
|
|
262
|
+
type: z.ZodLiteral<"string">;
|
|
263
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
264
|
+
label: z.ZodOptional<z.ZodString>;
|
|
265
|
+
description: z.ZodOptional<z.ZodString>;
|
|
266
|
+
required: z.ZodBoolean;
|
|
267
|
+
}, "strip", z.ZodTypeAny, {
|
|
268
|
+
description?: string | undefined;
|
|
269
|
+
label?: string | undefined;
|
|
270
|
+
defaultValue?: string | undefined;
|
|
271
|
+
type: "string";
|
|
272
|
+
required: boolean;
|
|
273
|
+
control: "file-image";
|
|
274
|
+
}, {
|
|
275
|
+
description?: string | undefined;
|
|
276
|
+
label?: string | undefined;
|
|
277
|
+
defaultValue?: string | undefined;
|
|
278
|
+
type: "string";
|
|
279
|
+
required: boolean;
|
|
280
|
+
control: "file-image";
|
|
281
|
+
}>, z.ZodObject<{
|
|
282
|
+
control: z.ZodLiteral<"url">;
|
|
283
|
+
type: z.ZodLiteral<"string">;
|
|
284
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
285
|
+
label: z.ZodOptional<z.ZodString>;
|
|
286
|
+
description: z.ZodOptional<z.ZodString>;
|
|
287
|
+
required: z.ZodBoolean;
|
|
288
|
+
}, "strip", z.ZodTypeAny, {
|
|
289
|
+
description?: string | undefined;
|
|
290
|
+
label?: string | undefined;
|
|
291
|
+
defaultValue?: string | undefined;
|
|
292
|
+
type: "string";
|
|
293
|
+
required: boolean;
|
|
294
|
+
control: "url";
|
|
295
|
+
}, {
|
|
296
|
+
description?: string | undefined;
|
|
297
|
+
label?: string | undefined;
|
|
298
|
+
defaultValue?: string | undefined;
|
|
299
|
+
type: "string";
|
|
300
|
+
required: boolean;
|
|
301
|
+
control: "url";
|
|
302
|
+
}>, z.ZodObject<{
|
|
303
|
+
control: z.ZodLiteral<"object">;
|
|
304
|
+
type: z.ZodLiteral<"Record<string, string>">;
|
|
305
|
+
defaultValue: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
306
|
+
label: z.ZodOptional<z.ZodString>;
|
|
307
|
+
description: z.ZodOptional<z.ZodString>;
|
|
308
|
+
required: z.ZodBoolean;
|
|
309
|
+
}, "strip", z.ZodTypeAny, {
|
|
310
|
+
description?: string | undefined;
|
|
311
|
+
label?: string | undefined;
|
|
312
|
+
defaultValue?: Record<string, string> | undefined;
|
|
313
|
+
type: "Record<string, string>";
|
|
314
|
+
required: boolean;
|
|
315
|
+
control: "object";
|
|
316
|
+
}, {
|
|
317
|
+
description?: string | undefined;
|
|
318
|
+
label?: string | undefined;
|
|
319
|
+
defaultValue?: Record<string, string> | undefined;
|
|
320
|
+
type: "Record<string, string>";
|
|
321
|
+
required: boolean;
|
|
322
|
+
control: "object";
|
|
323
|
+
}>, z.ZodObject<{
|
|
324
|
+
control: z.ZodLiteral<"date">;
|
|
325
|
+
type: z.ZodLiteral<"string">;
|
|
326
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
327
|
+
label: z.ZodOptional<z.ZodString>;
|
|
328
|
+
description: z.ZodOptional<z.ZodString>;
|
|
329
|
+
required: z.ZodBoolean;
|
|
330
|
+
}, "strip", z.ZodTypeAny, {
|
|
331
|
+
description?: string | undefined;
|
|
332
|
+
label?: string | undefined;
|
|
333
|
+
defaultValue?: string | undefined;
|
|
334
|
+
type: "string";
|
|
335
|
+
required: boolean;
|
|
336
|
+
control: "date";
|
|
337
|
+
}, {
|
|
338
|
+
description?: string | undefined;
|
|
339
|
+
label?: string | undefined;
|
|
340
|
+
defaultValue?: string | undefined;
|
|
341
|
+
type: "string";
|
|
342
|
+
required: boolean;
|
|
343
|
+
control: "date";
|
|
344
|
+
}>]>>;
|
|
345
|
+
initialProps: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
346
|
+
}, "strip", z.ZodTypeAny, {
|
|
347
|
+
initialProps?: string[] | undefined;
|
|
348
|
+
props: Record<string, {
|
|
349
|
+
description?: string | undefined;
|
|
350
|
+
label?: string | undefined;
|
|
351
|
+
defaultValue?: number | undefined;
|
|
352
|
+
type: "number";
|
|
353
|
+
required: boolean;
|
|
354
|
+
control: "number";
|
|
355
|
+
} | {
|
|
356
|
+
description?: string | undefined;
|
|
357
|
+
label?: string | undefined;
|
|
358
|
+
defaultValue?: number | undefined;
|
|
359
|
+
type: "number";
|
|
360
|
+
required: boolean;
|
|
361
|
+
control: "range";
|
|
362
|
+
} | {
|
|
363
|
+
description?: string | undefined;
|
|
364
|
+
label?: string | undefined;
|
|
365
|
+
defaultValue?: string | undefined;
|
|
366
|
+
rows?: number | undefined;
|
|
367
|
+
type: "string";
|
|
368
|
+
required: boolean;
|
|
369
|
+
control: "text";
|
|
370
|
+
} | {
|
|
371
|
+
description?: string | undefined;
|
|
372
|
+
label?: string | undefined;
|
|
373
|
+
defaultValue?: string | undefined;
|
|
374
|
+
type: "string";
|
|
375
|
+
required: boolean;
|
|
376
|
+
control: "color";
|
|
377
|
+
} | {
|
|
378
|
+
description?: string | undefined;
|
|
379
|
+
label?: string | undefined;
|
|
380
|
+
defaultValue?: boolean | undefined;
|
|
381
|
+
type: "boolean";
|
|
382
|
+
required: boolean;
|
|
383
|
+
control: "boolean";
|
|
384
|
+
} | {
|
|
385
|
+
description?: string | undefined;
|
|
386
|
+
label?: string | undefined;
|
|
387
|
+
defaultValue?: string | undefined;
|
|
388
|
+
options: string[];
|
|
389
|
+
type: "string";
|
|
390
|
+
required: boolean;
|
|
391
|
+
control: "radio";
|
|
392
|
+
} | {
|
|
393
|
+
description?: string | undefined;
|
|
394
|
+
label?: string | undefined;
|
|
395
|
+
defaultValue?: string | undefined;
|
|
396
|
+
options: string[];
|
|
397
|
+
type: "string";
|
|
398
|
+
required: boolean;
|
|
399
|
+
control: "inline-radio";
|
|
400
|
+
} | {
|
|
401
|
+
description?: string | undefined;
|
|
402
|
+
label?: string | undefined;
|
|
403
|
+
defaultValue?: string | undefined;
|
|
404
|
+
options: string[];
|
|
405
|
+
type: "string";
|
|
406
|
+
required: boolean;
|
|
407
|
+
control: "select";
|
|
408
|
+
} | {
|
|
409
|
+
description?: string | undefined;
|
|
410
|
+
label?: string | undefined;
|
|
411
|
+
defaultValue?: string[] | undefined;
|
|
412
|
+
options: string[];
|
|
413
|
+
type: "string[]";
|
|
414
|
+
required: boolean;
|
|
415
|
+
control: "check";
|
|
416
|
+
} | {
|
|
417
|
+
description?: string | undefined;
|
|
418
|
+
label?: string | undefined;
|
|
419
|
+
defaultValue?: string[] | undefined;
|
|
420
|
+
options: string[];
|
|
421
|
+
type: "string[]";
|
|
422
|
+
required: boolean;
|
|
423
|
+
control: "inline-check";
|
|
424
|
+
} | {
|
|
425
|
+
description?: string | undefined;
|
|
426
|
+
label?: string | undefined;
|
|
427
|
+
defaultValue?: string[] | undefined;
|
|
428
|
+
options: string[];
|
|
429
|
+
type: "string[]";
|
|
430
|
+
required: boolean;
|
|
431
|
+
control: "multi-select";
|
|
432
|
+
} | {
|
|
433
|
+
description?: string | undefined;
|
|
434
|
+
label?: string | undefined;
|
|
435
|
+
defaultValue?: string | undefined;
|
|
436
|
+
type: "string";
|
|
437
|
+
required: boolean;
|
|
438
|
+
control: "file-image";
|
|
439
|
+
} | {
|
|
440
|
+
description?: string | undefined;
|
|
441
|
+
label?: string | undefined;
|
|
442
|
+
defaultValue?: string | undefined;
|
|
443
|
+
type: "string";
|
|
444
|
+
required: boolean;
|
|
445
|
+
control: "url";
|
|
446
|
+
} | {
|
|
447
|
+
description?: string | undefined;
|
|
448
|
+
label?: string | undefined;
|
|
449
|
+
defaultValue?: Record<string, string> | undefined;
|
|
450
|
+
type: "Record<string, string>";
|
|
451
|
+
required: boolean;
|
|
452
|
+
control: "object";
|
|
453
|
+
} | {
|
|
454
|
+
description?: string | undefined;
|
|
455
|
+
label?: string | undefined;
|
|
456
|
+
defaultValue?: string | undefined;
|
|
457
|
+
type: "string";
|
|
458
|
+
required: boolean;
|
|
459
|
+
control: "date";
|
|
460
|
+
}>;
|
|
461
|
+
}, {
|
|
462
|
+
initialProps?: string[] | undefined;
|
|
463
|
+
props: Record<string, {
|
|
464
|
+
description?: string | undefined;
|
|
465
|
+
label?: string | undefined;
|
|
466
|
+
defaultValue?: number | undefined;
|
|
467
|
+
type: "number";
|
|
468
|
+
required: boolean;
|
|
469
|
+
control: "number";
|
|
470
|
+
} | {
|
|
471
|
+
description?: string | undefined;
|
|
472
|
+
label?: string | undefined;
|
|
473
|
+
defaultValue?: number | undefined;
|
|
474
|
+
type: "number";
|
|
475
|
+
required: boolean;
|
|
476
|
+
control: "range";
|
|
477
|
+
} | {
|
|
478
|
+
description?: string | undefined;
|
|
479
|
+
label?: string | undefined;
|
|
480
|
+
defaultValue?: string | undefined;
|
|
481
|
+
rows?: number | undefined;
|
|
482
|
+
type: "string";
|
|
483
|
+
required: boolean;
|
|
484
|
+
control: "text";
|
|
485
|
+
} | {
|
|
486
|
+
description?: string | undefined;
|
|
487
|
+
label?: string | undefined;
|
|
488
|
+
defaultValue?: string | undefined;
|
|
489
|
+
type: "string";
|
|
490
|
+
required: boolean;
|
|
491
|
+
control: "color";
|
|
492
|
+
} | {
|
|
493
|
+
description?: string | undefined;
|
|
494
|
+
label?: string | undefined;
|
|
495
|
+
defaultValue?: boolean | undefined;
|
|
496
|
+
type: "boolean";
|
|
497
|
+
required: boolean;
|
|
498
|
+
control: "boolean";
|
|
499
|
+
} | {
|
|
500
|
+
description?: string | undefined;
|
|
501
|
+
label?: string | undefined;
|
|
502
|
+
defaultValue?: string | undefined;
|
|
503
|
+
options: string[];
|
|
504
|
+
type: "string";
|
|
505
|
+
required: boolean;
|
|
506
|
+
control: "radio";
|
|
507
|
+
} | {
|
|
508
|
+
description?: string | undefined;
|
|
509
|
+
label?: string | undefined;
|
|
510
|
+
defaultValue?: string | undefined;
|
|
511
|
+
options: string[];
|
|
512
|
+
type: "string";
|
|
513
|
+
required: boolean;
|
|
514
|
+
control: "inline-radio";
|
|
515
|
+
} | {
|
|
516
|
+
description?: string | undefined;
|
|
517
|
+
label?: string | undefined;
|
|
518
|
+
defaultValue?: string | undefined;
|
|
519
|
+
options: string[];
|
|
520
|
+
type: "string";
|
|
521
|
+
required: boolean;
|
|
522
|
+
control: "select";
|
|
523
|
+
} | {
|
|
524
|
+
description?: string | undefined;
|
|
525
|
+
label?: string | undefined;
|
|
526
|
+
defaultValue?: string[] | undefined;
|
|
527
|
+
options: string[];
|
|
528
|
+
type: "string[]";
|
|
529
|
+
required: boolean;
|
|
530
|
+
control: "check";
|
|
531
|
+
} | {
|
|
532
|
+
description?: string | undefined;
|
|
533
|
+
label?: string | undefined;
|
|
534
|
+
defaultValue?: string[] | undefined;
|
|
535
|
+
options: string[];
|
|
536
|
+
type: "string[]";
|
|
537
|
+
required: boolean;
|
|
538
|
+
control: "inline-check";
|
|
539
|
+
} | {
|
|
540
|
+
description?: string | undefined;
|
|
541
|
+
label?: string | undefined;
|
|
542
|
+
defaultValue?: string[] | undefined;
|
|
543
|
+
options: string[];
|
|
544
|
+
type: "string[]";
|
|
545
|
+
required: boolean;
|
|
546
|
+
control: "multi-select";
|
|
547
|
+
} | {
|
|
548
|
+
description?: string | undefined;
|
|
549
|
+
label?: string | undefined;
|
|
550
|
+
defaultValue?: string | undefined;
|
|
551
|
+
type: "string";
|
|
552
|
+
required: boolean;
|
|
553
|
+
control: "file-image";
|
|
554
|
+
} | {
|
|
555
|
+
description?: string | undefined;
|
|
556
|
+
label?: string | undefined;
|
|
557
|
+
defaultValue?: string | undefined;
|
|
558
|
+
type: "string";
|
|
559
|
+
required: boolean;
|
|
560
|
+
control: "url";
|
|
561
|
+
} | {
|
|
562
|
+
description?: string | undefined;
|
|
563
|
+
label?: string | undefined;
|
|
564
|
+
defaultValue?: Record<string, string> | undefined;
|
|
565
|
+
type: "Record<string, string>";
|
|
566
|
+
required: boolean;
|
|
567
|
+
control: "object";
|
|
568
|
+
} | {
|
|
569
|
+
description?: string | undefined;
|
|
570
|
+
label?: string | undefined;
|
|
571
|
+
defaultValue?: string | undefined;
|
|
572
|
+
type: "string";
|
|
573
|
+
required: boolean;
|
|
574
|
+
control: "date";
|
|
575
|
+
}>;
|
|
576
|
+
}>;
|
|
577
|
+
export type WsComponentPropsMeta = z.infer<typeof WsComponentPropsMeta>;
|
|
578
|
+
export declare const componentCategories: readonly ["general", "typography", "media", "forms"];
|
|
579
|
+
declare const WsComponentMeta: z.ZodObject<{
|
|
580
|
+
category: z.ZodOptional<z.ZodEnum<["general", "typography", "media", "forms"]>>;
|
|
581
|
+
type: z.ZodEnum<["container", "control", "embed", "rich-text", "rich-text-child"]>;
|
|
582
|
+
label: z.ZodString;
|
|
583
|
+
Icon: z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>;
|
|
584
|
+
presetStyle: z.ZodOptional<z.ZodAny>;
|
|
585
|
+
children: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
586
|
+
}, "strip", z.ZodTypeAny, {
|
|
587
|
+
children?: string[] | undefined;
|
|
588
|
+
category?: "media" | "general" | "typography" | "forms" | undefined;
|
|
589
|
+
presetStyle?: any;
|
|
590
|
+
type: "embed" | "control" | "container" | "rich-text" | "rich-text-child";
|
|
591
|
+
label: string;
|
|
592
|
+
Icon: (...args: unknown[]) => unknown;
|
|
593
|
+
}, {
|
|
594
|
+
children?: string[] | undefined;
|
|
595
|
+
category?: "media" | "general" | "typography" | "forms" | undefined;
|
|
596
|
+
presetStyle?: any;
|
|
597
|
+
type: "embed" | "control" | "container" | "rich-text" | "rich-text-child";
|
|
598
|
+
label: string;
|
|
599
|
+
Icon: (...args: unknown[]) => unknown;
|
|
600
|
+
}>;
|
|
601
|
+
export type WsComponentMeta = Omit<z.infer<typeof WsComponentMeta>, "presetStyle" | "Icon"> & {
|
|
602
|
+
presetStyle?: PresetStyle;
|
|
603
|
+
Icon: FunctionComponent<IconProps>;
|
|
604
|
+
};
|
|
605
|
+
export {};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import * as components from "./components";
|
|
3
|
+
export type ComponentName = keyof typeof components;
|
|
4
|
+
export declare const getComponentNames: () => ComponentName[];
|
|
5
|
+
/**
|
|
6
|
+
* Now used only in builder app
|
|
7
|
+
* @todo Consider using the same approach in the builder app as in the published apps . A dynamic import is needed
|
|
8
|
+
*/
|
|
9
|
+
export declare const getComponent: (name: string) => undefined | (typeof components)[ComponentName];
|
|
10
|
+
/**
|
|
11
|
+
* The application imports only the components it uses, then pass them to createGetComponent i.e.
|
|
12
|
+
* getComponent = createGetComponent({ Box, BlaBla })
|
|
13
|
+
* <RootInstance data={data} getComponent={getComponent} />
|
|
14
|
+
* see example /packages/sdk-size-test/app/routes/$.tsx
|
|
15
|
+
**/
|
|
16
|
+
export declare const createGetComponent: (comps: Partial<typeof components>) => (name: string) => import("react").ForwardRefExoticComponent<{
|
|
17
|
+
children?: import("react").ReactNode;
|
|
18
|
+
} & import("react").RefAttributes<HTMLDivElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLBodyElement>, HTMLBodyElement>, "key" | keyof import("react").HTMLAttributes<HTMLBodyElement>> & import("react").RefAttributes<HTMLBodyElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
19
|
+
tag?: "div" | "address" | "article" | "aside" | "figure" | "footer" | "header" | "main" | "nav" | "section" | undefined;
|
|
20
|
+
}, "key" | keyof import("react").HTMLAttributes<HTMLDivElement> | "tag"> & import("react").RefAttributes<HTMLDivElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>> & import("react").RefAttributes<HTMLDivElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLHeadingElement> & import("react").HTMLAttributes<HTMLHeadingElement> & {
|
|
21
|
+
tag?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | undefined;
|
|
22
|
+
}, "key" | "tag" | keyof import("react").HTMLAttributes<HTMLHeadingElement>> & import("react").RefAttributes<HTMLHeadingElement>> | import("react").ForwardRefExoticComponent<Pick<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "href" | "target"> & {
|
|
23
|
+
href?: string | undefined;
|
|
24
|
+
target?: "_self" | "_blank" | "_parent" | "_top" | undefined;
|
|
25
|
+
prefetch?: "none" | "intent" | "render" | undefined;
|
|
26
|
+
}, "type" | "style" | "id" | "title" | "children" | "hidden" | "color" | "translate" | "property" | "placeholder" | "slot" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "lang" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "href" | "target" | "download" | "hrefLang" | "media" | "ping" | "rel" | "referrerPolicy" | "prefetch"> & import("react").RefAttributes<HTMLAnchorElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "key" | keyof import("react").HTMLAttributes<HTMLSpanElement>> & import("react").RefAttributes<HTMLSpanElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
27
|
+
innerText?: string | undefined;
|
|
28
|
+
}, "key" | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement> | "innerText"> & import("react").RefAttributes<HTMLButtonElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>> & import("react").RefAttributes<HTMLInputElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "key" | keyof import("react").FormHTMLAttributes<HTMLFormElement>> & import("react").RefAttributes<HTMLFormElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, "key" | keyof import("react").ImgHTMLAttributes<HTMLImageElement>> & import("react").RefAttributes<HTMLImageElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").BlockquoteHTMLAttributes<HTMLQuoteElement>, HTMLQuoteElement>, "key" | keyof import("react").BlockquoteHTMLAttributes<HTMLQuoteElement>> & import("react").RefAttributes<HTMLQuoteElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLUListElement> & import("react").HTMLAttributes<HTMLUListElement> & import("react").ClassAttributes<HTMLOListElement> & import("react").OlHTMLAttributes<HTMLOListElement> & {
|
|
29
|
+
ordered?: boolean | undefined;
|
|
30
|
+
}, "type" | "style" | "id" | "title" | "children" | "start" | "hidden" | "color" | "ordered" | "translate" | "property" | "placeholder" | "slot" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "lang" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "reversed"> & import("react").RefAttributes<HTMLUListElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "key" | keyof import("react").LiHTMLAttributes<HTMLLIElement>> & import("react").RefAttributes<HTMLLIElement>> | import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHRElement>, HTMLHRElement>, "key" | keyof import("react").HTMLAttributes<HTMLHRElement>> & import("react").RefAttributes<HTMLHRElement>> | import("react").ForwardRefExoticComponent<Pick<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "inline"> & {
|
|
31
|
+
inline?: boolean | undefined;
|
|
32
|
+
meta?: string | undefined;
|
|
33
|
+
}, "meta" | "inline" | "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>> | undefined;
|
|
34
|
+
export type GetComponent = typeof getComponent;
|