@webstudio-is/sdk-components-react 0.196.0 → 0.198.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 (172) hide show
  1. package/lib/__generated__/image.props.js +1 -0
  2. package/lib/__generated__/vimeo-preview-image.props.js +6 -1
  3. package/lib/__generated__/vimeo.props.js +4 -5
  4. package/lib/__generated__/youtube.props.js +665 -0
  5. package/lib/blockquote.template.js +11 -0
  6. package/lib/blockquote.ws.js +5 -15
  7. package/lib/body.ws.js +1 -1
  8. package/lib/bold.ws.js +1 -1
  9. package/lib/box.ws.js +1 -1
  10. package/lib/button.ws.js +1 -1
  11. package/lib/checkbox.template.js +14 -0
  12. package/lib/checkbox.ws.js +5 -25
  13. package/lib/code-text.ws.js +1 -1
  14. package/lib/components.js +35 -33
  15. package/lib/content-embed.template.js +83 -0
  16. package/lib/form.ws.js +1 -1
  17. package/lib/heading.template.js +11 -0
  18. package/lib/heading.ws.js +12 -22
  19. package/lib/image.ws.js +17 -22
  20. package/lib/input.ws.js +1 -1
  21. package/lib/italic.ws.js +1 -1
  22. package/lib/label.template.js +10 -0
  23. package/lib/label.ws.js +13 -28
  24. package/lib/link.template.js +11 -0
  25. package/lib/link.ws.js +3 -13
  26. package/lib/list-item.template.js +11 -0
  27. package/lib/list-item.ws.js +8 -18
  28. package/lib/list.ws.js +1 -1
  29. package/lib/markdown-embed.js +10 -5
  30. package/lib/markdown-embed.template.js +75 -0
  31. package/lib/markdown-embed.ws.js +9 -87
  32. package/lib/metas.js +59 -59
  33. package/lib/option.ws.js +4 -5
  34. package/lib/paragraph.template.js +11 -0
  35. package/lib/paragraph.ws.js +10 -20
  36. package/lib/props.js +32 -30
  37. package/lib/radio-button.template.js +14 -0
  38. package/lib/radio-button.ws.js +7 -27
  39. package/lib/rich-text-link.ws.js +3 -5
  40. package/lib/select.template.js +16 -0
  41. package/lib/select.ws.js +11 -63
  42. package/lib/separator.ws.js +1 -1
  43. package/lib/span.ws.js +1 -1
  44. package/lib/subscript.ws.js +1 -1
  45. package/lib/superscript.ws.js +1 -1
  46. package/lib/templates.js +34 -6
  47. package/lib/text.template.js +11 -0
  48. package/lib/text.ws.js +9 -25
  49. package/lib/textarea.ws.js +1 -1
  50. package/lib/time.ws.js +1 -1
  51. package/lib/types/__generated__/blockquote.props.d.ts +1 -1
  52. package/lib/types/__generated__/body.props.d.ts +1 -1
  53. package/lib/types/__generated__/bold.props.d.ts +1 -1
  54. package/lib/types/__generated__/box.props.d.ts +1 -1
  55. package/lib/types/__generated__/button.props.d.ts +1 -1
  56. package/lib/types/__generated__/checkbox.props.d.ts +1 -1
  57. package/lib/types/__generated__/code-text.props.d.ts +1 -1
  58. package/lib/types/__generated__/form.props.d.ts +1 -1
  59. package/lib/types/__generated__/fragment.props.d.ts +1 -1
  60. package/lib/types/__generated__/heading.props.d.ts +1 -1
  61. package/lib/types/__generated__/html-embed.props.d.ts +1 -1
  62. package/lib/types/__generated__/image.props.d.ts +1 -1
  63. package/lib/types/__generated__/input.props.d.ts +1 -1
  64. package/lib/types/__generated__/italic.props.d.ts +1 -1
  65. package/lib/types/__generated__/label.props.d.ts +1 -1
  66. package/lib/types/__generated__/link.props.d.ts +1 -1
  67. package/lib/types/__generated__/list-item.props.d.ts +1 -1
  68. package/lib/types/__generated__/list.props.d.ts +1 -1
  69. package/lib/types/__generated__/markdown-embed.props.d.ts +1 -1
  70. package/lib/types/__generated__/option.props.d.ts +1 -1
  71. package/lib/types/__generated__/paragraph.props.d.ts +1 -1
  72. package/lib/types/__generated__/radio-button.props.d.ts +1 -1
  73. package/lib/types/__generated__/rich-text-link.props.d.ts +1 -1
  74. package/lib/types/__generated__/select.props.d.ts +1 -1
  75. package/lib/types/__generated__/separator.props.d.ts +1 -1
  76. package/lib/types/__generated__/slot.props.d.ts +1 -1
  77. package/lib/types/__generated__/span.props.d.ts +1 -1
  78. package/lib/types/__generated__/subscript.props.d.ts +1 -1
  79. package/lib/types/__generated__/superscript.props.d.ts +1 -1
  80. package/lib/types/__generated__/text.props.d.ts +1 -1
  81. package/lib/types/__generated__/textarea.props.d.ts +1 -1
  82. package/lib/types/__generated__/time.props.d.ts +1 -1
  83. package/lib/types/__generated__/vimeo-play-button.props.d.ts +1 -1
  84. package/lib/types/__generated__/vimeo-preview-image.props.d.ts +1 -1
  85. package/lib/types/__generated__/vimeo-spinner.props.d.ts +1 -1
  86. package/lib/types/__generated__/vimeo.props.d.ts +1 -1
  87. package/lib/types/__generated__/webhook-form.props.d.ts +1 -1
  88. package/lib/types/__generated__/xml-node.props.d.ts +1 -1
  89. package/lib/types/__generated__/xml-time.props.d.ts +1 -1
  90. package/lib/types/__generated__/youtube.props.d.ts +2 -0
  91. package/lib/types/blockquote.template.d.ts +2 -0
  92. package/lib/types/blockquote.ws.d.ts +1 -1
  93. package/lib/types/body.ws.d.ts +1 -1
  94. package/lib/types/bold.ws.d.ts +1 -1
  95. package/lib/types/box.ws.d.ts +1 -1
  96. package/lib/types/button.ws.d.ts +1 -1
  97. package/lib/types/checkbox.d.ts +1 -1
  98. package/lib/types/checkbox.template.d.ts +2 -0
  99. package/lib/types/checkbox.ws.d.ts +1 -1
  100. package/lib/types/code-text.ws.d.ts +1 -1
  101. package/lib/types/components.d.ts +1 -0
  102. package/lib/types/content-embed.template.d.ts +2 -0
  103. package/lib/types/form.ws.d.ts +1 -1
  104. package/lib/types/fragment.ws.d.ts +1 -1
  105. package/lib/types/heading.template.d.ts +2 -0
  106. package/lib/types/heading.ws.d.ts +1 -1
  107. package/lib/types/html-embed.ws.d.ts +1 -1
  108. package/lib/types/image.ws.d.ts +1 -9
  109. package/lib/types/input.ws.d.ts +1 -1
  110. package/lib/types/italic.ws.d.ts +1 -1
  111. package/lib/types/label.template.d.ts +2 -0
  112. package/lib/types/label.ws.d.ts +1 -1
  113. package/lib/types/link.template.d.ts +2 -0
  114. package/lib/types/link.ws.d.ts +1 -1
  115. package/lib/types/list-item.template.d.ts +2 -0
  116. package/lib/types/list-item.ws.d.ts +1 -1
  117. package/lib/types/list.ws.d.ts +1 -1
  118. package/lib/types/markdown-embed.template.d.ts +2 -0
  119. package/lib/types/markdown-embed.ws.d.ts +1 -1
  120. package/lib/types/metas.d.ts +1 -1
  121. package/lib/types/option.ws.d.ts +1 -1
  122. package/lib/types/paragraph.template.d.ts +2 -0
  123. package/lib/types/paragraph.ws.d.ts +1 -1
  124. package/lib/types/props.d.ts +1 -0
  125. package/lib/types/radio-button.d.ts +1 -1
  126. package/lib/types/radio-button.template.d.ts +2 -0
  127. package/lib/types/radio-button.ws.d.ts +1 -1
  128. package/lib/types/rich-text-link.ws.d.ts +1 -1
  129. package/lib/types/select.template.d.ts +2 -0
  130. package/lib/types/select.ws.d.ts +1 -1
  131. package/lib/types/separator.ws.d.ts +1 -1
  132. package/lib/types/slot.ws.d.ts +1 -1
  133. package/lib/types/span.ws.d.ts +1 -1
  134. package/lib/types/subscript.ws.d.ts +1 -1
  135. package/lib/types/superscript.ws.d.ts +1 -1
  136. package/lib/types/templates.d.ts +14 -0
  137. package/lib/types/text.template.d.ts +2 -0
  138. package/lib/types/text.ws.d.ts +1 -1
  139. package/lib/types/textarea.ws.d.ts +1 -1
  140. package/lib/types/time.ws.d.ts +1 -1
  141. package/lib/types/vimeo-play-button.ws.d.ts +1 -1
  142. package/lib/types/vimeo-preview-image.d.ts +21 -21
  143. package/lib/types/vimeo-preview-image.ws.d.ts +1 -1
  144. package/lib/types/vimeo-spinner.ws.d.ts +1 -1
  145. package/lib/types/vimeo.d.ts +12 -2
  146. package/lib/types/vimeo.ws.d.ts +1 -1
  147. package/lib/types/webhook-form.d.ts +1 -0
  148. package/lib/types/webhook-form.template.d.ts +2 -0
  149. package/lib/types/webhook-form.ws.d.ts +1 -1
  150. package/lib/types/xml-node.ws.d.ts +1 -1
  151. package/lib/types/xml-time.ws.d.ts +1 -1
  152. package/lib/types/youtube.d.ts +143 -0
  153. package/lib/types/youtube.template.d.ts +2 -0
  154. package/lib/types/youtube.ws.d.ts +3 -0
  155. package/lib/vimeo-play-button.ws.js +8 -8
  156. package/lib/vimeo-preview-image.ws.js +17 -9
  157. package/lib/vimeo-spinner.ws.js +8 -8
  158. package/lib/vimeo.js +88 -87
  159. package/lib/vimeo.template.js +17 -16
  160. package/lib/vimeo.ws.js +8 -7
  161. package/lib/webhook-form.template.js +49 -0
  162. package/lib/webhook-form.ws.js +17 -118
  163. package/lib/xml-node.js +18 -14
  164. package/lib/xml-node.ws.js +4 -5
  165. package/lib/xml-time.ws.js +4 -5
  166. package/lib/youtube.js +200 -0
  167. package/lib/youtube.template.js +97 -0
  168. package/lib/youtube.ws.js +51 -0
  169. package/package.json +14 -11
  170. package/lib/content-embed.ws.js +0 -77
  171. package/lib/types/__generated__/local-date.props.d.ts +0 -2
  172. package/lib/types/content-embed.ws.d.ts +0 -2
