@webstudio-is/react-sdk 0.7.3 → 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 (142) 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/italic.ws.cjs +7 -0
  57. package/lib/cjs/components/italic.ws.d.ts.map +1 -1
  58. package/lib/cjs/components/meta.cjs +20 -18
  59. package/lib/cjs/components/meta.d.ts +1 -16
  60. package/lib/cjs/components/meta.d.ts.map +1 -1
  61. package/lib/cjs/css/categories.d.ts +1 -0
  62. package/lib/cjs/css/categories.d.ts.map +1 -1
  63. package/lib/cjs/css/get-browser-style.cjs +2 -1
  64. package/lib/cjs/css/get-browser-style.d.ts.map +1 -1
  65. package/lib/cjs/db/instance.d.ts +2 -2
  66. package/lib/cjs/db/instance.d.ts.map +1 -1
  67. package/lib/cjs/index.cjs +4 -3
  68. package/lib/cjs/index.d.ts +3 -2
  69. package/lib/cjs/index.d.ts.map +1 -1
  70. package/lib/cjs/tree/root.cjs +28 -0
  71. package/lib/cjs/tree/root.d.ts +2 -0
  72. package/lib/cjs/tree/root.d.ts.map +1 -1
  73. package/lib/cjs/tree/session-storage-polyfill.d.ts +1 -0
  74. package/lib/cjs/tree/session-storage-polyfill.d.ts.map +1 -1
  75. package/lib/cjs/tree/wrapper-component.cjs +2 -25
  76. package/lib/cjs/tree/wrapper-component.d.ts +1 -0
  77. package/lib/cjs/tree/wrapper-component.d.ts.map +1 -1
  78. package/lib/cjs/user-props/use-user-props-asset.cjs +22 -0
  79. package/lib/cjs/user-props/use-user-props-asset.d.ts +8 -0
  80. package/lib/cjs/user-props/use-user-props-asset.d.ts.map +1 -0
  81. package/lib/cjs/user-props/use-user-props.cjs +2 -12
  82. package/lib/cjs/user-props/use-user-props.d.ts.map +1 -1
  83. package/lib/components/{body.props.json → __generated__/body.props.json} +0 -0
  84. package/lib/components/{bold.props.json → __generated__/bold.props.json} +0 -0
  85. package/lib/components/{box.props.json → __generated__/box.props.json} +0 -0
  86. package/lib/components/{button.props.json → __generated__/button.props.json} +0 -0
  87. package/lib/components/{form.props.json → __generated__/form.props.json} +0 -0
  88. package/lib/components/{heading.props.json → __generated__/heading.props.json} +0 -0
  89. package/lib/{cjs/components → components/__generated__}/image.props.json +0 -15
  90. package/lib/components/{input.props.json → __generated__/input.props.json} +0 -0
  91. package/lib/components/{italic.props.json → __generated__/italic.props.json} +0 -0
  92. package/lib/components/{link.props.json → __generated__/link.props.json} +0 -0
  93. package/lib/components/{paragraph.props.json → __generated__/paragraph.props.json} +0 -0
  94. package/lib/components/{span.props.json → __generated__/span.props.json} +0 -0
  95. package/lib/components/{subscript.props.json → __generated__/subscript.props.json} +0 -0
  96. package/lib/components/{superscript.props.json → __generated__/superscript.props.json} +0 -0
  97. package/lib/components/{text-block.props.json → __generated__/text-block.props.json} +0 -0
  98. package/lib/components/index.d.ts +89 -15
  99. package/lib/components/index.d.ts.map +1 -1
  100. package/lib/components/index.js +70 -15
  101. package/lib/components/index.test.js +3 -6
  102. package/lib/components/italic.ws.d.ts.map +1 -1
  103. package/lib/components/italic.ws.js +7 -0
  104. package/lib/components/meta.d.ts +1 -16
  105. package/lib/components/meta.d.ts.map +1 -1
  106. package/lib/components/meta.js +18 -17
  107. package/lib/css/categories.d.ts +1 -0
  108. package/lib/css/categories.d.ts.map +1 -1
  109. package/lib/css/get-browser-style.d.ts.map +1 -1
  110. package/lib/css/get-browser-style.js +2 -1
  111. package/lib/db/instance.d.ts +2 -2
  112. package/lib/db/instance.d.ts.map +1 -1
  113. package/lib/index.d.ts +3 -2
  114. package/lib/index.d.ts.map +1 -1
  115. package/lib/index.js +3 -2
  116. package/lib/tree/root.d.ts +2 -0
  117. package/lib/tree/root.d.ts.map +1 -1
  118. package/lib/tree/root.js +5 -0
  119. package/lib/tree/session-storage-polyfill.d.ts +1 -0
  120. package/lib/tree/session-storage-polyfill.d.ts.map +1 -1
  121. package/lib/tree/wrapper-component.d.ts +1 -0
  122. package/lib/tree/wrapper-component.d.ts.map +1 -1
  123. package/lib/tree/wrapper-component.js +2 -2
  124. package/lib/tsconfig.tsbuildinfo +1 -1
  125. package/lib/user-props/use-user-props-asset.d.ts +8 -0
  126. package/lib/user-props/use-user-props-asset.d.ts.map +1 -0
  127. package/lib/user-props/use-user-props-asset.js +18 -0
  128. package/lib/user-props/use-user-props.d.ts.map +1 -1
  129. package/lib/user-props/use-user-props.js +3 -13
  130. package/package.json +7 -8
  131. package/lib/arg-types/utils.d.ts +0 -10
  132. package/lib/arg-types/utils.d.ts.map +0 -1
  133. package/lib/arg-types/utils.js +0 -83
  134. package/lib/cjs/arg-types/utils.cjs +0 -88
  135. package/lib/cjs/arg-types/utils.d.ts +0 -10
  136. package/lib/cjs/arg-types/utils.d.ts.map +0 -1
  137. package/lib/cjs/remix/handle-request.server.d.ts.map +0 -1
  138. package/lib/cjs/remix/index.d.ts.map +0 -1
  139. package/lib/cjs/remix/root.d.ts.map +0 -1
  140. package/lib/remix/handle-request.server.d.ts.map +0 -1
  141. package/lib/remix/index.d.ts.map +0 -1
  142. package/lib/remix/root.d.ts.map +0 -1
