Skip to content

Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.

Forms (#1525)

Oleg Isonenabb4c2f639e3
diff --git a/apps/builder/app/builder/builder.tsx b/apps/builder/app/builder/builder.tsx
index feefe5bb51..ee424028d6 100644
--- a/apps/builder/app/builder/builder.tsx
+++ b/apps/builder/app/builder/builder.tsx
@@ -49,6 +49,12 @@ import { useSearchParams } from "@remix-run/react";
import { useSyncInitializeOnce } from "~/shared/hook-utils";
import { BlockingAlerts } from "./features/blocking-alerts";
import { useStore } from "@nanostores/react";
+import {
+ customComponentMetas,
+ customComponentPropsMetas,
+ registerComponentMetas,
+ registerComponentPropsMetas,
+} from "@webstudio-is/react-sdk";
registerContainers();
@@ -240,6 +246,11 @@ export type BuilderProps = {
authPermit: AuthPermit;
};
+// @todo: Don't do this in builder
+// https://github.com/webstudio-is/webstudio-builder/issues/1545
+registerComponentMetas(customComponentMetas);
+registerComponentPropsMetas(customComponentPropsMetas);
+
export const Builder = ({
project,
build,
diff --git a/apps/builder/app/builder/features/inspector/inspector.tsx b/apps/builder/app/builder/features/inspector/inspector.tsx
index d3ed8dbb8d..0065d0ae81 100644
--- a/apps/builder/app/builder/features/inspector/inspector.tsx
+++ b/apps/builder/app/builder/features/inspector/inspector.tsx
@@ -8,7 +8,7 @@ import {
TabsTrigger,
TabsContent,
Card,
- DeprecatedParagraph,
+ Text,
Box,
Flex,
EnhancedTooltipProvider,
@@ -70,9 +70,7 @@ export const Inspector = ({ publish, navigatorLayout }: InspectorProps) => {
<Card
css={{ p: theme.spacing[9], mt: theme.spacing[9], width: "100%" }}
>
- <DeprecatedParagraph>
- Select an instance on the canvas
- </DeprecatedParagraph>
+ <Text>Select an instance on the canvas</Text>
</Card>
</Box>
);
diff --git a/apps/builder/app/builder/features/style-panel/style-panel.tsx b/apps/builder/app/builder/features/style-panel/style-panel.tsx
index aaf791537d..8e6b8982ba 100644
--- a/apps/builder/app/builder/features/style-panel/style-panel.tsx
+++ b/apps/builder/app/builder/features/style-panel/style-panel.tsx
@@ -1,4 +1,11 @@
-import { theme, Box, ScrollArea, Separator } from "@webstudio-is/design-system";
+import {
+ theme,
+ Box,
+ ScrollArea,
+ Separator,
+ Card,
+ Text,
+} from "@webstudio-is/design-system";
import type { Instance } from "@webstudio-is/project-build";
import type { Publish } from "~/shared/pubsub";
@@ -6,6 +13,8 @@ import { useStyleData } from "./shared/use-style-data";
import { StyleSettings } from "./style-settings";
import { StyleSourcesSection } from "./style-source-section";
+import { selectedInstanceIsRenderedStore } from "~/shared/nano-states";
+import { useStore } from "@nanostores/react";
type StylePanelProps = {
publish: Publish;
@@ -19,8 +28,19 @@ export const StylePanel = ({ selectedInstance, publish }: StylePanelProps) => {
publish,
});
- if (currentStyle === undefined || selectedInstance === undefined) {
- return null;
+ const selectedInstaceIsRendered = useStore(selectedInstanceIsRenderedStore);
+
+ // If selected instance is not rendered on the canvas,
+ // style panel will not work, because it needs the element in DOM in order to work.
+ // See <SelectedInstanceConnector> for more details.
+ if (selectedInstaceIsRendered === false) {
+ return (
+ <Box css={{ p: theme.spacing[5] }}>
+ <Card css={{ p: theme.spacing[9], width: "100%" }}>
+ <Text>Select an instance on the canvas</Text>
+ </Card>
+ </Box>
+ );
}
return (
diff --git a/apps/builder/app/canvas/features/webstudio-component/link.ts b/apps/builder/app/canvas/features/webstudio-component/link.ts
index 54a9004f2b..2f1ef63103 100644
--- a/apps/builder/app/canvas/features/webstudio-component/link.ts
+++ b/apps/builder/app/canvas/features/webstudio-component/link.ts
@@ -19,8 +19,6 @@ const isAbsoluteUrl = (href: string) => {
};
export const handleLinkClick = (event: MouseEvent) => {
- event.preventDefault();
-
const pages = pagesStore.get();
if (isPreviewModeStore.get() === false || pages === undefined) {
diff --git a/apps/builder/app/canvas/features/webstudio-component/selected-instance-connector.ts b/apps/builder/app/canvas/features/webstudio-component/selected-instance-connector.ts
index 68cbcbfe90..7daa416b08 100644
--- a/apps/builder/app/canvas/features/webstudio-component/selected-instance-connector.ts
+++ b/apps/builder/app/canvas/features/webstudio-component/selected-instance-connector.ts
@@ -10,6 +10,7 @@ import {
selectedInstanceBrowserStyleStore,
selectedInstanceIntanceToTagStore,
selectedInstanceUnitSizesStore,
+ selectedInstanceIsRenderedStore,
} from "~/shared/nano-states";
import htmlTags, { type htmlTags as HtmlTags } from "html-tags";
import { getAllElementsBoundingBox } from "~/shared/dom-utils";
@@ -174,6 +175,8 @@ export const SelectedInstanceConnector = ({
const unitSizes = calculateUnitSizes(element);
selectedInstanceUnitSizesStore.set(unitSizes);
+ selectedInstanceIsRenderedStore.set(true);
+
return () => {
hideOutline();
resizeObserver.disconnect();
@@ -182,6 +185,7 @@ export const SelectedInstanceConnector = ({
unsubscribeScrollState();
unsubscribeWindowResize();
unsubscribeIsResizingCanvas();
+ selectedInstanceIsRenderedStore.set(false);
};
}, [
instanceElementRef,
diff --git a/apps/builder/app/canvas/features/webstudio-component/webstudio-component.tsx b/apps/builder/app/canvas/features/webstudio-component/webstudio-component.tsx
index cd84013500..86d7a122dd 100644
--- a/apps/builder/app/canvas/features/webstudio-component/webstudio-component.tsx
+++ b/apps/builder/app/canvas/features/webstudio-component/webstudio-component.tsx
@@ -141,7 +141,9 @@ export const WebstudioComponentDev = ({
}, [isSelected]);
const readonlyProps =
- instance.component === "Input" ? { readOnly: true } : undefined;
+ instance.component === "Input" || instance.component === "Textarea"
+ ? { readOnly: true }
+ : undefined;
const Component = getComponent(instance.component);
@@ -156,6 +158,7 @@ export const WebstudioComponentDev = ({
[componentAttribute]: instance.component,
[idAttribute]: instance.id,
onClick: (event: MouseEvent) => {
+ event.preventDefault();
if (event.currentTarget instanceof HTMLAnchorElement) {
handleLinkClick(event);
}
@@ -176,9 +179,7 @@ export const WebstudioComponentDev = ({
instanceProps={instanceProps}
/>
)}
- {/* Component includes many types and it's hard to provide right ref type with useRef */}
- {/* eslint-disable-next-line @typescript-eslint/no-explicit-any */}
- <Component {...props} ref={instanceElementRef as any}>
+ <Component {...props} ref={instanceElementRef}>
{renderWebstudioComponentChildren(children)}
</Component>
</>
diff --git a/apps/builder/app/shared/nano-states/nano-states.ts b/apps/builder/app/shared/nano-states/nano-states.ts
index 301371ff2b..585921278e 100644
--- a/apps/builder/app/shared/nano-states/nano-states.ts
+++ b/apps/builder/app/shared/nano-states/nano-states.ts
@@ -233,6 +233,9 @@ export const selectedInstanceIntanceToTagStore = atom<
undefined | Map<Instance["id"], HtmlTags>
>();
+/** Whether or the selected instance is rendered on canvas */
+export const selectedInstanceIsRenderedStore = atom<boolean>(false);
+
export const selectedInstanceStatesByStyleSourceIdStore = computed(
[stylesStore, styleSourceSelectionsStore, selectedInstanceSelectorStore],
(styles, styleSourceSelections, selectedInstanceSelector) => {
diff --git a/apps/builder/app/shared/sync/sync-stores.ts b/apps/builder/app/shared/sync/sync-stores.ts
index fc5ef7376a..47f69ba470 100644
--- a/apps/builder/app/shared/sync/sync-stores.ts
+++ b/apps/builder/app/shared/sync/sync-stores.ts
@@ -17,6 +17,7 @@ import {
selectedInstanceBrowserStyleStore,
selectedInstanceUnitSizesStore,
selectedInstanceIntanceToTagStore,
+ selectedInstanceIsRenderedStore,
hoveredInstanceSelectorStore,
isPreviewModeStore,
synchronizedCanvasStores,
@@ -78,6 +79,10 @@ export const registerContainers = () => {
"selectedInstanceUnitSizesStore",
selectedInstanceUnitSizesStore
);
+ clientStores.set(
+ "selectedInstanceIsRenderedStore",
+ selectedInstanceIsRenderedStore
+ );
clientStores.set("hoveredInstanceSelector", hoveredInstanceSelectorStore);
clientStores.set("isPreviewMode", isPreviewModeStore);
clientStores.set(
diff --git a/packages/icons/icons/form-text-area.svg b/packages/icons/icons/form-text-area.svg
new file mode 100644
index 0000000000..64a0a9eabd
--- /dev/null
+++ b/packages/icons/icons/form-text-area.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path fill-rule="evenodd" clip-rule="evenodd" d="M1.34998 3.32501C1.34998 2.60152 1.93648 2.01501 2.65998 2.01501H13.3399C14.0634 2.01501 14.6499 2.60152 14.6499 3.32501V9.33267C14.6499 9.33304 14.6499 9.33341 14.6499 9.33379V12.675C14.6499 13.3985 14.0634 13.985 13.3399 13.985H2.65998C1.93648 13.985 1.34998 13.3985 1.34998 12.675V3.32501ZM13.3499 9.06399V3.32501C13.3499 3.32243 13.3495 3.32161 13.3494 3.32132C13.3491 3.3206 13.3484 3.31932 13.347 3.31794C13.3456 3.31657 13.3444 3.31584 13.3436 3.31553L13.3436 3.31552C13.3433 3.31538 13.3424 3.31501 13.3399 3.31501H2.65998C2.65749 3.31501 2.65664 3.31538 2.65632 3.31552L2.65628 3.31553C2.65556 3.31584 2.65428 3.31657 2.6529 3.31794C2.65153 3.31932 2.6508 3.3206 2.65049 3.32132L2.65048 3.32136C2.65034 3.32168 2.64998 3.32253 2.64998 3.32501V12.675C2.64998 12.6776 2.65037 12.6784 2.65049 12.6787C2.6508 12.6794 2.65153 12.6807 2.6529 12.6821C2.65428 12.6835 2.65556 12.6842 2.65628 12.6845L2.65632 12.6845C2.65664 12.6846 2.65749 12.685 2.65998 12.685H9.72892L13.3499 9.06399ZM11.5674 12.685L13.3499 10.9025V12.675C13.3499 12.6776 13.3495 12.6784 13.3494 12.6787C13.3491 12.6794 13.3484 12.6807 13.347 12.6821C13.3456 12.6835 13.3444 12.6842 13.3436 12.6845C13.3436 12.6845 13.3434 12.6846 13.3432 12.6847C13.3427 12.6848 13.3417 12.685 13.3399 12.685H11.5674ZM4.66743 4.67363C5.02641 4.67363 5.31743 4.96464 5.31743 5.32363V7.99363C5.31743 8.35261 5.02641 8.64363 4.66743 8.64363C4.30844 8.64363 4.01743 8.35261 4.01743 7.99363V5.32363C4.01743 4.96464 4.30844 4.67363 4.66743 4.67363Z" />
+</svg>
diff --git a/packages/icons/src/__generated__/form-text-area.tsx b/packages/icons/src/__generated__/form-text-area.tsx
new file mode 100644
index 0000000000..9a49cdfb5d
--- /dev/null
+++ b/packages/icons/src/__generated__/form-text-area.tsx
@@ -0,0 +1,15 @@
+// Generated from icons/form-text-area.svg
+
+import { forwardRef } from "react";
+import type { IconProps } from "../types";
+
+// prettier-ignore
+export const FormTextAreaIcon = forwardRef<SVGSVGElement, IconProps>(
+ ({ color = "currentColor", size = 16, ...props }, forwardedRef) => {
+ return (
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width={size} height={size} fill={color} {...props} ref={forwardedRef}><path fillRule="evenodd" d="M1.35 3.325c0-.723.586-1.31 1.31-1.31h10.68c.723 0 1.31.587 1.31 1.31v9.35a1.31 1.31 0 0 1-1.31 1.31H2.66a1.31 1.31 0 0 1-1.31-1.31v-9.35Zm12 5.739V3.321a.01.01 0 0 0-.003-.003.01.01 0 0 0-.003-.002l-.004-.001H2.656l-.003.003a.012.012 0 0 0-.003.003V12.68a.012.012 0 0 0 .006.005l.004.001h7.069l3.62-3.621Zm-1.783 3.621 1.783-1.783v1.777l-.003.003a.01.01 0 0 1-.003.002l-.004.001h-1.773Zm-6.9-8.011a.65.65 0 0 1 .65.65v2.67a.65.65 0 0 1-1.3 0v-2.67a.65.65 0 0 1 .65-.65Z" clipRule="evenodd" /></svg>
+ );
+ }
+);
+
+FormTextAreaIcon.displayName = "FormTextAreaIcon";
diff --git a/packages/icons/src/__generated__/index.ts b/packages/icons/src/__generated__/index.ts
index a87941dabc..2a02e9343e 100644
--- a/packages/icons/src/__generated__/index.ts
+++ b/packages/icons/src/__generated__/index.ts
@@ -62,6 +62,7 @@ export * from "./email";
export * from "./external-link";
export * from "./eyecon-closed";
export * from "./eyecon-open";
+export * from "./form-text-area";
export * from "./form-text-field";
export * from "./form";
export * from "./gap-horizontal";
diff --git a/packages/react-sdk/package.json b/packages/react-sdk/package.json
index 038ebb8c3a..bff2592208 100644
--- a/packages/react-sdk/package.json
+++ b/packages/react-sdk/package.json
@@ -8,7 +8,7 @@
"scripts": {
"dev": "build-package --watch",
"build": "build-package",
- "build:args": "generate-arg-types './src/components/*.tsx !./src/**/*.stories.tsx !./src/**/*.ws.tsx' && prettier --write \"**/*.props.ts\"",
+ "build:args": "generate-arg-types './src/components/*.tsx ./src/app/custom-components/*.tsx !./src/**/*.stories.tsx !./src/**/*.ws.tsx' && prettier --write \"**/*.props.ts\"",
"dts": "tsc --declarationDir lib/types",
"typecheck": "tsc --noEmit --emitDeclarationOnly false",
"test": "NODE_OPTIONS=--experimental-vm-modules jest --passWithNoTests",
diff --git a/packages/react-sdk/src/app/custom-components/__generated__/form.props.ts b/packages/react-sdk/src/app/custom-components/__generated__/form.props.ts
new file mode 100644
index 0000000000..03c5eeb7e5
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/__generated__/form.props.ts
@@ -0,0 +1,457 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ acceptCharset: { required: false, control: "text", type: "string" },
+ action: { required: false, control: "text", type: "string" },
+ autoComplete: { required: false, control: "text", type: "string" },
+ encType: { required: false, control: "text", type: "string" },
+ method: { required: false, control: "text", type: "string" },
+ name: { required: false, control: "text", type: "string" },
+ noValidate: { required: false, control: "boolean", type: "boolean" },
+ target: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ initialState: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["initial", "success", "error"],
+ },
+};
diff --git a/packages/react-sdk/src/app/custom-components/__generated__/image.props.ts b/packages/react-sdk/src/app/custom-components/__generated__/image.props.ts
new file mode 100644
index 0000000000..1c9a859383
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/__generated__/image.props.ts
@@ -0,0 +1,487 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ alt: { required: false, control: "text", type: "string" },
+ crossOrigin: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["", "anonymous", "use-credentials"],
+ },
+ decoding: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["async", "auto", "sync"],
+ },
+ height: { required: false, control: "number", type: "number" },
+ loading: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["eager", "lazy"],
+ },
+ referrerPolicy: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "",
+ "no-referrer",
+ "no-referrer-when-downgrade",
+ "origin",
+ "origin-when-cross-origin",
+ "same-origin",
+ "strict-origin",
+ "strict-origin-when-cross-origin",
+ "unsafe-url",
+ ],
+ },
+ sizes: { required: false, control: "text", type: "string" },
+ src: { required: false, control: "text", type: "string" },
+ srcSet: { required: false, control: "text", type: "string" },
+ useMap: { required: false, control: "text", type: "string" },
+ width: { required: false, control: "number", type: "number" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ quality: { required: false, control: "number", type: "number" },
+ loader: { required: true, control: "text", type: "string" },
+ optimize: { required: false, control: "boolean", type: "boolean" },
+};
diff --git a/packages/react-sdk/src/app/custom-components/__generated__/link-block.props.ts b/packages/react-sdk/src/app/custom-components/__generated__/link-block.props.ts
new file mode 100644
index 0000000000..d8a7b45ab5
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/__generated__/link-block.props.ts
@@ -0,0 +1,477 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ href: { required: false, control: "text", type: "string" },
+ target: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["_self", "_blank", "_parent", "_top"],
+ },
+ download: { required: false, control: "text", type: "string" },
+ hrefLang: { required: false, control: "text", type: "string" },
+ media: { required: false, control: "text", type: "string" },
+ ping: { required: false, control: "text", type: "string" },
+ type: { required: false, control: "text", type: "string" },
+ referrerPolicy: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "",
+ "no-referrer",
+ "no-referrer-when-downgrade",
+ "origin",
+ "origin-when-cross-origin",
+ "same-origin",
+ "strict-origin",
+ "strict-origin-when-cross-origin",
+ "unsafe-url",
+ ],
+ },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ prefetch: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["none", "intent", "render"],
+ },
+};
diff --git a/packages/react-sdk/src/app/custom-components/__generated__/link.props.ts b/packages/react-sdk/src/app/custom-components/__generated__/link.props.ts
new file mode 100644
index 0000000000..d8a7b45ab5
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/__generated__/link.props.ts
@@ -0,0 +1,477 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ href: { required: false, control: "text", type: "string" },
+ target: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["_self", "_blank", "_parent", "_top"],
+ },
+ download: { required: false, control: "text", type: "string" },
+ hrefLang: { required: false, control: "text", type: "string" },
+ media: { required: false, control: "text", type: "string" },
+ ping: { required: false, control: "text", type: "string" },
+ type: { required: false, control: "text", type: "string" },
+ referrerPolicy: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "",
+ "no-referrer",
+ "no-referrer-when-downgrade",
+ "origin",
+ "origin-when-cross-origin",
+ "same-origin",
+ "strict-origin",
+ "strict-origin-when-cross-origin",
+ "unsafe-url",
+ ],
+ },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ prefetch: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["none", "intent", "render"],
+ },
+};
diff --git a/packages/react-sdk/src/app/custom-components/__generated__/rich-text-link.props.ts b/packages/react-sdk/src/app/custom-components/__generated__/rich-text-link.props.ts
new file mode 100644
index 0000000000..d8a7b45ab5
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/__generated__/rich-text-link.props.ts
@@ -0,0 +1,477 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ href: { required: false, control: "text", type: "string" },
+ target: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["_self", "_blank", "_parent", "_top"],
+ },
+ download: { required: false, control: "text", type: "string" },
+ hrefLang: { required: false, control: "text", type: "string" },
+ media: { required: false, control: "text", type: "string" },
+ ping: { required: false, control: "text", type: "string" },
+ type: { required: false, control: "text", type: "string" },
+ referrerPolicy: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "",
+ "no-referrer",
+ "no-referrer-when-downgrade",
+ "origin",
+ "origin-when-cross-origin",
+ "same-origin",
+ "strict-origin",
+ "strict-origin-when-cross-origin",
+ "unsafe-url",
+ ],
+ },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ prefetch: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["none", "intent", "render"],
+ },
+};
diff --git a/packages/react-sdk/src/app/custom-components/form.tsx b/packages/react-sdk/src/app/custom-components/form.tsx
new file mode 100644
index 0000000000..7bebc10a05
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/form.tsx
@@ -0,0 +1,94 @@
+import {
+ Children,
+ cloneElement,
+ forwardRef,
+ type ReactNode,
+ type ElementRef,
+ type ComponentProps,
+} from "react";
+
+export const defaultTag = "form";
+
+const isComponentNode = (
+ component: string,
+ node: Exclude<ReactNode, null | number | string | boolean | undefined>
+) => "props" in node && node.props.instance?.component === component;
+
+const onlyErrorMessage = (children: ReactNode) =>
+ Children.map(children, (child): ReactNode => {
+ if (typeof child !== "object" || child === null) {
+ return null;
+ }
+
+ if (isComponentNode("ErrorMessage", child)) {
+ return child;
+ }
+
+ if ("props" in child) {
+ const newChildren = onlyErrorMessage(child.props.children);
+ return Children.toArray(newChildren).some((child) => child !== null)
+ ? cloneElement(child, { children: newChildren })
+ : null;
+ }
+
+ return onlyErrorMessage(child);
+ });
+
+const onlySuccessMessage = (children: ReactNode) =>
+ Children.map(children, (child): ReactNode => {
+ if (typeof child !== "object" || child === null) {
+ return null;
+ }
+
+ if (isComponentNode("SuccessMessage", child)) {
+ return child;
+ }
+
+ if ("props" in child) {
+ const newChildren = onlySuccessMessage(child.props.children);
+ return Children.toArray(newChildren).some((child) => child !== null)
+ ? cloneElement(child, { children: newChildren })
+ : null;
+ }
+
+ return onlySuccessMessage(child);
+ });
+
+const withoutMessages = (children: ReactNode) =>
+ Children.map(children, (child): ReactNode => {
+ if (typeof child !== "object" || child === null) {
+ return child;
+ }
+
+ if (
+ isComponentNode("ErrorMessage", child) ||
+ isComponentNode("SuccessMessage", child)
+ ) {
+ return null;
+ }
+
+ if ("props" in child) {
+ return cloneElement(child, {
+ children: withoutMessages(child.props.children),
+ });
+ }
+
+ return withoutMessages(child);
+ });
+
+export const Form = forwardRef<
+ ElementRef<typeof defaultTag>,
+ ComponentProps<typeof defaultTag> & {
+ initialState?: "initial" | "success" | "error";
+ }
+>(({ children, initialState = "initial", ...props }, ref) => (
+ <form {...props} data-state={initialState} ref={ref}>
+ {initialState === "success"
+ ? onlySuccessMessage(children)
+ : initialState === "error"
+ ? onlyErrorMessage(children)
+ : withoutMessages(children)}
+ </form>
+));
+
+Form.displayName = "Form";
diff --git a/packages/react-sdk/src/app/custom-components/form.ws.tsx b/packages/react-sdk/src/app/custom-components/form.ws.tsx
new file mode 100644
index 0000000000..da97e5889a
--- /dev/null
+++ b/packages/react-sdk/src/app/custom-components/form.ws.tsx
@@ -0,0 +1,86 @@
+import { FormIcon } from "@webstudio-is/icons";
+import { form } from "../../css/normalize";
+import type {
+ PresetStyle,
+ WsComponentMeta,
+ WsComponentPropsMeta,
+} from "../../components/component-meta";
+import type { defaultTag } from "./form";
+import { props } from "./__generated__/form.props";
+
+const presetStyle = {
+ form: [
+ ...form,
+ { property: "minHeight", value: { type: "unit", unit: "px", value: 20 } },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ category: "forms",
+ type: "container",
+ label: "Form",
+ Icon: FormIcon,
+ presetStyle,
+ states: [
+ { selector: "[data-state=error]", label: "Error" },
+ { selector: "[data-state=success]", label: "Success" },
+ ],
+ children: [
+ {
+ type: "instance",
+ component: "Label",
+ children: [{ type: "text", value: "Name" }],
+ },
+ {
+ type: "instance",
+ component: "Input",
+ props: [{ type: "string", name: "name", value: "name" }],
+ children: [],
+ },
+ {
+ type: "instance",
+ component: "Label",
+ children: [{ type: "text", value: "Email" }],
+ },
+ {
+ type: "instance",
+ component: "Input",
+ props: [{ type: "string", name: "email", value: "email" }],
+ children: [],
+ },
+ {
+ type: "instance",
+ component: "Button",
+ children: [{ type: "text", value: "Submit" }],
+ },
+ {
+ type: "instance",
+ component: "SuccessMessage",
+ children: [
+ {
+ type: "instance",
+ component: "TextBlock",
+ children: [
+ { type: "text", value: "Thank you for getting in touch!" },
+ ],
+ },
+ ],
+ },
+ {
+ type: "instance",
+ component: "ErrorMessage",
+ children: [
+ {
+ type: "instance",
+ component: "TextBlock",
+ children: [{ type: "text", value: "Sorry, something went wrong." }],
+ },
+ ],
+ },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: ["initialState"],
+};
diff --git a/packages/react-sdk/src/app/custom-components/index.ts b/packages/react-sdk/src/app/custom-components/index.ts
index 746b3e6d0b..59ce524d99 100644
--- a/packages/react-sdk/src/app/custom-components/index.ts
+++ b/packages/react-sdk/src/app/custom-components/index.ts
@@ -1,20 +1,25 @@
+import { imageProps } from "@webstudio-is/image";
+import type { WsComponentPropsMeta } from "../../components/component-meta";
import { Image } from "./image";
import { Link } from "./link";
import { LinkBlock } from "./link-block";
import { RichTextLink } from "./rich-text-link";
-import { imageProps } from "@webstudio-is/image";
-import type { WsComponentPropsMeta } from "../../components/component-meta";
+import { Form } from "./form";
+import { meta as formMeta, propsMeta as formPropsMeta } from "./form.ws";
export const customComponents = {
Image,
Link,
RichTextLink,
LinkBlock,
+ Form,
};
export const customComponentPropsMetas: Record<string, WsComponentPropsMeta> = {
Image: { props: imageProps },
+ Form: formPropsMeta,
};
-// just for completeness, maybe we add soemthing here later
-export const customComponentMetas = {};
+export const customComponentMetas = {
+ Form: formMeta,
+};
diff --git a/packages/react-sdk/src/components/__generated__/checkbox-field.props.ts b/packages/react-sdk/src/components/__generated__/checkbox-field.props.ts
new file mode 100644
index 0000000000..83238636e1
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/checkbox-field.props.ts
@@ -0,0 +1,444 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/checkbox.props.ts b/packages/react-sdk/src/components/__generated__/checkbox.props.ts
new file mode 100644
index 0000000000..c4a9107be7
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/checkbox.props.ts
@@ -0,0 +1,484 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ pattern: { required: false, control: "text", type: "string" },
+ accept: { required: false, control: "text", type: "string" },
+ alt: { required: false, control: "text", type: "string" },
+ autoComplete: { required: false, control: "text", type: "string" },
+ capture: { required: false, control: "text", type: "string" },
+ checked: { required: false, control: "boolean", type: "boolean" },
+ crossOrigin: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["", "anonymous", "use-credentials"],
+ },
+ disabled: { required: false, control: "boolean", type: "boolean" },
+ enterKeyHint: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["enter", "done", "go", "next", "previous", "search", "send"],
+ },
+ formAction: { required: false, control: "text", type: "string" },
+ formEncType: { required: false, control: "text", type: "string" },
+ formMethod: { required: false, control: "text", type: "string" },
+ formNoValidate: { required: false, control: "boolean", type: "boolean" },
+ formTarget: { required: false, control: "text", type: "string" },
+ height: { required: false, control: "number", type: "number" },
+ list: { required: false, control: "text", type: "string" },
+ max: { required: false, control: "number", type: "number" },
+ maxLength: { required: false, control: "number", type: "number" },
+ min: { required: false, control: "number", type: "number" },
+ minLength: { required: false, control: "number", type: "number" },
+ multiple: { required: false, control: "boolean", type: "boolean" },
+ name: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ readOnly: { required: false, control: "boolean", type: "boolean" },
+ required: { required: false, control: "boolean", type: "boolean" },
+ size: { required: false, control: "number", type: "number" },
+ src: { required: false, control: "text", type: "string" },
+ step: { required: false, control: "number", type: "number" },
+ value: { required: false, control: "text", type: "string" },
+ width: { required: false, control: "number", type: "number" },
+ onChange: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "search",
+ "none",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/error-message.props.ts b/packages/react-sdk/src/components/__generated__/error-message.props.ts
new file mode 100644
index 0000000000..e314ec6e6f
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/error-message.props.ts
@@ -0,0 +1,443 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/input.props.ts b/packages/react-sdk/src/components/__generated__/input.props.ts
index 47ddbe6e88..e04b080bf5 100644
--- a/packages/react-sdk/src/components/__generated__/input.props.ts
+++ b/packages/react-sdk/src/components/__generated__/input.props.ts
@@ -22,7 +22,7 @@ export const props: Record<string, PropMeta> = {
required: false,
control: "select",
type: "string",
- options: ["enter", "done", "go", "next", "previous", "search", "send"],
+ options: ["search", "enter", "done", "go", "next", "previous", "send"],
},
formAction: { required: false, control: "text", type: "string" },
formEncType: { required: false, control: "text", type: "string" },
@@ -43,7 +43,12 @@ export const props: Record<string, PropMeta> = {
size: { required: false, control: "number", type: "number" },
src: { required: false, control: "text", type: "string" },
step: { required: false, control: "number", type: "number" },
- type: { required: false, control: "text", type: "string" },
+ type: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["number", "text", "email", "password", "tel", "url"],
+ },
value: { required: false, control: "text", type: "string" },
width: { required: false, control: "number", type: "number" },
onChange: { required: false, control: "text", type: "string" },
@@ -116,10 +121,10 @@ export const props: Record<string, PropMeta> = {
type: "string",
options: [
"text",
- "search",
"email",
"tel",
"url",
+ "search",
"none",
"numeric",
"decimal",
diff --git a/packages/react-sdk/src/components/__generated__/label.props.ts b/packages/react-sdk/src/components/__generated__/label.props.ts
new file mode 100644
index 0000000000..46ea9390be
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/label.props.ts
@@ -0,0 +1,445 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ htmlFor: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/radio-button-field.props.ts b/packages/react-sdk/src/components/__generated__/radio-button-field.props.ts
new file mode 100644
index 0000000000..83238636e1
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/radio-button-field.props.ts
@@ -0,0 +1,444 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/radio-button.props.ts b/packages/react-sdk/src/components/__generated__/radio-button.props.ts
new file mode 100644
index 0000000000..c4a9107be7
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/radio-button.props.ts
@@ -0,0 +1,484 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ pattern: { required: false, control: "text", type: "string" },
+ accept: { required: false, control: "text", type: "string" },
+ alt: { required: false, control: "text", type: "string" },
+ autoComplete: { required: false, control: "text", type: "string" },
+ capture: { required: false, control: "text", type: "string" },
+ checked: { required: false, control: "boolean", type: "boolean" },
+ crossOrigin: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["", "anonymous", "use-credentials"],
+ },
+ disabled: { required: false, control: "boolean", type: "boolean" },
+ enterKeyHint: {
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["enter", "done", "go", "next", "previous", "search", "send"],
+ },
+ formAction: { required: false, control: "text", type: "string" },
+ formEncType: { required: false, control: "text", type: "string" },
+ formMethod: { required: false, control: "text", type: "string" },
+ formNoValidate: { required: false, control: "boolean", type: "boolean" },
+ formTarget: { required: false, control: "text", type: "string" },
+ height: { required: false, control: "number", type: "number" },
+ list: { required: false, control: "text", type: "string" },
+ max: { required: false, control: "number", type: "number" },
+ maxLength: { required: false, control: "number", type: "number" },
+ min: { required: false, control: "number", type: "number" },
+ minLength: { required: false, control: "number", type: "number" },
+ multiple: { required: false, control: "boolean", type: "boolean" },
+ name: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ readOnly: { required: false, control: "boolean", type: "boolean" },
+ required: { required: false, control: "boolean", type: "boolean" },
+ size: { required: false, control: "number", type: "number" },
+ src: { required: false, control: "text", type: "string" },
+ step: { required: false, control: "number", type: "number" },
+ value: { required: false, control: "text", type: "string" },
+ width: { required: false, control: "number", type: "number" },
+ onChange: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "search",
+ "none",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/success-message.props.ts b/packages/react-sdk/src/components/__generated__/success-message.props.ts
new file mode 100644
index 0000000000..e314ec6e6f
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/success-message.props.ts
@@ -0,0 +1,443 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/__generated__/textarea.props.ts b/packages/react-sdk/src/components/__generated__/textarea.props.ts
new file mode 100644
index 0000000000..8e49141fc6
--- /dev/null
+++ b/packages/react-sdk/src/components/__generated__/textarea.props.ts
@@ -0,0 +1,457 @@
+import type { PropMeta } from "@webstudio-is/generate-arg-types";
+
+export const props: Record<string, PropMeta> = {
+ form: { required: false, control: "text", type: "string" },
+ slot: { required: false, control: "text", type: "string" },
+ style: { required: false, control: "text", type: "string" },
+ title: { required: false, control: "text", type: "string" },
+ autoComplete: { required: false, control: "text", type: "string" },
+ cols: { required: false, control: "number", type: "number" },
+ dirName: { required: false, control: "text", type: "string" },
+ disabled: { required: false, control: "boolean", type: "boolean" },
+ maxLength: { required: false, control: "number", type: "number" },
+ minLength: { required: false, control: "number", type: "number" },
+ name: { required: false, control: "text", type: "string" },
+ placeholder: { required: false, control: "text", type: "string" },
+ readOnly: { required: false, control: "boolean", type: "boolean" },
+ required: { required: false, control: "boolean", type: "boolean" },
+ rows: { required: false, control: "number", type: "number" },
+ value: { required: false, control: "text", type: "string" },
+ wrap: { required: false, control: "text", type: "string" },
+ onChange: { required: false, control: "text", type: "string" },
+ defaultChecked: { required: false, control: "boolean", type: "boolean" },
+ defaultValue: { required: false, control: "text", type: "string" },
+ suppressContentEditableWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ suppressHydrationWarning: {
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ accessKey: { required: false, control: "text", type: "string" },
+ autoFocus: { required: false, control: "boolean", type: "boolean" },
+ className: { required: false, control: "text", type: "string" },
+ contentEditable: { required: false, control: "text", type: "string" },
+ contextMenu: { required: false, control: "text", type: "string" },
+ dir: { required: false, control: "text", type: "string" },
+ draggable: { required: false, control: "boolean", type: "boolean" },
+ hidden: { required: false, control: "boolean", type: "boolean" },
+ id: { required: false, control: "text", type: "string" },
+ lang: { required: false, control: "text", type: "string" },
+ nonce: { required: false, control: "text", type: "string" },
+ spellCheck: { required: false, control: "boolean", type: "boolean" },
+ tabIndex: { required: false, control: "number", type: "number" },
+ translate: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["yes", "no"],
+ },
+ radioGroup: { required: false, control: "text", type: "string" },
+ role: { required: false, control: "text", type: "string" },
+ about: { required: false, control: "text", type: "string" },
+ content: { required: false, control: "text", type: "string" },
+ datatype: { required: false, control: "text", type: "string" },
+ inlist: { required: false, control: "text", type: "string" },
+ prefix: { required: false, control: "text", type: "string" },
+ property: { required: false, control: "text", type: "string" },
+ rel: { required: false, control: "text", type: "string" },
+ resource: { required: false, control: "text", type: "string" },
+ rev: { required: false, control: "text", type: "string" },
+ typeof: { required: false, control: "text", type: "string" },
+ vocab: { required: false, control: "text", type: "string" },
+ autoCapitalize: { required: false, control: "text", type: "string" },
+ autoCorrect: { required: false, control: "text", type: "string" },
+ autoSave: { required: false, control: "text", type: "string" },
+ color: { required: false, control: "color", type: "string" },
+ itemProp: { required: false, control: "text", type: "string" },
+ itemScope: { required: false, control: "boolean", type: "boolean" },
+ itemType: { required: false, control: "text", type: "string" },
+ itemID: { required: false, control: "text", type: "string" },
+ itemRef: { required: false, control: "text", type: "string" },
+ results: { required: false, control: "number", type: "number" },
+ security: { required: false, control: "text", type: "string" },
+ unselectable: {
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["on", "off"],
+ },
+ inputMode: {
+ description:
+ "Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "none",
+ "search",
+ "tel",
+ "url",
+ "email",
+ "numeric",
+ "decimal",
+ ],
+ },
+ is: {
+ description:
+ "Specify that a standard HTML element should behave like a defined custom built-in element\n@see https://html.spec.whatwg.org/multipage/custom-elements.html#attr-is",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-activedescendant": {
+ description:
+ "Identifies the currently active element when DOM focus is on a composite widget, textbox, group, or application.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-atomic": {
+ description:
+ "Indicates whether assistive technologies will present all, or only parts of, the changed region based on the change notifications defined by the aria-relevant attribute.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-autocomplete": {
+ description:
+ "Indicates whether inputting text could trigger display of one or more predictions of the user's intended value for an input and specifies how predictions would be\npresented if they are made.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["list", "none", "inline", "both"],
+ },
+ "aria-busy": {
+ description:
+ "Indicates an element is being modified and that assistive technologies MAY want to wait until the modifications are complete before exposing them to the user.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-checked": {
+ description:
+ 'Indicates the current "checked" state of checkboxes, radio buttons, and other widgets.\n@see aria-pressed\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-colcount": {
+ description:
+ "Defines the total number of columns in a table, grid, or treegrid.\n@see aria-colindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colindex": {
+ description:
+ "Defines an element's column index or position with respect to the total number of columns within a table, grid, or treegrid.\n@see aria-colcount\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-colspan": {
+ description:
+ "Defines the number of columns spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-colindex\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-controls": {
+ description:
+ "Identifies the element (or elements) whose contents or presence are controlled by the current element.\n@see aria-owns.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-current": {
+ description:
+ "Indicates the element that represents the current item within a container or set of related elements.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-describedby": {
+ description:
+ "Identifies the element (or elements) that describes the object.\n@see aria-labelledby",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-details": {
+ description:
+ "Identifies the element that provides a detailed, extended description for the object.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-disabled": {
+ description:
+ "Indicates that the element is perceivable but disabled, so it is not editable or otherwise operable.\n@see aria-hidden\n@see aria-readonly.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-dropeffect": {
+ description:
+ "Indicates what functions can be performed when a dragged object is released on the drop target.\n@deprecated in ARIA 1.1",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["link", "none", "copy", "execute", "move", "popup"],
+ },
+ "aria-errormessage": {
+ description:
+ "Identifies the element that provides an error message for the object.\n@see aria-invalid\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-expanded": {
+ description:
+ "Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-flowto": {
+ description:
+ "Identifies the next element (or elements) in an alternate reading order of content which, at the user's discretion,\nallows assistive technology to override the general default of reading in document source order.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-grabbed": {
+ description:
+ 'Indicates an element\'s "grabbed" state in a drag-and-drop operation.\n@deprecated in ARIA 1.1',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-haspopup": {
+ description:
+ "Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-hidden": {
+ description:
+ "Indicates whether the element is exposed to an accessibility API.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-invalid": {
+ description:
+ "Indicates the entered value does not conform to the format expected by the application.\n@see aria-errormessage.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-keyshortcuts": {
+ description:
+ "Indicates keyboard shortcuts that an author has implemented to activate or give focus to an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-label": {
+ description:
+ "Defines a string value that labels the current element.\n@see aria-labelledby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-labelledby": {
+ description:
+ "Identifies the element (or elements) that labels the current element.\n@see aria-describedby.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-level": {
+ description:
+ "Defines the hierarchical level of an element within a structure.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-live": {
+ description:
+ "Indicates that an element will be updated, and describes the types of updates the user agents, assistive technologies, and user can expect from the live region.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["off", "assertive", "polite"],
+ },
+ "aria-modal": {
+ description: "Indicates whether an element is modal when displayed.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiline": {
+ description:
+ "Indicates whether a text box accepts multiple lines of input or only a single line.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-multiselectable": {
+ description:
+ "Indicates that the user may select more than one item from the current selectable descendants.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-orientation": {
+ description:
+ "Indicates whether the element's orientation is horizontal, vertical, or unknown/ambiguous.",
+ required: false,
+ control: "radio",
+ type: "string",
+ options: ["horizontal", "vertical"],
+ },
+ "aria-owns": {
+ description:
+ "Identifies an element (or elements) in order to define a visual, functional, or contextual parent/child relationship\nbetween DOM elements where the DOM hierarchy cannot be used to represent the relationship.\n@see aria-controls.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-placeholder": {
+ description:
+ "Defines a short hint (a word or short phrase) intended to aid the user with data entry when the control has no value.\nA hint could be a sample value or a brief description of the expected format.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-posinset": {
+ description:
+ "Defines an element's number or position in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-setsize.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-pressed": {
+ description:
+ 'Indicates the current "pressed" state of toggle buttons.\n@see aria-checked\n@see aria-selected.',
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-readonly": {
+ description:
+ "Indicates that the element is not editable, but is otherwise operable.\n@see aria-disabled.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-relevant": {
+ description:
+ "Indicates what notifications the user agent will trigger when the accessibility tree within a live region is modified.\n@see aria-atomic.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: [
+ "text",
+ "additions",
+ "additions removals",
+ "additions text",
+ "all",
+ "removals",
+ "removals additions",
+ "removals text",
+ "text additions",
+ "text removals",
+ ],
+ },
+ "aria-required": {
+ description:
+ "Indicates that user input is required on the element before a form may be submitted.",
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-roledescription": {
+ description:
+ "Defines a human-readable, author-localized description for the role of an element.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+ "aria-rowcount": {
+ description:
+ "Defines the total number of rows in a table, grid, or treegrid.\n@see aria-rowindex.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowindex": {
+ description:
+ "Defines an element's row index or position with respect to the total number of rows within a table, grid, or treegrid.\n@see aria-rowcount\n@see aria-rowspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-rowspan": {
+ description:
+ "Defines the number of rows spanned by a cell or gridcell within a table, grid, or treegrid.\n@see aria-rowindex\n@see aria-colspan.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-selected": {
+ description:
+ 'Indicates the current "selected" state of various widgets.\n@see aria-checked\n@see aria-pressed.',
+ required: false,
+ control: "boolean",
+ type: "boolean",
+ },
+ "aria-setsize": {
+ description:
+ "Defines the number of items in the current set of listitems or treeitems. Not required if all elements in the set are present in the DOM.\n@see aria-posinset.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-sort": {
+ description:
+ "Indicates if items in a table or grid are sorted in ascending or descending order.",
+ required: false,
+ control: "select",
+ type: "string",
+ options: ["none", "ascending", "descending", "other"],
+ },
+ "aria-valuemax": {
+ description: "Defines the maximum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuemin": {
+ description: "Defines the minimum allowed value for a range widget.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuenow": {
+ description:
+ "Defines the current value for a range widget.\n@see aria-valuetext.",
+ required: false,
+ control: "number",
+ type: "number",
+ },
+ "aria-valuetext": {
+ description:
+ "Defines the human readable text alternative of aria-valuenow for a range widget.",
+ required: false,
+ control: "text",
+ type: "string",
+ },
+};
diff --git a/packages/react-sdk/src/components/button.ws.tsx b/packages/react-sdk/src/components/button.ws.tsx
index 32be0af45b..44946cdca7 100644
--- a/packages/react-sdk/src/components/button.ws.tsx
+++ b/packages/react-sdk/src/components/button.ws.tsx
@@ -13,11 +13,16 @@ const presetStyle = {
} satisfies PresetStyle<typeof defaultTag>;
export const meta: WsComponentMeta = {
- category: "forms",
+ category: "general",
type: "container",
label: "Button",
Icon: ButtonElementIcon,
presetStyle,
+ states: [
+ { selector: ":active", label: "Active" },
+ { selector: ":disabled", label: "Disabled" },
+ { selector: ":enabled", label: "Enabled" },
+ ],
};
export const propsMeta: WsComponentPropsMeta = {
diff --git a/packages/react-sdk/src/components/checkbox-field.tsx b/packages/react-sdk/src/components/checkbox-field.tsx
new file mode 100644
index 0000000000..e5d3a8c774
--- /dev/null
+++ b/packages/react-sdk/src/components/checkbox-field.tsx
@@ -0,0 +1,10 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "label";
+
+export const CheckboxField = forwardRef<
+ ElementRef<typeof defaultTag>,
+ Omit<ComponentProps<typeof defaultTag>, "htmlFor">
+>((props, ref) => <label {...props} ref={ref} />);
+
+CheckboxField.displayName = "CheckboxField";
diff --git a/packages/react-sdk/src/components/checkbox-field.ws.tsx b/packages/react-sdk/src/components/checkbox-field.ws.tsx
new file mode 100644
index 0000000000..aed3feef41
--- /dev/null
+++ b/packages/react-sdk/src/components/checkbox-field.ws.tsx
@@ -0,0 +1,38 @@
+import { CheckboxCheckedFilledIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import { props } from "./__generated__/checkbox-field.props";
+import type { defaultTag } from "./checkbox-field";
+import { label } from "../css/normalize";
+
+const presetStyle = {
+ label: [
+ ...label,
+ { property: "display", value: { type: "keyword", value: "flex" } },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ category: "forms",
+ type: "container",
+ label: "Checkbox Field",
+ Icon: CheckboxCheckedFilledIcon,
+ presetStyle,
+ children: [
+ { type: "instance", component: "Checkbox", props: [], children: [] },
+ {
+ type: "instance",
+ component: "TextBlock",
+ props: [],
+ children: [{ type: "text", value: "Checkbox" }],
+ },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: [],
+};
diff --git a/packages/react-sdk/src/components/checkbox.tsx b/packages/react-sdk/src/components/checkbox.tsx
new file mode 100644
index 0000000000..b3ad8a9dd9
--- /dev/null
+++ b/packages/react-sdk/src/components/checkbox.tsx
@@ -0,0 +1,13 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "input";
+
+export const Checkbox = forwardRef<
+ ElementRef<typeof defaultTag>,
+ Omit<ComponentProps<typeof defaultTag>, "type">
+ // Make sure children are not passed down to an input, because this will result in error.
+>(({ children: _children, ...props }, ref) => (
+ <input {...props} type="checkbox" ref={ref} />
+));
+
+Checkbox.displayName = "Checkbox";
diff --git a/packages/react-sdk/src/components/checkbox.ws.tsx b/packages/react-sdk/src/components/checkbox.ws.tsx
new file mode 100644
index 0000000000..af8c182f5e
--- /dev/null
+++ b/packages/react-sdk/src/components/checkbox.ws.tsx
@@ -0,0 +1,40 @@
+import { CheckboxCheckedFilledIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import type { defaultTag } from "./checkbox";
+import { input } from "../css/normalize";
+import { props } from "./__generated__/checkbox.props";
+
+const presetStyle = {
+ input: [
+ ...input,
+ {
+ property: "marginRight",
+ value: { type: "unit", unit: "em", value: 0.5 },
+ },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ type: "control",
+ label: "Checkbox",
+ Icon: CheckboxCheckedFilledIcon,
+ presetStyle,
+ states: [
+ { selector: ":checked", label: "Checked" },
+ { selector: ":required", label: "Required" },
+ { selector: ":optional", label: "Optional" },
+ { selector: ":disabled", label: "Disabled" },
+ { selector: ":enabled", label: "Enabled" },
+ { selector: ":read-only", label: "Read Only" },
+ { selector: ":read-write", label: "Read Write" },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: ["name"],
+};
diff --git a/packages/react-sdk/src/components/components-utils.ts b/packages/react-sdk/src/components/components-utils.ts
index a8efd603b6..e7a58c6e80 100644
--- a/packages/react-sdk/src/components/components-utils.ts
+++ b/packages/react-sdk/src/components/components-utils.ts
@@ -1,3 +1,4 @@
+import type { forwardRef } from "react";
import * as components from "./components";
import { registeredComponents } from "./index";
@@ -34,6 +35,14 @@ const componentNames = Object.keys({
ListItem: 1,
Separator: 1,
Code: 1,
+ Label: 1,
+ SuccessMessage: 1,
+ ErrorMessage: 1,
+ Textarea: 1,
+ RadioButtonField: 1,
+ RadioButton: 1,
+ CheckboxField: 1,
+ Checkbox: 1,
} satisfies { [K in keyof typeof components]: 1 }) as Array<
keyof typeof components
>;
@@ -47,17 +56,16 @@ export const getComponentNames = (): ComponentName[] => {
return Array.from(uniqueNames) as ComponentName[];
};
+// eslint-disable-next-line @typescript-eslint/no-explicit-any
+type AnyComponent = ReturnType<typeof forwardRef<any, any>>;
+
/**
* Now used only in builder app
* @todo Consider using the same approach in the builder app as in the published apps . A dynamic import is needed
*/
-export const getComponent = (
- name: string
-): undefined | (typeof components)[ComponentName] => {
+export const getComponent = (name: string): undefined | AnyComponent => {
return registeredComponents != null && name in registeredComponents
- ? (registeredComponents[
- name as ComponentName
- ] as (typeof components)[ComponentName])
+ ? (registeredComponents[name as ComponentName] as AnyComponent)
: components[name as ComponentName];
};
@@ -68,11 +76,9 @@ export const getComponent = (
* see example /packages/sdk-size-test/app/routes/$.tsx
**/
export const createGetComponent = (comps: Partial<typeof components>) => {
- return (name: string) => {
+ return (name: string): undefined | AnyComponent => {
return registeredComponents != null && name in registeredComponents
- ? (registeredComponents[
- name as ComponentName
- ] as (typeof components)[ComponentName])
+ ? (registeredComponents[name as ComponentName] as AnyComponent)
: comps[name as ComponentName];
};
};
diff --git a/packages/react-sdk/src/components/components.ts b/packages/react-sdk/src/components/components.ts
index 0a72263d70..7f2844b646 100644
--- a/packages/react-sdk/src/components/components.ts
+++ b/packages/react-sdk/src/components/components.ts
@@ -29,3 +29,11 @@ export { List } from "./list";
export { ListItem } from "./list-item";
export { Separator } from "./separator";
export { Code } from "./code";
+export { Label } from "./label";
+export { SuccessMessage } from "./success-message";
+export { ErrorMessage } from "./error-message";
+export { Textarea } from "./textarea";
+export { RadioButtonField } from "./radio-button-field";
+export { RadioButton } from "./radio-button";
+export { CheckboxField } from "./checkbox-field";
+export { Checkbox } from "./checkbox";
diff --git a/packages/react-sdk/src/components/error-message.tsx b/packages/react-sdk/src/components/error-message.tsx
new file mode 100644
index 0000000000..65ca0bd55d
--- /dev/null
+++ b/packages/react-sdk/src/components/error-message.tsx
@@ -0,0 +1,10 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "div";
+
+export const ErrorMessage = forwardRef<
+ ElementRef<typeof defaultTag>,
+ ComponentProps<typeof defaultTag>
+>((props, ref) => <div {...props} ref={ref} />);
+
+ErrorMessage.displayName = "ErrorMessage";
diff --git a/packages/react-sdk/src/components/error-message.ws.tsx b/packages/react-sdk/src/components/error-message.ws.tsx
new file mode 100644
index 0000000000..74cb6c7ee4
--- /dev/null
+++ b/packages/react-sdk/src/components/error-message.ws.tsx
@@ -0,0 +1,24 @@
+import { BoxIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import { props } from "./__generated__/error-message.props";
+import { div } from "../css/normalize";
+
+const presetStyle = {
+ div,
+} satisfies PresetStyle<"div">;
+
+export const meta: WsComponentMeta = {
+ type: "container",
+ label: "Error Message",
+ Icon: BoxIcon,
+ presetStyle,
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: [],
+};
diff --git a/packages/react-sdk/src/components/form.tsx b/packages/react-sdk/src/components/form.tsx
index 4e30f337f4..69041526c2 100644
--- a/packages/react-sdk/src/components/form.tsx
+++ b/packages/react-sdk/src/components/form.tsx
@@ -5,6 +5,10 @@ export const defaultTag = "form";
export const Form = forwardRef<
ElementRef<typeof defaultTag>,
ComponentProps<typeof defaultTag>
->((props, ref) => <form {...props} ref={ref} />);
+>(({ children, ...props }, ref) => (
+ <form {...props} ref={ref}>
+ {children}
+ </form>
+));
Form.displayName = "Form";
diff --git a/packages/react-sdk/src/components/form.ws.tsx b/packages/react-sdk/src/components/form.ws.tsx
index afa9a30d0a..f720c329e8 100644
--- a/packages/react-sdk/src/components/form.ws.tsx
+++ b/packages/react-sdk/src/components/form.ws.tsx
@@ -11,10 +11,7 @@ import { props } from "./__generated__/form.props";
const presetStyle = {
form: [
...form,
- {
- property: "minHeight",
- value: { type: "unit", unit: "px", value: 20 },
- },
+ { property: "minHeight", value: { type: "unit", unit: "px", value: 20 } },
],
} satisfies PresetStyle<typeof defaultTag>;
@@ -25,7 +22,28 @@ export const meta: WsComponentMeta = {
Icon: FormIcon,
presetStyle,
children: [
- { type: "instance", component: "Input", children: [] },
+ {
+ type: "instance",
+ component: "Label",
+ children: [{ type: "text", value: "Name" }],
+ },
+ {
+ type: "instance",
+ component: "Input",
+ props: [{ type: "string", name: "name", value: "name" }],
+ children: [],
+ },
+ {
+ type: "instance",
+ component: "Label",
+ children: [{ type: "text", value: "Email" }],
+ },
+ {
+ type: "instance",
+ component: "Input",
+ props: [{ type: "string", name: "email", value: "email" }],
+ children: [],
+ },
{
type: "instance",
component: "Button",
@@ -36,4 +54,5 @@ export const meta: WsComponentMeta = {
export const propsMeta: WsComponentPropsMeta = {
props,
+ initialProps: [],
};
diff --git a/packages/react-sdk/src/components/index.ts b/packages/react-sdk/src/components/index.ts
index 775eca2ecd..21903bd105 100644
--- a/packages/react-sdk/src/components/index.ts
+++ b/packages/react-sdk/src/components/index.ts
@@ -25,6 +25,14 @@ import { meta as ListMeta } from "./list.ws";
import { meta as ListItemMeta } from "./list-item.ws";
import { meta as SeparatorMeta } from "./separator.ws";
import { meta as CodeMeta } from "./code.ws";
+import { meta as LabelMeta } from "./label.ws";
+import { meta as SuccessMessageMeta } from "./success-message.ws";
+import { meta as ErrorMessageMeta } from "./error-message.ws";
+import { meta as TextareaMeta } from "./textarea.ws";
+import { meta as RadioButtonFieldMeta } from "./radio-button-field.ws";
+import { meta as RadioButtonMeta } from "./radio-button.ws";
+import { meta as CheckboxFieldMeta } from "./checkbox-field.ws";
+import { meta as CheckboxMeta } from "./checkbox.ws";
// these are huge JSON objects that we want to be tree-shaken when not used!
import { propsMeta as SlotMetaPropsMeta } from "./slot.ws";
@@ -51,6 +59,14 @@ import { propsMeta as ListPropsMeta } from "./list.ws";
import { propsMeta as ListItemPropsMeta } from "./list-item.ws";
import { propsMeta as SeparatorPropsMeta } from "./separator.ws";
import { propsMeta as CodePropsMeta } from "./code.ws";
+import { propsMeta as LabelPropsMeta } from "./label.ws";
+import { propsMeta as SuccessMessagePropsMeta } from "./success-message.ws";
+import { propsMeta as ErrorMessagePropsMeta } from "./error-message.ws";
+import { propsMeta as TextareaPropsMeta } from "./textarea.ws";
+import { propsMeta as RadioButtonFieldPropsMeta } from "./radio-button-field.ws";
+import { propsMeta as RadioButtonPropsMeta } from "./radio-button.ws";
+import { propsMeta as CheckboxFieldPropsMeta } from "./checkbox-field.ws";
+import { propsMeta as CheckboxPropsMeta } from "./checkbox.ws";
// @todo this list should not be hardcoded!
const defaultMetas: Record<string, WsComponentMeta> = {
@@ -78,6 +94,14 @@ const defaultMetas: Record<string, WsComponentMeta> = {
ListItem: ListItemMeta,
Separator: SeparatorMeta,
Code: CodeMeta,
+ Label: LabelMeta,
+ SuccessMessage: SuccessMessageMeta,
+ ErrorMessage: ErrorMessageMeta,
+ Textarea: TextareaMeta,
+ RadioButtonField: RadioButtonFieldMeta,
+ RadioButton: RadioButtonMeta,
+ CheckboxField: CheckboxFieldMeta,
+ Checkbox: CheckboxMeta,
};
let currentMetas = defaultMetas;
@@ -122,6 +146,14 @@ const defaultPropsMetasRaw = {
ListItem: ListItemPropsMeta,
Separator: SeparatorPropsMeta,
Code: CodePropsMeta,
+ Label: LabelPropsMeta,
+ SuccessMessage: SuccessMessagePropsMeta,
+ ErrorMessage: ErrorMessagePropsMeta,
+ Textarea: TextareaPropsMeta,
+ RadioButtonField: RadioButtonFieldPropsMeta,
+ RadioButton: RadioButtonPropsMeta,
+ CheckboxField: CheckboxFieldPropsMeta,
+ Checkbox: CheckboxPropsMeta,
} as const;
const defaultPropsMetas: Record<string, WsComponentPropsMeta> =
diff --git a/packages/react-sdk/src/components/input.tsx b/packages/react-sdk/src/components/input.tsx
index f6b19da07f..5f48278269 100644
--- a/packages/react-sdk/src/components/input.tsx
+++ b/packages/react-sdk/src/components/input.tsx
@@ -4,7 +4,9 @@ export const defaultTag = "input";
export const Input = forwardRef<
ElementRef<typeof defaultTag>,
- ComponentProps<typeof defaultTag>
+ ComponentProps<typeof defaultTag> & {
+ type?: "text" | "email" | "password" | "number" | "tel" | "url";
+ }
// Make sure children are not passed down to an input, because this will result in error.
>(({ children: _children, ...props }, ref) => <input {...props} ref={ref} />);
diff --git a/packages/react-sdk/src/components/input.ws.tsx b/packages/react-sdk/src/components/input.ws.tsx
index ec0acc39da..55265d2a8c 100644
--- a/packages/react-sdk/src/components/input.ws.tsx
+++ b/packages/react-sdk/src/components/input.ws.tsx
@@ -15,11 +15,23 @@ const presetStyle = {
export const meta: WsComponentMeta = {
category: "forms",
type: "control",
- label: "Input",
+ label: "Text Field",
Icon: FormTextFieldIcon,
presetStyle,
+ states: [
+ { selector: "::placeholder", label: "Placeholder" },
+ { selector: ":valid", label: "Valid" },
+ { selector: ":invalid", label: "Invalid" },
+ { selector: ":required", label: "Required" },
+ { selector: ":optional", label: "Optional" },
+ { selector: ":disabled", label: "Disabled" },
+ { selector: ":enabled", label: "Enabled" },
+ { selector: ":read-only", label: "Read Only" },
+ { selector: ":read-write", label: "Read Write" },
+ ],
};
export const propsMeta: WsComponentPropsMeta = {
props,
+ initialProps: ["name", "type", "placeholder", "required", "autoFocus"],
};
diff --git a/packages/react-sdk/src/components/label.tsx b/packages/react-sdk/src/components/label.tsx
new file mode 100644
index 0000000000..121c171c07
--- /dev/null
+++ b/packages/react-sdk/src/components/label.tsx
@@ -0,0 +1,10 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "label";
+
+export const Label = forwardRef<
+ ElementRef<typeof defaultTag>,
+ ComponentProps<typeof defaultTag>
+>((props, ref) => <label {...props} ref={ref} />);
+
+Label.displayName = "Label";
diff --git a/packages/react-sdk/src/components/label.ws.tsx b/packages/react-sdk/src/components/label.ws.tsx
new file mode 100644
index 0000000000..f5fc0152aa
--- /dev/null
+++ b/packages/react-sdk/src/components/label.ws.tsx
@@ -0,0 +1,39 @@
+import { TextBlockIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import { props } from "./__generated__/label.props";
+import type { defaultTag } from "./label";
+import { label } from "../css/normalize";
+
+const presetStyle = {
+ label: [
+ ...label,
+ { property: "display", value: { type: "keyword", value: "block" } },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ category: "forms",
+ type: "rich-text",
+ label: "Input Label",
+ Icon: TextBlockIcon,
+ presetStyle,
+ children: [{ type: "text", value: "Form Label" }],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props: {
+ ...props,
+ htmlFor: {
+ required: false,
+ control: "text",
+ type: "string",
+ rows: 0,
+ label: "For",
+ },
+ },
+ initialProps: ["htmlFor"],
+};
diff --git a/packages/react-sdk/src/components/radio-button-field.tsx b/packages/react-sdk/src/components/radio-button-field.tsx
new file mode 100644
index 0000000000..4fc6a2d128
--- /dev/null
+++ b/packages/react-sdk/src/components/radio-button-field.tsx
@@ -0,0 +1,10 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "label";
+
+export const RadioButtonField = forwardRef<
+ ElementRef<typeof defaultTag>,
+ Omit<ComponentProps<typeof defaultTag>, "htmlFor">
+>((props, ref) => <label {...props} ref={ref} />);
+
+RadioButtonField.displayName = "RadioButtonField";
diff --git a/packages/react-sdk/src/components/radio-button-field.ws.tsx b/packages/react-sdk/src/components/radio-button-field.ws.tsx
new file mode 100644
index 0000000000..27ea7a9b6a
--- /dev/null
+++ b/packages/react-sdk/src/components/radio-button-field.ws.tsx
@@ -0,0 +1,38 @@
+import { RadioCheckedIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import { props } from "./__generated__/radio-button-field.props";
+import type { defaultTag } from "./radio-button-field";
+import { label } from "../css/normalize";
+
+const presetStyle = {
+ label: [
+ ...label,
+ { property: "display", value: { type: "keyword", value: "flex" } },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ category: "forms",
+ type: "container",
+ label: "Radio Button Field",
+ Icon: RadioCheckedIcon,
+ presetStyle,
+ children: [
+ { type: "instance", component: "RadioButton", props: [], children: [] },
+ {
+ type: "instance",
+ component: "TextBlock",
+ props: [],
+ children: [{ type: "text", value: "Radio" }],
+ },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: [],
+};
diff --git a/packages/react-sdk/src/components/radio-button.tsx b/packages/react-sdk/src/components/radio-button.tsx
new file mode 100644
index 0000000000..a90f758ed6
--- /dev/null
+++ b/packages/react-sdk/src/components/radio-button.tsx
@@ -0,0 +1,13 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "input";
+
+export const RadioButton = forwardRef<
+ ElementRef<typeof defaultTag>,
+ Omit<ComponentProps<typeof defaultTag>, "type">
+ // Make sure children are not passed down to an input, because this will result in error.
+>(({ children: _children, ...props }, ref) => (
+ <input {...props} type="radio" ref={ref} />
+));
+
+RadioButton.displayName = "RadioButton";
diff --git a/packages/react-sdk/src/components/radio-button.ws.tsx b/packages/react-sdk/src/components/radio-button.ws.tsx
new file mode 100644
index 0000000000..d56bc28850
--- /dev/null
+++ b/packages/react-sdk/src/components/radio-button.ws.tsx
@@ -0,0 +1,40 @@
+import { RadioCheckedIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import type { defaultTag } from "./radio-button";
+import { input } from "../css/normalize";
+import { props } from "./__generated__/radio-button.props";
+
+const presetStyle = {
+ input: [
+ ...input,
+ {
+ property: "marginRight",
+ value: { type: "unit", unit: "em", value: 0.5 },
+ },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ type: "control",
+ label: "Radio Button",
+ Icon: RadioCheckedIcon,
+ presetStyle,
+ states: [
+ { selector: ":checked", label: "Checked" },
+ { selector: ":required", label: "Required" },
+ { selector: ":optional", label: "Optional" },
+ { selector: ":disabled", label: "Disabled" },
+ { selector: ":enabled", label: "Enabled" },
+ { selector: ":read-only", label: "Read Only" },
+ { selector: ":read-write", label: "Read Write" },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: ["name"],
+};
diff --git a/packages/react-sdk/src/components/success-message.tsx b/packages/react-sdk/src/components/success-message.tsx
new file mode 100644
index 0000000000..6f6cabc407
--- /dev/null
+++ b/packages/react-sdk/src/components/success-message.tsx
@@ -0,0 +1,10 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "div";
+
+export const SuccessMessage = forwardRef<
+ ElementRef<typeof defaultTag>,
+ ComponentProps<typeof defaultTag>
+>((props, ref) => <div {...props} ref={ref} />);
+
+SuccessMessage.displayName = "SuccessMessage";
diff --git a/packages/react-sdk/src/components/success-message.ws.tsx b/packages/react-sdk/src/components/success-message.ws.tsx
new file mode 100644
index 0000000000..f8481ef225
--- /dev/null
+++ b/packages/react-sdk/src/components/success-message.ws.tsx
@@ -0,0 +1,24 @@
+import { BoxIcon } from "@webstudio-is/icons";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import { props } from "./__generated__/success-message.props";
+import { div } from "../css/normalize";
+
+const presetStyle = {
+ div,
+} satisfies PresetStyle<"div">;
+
+export const meta: WsComponentMeta = {
+ type: "container",
+ label: "Success Message",
+ Icon: BoxIcon,
+ presetStyle,
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: [],
+};
diff --git a/packages/react-sdk/src/components/textarea.tsx b/packages/react-sdk/src/components/textarea.tsx
new file mode 100644
index 0000000000..48890027f0
--- /dev/null
+++ b/packages/react-sdk/src/components/textarea.tsx
@@ -0,0 +1,13 @@
+import { forwardRef, type ElementRef, type ComponentProps } from "react";
+
+export const defaultTag = "textarea";
+
+export const Textarea = forwardRef<
+ ElementRef<typeof defaultTag>,
+ ComponentProps<typeof defaultTag>
+ // Make sure children are not passed down to an textarea, because this will result in error.
+>(({ children: _children, ...props }, ref) => (
+ <textarea {...props} ref={ref} />
+));
+
+Textarea.displayName = "Textarea";
diff --git a/packages/react-sdk/src/components/textarea.ws.tsx b/packages/react-sdk/src/components/textarea.ws.tsx
new file mode 100644
index 0000000000..81f1148b37
--- /dev/null
+++ b/packages/react-sdk/src/components/textarea.ws.tsx
@@ -0,0 +1,41 @@
+import { FormTextAreaIcon } from "@webstudio-is/icons";
+import { textarea } from "../css/normalize";
+import type {
+ WsComponentMeta,
+ WsComponentPropsMeta,
+ PresetStyle,
+} from "./component-meta";
+import type { defaultTag } from "./textarea";
+import { props } from "./__generated__/textarea.props";
+
+const presetStyle = {
+ textarea: [
+ ...textarea,
+ // resize doesn't work well while on canvas
+ { property: "resize", value: { type: "keyword", value: "none" } },
+ ],
+} satisfies PresetStyle<typeof defaultTag>;
+
+export const meta: WsComponentMeta = {
+ category: "forms",
+ type: "control",
+ label: "Text Area",
+ Icon: FormTextAreaIcon,
+ presetStyle,
+ states: [
+ { selector: "::placeholder", label: "Placeholder" },
+ { selector: ":valid", label: "Valid" },
+ { selector: ":invalid", label: "Invalid" },
+ { selector: ":required", label: "Required" },
+ { selector: ":optional", label: "Optional" },
+ { selector: ":disabled", label: "Disabled" },
+ { selector: ":enabled", label: "Enabled" },
+ { selector: ":read-only", label: "Read Only" },
+ { selector: ":read-write", label: "Read Write" },
+ ],
+};
+
+export const propsMeta: WsComponentPropsMeta = {
+ props,
+ initialProps: ["name", "placeholder", "required", "autoFocus"],
+};
diff --git a/packages/react-sdk/src/css/normalize.ts b/packages/react-sdk/src/css/normalize.ts
index 3873c4d8e9..46350da0e9 100644
--- a/packages/react-sdk/src/css/normalize.ts
+++ b/packages/react-sdk/src/css/normalize.ts
@@ -48,6 +48,7 @@ export const main = baseStyle;
export const nav = baseStyle;
export const section = baseStyle;
export const form = baseStyle;
+export const label = baseStyle;
export const h1 = baseStyle;
export const h2 = baseStyle;