@@ -1,5 +1,5 @@
1
- import { BlockquoteIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
1
+ import { BlockquoteIcon as t } from "@webstudio-is/icons/svg";
2
+ import { defaultStates as e } from "@webstudio-is/sdk";
3
3
  import { props as p } from "./__generated__/blockquote.props.js";
4
4
  const r = {
5
5
  blockquote: [
@@ -49,20 +49,10 @@ const r = {
49
49
  }
50
50
  ]
51
51
  }, i = {
52
- category: "typography",
53
52
  type: "container",
54
- description: "Use to style a quote from an external source like an article or book.",
55
- icon: e,
56
- states: t,
57
- presetStyle: r,
58
- order: 3,
59
- template: [
60
- {
61
- type: "instance",
62
- component: "Blockquote",
63
- children: []
64
- }
65
- ]
53
+ icon: t,
54
+ states: e,
55
+ presetStyle: r
66
56
  }, n = {
67
57
  props: p,
68
58
  initialProps: ["id", "className", "cite"]
package/lib/body.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { BodyIcon as o } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
3
  import { body as e } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as r } from "./__generated__/body.props.js";
5
5
  const a = {
package/lib/bold.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { BoldIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as o } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as o } from "@webstudio-is/sdk";
3
3
  import { b as e } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as r } from "./__generated__/bold.props.js";
