@plasmicpkgs/react-aria 0.0.15 → 0.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"registerTextField.cjs.js","sources":["../src/registerTextField.tsx"],"sourcesContent":["import React, { ReactNode } from \"react\";\nimport type { InputProps, TextFieldProps } from \"react-aria-components\";\nimport { TextField } from \"react-aria-components\";\nimport { getCommonInputProps } from \"./common\";\nimport { registerDescription } from \"./registerDescription\";\nimport { registerFieldError } from \"./registerFieldError\";\nimport { registerInput } from \"./registerInput\";\nimport { registerLabel } from \"./registerLabel\";\nimport { registerTextArea } from \"./registerTextArea\";\nimport {\n CodeComponentMetaOverrides,\n makeChildComponentName,\n makeComponentName,\n Registerable,\n registerComponentHelper,\n ValueObserver,\n} from \"./utils\";\n\ninterface BaseTextFieldProps extends TextFieldProps {\n children?: ReactNode;\n label?: ReactNode;\n description?: ReactNode;\n enableAutoComplete?: boolean;\n multiline?: boolean;\n inputProps?: InputProps;\n onInvalidChange?: (isInvalid: boolean) => void;\n}\n\nexport function BaseTextField(props: BaseTextFieldProps) {\n const {\n enableAutoComplete,\n autoComplete,\n children,\n onInvalidChange,\n ...rest\n } = props;\n\n return (\n <TextField\n autoComplete={enableAutoComplete ? autoComplete : undefined}\n {...rest}\n >\n {({ isInvalid }) => (\n <>\n <ValueObserver value={isInvalid} onChange={onInvalidChange} />\n {children as ReactNode}\n </>\n )}\n </TextField>\n );\n}\n\nconst componentName = makeComponentName(\"textField\");\n\nexport function registerTextField(\n loader?: Registerable,\n overrides?: CodeComponentMetaOverrides<typeof BaseTextField>\n) {\n registerComponentHelper(\n loader,\n BaseTextField,\n {\n name: componentName,\n displayName: \"Aria TextField\",\n importPath: \"@plasmicpkgs/react-aria/skinny/registerTextField\",\n importName: \"BaseTextField\",\n // TODO: Support for validate prop\n props: {\n ...getCommonInputProps<BaseTextFieldProps>(\"input\", [\n \"name\",\n \"isDisabled\",\n \"isReadOnly\",\n \"autoFocus\",\n \"aria-label\",\n \"children\",\n \"isRequired\",\n ]),\n value: {\n type: \"string\",\n editOnly: true,\n uncontrolledProp: \"defaultValue\",\n description: \"The current value\",\n },\n isInvalid: {\n // TODO: Not sure if needed\n displayName: \"Invalid\",\n type: \"boolean\",\n description: \"Whether the input value is invalid\",\n defaultValueHint: false,\n },\n customValidationErrors: {\n // TODO: Not sure if needed\n type: \"array\",\n description: \"Errors for custom validation\",\n },\n // validate: {\n // type: \"function\" as const,\n // argNames: [\"value\"],\n // argValues: (_ps: any, ctx: any) => [ctx.data[0]],\n // },\n enableAutoComplete: {\n type: \"boolean\",\n description:\n \"Whether the browser is allowed to automatically complete the input\",\n defaultValueHint: false,\n },\n autoComplete: {\n type: \"choice\",\n hidden: ({ enableAutoComplete }: BaseTextFieldProps) =>\n !enableAutoComplete,\n description: \"Guidance as to the type of data expected in the field\",\n helpText:\n \"For explanations on what each of the values mean, check https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\",\n options: [\n \"name\",\n \"honorific-prefix\",\n \"given-name\",\n \"additional-name\",\n \"family-name\",\n \"honorific-suffix\",\n \"nickname\",\n \"email\",\n \"username\",\n \"new-password\",\n \"current-password\",\n \"one-time-code\",\n \"organization-title\",\n \"organization\",\n \"street-address\",\n \"shipping\",\n \"billing\",\n \"address-line1\",\n \"address-line2\",\n \"address-line3\",\n \"address-level4\",\n \"address-level3\",\n \"address-level2\",\n \"address-level1\",\n \"country\",\n \"country-name\",\n \"postal-code\",\n \"cc-name\",\n \"cc-given-name\",\n \"cc-additional-name\",\n \"cc-family-name\",\n \"cc-number\",\n \"cc-exp\",\n \"cc-exp-month\",\n \"cc-exp-year\",\n \"cc-csc\",\n \"cc-type\",\n \"transaction-currency\",\n \"transaction-amount\",\n \"language\",\n \"bday\",\n \"bday-day\",\n \"bday-month\",\n \"bday-year\",\n \"sex\",\n \"tel\",\n \"tel-country-code\",\n \"tel-national\",\n \"tel-area-code\",\n \"tel-local\",\n \"tel-local-suffix\",\n \"tel-local-prefix\",\n \"tel-extension\",\n \"impp\",\n \"url\",\n \"photo\",\n \"webauthn\",\n ],\n },\n maxLength: {\n type: \"number\",\n description:\n \"The maximum number of characters supported by the input\",\n },\n minLength: {\n type: \"number\",\n description:\n \"The minimum number of characters supported by the input\",\n },\n pattern: {\n type: \"string\",\n description:\n \"Regex pattern that the value of the input must match to be valid\",\n helpText:\n \"For more information about writing Regular Expressions (regex), check out https://regexr.com/\",\n validator: (value) => {\n try {\n new RegExp(value);\n return true;\n } catch (error) {\n return \"Invalid Regex\";\n }\n },\n },\n type: {\n type: \"choice\",\n defaultValueHint: \"text\",\n options: [\"text\", \"search\", \"url\", \"tel\", \"email\", \"password\"],\n },\n inputMode: {\n type: \"choice\",\n description:\n \"hint to browsers as to the type of virtual keyboard configuration to use when editing this element or its contents.\",\n options: [\n \"none\",\n \"text\",\n \"tel\",\n \"url\",\n \"email\",\n \"numeric\",\n \"decimal\",\n \"search\",\n ],\n },\n validationBehavior: {\n type: \"choice\",\n options: [\"native\", \"aria\"],\n description:\n \"Whether to use native HTML form validation to prevent form submission when the value is missing or invalid, or mark the field as required or invalid via ARIA.\",\n defaultValueHint: \"native\",\n },\n onChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"value\", type: \"string\" }],\n },\n onFocusChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isFocused\", type: \"boolean\" }],\n },\n onInvalidChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isInvalid\", type: \"boolean\" }],\n },\n },\n // NOTE: React-Aria does not support render props for <Input> and <Textarea>, so focusVisible and inputHovered states are not implemented\n states: {\n value: {\n type: \"writable\",\n valueProp: \"value\",\n onChangeProp: \"onChange\",\n variableType: \"text\",\n },\n isFocused: {\n type: \"readonly\",\n onChangeProp: \"onFocusChange\",\n variableType: \"boolean\",\n },\n isInvalid: {\n type: \"readonly\",\n onChangeProp: \"onInvalidChange\",\n variableType: \"boolean\",\n },\n },\n trapsFocus: true,\n },\n overrides\n );\n\n const thisName = makeChildComponentName(\n overrides?.parentComponentName,\n componentName\n );\n\n registerFieldError(loader, { parentComponentName: thisName });\n registerInput(loader, { parentComponentName: thisName });\n registerLabel(loader, { parentComponentName: thisName });\n registerDescription(loader, { parentComponentName: thisName });\n registerTextArea(loader, { parentComponentName: thisName });\n}\n"],"names":["React","TextField","ValueObserver","makeComponentName","registerComponentHelper","getCommonInputProps","makeChildComponentName","registerFieldError","registerInput","registerLabel","registerDescription","registerTextArea"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4BO,SAAS,cAAc,KAA2B,EAAA;AACvD,EAAA,MAMI,EALF,GAAA,KAAA,EAAA;AAAA,IAAA,kBAAA;AAAA,IACA,YAAA;AAAA,IACA,QAAA;AAAA,IACA,eAAA;AAAA,GAjCJ,GAmCM,EADC,EAAA,IAAA,GAAA,SAAA,CACD,EADC,EAAA;AAAA,IAJH,oBAAA;AAAA,IACA,cAAA;AAAA,IACA,UAAA;AAAA,IACA,iBAAA;AAAA,GAAA,CAAA,CAAA;AAIF,EACE,uBAAAA,sBAAA,CAAA,aAAA;AAAA,IAACC,6BAAA;AAAA,IAAA,cAAA,CAAA;AAAA,MACC,YAAA,EAAc,qBAAqB,YAAe,GAAA,KAAA,CAAA;AAAA,KAC9C,EAAA,IAAA,CAAA;AAAA,IAEH,CAAC,EAAE,SAAU,EAAA,qBAEVD,sBAAA,CAAA,aAAA,CAAAA,sBAAA,CAAA,QAAA,EAAA,IAAA,kBAAAA,sBAAA,CAAA,aAAA,CAACE,mBAAc,EAAA,EAAA,KAAA,EAAO,SAAW,EAAA,QAAA,EAAU,eAAiB,EAAA,CAAA,EAC3D,QACH,CAAA;AAAA,GAEJ,CAAA;AAEJ,CAAA;AAEA,MAAM,aAAA,GAAgBC,wBAAkB,WAAW,CAAA,CAAA;AAEnC,SAAA,iBAAA,CACd,QACA,SACA,EAAA;AACA,EAAAC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AAA,EAAM,WAAW,CAAA;AAAA,SACnD;AAAA,OACF,CAAA;AAAA;AAAA,MAEA,MAAQ,EAAA;AAAA,QACN,KAAO,EAAA;AAAA,UACL,IAAM,EAAA,UAAA;AAAA,UACN,SAAW,EAAA,OAAA;AAAA,UACX,YAAc,EAAA,UAAA;AAAA,UACd,YAAc,EAAA,MAAA;AAAA,SAChB;AAAA,QACA,SAAW,EAAA;AAAA,UACT,IAAM,EAAA,UAAA;AAAA,UACN,YAAc,EAAA,eAAA;AAAA,UACd,YAAc,EAAA,SAAA;AAAA,SAChB;AAAA,QACA,SAAW,EAAA;AAAA,UACT,IAAM,EAAA,UAAA;AAAA,UACN,YAAc,EAAA,iBAAA;AAAA,UACd,YAAc,EAAA,SAAA;AAAA,SAChB;AAAA,OACF;AAAA,MACA,UAAY,EAAA,IAAA;AAAA,KACd;AAAA,IACA,SAAA;AAAA,GACF,CAAA;AAEA,EAAA,MAAM,QAAW,GAAAC,4BAAA;AAAA,IACf,SAAW,IAAA,IAAA,GAAA,KAAA,CAAA,GAAA,SAAA,CAAA,mBAAA;AAAA,IACX,aAAA;AAAA,GACF,CAAA;AAEA,EAAAC,qCAAA,CAAmB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC5D,EAAAC,2BAAA,CAAc,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AACvD,EAAAC,2BAAA,CAAc,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AACvD,EAAAC,uCAAA,CAAoB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC7D,EAAAC,iCAAA,CAAiB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC5D;;;;;"}
1
+ {"version":3,"file":"registerTextField.cjs.js","sources":["../src/registerTextField.tsx"],"sourcesContent":["import React, { ReactNode } from \"react\";\nimport type { InputProps, TextFieldProps } from \"react-aria-components\";\nimport { TextField } from \"react-aria-components\";\nimport { getCommonInputProps } from \"./common\";\nimport { registerDescription } from \"./registerDescription\";\nimport { registerFieldError } from \"./registerFieldError\";\nimport { registerInput } from \"./registerInput\";\nimport { registerLabel } from \"./registerLabel\";\nimport { registerTextArea } from \"./registerTextArea\";\nimport {\n CodeComponentMetaOverrides,\n makeChildComponentName,\n makeComponentName,\n Registerable,\n registerComponentHelper,\n} from \"./utils\";\n\ninterface BaseTextFieldProps extends TextFieldProps {\n children?: ReactNode;\n label?: ReactNode;\n description?: ReactNode;\n enableAutoComplete?: boolean;\n multiline?: boolean;\n inputProps?: InputProps;\n}\n\nexport function BaseTextField(props: BaseTextFieldProps) {\n const { enableAutoComplete, autoComplete, children, ...rest } = props;\n\n return (\n <TextField\n autoComplete={enableAutoComplete ? autoComplete : undefined}\n {...rest}\n >\n {children}\n </TextField>\n );\n}\n\nconst componentName = makeComponentName(\"textField\");\n\nexport function registerTextField(\n loader?: Registerable,\n overrides?: CodeComponentMetaOverrides<typeof BaseTextField>\n) {\n registerComponentHelper(\n loader,\n BaseTextField,\n {\n name: componentName,\n displayName: \"Aria TextField\",\n importPath: \"@plasmicpkgs/react-aria/skinny/registerTextField\",\n importName: \"BaseTextField\",\n // TODO: Support for validate prop\n props: {\n ...getCommonInputProps<BaseTextFieldProps>(\"input\", [\n \"name\",\n \"isDisabled\",\n \"isReadOnly\",\n \"autoFocus\",\n \"aria-label\",\n \"children\",\n \"isRequired\",\n ]),\n value: {\n type: \"string\",\n editOnly: true,\n uncontrolledProp: \"defaultValue\",\n description: \"The current value\",\n },\n isInvalid: {\n // TODO: Not sure if needed\n displayName: \"Invalid\",\n type: \"boolean\",\n description: \"Whether the input value is invalid\",\n defaultValueHint: false,\n },\n customValidationErrors: {\n // TODO: Not sure if needed\n type: \"array\",\n description: \"Errors for custom validation\",\n },\n // validate: {\n // type: \"function\" as const,\n // argNames: [\"value\"],\n // argValues: (_ps: any, ctx: any) => [ctx.data[0]],\n // },\n enableAutoComplete: {\n type: \"boolean\",\n description:\n \"Whether the browser is allowed to automatically complete the input\",\n defaultValueHint: false,\n },\n autoComplete: {\n type: \"choice\",\n hidden: ({ enableAutoComplete }: BaseTextFieldProps) =>\n !enableAutoComplete,\n description: \"Guidance as to the type of data expected in the field\",\n helpText:\n \"For explanations on what each of the values mean, check https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\",\n options: [\n \"name\",\n \"honorific-prefix\",\n \"given-name\",\n \"additional-name\",\n \"family-name\",\n \"honorific-suffix\",\n \"nickname\",\n \"email\",\n \"username\",\n \"new-password\",\n \"current-password\",\n \"one-time-code\",\n \"organization-title\",\n \"organization\",\n \"street-address\",\n \"shipping\",\n \"billing\",\n \"address-line1\",\n \"address-line2\",\n \"address-line3\",\n \"address-level4\",\n \"address-level3\",\n \"address-level2\",\n \"address-level1\",\n \"country\",\n \"country-name\",\n \"postal-code\",\n \"cc-name\",\n \"cc-given-name\",\n \"cc-additional-name\",\n \"cc-family-name\",\n \"cc-number\",\n \"cc-exp\",\n \"cc-exp-month\",\n \"cc-exp-year\",\n \"cc-csc\",\n \"cc-type\",\n \"transaction-currency\",\n \"transaction-amount\",\n \"language\",\n \"bday\",\n \"bday-day\",\n \"bday-month\",\n \"bday-year\",\n \"sex\",\n \"tel\",\n \"tel-country-code\",\n \"tel-national\",\n \"tel-area-code\",\n \"tel-local\",\n \"tel-local-suffix\",\n \"tel-local-prefix\",\n \"tel-extension\",\n \"impp\",\n \"url\",\n \"photo\",\n \"webauthn\",\n ],\n },\n maxLength: {\n type: \"number\",\n description:\n \"The maximum number of characters supported by the input\",\n },\n minLength: {\n type: \"number\",\n description:\n \"The minimum number of characters supported by the input\",\n },\n pattern: {\n type: \"string\",\n description:\n \"Regex pattern that the value of the input must match to be valid\",\n helpText:\n \"For more information about writing Regular Expressions (regex), check out https://regexr.com/\",\n validator: (value) => {\n try {\n new RegExp(value);\n return true;\n } catch (error) {\n return \"Invalid Regex\";\n }\n },\n },\n type: {\n type: \"choice\",\n defaultValueHint: \"text\",\n options: [\"text\", \"search\", \"url\", \"tel\", \"email\", \"password\"],\n },\n inputMode: {\n type: \"choice\",\n description:\n \"hint to browsers as to the type of virtual keyboard configuration to use when editing this element or its contents.\",\n options: [\n \"none\",\n \"text\",\n \"tel\",\n \"url\",\n \"email\",\n \"numeric\",\n \"decimal\",\n \"search\",\n ],\n },\n validationBehavior: {\n type: \"choice\",\n options: [\"native\", \"aria\"],\n description:\n \"Whether to use native HTML form validation to prevent form submission when the value is missing or invalid, or mark the field as required or invalid via ARIA.\",\n defaultValueHint: \"native\",\n },\n onChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"value\", type: \"string\" }],\n },\n onFocusChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isFocused\", type: \"boolean\" }],\n },\n },\n // NOTE: React-Aria does not support render props for <Input> and <Textarea>, so focusVisible and inputHovered states are not implemented\n states: {\n value: {\n type: \"writable\",\n valueProp: \"value\",\n onChangeProp: \"onChange\",\n variableType: \"text\",\n },\n isFocused: {\n type: \"readonly\",\n onChangeProp: \"onFocusChange\",\n variableType: \"boolean\",\n },\n },\n trapsFocus: true,\n },\n overrides\n );\n\n const thisName = makeChildComponentName(\n overrides?.parentComponentName,\n componentName\n );\n\n registerFieldError(loader, { parentComponentName: thisName });\n registerInput(loader, { parentComponentName: thisName });\n registerLabel(loader, { parentComponentName: thisName });\n registerDescription(loader, { parentComponentName: thisName });\n registerTextArea(loader, { parentComponentName: thisName });\n}\n"],"names":["React","TextField","makeComponentName","registerComponentHelper","getCommonInputProps","makeChildComponentName","registerFieldError","registerInput","registerLabel","registerDescription","registerTextArea"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BO,SAAS,cAAc,KAA2B,EAAA;AACvD,EAAgE,MAAA,EAAA,GAAA,KAAA,EAAxD,EAAoB,kBAAA,EAAA,YAAA,EAA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AA;AAC7D,EAAAC,iCAAA,CAAiB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC5D;;;;;"}
@@ -8,7 +8,6 @@ interface BaseTextFieldProps extends TextFieldProps {
8
8
  enableAutoComplete?: boolean;
9
9
  multiline?: boolean;
10
10
  inputProps?: InputProps;
11
- onInvalidChange?: (isInvalid: boolean) => void;
12
11
  }
13
12
  export declare function BaseTextField(props: BaseTextFieldProps): React.JSX.Element;
14
13
  export declare function registerTextField(loader?: Registerable, overrides?: CodeComponentMetaOverrides<typeof BaseTextField>): void;
@@ -6,7 +6,7 @@ import { registerFieldError } from './registerFieldError.esm.js';
6
6
  import { registerInput } from './registerInput.esm.js';
7
7
  import { registerLabel } from './registerLabel.esm.js';
8
8
  import { registerTextArea } from './registerTextArea.esm.js';
9
- import { V as ValueObserver, r as registerComponentHelper, a as makeChildComponentName, m as makeComponentName } from './utils-28f98072.esm.js';
9
+ import { r as registerComponentHelper, a as makeChildComponentName, m as makeComponentName } from './utils-28f98072.esm.js';
10
10
  import './registerText.esm.js';
11
11
  import '@plasmicapp/host/registerComponent';
12
12
 
@@ -42,23 +42,13 @@ var __objRest = (source, exclude) => {
42
42
  return target;
43
43
  };
44
44
  function BaseTextField(props) {
45
- const _a = props, {
46
- enableAutoComplete,
47
- autoComplete,
48
- children,
49
- onInvalidChange
50
- } = _a, rest = __objRest(_a, [
51
- "enableAutoComplete",
52
- "autoComplete",
53
- "children",
54
- "onInvalidChange"
55
- ]);
45
+ const _a = props, { enableAutoComplete, autoComplete, children } = _a, rest = __objRest(_a, ["enableAutoComplete", "autoComplete", "children"]);
56
46
  return /* @__PURE__ */ React.createElement(
57
47
  TextField,
58
48
  __spreadValues({
59
49
  autoComplete: enableAutoComplete ? autoComplete : void 0
60
50
  }, rest),
61
- ({ isInvalid }) => /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(ValueObserver, { value: isInvalid, onChange: onInvalidChange }), children)
51
+ children
62
52
  );
63
53
  }
64
54
  const componentName = makeComponentName("textField");
@@ -227,10 +217,6 @@ function registerTextField(loader, overrides) {
227
217
  onFocusChange: {
228
218
  type: "eventHandler",
229
219
  argTypes: [{ name: "isFocused", type: "boolean" }]
230
- },
231
- onInvalidChange: {
232
- type: "eventHandler",
233
- argTypes: [{ name: "isInvalid", type: "boolean" }]
234
220
  }
235
221
  }),
236
222
  // NOTE: React-Aria does not support render props for <Input> and <Textarea>, so focusVisible and inputHovered states are not implemented
@@ -245,11 +231,6 @@ function registerTextField(loader, overrides) {
245
231
  type: "readonly",
246
232
  onChangeProp: "onFocusChange",
247
233
  variableType: "boolean"
248
- },
249
- isInvalid: {
250
- type: "readonly",
251
- onChangeProp: "onInvalidChange",
252
- variableType: "boolean"
253
234
  }
254
235
  },
