@webstudio-is/react-sdk 0.8.0 → 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (138) hide show
  1. package/lib/app/custom-components/image.d.ts +9 -0
  2. package/lib/app/custom-components/image.d.ts.map +1 -0
  3. package/lib/app/custom-components/image.js +24 -0
  4. package/lib/app/custom-components/index.d.ts +2 -0
  5. package/lib/app/custom-components/index.d.ts.map +1 -0
  6. package/lib/app/custom-components/index.js +1 -0
  7. package/lib/{cjs/remix → app}/handle-request.server.d.ts +0 -0
  8. package/lib/app/handle-request.server.d.ts.map +1 -0
  9. package/lib/{remix → app}/handle-request.server.js +0 -0
  10. package/lib/{cjs/remix → app}/index.d.ts +1 -0
  11. package/lib/app/index.d.ts.map +1 -0
  12. package/lib/{remix → app}/index.js +1 -0
  13. package/lib/app/params.d.ts +6 -0
  14. package/lib/app/params.d.ts.map +1 -0
  15. package/lib/app/params.js +6 -0
  16. package/lib/{cjs/remix → app}/root.d.ts +1 -0
  17. package/lib/app/root.d.ts.map +1 -0
  18. package/lib/{remix → app}/root.js +0 -0
  19. package/lib/cjs/app/custom-components/image.cjs +27 -0
  20. package/lib/cjs/app/custom-components/image.d.ts +9 -0
  21. package/lib/cjs/app/custom-components/image.d.ts.map +1 -0
  22. package/lib/cjs/app/custom-components/index.cjs +27 -0
  23. package/lib/cjs/app/custom-components/index.d.ts +2 -0
  24. package/lib/cjs/app/custom-components/index.d.ts.map +1 -0
  25. package/lib/cjs/{remix → app}/handle-request.server.cjs +0 -0
  26. package/lib/{remix → cjs/app}/handle-request.server.d.ts +0 -0
  27. package/lib/cjs/app/handle-request.server.d.ts.map +1 -0
  28. package/lib/cjs/{remix → app}/index.cjs +1 -0
  29. package/lib/{remix → cjs/app}/index.d.ts +1 -0
  30. package/lib/cjs/app/index.d.ts.map +1 -0
  31. package/lib/cjs/app/params.cjs +11 -0
  32. package/lib/cjs/app/params.d.ts +6 -0
  33. package/lib/cjs/app/params.d.ts.map +1 -0
  34. package/lib/cjs/{remix → app}/root.cjs +0 -0
  35. package/lib/{remix → cjs/app}/root.d.ts +1 -0
  36. package/lib/cjs/app/root.d.ts.map +1 -0
  37. package/lib/cjs/components/{body.props.json → __generated__/body.props.json} +0 -0
  38. package/lib/cjs/components/{bold.props.json → __generated__/bold.props.json} +0 -0
  39. package/lib/cjs/components/{box.props.json → __generated__/box.props.json} +0 -0
  40. package/lib/cjs/components/{button.props.json → __generated__/button.props.json} +0 -0
  41. package/lib/cjs/components/{form.props.json → __generated__/form.props.json} +0 -0
  42. package/lib/cjs/components/{heading.props.json → __generated__/heading.props.json} +0 -0
  43. package/lib/{components → cjs/components/__generated__}/image.props.json +0 -15
  44. package/lib/cjs/components/{input.props.json → __generated__/input.props.json} +0 -0
  45. package/lib/cjs/components/{italic.props.json → __generated__/italic.props.json} +0 -0
  46. package/lib/cjs/components/{link.props.json → __generated__/link.props.json} +0 -0
  47. package/lib/cjs/components/{paragraph.props.json → __generated__/paragraph.props.json} +0 -0
  48. package/lib/cjs/components/{span.props.json → __generated__/span.props.json} +0 -0
  49. package/lib/cjs/components/{subscript.props.json → __generated__/subscript.props.json} +0 -0
  50. package/lib/cjs/components/{superscript.props.json → __generated__/superscript.props.json} +0 -0
  51. package/lib/cjs/components/{text-block.props.json → __generated__/text-block.props.json} +0 -0
  52. package/lib/cjs/components/index.cjs +75 -31
  53. package/lib/cjs/components/index.d.ts +89 -15
  54. package/lib/cjs/components/index.d.ts.map +1 -1
  55. package/lib/cjs/components/index.test.cjs +3 -29
  56. package/lib/cjs/components/meta.cjs +20 -18
  57. package/lib/cjs/components/meta.d.ts +1 -16
  58. package/lib/cjs/components/meta.d.ts.map +1 -1
  59. package/lib/cjs/css/categories.d.ts +1 -0
  60. package/lib/cjs/css/categories.d.ts.map +1 -1
  61. package/lib/cjs/css/get-browser-style.cjs +2 -1
  62. package/lib/cjs/css/get-browser-style.d.ts.map +1 -1
  63. package/lib/cjs/db/instance.d.ts +2 -2
  64. package/lib/cjs/db/instance.d.ts.map +1 -1
  65. package/lib/cjs/index.cjs +4 -3
  66. package/lib/cjs/index.d.ts +3 -2
  67. package/lib/cjs/index.d.ts.map +1 -1
  68. package/lib/cjs/tree/root.cjs +28 -0
  69. package/lib/cjs/tree/root.d.ts +2 -0
  70. package/lib/cjs/tree/root.d.ts.map +1 -1
  71. package/lib/cjs/tree/session-storage-polyfill.d.ts +1 -0
  72. package/lib/cjs/tree/session-storage-polyfill.d.ts.map +1 -1
  73. package/lib/cjs/tree/wrapper-component.cjs +2 -25
  74. package/lib/cjs/tree/wrapper-component.d.ts +1 -0
  75. package/lib/cjs/tree/wrapper-component.d.ts.map +1 -1
  76. package/lib/cjs/user-props/use-user-props-asset.cjs +22 -0
  77. package/lib/cjs/user-props/use-user-props-asset.d.ts +8 -0
  78. package/lib/cjs/user-props/use-user-props-asset.d.ts.map +1 -0
  79. package/lib/cjs/user-props/use-user-props.cjs +2 -12
  80. package/lib/cjs/user-props/use-user-props.d.ts.map +1 -1
  81. package/lib/components/{body.props.json → __generated__/body.props.json} +0 -0
  82. package/lib/components/{bold.props.json → __generated__/bold.props.json} +0 -0
  83. package/lib/components/{box.props.json → __generated__/box.props.json} +0 -0
  84. package/lib/components/{button.props.json → __generated__/button.props.json} +0 -0
  85. package/lib/components/{form.props.json → __generated__/form.props.json} +0 -0
  86. package/lib/components/{heading.props.json → __generated__/heading.props.json} +0 -0
  87. package/lib/{cjs/components → components/__generated__}/image.props.json +0 -15
  88. package/lib/components/{input.props.json → __generated__/input.props.json} +0 -0
  89. package/lib/components/{italic.props.json → __generated__/italic.props.json} +0 -0
  90. package/lib/components/{link.props.json → __generated__/link.props.json} +0 -0
  91. package/lib/components/{paragraph.props.json → __generated__/paragraph.props.json} +0 -0
  92. package/lib/components/{span.props.json → __generated__/span.props.json} +0 -0
  93. package/lib/components/{subscript.props.json → __generated__/subscript.props.json} +0 -0
  94. package/lib/components/{superscript.props.json → __generated__/superscript.props.json} +0 -0
  95. package/lib/components/{text-block.props.json → __generated__/text-block.props.json} +0 -0
  96. package/lib/components/index.d.ts +89 -15
  97. package/lib/components/index.d.ts.map +1 -1
  98. package/lib/components/index.js +70 -15
  99. package/lib/components/index.test.js +3 -6
  100. package/lib/components/meta.d.ts +1 -16
  101. package/lib/components/meta.d.ts.map +1 -1
  102. package/lib/components/meta.js +18 -17
  103. package/lib/css/categories.d.ts +1 -0
  104. package/lib/css/categories.d.ts.map +1 -1
  105. package/lib/css/get-browser-style.d.ts.map +1 -1
  106. package/lib/css/get-browser-style.js +2 -1
  107. package/lib/db/instance.d.ts +2 -2
  108. package/lib/db/instance.d.ts.map +1 -1
  109. package/lib/index.d.ts +3 -2
  110. package/lib/index.d.ts.map +1 -1
  111. package/lib/index.js +3 -2
  112. package/lib/tree/root.d.ts +2 -0
  113. package/lib/tree/root.d.ts.map +1 -1
  114. package/lib/tree/root.js +5 -0
  115. package/lib/tree/session-storage-polyfill.d.ts +1 -0
  116. package/lib/tree/session-storage-polyfill.d.ts.map +1 -1
  117. package/lib/tree/wrapper-component.d.ts +1 -0
  118. package/lib/tree/wrapper-component.d.ts.map +1 -1
  119. package/lib/tree/wrapper-component.js +2 -2
  120. package/lib/tsconfig.tsbuildinfo +1 -1
  121. package/lib/user-props/use-user-props-asset.d.ts +8 -0
  122. package/lib/user-props/use-user-props-asset.d.ts.map +1 -0
  123. package/lib/user-props/use-user-props-asset.js +18 -0
  124. package/lib/user-props/use-user-props.d.ts.map +1 -1
  125. package/lib/user-props/use-user-props.js +3 -13
  126. package/package.json +5 -7
  127. package/lib/arg-types/utils.d.ts +0 -10
  128. package/lib/arg-types/utils.d.ts.map +0 -1
  129. package/lib/arg-types/utils.js +0 -83
  130. package/lib/cjs/arg-types/utils.cjs +0 -88
  131. package/lib/cjs/arg-types/utils.d.ts +0 -10
  132. package/lib/cjs/arg-types/utils.d.ts.map +0 -1
  133. package/lib/cjs/remix/handle-request.server.d.ts.map +0 -1
  134. package/lib/cjs/remix/index.d.ts.map +0 -1
  135. package/lib/cjs/remix/root.d.ts.map +0 -1
  136. package/lib/remix/handle-request.server.d.ts.map +0 -1
  137. package/lib/remix/index.d.ts.map +0 -1
  138. package/lib/remix/root.d.ts.map +0 -1