5
5
  const p = {
package/lib/box.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { BoxIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as e } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as e } from "@webstudio-is/sdk";
3
3
  import { div as o, address as r, article as a, aside as i, figure as n, footer as s, header as c, main as p, nav as d, section as m } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as f } from "./__generated__/box.props.js";
5
5
  const g = {
package/lib/button.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { ButtonElementIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as e } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as e } from "@webstudio-is/sdk";
3
3
  import { button as o } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as n } from "./__generated__/button.props.js";
5
5
  const a = {
@@ -0,0 +1,14 @@
1
+ import { jsxs as r, jsx as o } from "react/jsx-runtime";
2
+ import { $ as e, PlaceholderValue as c } from "@webstudio-is/template";
3
+ const l = {
4
+ category: "forms",
5
+ description: "Use within a form to allow your users to toggle between checked and not checked. Group checkboxes by matching their “Name” properties. Unlike radios, any number of checkboxes in a group can be checked.",
6
+ order: 6,
7
+ template: /* @__PURE__ */ r(e.Label, { "ws:label": "Checkbox Field", children: [
8
+ /* @__PURE__ */ o(e.Checkbox, {}),
9
+ /* @__PURE__ */ o(e.Text, { "ws:label": "Checkbox Label", tag: "span", children: new c("Checkbox") })
10
+ ] })
11
+ };
12
+ export {
13
+ l as meta
14
+ };
@@ -1,8 +1,8 @@
1
1
  import { CheckboxCheckedIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
3
  import { checkbox as o } from "@webstudio-is/sdk/normalize.css";
4
- import { props as r } from "./__generated__/checkbox.props.js";
5
- const a = {
4
+ import { props as l } from "./__generated__/checkbox.props.js";
5
+ const r = {
6
6
  input: [
7
7
  ...o,
8
8
  {
@@ -11,16 +11,13 @@ const a = {
11
11
  }
12
12
  ]
13
13
  }, s = {
14
- category: "forms",
15
14
  constraints: {
16
15
  relation: "ancestor",
17
16
  component: { $nin: ["Button", "Link"] }
18
17
  },
19
18
  type: "control",
20
- description: "Use within a form to allow your users to toggle between checked and not checked. Group checkboxes by matching their “Name” properties. Unlike radios, any number of checkboxes in a group can be checked.",
21
19
  icon: e,
22
- presetStyle: a,
23
- order: 6,
20
+ presetStyle: r,
24
21
  states: [
25
22
  ...t,
26
23
  { selector: ":checked", label: "Checked" },
@@ -30,26 +27,9 @@ const a = {
30
27
  { selector: ":enabled", label: "Enabled" },
31
28
  { selector: ":read-only", label: "Read Only" },
32
29
  { selector: ":read-write", label: "Read Write" }
33
- ],
34
- template: [
35
- {
36
- type: "instance",
37
- component: "Label",
38
- label: "Checkbox Field",
39
- children: [
40
- { type: "instance", component: "Checkbox", children: [] },
41
- {
42
- type: "instance",
43
- component: "Text",
44
- label: "Checkbox Label",
45
- props: [{ type: "string", name: "tag", value: "span" }],
46
- children: [{ type: "text", value: "Checkbox", placeholder: !0 }]
47
- }
48
- ]
49
- }
50
30
  ]
51
31
  }, p = {
52
- props: r,
32
+ props: l,
53
33
  initialProps: ["id", "className", "name", "value", "required", "checked"]
54
34
  };
55
35
  export {
@@ -1,5 +1,5 @@
1
1
  import { BracesIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
3
  import { code as o } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as r } from "./__generated__/code-text.props.js";
5
5
  const p = {
package/lib/components.js CHANGED
@@ -4,10 +4,10 @@ import { HtmlEmbed as x } from "./html-embed.js";
4
4
  import { MarkdownEmbed as i } from "./markdown-embed.js";
5
5
  import { Body as n } from "./body.js";
6
6
  import { Box as d } from "./box.js";
7
- import { Text as k } from "./text.js";
8
- import { Heading as u } from "./heading.js";
9
- import { Paragraph as S } from "./paragraph.js";
10
- import { Link as L, Link as T } from "./link.js";
7
+ import { Text as b } from "./text.js";
8
+ import { Heading as k } from "./heading.js";
9
+ import { Paragraph as B } from "./paragraph.js";
10
+ import { Link as T, Link as L } from "./link.js";
11
11
  import { Span as F } from "./span.js";
12
12
  import { Bold as h } from "./bold.js";
13
13
  import { Italic as P } from "./italic.js";
@@ -17,27 +17,28 @@ import { Button as H } from "./button.js";
17
17
  import { Input as q } from "./input.js";
18
18
  import { WebhookForm as M } from "./webhook-form.js";
19
19
  import { Form as O } from "./form.js";
20
- import { Image as j } from "./image.js";
21
- import { Blockquote as A } from "./blockquote.js";
22
- import { List as G } from "./list.js";
23
- import { ListItem as K } from "./list-item.js";
24
- import { Separator as U } from "./separator.js";
20
+ import { Image as Y } from "./image.js";
21
+ import { Blockquote as z } from "./blockquote.js";
22
+ import { List as D } from "./list.js";
23
+ import { ListItem as J } from "./list-item.js";
24
+ import { Separator as Q } from "./separator.js";
25
25
  import { CodeText as Z } from "./code-text.js";
26
26
  import { Label as $ } from "./label.js";
27
27
  import { Textarea as ro } from "./textarea.js";
28
28
  import { RadioButton as to } from "./radio-button.js";
29
29
  import { Checkbox as po } from "./checkbox.js";
30
30
  import { Vimeo as fo } from "./vimeo.js";
31
- import { VimeoPreviewImage as ao } from "./vimeo-preview-image.js";
32
- import { VimeoPlayButton as lo } from "./vimeo-play-button.js";
31
+ import { YouTube as ao } from "./youtube.js";
32
+ import { VimeoPreviewImage as lo } from "./vimeo-preview-image.js";
33
+ import { VimeoPlayButton as bo } from "./vimeo-play-button.js";
33
34
  import { VimeoSpinner as ko } from "./vimeo-spinner.js";
34
- import { XmlNode as uo } from "./xml-node.js";
35
- import { XmlTime as So } from "./xml-time.js";
36
- import { Time as Lo } from "./time.js";
37
- import { Select as go } from "./select.js";
38
- import { Option as Io } from "./option.js";
35
+ import { XmlNode as Bo } from "./xml-node.js";
36
+ import { XmlTime as To } from "./xml-time.js";
37
+ import { Time as go } from "./time.js";
38
+ import { Select as Io } from "./select.js";
39
+ import { Option as Vo } from "./option.js";
39
40
  export {
40
- A as Blockquote,
41
+ z as Blockquote,
41
42
  n as Body,
42
43
  h as Bold,
43
44
  d as Box,
@@ -46,34 +47,35 @@ export {
46
47
  Z as CodeText,
47
48
  M as Form,
48
49
  m as Fragment,
49
- u as Heading,
50
+ k as Heading,
50
51
  x as HtmlEmbed,
51
- j as Image,
52
+ Y as Image,
52
53
  q as Input,
53
54
  P as Italic,
54
55
  $ as Label,
55
- L as Link,
56
- G as List,
57
- K as ListItem,
56
+ T as Link,
57
+ D as List,
58
+ J as ListItem,
58
59
  i as MarkdownEmbed,
59
- Io as Option,
60
- S as Paragraph,
60
+ Vo as Option,
61
+ B as Paragraph,
61
62
  to as RadioButton,
62
63
  O as RemixForm,
63
- T as RichTextLink,
64
- go as Select,
65
- U as Separator,
64
+ L as RichTextLink,
65
+ Io as Select,
66
+ Q as Separator,
66
67
  e as Slot,
67
68
  F as Span,
68
69
  C as Subscript,
69
70
  w as Superscript,
70
- k as Text,
71
+ b as Text,
71
72
  ro as Textarea,
72
- Lo as Time,
73
+ go as Time,
73
74
  fo as Vimeo,
74
- lo as VimeoPlayButton,
75
- ao as VimeoPreviewImage,
75
+ bo as VimeoPlayButton,
76
+ lo as VimeoPreviewImage,
76
77
  ko as VimeoSpinner,
77
- uo as XmlNode,
78
- So as XmlTime
78
+ Bo as XmlNode,
79
+ To as XmlTime,
80
+ ao as YouTube
79
81
  };
@@ -0,0 +1,83 @@
1
+ import { jsxs as l, jsx as e } from "react/jsx-runtime";
2
+ import { $ as a, ws as t } from "@webstudio-is/template";
3
+ import { imagePlaceholderDataUrl as o } from "@webstudio-is/image";
4
+ import { ContentEmbedIcon as n } from "@webstudio-is/icons/svg";
5
+ const s = `
6
+ <h1>Styling HTML with Content Embed</h1>
7
+ <p>Content Embed allows styling of HTML, which primarily comes from external data.</p>
8
+ <h2>How to Use Content Embed</h2>
9
+ <ul>
10
+ <li>Every element is shown in the Navigator.</li>
11
+ <li>Apply styles and Tokens to each element.</li>
12
+ <li>Adjustments to elements apply universally within this embed, ensuring consistency across your content.</li>
13
+ </ul>
14
+ <hr>
15
+ <h2>This sample text contains all the elements that can be styled.</h2>
16
+ <p>Any elements that were not used above are used below.</p>
17
+ <h3>Heading 3</h3>
18
+ <h4>Heading 4</h4>
19
+ <h5>Heading 5</h5>
20
+ <h6>Heading 6</h6>
21
+ <p><a href="#">Links</a> connect your content to relevant resources.</p>
22
+ <p><strong>Bold text</strong> makes your important points stand out.</p>
23
+ <p><em>Italic text</em> is great for emphasizing terms.</p>
24
+ <ol>
25
+ <li>First Step</li>
26
+ <li>Second Step</li>
27
+ </ol>
28
+ <img src="${o}">
29
+ <blockquote>Capture attention with a powerful quote.</blockquote>
30
+ <p>Using <code>console.log("Hello World");</code> will log to the console.</p>
31
+ <table>
32
+ <tr>
33
+ <th>Header 1</th>
34
+ <th>Header 2</th>
35
+ <th>Header 3</th>
36
+ </tr>
37
+ <tr>
38
+ <td>Cell 1.1</td>
39
+ <td>Cell 1.2</td>
40
+ <td>Cell 1.3</td>
41
+ </tr>
42
+ <tr>
43
+ <td>Cell 2.1</td>
44
+ <td>Cell 2.2</td>
45
+ <td>Cell 2.3</td>
46
+ </tr>
47
+ <tr>
48
+ <td>Cell 3.1</td>
49
+ <td>Cell 3.2</td>
50
+ <td>Cell 3.3</td>
51
+ </tr>
52
+ </table>
53
+ `.trim(), h = {
54
+ category: "data",
55
+ icon: n,
56
+ description: "Content Embed allows styling of HTML, which can be provided via the Code property statically or loaded dynamically from any Resource, for example, from a CMS.",
57
+ order: 3,
58
+ template: /* @__PURE__ */ l(a.HtmlEmbed, { "ws:label": "Content Embed", code: s, children: [
59
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Paragraph", selector: " p" }),
60
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 1", selector: " h1" }),
61
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 2", selector: " h2" }),
62
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 3", selector: " h3" }),
63
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 4", selector: " h4" }),
64
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 5", selector: " h5" }),
65
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Heading 6", selector: " h6" }),
66
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Bold", selector: " :where(strong, b)" }),
67
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Italic", selector: " :where(em, i)" }),
68
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Link", selector: " a" }),
69
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Image", selector: " img" }),
70
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Blockquote", selector: " blockquote" }),
71
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Code Text", selector: " code" }),
72
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "List", selector: " :where(ul, ol)" }),
73
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "List Item", selector: " li" }),
74
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Separator", selector: " hr" }),
75
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Table", selector: " table" }),
76
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Table Row", selector: " tr" }),
77
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Table Header Cell", selector: " th" }),
78
+ /* @__PURE__ */ e(t.descendant, { "ws:label": "Table Cell", selector: " td" })
79
+ ] })
80
+ };
81
+ export {
82
+ h as meta
83
+ };
package/lib/form.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { FormIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as o } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as o } from "@webstudio-is/sdk";
3
3
  import { form as r } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as e } from "./__generated__/form.props.js";
5
5
  const n = {
@@ -0,0 +1,11 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { $ as t } from "@webstudio-is/template";
3
+ const n = {
4
+ category: "typography",
5
+ description: "Use HTML headings to structure and organize content. Use the Tag property in settings to change the heading level (h1-h6).",
6
+ order: 1,
7
+ template: /* @__PURE__ */ e(t.Heading, {})
8
+ };
9
+ export {
10
+ n as meta
11
+ };
package/lib/heading.ws.js CHANGED
@@ -1,38 +1,28 @@
1
1
  import { HeadingIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as e } from "@webstudio-is/react-sdk";
3
- import { h1 as o, h2 as n, h3 as r, h4 as a, h5 as i, h6 as s } from "@webstudio-is/sdk/normalize.css";
2
+ import { defaultStates as o } from "@webstudio-is/sdk";
3
+ import { h1 as e, h2 as n, h3 as r, h4 as a, h5 as s, h6 as i } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as p } from "./__generated__/heading.props.js";
5
- const c = {
6
- h1: o,
5
+ const m = {
6
+ h1: e,
7
7
  h2: n,
8
8
  h3: r,
9
9
  h4: a,
10
- h5: i,
11
- h6: s
12
- }, l = {
13
- category: "typography",
10
+ h5: s,
11
+ h6: i
12
+ }, d = {
14
13
  type: "container",
15
- description: "Use HTML headings to structure and organize content. Use the Tag property in settings to change the heading level (h1-h6).",
16
14
  icon: t,
17
15
  constraints: {
18
16
  relation: "ancestor",
19
17
  component: { $neq: "Heading" }
20
18
  },
21
- states: e,
22
- presetStyle: c,
23
- order: 1,
24
- template: [
25
- {
26
- type: "instance",
27
- component: "Heading",
28
- children: []
29
- }
30
- ]
31
- }, y = {
19
+ states: o,
20
+ presetStyle: m
21
+ }, g = {
32
22
  props: p,
33
23
  initialProps: ["id", "className", "tag"]
34
24
  };
35
25
  export {
36
- l as meta,
37
- y as propsMeta
26
+ d as meta,
27
+ g as propsMeta
38
28
  };
package/lib/image.ws.js CHANGED
@@ -1,10 +1,10 @@
1
- import { ImageIcon as o } from "@webstudio-is/icons/svg";
2
- import { defaultStates as r } from "@webstudio-is/react-sdk";
3
- import { img as i } from "@webstudio-is/sdk/normalize.css";
4
- import { props as e } from "./__generated__/image.props.js";
1
+ import { ImageIcon as e } from "@webstudio-is/icons/svg";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
+ import { img as o } from "@webstudio-is/sdk/normalize.css";
4
+ import { props as r } from "./__generated__/image.props.js";
5
5
  const a = {
6
6
  img: [
7
- ...i,
7
+ ...o,
8
8
  // Otherwise on new image insert onto canvas it can overfit screen size multiple times
9
9
  {
10
10
  property: "maxWidth",
@@ -28,24 +28,20 @@ const a = {
28
28
  category: "media",
29
29
  type: "embed",
30
30
  description: "Add an image asset to the page. Webstudio automatically converts images to WebP or AVIF format and makes them responsive for best performance.",
31
- icon: o,
32
- states: r,
31
+ icon: e,
32
+ states: t,
33
33
  presetStyle: a,
34
34
  order: 0
35
- }, p = {
36
- src: {
37
- type: "string",
38
- control: "file",
39
- label: "Source",
40
- required: !1
41
- }
42
- }, t = e.optimize;
43
- t.description = "Optimize the image for enhanced performance.";
44
- const d = {
35
+ }, d = {
45
36
  props: {
46
- ...e,
47
- ...p,
48
- optimize: t
37
+ ...r,
38
+ // Automatically generated props don't have the right control.
39
+ src: {
40
+ type: "string",
41
+ control: "file",
42
+ label: "Source",
43
+ required: !1
44
+ }
49
45
  },
50
46
  initialProps: [
51
47
  "id",
@@ -60,6 +56,5 @@ const d = {
60
56
  };
61
57
  export {
62
58
  l as meta,
63
- d as propsMeta,
64
- p as propsOverrides
59
+ d as propsMeta
65
60
  };
package/lib/input.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { FormTextFieldIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
3
  import { input as o } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as l } from "./__generated__/input.props.js";
5
5
  const r = {
package/lib/italic.ws.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { TextItalicIcon as t } from "@webstudio-is/icons/svg";
2
- import { defaultStates as e } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as e } from "@webstudio-is/sdk";
3
3
  import { i as o } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as i } from "./__generated__/italic.props.js";
5
5
  const r = {
@@ -0,0 +1,10 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { $ as r, PlaceholderValue as o } from "@webstudio-is/template";
3
+ const a = {
4
+ category: "forms",
5
+ order: 2,
6
+ template: /* @__PURE__ */ e(r.Label, { children: new o("Form Label") })
7
+ };
8
+ export {
9
+ a as meta
10
+ };
package/lib/label.ws.js CHANGED
@@ -1,42 +1,27 @@
1
- import { LabelIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as o } from "@webstudio-is/react-sdk";
3
- import { label as r } from "@webstudio-is/sdk/normalize.css";
4
- import { props as t } from "./__generated__/label.props.js";
5
- const l = {
1
+ import { LabelIcon as t } from "@webstudio-is/icons/svg";
2
+ import { defaultStates as o } from "@webstudio-is/sdk";
3
+ import { label as e } from "@webstudio-is/sdk/normalize.css";
4
+ import { props as r } from "./__generated__/label.props.js";
5
+ const a = {
6
6
  label: [
7
- ...r,
7
+ ...e,
8
8
  { property: "display", value: { type: "keyword", value: "block" } }
9
9
  ]
10
- }, m = {
11
- category: "forms",
10
+ }, i = {
12
11
  constraints: {
13
12
  relation: "ancestor",
14
13
  component: { $nin: ["Button", "Link"] }
15
14
  },
16
15
  type: "container",
17
16
  label: "Input Label",
18
- icon: e,
17
+ icon: t,
19
18
  states: o,
20
- presetStyle: l,
21
- order: 2,
22
- template: [
23
- {
24
- type: "instance",
25
- component: "Label",
26
- children: [{ type: "text", value: "Form Label", placeholder: !0 }]
27
- }
28
- ]
29
- }, i = {
30
- props: {
31
- ...t,
32
- htmlFor: {
33
- ...t.htmlFor,
34
- label: "For"
35
- }
36
- },
19
+ presetStyle: a
20
+ }, m = {
21
+ props: r,
37
22
  initialProps: ["id", "className", "htmlFor"]
38
23
  };
39
24
  export {
40
- m as meta,
41
- i as propsMeta
25
+ i as meta,
26
+ m as propsMeta
42
27
  };
@@ -0,0 +1,11 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { $ as o } from "@webstudio-is/template";
3
+ const n = {
4
+ category: "general",
5
+ description: "Use a link to send your users to another page, section, or resource. Configure links in the Settings panel.",
6
+ order: 1,
7
+ template: /* @__PURE__ */ e(o.Link, {})
8
+ };
9
+ export {
10
+ n as meta
11
+ };
package/lib/link.ws.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { LinkIcon as e } from "@webstudio-is/icons/svg";
2
- import { defaultStates as t } from "@webstudio-is/react-sdk";
2
+ import { defaultStates as t } from "@webstudio-is/sdk";
3
3
  import { a as r } from "@webstudio-is/sdk/normalize.css";
4
4
  import { props as o } from "./__generated__/link.props.js";
5
- const n = {
5
+ const a = {
6
6
  a: [
7
7
  ...r,
8
8
  {
@@ -11,16 +11,13 @@ const n = {
11
11
  }
12
12
  ]
13
13
  }, l = {
14
- category: "general",
15
14
  type: "container",
16
- description: "Use a link to send your users to another page, section, or resource. Configure links in the Settings panel.",
17
15
  icon: e,
18
16
  constraints: {
19
17
  relation: "ancestor",
20
18
  component: { $nin: ["Button", "Link"] }
21
19
  },
22
- presetStyle: n,
23
- order: 1,
20
+ presetStyle: a,
24
21
  states: [
25
22
  ...t,
26
23
  {
@@ -32,13 +29,6 @@ const n = {
32
29
  selector: "[aria-current=page]",
33
30
  label: "Current page"
34
31
  }
35
- ],
36
- template: [
37
- {
38
- type: "instance",
39
- component: "Link",
40
- children: []
41
- }
42
32
  ]
43
33
  }, c = {
44
34
  props: {
@@ -0,0 +1,11 @@
1
+ import { jsx as t } from "react/jsx-runtime";
2
+ import { $ as e } from "@webstudio-is/template";
3
+ const i = {
4
+ category: "typography",
5
+ description: "Adds a new item to an existing list.",
6
+ order: 5,
7
+ template: /* @__PURE__ */ t(e.ListItem, {})
8
+ };
9
+ export {
10
+ i as meta
11
+ };