@@ -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;
@@ -0,0 +1,8 @@
1
+ import { type Instance } from "../db";
2
+ import { type UserProp } from "./schema";
3
+ import type { Asset } from "@webstudio-is/asset-uploader";
4
+ /**
5
+ * Get asset for prop, like src on the Image component
6
+ */
7
+ export declare const useUserPropsAsset: (instanceId: Instance["id"], propName: UserProp["prop"]) => Asset | null;
8
+ //# sourceMappingURL=use-user-props-asset.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-user-props-asset.d.ts","sourceRoot":"","sources":["../../../src/user-props/use-user-props-asset.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEzC,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAE1D;;GAEG;AACH,eAAO,MAAM,iBAAiB,eAChB,QAAQ,CAAC,IAAI,CAAC,YAChB,QAAQ,CAAC,MAAM,CAAC,KACzB,KAAK,GAAG,IAaV,CAAC"}
@@ -10,24 +10,14 @@ const all_user_props_1 = require("./all-user-props");
10
10
  const useUserProps = (instanceId) => {
11
11
  const [allUserProps] = (0, all_user_props_1.useAllUserProps)();
12
12
  const propsData = allUserProps[instanceId];
13
- const initialUserProps = (0, react_1.useMemo)(() => {
14
- if (propsData === undefined)
13
+ const props = (0, react_1.useMemo)(() => {
14
+ if (propsData == null)
15
15
  return {};
16
16
  return propsData.props.reduce((props, { prop, value }) => {
17
17
  props[prop] = value;
18
18
  return props;
19
19
  }, {});
20
20
  }, [propsData]);
21
- const [props, setProps] = (0, react_1.useState)(initialUserProps);
22
- (0, react_1.useEffect)(() => {
23
- if (propsData == undefined)
24
- return;
25
- const nextProps = {};
26
- for (const prop of propsData.props) {
27
- nextProps[prop.prop] = prop.value;
28
- }
29
- setProps(nextProps);
30
- }, [propsData]);
31
21
  return props;
32
22
  };
33
23
  exports.useUserProps = useUserProps;
@@ -1 +1 @@
1
- {"version":3,"file":"use-user-props.d.ts","sourceRoot":"","sources":["../../../src/user-props/use-user-props.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,aAAK,SAAS,GAAG;IAAE,CAAC,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;CAAE,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,YAAY,eAAgB,QAAQ,CAAC,IAAI,CAAC,cAwBtD,CAAC"}
1
+ {"version":3,"file":"use-user-props.d.ts","sourceRoot":"","sources":["../../../src/user-props/use-user-props.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,aAAK,SAAS,GAAG;IAAE,CAAC,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;CAAE,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,YAAY,eAAgB,QAAQ,CAAC,IAAI,CAAC,cAatD,CAAC"}
@@ -556,20 +556,5 @@
556
556
  "defaultValue": null,
557
557
  "required": false,
558
558
  "type": "text"
559
- },
560
- "quality": {
561
- "defaultValue": null,
562
- "required": false,
563
- "type": "number"
564
- },
565
- "loader": {
566
- "defaultValue": null,
567
- "required": false,
568
- "type": "text"
569
- },
570
- "optimize": {
571
- "defaultValue": null,
572
- "required": false,
573
- "type": "boolean"
574
559
  }
575
560
  }
@@ -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,15 +1,70 @@
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
+ import Body from "./body.ws";
2
+ import Box from "./box.ws";
3
+ import TextBlock from "./text-block.ws";
4
+ import Heading from "./heading.ws";
5
+ import Paragraph from "./paragraph.ws";
6
+ import Link from "./link.ws";
7
+ import Span from "./span.ws";
8
+ import Bold from "./bold.ws";
9
+ import Italic from "./italic.ws";
10
+ import Superscript from "./superscript.ws";
11
+ import Subscript from "./subscript.ws";
12
+ import Button from "./button.ws";
13
+ import Input from "./input.ws";
14
+ import Form from "./form.ws";
15
+ import Image from "./image.ws";
16
+ const components = {
17
+ Body,
18
+ Box,
19
+ TextBlock,
20
+ Heading,
21
+ Paragraph,
22
+ Link,
23
+ Span,
24
+ Bold,
25
+ Italic,
26
+ Superscript,
27
+ Subscript,
28
+ Button,
29
+ Input,
30
+ Form,
31
+ Image,
32
+ };
33
+ let registeredComponents = null;
34
+ const componentNames = Object.keys(components);
35
+ export const getComponentNames = () => {
36
+ const uniqueNames = new Set([
37
+ ...componentNames,
38
+ ...Object.keys(registeredComponents || {}),
39
+ ]);
40
+ return [...uniqueNames.values()];
41
+ };
42
+ export const getComponentMeta = (name) => {
43
+ if (registeredComponents != null &&
44
+ name in registeredComponents &&
45
+ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
46
+ registeredComponents[name].meta != null) {
47
+ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
48
+ return { ...components[name], ...registeredComponents[name].meta };
49
+ }
50
+ return components[name];
51
+ };
52
+ /**
53
+ * @todo Remove Component from meta and read directly (via import),
54
+ * as meta information is not needed during production render.
55
+ **/
56
+ export const getComponent = (name) => {
57
+ return registeredComponents != null && name in registeredComponents
58
+ ? // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
59
+ registeredComponents[name]
60
+ .Component
61
+ : components[name].Component;
62
+ };
63
+ /**
64
+ * @todo: Allow register any component.
65
+ * Now we can register only existings Components, as all our type system would
66
+ * break otherwise, see getComponent etc. So its overwriteComponent now
67
+ **/
68
+ export const registerComponents = (components) => {
69
+ registeredComponents = components;
70
+ };
@@ -1,8 +1,5 @@
1
- import * as components from "./index";
1
+ import { getComponentNames, getComponentMeta } from "./index";
2
2
  import { WsComponentMeta } from "./component-type";
3
- test.each(Object.entries(components))("validating meta definition of %s", (name, component) => {
4
- if (name === "default") {
5
- return;
6
- }
7
- WsComponentMeta.parse(component);
3
+ test.each(getComponentNames())("validating meta definition of %s", (name) => {
4
+ WsComponentMeta.parse(getComponentMeta(name));
8
5
  });
@@ -1 +1 @@
1
- {"version":3,"file":"italic.ws.d.ts","sourceRoot":"","sources":["../../src/components/italic.ws.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,QAAA,MAAM,IAAI,EAAE,eAAe,CAAC,OAAO,MAAM,CAQxC,CAAC;AAEF,eAAe,IAAI,CAAC"}
1
+ {"version":3,"file":"italic.ws.d.ts","sourceRoot":"","sources":["../../src/components/italic.ws.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AASlC,QAAA,MAAM,IAAI,EAAE,eAAe,CAAC,OAAO,MAAM,CASxC,CAAC;AAEF,eAAe,IAAI,CAAC"}
@@ -1,8 +1,15 @@
1
1
  import { FontItalicIcon } from "@webstudio-is/icons";
2
2
  import { Italic } from "./italic";
3
+ const defaultStyle = {
4
+ fontStyle: {
5
+ type: "keyword",
6
+ value: "italic",
7
+ },
8
+ };
3
9
  const meta = {
4
10
  Icon: FontItalicIcon,
5
11
  Component: Italic,
12
+ defaultStyle,
6
13
  canAcceptChildren: false,
7
14
  isContentEditable: false,
8
15
  isInlineOnly: true,
@@ -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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AY,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"}
@@ -1,18 +1,18 @@
1
- import Body from "./body.props.json";
2
- import Button from "./button.props.json";
3
- import Bold from "./bold.props.json";
4
- import Box from "./box.props.json";
5
- import Form from "./form.props.json";
6
- import Heading from "./heading.props.json";
7
- import Input from "./input.props.json";
8
- import Italic from "./italic.props.json";
9
- import Superscript from "./superscript.props.json";
10
- import Subscript from "./subscript.props.json";
11
- import Link from "./link.props.json";
12
- import Paragraph from "./paragraph.props.json";
13
- import Span from "./span.props.json";
14
- import TextBlock from "./text-block.props.json";
15
- import Image from "./image.props.json";
1
+ import Body from "./__generated__/body.props.json";
2
+ import Button from "./__generated__/button.props.json";
3
+ import Bold from "./__generated__/bold.props.json";
4
+ import Box from "./__generated__/box.props.json";
5
+ import Form from "./__generated__/form.props.json";
6
+ import Heading from "./__generated__/heading.props.json";
7
+ import Input from "./__generated__/input.props.json";
8
+ import Italic from "./__generated__/italic.props.json";
9
+ import Superscript from "./__generated__/superscript.props.json";
10
+ import Subscript from "./__generated__/subscript.props.json";
11
+ import Link from "./__generated__/link.props.json";
12
+ import Paragraph from "./__generated__/paragraph.props.json";
13
+ import Span from "./__generated__/span.props.json";
14
+ import TextBlock from "./__generated__/text-block.props.json";
15
+ import Image from "./__generated__/image.props.json";
16
16
  const meta = {
17
17
  Body,
18
18
  Button,
@@ -30,5 +30,6 @@ const meta = {
30
30
  TextBlock,
31
31
  Image,
32
32
  };
33
- // Probably better instead of JSON to generate ts with `as const`
34
- export const componentsMeta = meta;
33
+ export const getComponentMetaProps = (name) => {
34
+ return meta[name];
35
+ };
@@ -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"}
@@ -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"}
@@ -13,7 +13,8 @@ const parseValue = (property, value) => {
13
13
  value,
14
14
  };
15
15
  }
16
- if (number === 0) {
16
+ if (number === 0 && property in properties) {
17
+ // @todo
17
18
  return properties[property].initial;
18
19
  }
19
20
  return {
@@ -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 & {