@@ -1,16 +1,90 @@
1
- export { default as Body } from "./body.ws";
2
- export { default as Box } from "./box.ws";
3
- export { default as TextBlock } from "./text-block.ws";
4
- export { default as Heading } from "./heading.ws";
5
- export { default as Paragraph } from "./paragraph.ws";
6
- export { default as Link } from "./link.ws";
7
- export { default as Span } from "./span.ws";
8
- export { default as Bold } from "./bold.ws";
9
- export { default as Italic } from "./italic.ws";
10
- export { default as Superscript } from "./superscript.ws";
11
- export { default as Subscript } from "./subscript.ws";
12
- export { default as Button } from "./button.ws";
13
- export { default as Input } from "./input.ws";
14
- export { default as Form } from "./form.ws";
15
- export { default as Image } from "./image.ws";
1
+ /// <reference types="react" />
2
+ declare const components: {
3
+ readonly Body: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLBodyElement>, HTMLBodyElement>, "key" | keyof import("react").HTMLAttributes<HTMLBodyElement>> & import("react").RefAttributes<HTMLBodyElement>>>;
4
+ readonly Box: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
5
+ tag?: "address" | "article" | "aside" | "div" | "figure" | "footer" | "header" | "main" | "nav" | "section" | undefined;
6
+ }, "key" | keyof import("react").HTMLAttributes<HTMLDivElement> | "tag"> & import("react").RefAttributes<HTMLDivElement>>>;
7
+ readonly TextBlock: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>> & import("react").RefAttributes<HTMLDivElement>>>;
8
+ readonly Heading: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLHeadingElement> & import("react").HTMLAttributes<HTMLHeadingElement> & {
9
+ tag?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | undefined;
10
+ }, "key" | "tag" | keyof import("react").HTMLAttributes<HTMLHeadingElement>> & import("react").RefAttributes<HTMLHeadingElement>>>;
11
+ readonly Paragraph: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, "key" | keyof import("react").HTMLAttributes<HTMLParagraphElement>> & import("react").RefAttributes<HTMLParagraphElement>>>;
12
+ readonly Link: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "href"> & {
13
+ href?: string | undefined;
14
+ }, "color" | "translate" | "type" | "id" | "children" | "slot" | "style" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "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" | "media" | "target" | "href" | "download" | "hrefLang" | "ping" | "rel" | "referrerPolicy"> & import("react").RefAttributes<HTMLAnchorElement>>>;
15
+ readonly Span: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "key" | keyof import("react").HTMLAttributes<HTMLSpanElement>> & import("react").RefAttributes<HTMLSpanElement>>>;
16
+ readonly Bold: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
17
+ readonly Italic: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
18
+ readonly Superscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
19
+ readonly Subscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
20
+ readonly Button: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "key" | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement>> & import("react").RefAttributes<HTMLButtonElement>>>;
21
+ readonly Input: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>> & import("react").RefAttributes<HTMLInputElement>>>;
22
+ readonly Form: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "key" | keyof import("react").FormHTMLAttributes<HTMLFormElement>> & import("react").RefAttributes<HTMLFormElement>>>;
23
+ readonly Image: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, "key" | keyof import("react").ImgHTMLAttributes<HTMLImageElement>> & import("react").RefAttributes<HTMLImageElement>>>;
24
+ };
25
+ declare type RegisteredComponents = Partial<{
26
+ [p in ComponentName]: {
27
+ Component: {};
28
+ meta?: Partial<Omit<typeof components[p], "Component">>;
29
+ };
30
+ }>;
31
+ export declare type ComponentName = keyof typeof components;
32
+ export declare const getComponentNames: () => ComponentName[];
33
+ export declare const getComponentMeta: <Name extends "Body" | "Box" | "TextBlock" | "Heading" | "Paragraph" | "Link" | "Span" | "Bold" | "Italic" | "Subscript" | "Button" | "Input" | "Form" | "Image" | "Superscript">(name: Name) => Omit<{
34
+ readonly Body: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLBodyElement>, HTMLBodyElement>, "key" | keyof import("react").HTMLAttributes<HTMLBodyElement>> & import("react").RefAttributes<HTMLBodyElement>>>;
35
+ readonly Box: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
36
+ tag?: "address" | "article" | "aside" | "div" | "figure" | "footer" | "header" | "main" | "nav" | "section" | undefined;
37
+ }, "key" | keyof import("react").HTMLAttributes<HTMLDivElement> | "tag"> & import("react").RefAttributes<HTMLDivElement>>>;
38
+ readonly TextBlock: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>> & import("react").RefAttributes<HTMLDivElement>>>;
39
+ readonly Heading: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLHeadingElement> & import("react").HTMLAttributes<HTMLHeadingElement> & {
40
+ tag?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | undefined;
41
+ }, "key" | "tag" | keyof import("react").HTMLAttributes<HTMLHeadingElement>> & import("react").RefAttributes<HTMLHeadingElement>>>;
42
+ readonly Paragraph: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, "key" | keyof import("react").HTMLAttributes<HTMLParagraphElement>> & import("react").RefAttributes<HTMLParagraphElement>>>;
43
+ readonly Link: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "href"> & {
44
+ href?: string | undefined;
45
+ }, "color" | "translate" | "type" | "id" | "children" | "slot" | "style" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "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" | "media" | "target" | "href" | "download" | "hrefLang" | "ping" | "rel" | "referrerPolicy"> & import("react").RefAttributes<HTMLAnchorElement>>>;
46
+ readonly Span: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "key" | keyof import("react").HTMLAttributes<HTMLSpanElement>> & import("react").RefAttributes<HTMLSpanElement>>>;
47
+ readonly Bold: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
48
+ readonly Italic: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
49
+ readonly Superscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
50
+ readonly Subscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
51
+ readonly Button: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "key" | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement>> & import("react").RefAttributes<HTMLButtonElement>>>;
52
+ readonly Input: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>> & import("react").RefAttributes<HTMLInputElement>>>;
53
+ readonly Form: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "key" | keyof import("react").FormHTMLAttributes<HTMLFormElement>> & import("react").RefAttributes<HTMLFormElement>>>;
54
+ readonly Image: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, "key" | keyof import("react").ImgHTMLAttributes<HTMLImageElement>> & import("react").RefAttributes<HTMLImageElement>>>;
55
+ }[Name], "Component">;
56
+ /**
57
+ * @todo Remove Component from meta and read directly (via import),
58
+ * as meta information is not needed during production render.
59
+ **/
60
+ export declare const getComponent: <Name extends "Body" | "Box" | "TextBlock" | "Heading" | "Paragraph" | "Link" | "Span" | "Bold" | "Italic" | "Subscript" | "Button" | "Input" | "Form" | "Image" | "Superscript">(name: Name) => {
61
+ readonly Body: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLBodyElement>, HTMLBodyElement>, "key" | keyof import("react").HTMLAttributes<HTMLBodyElement>> & import("react").RefAttributes<HTMLBodyElement>>>;
62
+ readonly Box: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
63
+ tag?: "address" | "article" | "aside" | "div" | "figure" | "footer" | "header" | "main" | "nav" | "section" | undefined;
64
+ }, "key" | keyof import("react").HTMLAttributes<HTMLDivElement> | "tag"> & import("react").RefAttributes<HTMLDivElement>>>;
65
+ readonly TextBlock: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>> & import("react").RefAttributes<HTMLDivElement>>>;
66
+ readonly Heading: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").ClassAttributes<HTMLHeadingElement> & import("react").HTMLAttributes<HTMLHeadingElement> & {
67
+ tag?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | undefined;
68
+ }, "key" | "tag" | keyof import("react").HTMLAttributes<HTMLHeadingElement>> & import("react").RefAttributes<HTMLHeadingElement>>>;
69
+ readonly Paragraph: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, "key" | keyof import("react").HTMLAttributes<HTMLParagraphElement>> & import("react").RefAttributes<HTMLParagraphElement>>>;
70
+ readonly Link: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "href"> & {
71
+ href?: string | undefined;
72
+ }, "color" | "translate" | "type" | "id" | "children" | "slot" | "style" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "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" | "media" | "target" | "href" | "download" | "hrefLang" | "ping" | "rel" | "referrerPolicy"> & import("react").RefAttributes<HTMLAnchorElement>>>;
73
+ readonly Span: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "key" | keyof import("react").HTMLAttributes<HTMLSpanElement>> & import("react").RefAttributes<HTMLSpanElement>>>;
74
+ readonly Bold: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
75
+ readonly Italic: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
76
+ readonly Superscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
77
+ readonly Subscript: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "key" | keyof import("react").HTMLAttributes<HTMLElement>> & import("react").RefAttributes<HTMLElement>>>;
78
+ readonly Button: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "key" | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement>> & import("react").RefAttributes<HTMLButtonElement>>>;
79
+ readonly Input: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>> & import("react").RefAttributes<HTMLInputElement>>>;
80
+ readonly Form: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "key" | keyof import("react").FormHTMLAttributes<HTMLFormElement>> & import("react").RefAttributes<HTMLFormElement>>>;
81
+ readonly Image: import("./component-type").WsComponentMeta<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, "key" | keyof import("react").ImgHTMLAttributes<HTMLImageElement>> & import("react").RefAttributes<HTMLImageElement>>>;
82
+ }[Name]["Component"];
83
+ /**
84
+ * @todo: Allow register any component.
85
+ * Now we can register only existings Components, as all our type system would
86
+ * break otherwise, see getComponent etc. So its overwriteComponent now
87
+ **/
88
+ export declare const registerComponents: (components: RegisteredComponents) => void;
89
+ export {};
16
90
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,GAAG,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC1D,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,YAAY,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":";AAgBA,QAAA,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;CAgBN,CAAC;AAEX,aAAK,oBAAoB,GAAG,OAAO,CAAC;KACjC,CAAC,IAAI,aAAa,GAAG;QAGpB,SAAS,EAAE,EAAE,CAAC;QACd,IAAI,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC;KACzD;CACF,CAAC,CAAC;AAIH,oBAAY,aAAa,GAAG,MAAM,OAAO,UAAU,CAAC;AAIpD,eAAO,MAAM,iBAAiB,QAAO,aAAa,EAOjD,CAAC;AAEF,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;qBAc5B,CAAC;AAEF;;;IAGI;AACJ,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;oBAQxB,CAAC;AAEF;;;;IAII;AACJ,eAAO,MAAM,kBAAkB,eAAgB,oBAAoB,SAElE,CAAC"}
@@ -1,33 +1,7 @@
1
1
  "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
