@webstudio-is/sdk-components-react 0.70.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +3 -0
- package/lib/__generated__/blockquote.props.js +399 -0
- package/lib/__generated__/body.props.js +398 -0
- package/lib/__generated__/bold.props.js +398 -0
- package/lib/__generated__/box.props.js +416 -0
- package/lib/__generated__/button.props.js +420 -0
- package/lib/__generated__/checkbox-field.props.js +399 -0
- package/lib/__generated__/checkbox.props.js +439 -0
- package/lib/__generated__/code-text.props.js +405 -0
- package/lib/__generated__/error-message.props.js +398 -0
- package/lib/__generated__/form.props.js +406 -0
- package/lib/__generated__/fragment.props.js +4 -0
- package/lib/__generated__/heading.props.js +405 -0
- package/lib/__generated__/html-embed.props.js +11 -0
- package/lib/__generated__/image.props.js +442 -0
- package/lib/__generated__/input.props.js +445 -0
- package/lib/__generated__/italic.props.js +398 -0
- package/lib/__generated__/label.props.js +400 -0
- package/lib/__generated__/link-block.props.js +432 -0
- package/lib/__generated__/link.props.js +432 -0
- package/lib/__generated__/list-item.props.js +399 -0
- package/lib/__generated__/list.props.js +412 -0
- package/lib/__generated__/paragraph.props.js +398 -0
- package/lib/__generated__/radio-button-field.props.js +399 -0
- package/lib/__generated__/radio-button.props.js +439 -0
- package/lib/__generated__/rich-text-link.props.js +432 -0
- package/lib/__generated__/separator.props.js +398 -0
- package/lib/__generated__/slot.props.js +4 -0
- package/lib/__generated__/span.props.js +398 -0
- package/lib/__generated__/subscript.props.js +398 -0
- package/lib/__generated__/success-message.props.js +398 -0
- package/lib/__generated__/superscript.props.js +398 -0
- package/lib/__generated__/text-block.props.js +405 -0
- package/lib/__generated__/textarea.props.js +412 -0
- package/lib/blockquote.js +15 -0
- package/lib/blockquote.ws.js +76 -0
- package/lib/body.js +9 -0
- package/lib/body.ws.js +47 -0
- package/lib/bold.js +9 -0
- package/lib/bold.ws.js +23 -0
- package/lib/box.js +14 -0
- package/lib/box.ws.js +46 -0
- package/lib/button.js +16 -0
- package/lib/button.ws.js +31 -0
- package/lib/checkbox-field.js +9 -0
- package/lib/checkbox-field.ws.js +44 -0
- package/lib/checkbox.js +9 -0
- package/lib/checkbox.ws.js +40 -0
- package/lib/cjs/__generated__/blockquote.props.js +419 -0
- package/lib/cjs/__generated__/body.props.js +418 -0
- package/lib/cjs/__generated__/bold.props.js +418 -0
- package/lib/cjs/__generated__/box.props.js +436 -0
- package/lib/cjs/__generated__/button.props.js +440 -0
- package/lib/cjs/__generated__/checkbox-field.props.js +419 -0
- package/lib/cjs/__generated__/checkbox.props.js +459 -0
- package/lib/cjs/__generated__/code-text.props.js +425 -0
- package/lib/cjs/__generated__/error-message.props.js +418 -0
- package/lib/cjs/__generated__/form.props.js +426 -0
- package/lib/cjs/__generated__/fragment.props.js +24 -0
- package/lib/cjs/__generated__/heading.props.js +425 -0
- package/lib/cjs/__generated__/html-embed.props.js +31 -0
- package/lib/cjs/__generated__/image.props.js +462 -0
- package/lib/cjs/__generated__/input.props.js +465 -0
- package/lib/cjs/__generated__/italic.props.js +418 -0
- package/lib/cjs/__generated__/label.props.js +420 -0
- package/lib/cjs/__generated__/link-block.props.js +452 -0
- package/lib/cjs/__generated__/link.props.js +452 -0
- package/lib/cjs/__generated__/list-item.props.js +419 -0
- package/lib/cjs/__generated__/list.props.js +432 -0
- package/lib/cjs/__generated__/paragraph.props.js +418 -0
- package/lib/cjs/__generated__/radio-button-field.props.js +419 -0
- package/lib/cjs/__generated__/radio-button.props.js +459 -0
- package/lib/cjs/__generated__/rich-text-link.props.js +452 -0
- package/lib/cjs/__generated__/separator.props.js +418 -0
- package/lib/cjs/__generated__/slot.props.js +24 -0
- package/lib/cjs/__generated__/span.props.js +418 -0
- package/lib/cjs/__generated__/subscript.props.js +418 -0
- package/lib/cjs/__generated__/success-message.props.js +418 -0
- package/lib/cjs/__generated__/superscript.props.js +418 -0
- package/lib/cjs/__generated__/text-block.props.js +425 -0
- package/lib/cjs/__generated__/textarea.props.js +432 -0
- package/lib/cjs/blockquote.js +32 -0
- package/lib/cjs/blockquote.ws.js +94 -0
- package/lib/cjs/body.js +29 -0
- package/lib/cjs/body.ws.js +65 -0
- package/lib/cjs/bold.js +29 -0
- package/lib/cjs/bold.ws.js +41 -0
- package/lib/cjs/box.js +31 -0
- package/lib/cjs/box.ws.js +53 -0
- package/lib/cjs/button.js +36 -0
- package/lib/cjs/button.ws.js +49 -0
- package/lib/cjs/checkbox-field.js +29 -0
- package/lib/cjs/checkbox-field.ws.js +62 -0
- package/lib/cjs/checkbox.js +29 -0
- package/lib/cjs/checkbox.ws.js +58 -0
- package/lib/cjs/code-text.js +39 -0
- package/lib/cjs/code-text.ws.js +74 -0
- package/lib/cjs/components.js +88 -0
- package/lib/cjs/error-message.js +29 -0
- package/lib/cjs/error-message.ws.js +40 -0
- package/lib/cjs/form.js +29 -0
- package/lib/cjs/form.ws.js +82 -0
- package/lib/cjs/fragment.js +29 -0
- package/lib/cjs/fragment.ws.js +33 -0
- package/lib/cjs/heading.js +31 -0
- package/lib/cjs/heading.ws.js +56 -0
- package/lib/cjs/html-embed.js +80 -0
- package/lib/cjs/html-embed.ws.js +45 -0
- package/lib/cjs/image.js +76 -0
- package/lib/cjs/image.ws.js +66 -0
- package/lib/cjs/input.js +29 -0
- package/lib/cjs/input.ws.js +55 -0
- package/lib/cjs/italic.js +29 -0
- package/lib/cjs/italic.ws.js +47 -0
- package/lib/cjs/label.js +29 -0
- package/lib/cjs/label.ws.js +63 -0
- package/lib/cjs/link-block.js +30 -0
- package/lib/cjs/link-block.ws.js +53 -0
- package/lib/cjs/link.js +48 -0
- package/lib/cjs/link.ws.js +79 -0
- package/lib/cjs/list-item.js +32 -0
- package/lib/cjs/list-item.ws.js +51 -0
- package/lib/cjs/list.js +31 -0
- package/lib/cjs/list.ws.js +73 -0
- package/lib/cjs/metas.js +88 -0
- package/lib/cjs/package.json +1 -0
- package/lib/cjs/paragraph.js +29 -0
- package/lib/cjs/paragraph.ws.js +50 -0
- package/lib/cjs/props.js +88 -0
- package/lib/cjs/radio-button-field.js +29 -0
- package/lib/cjs/radio-button-field.ws.js +62 -0
- package/lib/cjs/radio-button.js +29 -0
- package/lib/cjs/radio-button.ws.js +58 -0
- package/lib/cjs/rich-text-link.js +28 -0
- package/lib/cjs/rich-text-link.ws.js +39 -0
- package/lib/cjs/separator.js +32 -0
- package/lib/cjs/separator.ws.js +70 -0
- package/lib/cjs/slot.js +36 -0
- package/lib/cjs/slot.ws.js +36 -0
- package/lib/cjs/span.js +29 -0
- package/lib/cjs/span.ws.js +41 -0
- package/lib/cjs/subscript.js +29 -0
- package/lib/cjs/subscript.ws.js +41 -0
- package/lib/cjs/success-message.js +29 -0
- package/lib/cjs/success-message.ws.js +40 -0
- package/lib/cjs/superscript.js +29 -0
- package/lib/cjs/superscript.ws.js +41 -0
- package/lib/cjs/text-block.js +32 -0
- package/lib/cjs/text-block.ws.js +57 -0
- package/lib/cjs/textarea.js +29 -0
- package/lib/cjs/textarea.ws.js +59 -0
- package/lib/code-text.js +22 -0
- package/lib/code-text.ws.js +56 -0
- package/lib/components.js +68 -0
- package/lib/error-message.js +9 -0
- package/lib/error-message.ws.js +20 -0
- package/lib/form.js +9 -0
- package/lib/form.ws.js +64 -0
- package/lib/fragment.js +9 -0
- package/lib/fragment.ws.js +13 -0
- package/lib/heading.js +14 -0
- package/lib/heading.ws.js +38 -0
- package/lib/html-embed.js +65 -0
- package/lib/html-embed.ws.js +25 -0
- package/lib/image.js +66 -0
- package/lib/image.ws.js +48 -0
- package/lib/input.js +9 -0
- package/lib/input.ws.js +37 -0
- package/lib/italic.js +9 -0
- package/lib/italic.ws.js +29 -0
- package/lib/label.js +9 -0
- package/lib/label.ws.js +45 -0
- package/lib/link-block.js +10 -0
- package/lib/link-block.ws.js +33 -0
- package/lib/link.js +32 -0
- package/lib/link.ws.js +61 -0
- package/lib/list-item.js +15 -0
- package/lib/list-item.ws.js +33 -0
- package/lib/list.js +14 -0
- package/lib/list.ws.js +55 -0
- package/lib/metas.js +68 -0
- package/lib/paragraph.js +9 -0
- package/lib/paragraph.ws.js +32 -0
- package/lib/props.js +68 -0
- package/lib/radio-button-field.js +9 -0
- package/lib/radio-button-field.ws.js +44 -0
- package/lib/radio-button.js +9 -0
- package/lib/radio-button.ws.js +40 -0
- package/lib/rich-text-link.js +8 -0
- package/lib/rich-text-link.ws.js +19 -0
- package/lib/separator.js +15 -0
- package/lib/separator.ws.js +52 -0
- package/lib/slot.js +16 -0
- package/lib/slot.ws.js +16 -0
- package/lib/span.js +9 -0
- package/lib/span.ws.js +23 -0
- package/lib/subscript.js +9 -0
- package/lib/subscript.ws.js +23 -0
- package/lib/success-message.js +9 -0
- package/lib/success-message.ws.js +20 -0
- package/lib/superscript.js +9 -0
- package/lib/superscript.ws.js +23 -0
- package/lib/text-block.js +15 -0
- package/lib/text-block.ws.js +39 -0
- package/lib/textarea.js +9 -0
- package/lib/textarea.ws.js +41 -0
- package/lib/types/__generated__/blockquote.props.d.ts +2 -0
- package/lib/types/__generated__/body.props.d.ts +2 -0
- package/lib/types/__generated__/bold.props.d.ts +2 -0
- package/lib/types/__generated__/box.props.d.ts +2 -0
- package/lib/types/__generated__/button.props.d.ts +2 -0
- package/lib/types/__generated__/checkbox-field.props.d.ts +2 -0
- package/lib/types/__generated__/checkbox.props.d.ts +2 -0
- package/lib/types/__generated__/code-text.props.d.ts +2 -0
- package/lib/types/__generated__/error-message.props.d.ts +2 -0
- package/lib/types/__generated__/form.props.d.ts +2 -0
- package/lib/types/__generated__/fragment.props.d.ts +2 -0
- package/lib/types/__generated__/heading.props.d.ts +2 -0
- package/lib/types/__generated__/html-embed.props.d.ts +2 -0
- package/lib/types/__generated__/image.props.d.ts +2 -0
- package/lib/types/__generated__/input.props.d.ts +2 -0
- package/lib/types/__generated__/italic.props.d.ts +2 -0
- package/lib/types/__generated__/label.props.d.ts +2 -0
- package/lib/types/__generated__/link-block.props.d.ts +2 -0
- package/lib/types/__generated__/link.props.d.ts +2 -0
- package/lib/types/__generated__/list-item.props.d.ts +2 -0
- package/lib/types/__generated__/list.props.d.ts +2 -0
- package/lib/types/__generated__/paragraph.props.d.ts +2 -0
- package/lib/types/__generated__/radio-button-field.props.d.ts +2 -0
- package/lib/types/__generated__/radio-button.props.d.ts +2 -0
- package/lib/types/__generated__/rich-text-link.props.d.ts +2 -0
- package/lib/types/__generated__/separator.props.d.ts +2 -0
- package/lib/types/__generated__/slot.props.d.ts +2 -0
- package/lib/types/__generated__/span.props.d.ts +2 -0
- package/lib/types/__generated__/subscript.props.d.ts +2 -0
- package/lib/types/__generated__/success-message.props.d.ts +2 -0
- package/lib/types/__generated__/superscript.props.d.ts +2 -0
- package/lib/types/__generated__/text-block.props.d.ts +2 -0
- package/lib/types/__generated__/textarea.props.d.ts +2 -0
- package/lib/types/blockquote.d.ts +3 -0
- package/lib/types/blockquote.stories.d.ts +5 -0
- package/lib/types/blockquote.ws.d.ts +3 -0
- package/lib/types/body.d.ts +3 -0
- package/lib/types/body.stories.d.ts +6 -0
- package/lib/types/body.ws.d.ts +3 -0
- package/lib/types/bold.d.ts +3 -0
- package/lib/types/bold.stories.d.ts +5 -0
- package/lib/types/bold.ws.d.ts +3 -0
- package/lib/types/box.d.ts +7 -0
- package/lib/types/box.stories.d.ts +9 -0
- package/lib/types/box.ws.d.ts +3 -0
- package/lib/types/button.d.ts +7 -0
- package/lib/types/button.stories.d.ts +9 -0
- package/lib/types/button.ws.d.ts +3 -0
- package/lib/types/checkbox-field.d.ts +3 -0
- package/lib/types/checkbox-field.ws.d.ts +3 -0
- package/lib/types/checkbox.d.ts +3 -0
- package/lib/types/checkbox.ws.d.ts +3 -0
- package/lib/types/code-text.d.ts +9 -0
- package/lib/types/code-text.stories.d.ts +11 -0
- package/lib/types/code-text.ws.d.ts +3 -0
- package/lib/types/components.d.ts +33 -0
- package/lib/types/error-message.d.ts +3 -0
- package/lib/types/error-message.ws.d.ts +3 -0
- package/lib/types/form.d.ts +3 -0
- package/lib/types/form.stories.d.ts +5 -0
- package/lib/types/form.ws.d.ts +3 -0
- package/lib/types/fragment.d.ts +6 -0
- package/lib/types/fragment.ws.d.ts +3 -0
- package/lib/types/heading.d.ts +7 -0
- package/lib/types/heading.stories.d.ts +9 -0
- package/lib/types/heading.ws.d.ts +3 -0
- package/lib/types/html-embed.d.ts +7 -0
- package/lib/types/html-embed.stories.d.ts +11 -0
- package/lib/types/html-embed.ws.d.ts +3 -0
- package/lib/types/image.d.ts +7 -0
- package/lib/types/image.stories.d.ts +13 -0
- package/lib/types/image.ws.d.ts +3 -0
- package/lib/types/input.d.ts +5 -0
- package/lib/types/input.stories.d.ts +9 -0
- package/lib/types/input.ws.d.ts +3 -0
- package/lib/types/italic.d.ts +3 -0
- package/lib/types/italic.stories.d.ts +5 -0
- package/lib/types/italic.ws.d.ts +3 -0
- package/lib/types/label.d.ts +3 -0
- package/lib/types/label.ws.d.ts +3 -0
- package/lib/types/link-block.d.ts +3 -0
- package/lib/types/link-block.stories.d.ts +13 -0
- package/lib/types/link-block.ws.d.ts +3 -0
- package/lib/types/link.d.ts +9 -0
- package/lib/types/link.stories.d.ts +13 -0
- package/lib/types/link.ws.d.ts +3 -0
- package/lib/types/list-item.d.ts +3 -0
- package/lib/types/list-item.stories.d.ts +5 -0
- package/lib/types/list-item.ws.d.ts +3 -0
- package/lib/types/list.d.ts +9 -0
- package/lib/types/list.stories.d.ts +9 -0
- package/lib/types/list.ws.d.ts +3 -0
- package/lib/types/metas.d.ts +33 -0
- package/lib/types/paragraph.d.ts +3 -0
- package/lib/types/paragraph.stories.d.ts +5 -0
- package/lib/types/paragraph.ws.d.ts +3 -0
- package/lib/types/props.d.ts +33 -0
- package/lib/types/radio-button-field.d.ts +3 -0
- package/lib/types/radio-button-field.ws.d.ts +3 -0
- package/lib/types/radio-button.d.ts +3 -0
- package/lib/types/radio-button.ws.d.ts +3 -0
- package/lib/types/rich-text-link.d.ts +2 -0
- package/lib/types/rich-text-link.stories.d.ts +13 -0
- package/lib/types/rich-text-link.ws.d.ts +3 -0
- package/lib/types/separator.d.ts +3 -0
- package/lib/types/separator.stories.d.ts +5 -0
- package/lib/types/separator.ws.d.ts +3 -0
- package/lib/types/slot.d.ts +6 -0
- package/lib/types/slot.stories.d.ts +9 -0
- package/lib/types/slot.ws.d.ts +3 -0
- package/lib/types/span.d.ts +3 -0
- package/lib/types/span.stories.d.ts +5 -0
- package/lib/types/span.ws.d.ts +3 -0
- package/lib/types/subscript.d.ts +3 -0
- package/lib/types/subscript.stories.d.ts +5 -0
- package/lib/types/subscript.ws.d.ts +3 -0
- package/lib/types/success-message.d.ts +3 -0
- package/lib/types/success-message.ws.d.ts +3 -0
- package/lib/types/superscript.d.ts +3 -0
- package/lib/types/superscript.stories.d.ts +5 -0
- package/lib/types/superscript.ws.d.ts +3 -0
- package/lib/types/text-block.d.ts +7 -0
- package/lib/types/text-block.stories.d.ts +9 -0
- package/lib/types/text-block.ws.d.ts +3 -0
- package/lib/types/textarea.d.ts +3 -0
- package/lib/types/textarea.ws.d.ts +3 -0
- package/package.json +69 -0
- package/src/__generated__/blockquote.props.ts +444 -0
- package/src/__generated__/body.props.ts +443 -0
- package/src/__generated__/bold.props.ts +443 -0
- package/src/__generated__/box.props.ts +461 -0
- package/src/__generated__/button.props.ts +465 -0
- package/src/__generated__/checkbox-field.props.ts +444 -0
- package/src/__generated__/checkbox.props.ts +484 -0
- package/src/__generated__/code-text.props.ts +450 -0
- package/src/__generated__/error-message.props.ts +443 -0
- package/src/__generated__/form.props.ts +451 -0
- package/src/__generated__/fragment.props.ts +3 -0
- package/src/__generated__/heading.props.ts +450 -0
- package/src/__generated__/html-embed.props.ts +10 -0
- package/src/__generated__/image.props.ts +487 -0
- package/src/__generated__/input.props.ts +490 -0
- package/src/__generated__/italic.props.ts +443 -0
- package/src/__generated__/label.props.ts +445 -0
- package/src/__generated__/link-block.props.ts +477 -0
- package/src/__generated__/link.props.ts +477 -0
- package/src/__generated__/list-item.props.ts +444 -0
- package/src/__generated__/list.props.ts +457 -0
- package/src/__generated__/paragraph.props.ts +443 -0
- package/src/__generated__/radio-button-field.props.ts +444 -0
- package/src/__generated__/radio-button.props.ts +484 -0
- package/src/__generated__/rich-text-link.props.ts +477 -0
- package/src/__generated__/separator.props.ts +443 -0
- package/src/__generated__/slot.props.ts +3 -0
- package/src/__generated__/span.props.ts +443 -0
- package/src/__generated__/subscript.props.ts +443 -0
- package/src/__generated__/success-message.props.ts +443 -0
- package/src/__generated__/superscript.props.ts +443 -0
- package/src/__generated__/text-block.props.ts +450 -0
- package/src/__generated__/textarea.props.ts +457 -0
- package/src/blockquote.stories.tsx +16 -0
- package/src/blockquote.tsx +18 -0
- package/src/blockquote.ws.tsx +81 -0
- package/src/body.stories.tsx +11 -0
- package/src/body.tsx +10 -0
- package/src/body.ws.tsx +51 -0
- package/src/bold.stories.tsx +16 -0
- package/src/bold.tsx +10 -0
- package/src/bold.ws.tsx +26 -0
- package/src/box.stories.tsx +17 -0
- package/src/box.tsx +31 -0
- package/src/box.ws.ts +52 -0
- package/src/button.stories.tsx +13 -0
- package/src/button.tsx +23 -0
- package/src/button.ws.tsx +34 -0
- package/src/checkbox-field.tsx +10 -0
- package/src/checkbox-field.ws.tsx +47 -0
- package/src/checkbox.tsx +13 -0
- package/src/checkbox.ws.tsx +43 -0
- package/src/code-text.stories.tsx +16 -0
- package/src/code-text.tsx +31 -0
- package/src/code-text.ws.tsx +58 -0
- package/src/components.ts +33 -0
- package/src/error-message.tsx +10 -0
- package/src/error-message.ws.tsx +24 -0
- package/src/form.stories.tsx +14 -0
- package/src/form.tsx +14 -0
- package/src/form.ws.tsx +67 -0
- package/src/fragment.tsx +11 -0
- package/src/fragment.ws.ts +15 -0
- package/src/heading.stories.tsx +16 -0
- package/src/heading.tsx +20 -0
- package/src/heading.ws.tsx +44 -0
- package/src/html-embed.stories.tsx +16 -0
- package/src/html-embed.tsx +96 -0
- package/src/html-embed.ws.ts +27 -0
- package/src/image.stories.tsx +15 -0
- package/src/image.tsx +83 -0
- package/src/image.ws.tsx +54 -0
- package/src/input.stories.tsx +14 -0
- package/src/input.tsx +13 -0
- package/src/input.ws.tsx +40 -0
- package/src/italic.stories.tsx +16 -0
- package/src/italic.tsx +10 -0
- package/src/italic.ws.tsx +32 -0
- package/src/label.tsx +10 -0
- package/src/label.ws.tsx +48 -0
- package/src/link-block.stories.tsx +16 -0
- package/src/link-block.tsx +9 -0
- package/src/link-block.ws.tsx +38 -0
- package/src/link.stories.tsx +16 -0
- package/src/link.tsx +44 -0
- package/src/link.ws.tsx +64 -0
- package/src/list-item.stories.tsx +16 -0
- package/src/list-item.tsx +18 -0
- package/src/list-item.ws.tsx +36 -0
- package/src/list.stories.tsx +17 -0
- package/src/list.tsx +26 -0
- package/src/list.ws.tsx +58 -0
- package/src/metas.ts +33 -0
- package/src/paragraph.stories.tsx +16 -0
- package/src/paragraph.tsx +10 -0
- package/src/paragraph.ws.tsx +35 -0
- package/src/props.ts +33 -0
- package/src/radio-button-field.tsx +10 -0
- package/src/radio-button-field.ws.tsx +47 -0
- package/src/radio-button.tsx +13 -0
- package/src/radio-button.ws.tsx +43 -0
- package/src/rich-text-link.stories.tsx +16 -0
- package/src/rich-text-link.tsx +8 -0
- package/src/rich-text-link.ws.tsx +22 -0
- package/src/separator.stories.tsx +14 -0
- package/src/separator.tsx +18 -0
- package/src/separator.ws.tsx +56 -0
- package/src/slot.stories.tsx +16 -0
- package/src/slot.tsx +17 -0
- package/src/slot.ws.ts +18 -0
- package/src/span.stories.tsx +16 -0
- package/src/span.tsx +10 -0
- package/src/span.ws.tsx +26 -0
- package/src/subscript.stories.tsx +16 -0
- package/src/subscript.tsx +10 -0
- package/src/subscript.ws.tsx +26 -0
- package/src/success-message.tsx +10 -0
- package/src/success-message.ws.tsx +24 -0
- package/src/superscript.stories.tsx +16 -0
- package/src/superscript.tsx +10 -0
- package/src/superscript.ws.tsx +26 -0
- package/src/text-block.stories.tsx +16 -0
- package/src/text-block.tsx +21 -0
- package/src/text-block.ws.tsx +42 -0
- package/src/textarea.tsx +13 -0
- package/src/textarea.ws.tsx +44 -0
package/lib/metas.js
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { meta } from "./slot.ws";
|
|
2
|
+
import { meta as meta2 } from "./fragment.ws";
|
|
3
|
+
import { meta as meta3 } from "./html-embed.ws";
|
|
4
|
+
import { meta as meta4 } from "./body.ws";
|
|
5
|
+
import { meta as meta5 } from "./box.ws";
|
|
6
|
+
import { meta as meta6 } from "./text-block.ws";
|
|
7
|
+
import { meta as meta7 } from "./heading.ws";
|
|
8
|
+
import { meta as meta8 } from "./paragraph.ws";
|
|
9
|
+
import { meta as meta9 } from "./link.ws";
|
|
10
|
+
import { meta as meta10 } from "./link-block.ws";
|
|
11
|
+
import { meta as meta11 } from "./rich-text-link.ws";
|
|
12
|
+
import { meta as meta12 } from "./span.ws";
|
|
13
|
+
import { meta as meta13 } from "./bold.ws";
|
|
14
|
+
import { meta as meta14 } from "./italic.ws";
|
|
15
|
+
import { meta as meta15 } from "./superscript.ws";
|
|
16
|
+
import { meta as meta16 } from "./subscript.ws";
|
|
17
|
+
import { meta as meta17 } from "./button.ws";
|
|
18
|
+
import { meta as meta18 } from "./input.ws";
|
|
19
|
+
import { meta as meta19 } from "./form.ws";
|
|
20
|
+
import { meta as meta20 } from "./image.ws";
|
|
21
|
+
import { meta as meta21 } from "./blockquote.ws";
|
|
22
|
+
import { meta as meta22 } from "./list.ws";
|
|
23
|
+
import { meta as meta23 } from "./list-item.ws";
|
|
24
|
+
import { meta as meta24 } from "./separator.ws";
|
|
25
|
+
import { meta as meta25 } from "./code-text.ws";
|
|
26
|
+
import { meta as meta26 } from "./label.ws";
|
|
27
|
+
import { meta as meta27 } from "./success-message.ws";
|
|
28
|
+
import { meta as meta28 } from "./error-message.ws";
|
|
29
|
+
import { meta as meta29 } from "./textarea.ws";
|
|
30
|
+
import { meta as meta30 } from "./radio-button-field.ws";
|
|
31
|
+
import { meta as meta31 } from "./radio-button.ws";
|
|
32
|
+
import { meta as meta32 } from "./checkbox-field.ws";
|
|
33
|
+
import { meta as meta33 } from "./checkbox.ws";
|
|
34
|
+
export {
|
|
35
|
+
meta21 as Blockquote,
|
|
36
|
+
meta4 as Body,
|
|
37
|
+
meta13 as Bold,
|
|
38
|
+
meta5 as Box,
|
|
39
|
+
meta17 as Button,
|
|
40
|
+
meta33 as Checkbox,
|
|
41
|
+
meta32 as CheckboxField,
|
|
42
|
+
meta25 as CodeText,
|
|
43
|
+
meta28 as ErrorMessage,
|
|
44
|
+
meta19 as Form,
|
|
45
|
+
meta2 as Fragment,
|
|
46
|
+
meta7 as Heading,
|
|
47
|
+
meta3 as HtmlEmbed,
|
|
48
|
+
meta20 as Image,
|
|
49
|
+
meta18 as Input,
|
|
50
|
+
meta14 as Italic,
|
|
51
|
+
meta26 as Label,
|
|
52
|
+
meta9 as Link,
|
|
53
|
+
meta10 as LinkBlock,
|
|
54
|
+
meta22 as List,
|
|
55
|
+
meta23 as ListItem,
|
|
56
|
+
meta8 as Paragraph,
|
|
57
|
+
meta31 as RadioButton,
|
|
58
|
+
meta30 as RadioButtonField,
|
|
59
|
+
meta11 as RichTextLink,
|
|
60
|
+
meta24 as Separator,
|
|
61
|
+
meta as Slot,
|
|
62
|
+
meta12 as Span,
|
|
63
|
+
meta16 as Subscript,
|
|
64
|
+
meta27 as SuccessMessage,
|
|
65
|
+
meta15 as Superscript,
|
|
66
|
+
meta6 as TextBlock,
|
|
67
|
+
meta29 as Textarea
|
|
68
|
+
};
|
package/lib/paragraph.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "p";
|
|
4
|
+
const Paragraph = forwardRef((props, ref) => /* @__PURE__ */ jsx("p", { ...props, ref }));
|
|
5
|
+
Paragraph.displayName = "Paragraph";
|
|
6
|
+
export {
|
|
7
|
+
Paragraph,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { TextAlignLeftIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { p } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/paragraph.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
p
|
|
9
|
+
};
|
|
10
|
+
const meta = {
|
|
11
|
+
category: "text",
|
|
12
|
+
type: "rich-text",
|
|
13
|
+
label: "Paragraph",
|
|
14
|
+
icon: TextAlignLeftIcon,
|
|
15
|
+
states: defaultStates,
|
|
16
|
+
presetStyle,
|
|
17
|
+
template: [
|
|
18
|
+
{
|
|
19
|
+
type: "instance",
|
|
20
|
+
component: "Paragraph",
|
|
21
|
+
children: [{ type: "text", value: "Pragraph you can edit" }]
|
|
22
|
+
}
|
|
23
|
+
],
|
|
24
|
+
order: 2
|
|
25
|
+
};
|
|
26
|
+
const propsMeta = {
|
|
27
|
+
props
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
meta,
|
|
31
|
+
propsMeta
|
|
32
|
+
};
|
package/lib/props.js
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { propsMeta } from "./slot.ws";
|
|
2
|
+
import { propsMeta as propsMeta2 } from "./fragment.ws";
|
|
3
|
+
import { propsMeta as propsMeta3 } from "./html-embed.ws";
|
|
4
|
+
import { propsMeta as propsMeta4 } from "./body.ws";
|
|
5
|
+
import { propsMeta as propsMeta5 } from "./box.ws";
|
|
6
|
+
import { propsMeta as propsMeta6 } from "./text-block.ws";
|
|
7
|
+
import { propsMeta as propsMeta7 } from "./heading.ws";
|
|
8
|
+
import { propsMeta as propsMeta8 } from "./paragraph.ws";
|
|
9
|
+
import { propsMeta as propsMeta9 } from "./link.ws";
|
|
10
|
+
import { propsMeta as propsMeta10 } from "./link-block.ws";
|
|
11
|
+
import { propsMeta as propsMeta11 } from "./rich-text-link.ws";
|
|
12
|
+
import { propsMeta as propsMeta12 } from "./span.ws";
|
|
13
|
+
import { propsMeta as propsMeta13 } from "./bold.ws";
|
|
14
|
+
import { propsMeta as propsMeta14 } from "./italic.ws";
|
|
15
|
+
import { propsMeta as propsMeta15 } from "./superscript.ws";
|
|
16
|
+
import { propsMeta as propsMeta16 } from "./subscript.ws";
|
|
17
|
+
import { propsMeta as propsMeta17 } from "./button.ws";
|
|
18
|
+
import { propsMeta as propsMeta18 } from "./input.ws";
|
|
19
|
+
import { propsMeta as propsMeta19 } from "./form.ws";
|
|
20
|
+
import { propsMeta as propsMeta20 } from "./image.ws";
|
|
21
|
+
import { propsMeta as propsMeta21 } from "./blockquote.ws";
|
|
22
|
+
import { propsMeta as propsMeta22 } from "./list.ws";
|
|
23
|
+
import { propsMeta as propsMeta23 } from "./list-item.ws";
|
|
24
|
+
import { propsMeta as propsMeta24 } from "./separator.ws";
|
|
25
|
+
import { propsMeta as propsMeta25 } from "./code-text.ws";
|
|
26
|
+
import { propsMeta as propsMeta26 } from "./label.ws";
|
|
27
|
+
import { propsMeta as propsMeta27 } from "./success-message.ws";
|
|
28
|
+
import { propsMeta as propsMeta28 } from "./error-message.ws";
|
|
29
|
+
import { propsMeta as propsMeta29 } from "./textarea.ws";
|
|
30
|
+
import { propsMeta as propsMeta30 } from "./radio-button-field.ws";
|
|
31
|
+
import { propsMeta as propsMeta31 } from "./radio-button.ws";
|
|
32
|
+
import { propsMeta as propsMeta32 } from "./checkbox-field.ws";
|
|
33
|
+
import { propsMeta as propsMeta33 } from "./checkbox.ws";
|
|
34
|
+
export {
|
|
35
|
+
propsMeta21 as Blockquote,
|
|
36
|
+
propsMeta4 as Body,
|
|
37
|
+
propsMeta13 as Bold,
|
|
38
|
+
propsMeta5 as Box,
|
|
39
|
+
propsMeta17 as Button,
|
|
40
|
+
propsMeta33 as Checkbox,
|
|
41
|
+
propsMeta32 as CheckboxField,
|
|
42
|
+
propsMeta25 as CodeText,
|
|
43
|
+
propsMeta28 as ErrorMessage,
|
|
44
|
+
propsMeta19 as Form,
|
|
45
|
+
propsMeta2 as Fragment,
|
|
46
|
+
propsMeta7 as Heading,
|
|
47
|
+
propsMeta3 as HtmlEmbed,
|
|
48
|
+
propsMeta20 as Image,
|
|
49
|
+
propsMeta18 as Input,
|
|
50
|
+
propsMeta14 as Italic,
|
|
51
|
+
propsMeta26 as Label,
|
|
52
|
+
propsMeta9 as Link,
|
|
53
|
+
propsMeta10 as LinkBlock,
|
|
54
|
+
propsMeta22 as List,
|
|
55
|
+
propsMeta23 as ListItem,
|
|
56
|
+
propsMeta8 as Paragraph,
|
|
57
|
+
propsMeta31 as RadioButton,
|
|
58
|
+
propsMeta30 as RadioButtonField,
|
|
59
|
+
propsMeta11 as RichTextLink,
|
|
60
|
+
propsMeta24 as Separator,
|
|
61
|
+
propsMeta as Slot,
|
|
62
|
+
propsMeta12 as Span,
|
|
63
|
+
propsMeta16 as Subscript,
|
|
64
|
+
propsMeta27 as SuccessMessage,
|
|
65
|
+
propsMeta15 as Superscript,
|
|
66
|
+
propsMeta6 as TextBlock,
|
|
67
|
+
propsMeta29 as Textarea
|
|
68
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "label";
|
|
4
|
+
const RadioButtonField = forwardRef((props, ref) => /* @__PURE__ */ jsx("label", { ...props, ref }));
|
|
5
|
+
RadioButtonField.displayName = "RadioButtonField";
|
|
6
|
+
export {
|
|
7
|
+
RadioButtonField,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { RadioCheckedIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { props } from "./__generated__/radio-button-field.props";
|
|
6
|
+
import { label } from "@webstudio-is/react-sdk/css-normalize";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
label: [
|
|
9
|
+
...label,
|
|
10
|
+
{ property: "display", value: { type: "keyword", value: "flex" } }
|
|
11
|
+
]
|
|
12
|
+
};
|
|
13
|
+
const meta = {
|
|
14
|
+
category: "forms",
|
|
15
|
+
type: "container",
|
|
16
|
+
label: "Radio",
|
|
17
|
+
icon: RadioCheckedIcon,
|
|
18
|
+
states: defaultStates,
|
|
19
|
+
presetStyle,
|
|
20
|
+
template: [
|
|
21
|
+
{
|
|
22
|
+
type: "instance",
|
|
23
|
+
component: "RadioButtonField",
|
|
24
|
+
children: [
|
|
25
|
+
{ type: "instance", component: "RadioButton", props: [], children: [] },
|
|
26
|
+
{
|
|
27
|
+
type: "instance",
|
|
28
|
+
component: "TextBlock",
|
|
29
|
+
label: "Radio Label",
|
|
30
|
+
props: [],
|
|
31
|
+
children: [{ type: "text", value: "Radio" }]
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
};
|
|
37
|
+
const propsMeta = {
|
|
38
|
+
props,
|
|
39
|
+
initialProps: []
|
|
40
|
+
};
|
|
41
|
+
export {
|
|
42
|
+
meta,
|
|
43
|
+
propsMeta
|
|
44
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "input";
|
|
4
|
+
const RadioButton = forwardRef(({ children: _children, ...props }, ref) => /* @__PURE__ */ jsx("input", { ...props, type: "radio", ref }));
|
|
5
|
+
RadioButton.displayName = "RadioButton";
|
|
6
|
+
export {
|
|
7
|
+
RadioButton,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { RadioCheckedIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { input } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/radio-button.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
input: [
|
|
9
|
+
...input,
|
|
10
|
+
{
|
|
11
|
+
property: "marginRight",
|
|
12
|
+
value: { type: "unit", unit: "em", value: 0.5 }
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
};
|
|
16
|
+
const meta = {
|
|
17
|
+
type: "control",
|
|
18
|
+
label: "Radio Input",
|
|
19
|
+
icon: RadioCheckedIcon,
|
|
20
|
+
presetStyle,
|
|
21
|
+
order: 5,
|
|
22
|
+
states: [
|
|
23
|
+
...defaultStates,
|
|
24
|
+
{ selector: ":checked", label: "Checked" },
|
|
25
|
+
{ selector: ":required", label: "Required" },
|
|
26
|
+
{ selector: ":optional", label: "Optional" },
|
|
27
|
+
{ selector: ":disabled", label: "Disabled" },
|
|
28
|
+
{ selector: ":enabled", label: "Enabled" },
|
|
29
|
+
{ selector: ":read-only", label: "Read Only" },
|
|
30
|
+
{ selector: ":read-write", label: "Read Write" }
|
|
31
|
+
]
|
|
32
|
+
};
|
|
33
|
+
const propsMeta = {
|
|
34
|
+
props,
|
|
35
|
+
initialProps: ["name"]
|
|
36
|
+
};
|
|
37
|
+
export {
|
|
38
|
+
meta,
|
|
39
|
+
propsMeta
|
|
40
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
import { Link } from "./link";
|
|
4
|
+
const RichTextLink = forwardRef((props, ref) => /* @__PURE__ */ jsx(Link, { ...props, ref }));
|
|
5
|
+
RichTextLink.displayName = "RichTextLink";
|
|
6
|
+
export {
|
|
7
|
+
RichTextLink
|
|
8
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { props } from "./__generated__/rich-text-link.props";
|
|
2
|
+
import { meta as linkMeta, propsMeta as linkPropsMeta } from "./link.ws";
|
|
3
|
+
const { category, ...linkMetaRest } = linkMeta;
|
|
4
|
+
const meta = {
|
|
5
|
+
...linkMetaRest,
|
|
6
|
+
type: "rich-text-child",
|
|
7
|
+
template: []
|
|
8
|
+
};
|
|
9
|
+
const propsMeta = {
|
|
10
|
+
initialProps: linkPropsMeta.initialProps,
|
|
11
|
+
props: {
|
|
12
|
+
...props,
|
|
13
|
+
href: linkPropsMeta.props.href
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
meta,
|
|
18
|
+
propsMeta
|
|
19
|
+
};
|
package/lib/separator.js
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import {
|
|
2
|
+
forwardRef,
|
|
3
|
+
createElement
|
|
4
|
+
} from "react";
|
|
5
|
+
const defaultTag = "hr";
|
|
6
|
+
const Separator = forwardRef(
|
|
7
|
+
(props, ref) => {
|
|
8
|
+
return createElement(defaultTag, { ...props, ref });
|
|
9
|
+
}
|
|
10
|
+
);
|
|
11
|
+
Separator.displayName = "Separator";
|
|
12
|
+
export {
|
|
13
|
+
Separator,
|
|
14
|
+
defaultTag
|
|
15
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { DashIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { hr } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/separator.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
hr: [
|
|
9
|
+
...hr,
|
|
10
|
+
{
|
|
11
|
+
property: "height",
|
|
12
|
+
value: { type: "keyword", value: "1px" }
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
property: "backgroundColor",
|
|
16
|
+
value: { type: "keyword", value: "gray" }
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
property: "borderTopStyle",
|
|
20
|
+
value: { type: "keyword", value: "none" }
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
property: "borderRightStyle",
|
|
24
|
+
value: { type: "keyword", value: "none" }
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
property: "borderLeftStyle",
|
|
28
|
+
value: { type: "keyword", value: "none" }
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
property: "borderBottomStyle",
|
|
32
|
+
value: { type: "keyword", value: "none" }
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
};
|
|
36
|
+
const meta = {
|
|
37
|
+
category: "general",
|
|
38
|
+
type: "embed",
|
|
39
|
+
label: "Separator",
|
|
40
|
+
icon: DashIcon,
|
|
41
|
+
states: defaultStates,
|
|
42
|
+
presetStyle,
|
|
43
|
+
order: 5
|
|
44
|
+
};
|
|
45
|
+
const propsMeta = {
|
|
46
|
+
props,
|
|
47
|
+
initialProps: []
|
|
48
|
+
};
|
|
49
|
+
export {
|
|
50
|
+
meta,
|
|
51
|
+
propsMeta
|
|
52
|
+
};
|
package/lib/slot.js
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const Slot = forwardRef((props, ref) => {
|
|
4
|
+
return /* @__PURE__ */ jsx(
|
|
5
|
+
"div",
|
|
6
|
+
{
|
|
7
|
+
...props,
|
|
8
|
+
ref,
|
|
9
|
+
style: { display: props.children ? "contents" : "block" }
|
|
10
|
+
}
|
|
11
|
+
);
|
|
12
|
+
});
|
|
13
|
+
Slot.displayName = "Slot";
|
|
14
|
+
export {
|
|
15
|
+
Slot
|
|
16
|
+
};
|
package/lib/slot.ws.js
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SlotComponentIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
const meta = {
|
|
3
|
+
category: "general",
|
|
4
|
+
type: "container",
|
|
5
|
+
label: "Slot",
|
|
6
|
+
icon: SlotComponentIcon,
|
|
7
|
+
stylable: false,
|
|
8
|
+
order: 6
|
|
9
|
+
};
|
|
10
|
+
const propsMeta = {
|
|
11
|
+
props: {}
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
meta,
|
|
15
|
+
propsMeta
|
|
16
|
+
};
|
package/lib/span.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "span";
|
|
4
|
+
const Span = forwardRef((props, ref) => /* @__PURE__ */ jsx("span", { ...props, ref }));
|
|
5
|
+
Span.displayName = "Span";
|
|
6
|
+
export {
|
|
7
|
+
Span,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
package/lib/span.ws.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { PaintBrushIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { span } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/span.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
span
|
|
9
|
+
};
|
|
10
|
+
const meta = {
|
|
11
|
+
type: "rich-text-child",
|
|
12
|
+
label: "Styled Text",
|
|
13
|
+
icon: PaintBrushIcon,
|
|
14
|
+
states: defaultStates,
|
|
15
|
+
presetStyle
|
|
16
|
+
};
|
|
17
|
+
const propsMeta = {
|
|
18
|
+
props
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
meta,
|
|
22
|
+
propsMeta
|
|
23
|
+
};
|
package/lib/subscript.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "sub";
|
|
4
|
+
const Subscript = forwardRef((props, ref) => /* @__PURE__ */ jsx("sub", { ...props, ref }));
|
|
5
|
+
Subscript.displayName = "Subscript";
|
|
6
|
+
export {
|
|
7
|
+
Subscript,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { SubscriptIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { sub } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/subscript.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
sub
|
|
9
|
+
};
|
|
10
|
+
const meta = {
|
|
11
|
+
type: "rich-text-child",
|
|
12
|
+
label: "Subscript Text",
|
|
13
|
+
icon: SubscriptIcon,
|
|
14
|
+
states: defaultStates,
|
|
15
|
+
presetStyle
|
|
16
|
+
};
|
|
17
|
+
const propsMeta = {
|
|
18
|
+
props
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
meta,
|
|
22
|
+
propsMeta
|
|
23
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "div";
|
|
4
|
+
const SuccessMessage = forwardRef((props, ref) => /* @__PURE__ */ jsx("div", { ...props, ref }));
|
|
5
|
+
SuccessMessage.displayName = "SuccessMessage";
|
|
6
|
+
export {
|
|
7
|
+
SuccessMessage,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { BoxIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import { props } from "./__generated__/success-message.props";
|
|
3
|
+
import { div } from "@webstudio-is/react-sdk/css-normalize";
|
|
4
|
+
const presetStyle = {
|
|
5
|
+
div
|
|
6
|
+
};
|
|
7
|
+
const meta = {
|
|
8
|
+
type: "container",
|
|
9
|
+
label: "Success Message",
|
|
10
|
+
icon: BoxIcon,
|
|
11
|
+
presetStyle
|
|
12
|
+
};
|
|
13
|
+
const propsMeta = {
|
|
14
|
+
props,
|
|
15
|
+
initialProps: []
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
meta,
|
|
19
|
+
propsMeta
|
|
20
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "sup";
|
|
4
|
+
const Superscript = forwardRef((props, ref) => /* @__PURE__ */ jsx("sup", { ...props, ref }));
|
|
5
|
+
Superscript.displayName = "Bold";
|
|
6
|
+
export {
|
|
7
|
+
Superscript,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { SuperscriptIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { sup } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/superscript.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
sup
|
|
9
|
+
};
|
|
10
|
+
const meta = {
|
|
11
|
+
type: "rich-text-child",
|
|
12
|
+
label: "Superscript Text",
|
|
13
|
+
icon: SuperscriptIcon,
|
|
14
|
+
states: defaultStates,
|
|
15
|
+
presetStyle
|
|
16
|
+
};
|
|
17
|
+
const propsMeta = {
|
|
18
|
+
props
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
meta,
|
|
22
|
+
propsMeta
|
|
23
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import {
|
|
2
|
+
createElement,
|
|
3
|
+
forwardRef
|
|
4
|
+
} from "react";
|
|
5
|
+
const defaultTag = "div";
|
|
6
|
+
const TextBlock = forwardRef(
|
|
7
|
+
({ tag = defaultTag, ...props }, ref) => {
|
|
8
|
+
return createElement(tag, { ...props, ref });
|
|
9
|
+
}
|
|
10
|
+
);
|
|
11
|
+
TextBlock.displayName = "TextBlock";
|
|
12
|
+
export {
|
|
13
|
+
TextBlock,
|
|
14
|
+
defaultTag
|
|
15
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { TextBlockIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { div } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/text-block.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
div: [
|
|
9
|
+
...div,
|
|
10
|
+
{
|
|
11
|
+
property: "minHeight",
|
|
12
|
+
value: { type: "unit", unit: "em", value: 1 }
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
};
|
|
16
|
+
const meta = {
|
|
17
|
+
category: "text",
|
|
18
|
+
type: "rich-text",
|
|
19
|
+
label: "Text Block",
|
|
20
|
+
icon: TextBlockIcon,
|
|
21
|
+
states: defaultStates,
|
|
22
|
+
presetStyle,
|
|
23
|
+
template: [
|
|
24
|
+
{
|
|
25
|
+
type: "instance",
|
|
26
|
+
component: "TextBlock",
|
|
27
|
+
children: [{ type: "text", value: "Block of text you can edit" }]
|
|
28
|
+
}
|
|
29
|
+
],
|
|
30
|
+
order: 0
|
|
31
|
+
};
|
|
32
|
+
const propsMeta = {
|
|
33
|
+
props,
|
|
34
|
+
initialProps: ["tag"]
|
|
35
|
+
};
|
|
36
|
+
export {
|
|
37
|
+
meta,
|
|
38
|
+
propsMeta
|
|
39
|
+
};
|
package/lib/textarea.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
const defaultTag = "textarea";
|
|
4
|
+
const Textarea = forwardRef(({ children: _children, ...props }, ref) => /* @__PURE__ */ jsx("textarea", { ...props, ref }));
|
|
5
|
+
Textarea.displayName = "Textarea";
|
|
6
|
+
export {
|
|
7
|
+
Textarea,
|
|
8
|
+
defaultTag
|
|
9
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { FormTextAreaIcon } from "@webstudio-is/icons/svg";
|
|
2
|
+
import {
|
|
3
|
+
defaultStates
|
|
4
|
+
} from "@webstudio-is/react-sdk";
|
|
5
|
+
import { textarea } from "@webstudio-is/react-sdk/css-normalize";
|
|
6
|
+
import { props } from "./__generated__/textarea.props";
|
|
7
|
+
const presetStyle = {
|
|
8
|
+
textarea: [
|
|
9
|
+
...textarea,
|
|
10
|
+
// resize doesn't work well while on canvas
|
|
11
|
+
{ property: "resize", value: { type: "keyword", value: "none" } }
|
|
12
|
+
]
|
|
13
|
+
};
|
|
14
|
+
const meta = {
|
|
15
|
+
category: "forms",
|
|
16
|
+
type: "control",
|
|
17
|
+
label: "Text Area",
|
|
18
|
+
icon: FormTextAreaIcon,
|
|
19
|
+
presetStyle,
|
|
20
|
+
order: 4,
|
|
21
|
+
states: [
|
|
22
|
+
...defaultStates,
|
|
23
|
+
{ selector: "::placeholder", label: "Placeholder" },
|
|
24
|
+
{ selector: ":valid", label: "Valid" },
|
|
25
|
+
{ selector: ":invalid", label: "Invalid" },
|
|
26
|
+
{ selector: ":required", label: "Required" },
|
|
27
|
+
{ selector: ":optional", label: "Optional" },
|
|
28
|
+
{ selector: ":disabled", label: "Disabled" },
|
|
29
|
+
{ selector: ":enabled", label: "Enabled" },
|
|
30
|
+
{ selector: ":read-only", label: "Read Only" },
|
|
31
|
+
{ selector: ":read-write", label: "Read Write" }
|
|
32
|
+
]
|
|
33
|
+
};
|
|
34
|
+
const propsMeta = {
|
|
35
|
+
props,
|
|
36
|
+
initialProps: ["name", "placeholder", "required", "autoFocus"]
|
|
37
|
+
};
|
|
38
|
+
export {
|
|
39
|
+
meta,
|
|
40
|
+
propsMeta
|
|
41
|
+
};
|