@react-magma/schema-renderer 2.0.1 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/BasicTemplate/index.d.ts +0 -1
- package/dist/components/FieldArray/FieldArray.d.ts +0 -1
- package/dist/components/FieldArray/FieldArrayItem.d.ts +0 -1
- package/dist/components/FormTemplate/index.d.ts +0 -1
- package/dist/components/SchemaRenderer/SchemaRenderer.d.ts +0 -1
- package/dist/components/SchemaRenderer/SchemaRenderer.stories.d.ts +0 -1
- package/dist/components/Spy/index.d.ts +0 -1
- package/dist/schema-renderer.cjs.development.js +140 -213
- package/dist/schema-renderer.cjs.development.js.map +1 -1
- package/dist/schema-renderer.cjs.production.min.js.map +1 -1
- package/dist/schema-renderer.esm.js +140 -213
- package/dist/schema-renderer.esm.js.map +1 -1
- package/package.json +9 -9
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-renderer.esm.js","sources":["../src/components/Checkbox/index.tsx","../src/components/Combobox/index.tsx","../src/components/Custom/index.tsx","../src/components/DatePicker/index.tsx","../src/components/FieldArray/FieldArrayItem.tsx","../src/components/FieldArray/FieldArray.tsx","../src/components/FormGroup/index.tsx","../src/components/Input/index.tsx","../src/components/Modal/index.tsx","../src/components/PasswordInput/index.tsx","../src/components/Radio/index.tsx","../src/components/Spy/index.tsx","../src/components/Select/index.tsx","../src/components/Textarea/index.tsx","../src/components/TimePicker/index.tsx","../src/components/Toggle/index.tsx","../src/components/ComponentMapper/index.ts","../src/components/BasicTemplate/index.tsx","../src/components/FormTemplate/index.tsx","../src/components/TemplateMapper/index.ts","../src/components/SchemaRenderer/SchemaRenderer.tsx"],"sourcesContent":["import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Checkbox as MagmaCheckbox,\n CheckboxProps as MagmaCheckboxProps,\n FormGroup,\n FormGroupProps as MagmaFormGroupProps,\n} from 'react-magma-dom';\n\ninterface MagmaMultiCheckboxProps extends MagmaFormGroupProps {\n options: MagmaCheckboxProps[];\n}\n\ntype CheckboxProps = MagmaCheckboxProps & UseFieldApiConfig;\ntype MultiCheckboxProps = MagmaMultiCheckboxProps & UseFieldApiConfig;\n\nconst GroupedCheckbox = (props: CheckboxProps) => {\n const { input } = useFieldApi({\n name: props.name,\n type: 'checkbox',\n value: props.value,\n });\n return <MagmaCheckbox {...props} {...input} />;\n};\n\nconst CheckboxMapping = (props: MultiCheckboxProps) => {\n const {\n input,\n options,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) ||\n rest.errorMessage;\n\n if (options && options.length > 0) {\n return (\n <FormGroup errorMessage={errorMessage} {...rest}>\n {options.map((option: MagmaCheckboxProps) => {\n return (\n <GroupedCheckbox\n name={name}\n {...option}\n key={option.value?.toString()}\n />\n );\n })}\n </FormGroup>\n );\n } else {\n return (\n <MagmaCheckbox\n {...input}\n name={name}\n labelText={rest.labelText}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n }\n};\n\nexport const Checkbox = React.memo(CheckboxMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { Combobox as MagmaCombobox } from 'react-magma-dom';\nimport { XORComboboxProps as MagmaComboboxProps } from 'react-magma-dom/dist/components/Combobox';\n\nexport type ComboboxProps = MagmaComboboxProps<ComboOption> & UseFieldApiConfig;\n\ninterface ComboOption {\n label: string;\n value: string;\n name: string;\n}\n\ninterface ComboOptionEvent {\n selectedItem: ComboOption;\n}\n\ninterface MultiComboOptionEvent {\n selectedItems: ComboOption[];\n}\n\nconst ComboboxMapping = (props: ComboboxProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n options,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n const innerRef = React.useRef<HTMLInputElement>(null);\n\n const [items, updateItems] = React.useState(\n options.map(({ labelText, ...rest }: { labelText: string }) => {\n return { label: labelText, ...rest };\n })\n );\n\n const newItemTransform = ({ value }: { value: string }) => {\n return {\n label: value,\n value: value.toLowerCase(),\n };\n };\n\n const onItemCreated = (item: any) => {\n updateItems([...items, item]);\n input.onChange(item.value);\n };\n\n if (rest.isMulti) {\n rest.onSelectedItemsChange = (evt: MultiComboOptionEvent) => {\n input.onChange(evt.selectedItems.map(item => item.value));\n };\n rest.selectedItems = items.filter((item: { value: string }) =>\n input.value.includes(item.value)\n );\n } else {\n rest.onSelectedItemChange = (evt: ComboOptionEvent) => {\n input.onChange(evt.selectedItem.value);\n };\n rest.selectedItem = items\n .filter((item: { value: string }) => item.value === input.value)\n .pop();\n }\n\n return (\n <MagmaCombobox\n {...input}\n id={name}\n innerRef={innerRef}\n items={items}\n newItemTransform={newItemTransform}\n onItemCreated={onItemCreated}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Combobox = React.memo(ComboboxMapping);\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nconst CustomMapping = (props: any) => {\n const { customComponent: CustomComponent, ...rest } = useFieldApi(props);\n const { getState } = useFormApi();\n\n return <CustomComponent {...rest} data={getState().values} />;\n};\n\nexport const Custom = React.memo(CustomMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n DatePicker as MagmaDatePicker,\n DatePickerProps as MagmaDatePickerProps,\n} from 'react-magma-dom';\n\nexport type DatePickerProps = MagmaDatePickerProps & UseFieldApiConfig;\n\nconst DatePickerMapping = (props: DatePickerProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaDatePicker\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const DatePicker = React.memo(DatePickerMapping);\n","import * as React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { IconButton, ButtonVariant, ThemeContext } from 'react-magma-dom';\nimport { DeleteIcon } from 'react-magma-icons';\n\nexport const FieldArrayItem = ({\n fields,\n fieldIndex,\n name,\n remove,\n length,\n minItems,\n removeLabel,\n}: any) => {\n const { renderForm } = useFormApi();\n const theme = React.useContext(ThemeContext);\n\n const editedFields = React.useMemo(() => {\n return fields.map((field: any) => {\n const computedName = field.name ? `${name}.${field.name}` : uuidv4();\n return {\n ...field,\n name: computedName,\n key: computedName,\n labelText: fieldIndex === 0 ? field.labelText : null,\n children: (\n <IconButton\n aria-label={removeLabel}\n icon={<DeleteIcon />}\n variant={ButtonVariant.link}\n onClick={() => remove(fieldIndex)}\n disabled={length <= minItems}\n />\n ),\n };\n });\n }, [fields, name, fieldIndex]);\n\n return (\n <div style={{ marginTop: theme.spaceScale.spacing04 }}>\n {editedFields.map((field: any) => renderForm([field]))}\n </div>\n );\n};\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { FieldArray as FieldArrayBase } from '@data-driven-forms/react-form-renderer';\nimport {\n Button,\n ButtonColor,\n ButtonType,\n Paragraph,\n} from 'react-magma-dom';\n\nimport { FieldArrayItem } from './FieldArrayItem';\n\nexport const FieldArray = ({ ...props }: any) => {\n const {\n arrayValidator,\n label,\n description,\n fields: formFields,\n defaultItem,\n meta,\n minItems,\n maxItems,\n noItemsMessage = \"You haven't added any items yet!\",\n FormControlProps,\n ...rest\n } = useFieldApi(props);\n\n const { dirty, submitFailed, error } = meta;\n const isError = (dirty || submitFailed) && error && typeof error === 'string';\n\n return (\n <FieldArrayBase\n key={rest.input.name}\n name={rest.input.name}\n validate={arrayValidator}\n >\n {({ fields: { map, value = [], push, remove } }) => {\n return (\n <>\n {<h6>label</h6>}\n <Button\n color={ButtonColor.primary}\n type={ButtonType.button}\n onClick={() => push(defaultItem)}\n disabled={value.length >= maxItems}\n >\n ADD ITEM\n </Button>\n {description && <Paragraph>{description}</Paragraph>}\n {value.length <= 0 ? (\n <Paragraph>{noItemsMessage}</Paragraph>\n ) : (\n map((name, index) => (\n <FieldArrayItem\n key={name}\n fields={formFields}\n name={name}\n fieldIndex={index}\n remove={remove}\n length={value.length}\n minItems={minItems}\n removeLabel=\"REMOVE\"\n />\n ))\n )}\n {isError && <Paragraph>{error}</Paragraph>}\n </>\n );\n }}\n </FieldArrayBase>\n );\n};\n","import React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\nimport {\n FormGroup as MagmaFormGroup,\n FormGroupProps as MagmaFormGroupProps,\n} from 'react-magma-dom';\n\nexport interface FormGroupProps extends MagmaFormGroupProps {\n fields: any;\n showError?: boolean;\n}\n\nconst FormGroupMapping = (props: FormGroupProps) => {\n const { renderForm } = useFormApi();\n\n const subfields = React.useMemo(() => {\n return props.fields.map((field: any) => ({\n ...field,\n showError: props.showError,\n }));\n }, [props.fields, props.showError]);\n\n return <MagmaFormGroup {...props}>{renderForm(subfields)}</MagmaFormGroup>;\n};\n\nexport const FormGroup = React.memo(FormGroupMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Input as MagmaInput,\n InputType,\n InputProps as MagmaInputProps,\n} from 'react-magma-dom';\n\nexport type InputProps = MagmaInputProps & UseFieldApiConfig;\n\nconst InputMapping = (props: InputProps) => {\n const {\n input,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n input: { type = 'text', ...inputRest },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaInput\n {...inputRest}\n type={InputType[type as keyof typeof InputType] || InputType.text}\n id={id}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n};\n\nexport const Input = React.memo(InputMapping);\n","import React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nimport {\n Modal as MagmaModal,\n ModalProps as MagmaModalProps,\n} from 'react-magma-dom';\n\nexport interface ModalProps extends MagmaModalProps {\n fields: any;\n showError?: boolean;\n}\n\nconst ModalMapping = (props: ModalProps) => {\n const { renderForm } = useFormApi();\n\n const subfields = React.useMemo(() => {\n return props.fields.map((field: any) => ({\n ...field,\n showError: props.showError,\n }));\n }, [props.fields, props.showError]);\n\n return <MagmaModal {...props}>{renderForm(subfields)}</MagmaModal>;\n};\n\nexport const Modal = React.memo(ModalMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n PasswordInput as MagmaPasswordInput,\n PasswordInputProps as MagmaPasswordInputProps,\n} from 'react-magma-dom';\n\nexport type PasswordInputProps = MagmaPasswordInputProps & UseFieldApiConfig;\n\nconst PasswordInputMapping = (props: PasswordInputProps) => {\n const {\n input,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaPasswordInput\n {...input}\n labelText={rest.labelText}\n id={id}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n};\n\nexport const PasswordInput = React.memo(PasswordInputMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Radio as MagmaRadio,\n RadioProps,\n RadioGroup,\n RadioGroupProps as MagmaRadioGroupProps,\n} from 'react-magma-dom';\n\ntype RadioGroupProps = MagmaRadioGroupProps & UseFieldApiConfig;\n\nconst RadioMapping = (props: RadioGroupProps) => {\n const {\n input,\n options,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi({ ...props, type: 'radio' });\n const name = input.name || uuidv4();\n\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) ||\n rest.errorMessage;\n\n return (\n <RadioGroup\n onChange={input.onChange}\n errorMessage={errorMessage}\n name={name}\n {...rest}\n >\n {options.map((option: RadioProps) => {\n return <MagmaRadio {...option} key={option.value?.toString()} />;\n })}\n </RadioGroup>\n );\n};\n\nexport const Radio = React.memo(RadioMapping);\n","import React from 'react';\nimport { FormSpy } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\n\nexport const Spy = (props: any) => {\n const { template: Template, ...rest } = useFieldApi(props);\n return (\n <FormSpy {...rest}>\n {props => {\n return <Template {...props} />;\n }}\n </FormSpy>\n );\n};\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { Select as MagmaSelect } from 'react-magma-dom';\n\ninterface SelectOption {\n label: string;\n value: string;\n name: string;\n}\n\ninterface SelectOptionEvent {\n selectedItem: SelectOption;\n}\n\ninterface MultiSelectOptionEvent {\n selectedItems: SelectOption[];\n}\n\nconst SelectMapping = (props: any) => {\n const {\n input,\n validateOnMount,\n showError,\n options,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n if (rest.isMulti) {\n rest.onSelectedItemsChange = (evt: MultiSelectOptionEvent) => {\n input.onChange(evt.selectedItems.map(item => item.value));\n };\n } else {\n rest.onSelectedItemChange = (evt: SelectOptionEvent) => {\n input.onChange(evt.selectedItem.value);\n };\n }\n\n return (\n <MagmaSelect\n id={name}\n items={options.map(({ labelText, ...rest }: { labelText: string }) => {\n return { label: labelText, ...rest };\n })}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Select = React.memo(SelectMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Textarea as MagmaTextarea,\n TextareaProps as MagmaTextareaProps,\n} from 'react-magma-dom';\n\nexport type TextareaProps = MagmaTextareaProps & UseFieldApiConfig;\n\nconst TextareaMapping = (props: TextareaProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaTextarea\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Textarea = React.memo(TextareaMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n TimePicker as MagmaTimePicker,\n TimePickerProps as MagmaTimePickerProps,\n} from 'react-magma-dom';\n\nexport type TimePickerProps = MagmaTimePickerProps & UseFieldApiConfig;\n\nconst TimePickerMapping = (props: TimePickerProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaTimePicker\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const TimePicker = React.memo(TimePickerMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Toggle as MagmaToggle,\n ToggleProps as MagmaToggleProps,\n} from 'react-magma-dom';\n\nexport type ToggleProps = MagmaToggleProps & UseFieldApiConfig;\n\nconst ToggleMapping = (props: ToggleProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaToggle\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Toggle = React.memo(ToggleMapping);\n","import { ComponentMapper } from '@data-driven-forms/react-form-renderer';\n\nimport { Checkbox } from '../Checkbox';\nimport { Combobox } from '../Combobox';\nimport { Custom } from '../Custom';\nimport { DatePicker } from '../DatePicker';\nimport { FieldArray } from '../FieldArray';\nimport { FormGroup } from '../FormGroup';\nimport { Input } from '../Input';\nimport { Modal } from '../Modal';\nimport { PasswordInput } from '../PasswordInput';\nimport { Radio } from '../Radio';\nimport { Spy } from '../Spy';\nimport { Select } from '../Select';\nimport { Textarea } from '../Textarea';\nimport { TimePicker } from '../TimePicker';\nimport { Toggle } from '../Toggle';\n\nimport {\n Alert,\n Banner,\n Heading,\n Hyperlink,\n Toast,\n Paragraph,\n} from 'react-magma-dom';\n\nexport enum componentTypes {\n ALERT = 'ALERT',\n BANNER = 'BANNER',\n CUSTOM = 'CUSTOM',\n HEADING = 'HEADING',\n HYPERLINK = 'HYPERLINK',\n TOAST = 'TOAST',\n CHECKBOX = 'CHECKBOX',\n COMBOBOX = 'COMBOBOX',\n DATE_PICKER = 'DATE_PICKER',\n FIELD_ARRAY = 'FIELD_ARRAY',\n FORM_GROUP = 'FORM_GROUP',\n INPUT = 'INPUT',\n MODAL = 'MODAL',\n PARAGRAPH = 'PARAGRAPH',\n PASSWORD_INPUT = 'PASSWORD_INPUT',\n RADIO = 'RADIO',\n SPY = 'SPY',\n SELECT = 'SELECT',\n TEXTAREA = 'TEXTAREA',\n TIME_PICKER = 'TIME_PICKER',\n TOGGLE = 'TOGGLE',\n}\n\nexport const componentMapper: ComponentMapper = {\n [componentTypes.ALERT]: Alert,\n [componentTypes.BANNER]: Banner,\n [componentTypes.CUSTOM]: Custom,\n [componentTypes.HEADING]: Heading,\n [componentTypes.HYPERLINK]: Hyperlink,\n [componentTypes.TOAST]: Toast,\n [componentTypes.CHECKBOX]: Checkbox,\n [componentTypes.COMBOBOX]: Combobox,\n [componentTypes.DATE_PICKER]: DatePicker,\n [componentTypes.FIELD_ARRAY]: FieldArray,\n [componentTypes.FORM_GROUP]: FormGroup,\n [componentTypes.INPUT]: Input,\n [componentTypes.MODAL]: Modal,\n [componentTypes.PARAGRAPH]: Paragraph,\n [componentTypes.PASSWORD_INPUT]: PasswordInput,\n [componentTypes.RADIO]: Radio,\n [componentTypes.SPY]: Spy,\n [componentTypes.SELECT]: Select,\n [componentTypes.TEXTAREA]: Textarea,\n [componentTypes.TIME_PICKER]: TimePicker,\n [componentTypes.TOGGLE]: Toggle,\n};\n\nexport { ComponentMapper };\n","import React from 'react';\n\nimport { FormTemplateRenderProps } from '@data-driven-forms/react-form-renderer';\n\nexport const BasicTemplate = ({\n formFields,\n}: FormTemplateRenderProps) => {\n return (\n <div>\n {formFields}\n </div>\n );\n};\n","import React from 'react';\nimport {\n Button,\n ButtonColor,\n ButtonVariant,\n ButtonType,\n Form,\n ButtonGroup,\n} from 'react-magma-dom';\n\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nexport interface FormTemplateProps {\n formFields: any;\n schema: any;\n}\n\nexport const FormTemplate = ({\n formFields,\n schema: { cancelLabel, submitLabel },\n schema,\n}: FormTemplateProps) => {\n const { handleSubmit, onCancel, getState } = useFormApi();\n const { submitting, pristine } = getState();\n\n const actions = (\n <ButtonGroup>\n <Button\n disabled={pristine}\n variant={ButtonVariant.link}\n onClick={onCancel}\n >\n {cancelLabel || 'Cancel'}\n </Button>\n <Button\n disabled={submitting}\n type={ButtonType.submit}\n color={ButtonColor.primary}\n >\n {submitLabel || 'Submit'}\n </Button>\n </ButtonGroup>\n );\n\n const actionsVisible = React.useMemo(() => {\n return true;\n }, []);\n\n return (\n <Form\n onSubmit={handleSubmit}\n header={schema.title}\n description={schema.description}\n actions={actionsVisible ? actions : undefined}\n >\n {formFields}\n </Form>\n );\n};\n","import * as React from 'react';\nimport { BasicTemplate } from '../BasicTemplate';\nimport { FormTemplate } from '../FormTemplate';\n\nimport { FormTemplateRenderProps } from '@data-driven-forms/react-form-renderer';\nexport interface TemplateMapper {\n [key: string]: (props: FormTemplateRenderProps) => React.ReactElement;\n}\n\nexport enum templateTypes {\n BASIC = 'BASIC',\n FORM = 'FORM',\n}\n\nexport const templateMapper: TemplateMapper = {\n [templateTypes.BASIC]: BasicTemplate,\n [templateTypes.FORM]: FormTemplate,\n};\n","import React from 'react';\n// import FormRender from '@data-driven-forms/react-form-renderer/dist/cjs/form-renderer';\n\nimport {\n FormRenderer,\n FormRendererProps,\n Schema as DataDrivenFormSchema,\n} from '@data-driven-forms/react-form-renderer';\nimport { componentMapper, ComponentMapper } from '../ComponentMapper';\nimport { templateMapper } from '../TemplateMapper';\nimport { ValidatorMapper } from '../ValidatorMapper';\n\nexport interface Schema extends DataDrivenFormSchema {\n type: string;\n}\n\nexport interface SchemaRendererProps\n extends Omit<FormRendererProps, 'FormTemplate' | 'componentMapper'> {\n schema: Schema;\n customComponentMapper?: ComponentMapper;\n customValidatorMapper?: ValidatorMapper;\n}\n\nexport const SchemaRenderer = ({\n schema,\n customComponentMapper = componentMapper,\n customValidatorMapper,\n ...rest\n}: SchemaRendererProps) => {\n return (\n <FormRenderer\n onCancel={() => {}}\n onSubmit={() => {}}\n {...rest}\n componentMapper={customComponentMapper}\n validatorMapper={customValidatorMapper}\n FormTemplate={templateMapper[schema.type]}\n schema={schema}\n />\n );\n};\n"],"names":["GroupedCheckbox","props","useFieldApi","name","type","value","input","React","MagmaCheckbox","CheckboxMapping","options","validateOnMount","showError","meta","error","submitFailed","rest","uuidv4","errorMessage","length","FormGroup","map","option","key","toString","labelText","Checkbox","memo","ComboboxMapping","innerRef","useRef","useState","label","items","updateItems","newItemTransform","toLowerCase","onItemCreated","item","onChange","isMulti","onSelectedItemsChange","evt","selectedItems","filter","includes","onSelectedItemChange","selectedItem","pop","MagmaCombobox","id","Combobox","CustomMapping","CustomComponent","customComponent","useFormApi","getState","data","values","Custom","DatePickerMapping","MagmaDatePicker","DatePicker","FieldArrayItem","fields","fieldIndex","remove","minItems","removeLabel","renderForm","theme","ThemeContext","editedFields","field","computedName","children","IconButton","icon","DeleteIcon","variant","ButtonVariant","link","onClick","disabled","style","marginTop","spaceScale","spacing04","FieldArray","arrayValidator","description","formFields","defaultItem","maxItems","noItemsMessage","FormControlProps","dirty","isError","FieldArrayBase","validate","push","Button","color","ButtonColor","primary","ButtonType","button","Paragraph","index","FormGroupMapping","subfields","useMemo","MagmaFormGroup","InputMapping","inputRest","MagmaInput","InputType","text","Input","ModalMapping","MagmaModal","Modal","PasswordInputMapping","MagmaPasswordInput","PasswordInput","RadioMapping","RadioGroup","MagmaRadio","Radio","Spy","Template","template","FormSpy","SelectMapping","MagmaSelect","Select","TextareaMapping","MagmaTextarea","Textarea","TimePickerMapping","MagmaTimePicker","TimePicker","ToggleMapping","MagmaToggle","Toggle","componentTypes","componentMapper","ALERT","Alert","BANNER","Banner","CUSTOM","HEADING","Heading","HYPERLINK","Hyperlink","TOAST","Toast","CHECKBOX","COMBOBOX","DATE_PICKER","FIELD_ARRAY","FORM_GROUP","INPUT","MODAL","PARAGRAPH","PASSWORD_INPUT","RADIO","SPY","SELECT","TEXTAREA","TIME_PICKER","TOGGLE","BasicTemplate","FormTemplate","schema","cancelLabel","submitLabel","handleSubmit","onCancel","submitting","pristine","actions","ButtonGroup","submit","actionsVisible","Form","onSubmit","header","title","undefined","templateTypes","templateMapper","BASIC","FORM","SchemaRenderer","customComponentMapper","customValidatorMapper","FormRenderer","validatorMapper"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkBA,IAAMA,eAAe,GAAG,SAAlBA,eAAkB,CAACC,KAAD;AACtB,qBAAkBC,WAAW,CAAC;AAC5BC,IAAAA,IAAI,EAAEF,KAAK,CAACE,IADgB;AAE5BC,IAAAA,IAAI,EAAE,UAFsB;AAG5BC,IAAAA,KAAK,EAAEJ,KAAK,CAACI;AAHe,GAAD,CAA7B;AAAA,MAAQC,KAAR,gBAAQA,KAAR;;AAKA,SAAOC,4BAAA,CAACC,UAAD,oBAAmBP,OAAWK,MAA9B,CAAP;AACD,CAPD;;AASA,IAAMG,eAAe,GAAG,SAAlBA,eAAkB,CAACR,KAAD;AACtB,sBAOIC,WAAW,CAACD,KAAD,CAPf;AAAA,MACEK,KADF,iBACEA,KADF;AAAA,MAEEI,OAFF,iBAEEA,OAFF;AAAA,MAGEC,eAHF,iBAGEA,eAHF;AAAA,MAIEC,SAJF,iBAIEA,SAJF;AAAA,yCAKEC,IALF;AAAA,MAKUC,KALV,sBAKUA,KALV;AAAA,MAKiBC,YALjB,sBAKiBA,YALjB;AAAA,MAMKC,IANL;;AAQA,MAAMb,IAAI,GAAGG,KAAK,CAACH,IAAN,IAAcc,EAAM,EAAjC;AAEA,MAAMC,YAAY,GACf,CAACP,eAAe,IAAII,YAAnB,IAAmCH,SAApC,KAAkDE,KAAnD,IACAE,IAAI,CAACE,YAFP;;AAIA,M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EC,IAAAA,QAAQ,EAAET;AACVU,IAAAA,MAAM,EAAEb,MAAM,CAACc;AACfnG,IAAAA,WAAW,EAAEqF,MAAM,CAACrF;AACpB4F,IAAAA,OAAO,EAAEG,cAAc,GAAGH,OAAH,GAAaQ;GAJtC,EAMGnG,UANH,CADF;AAUD,CAzCM;;;ICRKoG,aAAZ;;AAAA,WAAYA;AACVA,EAAAA,sBAAA,UAAA;AACAA,EAAAA,qBAAA,SAAA;AACD,CAHD,EAAYA,aAAa,KAAbA,aAAa,KAAA,CAAzB;;AAKA,IAAaC,cAAc,0CACxBD,aAAa,CAACE,KADU,IACFpB,aADE,kBAExBkB,aAAa,CAACG,IAFU,IAEHpB,YAFG,kBAApB;;;ACdP,IAuBaqB,cAAc,GAAG,SAAjBA,cAAiB;MAC5BpB,cAAAA;mCACAqB;MAAAA,2DAAwBlD;MACxBmD,6BAAAA;MACGrL;;AAEH,SACET,4BAAA,CAAC+L,YAAD;AACEnB,IAAAA,QAAQ,EAAE;AACVQ,IAAAA,QAAQ,EAAE;KACN3K;AACJkI,IAAAA,eAAe,EAAEkD;AACjBG,IAAAA,eAAe,EAAEF;AACjBvB,IAAAA,YAAY,EAAEkB,cAAc,CAACjB,MAAM,CAAC3K,IAAR;AAC5B2K,IAAAA,MAAM,EAAEA;IAPV,CADF;AAWD,CAjBM;;;;"}
|
|
1
|
+
{"version":3,"file":"schema-renderer.esm.js","sources":["../src/components/Checkbox/index.tsx","../src/components/Combobox/index.tsx","../src/components/Custom/index.tsx","../src/components/DatePicker/index.tsx","../src/components/FieldArray/FieldArrayItem.tsx","../src/components/FieldArray/FieldArray.tsx","../src/components/FormGroup/index.tsx","../src/components/Input/index.tsx","../src/components/Modal/index.tsx","../src/components/PasswordInput/index.tsx","../src/components/Radio/index.tsx","../src/components/Spy/index.tsx","../src/components/Select/index.tsx","../src/components/Textarea/index.tsx","../src/components/TimePicker/index.tsx","../src/components/Toggle/index.tsx","../src/components/ComponentMapper/index.ts","../src/components/BasicTemplate/index.tsx","../src/components/FormTemplate/index.tsx","../src/components/TemplateMapper/index.ts","../src/components/SchemaRenderer/SchemaRenderer.tsx"],"sourcesContent":["import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Checkbox as MagmaCheckbox,\n CheckboxProps as MagmaCheckboxProps,\n FormGroup,\n FormGroupProps as MagmaFormGroupProps,\n} from 'react-magma-dom';\n\ninterface MagmaMultiCheckboxProps extends MagmaFormGroupProps {\n options: MagmaCheckboxProps[];\n}\n\ntype CheckboxProps = MagmaCheckboxProps & UseFieldApiConfig;\ntype MultiCheckboxProps = MagmaMultiCheckboxProps & UseFieldApiConfig;\n\nconst GroupedCheckbox = (props: CheckboxProps) => {\n const { input } = useFieldApi({\n name: props.name,\n type: 'checkbox',\n value: props.value,\n });\n return <MagmaCheckbox {...props} {...input} />;\n};\n\nconst CheckboxMapping = (props: MultiCheckboxProps) => {\n const {\n input,\n options,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) ||\n rest.errorMessage;\n\n if (options && options.length > 0) {\n return (\n <FormGroup errorMessage={errorMessage} {...rest}>\n {options.map((option: MagmaCheckboxProps) => {\n return (\n <GroupedCheckbox\n name={name}\n {...option}\n key={option.value?.toString()}\n />\n );\n })}\n </FormGroup>\n );\n } else {\n return (\n <MagmaCheckbox\n {...input}\n name={name}\n labelText={rest.labelText}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n }\n};\n\nexport const Checkbox = React.memo(CheckboxMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { Combobox as MagmaCombobox } from 'react-magma-dom';\nimport { XORComboboxProps as MagmaComboboxProps } from 'react-magma-dom/dist/components/Combobox';\n\nexport type ComboboxProps = MagmaComboboxProps<ComboOption> & UseFieldApiConfig;\n\ninterface ComboOption {\n label: string;\n value: string;\n name: string;\n}\n\ninterface ComboOptionEvent {\n selectedItem: ComboOption;\n}\n\ninterface MultiComboOptionEvent {\n selectedItems: ComboOption[];\n}\n\nconst ComboboxMapping = (props: ComboboxProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n options,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n const innerRef = React.useRef<HTMLInputElement>(null);\n\n const [items, updateItems] = React.useState(\n options.map(({ labelText, ...rest }: { labelText: string }) => {\n return { label: labelText, ...rest };\n })\n );\n\n const newItemTransform = ({ value }: { value: string }) => {\n return {\n label: value,\n value: value.toLowerCase(),\n };\n };\n\n const onItemCreated = (item: any) => {\n updateItems([...items, item]);\n input.onChange(item.value);\n };\n\n if (rest.isMulti) {\n rest.onSelectedItemsChange = (evt: MultiComboOptionEvent) => {\n input.onChange(evt.selectedItems.map(item => item.value));\n };\n rest.selectedItems = items.filter((item: { value: string }) =>\n input.value.includes(item.value)\n );\n } else {\n rest.onSelectedItemChange = (evt: ComboOptionEvent) => {\n input.onChange(evt.selectedItem.value);\n };\n rest.selectedItem = items\n .filter((item: { value: string }) => item.value === input.value)\n .pop();\n }\n\n return (\n <MagmaCombobox\n {...input}\n id={name}\n innerRef={innerRef}\n items={items}\n newItemTransform={newItemTransform}\n onItemCreated={onItemCreated}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Combobox = React.memo(ComboboxMapping);\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nconst CustomMapping = (props: any) => {\n const { customComponent: CustomComponent, ...rest } = useFieldApi(props);\n const { getState } = useFormApi();\n\n return <CustomComponent {...rest} data={getState().values} />;\n};\n\nexport const Custom = React.memo(CustomMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n DatePicker as MagmaDatePicker,\n DatePickerProps as MagmaDatePickerProps,\n} from 'react-magma-dom';\n\nexport type DatePickerProps = MagmaDatePickerProps & UseFieldApiConfig;\n\nconst DatePickerMapping = (props: DatePickerProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaDatePicker\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const DatePicker = React.memo(DatePickerMapping);\n","import * as React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { IconButton, ButtonVariant, ThemeContext } from 'react-magma-dom';\nimport { DeleteIcon } from 'react-magma-icons';\n\nexport const FieldArrayItem = ({\n fields,\n fieldIndex,\n name,\n remove,\n length,\n minItems,\n removeLabel,\n}: any) => {\n const { renderForm } = useFormApi();\n const theme = React.useContext(ThemeContext);\n\n const editedFields = React.useMemo(() => {\n return fields.map((field: any) => {\n const computedName = field.name ? `${name}.${field.name}` : uuidv4();\n return {\n ...field,\n name: computedName,\n key: computedName,\n labelText: fieldIndex === 0 ? field.labelText : null,\n children: (\n <IconButton\n aria-label={removeLabel}\n icon={<DeleteIcon />}\n variant={ButtonVariant.link}\n onClick={() => remove(fieldIndex)}\n disabled={length <= minItems}\n />\n ),\n };\n });\n }, [fields, name, fieldIndex]);\n\n return (\n <div style={{ marginTop: theme.spaceScale.spacing04 }}>\n {editedFields.map((field: any) => renderForm([field]))}\n </div>\n );\n};\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { FieldArray as FieldArrayBase } from '@data-driven-forms/react-form-renderer';\nimport {\n Button,\n ButtonColor,\n ButtonType,\n Paragraph,\n} from 'react-magma-dom';\n\nimport { FieldArrayItem } from './FieldArrayItem';\n\nexport const FieldArray = ({ ...props }: any) => {\n const {\n arrayValidator,\n label,\n description,\n fields: formFields,\n defaultItem,\n meta,\n minItems,\n maxItems,\n noItemsMessage = \"You haven't added any items yet!\",\n FormControlProps,\n ...rest\n } = useFieldApi(props);\n\n const { dirty, submitFailed, error } = meta;\n const isError = (dirty || submitFailed) && error && typeof error === 'string';\n\n return (\n <FieldArrayBase\n key={rest.input.name}\n name={rest.input.name}\n validate={arrayValidator}\n >\n {({ fields: { map, value = [], push, remove } }) => {\n return (\n <>\n {<h6>label</h6>}\n <Button\n color={ButtonColor.primary}\n type={ButtonType.button}\n onClick={() => push(defaultItem)}\n disabled={value.length >= maxItems}\n >\n ADD ITEM\n </Button>\n {description && <Paragraph>{description}</Paragraph>}\n {value.length <= 0 ? (\n <Paragraph>{noItemsMessage}</Paragraph>\n ) : (\n map((name, index) => (\n <FieldArrayItem\n key={name}\n fields={formFields}\n name={name}\n fieldIndex={index}\n remove={remove}\n length={value.length}\n minItems={minItems}\n removeLabel=\"REMOVE\"\n />\n ))\n )}\n {isError && <Paragraph>{error}</Paragraph>}\n </>\n );\n }}\n </FieldArrayBase>\n );\n};\n","import React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\nimport {\n FormGroup as MagmaFormGroup,\n FormGroupProps as MagmaFormGroupProps,\n} from 'react-magma-dom';\n\nexport interface FormGroupProps extends MagmaFormGroupProps {\n fields: any;\n showError?: boolean;\n}\n\nconst FormGroupMapping = (props: FormGroupProps) => {\n const { renderForm } = useFormApi();\n\n const subfields = React.useMemo(() => {\n return props.fields.map((field: any) => ({\n ...field,\n showError: props.showError,\n }));\n }, [props.fields, props.showError]);\n\n return <MagmaFormGroup {...props}>{renderForm(subfields)}</MagmaFormGroup>;\n};\n\nexport const FormGroup = React.memo(FormGroupMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Input as MagmaInput,\n InputType,\n InputProps as MagmaInputProps,\n} from 'react-magma-dom';\n\nexport type InputProps = MagmaInputProps & UseFieldApiConfig;\n\nconst InputMapping = (props: InputProps) => {\n const {\n input,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n input: { type = 'text', ...inputRest },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaInput\n {...inputRest}\n type={InputType[type as keyof typeof InputType] || InputType.text}\n id={id}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n};\n\nexport const Input = React.memo(InputMapping);\n","import React from 'react';\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nimport {\n Modal as MagmaModal,\n ModalProps as MagmaModalProps,\n} from 'react-magma-dom';\n\nexport interface ModalProps extends MagmaModalProps {\n fields: any;\n showError?: boolean;\n}\n\nconst ModalMapping = (props: ModalProps) => {\n const { renderForm } = useFormApi();\n\n const subfields = React.useMemo(() => {\n return props.fields.map((field: any) => ({\n ...field,\n showError: props.showError,\n }));\n }, [props.fields, props.showError]);\n\n return <MagmaModal {...props}>{renderForm(subfields)}</MagmaModal>;\n};\n\nexport const Modal = React.memo(ModalMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n PasswordInput as MagmaPasswordInput,\n PasswordInputProps as MagmaPasswordInputProps,\n} from 'react-magma-dom';\n\nexport type PasswordInputProps = MagmaPasswordInputProps & UseFieldApiConfig;\n\nconst PasswordInputMapping = (props: PasswordInputProps) => {\n const {\n input,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaPasswordInput\n {...input}\n labelText={rest.labelText}\n id={id}\n errorMessage={errorMessage}\n {...rest}\n />\n );\n};\n\nexport const PasswordInput = React.memo(PasswordInputMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Radio as MagmaRadio,\n RadioProps,\n RadioGroup,\n RadioGroupProps as MagmaRadioGroupProps,\n} from 'react-magma-dom';\n\ntype RadioGroupProps = MagmaRadioGroupProps & UseFieldApiConfig;\n\nconst RadioMapping = (props: RadioGroupProps) => {\n const {\n input,\n options,\n validateOnMount,\n showError,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi({ ...props, type: 'radio' });\n const name = input.name || uuidv4();\n\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) ||\n rest.errorMessage;\n\n return (\n <RadioGroup\n onChange={input.onChange}\n errorMessage={errorMessage}\n name={name}\n {...rest}\n >\n {options.map((option: RadioProps) => {\n return <MagmaRadio {...option} key={option.value?.toString()} />;\n })}\n </RadioGroup>\n );\n};\n\nexport const Radio = React.memo(RadioMapping);\n","import React from 'react';\nimport { FormSpy } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\n\nexport const Spy = (props: any) => {\n const { template: Template, ...rest } = useFieldApi(props);\n return (\n <FormSpy {...rest}>\n {props => {\n return <Template {...props} />;\n }}\n </FormSpy>\n );\n};\n","import * as React from 'react';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport { Select as MagmaSelect } from 'react-magma-dom';\n\ninterface SelectOption {\n label: string;\n value: string;\n name: string;\n}\n\ninterface SelectOptionEvent {\n selectedItem: SelectOption;\n}\n\ninterface MultiSelectOptionEvent {\n selectedItems: SelectOption[];\n}\n\nconst SelectMapping = (props: any) => {\n const {\n input,\n validateOnMount,\n showError,\n options,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const name = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n if (rest.isMulti) {\n rest.onSelectedItemsChange = (evt: MultiSelectOptionEvent) => {\n input.onChange(evt.selectedItems.map(item => item.value));\n };\n } else {\n rest.onSelectedItemChange = (evt: SelectOptionEvent) => {\n input.onChange(evt.selectedItem.value);\n };\n }\n\n return (\n <MagmaSelect\n id={name}\n items={options.map(({ labelText, ...rest }: { labelText: string }) => {\n return { label: labelText, ...rest };\n })}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Select = React.memo(SelectMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Textarea as MagmaTextarea,\n TextareaProps as MagmaTextareaProps,\n} from 'react-magma-dom';\n\nexport type TextareaProps = MagmaTextareaProps & UseFieldApiConfig;\n\nconst TextareaMapping = (props: TextareaProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaTextarea\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Textarea = React.memo(TextareaMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n TimePicker as MagmaTimePicker,\n TimePickerProps as MagmaTimePickerProps,\n} from 'react-magma-dom';\n\nexport type TimePickerProps = MagmaTimePickerProps & UseFieldApiConfig;\n\nconst TimePickerMapping = (props: TimePickerProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaTimePicker\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const TimePicker = React.memo(TimePickerMapping);\n","import React from 'react';\nimport { UseFieldApiConfig } from '@data-driven-forms/react-form-renderer';\nimport useFieldApi from '@data-driven-forms/react-form-renderer/use-field-api';\nimport { v4 as uuidv4 } from 'uuid';\nimport {\n Toggle as MagmaToggle,\n ToggleProps as MagmaToggleProps,\n} from 'react-magma-dom';\n\nexport type ToggleProps = MagmaToggleProps & UseFieldApiConfig;\n\nconst ToggleMapping = (props: ToggleProps) => {\n const {\n input,\n validateOnMount,\n showError,\n type,\n meta: { error, submitFailed },\n ...rest\n } = useFieldApi(props);\n const id = input.name || uuidv4();\n const errorMessage =\n ((validateOnMount || submitFailed || showError) && error) || '';\n\n return (\n <MagmaToggle\n {...input}\n id={id}\n errorMessage={errorMessage}\n labelText={rest.labelText}\n {...rest}\n />\n );\n};\n\nexport const Toggle = React.memo(ToggleMapping);\n","import { ComponentMapper } from '@data-driven-forms/react-form-renderer';\n\nimport { Checkbox } from '../Checkbox';\nimport { Combobox } from '../Combobox';\nimport { Custom } from '../Custom';\nimport { DatePicker } from '../DatePicker';\nimport { FieldArray } from '../FieldArray';\nimport { FormGroup } from '../FormGroup';\nimport { Input } from '../Input';\nimport { Modal } from '../Modal';\nimport { PasswordInput } from '../PasswordInput';\nimport { Radio } from '../Radio';\nimport { Spy } from '../Spy';\nimport { Select } from '../Select';\nimport { Textarea } from '../Textarea';\nimport { TimePicker } from '../TimePicker';\nimport { Toggle } from '../Toggle';\n\nimport {\n Alert,\n Banner,\n Heading,\n Hyperlink,\n Toast,\n Paragraph,\n} from 'react-magma-dom';\n\nexport enum componentTypes {\n ALERT = 'ALERT',\n BANNER = 'BANNER',\n CUSTOM = 'CUSTOM',\n HEADING = 'HEADING',\n HYPERLINK = 'HYPERLINK',\n TOAST = 'TOAST',\n CHECKBOX = 'CHECKBOX',\n COMBOBOX = 'COMBOBOX',\n DATE_PICKER = 'DATE_PICKER',\n FIELD_ARRAY = 'FIELD_ARRAY',\n FORM_GROUP = 'FORM_GROUP',\n INPUT = 'INPUT',\n MODAL = 'MODAL',\n PARAGRAPH = 'PARAGRAPH',\n PASSWORD_INPUT = 'PASSWORD_INPUT',\n RADIO = 'RADIO',\n SPY = 'SPY',\n SELECT = 'SELECT',\n TEXTAREA = 'TEXTAREA',\n TIME_PICKER = 'TIME_PICKER',\n TOGGLE = 'TOGGLE',\n}\n\nexport const componentMapper: ComponentMapper = {\n [componentTypes.ALERT]: Alert,\n [componentTypes.BANNER]: Banner,\n [componentTypes.CUSTOM]: Custom,\n [componentTypes.HEADING]: Heading,\n [componentTypes.HYPERLINK]: Hyperlink,\n [componentTypes.TOAST]: Toast,\n [componentTypes.CHECKBOX]: Checkbox,\n [componentTypes.COMBOBOX]: Combobox,\n [componentTypes.DATE_PICKER]: DatePicker,\n [componentTypes.FIELD_ARRAY]: FieldArray,\n [componentTypes.FORM_GROUP]: FormGroup,\n [componentTypes.INPUT]: Input,\n [componentTypes.MODAL]: Modal,\n [componentTypes.PARAGRAPH]: Paragraph,\n [componentTypes.PASSWORD_INPUT]: PasswordInput,\n [componentTypes.RADIO]: Radio,\n [componentTypes.SPY]: Spy,\n [componentTypes.SELECT]: Select,\n [componentTypes.TEXTAREA]: Textarea,\n [componentTypes.TIME_PICKER]: TimePicker,\n [componentTypes.TOGGLE]: Toggle,\n};\n\nexport { ComponentMapper };\n","import React from 'react';\n\nimport { FormTemplateRenderProps } from '@data-driven-forms/react-form-renderer';\n\nexport const BasicTemplate = ({\n formFields,\n}: FormTemplateRenderProps) => {\n return (\n <div>\n {formFields}\n </div>\n );\n};\n","import React from 'react';\nimport {\n Button,\n ButtonColor,\n ButtonVariant,\n ButtonType,\n Form,\n ButtonGroup,\n} from 'react-magma-dom';\n\nimport useFormApi from '@data-driven-forms/react-form-renderer/use-form-api';\n\nexport interface FormTemplateProps {\n formFields: any;\n schema: any;\n}\n\nexport const FormTemplate = ({\n formFields,\n schema: { cancelLabel, submitLabel },\n schema,\n}: FormTemplateProps) => {\n const { handleSubmit, onCancel, getState } = useFormApi();\n const { submitting, pristine } = getState();\n\n const actions = (\n <ButtonGroup>\n <Button\n disabled={pristine}\n variant={ButtonVariant.link}\n onClick={onCancel}\n >\n {cancelLabel || 'Cancel'}\n </Button>\n <Button\n disabled={submitting}\n type={ButtonType.submit}\n color={ButtonColor.primary}\n >\n {submitLabel || 'Submit'}\n </Button>\n </ButtonGroup>\n );\n\n const actionsVisible = React.useMemo(() => {\n return true;\n }, []);\n\n return (\n <Form\n onSubmit={handleSubmit}\n header={schema.title}\n description={schema.description}\n actions={actionsVisible ? actions : undefined}\n >\n {formFields}\n </Form>\n );\n};\n","import * as React from 'react';\nimport { BasicTemplate } from '../BasicTemplate';\nimport { FormTemplate } from '../FormTemplate';\n\nimport { FormTemplateRenderProps } from '@data-driven-forms/react-form-renderer';\nexport interface TemplateMapper {\n [key: string]: (props: FormTemplateRenderProps) => React.ReactElement;\n}\n\nexport enum templateTypes {\n BASIC = 'BASIC',\n FORM = 'FORM',\n}\n\nexport const templateMapper: TemplateMapper = {\n [templateTypes.BASIC]: BasicTemplate,\n [templateTypes.FORM]: FormTemplate,\n};\n","import React from 'react';\n// import FormRender from '@data-driven-forms/react-form-renderer/dist/cjs/form-renderer';\n\nimport {\n FormRenderer,\n FormRendererProps,\n Schema as DataDrivenFormSchema,\n} from '@data-driven-forms/react-form-renderer';\nimport { componentMapper, ComponentMapper } from '../ComponentMapper';\nimport { templateMapper } from '../TemplateMapper';\nimport { ValidatorMapper } from '../ValidatorMapper';\n\nexport interface Schema extends DataDrivenFormSchema {\n type: string;\n}\n\nexport interface SchemaRendererProps\n extends Omit<FormRendererProps, 'FormTemplate' | 'componentMapper'> {\n schema: Schema;\n customComponentMapper?: ComponentMapper;\n customValidatorMapper?: ValidatorMapper;\n}\n\nexport const SchemaRenderer = ({\n schema,\n customComponentMapper = componentMapper,\n customValidatorMapper,\n ...rest\n}: SchemaRendererProps) => {\n return (\n <FormRenderer\n onCancel={() => {}}\n onSubmit={() => {}}\n {...rest}\n componentMapper={customComponentMapper}\n validatorMapper={customValidatorMapper}\n FormTemplate={templateMapper[schema.type]}\n schema={schema}\n />\n );\n};\n"],"names":["GroupedCheckbox","props","useFieldApi","name","type","value","input","React","MagmaCheckbox","CheckboxMapping","options","validateOnMount","showError","meta","error","submitFailed","rest","uuidv4","errorMessage","length","FormGroup","map","option","key","toString","labelText","Checkbox","memo","ComboboxMapping","innerRef","useRef","useState","label","items","updateItems","newItemTransform","toLowerCase","onItemCreated","item","onChange","isMulti","onSelectedItemsChange","evt","selectedItems","filter","includes","onSelectedItemChange","selectedItem","pop","MagmaCombobox","id","Combobox","CustomMapping","CustomComponent","customComponent","useFormApi","getState","data","values","Custom","DatePickerMapping","MagmaDatePicker","DatePicker","FieldArrayItem","fields","fieldIndex","remove","minItems","removeLabel","renderForm","theme","ThemeContext","editedFields","field","computedName","children","IconButton","icon","DeleteIcon","variant","ButtonVariant","link","onClick","disabled","style","marginTop","spaceScale","spacing04","FieldArray","arrayValidator","description","formFields","defaultItem","maxItems","noItemsMessage","FormControlProps","dirty","isError","FieldArrayBase","validate","push","Button","color","ButtonColor","primary","ButtonType","button","Paragraph","index","FormGroupMapping","subfields","useMemo","MagmaFormGroup","InputMapping","inputRest","MagmaInput","InputType","text","Input","ModalMapping","MagmaModal","Modal","PasswordInputMapping","MagmaPasswordInput","PasswordInput","RadioMapping","RadioGroup","MagmaRadio","Radio","Spy","Template","template","FormSpy","SelectMapping","MagmaSelect","Select","TextareaMapping","MagmaTextarea","Textarea","TimePickerMapping","MagmaTimePicker","TimePicker","ToggleMapping","MagmaToggle","Toggle","componentTypes","componentMapper","ALERT","Alert","BANNER","Banner","CUSTOM","HEADING","Heading","HYPERLINK","Hyperlink","TOAST","Toast","CHECKBOX","COMBOBOX","DATE_PICKER","FIELD_ARRAY","FORM_GROUP","INPUT","MODAL","PARAGRAPH","PASSWORD_INPUT","RADIO","SPY","SELECT","TEXTAREA","TIME_PICKER","TOGGLE","BasicTemplate","FormTemplate","schema","cancelLabel","submitLabel","handleSubmit","onCancel","submitting","pristine","actions","ButtonGroup","submit","actionsVisible","Form","onSubmit","header","title","undefined","templateTypes","templateMapper","BASIC","FORM","SchemaRenderer","customComponentMapper","customValidatorMapper","FormRenderer","validatorMapper"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkBA,IAAMA,eAAe,GAAG,SAAlBA,eAAe,CAAIC,KAAoB;EAC3C,mBAAkBC,WAAW,CAAC;MAC5BC,IAAI,EAAEF,KAAK,CAACE,IAAI;MAChBC,IAAI,EAAE,UAAU;MAChBC,KAAK,EAAEJ,KAAK,CAACI;KACd,CAAC;IAJMC,KAAK,gBAALA,KAAK;EAKb,OAAOC,6BAACC,UAAa,oBAAKP,KAAK,EAAMK,KAAK,EAAI;AAChD,CAAC;AAED,IAAMG,eAAe,GAAG,SAAlBA,eAAe,CAAIR,KAAyB;EAChD,oBAOIC,WAAW,CAACD,KAAK,CAAC;IANpBK,KAAK,iBAALA,KAAK;IACLI,OAAO,iBAAPA,OAAO;IACPC,eAAe,iBAAfA,eAAe;IACfC,SAAS,iBAATA,SAAS;IAAA,mCACTC,IAAI;IAAIC,KAAK,sBAALA,KAAK;IAAEC,YAAY,sBAAZA,YAAY;IACxBC,IAAI;EAET,I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GQ;KAEnCnG,UAAU,CACN;AAEX,CAAC;;;ACzDD,IAQYoG,aAGX;AAHD,WAAYA,aAAa;EACvBA,gCAAe;EACfA,8BAAa;AACf,CAAC,EAHWA,aAAa,KAAbA,aAAa;AAKzB,IAAaC,cAAc,0CACxBD,aAAa,CAACE,KAAK,IAAGpB,aAAa,kBACnCkB,aAAa,CAACG,IAAI,IAAGpB,YAAY,kBACnC;;;ACjBD,IAuBaqB,cAAc,GAAG,SAAjBA,cAAc;MACzBpB,MAAM,QAANA,MAAM;IAAA,6BACNqB,qBAAqB;IAArBA,qBAAqB,sCAAGlD,eAAe;IACvCmD,qBAAqB,QAArBA,qBAAqB;IAClBrL,IAAI;EAEP,OACET,6BAAC+L,YAAY;IACXnB,QAAQ,EAAE,sBAAQ;IAClBQ,QAAQ,EAAE;KACN3K,IAAI;IACRkI,eAAe,EAAEkD,qBAAqB;IACtCG,eAAe,EAAEF,qBAAqB;IACtCvB,YAAY,EAAEkB,cAAc,CAACjB,MAAM,CAAC3K,IAAI,CAAC;IACzC2K,MAAM,EAAEA;KACR;AAEN,CAAC;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@react-magma/schema-renderer",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"@emotion/styled": "^10.0.27",
|
|
26
26
|
"date-fns": "^2.12.0",
|
|
27
27
|
"downshift": "^5.4.5",
|
|
28
|
-
"react": "^
|
|
29
|
-
"react-dom": "^
|
|
30
|
-
"react-magma-dom": "^
|
|
31
|
-
"react-magma-icons": "
|
|
28
|
+
"react": "^17.0.2",
|
|
29
|
+
"react-dom": "^17.0.2",
|
|
30
|
+
"react-magma-dom": "^4.0.0-next.0",
|
|
31
|
+
"react-magma-icons": "^3.0.0",
|
|
32
32
|
"uuid": "^8.3.0"
|
|
33
33
|
},
|
|
34
34
|
"module": "dist/react-magma-schema-renderer.esm.js",
|
|
@@ -38,11 +38,11 @@
|
|
|
38
38
|
"@emotion/styled": "^10.0.27",
|
|
39
39
|
"date-fns": "^2.16.1",
|
|
40
40
|
"downshift": "^5.4.5",
|
|
41
|
-
"react": "^
|
|
42
|
-
"react-dom": "^
|
|
41
|
+
"react": "^17.0.2",
|
|
42
|
+
"react-dom": "^17.0.2",
|
|
43
43
|
"react-dropzone": "11.3.2",
|
|
44
|
-
"react-magma-dom": "^
|
|
45
|
-
"react-magma-icons": "
|
|
44
|
+
"react-magma-dom": "^4.0.0",
|
|
45
|
+
"react-magma-icons": "^3.0.0",
|
|
46
46
|
"tsdx": "^0.14.1",
|
|
47
47
|
"uuid": "^8.3.0"
|
|
48
48
|
},
|