25
2
  Object.defineProperty(exports, "__esModule", { value: true });
26
- const components = __importStar(require("./index"));
3
+ const index_1 = require("./index");
27
4
  const component_type_1 = require("./component-type");
28
- test.each(Object.entries(components))("validating meta definition of %s", (name, component) => {
29
- if (name === "default") {
30
- return;
31
- }
32
- component_type_1.WsComponentMeta.parse(component);
5
+ test.each((0, index_1.getComponentNames)())("validating meta definition of %s", (name) => {
6
+ component_type_1.WsComponentMeta.parse((0, index_1.getComponentMeta)(name));
33
7
  });
@@ -3,22 +3,22 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.componentsMeta = void 0;
7
- const body_props_json_1 = __importDefault(require("./body.props.json"));
8
- const button_props_json_1 = __importDefault(require("./button.props.json"));
9
- const bold_props_json_1 = __importDefault(require("./bold.props.json"));
10
- const box_props_json_1 = __importDefault(require("./box.props.json"));
11
- const form_props_json_1 = __importDefault(require("./form.props.json"));
12
- const heading_props_json_1 = __importDefault(require("./heading.props.json"));
13
- const input_props_json_1 = __importDefault(require("./input.props.json"));
14
- const italic_props_json_1 = __importDefault(require("./italic.props.json"));
15
- const superscript_props_json_1 = __importDefault(require("./superscript.props.json"));
16
- const subscript_props_json_1 = __importDefault(require("./subscript.props.json"));
17
- const link_props_json_1 = __importDefault(require("./link.props.json"));
18
- const paragraph_props_json_1 = __importDefault(require("./paragraph.props.json"));
19
- const span_props_json_1 = __importDefault(require("./span.props.json"));
20
- const text_block_props_json_1 = __importDefault(require("./text-block.props.json"));
21
- const image_props_json_1 = __importDefault(require("./image.props.json"));
6
+ exports.getComponentMetaProps = void 0;
7
+ const body_props_json_1 = __importDefault(require("./__generated__/body.props.json"));
8
+ const button_props_json_1 = __importDefault(require("./__generated__/button.props.json"));
9
+ const bold_props_json_1 = __importDefault(require("./__generated__/bold.props.json"));
10
+ const box_props_json_1 = __importDefault(require("./__generated__/box.props.json"));
11
+ const form_props_json_1 = __importDefault(require("./__generated__/form.props.json"));
12
+ const heading_props_json_1 = __importDefault(require("./__generated__/heading.props.json"));
13
+ const input_props_json_1 = __importDefault(require("./__generated__/input.props.json"));
14
+ const italic_props_json_1 = __importDefault(require("./__generated__/italic.props.json"));
15
+ const superscript_props_json_1 = __importDefault(require("./__generated__/superscript.props.json"));
16
+ const subscript_props_json_1 = __importDefault(require("./__generated__/subscript.props.json"));
17
+ const link_props_json_1 = __importDefault(require("./__generated__/link.props.json"));
18
+ const paragraph_props_json_1 = __importDefault(require("./__generated__/paragraph.props.json"));
19
+ const span_props_json_1 = __importDefault(require("./__generated__/span.props.json"));
20
+ const text_block_props_json_1 = __importDefault(require("./__generated__/text-block.props.json"));
21
+ const image_props_json_1 = __importDefault(require("./__generated__/image.props.json"));
22
22
  const meta = {
23
23
  Body: body_props_json_1.default,
24
24
  Button: button_props_json_1.default,
@@ -36,5 +36,7 @@ const meta = {
36
36
  TextBlock: text_block_props_json_1.default,
37
37
  Image: image_props_json_1.default,
38
38
  };
39
- // Probably better instead of JSON to generate ts with `as const`
40
- exports.componentsMeta = meta;
39
+ const getComponentMetaProps = (name) => {
40
+ return meta[name];
41
+ };
42
+ exports.getComponentMetaProps = getComponentMetaProps;
@@ -7442,21 +7442,6 @@ declare const meta: {
7442
7442
  required: boolean;
7443
7443
  type: string;
7444
7444
  };
7445
- quality: {
7446
- defaultValue: null;
7447
- required: boolean;
7448
- type: string;
7449
- };
7450
- loader: {
7451
- defaultValue: null;
7452
- required: boolean;
7453
- type: string;
7454
- };
7455
- optimize: {
7456
- defaultValue: null;
7457
- required: boolean;
7458
- type: string;
7459
- };
7460
7445
  };
7461
7446
  };
7462
7447
  declare type MetaProp = {
@@ -7474,6 +7459,6 @@ declare type MetaProp = {
7474
7459
  options: string[];
7475
7460
  };
7476
7461
  declare type MetaProps = Record<string, MetaProp>;
7477
- export declare const componentsMeta: Record<keyof typeof meta, MetaProps>;
7462
+ export declare const getComponentMetaProps: (name: keyof typeof meta) => MetaProps;
7478
7463
  export {};
7479
7464
  //# sourceMappingURL=meta.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"meta.d.ts","sourceRoot":"","sources":["../../../src/components/meta.ts"],"names":[],"mappings":"AAgBA,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgBA,CAAC;AAEX,aAAK,QAAQ,GACT;IACE,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,IAAI,GAAG,MAAM,CAAC;CAC7B,GACD;IACE,IAAI,EAAE,SAAS,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,IAAI,GAAG,OAAO,CAAC;CAC9B,GACD;IACE,IAAI,EACA,OAAO,GACP,cAAc,GACd,OAAO,GACP,cAAc,GACd,cAAc,GACd,QAAQ,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,IAAI,GAAG,MAAM,CAAC;IAC5B,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB,CAAC;AAEN,aAAK,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;AAE1C,eAAO,MAAM,qBAAqB,SAAU,MAAM,WAAW,KAAG,SAE/D,CAAC"}
@@ -56,6 +56,7 @@ export declare const categories: {
56
56
  };
57
57
  };
58
58
  export declare const propertyCategoryMap: {
59
+ [x: `--${string}`]: "position" | "layout" | "flexChild" | "gridChild" | "spacing" | "size" | "typography" | "backgrounds" | "borders" | "effects" | "other";
59
60
  accentColor: "position" | "layout" | "flexChild" | "gridChild" | "spacing" | "size" | "typography" | "backgrounds" | "borders" | "effects" | "other";
60
61
  alignContent: "position" | "layout" | "flexChild" | "gridChild" | "spacing" | "size" | "typography" | "backgrounds" | "borders" | "effects" | "other";
61
62
  alignItems: "position" | "layout" | "flexChild" | "gridChild" | "spacing" | "size" | "typography" | "backgrounds" | "borders" | "effects" | "other";
@@ -1 +1 @@
1
- {"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../../src/css/categories.ts"],"names":[],"mappings":"AA0MA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoCtB,CAAC;AAEF,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAE/B,CAAC;AAUF,oBAAY,QAAQ,GAAG,MAAM,OAAO,UAAU,CAAC"}
1
+ {"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../../src/css/categories.ts"],"names":[],"mappings":"AA0MA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoCtB,CAAC;AAEF,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAE/B,CAAC;AAUF,oBAAY,QAAQ,GAAG,MAAM,OAAO,UAAU,CAAC"}
@@ -16,7 +16,8 @@ const parseValue = (property, value) => {
16
16
  value,
17
17
  };