255
236
  trapsFocus: true
@@ -1 +1 @@
1
- {"version":3,"file":"registerTextField.esm.js","sources":["../src/registerTextField.tsx"],"sourcesContent":["import React, { ReactNode } from \"react\";\nimport type { InputProps, TextFieldProps } from \"react-aria-components\";\nimport { TextField } from \"react-aria-components\";\nimport { getCommonInputProps } from \"./common\";\nimport { registerDescription } from \"./registerDescription\";\nimport { registerFieldError } from \"./registerFieldError\";\nimport { registerInput } from \"./registerInput\";\nimport { registerLabel } from \"./registerLabel\";\nimport { registerTextArea } from \"./registerTextArea\";\nimport {\n CodeComponentMetaOverrides,\n makeChildComponentName,\n makeComponentName,\n Registerable,\n registerComponentHelper,\n ValueObserver,\n} from \"./utils\";\n\ninterface BaseTextFieldProps extends TextFieldProps {\n children?: ReactNode;\n label?: ReactNode;\n description?: ReactNode;\n enableAutoComplete?: boolean;\n multiline?: boolean;\n inputProps?: InputProps;\n onInvalidChange?: (isInvalid: boolean) => void;\n}\n\nexport function BaseTextField(props: BaseTextFieldProps) {\n const {\n enableAutoComplete,\n autoComplete,\n children,\n onInvalidChange,\n ...rest\n } = props;\n\n return (\n <TextField\n autoComplete={enableAutoComplete ? autoComplete : undefined}\n {...rest}\n >\n {({ isInvalid }) => (\n <>\n <ValueObserver value={isInvalid} onChange={onInvalidChange} />\n {children as ReactNode}\n </>\n )}\n </TextField>\n );\n}\n\nconst componentName = makeComponentName(\"textField\");\n\nexport function registerTextField(\n loader?: Registerable,\n overrides?: CodeComponentMetaOverrides<typeof BaseTextField>\n) {\n registerComponentHelper(\n loader,\n BaseTextField,\n {\n name: componentName,\n displayName: \"Aria TextField\",\n importPath: \"@plasmicpkgs/react-aria/skinny/registerTextField\",\n importName: \"BaseTextField\",\n // TODO: Support for validate prop\n props: {\n ...getCommonInputProps<BaseTextFieldProps>(\"input\", [\n \"name\",\n \"isDisabled\",\n \"isReadOnly\",\n \"autoFocus\",\n \"aria-label\",\n \"children\",\n \"isRequired\",\n ]),\n value: {\n type: \"string\",\n editOnly: true,\n uncontrolledProp: \"defaultValue\",\n description: \"The current value\",\n },\n isInvalid: {\n // TODO: Not sure if needed\n displayName: \"Invalid\",\n type: \"boolean\",\n description: \"Whether the input value is invalid\",\n defaultValueHint: false,\n },\n customValidationErrors: {\n // TODO: Not sure if needed\n type: \"array\",\n description: \"Errors for custom validation\",\n },\n // validate: {\n // type: \"function\" as const,\n // argNames: [\"value\"],\n // argValues: (_ps: any, ctx: any) => [ctx.data[0]],\n // },\n enableAutoComplete: {\n type: \"boolean\",\n description:\n \"Whether the browser is allowed to automatically complete the input\",\n defaultValueHint: false,\n },\n autoComplete: {\n type: \"choice\",\n hidden: ({ enableAutoComplete }: BaseTextFieldProps) =>\n !enableAutoComplete,\n description: \"Guidance as to the type of data expected in the field\",\n helpText:\n \"For explanations on what each of the values mean, check https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\",\n options: [\n \"name\",\n \"honorific-prefix\",\n \"given-name\",\n \"additional-name\",\n \"family-name\",\n \"honorific-suffix\",\n \"nickname\",\n \"email\",\n \"username\",\n \"new-password\",\n \"current-password\",\n \"one-time-code\",\n \"organization-title\",\n \"organization\",\n \"street-address\",\n \"shipping\",\n \"billing\",\n \"address-line1\",\n \"address-line2\",\n \"address-line3\",\n \"address-level4\",\n \"address-level3\",\n \"address-level2\",\n \"address-level1\",\n \"country\",\n \"country-name\",\n \"postal-code\",\n \"cc-name\",\n \"cc-given-name\",\n \"cc-additional-name\",\n \"cc-family-name\",\n \"cc-number\",\n \"cc-exp\",\n \"cc-exp-month\",\n \"cc-exp-year\",\n \"cc-csc\",\n \"cc-type\",\n \"transaction-currency\",\n \"transaction-amount\",\n \"language\",\n \"bday\",\n \"bday-day\",\n \"bday-month\",\n \"bday-year\",\n \"sex\",\n \"tel\",\n \"tel-country-code\",\n \"tel-national\",\n \"tel-area-code\",\n \"tel-local\",\n \"tel-local-suffix\",\n \"tel-local-prefix\",\n \"tel-extension\",\n \"impp\",\n \"url\",\n \"photo\",\n \"webauthn\",\n ],\n },\n maxLength: {\n type: \"number\",\n description:\n \"The maximum number of characters supported by the input\",\n },\n minLength: {\n type: \"number\",\n description:\n \"The minimum number of characters supported by the input\",\n },\n pattern: {\n type: \"string\",\n description:\n \"Regex pattern that the value of the input must match to be valid\",\n helpText:\n \"For more information about writing Regular Expressions (regex), check out https://regexr.com/\",\n validator: (value) => {\n try {\n new RegExp(value);\n return true;\n } catch (error) {\n return \"Invalid Regex\";\n }\n },\n },\n type: {\n type: \"choice\",\n defaultValueHint: \"text\",\n options: [\"text\", \"search\", \"url\", \"tel\", \"email\", \"password\"],\n },\n inputMode: {\n type: \"choice\",\n description:\n \"hint to browsers as to the type of virtual keyboard configuration to use when editing this element or its contents.\",\n options: [\n \"none\",\n \"text\",\n \"tel\",\n \"url\",\n \"email\",\n \"numeric\",\n \"decimal\",\n \"search\",\n ],\n },\n validationBehavior: {\n type: \"choice\",\n options: [\"native\", \"aria\"],\n description:\n \"Whether to use native HTML form validation to prevent form submission when the value is missing or invalid, or mark the field as required or invalid via ARIA.\",\n defaultValueHint: \"native\",\n },\n onChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"value\", type: \"string\" }],\n },\n onFocusChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isFocused\", type: \"boolean\" }],\n },\n onInvalidChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isInvalid\", type: \"boolean\" }],\n },\n },\n // NOTE: React-Aria does not support render props for <Input> and <Textarea>, so focusVisible and inputHovered states are not implemented\n states: {\n value: {\n type: \"writable\",\n valueProp: \"value\",\n onChangeProp: \"onChange\",\n variableType: \"text\",\n },\n isFocused: {\n type: \"readonly\",\n onChangeProp: \"onFocusChange\",\n variableType: \"boolean\",\n },\n isInvalid: {\n type: \"readonly\",\n onChangeProp: \"onInvalidChange\",\n variableType: \"boolean\",\n },\n },\n trapsFocus: true,\n },\n overrides\n );\n\n const thisName = makeChildComponentName(\n overrides?.parentComponentName,\n componentName\n );\n\n registerFieldError(loader, { parentComponentName: thisName });\n registerInput(loader, { parentComponentName: thisName });\n registerLabel(loader, { parentComponentName: thisName });\n registerDescription(loader, { parentComponentName: thisName });\n registerTextArea(loader, { parentComponentName: thisName });\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4BO,SAAS,cAAc,KAA2B,EAAA;AACvD,EAAA,MAMI,EALF,GAAA,KAAA,EAAA;AAAA,IAAA,kBAAA;AAAA,IACA,YAAA;AAAA,IACA,QAAA;AAAA,IACA,eAAA;AAAA,GAjCJ,GAmCM,EADC,EAAA,IAAA,GAAA,SAAA,CACD,EADC,EAAA;AAAA,IAJH,oBAAA;AAAA,IACA,cAAA;AAAA,IACA,UAAA;AAAA,IACA,iBAAA;AAAA,GAAA,CAAA,CAAA;AAIF,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,SAAA;AAAA,IAAA,cAAA,CAAA;AAAA,MACC,YAAA,EAAc,qBAAqB,YAAe,GAAA,KAAA,CAAA;AAAA,KAC9C,EAAA,IAAA,CAAA;AAAA,IAEH,CAAC,EAAE,SAAU,EAAA,qBAEV,KAAA,CAAA,aAAA,CAAA,KA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CAAA;AACvD,EAAA,mBAAA,CAAoB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC7D,EAAA,gBAAA,CAAiB,MAAQ,EAAA,EAAE,mBAAqB,EAAA,QAAA,EAAU,CAAA,CAAA;AAC5D;;;;"}
1
+ {"version":3,"file":"registerTextField.esm.js","sources":["../src/registerTextField.tsx"],"sourcesContent":["import React, { ReactNode } from \"react\";\nimport type { InputProps, TextFieldProps } from \"react-aria-components\";\nimport { TextField } from \"react-aria-components\";\nimport { getCommonInputProps } from \"./common\";\nimport { registerDescription } from \"./registerDescription\";\nimport { registerFieldError } from \"./registerFieldError\";\nimport { registerInput } from \"./registerInput\";\nimport { registerLabel } from \"./registerLabel\";\nimport { registerTextArea } from \"./registerTextArea\";\nimport {\n CodeComponentMetaOverrides,\n makeChildComponentName,\n makeComponentName,\n Registerable,\n registerComponentHelper,\n} from \"./utils\";\n\ninterface BaseTextFieldProps extends TextFieldProps {\n children?: ReactNode;\n label?: ReactNode;\n description?: ReactNode;\n enableAutoComplete?: boolean;\n multiline?: boolean;\n inputProps?: InputProps;\n}\n\nexport function BaseTextField(props: BaseTextFieldProps) {\n const { enableAutoComplete, autoComplete, children, ...rest } = props;\n\n return (\n <TextField\n autoComplete={enableAutoComplete ? autoComplete : undefined}\n {...rest}\n >\n {children}\n </TextField>\n );\n}\n\nconst componentName = makeComponentName(\"textField\");\n\nexport function registerTextField(\n loader?: Registerable,\n overrides?: CodeComponentMetaOverrides<typeof BaseTextField>\n) {\n registerComponentHelper(\n loader,\n BaseTextField,\n {\n name: componentName,\n displayName: \"Aria TextField\",\n importPath: \"@plasmicpkgs/react-aria/skinny/registerTextField\",\n importName: \"BaseTextField\",\n // TODO: Support for validate prop\n props: {\n ...getCommonInputProps<BaseTextFieldProps>(\"input\", [\n \"name\",\n \"isDisabled\",\n \"isReadOnly\",\n \"autoFocus\",\n \"aria-label\",\n \"children\",\n \"isRequired\",\n ]),\n value: {\n type: \"string\",\n editOnly: true,\n uncontrolledProp: \"defaultValue\",\n description: \"The current value\",\n },\n isInvalid: {\n // TODO: Not sure if needed\n displayName: \"Invalid\",\n type: \"boolean\",\n description: \"Whether the input value is invalid\",\n defaultValueHint: false,\n },\n customValidationErrors: {\n // TODO: Not sure if needed\n type: \"array\",\n description: \"Errors for custom validation\",\n },\n // validate: {\n // type: \"function\" as const,\n // argNames: [\"value\"],\n // argValues: (_ps: any, ctx: any) => [ctx.data[0]],\n // },\n enableAutoComplete: {\n type: \"boolean\",\n description:\n \"Whether the browser is allowed to automatically complete the input\",\n defaultValueHint: false,\n },\n autoComplete: {\n type: \"choice\",\n hidden: ({ enableAutoComplete }: BaseTextFieldProps) =>\n !enableAutoComplete,\n description: \"Guidance as to the type of data expected in the field\",\n helpText:\n \"For explanations on what each of the values mean, check https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\",\n options: [\n \"name\",\n \"honorific-prefix\",\n \"given-name\",\n \"additional-name\",\n \"family-name\",\n \"honorific-suffix\",\n \"nickname\",\n \"email\",\n \"username\",\n \"new-password\",\n \"current-password\",\n \"one-time-code\",\n \"organization-title\",\n \"organization\",\n \"street-address\",\n \"shipping\",\n \"billing\",\n \"address-line1\",\n \"address-line2\",\n \"address-line3\",\n \"address-level4\",\n \"address-level3\",\n \"address-level2\",\n \"address-level1\",\n \"country\",\n \"country-name\",\n \"postal-code\",\n \"cc-name\",\n \"cc-given-name\",\n \"cc-additional-name\",\n \"cc-family-name\",\n \"cc-number\",\n \"cc-exp\",\n \"cc-exp-month\",\n \"cc-exp-year\",\n \"cc-csc\",\n \"cc-type\",\n \"transaction-currency\",\n \"transaction-amount\",\n \"language\",\n \"bday\",\n \"bday-day\",\n \"bday-month\",\n \"bday-year\",\n \"sex\",\n \"tel\",\n \"tel-country-code\",\n \"tel-national\",\n \"tel-area-code\",\n \"tel-local\",\n \"tel-local-suffix\",\n \"tel-local-prefix\",\n \"tel-extension\",\n \"impp\",\n \"url\",\n \"photo\",\n \"webauthn\",\n ],\n },\n maxLength: {\n type: \"number\",\n description:\n \"The maximum number of characters supported by the input\",\n },\n minLength: {\n type: \"number\",\n description:\n \"The minimum number of characters supported by the input\",\n },\n pattern: {\n type: \"string\",\n description:\n \"Regex pattern that the value of the input must match to be valid\",\n helpText:\n \"For more information about writing Regular Expressions (regex), check out https://regexr.com/\",\n validator: (value) => {\n try {\n new RegExp(value);\n return true;\n } catch (error) {\n return \"Invalid Regex\";\n }\n },\n },\n type: {\n type: \"choice\",\n defaultValueHint: \"text\",\n options: [\"text\", \"search\", \"url\", \"tel\", \"email\", \"password\"],\n },\n inputMode: {\n type: \"choice\",\n description:\n \"hint to browsers as to the type of virtual keyboard configuration to use when editing this element or its contents.\",\n options: [\n \"none\",\n \"text\",\n \"tel\",\n \"url\",\n \"email\",\n \"numeric\",\n \"decimal\",\n \"search\",\n ],\n },\n validationBehavior: {\n type: \"choice\",\n options: [\"native\", \"aria\"],\n description:\n \"Whether to use native HTML form validation to prevent form submission when the value is missing or invalid, or mark the field as required or invalid via ARIA.\",\n defaultValueHint: \"native\",\n },\n onChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"value\", type: \"string\" }],\n },\n onFocusChange: {\n type: \"eventHandler\",\n argTypes: [{ name: \"isFocused\", type: \"boolean\" }],\n },\n },\n // NOTE: React-Aria does not support render props for <Input> and <Textarea>, so focusVisible and inputHovered states are not implemented\n states: {\n value: {\n type: \"writable\",\n valueProp: \"value\",\n onChangeProp: \"onChange\",\n variableType: \"text\",\n },\n isFocused: {\n type: \"readonly\",\n onChangeProp: \"onFocusChange\",\n variableType: \"boolean\",\n },\n },\n trapsFocus: true,\n },\n overrides\n );\n\n const thisName = makeChildComponentName(\n overrides?.parentComponentName,\n componentName\n );\n\n registerFieldError(loader, { parentComponentName: thisName });\n registerInput(loader, { parentComponentName: thisName });\n registerLabel(loader, { parentComponentName: thisName });\n registerDescription(loader, { parentComponentName: thisName });\n registerTextArea(loader, { parentComponentName: thisName });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