18
18
  }
19
- if (number === 0) {
19
+ if (number === 0 && property in css_data_1.properties) {
20
+ // @todo
20
21
  return css_data_1.properties[property].initial;
21
22
  }
22
23
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"get-browser-style.d.ts","sourceRoot":"","sources":["../../../src/css/get-browser-style.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,KAAK,EAGN,MAAM,wBAAwB,CAAC;AA4BhC,eAAO,MAAM,eAAe,aAAc,OAAO,KAAG,KAiBnD,CAAC"}
1
+ {"version":3,"file":"get-browser-style.d.ts","sourceRoot":"","sources":["../../../src/css/get-browser-style.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAoB,MAAM,wBAAwB,CAAC;AAgCtE,eAAO,MAAM,eAAe,aAAc,OAAO,KAAG,KAiBnD,CAAC"}
@@ -1,9 +1,9 @@
1
1
  import { CssRule } from "@webstudio-is/css-data";
2
2
  import { z } from "zod";
3
- import * as components from "../components";
3
+ import { ComponentName } from "../components";
4
4
  export declare type BaseInstance = {
5
5
  id: string;
6
- component: keyof typeof components;
6
+ component: ComponentName;
7
7
  cssRules: Array<CssRule>;
8
8
  };
9
9
  export declare type Instance = BaseInstance & {
@@ -1 +1 @@
1
- {"version":3,"file":"instance.d.ts","sourceRoot":"","sources":["../../../src/db/instance.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,UAAU,MAAM,eAAe,CAAC;AAI5C,oBAAY,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,OAAO,UAAU,CAAC;IACnC,QAAQ,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;CAC1B,CAAC;AAEF,oBAAY,QAAQ,GAAG,YAAY,GAAG;IACpC,QAAQ,EAAE,KAAK,CAAC,QAAQ,GAAG,MAAM,CAAC,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,cAAc,aAAc,QAAQ,KAAG,YAMnD,CAAC;AAEF,eAAO,MAAM,QAAQ,6CASG,CAAC"}
1
+ {"version":3,"file":"instance.d.ts","sourceRoot":"","sources":["../../../src/db/instance.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAI9C,oBAAY,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,aAAa,CAAC;IACzB,QAAQ,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;CAC1B,CAAC;AAEF,oBAAY,QAAQ,GAAG,YAAY,GAAG;IACpC,QAAQ,EAAE,KAAK,CAAC,QAAQ,GAAG,MAAM,CAAC,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,cAAc,aAAc,QAAQ,KAAG,YAMnD,CAAC;AAEF,eAAO,MAAM,QAAQ,6CASG,CAAC"}
package/lib/cjs/index.cjs CHANGED
@@ -26,12 +26,13 @@ var __importStar = (this && this.__importStar) || function (mod) {
26
26
  return result;
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.components = void 0;
29
+ exports.customComponents = void 0;
30
30
  __exportStar(require("./css"), exports);
31
31
  __exportStar(require("./tree"), exports);
32
- exports.components = __importStar(require("./components"));
32
+ __exportStar(require("./components"), exports);
33
33
  __exportStar(require("./components/meta"), exports);
34
34
  __exportStar(require("./user-props"), exports);
35
35
  __exportStar(require("./pubsub"), exports);
36
36
  __exportStar(require("./db"), exports);
37
- __exportStar(require("./remix"), exports);
37
+ __exportStar(require("./app"), exports);
38
+ exports.customComponents = __importStar(require("./app/custom-components"));
@@ -1,9 +1,10 @@
1
1
  export * from "./css";
2
2
  export * from "./tree";
3
- export * as components from "./components";
3
+ export * from "./components";
4
4
  export * from "./components/meta";
5
5
  export * from "./user-props";
6
6
  export * from "./pubsub";
7
7
  export * from "./db";
8
- export * from "./remix";
8
+ export * from "./app";
9
+ export * as customComponents from "./app/custom-components";
9
10
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,OAAO,KAAK,UAAU,MAAM,cAAc,CAAC;AAC3C,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,MAAM,CAAC;AACrB,cAAc,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,MAAM,CAAC;AACrB,cAAc,OAAO,CAAC;AACtB,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC"}
@@ -1,14 +1,42 @@
1
1
  "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
2
25
  Object.defineProperty(exports, "__esModule", { value: true });
3
26
  exports.InstanceRoot = void 0;
4
27
  const user_props_1 = require("../user-props/");
5
28
  const create_elements_tree_1 = require("./create-elements-tree");
6
29
  const wrapper_component_1 = require("./wrapper-component");
30
+ const components_1 = require("../components");
31
+ const customComponents = __importStar(require("../app/custom-components"));
32
+ const params_1 = require("../app/params");
7
33
  const InstanceRoot = ({ data, Component, }) => {
8
34
  if (data.tree === null) {
9
35
  throw new Error("Tree is null");
10
36
  }
11
37
  (0, user_props_1.useAllUserProps)(data.props);
38
+ (0, params_1.setParams)(data.params ?? null);
39
+ (0, components_1.registerComponents)(customComponents);
12
40
  return (0, create_elements_tree_1.createElementsTree)({
13
41
  instance: data.tree.root,
14
42
  Component: Component ?? wrapper_component_1.WrapperComponent,
@@ -3,11 +3,13 @@ import { WrapperComponent } from "./wrapper-component";
3
3
  import type { Asset } from "@webstudio-is/asset-uploader";
4
4
  import { type ComponentProps } from "react";
5
5
  import type { Breakpoint } from "@webstudio-is/css-data";
6
+ import { type Params } from "../app/params";
6
7
  export declare type Data = {
7
8
  tree: Tree | null;
8
9
  breakpoints: Array<Breakpoint>;
9
10
  props: Array<InstanceProps>;
10
11
  assets: Array<Asset>;
12
+ params?: Params;
11
13
  };
12
14
  declare type RootProps = {
13
15
  data: Data;
@@ -1 +1 @@
1
- {"version":3,"file":"root.d.ts","sourceRoot":"","sources":["../../../src/tree/root.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEzD,oBAAY,IAAI,GAAG;IACjB,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,WAAW,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IAC/B,KAAK,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC;IAC5B,MAAM,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC;CACtB,CAAC;AAEF,aAAK,SAAS,GAAG;IACf,IAAI,EAAE,IAAI,CAAC;IACX,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,CAAC,OAAO,gBAAgB,CAAC,KAAK,GAAG,CAAC,OAAO,CAAC;CAC7E,CAAC;AAEF,eAAO,MAAM,YAAY,yBAGtB,SAAS,KAAG,WAAW,GAAG,IAS5B,CAAC"}
1
+ {"version":3,"file":"root.d.ts","sourceRoot":"","sources":["../../../src/tree/root.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAGzD,OAAO,EAAa,KAAK,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvD,oBAAY,IAAI,GAAG;IACjB,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,WAAW,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IAC/B,KAAK,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC;IAC5B,MAAM,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,aAAK,SAAS,GAAG;IACf,IAAI,EAAE,IAAI,CAAC;IACX,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,CAAC,OAAO,gBAAgB,CAAC,KAAK,GAAG,CAAC,OAAO,CAAC;CAC7E,CAAC;AAEF,eAAO,MAAM,YAAY,yBAGtB,SAAS,KAAG,WAAW,GAAG,IAa5B,CAAC"}
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  export declare const SessionStoragePolyfill: () => JSX.Element;
2
3
  //# sourceMappingURL=session-storage-polyfill.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"session-storage-polyfill.d.ts","sourceRoot":"","sources":["../../../src/tree/session-storage-polyfill.tsx"],"names":[],"mappings":"AA4CA,eAAO,MAAM,sBAAsB,mBAKlC,CAAC"}
1
+ {"version":3,"file":"session-storage-polyfill.d.ts","sourceRoot":"","sources":["../../../src/tree/session-storage-polyfill.tsx"],"names":[],"mappings":";AA4CA,eAAO,MAAM,sBAAsB,mBAKlC,CAAC"}
@@ -1,32 +1,9 @@
1
1
  "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
25
2
  Object.defineProperty(exports, "__esModule", { value: true });
26
3
  exports.idAttribute = exports.WrapperComponent = exports.renderWrapperComponentChildren = void 0;
27
4
  const jsx_runtime_1 = require("react/jsx-runtime");
28
5
  const react_1 = require("react");
29
- const components = __importStar(require("../components"));
6
+ const components_1 = require("../components");
30
7
  const use_user_props_1 = require("../user-props/use-user-props");
31
8
  const renderText = (text) => {
32
9
  const lines = text.split("\n");
@@ -44,7 +21,7 @@ const renderWrapperComponentChildren = (children) => {
44
21
  exports.renderWrapperComponentChildren = renderWrapperComponentChildren;
45
22
  const WrapperComponent = ({ instance, onChangeChildren, // prevent it from passing to sdk component
46
23
  children, ...rest }) => {
47
- const { Component } = components[instance.component];
24
+ const Component = (0, components_1.getComponent)(instance.component);
48
25
  const userProps = (0, use_user_props_1.useUserProps)(instance.id);
49
26
  const props = { ...userProps, ...rest, [exports.idAttribute]: instance.id };
50
27
  return ((0, jsx_runtime_1.jsx)(Component, { ...props, children: (0, exports.renderWrapperComponentChildren)(children) }));
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { Instance } from "../db";
2
3
  import type { OnChangeChildren } from "./create-elements-tree";
3
4
  export declare const renderWrapperComponentChildren: (children: Array<JSX.Element | string> | undefined) => Array<JSX.Element | string | Array<JSX.Element | string>> | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"wrapper-component.d.ts","sourceRoot":"","sources":["../../../src/tree/wrapper-component.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAGtC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAY/D,eAAO,MAAM,8BAA8B,aAC/B,MAAM,WAAW,GAAG,MAAM,CAAC,GAAG,SAAS,KAChD,MAAM,WAAW,GAAG,MAAM,GAAG,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,GAAG,SAO9D,CAAC;AAEF,aAAK,qBAAqB,GAAG;IAC3B,QAAQ,EAAE,QAAQ,CAAC;IACnB,QAAQ,EAAE,KAAK,CAAC,GAAG,CAAC,OAAO,GAAG,MAAM,CAAC,CAAC;IACtC,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;CACrC,CAAC;AAEF,eAAO,MAAM,gBAAgB,sDAK1B,qBAAqB,gBAOvB,CAAC;AAEF,eAAO,MAAM,WAAW,eAAe,CAAC"}
1
+ {"version":3,"file":"wrapper-component.d.ts","sourceRoot":"","sources":["../../../src/tree/wrapper-component.tsx"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAGtC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAY/D,eAAO,MAAM,8BAA8B,aAC/B,MAAM,WAAW,GAAG,MAAM,CAAC,GAAG,SAAS,KAChD,MAAM,WAAW,GAAG,MAAM,GAAG,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,GAAG,SAO9D,CAAC;AAEF,aAAK,qBAAqB,GAAG;IAC3B,QAAQ,EAAE,QAAQ,CAAC;IACnB,QAAQ,EAAE,KAAK,CAAC,GAAG,CAAC,OAAO,GAAG,MAAM,CAAC,CAAC;IACtC,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;CACrC,CAAC;AAEF,eAAO,MAAM,gBAAgB,sDAK1B,qBAAqB,gBAOvB,CAAC;AAEF,eAAO,MAAM,WAAW,eAAe,CAAC"}
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.useUserPropsAsset = void 0;
4
+ const react_1 = require("react");
5
+ const all_user_props_1 = require("./all-user-props");
6
+ /**
7
+ * Get asset for prop, like src on the Image component
8
+ */
9
+ const useUserPropsAsset = (instanceId, propName) => {
10
+ const [allUserProps] = (0, all_user_props_1.useAllUserProps)();
11
+ const propsData = allUserProps[instanceId];
12
+ const asset = (0, react_1.useMemo)(() => {
13
+ if (propsData == null)
14
+ return null;
15
+ const prop = propsData.props.find((prop) => prop.prop === propName);
16
+ if (prop == null)
17
+ return null;
18
+ return prop.asset ?? null;
19
+ }, [propName, propsData]);
20
+ return asset;
21
+ };
22
+ exports.useUserPropsAsset = useUserPropsAsset;