@backstage/plugin-scaffolder-react 2.1.0-next.1 → 2.1.1-next.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/CHANGELOG.md +37 -0
- package/dist/alpha.esm.js.map +1 -1
- package/dist/api/ref.esm.js.map +1 -1
- package/dist/extensions/createScaffolderFieldExtension.esm.js.map +1 -1
- package/dist/extensions/keys.esm.js.map +1 -1
- package/dist/hooks/useCustomFieldExtensions.esm.js.map +1 -1
- package/dist/hooks/useCustomLayouts.esm.js.map +1 -1
- package/dist/hooks/useEventStream.esm.js +132 -67
- package/dist/hooks/useEventStream.esm.js.map +1 -1
- package/dist/layouts/createScaffolderLayout.esm.js.map +1 -1
- package/dist/layouts/keys.esm.js.map +1 -1
- package/dist/next/api/index.esm.js.map +1 -1
- package/dist/next/blueprints/FormDecoratorBlueprint.esm.js.map +1 -1
- package/dist/next/blueprints/FormFieldBlueprint.esm.js.map +1 -1
- package/dist/next/blueprints/scaffolderTaskOutputsBlueprint.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/Form.module.css.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/index.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ArrayFieldDescriptionTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ArrayFieldItemTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ArrayFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ArrayFieldTitleTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ButtonTemplates.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/DescriptionFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ErrorListTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/FieldErrorTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/FieldHelpTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/FieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/ObjectFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/TitleFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/UnsupportedFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/WrapIfAdditionalTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/templates/index.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/BaseInputTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/CheckboxWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/CheckboxesWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/ColorWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/DateInput.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/DateTimeWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/DateWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/EmailWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/FileWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/HiddenWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/PasswordWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/RadioWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/RangeWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/SelectWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/TextWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/TextareaWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/TimeWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/URLWidget.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/index.esm.js.map +1 -1
- package/dist/next/components/Form/BuiTheme/widgets/selectOverrides.module.css.esm.js.map +1 -1
- package/dist/next/components/Form/DescriptionFieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/FieldTemplate.esm.js.map +1 -1
- package/dist/next/components/Form/Form.esm.js.map +1 -1
- package/dist/next/components/Form/ScaffolderThemeContext.esm.js.map +1 -1
- package/dist/next/components/PasswordWidget/PasswordWidget.esm.js.map +1 -1
- package/dist/next/components/ReviewState/ReviewState.esm.js +1 -1
- package/dist/next/components/ReviewState/ReviewState.esm.js.map +1 -1
- package/dist/next/components/ReviewState/util.esm.js.map +1 -1
- package/dist/next/components/ScaffolderField/ScaffolderField.esm.js.map +1 -1
- package/dist/next/components/ScaffolderPageContextMenu/ScaffolderPageContextMenu.esm.js.map +1 -1
- package/dist/next/components/SecretWidget/SecretWidget.esm.js.map +1 -1
- package/dist/next/components/Stepper/ErrorListTemplate/errorListTemplate.esm.js.map +1 -1
- package/dist/next/components/Stepper/FieldOverrides/DescriptionField.esm.js.map +1 -1
- package/dist/next/components/Stepper/Stepper.esm.js.map +1 -1
- package/dist/next/components/Stepper/createAsyncValidators.esm.js.map +1 -1
- package/dist/next/components/Stepper/utils.esm.js.map +1 -1
- package/dist/next/components/TaskLogStream/TaskLogStream.esm.js.map +1 -1
- package/dist/next/components/TaskSteps/StepIcon.esm.js.map +1 -1
- package/dist/next/components/TaskSteps/StepTime.esm.js.map +1 -1
- package/dist/next/components/TaskSteps/TaskBorder.esm.js.map +1 -1
- package/dist/next/components/TaskSteps/TaskSteps.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/CardHeader.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/CardLink.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCard.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCardActions.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCardContent.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCardImpl.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCardLinks.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateCardTags.esm.js.map +1 -1
- package/dist/next/components/TemplateCard/TemplateDetailButton.esm.js.map +1 -1
- package/dist/next/components/TemplateCategoryPicker/TemplateCategoryPicker.esm.js.map +1 -1
- package/dist/next/components/TemplateGroup/TemplateGroup.esm.js.map +1 -1
- package/dist/next/components/TemplateGroups/TemplateGroups.esm.js.map +1 -1
- package/dist/next/components/TemplateOutputs/DefaultTemplateOutputs.esm.js.map +1 -1
- package/dist/next/components/TemplateOutputs/LinkOutputs.esm.js.map +1 -1
- package/dist/next/components/TemplateOutputs/TextOutputs.esm.js.map +1 -1
- package/dist/next/components/Workflow/Workflow.esm.js.map +1 -1
- package/dist/next/extensions/createScaffolderFormDecorator.esm.js.map +1 -1
- package/dist/next/hooks/useDownloadLogs.esm.js.map +1 -1
- package/dist/next/hooks/useFilteredSchemaProperties.esm.js.map +1 -1
- package/dist/next/hooks/useFormDataFromQuery.esm.js.map +1 -1
- package/dist/next/hooks/useTemplateParameterSchema.esm.js.map +1 -1
- package/dist/next/hooks/useTemplateSchema.esm.js.map +1 -1
- package/dist/next/hooks/useTemplateTimeSaved.esm.js.map +1 -1
- package/dist/next/hooks/useTransformSchemaToProps.esm.js.map +1 -1
- package/dist/next/lib/schema.esm.js.map +1 -1
- package/dist/node_modules_dist/style-inject/dist/style-inject.es.esm.js.map +1 -1
- package/dist/packages/opaque-internal/src/OpaqueType.esm.js.map +1 -1
- package/dist/packages/scaffolder-internal/src/wiring/InternalFormDecorator.esm.js.map +1 -1
- package/dist/packages/scaffolder-internal/src/wiring/InternalFormField.esm.js.map +1 -1
- package/dist/secrets/SecretsContext.esm.js.map +1 -1
- package/dist/testUtils/scaffolderApiMock.esm.js.map +1 -1
- package/dist/translation.esm.js.map +1 -1
- package/dist/utils.esm.js.map +1 -1
- package/package.json +18 -18
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ArrayFieldTitleTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ArrayFieldTitleTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ArrayFieldTitleProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n titleId,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function ArrayFieldTitleTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ idSchema, title, required }: ArrayFieldTitleProps<T, S, F>) {\n if (!title) {\n return null;\n }\n\n const id = titleId<T>(idSchema);\n\n return (\n <Text id={id} as=\"h3\" variant=\"title-medium\" weight=\"bold\">\n {title}\n {required && (\n <Text as=\"span\" color=\"danger\">\n {' '}\n *\n </Text>\n )}\n </Text>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,uBAAA,CAItB,EAAE,QAAA,EAAU,KAAA,EAAO,UAAS,EAAkC;AAC9D,EAAA,IAAI,CAAC,KAAA,EAAO;AACV,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,QAAW,QAAQ,CAAA;AAE9B,EAAA,uBACE,IAAA,CAAC,QAAK,EAAA,EAAQ,EAAA,EAAG,MAAK,OAAA,EAAQ,cAAA,EAAe,QAAO,MAAA,EACjD,QAAA,EAAA;AAAA,IAAA,KAAA;AAAA,IACA,4BACC,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAG,MAAA,EAAO,OAAM,QAAA,EACnB,QAAA,EAAA;AAAA,MAAA,GAAA;AAAA,MAAI;AAAA,KAAA,EAEP;AAAA,GAAA,EAEJ,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"ArrayFieldTitleTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ArrayFieldTitleTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ArrayFieldTitleProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n titleId,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function ArrayFieldTitleTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ idSchema, title, required }: ArrayFieldTitleProps<T, S, F>) {\n if (!title) {\n return null;\n }\n\n const id = titleId<T>(idSchema);\n\n return (\n <Text id={id} as=\"h3\" variant=\"title-medium\" weight=\"bold\">\n {title}\n {required && (\n <Text as=\"span\" color=\"danger\">\n {' '}\n *\n </Text>\n )}\n </Text>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,uBAAA,CAItB,EAAE,QAAA,EAAU,KAAA,EAAO,UAAS,EAAkC;AAC9D,EAAA,IAAI,CAAC,KAAA,EAAO;AACV,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,QAAW,QAAQ,CAAA;AAE9B,EAAA,uBACE,IAAA,CAAC,QAAK,EAAA,EAAQ,EAAA,EAAG,MAAK,OAAA,EAAQ,cAAA,EAAe,QAAO,MAAA,EACjD,QAAA,EAAA;AAAA,IAAA,KAAA;AAAA,IACA,4BACC,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAG,MAAA,EAAO,OAAM,QAAA,EACnB,QAAA,EAAA;AAAA,MAAA,GAAA;AAAA,MAAI;AAAA,KAAA,EAEP;AAAA,GAAA,EAEJ,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonTemplates.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ButtonTemplates.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n IconButtonProps,\n RJSFSchema,\n StrictRJSFSchema,\n SubmitButtonProps,\n TranslatableString,\n getSubmitButtonOptions,\n} from '@rjsf/utils';\nimport { Button } from '@backstage/ui';\nimport {\n RiAddLine,\n RiArrowUpLine,\n RiArrowDownLine,\n RiDeleteBinLine,\n RiFileCopyLine,\n} from '@remixicon/react';\n\nexport function SubmitButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ uiSchema }: SubmitButtonProps<T, S, F>) {\n const {\n submitText,\n norender,\n props: submitButtonProps = {},\n } = getSubmitButtonOptions<T, S, F>(uiSchema);\n\n if (norender) {\n return null;\n }\n\n return (\n <Button type=\"submit\" variant=\"primary\" {...submitButtonProps}>\n {submitText}\n </Button>\n );\n}\n\nexport function AddButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ registry, disabled, onClick, className }: IconButtonProps<T, S, F>) {\n const { translateString } = registry;\n\n const handleClick = onClick ? (e: any) => onClick(e) : undefined;\n\n return (\n <Button\n isDisabled={disabled}\n onClick={handleClick}\n className={className}\n variant=\"secondary\"\n size=\"small\"\n iconStart={<RiAddLine />}\n >\n {translateString(TranslatableString.AddItemButton)}\n </Button>\n );\n}\n\nexport function IconButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: IconButtonProps<T, S, F>) {\n const { icon, registry, disabled, onClick, className } = props;\n const { translateString } = registry;\n\n let buttonIcon;\n let buttonLabel;\n\n switch (icon) {\n case 'arrow-up':\n buttonIcon = <RiArrowUpLine />;\n buttonLabel = translateString(TranslatableString.MoveUpButton);\n break;\n case 'arrow-down':\n buttonIcon = <RiArrowDownLine />;\n buttonLabel = translateString(TranslatableString.MoveDownButton);\n break;\n case 'remove':\n buttonIcon = <RiDeleteBinLine />;\n buttonLabel = translateString(TranslatableString.RemoveButton);\n break;\n case 'copy':\n buttonIcon = <RiFileCopyLine />;\n buttonLabel = translateString(TranslatableString.CopyButton);\n break;\n default:\n buttonIcon = null;\n buttonLabel = '';\n }\n\n const handleClick = onClick ? () => onClick(undefined as any) : undefined;\n\n return (\n <Button\n isDisabled={disabled}\n onClick={handleClick}\n className={className}\n variant=\"tertiary\"\n size=\"small\"\n iconStart={buttonIcon || undefined}\n >\n {buttonLabel}\n </Button>\n );\n}\n\nconst ButtonTemplates = {\n SubmitButton,\n AddButton,\n RemoveButton: IconButton,\n MoveDownButton: IconButton,\n MoveUpButton: IconButton,\n CopyButton: IconButton,\n};\n\nexport default ButtonTemplates;\n"],"names":[],"mappings":";;;;;AAiCO,SAAS,YAAA,CAId,EAAE,QAAA,EAAS,EAA+B;AAC1C,EAAA,MAAM;AAAA,IACJ,UAAA;AAAA,IACA,QAAA;AAAA,IACA,KAAA,EAAO,oBAAoB;AAAC,GA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c,eAAA,CAAgB,mBAAmB,cAAc,CAAA;AAC/D,MAAA;AAAA,IACF,KAAK,QAAA;AACH,MAAA,UAAA,uBAAc,eAAA,EAAA,EAAgB,CAAA;AAC9B,MAAA,WAAA,GAAc,eAAA,CAAgB,mBAAmB,YAAY,CAAA;AAC7D,MAAA;AAAA,IACF,KAAK,MAAA;AACH,MAAA,UAAA,uBAAc,cAAA,EAAA,EAAe,CAAA;AAC7B,MAAA,WAAA,GAAc,eAAA,CAAgB,mBAAmB,UAAU,CAAA;AAC3D,MAAA;AAAA,IACF;AACE,MAAA,UAAA,GAAa,IAAA;AACb,MAAA,WAAA,GAAc,EAAA;AAAA;AAGlB,EAAA,MAAM,WAAA,GAAc,OAAA,GAAU,MAAM,OAAA,CAAQ,MAAgB,CAAA,GAAI,MAAA;AAEhE,EAAA,uBACE,GAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,UAAA,EAAY,QAAA;AAAA,MACZ,OAAA,EAAS,WAAA;AAAA,MACT,SAAA;AAAA,MACA,OAAA,EAAQ,UAAA;AAAA,MACR,IAAA,EAAK,OAAA;AAAA,MACL,WAAW,UAAA,IAAc,MAAA;AAAA,MAExB,QAAA,EAAA;AAAA;AAAA,GACH;AAEJ;AAEA,MAAM,eAAA,GAAkB;AAAA,EACtB,YAAA;AAAA,EACA,SAAA;AAAA,EACA,YAAA,EAAc,UAAA;AAAA,EACd,cAAA,EAAgB,UAAA;AAAA,EAChB,YAAA,EAAc,UAAA;AAAA,EACd,UAAA,EAAY;AACd
|
|
1
|
+
{"version":3,"file":"ButtonTemplates.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ButtonTemplates.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n IconButtonProps,\n RJSFSchema,\n StrictRJSFSchema,\n SubmitButtonProps,\n TranslatableString,\n getSubmitButtonOptions,\n} from '@rjsf/utils';\nimport { Button } from '@backstage/ui';\nimport {\n RiAddLine,\n RiArrowUpLine,\n RiArrowDownLine,\n RiDeleteBinLine,\n RiFileCopyLine,\n} from '@remixicon/react';\n\nexport function SubmitButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ uiSchema }: SubmitButtonProps<T, S, F>) {\n const {\n submitText,\n norender,\n props: submitButtonProps = {},\n } = getSubmitButtonOptions<T, S, F>(uiSchema);\n\n if (norender) {\n return null;\n }\n\n return (\n <Button type=\"submit\" variant=\"primary\" {...submitButtonProps}>\n {submitText}\n </Button>\n );\n}\n\nexport function AddButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ registry, disabled, onClick, className }: IconButtonProps<T, S, F>) {\n const { translateString } = registry;\n\n const handleClick = onClick ? (e: any) => onClick(e) : undefined;\n\n return (\n <Button\n isDisabled={disabled}\n onClick={handleClick}\n className={className}\n variant=\"secondary\"\n size=\"small\"\n iconStart={<RiAddLine />}\n >\n {translateString(TranslatableString.AddItemButton)}\n </Button>\n );\n}\n\nexport function IconButton<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: IconButtonProps<T, S, F>) {\n const { icon, registry, disabled, onClick, className } = props;\n const { translateString } = registry;\n\n let buttonIcon;\n let buttonLabel;\n\n switch (icon) {\n case 'arrow-up':\n buttonIcon = <RiArrowUpLine />;\n buttonLabel = translateString(TranslatableString.MoveUpButton);\n break;\n case 'arrow-down':\n buttonIcon = <RiArrowDownLine />;\n buttonLabel = translateString(TranslatableString.MoveDownButton);\n break;\n case 'remove':\n buttonIcon = <RiDeleteBinLine />;\n buttonLabel = translateString(TranslatableString.RemoveButton);\n break;\n case 'copy':\n buttonIcon = <RiFileCopyLine />;\n buttonLabel = translateString(TranslatableString.CopyButton);\n break;\n default:\n buttonIcon = null;\n buttonLabel = '';\n }\n\n const handleClick = onClick ? () => onClick(undefined as any) : undefined;\n\n return (\n <Button\n isDisabled={disabled}\n onClick={handleClick}\n className={className}\n variant=\"tertiary\"\n size=\"small\"\n iconStart={buttonIcon || undefined}\n >\n {buttonLabel}\n </Button>\n );\n}\n\nconst ButtonTemplates = {\n SubmitButton,\n AddButton,\n RemoveButton: IconButton,\n MoveDownButton: IconButton,\n MoveUpButton: IconButton,\n CopyButton: IconButton,\n};\n\nexport default ButtonTemplates;\n"],"names":[],"mappings":";;;;;AAiCO,SAAS,YAAA,CAId,EAAE,QAAA,EAAS,EAA+B;AAC1C,EAAA,MAAM;AAAA,IACJ,UAAA;AAAA,IACA,QAAA;AAAA,IACA,KAAA,EAAO,oBAAoB;AAAC,GAC9B,GAAI,uBAAgC,QAAQ,CAAA;AAE5C,EAAA,IAAI,QAAA,EAAU;AACZ,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,uBACE,GAAA,CAAC,UAAO,IAAA,EAAK,QAAA,EAAS,SAAQ,SAAA,EAAW,GAAG,mBACzC,QAAA,EAAA,UAAA,EACH,CAAA;AAEJ;AAEO,SAAS,UAId,EAAE,QAAA,EAAU,QAAA,EAAU,OAAA,EAAS,WAAU,EAA6B;AACtE,EAAA,MAAM,EAAE,iBAAgB,GAAI,QAAA;AAE5B,EAAA,MAAM,cAAc,OAAA,GAAU,CAAC,CAAA,KAAW,OAAA,CAAQ,CAAC,CAAA,GAAI,MAAA;AAEvD,EAAA,uBACE,GAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,UAAA,EAAY,QAAA;AAAA,MACZ,OAAA,EAAS,WAAA;AAAA,MACT,SAAA;AAAA,MACA,OAAA,EAAQ,WAAA;A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A,EAAS,WAAA;AAAA,MACT,SAAA;AAAA,MACA,OAAA,EAAQ,UAAA;AAAA,MACR,IAAA,EAAK,OAAA;AAAA,MACL,WAAW,UAAA,IAAc,MAAA;AAAA,MAExB,QAAA,EAAA;AAAA;AAAA,GACH;AAEJ;AAEA,MAAM,eAAA,GAAkB;AAAA,EACtB,YAAA;AAAA,EACA,SAAA;AAAA,EACA,YAAA,EAAc,UAAA;AAAA,EACd,cAAA,EAAgB,UAAA;AAAA,EAChB,YAAA,EAAc,UAAA;AAAA,EACd,UAAA,EAAY;AACd;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DescriptionFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/DescriptionFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { isValidElement } from 'react';\nimport {\n DescriptionFieldProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { MarkdownContent } from '@backstage/core-components';\n\nexport default function DescriptionFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, description }: DescriptionFieldProps<T, S, F>) {\n if (!description) {\n return null;\n }\n\n return (\n <div id={id}>\n {isValidElement(description) ? (\n description\n ) : (\n <MarkdownContent\n content={description as string}\n linkTarget=\"_blank\"\n />\n )}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,wBAAA,CAItB,EAAE,EAAA,EAAI,WAAA,EAAY,EAAmC;AACrD,EAAA,IAAI,CAAC,WAAA,EAAa;AAChB,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EACF,QAAA,EAAA,cAAA,CAAe,WAAW,IACzB,WAAA,mBAEA,GAAA;AAAA,IAAC,eAAA;AAAA,IAAA;AAAA,MACC,OAAA,EAAS,WAAA;AAAA,MACT,UAAA,EAAW;AAAA;AAAA,GACb,EAEJ,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"DescriptionFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/DescriptionFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { isValidElement } from 'react';\nimport {\n DescriptionFieldProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { MarkdownContent } from '@backstage/core-components';\n\nexport default function DescriptionFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, description }: DescriptionFieldProps<T, S, F>) {\n if (!description) {\n return null;\n }\n\n return (\n <div id={id}>\n {isValidElement(description) ? (\n description\n ) : (\n <MarkdownContent\n content={description as string}\n linkTarget=\"_blank\"\n />\n )}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,wBAAA,CAItB,EAAE,EAAA,EAAI,WAAA,EAAY,EAAmC;AACrD,EAAA,IAAI,CAAC,WAAA,EAAa;AAChB,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EACF,QAAA,EAAA,cAAA,CAAe,WAAW,IACzB,WAAA,mBAEA,GAAA;AAAA,IAAC,eAAA;AAAA,IAAA;AAAA,MACC,OAAA,EAAS,WAAA;AAAA,MACT,UAAA,EAAW;AAAA;AAAA,GACb,EAEJ,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorListTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ErrorListTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ErrorListProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n TranslatableString,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function ErrorListTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ errors, registry }: ErrorListProps<T, S, F>) {\n const { translateString } = registry;\n\n if (errors.length === 0) {\n return null;\n }\n\n return (\n <Box\n p=\"4\"\n mb=\"8\"\n style={{\n backgroundColor: 'var(--bui-bg-danger)',\n border: '1px solid var(--bui-border-danger)',\n borderRadius: 'var(--bui-radius-2)',\n }}\n >\n <Text as=\"h4\" variant=\"title-small\" weight=\"bold\" color=\"danger\">\n {translateString(TranslatableString.ErrorsLabel)}\n </Text>\n <Box mt=\"2\" pl=\"8\">\n {errors.map((error, i) => (\n <Box\n key={i}\n style={{\n display: 'list-item',\n listStyleType: 'disc',\n marginLeft: '20px',\n }}\n >\n <Text variant=\"body-small\" color=\"danger\">\n {error.stack}\n </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esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ErrorListTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ErrorListProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n TranslatableString,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function ErrorListTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ errors, registry }: ErrorListProps<T, S, F>) {\n const { translateString } = registry;\n\n if (errors.length === 0) {\n return null;\n }\n\n return (\n <Box\n p=\"4\"\n mb=\"8\"\n style={{\n backgroundColor: 'var(--bui-bg-danger)',\n border: '1px solid var(--bui-border-danger)',\n borderRadius: 'var(--bui-radius-2)',\n }}\n >\n <Text as=\"h4\" variant=\"title-small\" weight=\"bold\" color=\"danger\">\n {translateString(TranslatableString.ErrorsLabel)}\n </Text>\n <Box mt=\"2\" pl=\"8\">\n {errors.map((error, i) => (\n <Box\n key={i}\n style={{\n display: 'list-item',\n listStyleType: 'disc',\n marginLeft: '20px',\n }}\n >\n <Text variant=\"body-small\" color=\"danger\">\n {error.stack}\n </Text>\n </Box>\n ))}\n </Box>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,iBAAA,CAItB,EAAE,MAAA,EAAQ,QAAA,EAAS,EAA4B;AAC/C,EAAA,MAAM,EAAE,iBAAgB,GAAI,QAAA;AAE5B,EAAA,IAAI,MAAA,CAAO,WAAW,CAAA,EAAG;AACvB,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,uBACE,IAAA;AAAA,IAAC,GAAA;AAAA,IAAA;AAAA,MACC,CAAA,EAAE,GAAA;AAAA,MACF,EAAA,EAAG,GAAA;AAAA,MACH,KAAA,EAAO;AAAA,QACL,eAAA,EAAiB,sBAAA;AAAA,QACjB,MAAA,EAAQ,oCAAA;AAAA,QACR,YAAA,EAAc;AAAA,OAChB;AAAA,MAEA,QAAA,EAAA;AAAA,wBAAA,GAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAG,IAAA,EAAK,OAAA,EAAQ,aAAA,EAAc,MAAA,EAAO,MAAA,EAAO,KAAA,EAAM,QAAA,EACrD,QAAA,EAAA,eAAA,CAAgB,kBAAA,CAAmB,WAAW,CAAA,EACjD,CAAA;AAAA,wBACA,GAAA,CAAC,GAAA,EAAA,EAAI,EAAA,EAAG,GAAA,EAAI,EAAA,EAAG,KACZ,QAAA,EAAA,MAAA,CAAO,GAAA,CAAI,CAAC,KAAA,EAAO,CAAA,qBAClB,GAAA;AAAA,UAAC,GAAA;AAAA,UAAA;AAAA,YAEC,KAAA,EAAO;AAAA,cACL,OAAA,EAAS,WAAA;AAAA,cACT,aAAA,EAAe,MAAA;AAAA,cACf,UAAA,EAAY;AAAA,aACd;AAAA,YAEA,8BAAC,IAAA,EAAA,EAAK,OAAA,EAAQ,cAAa,KAAA,EAAM,QAAA,EAC9B,gBAAM,KAAA,EACT;AAAA,WAAA;AAAA,UATK;AAAA,SAWR,CAAA,EACH;AAAA;AAAA;AAAA,GACF;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldErrorTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldErrorTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n errorId,\n FieldErrorProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function FieldErrorTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ errors = [], idSchema }: FieldErrorProps<T, S, F>) {\n if (errors.length === 0) {\n return null;\n }\n\n const id = errorId<T>(idSchema);\n\n return (\n <div id={id}>\n {errors.map((error, i) => (\n <Text key={i} as=\"div\" variant=\"body-small\" color=\"danger\">\n {error}\n </Text>\n ))}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,mBAItB,EAAE,MAAA,GAAS,EAAC,EAAG,UAAS,EAA6B;AACrD,EAAA,IAAI,MAAA,CAAO,WAAW,CAAA,EAAG;AACvB,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,QAAW,QAAQ,CAAA;AAE9B,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EACF,iBAAO,GAAA,CAAI,CAAC,OAAO,CAAA,qBAClB,GAAA,CAAC,QAAa,EAAA,EAAG,KAAA,EAAM,SAAQ,YAAA,EAAa,KAAA,EAAM,UAC/C,QAAA,EAAA,KAAA,EAAA,EADQ,CAEX,CACD,CAAA,EACH,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"FieldErrorTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldErrorTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n errorId,\n FieldErrorProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function FieldErrorTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ errors = [], idSchema }: FieldErrorProps<T, S, F>) {\n if (errors.length === 0) {\n return null;\n }\n\n const id = errorId<T>(idSchema);\n\n return (\n <div id={id}>\n {errors.map((error, i) => (\n <Text key={i} as=\"div\" variant=\"body-small\" color=\"danger\">\n {error}\n </Text>\n ))}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,mBAItB,EAAE,MAAA,GAAS,EAAC,EAAG,UAAS,EAA6B;AACrD,EAAA,IAAI,MAAA,CAAO,WAAW,CAAA,EAAG;AACvB,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,QAAW,QAAQ,CAAA;AAE9B,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EACF,iBAAO,GAAA,CAAI,CAAC,OAAO,CAAA,qBAClB,GAAA,CAAC,QAAa,EAAA,EAAG,KAAA,EAAM,SAAQ,YAAA,EAAa,KAAA,EAAM,UAC/C,QAAA,EAAA,KAAA,EAAA,EADQ,CAEX,CACD,CAAA,EACH,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldHelpTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldHelpTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { isValidElement } from 'react';\nimport {\n FieldHelpProps,\n FormContextType,\n helpId,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function FieldHelpTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ idSchema, help }: FieldHelpProps<T, S, F>) {\n if (!help) {\n return null;\n }\n\n const id = helpId<T>(idSchema);\n\n return (\n <div id={id} style={{ marginTop: 'var(--bui-space-1)' }}>\n {isValidElement(help) ? (\n help\n ) : (\n <Text variant=\"body-small\" color=\"secondary\">\n {help}\n </Text>\n )}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;;AAyBA,SAAwB,iBAAA,CAItB,EAAE,QAAA,EAAU,IAAA,EAAK,EAA4B;AAC7C,EAAA,IAAI,CAAC,IAAA,EAAM;AACT,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,OAAU,QAAQ,CAAA;AAE7B,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EAAQ,OAAO,EAAE,SAAA,EAAW,sBAAqB,EACnD,QAAA,EAAA,cAAA,CAAe,IAAI,CAAA,GAClB,IAAA,uBAEC,IAAA,EAAA,EAAK,OAAA,EAAQ,cAAa,KAAA,EAAM,WAAA,EAC9B,gBACH,CAAA,EAEJ,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"FieldHelpTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldHelpTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { isValidElement } from 'react';\nimport {\n FieldHelpProps,\n FormContextType,\n helpId,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Text } from '@backstage/ui';\n\nexport default function FieldHelpTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ idSchema, help }: FieldHelpProps<T, S, F>) {\n if (!help) {\n return null;\n }\n\n const id = helpId<T>(idSchema);\n\n return (\n <div id={id} style={{ marginTop: 'var(--bui-space-1)' }}>\n {isValidElement(help) ? (\n help\n ) : (\n <Text variant=\"body-small\" color=\"secondary\">\n {help}\n </Text>\n )}\n </div>\n );\n}\n"],"names":[],"mappings":";;;;;AAyBA,SAAwB,iBAAA,CAItB,EAAE,QAAA,EAAU,IAAA,EAAK,EAA4B;AAC7C,EAAA,IAAI,CAAC,IAAA,EAAM;AACT,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,EAAA,GAAK,OAAU,QAAQ,CAAA;AAE7B,EAAA,2BACG,KAAA,EAAA,EAAI,EAAA,EAAQ,OAAO,EAAE,SAAA,EAAW,sBAAqB,EACnD,QAAA,EAAA,cAAA,CAAe,IAAI,CAAA,GAClB,IAAA,uBAEC,IAAA,EAAA,EAAK,OAAA,EAAQ,cAAa,KAAA,EAAM,WAAA,EAC9B,gBACH,CAAA,EAEJ,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FieldTemplateProps,\n FormContextType,\n getTemplate,\n getUiOptions,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box } from '@backstage/ui';\nimport { ScaffolderField } from '../../../ScaffolderField';\n\nexport default function FieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: FieldTemplateProps<T, S, F>) {\n const {\n id,\n children,\n classNames,\n style,\n disabled,\n displayLabel,\n hidden,\n label,\n onDropPropertyClick,\n onKeyChange,\n readonly,\n registry,\n required,\n rawErrors = [],\n errors,\n help,\n rawDescription,\n schema,\n uiSchema,\n } = props;\n\n const uiOptions = getUiOptions<T, S, F>(uiSchema);\n const WrapIfAdditionalTemplate = getTemplate<\n 'WrapIfAdditionalTemplate',\n T,\n S,\n F\n >('WrapIfAdditionalTemplate', registry, uiOptions);\n\n if (hidden) {\n return <Box display=\"none\">{children}</Box>;\n }\n\n return (\n <WrapIfAdditionalTemplate\n classNames={classNames}\n style={style}\n disabled={disabled}\n id={id}\n label={label}\n onDropPropertyClick={onDropPropertyClick}\n onKeyChange={onKeyChange}\n readonly={readonly}\n required={required}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n >\n <ScaffolderField\n displayLabel={displayLabel}\n rawErrors={rawErrors}\n help={help}\n disabled={disabled}\n rawDescription={rawDescription}\n errors={errors}\n required={required}\n >\n {children}\n </ScaffolderField>\n </WrapIfAdditionalTemplate>\n );\n}\n"],"names":[],"mappings":";;;;;AA0BA,SAAwB,cAItB,KAAA,EAAoC;AACpC,EAAA,MAAM;AAAA,IACJ,EAAA;AAAA,IACA,QAAA;AAAA,IACA,UAAA;AAAA,IACA,KAAA;AAAA,IACA,QAAA;AAAA,IACA,YAAA;AAAA,IACA,MAAA;AAAA,IACA,KAAA;AAAA,IACA,mBAAA;AAAA,IACA,WAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,YAAY,EAAC;AAAA,IACb,MAAA;AAAA,IACA,IAAA;AAAA,IACA,cAAA;AAAA,IACA,MAAA;AAAA,IACA;AAAA,GACF,GAAI,KAAA;AAEJ,EAAA,MAAM,SAAA,GAAY,aAAsB,QAAQ,CAAA;AAChD,EAAA,MAAM,wBAAA,GAA2B,WAAA,CAK/B,0BAAA,EAA4B,QAAA,EAAU,SAAS,CAAA;AAEjD,EAAA,IAAI,MAAA,EAAQ;AACV,IAAA,uBAAO,GAAA,CAAC,GAAA,EAAA,EAAI,OAAA,EAAQ,MAAA,EAAQ,QAAA,EAAS,CAAA;AAAA,EACvC;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,wBAAA;AAAA,IAAA;AAAA,MACC,UAAA;AAAA,MACA,KAAA;AAAA,MACA,QAAA;AAAA,MACA,EAAA;AAAA,MACA,KAAA;AAAA,MACA,mBAAA;AAAA,MACA,WAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAA;AAAA,MAEA,QAAA,kBAAA,GAAA;AAAA,QAAC,eAAA;AAAA,QAAA;AAAA,UACC,YAAA;AAAA,UACA,SAAA;AAAA,UACA,IAAA;AAAA,UACA,QAAA;AAAA,UACA,cAAA;AAAA,UACA,MAAA;AAAA,UACA,QAAA;AAAA,UAEC;AAAA;AAAA;AACH;AAAA,GACF;AAEJ
|
|
1
|
+
{"version":3,"file":"FieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/FieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FieldTemplateProps,\n FormContextType,\n getTemplate,\n getUiOptions,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box } from '@backstage/ui';\nimport { ScaffolderField } from '../../../ScaffolderField';\n\nexport default function FieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: FieldTemplateProps<T, S, F>) {\n const {\n id,\n children,\n classNames,\n style,\n disabled,\n displayLabel,\n hidden,\n label,\n onDropPropertyClick,\n onKeyChange,\n readonly,\n registry,\n required,\n rawErrors = [],\n errors,\n help,\n rawDescription,\n schema,\n uiSchema,\n } = props;\n\n const uiOptions = getUiOptions<T, S, F>(uiSchema);\n const WrapIfAdditionalTemplate = getTemplate<\n 'WrapIfAdditionalTemplate',\n T,\n S,\n F\n >('WrapIfAdditionalTemplate', registry, uiOptions);\n\n if (hidden) {\n return <Box display=\"none\">{children}</Box>;\n }\n\n return (\n <WrapIfAdditionalTemplate\n classNames={classNames}\n style={style}\n disabled={disabled}\n id={id}\n label={label}\n onDropPropertyClick={onDropPropertyClick}\n onKeyChange={onKeyChange}\n readonly={readonly}\n required={required}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n >\n <ScaffolderField\n displayLabel={displayLabel}\n rawErrors={rawErrors}\n help={help}\n disabled={disabled}\n rawDescription={rawDescription}\n errors={errors}\n required={required}\n >\n {children}\n </ScaffolderField>\n </WrapIfAdditionalTemplate>\n );\n}\n"],"names":[],"mappings":";;;;;AA0BA,SAAwB,cAItB,KAAA,EAAoC;AACpC,EAAA,MAAM;AAAA,IACJ,EAAA;AAAA,IACA,QAAA;AAAA,IACA,UAAA;AAAA,IACA,KAAA;AAAA,IACA,QAAA;AAAA,IACA,YAAA;AAAA,IACA,MAAA;AAAA,IACA,KAAA;AAAA,IACA,mBAAA;AAAA,IACA,WAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,YAAY,EAAC;AAAA,IACb,MAAA;AAAA,IACA,IAAA;AAAA,IACA,cAAA;AAAA,IACA,MAAA;AAAA,IACA;AAAA,GACF,GAAI,KAAA;AAEJ,EAAA,MAAM,SAAA,GAAY,aAAsB,QAAQ,CAAA;AAChD,EAAA,MAAM,wBAAA,GAA2B,WAAA,CAK/B,0BAAA,EAA4B,QAAA,EAAU,SAAS,CAAA;AAEjD,EAAA,IAAI,MAAA,EAAQ;AACV,IAAA,uBAAO,GAAA,CAAC,GAAA,EAAA,EAAI,OAAA,EAAQ,MAAA,EAAQ,QAAA,EAAS,CAAA;AAAA,EACvC;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,wBAAA;AAAA,IAAA;AAAA,MACC,UAAA;AAAA,MACA,KAAA;AAAA,MACA,QAAA;AAAA,MACA,EAAA;AAAA,MACA,KAAA;AAAA,MACA,mBAAA;AAAA,MACA,WAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAA;AAAA,MAEA,QAAA,kBAAA,GAAA;AAAA,QAAC,eAAA;AAAA,QAAA;AAAA,UACC,YAAA;AAAA,UACA,SAAA;AAAA,UACA,IAAA;AAAA,UACA,QAAA;AAAA,UACA,cAAA;AAAA,UACA,MAAA;AAAA,UACA,QAAA;AAAA,UAEC;AAAA;AAAA;AACH;AAAA,GACF;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ObjectFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ObjectFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n canExpand,\n FormContextType,\n getTemplate,\n getUiOptions,\n ObjectFieldTemplateProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box } from '@backstage/ui';\n\nexport default function ObjectFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n description,\n title,\n properties,\n required,\n disabled,\n readonly,\n uiSchema,\n idSchema,\n schema,\n formData,\n onAddClick,\n registry,\n}: ObjectFieldTemplateProps<T, S, F>) {\n const uiOptions = getUiOptions<T, S, F>(uiSchema);\n const TitleFieldTemplate = getTemplate<'TitleFieldTemplate', T, S, F>(\n 'TitleFieldTemplate',\n registry,\n uiOptions,\n );\n const DescriptionFieldTemplate = getTemplate<\n 'DescriptionFieldTemplate',\n T,\n S,\n F\n >('DescriptionFieldTemplate', registry, uiOptions);\n const {\n ButtonTemplates: { AddButton },\n } = registry.templates;\n\n const isNested =\n idSchema.$id !== 'root' &&\n (idSchema.$id.includes('.') || idSchema.$id.includes('_'));\n\n const isRoot = idSchema.$id === 'root';\n const hasTitle = !isRoot && (uiOptions.title || title);\n const hasDescription = !isRoot && (uiOptions.description || description);\n\n const isAutoGeneratedTitle = title && /^.+-\\d+$/.test(title);\n\n if (isNested || isAutoGeneratedTitle) {\n return (\n <Box>\n {properties.map(element => element.content)}\n {canExpand<T, S, F>(schema, uiSchema, formData) && (\n <Box mt=\"3\">\n <AddButton\n onClick={onAddClick(schema)}\n disabled={disabled || readonly}\n className=\"object-property-expand\"\n uiSchema={uiSchema}\n registry={registry}\n />\n </Box>\n )}\n </Box>\n );\n }\n\n return (\n <Box>\n {hasTitle && (\n <TitleFieldTemplate\n id={`${idSchema.$id}__title`}\n title={(title || uiOptions.title) as string}\n required={required}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n />\n )}\n {hasDescription && (\n <DescriptionFieldTemplate\n id={`${idSchema.$id}__description`}\n description={uiOptions.description || description!}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n />\n )}\n {properties.map(element => element.content)}\n {canExpand<T, S, F>(schema, uiSchema, formData) && (\n <Box mt=\"3\">\n <AddButton\n onClick={onAddClick(schema)}\n disabled={disabled || readonly}\n className=\"object-property-expand\"\n uiSchema={uiSchema}\n registry={registry}\n />\n </Box>\n )}\n </Box>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,mBAAA,CAItB;AAAA,EACA,WAAA;AAAA,EACA,KAAA;AAAA,EACA,UAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,MAAA;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA;AACF,CAAA,EAAsC;AACpC,EAAA,MAAM,SAAA,GAAY,aAAsB,QAAQ,CAAA;AAChD,EAAA,MAAM,kBAAA,GAAqB,WAAA;AAAA,IACzB,oBAAA;AAAA,IACA,QAAA;AAAA,IACA;AAAA,GACF;AACA,EAAA,MAAM,wBAAA,GAA2B,WAAA,CAK/B,0BAAA,EAA4B,QAAA,EAAU,SAAS,CAAA;AACjD,EAAA,MAAM;AAAA,IACJ,eAAA,EAAiB,EAAE,SAAA;AAAU,MAC3B,QAAA,CAAS,SAAA;AAEb,EAAA,MAAM,QAAA,GACJ,QAAA,CAAS,GAAA,KAAQ,MAAA,KAChB,QAAA,CAAS,GAAA,CAAI,QAAA,CAAS,GAAG,CAAA,IAAK,QAAA,CAAS,GAAA,CAAI,QAAA,CAAS,GAAG,CAAA,CAAA;AAE1D,EAAA,MAAM,MAAA,GAAS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CAAA;AAAA,QACnB,WAAA,EAAa,UAAU,WAAA,IAAe,WAAA;AAAA,QACtC,MAAA;AAAA,QACA,QAAA;AAAA,QACA;AAAA;AAAA,KACF;AAAA,IAED,UAAA,CAAW,GAAA,CAAI,CAAA,OAAA,KAAW,OAAA,CAAQ,OAAO,CAAA;AAAA,IACzC,SAAA,CAAmB,QAAQ,QAAA,EAAU,QAAQ,qBAC5C,GAAA,CAAC,GAAA,EAAA,EAAI,IAAG,GAAA,EACN,QAAA,kBAAA,GAAA;AAAA,MAAC,SAAA;AAAA,MAAA;AAAA,QACC,OAAA,EAAS,WAAW,MAAM,CAAA;AAAA,QAC1B,UAAU,QAAA,IAAY,QAAA;AAAA,QACtB,SAAA,EAAU,wBAAA;AAAA,QACV,QAAA;AAAA,QACA;AAAA;AAAA,KACF,EACF;AAAA,GAAA,EAEJ,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"ObjectFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/ObjectFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n canExpand,\n FormContextType,\n getTemplate,\n getUiOptions,\n ObjectFieldTemplateProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box } from '@backstage/ui';\n\nexport default function ObjectFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n description,\n title,\n properties,\n required,\n disabled,\n readonly,\n uiSchema,\n idSchema,\n schema,\n formData,\n onAddClick,\n registry,\n}: ObjectFieldTemplateProps<T, S, F>) {\n const uiOptions = getUiOptions<T, S, F>(uiSchema);\n const TitleFieldTemplate = getTemplate<'TitleFieldTemplate', T, S, F>(\n 'TitleFieldTemplate',\n registry,\n uiOptions,\n );\n const DescriptionFieldTemplate = getTemplate<\n 'DescriptionFieldTemplate',\n T,\n S,\n F\n >('DescriptionFieldTemplate', registry, uiOptions);\n const {\n ButtonTemplates: { AddButton },\n } = registry.templates;\n\n const isNested =\n idSchema.$id !== 'root' &&\n (idSchema.$id.includes('.') || idSchema.$id.includes('_'));\n\n const isRoot = idSchema.$id === 'root';\n const hasTitle = !isRoot && (uiOptions.title || title);\n const hasDescription = !isRoot && (uiOptions.description || description);\n\n const isAutoGeneratedTitle = title && /^.+-\\d+$/.test(title);\n\n if (isNested || isAutoGeneratedTitle) {\n return (\n <Box>\n {properties.map(element => element.content)}\n {canExpand<T, S, F>(schema, uiSchema, formData) && (\n <Box mt=\"3\">\n <AddButton\n onClick={onAddClick(schema)}\n disabled={disabled || readonly}\n className=\"object-property-expand\"\n uiSchema={uiSchema}\n registry={registry}\n />\n </Box>\n )}\n </Box>\n );\n }\n\n return (\n <Box>\n {hasTitle && (\n <TitleFieldTemplate\n id={`${idSchema.$id}__title`}\n title={(title || uiOptions.title) as string}\n required={required}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n />\n )}\n {hasDescription && (\n <DescriptionFieldTemplate\n id={`${idSchema.$id}__description`}\n description={uiOptions.description || description!}\n schema={schema}\n uiSchema={uiSchema}\n registry={registry}\n />\n )}\n {properties.map(element => element.content)}\n {canExpand<T, S, F>(schema, uiSchema, formData) && (\n <Box mt=\"3\">\n <AddButton\n onClick={onAddClick(schema)}\n disabled={disabled || readonly}\n className=\"object-property-expand\"\n uiSchema={uiSchema}\n registry={registry}\n />\n </Box>\n )}\n </Box>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,mBAAA,CAItB;AAAA,EACA,WAAA;AAAA,EACA,KAAA;AAAA,E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AEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TitleFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/TitleFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n TitleFieldProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function TitleFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, title, required }: TitleFieldProps<T, S, F>) {\n return (\n <Box mb=\"3\">\n <Text id={id} as=\"h3\" variant=\"title-small\" weight=\"bold\">\n {title}\n {required && (\n <Text as=\"span\" color=\"danger\">\n {' '}\n *\n </Text>\n )}\n </Text>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,kBAAA,CAItB,EAAE,EAAA,EAAI,KAAA,EAAO,UAAS,EAA6B;AACnD,EAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,EAAA,EAAG,GAAA,EACN,QAAA,kBAAA,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAQ,EAAA,EAAG,IAAA,EAAK,OAAA,EAAQ,aAAA,EAAc,MAAA,EAAO,MAAA,EAChD,QAAA,EAAA;AAAA,IAAA,KAAA;AAAA,IACA,4BACC,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAG,MAAA,EAAO,OAAM,QAAA,EACnB,QAAA,EAAA;AAAA,MAAA,GAAA;AAAA,MAAI;AAAA,KAAA,EAEP;AAAA,GAAA,EAEJ,CAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"TitleFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/TitleFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n TitleFieldProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function TitleFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, title, required }: TitleFieldProps<T, S, F>) {\n return (\n <Box mb=\"3\">\n <Text id={id} as=\"h3\" variant=\"title-small\" weight=\"bold\">\n {title}\n {required && (\n <Text as=\"span\" color=\"danger\">\n {' '}\n *\n </Text>\n )}\n </Text>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,kBAAA,CAItB,EAAE,EAAA,EAAI,KAAA,EAAO,UAAS,EAA6B;AACnD,EAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,EAAA,EAAG,GAAA,EACN,QAAA,kBAAA,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAQ,EAAA,EAAG,IAAA,EAAK,OAAA,EAAQ,aAAA,EAAc,MAAA,EAAO,MAAA,EAChD,QAAA,EAAA;AAAA,IAAA,KAAA;AAAA,IACA,4BACC,IAAA,CAAC,IAAA,EAAA,EAAK,EAAA,EAAG,MAAA,EAAO,OAAM,QAAA,EACnB,QAAA,EAAA;AAAA,MAAA,GAAA;AAAA,MAAI;AAAA,KAAA,EAEP;AAAA,GAAA,EAEJ,CAAA,EACF,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UnsupportedFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/UnsupportedFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n UnsupportedFieldProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function UnsupportedFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: UnsupportedFieldProps<T, S, F>) {\n const { schema, reason } = props;\n return (\n <Box p=\"3\" style={{ backgroundColor: 'var(--bui-bg-neutral-3)' }}>\n <Text variant=\"body-small\" color=\"danger\">\n Unsupported field schema\n {schema && schema.type && ` for type: ${JSON.stringify(schema.type)}`}\n {reason && `: ${reason}`}\n </Text>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,yBAItB,KAAA,EAAuC;AACvC,EAAA,MAAM,EAAE,MAAA,EAAQ,MAAA,EAAO,GAAI,KAAA;AAC3B,EAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,CAAA,EAAE,GAAA,EAAI,OAAO,EAAE,eAAA,EAAiB,yBAAA,EAA0B,EAC7D,QAAA,kBAAA,IAAA,CAAC,IAAA,EAAA,EAAK,OAAA,EAAQ,YAAA,EAAa,OAAM,QAAA,EAAS,QAAA,EAAA;AAAA,IAAA,0BAAA;AAAA,IAEvC,MAAA,IAAU,OAAO,IAAA,IAAQ,CAAA,WAAA,EAAc,KAAK,SAAA,CAAU,MAAA,CAAO,IAAI,CAAC,CAAA,CAAA;AAAA,IAClE,MAAA,IAAU,KAAK,MAAM,CAAA;AAAA,GAAA,EACxB,CAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"UnsupportedFieldTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/UnsupportedFieldTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n UnsupportedFieldProps,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { Box, Text } from '@backstage/ui';\n\nexport default function UnsupportedFieldTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: UnsupportedFieldProps<T, S, F>) {\n const { schema, reason } = props;\n return (\n <Box p=\"3\" style={{ backgroundColor: 'var(--bui-bg-neutral-3)' }}>\n <Text variant=\"body-small\" color=\"danger\">\n Unsupported field schema\n {schema && schema.type && ` for type: ${JSON.stringify(schema.type)}`}\n {reason && `: ${reason}`}\n </Text>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,yBAItB,KAAA,EAAuC;AACvC,EAAA,MAAM,EAAE,MAAA,EAAQ,MAAA,EAAO,GAAI,KAAA;AAC3B,EAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,CAAA,EAAE,GAAA,EAAI,OAAO,EAAE,eAAA,EAAiB,yBAAA,EAA0B,EAC7D,QAAA,kBAAA,IAAA,CAAC,IAAA,EAAA,EAAK,OAAA,EAAQ,YAAA,EAAa,OAAM,QAAA,EAAS,QAAA,EAAA;AAAA,IAAA,0BAAA;AAAA,IAEvC,MAAA,IAAU,OAAO,IAAA,IAAQ,CAAA,WAAA,EAAc,KAAK,SAAA,CAAU,MAAA,CAAO,IAAI,CAAC,CAAA,CAAA;AAAA,IAClE,MAAA,IAAU,KAAK,MAAM,CAAA;AAAA,GAAA,EACxB,CAAA,EACF,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WrapIfAdditionalTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/WrapIfAdditionalTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ADDITIONAL_PROPERTY_FLAG,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WrapIfAdditionalTemplateProps,\n} from '@rjsf/utils';\nimport { Button, Flex, Box, TextField } from '@backstage/ui';\nimport { RiDeleteBinLine } from '@remixicon/react';\n\nexport default function WrapIfAdditionalTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n children,\n classNames,\n style,\n disabled,\n id,\n label,\n onDropPropertyClick,\n onKeyChange,\n readonly,\n required,\n schema,\n}: WrapIfAdditionalTemplateProps<T, S, F>) {\n const keyLabel = `${label} Key`;\n const additional = ADDITIONAL_PROPERTY_FLAG in schema;\n\n if (!additional) {\n return (\n <Box className={classNames} style={style}>\n {children}\n </Box>\n );\n }\n\n const handleChange = (value: string) => {\n onKeyChange(value);\n };\n\n return (\n <Box className={classNames} style={style}>\n <Flex align=\"start\" gap=\"4\">\n <Box style={{ flex: 1 }}>\n <Box mb=\"4\">\n <TextField\n id={`${id}-key`}\n label={keyLabel}\n secondaryLabel={required ? 'Required' : undefined}\n defaultValue={label}\n isDisabled={disabled || readonly}\n onChange={handleChange}\n />\n </Box>\n {children}\n </Box>\n <Button\n variant=\"tertiary\"\n size=\"small\"\n isDisabled={disabled || readonly}\n onClick={onDropPropertyClick(label)}\n iconStart={<RiDeleteBinLine />}\n aria-label=\"Remove\"\n />\n </Flex>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;;;AAyBA,SAAwB,wBAAA,CAItB;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,mBAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF,CAAA,EAA2C;AACzC,EAAA,MAAM,QAAA,GAAW,GAAG,KAAK,CAAA,IAAA,CAAA;AACzB,EAAA,MAAM,aAAa,wBAAA,IAA4B,MAAA;AAE/C,EAAA,IAAI,CAAC,UAAA,EAAY;AACf,IAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,SAAA,EAAW,UAAA,EAAY,OACzB,QAAA,EACH,CAAA;AAAA,EAEJ;AAEA,EAAA,MAAM,YAAA,GAAe,CAAC,KAAA,KAAkB;AACtC,IAAA,WAAA,CAAY,KAAK,CAAA;AAAA,EACnB,CAAA;AAEA,EAAA,uBACE,GAAA,CAAC,GAAA,EAAA,EAAI,SAAA,EAAW,UAAA,EAAY,KAAA,EAC1B,+BAAC,IAAA,EAAA,EAAK,KAAA,EAAM,OAAA,EAAQ,GAAA,EAAI,GAAA,EACtB,QAAA,EAAA;AAAA,oBAAA,IAAA,CAAC,GAAA,EAAA,EAAI,KAAA,EAAO,EAAE,IAAA,EAAM,GAAE,EACpB,QAAA,EAAA;AAAA,sBAAA,GAAA,CAAC,GAAA,EAAA,EAAI,IAAG,GAAA,EACN,QAAA,kBAAA,GAAA;AAAA,QAAC,SAAA;AAAA,QAAA;AAAA,UACC,EAAA,EAAI,GAAG,EAAE,CAAA,IAAA,CAAA;AAAA,UACT,KAAA,EAAO,QAAA;AAAA,UACP,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,UACxC,YAAA,EAAc,KAAA;AAAA,UACd,YAAY,QAAA,IAAY,QAAA;AAAA,UACxB,QAAA,EAAU;AAAA;AAAA,OACZ,EACF,CAAA;AAAA,MACC;AAAA,KAAA,EACH,CAAA;AAAA,oBACA,GAAA;AAAA,MAAC,MAAA;AAAA,MAAA;AAAA,QACC,OAAA,EAAQ,UAAA;AAAA,QACR,IAAA,EAAK,OAAA;AAAA,QACL,YAAY,QAAA,IAAY,QAAA;AAAA,QACxB,OAAA,EAAS,oBAAoB,KAAK,CAAA;AAAA,QAClC,SAAA,sBAAY,eAAA,EAAA,EAAgB,CAAA;AAAA,QAC5B,YAAA,EAAW;AAAA;AAAA;AACb,GAAA,EACF,CAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"WrapIfAdditionalTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/WrapIfAdditionalTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ADDITIONAL_PROPERTY_FLAG,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WrapIfAdditionalTemplateProps,\n} from '@rjsf/utils';\nimport { Button, Flex, Box, TextField } from '@backstage/ui';\nimport { RiDeleteBinLine } from '@remixicon/react';\n\nexport default function WrapIfAdditionalTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n children,\n classNames,\n style,\n disabled,\n id,\n label,\n onDropPropertyClick,\n onKeyChange,\n readonly,\n required,\n schema,\n}: WrapIfAdditionalTemplateProps<T, S, F>) {\n const keyLabel = `${label} Key`;\n const additional = ADDITIONAL_PROPERTY_FLAG in schema;\n\n if (!additional) {\n return (\n <Box className={classNames} style={style}>\n {children}\n </Box>\n );\n }\n\n const handleChange = (value: string) => {\n onKeyChange(value);\n };\n\n return (\n <Box className={classNames} style={style}>\n <Flex align=\"start\" gap=\"4\">\n <Box style={{ flex: 1 }}>\n <Box mb=\"4\">\n <TextField\n id={`${id}-key`}\n label={keyLabel}\n secondaryLabel={required ? 'Required' : undefined}\n defaultValue={label}\n isDisabled={disabled || readonly}\n onChange={handleChange}\n />\n </Box>\n {children}\n </Box>\n <Button\n variant=\"tertiary\"\n size=\"small\"\n isDisabled={disabled || readonly}\n onClick={onDropPropertyClick(label)}\n iconStart={<RiDeleteBinLine />}\n aria-label=\"Remove\"\n />\n </Flex>\n </Box>\n );\n}\n"],"names":[],"mappings":";;;;;AAyBA,SAAwB,wBAAA,CAItB;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,mBAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF,CAAA,EAA2C;AACzC,EAAA,MAAM,QAAA,GAAW,GAAG,KAAK,CAAA,IAAA,CAAA;AACzB,EAAA,MAAM,aAAa,wBAAA,IAA4B,MAAA;AAE/C,EAAA,IAAI,CAA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
|
-
{"version":3,"file":"index.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/index.ts"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n TemplatesType,\n} from '@rjsf/utils';\n\nimport ArrayFieldDescriptionTemplate from './ArrayFieldDescriptionTemplate';\nimport ArrayFieldItemTemplate from './ArrayFieldItemTemplate';\nimport ArrayFieldTemplate from './ArrayFieldTemplate';\nimport ArrayFieldTitleTemplate from './ArrayFieldTitleTemplate';\nimport ButtonTemplates, {\n SubmitButton,\n AddButton,\n IconButton,\n} from './ButtonTemplates';\nimport DescriptionFieldTemplate from './DescriptionFieldTemplate';\nimport ErrorListTemplate from './ErrorListTemplate';\nimport FieldErrorTemplate from './FieldErrorTemplate';\nimport FieldHelpTemplate from './FieldHelpTemplate';\nimport FieldTemplate from './FieldTemplate';\nimport ObjectFieldTemplate from './ObjectFieldTemplate';\nimport TitleFieldTemplate from './TitleFieldTemplate';\nimport UnsupportedFieldTemplate from './UnsupportedFieldTemplate';\nimport WrapIfAdditionalTemplate from './WrapIfAdditionalTemplate';\n\nexport function generateBuiTemplates<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(): Partial<TemplatesType<T, S, F>> {\n return {\n ArrayFieldDescriptionTemplate,\n ArrayFieldItemTemplate,\n ArrayFieldTemplate,\n ArrayFieldTitleTemplate,\n ButtonTemplates: {\n ...ButtonTemplates,\n SubmitButton,\n AddButton,\n RemoveButton: IconButton,\n MoveDownButton: IconButton,\n MoveUpButton: IconButton,\n CopyButton: IconButton,\n },\n DescriptionFieldTemplate,\n ErrorListTemplate,\n FieldErrorTemplate,\n FieldHelpTemplate,\n FieldTemplate,\n ObjectFieldTemplate,\n TitleFieldTemplate,\n UnsupportedFieldTemplate,\n WrapIfAdditionalTemplate,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AAyCO,SAAS,oBAAA,GAIqB;AACnC,EAAA,OAAO;AAAA,IACL,6BAAA;AAAA,IACA,sBAAA;AAAA,IACA,kBAAA;AAAA,IACA,uBAAA;AAAA,IACA,eAAA,EAAiB;AAAA,MACf,GAAG,eAAA;AAAA,MACH,YAAA;AAAA,MACA,SAAA;AAAA,MACA,YAAA,EAAc,UAAA;AAAA,MACd,cAAA,EAAgB,UAAA;AAAA,MAChB,YAAA,EAAc,UAAA;AAAA,MACd,UAAA,EAAY;AAAA,KACd;AAAA,IACA,wBAAA;AAAA,IACA,iBAAA;AAAA,IACA,kBAAA;AAAA,IACA,iBAAA;AAAA,IACA,aAAA;AAAA,IACA,mBAAA;AAAA,IACA,kBAAA;AAAA,IACA,wBAAA;AAAA,IACA;AAAA,GACF;AACF
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/templates/index.ts"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n TemplatesType,\n} from '@rjsf/utils';\n\nimport ArrayFieldDescriptionTemplate from './ArrayFieldDescriptionTemplate';\nimport ArrayFieldItemTemplate from './ArrayFieldItemTemplate';\nimport ArrayFieldTemplate from './ArrayFieldTemplate';\nimport ArrayFieldTitleTemplate from './ArrayFieldTitleTemplate';\nimport ButtonTemplates, {\n SubmitButton,\n AddButton,\n IconButton,\n} from './ButtonTemplates';\nimport DescriptionFieldTemplate from './DescriptionFieldTemplate';\nimport ErrorListTemplate from './ErrorListTemplate';\nimport FieldErrorTemplate from './FieldErrorTemplate';\nimport FieldHelpTemplate from './FieldHelpTemplate';\nimport FieldTemplate from './FieldTemplate';\nimport ObjectFieldTemplate from './ObjectFieldTemplate';\nimport TitleFieldTemplate from './TitleFieldTemplate';\nimport UnsupportedFieldTemplate from './UnsupportedFieldTemplate';\nimport WrapIfAdditionalTemplate from './WrapIfAdditionalTemplate';\n\nexport function generateBuiTemplates<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(): Partial<TemplatesType<T, S, F>> {\n return {\n ArrayFieldDescriptionTemplate,\n ArrayFieldItemTemplate,\n ArrayFieldTemplate,\n ArrayFieldTitleTemplate,\n ButtonTemplates: {\n ...ButtonTemplates,\n SubmitButton,\n AddButton,\n RemoveButton: IconButton,\n MoveDownButton: IconButton,\n MoveUpButton: IconButton,\n CopyButton: IconButton,\n },\n DescriptionFieldTemplate,\n ErrorListTemplate,\n FieldErrorTemplate,\n FieldHelpTemplate,\n FieldTemplate,\n ObjectFieldTemplate,\n TitleFieldTemplate,\n UnsupportedFieldTemplate,\n WrapIfAdditionalTemplate,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AAyCO,SAAS,oBAAA,GAIqB;AACnC,EAAA,OAAO;AAAA,IACL,6BAAA;AAAA,IACA,sBAAA;AAAA,IACA,kBAAA;AAAA,IACA,uBAAA;AAAA,IACA,eAAA,EAAiB;AAAA,MACf,GAAG,eAAA;AAAA,MACH,YAAA;AAAA,MACA,SAAA;AAAA,MACA,YAAA,EAAc,UAAA;AAAA,MACd,cAAA,EAAgB,UAAA;AAAA,MAChB,YAAA,EAAc,UAAA;AAAA,MACd,UAAA,EAAY;AAAA,KACd;AAAA,IACA,wBAAA;AAAA,IACA,iBAAA;AAAA,IACA,kBAAA;AAAA,IACA,iBAAA;AAAA,IACA,aAAA;AAAA,IACA,mBAAA;AAAA,IACA,kBAAA;AAAA,IACA,wBAAA;AAAA,IACA;AAAA,GACF;AACF;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseInputTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/BaseInputTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n BaseInputTemplateProps,\n examplesId,\n FormContextType,\n getInputProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { TextField } from '@backstage/ui';\n\nexport default function BaseInputTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n placeholder,\n required,\n readonly,\n disabled,\n type,\n label,\n value,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n autofocus,\n options,\n schema,\n rawErrors = [],\n children,\n extraProps,\n}: BaseInputTemplateProps<T, S, F>) {\n const { type: inputType, ...restInputProps } = {\n ...extraProps,\n ...getInputProps<T, S, F>(schema, type, options),\n };\n\n const list = schema.examples ? examplesId<T>(id) : undefined;\n\n const handleChange = (val: string) =>\n onFieldChange(val === '' ? options.emptyValue : val);\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n const isNumeric = inputType === 'number' || inputType === 'integer';\n\n // Normalize value to string for the input\n let inputValue: string;\n if (isNumeric) {\n inputValue = value || value === 0 ? String(value) : '';\n } else {\n inputValue = value === null || value === undefined ? '' : String(value);\n }\n\n return (\n <>\n <TextField\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n isRequired={required}\n isDisabled={disabled}\n isReadOnly={readonly}\n isInvalid={hasError}\n value={inputValue}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id, !!schema.examples)}\n list={list}\n {...restInputProps}\n />\n {children}\n {Array.isArray(schema.examples) ? (\n <datalist id={examplesId<T>(id)}>\n {(schema.examples as string[])\n .concat(\n schema.default && !schema.examples.includes(schema.default)\n ? ([schema.default] as string[])\n : [],\n )\n .map((example: any) => {\n return <option key={example} value={example} />;\n })}\n </datalist>\n ) : null}\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,iBAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,IAAA;AAAA,EACA,KAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,SAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,YAAY,EAAC;AAAA,EACb,QAAA;AAAA,EACA;AACF,CAAA,EAAoC;AAClC,EAAA,MAAM,EAAE,IAAA,EAAM,SAAA,EAAW,GAAG,gBAAe,GAAI;AAAA,IAC7C,GAAG,UAAA;AAAA,IACH,GAAG,aAAA,CAAuB,MAAA,EAAQ,IAAA,EAAM,OAAO;AAAA,GACjD;A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AAAA,QACV,MAAA,EAAQ,UAAA;AAAA,QACR,OAAA,EAAS,WAAA;AAAA,QACT,oBAAkB,kBAAA,CAAsB,EAAA,EAAI,CAAC,CAAC,OAAO,QAAQ,CAAA;AAAA,QAC7D,IAAA;AAAA,QACC,GAAG;AAAA;AAAA,KACN;AAAA,IACC,QAAA;AAAA,IACA,KAAA,CAAM,OAAA,CAAQ,MAAA,CAAO,QAAQ,CAAA,mBAC5B,GAAA,CAAC,UAAA,EAAA,EAAS,EAAA,EAAI,UAAA,CAAc,EAAE,CAAA,EAC1B,QAAA,EAAA,MAAA,CAAO,QAAA,CACN,MAAA;AAAA,MACC,MAAA,CAAO,OAAA,IAAW,CAAC,MAAA,CAAO,QAAA,CAAS,QAAA,CAAS,MAAA,CAAO,OAAO,CAAA,GACrD,CAAC,MAAA,CAAO,OAAO,IAChB;AAAC,KACP,CACC,GAAA,CAAI,CAAC,OAAA,KAAiB;AACrB,MAAA,uBAAO,GAAA,CAAC,QAAA,EAAA,EAAqB,KAAA,EAAO,OAAA,EAAA,EAAhB,OAAyB,CAAA;AAAA,IAC/C,CAAC,GACL,CAAA,GACE;AAAA,GAAA,EACN,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"BaseInputTemplate.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/BaseInputTemplate.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n BaseInputTemplateProps,\n examplesId,\n FormContextType,\n getInputProps,\n RJSFSchema,\n StrictRJSFSchema,\n} from '@rjsf/utils';\nimport { TextField } from '@backstage/ui';\n\nexport default function BaseInputTemplate<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n placeholder,\n required,\n readonly,\n disabled,\n type,\n label,\n value,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n autofocus,\n options,\n schema,\n rawErrors = [],\n children,\n extraProps,\n}: BaseInputTemplateProps<T, S, F>) {\n const { type: inputType, ...restInputProps } = {\n ...extraProps,\n ...getInputProps<T, S, F>(schema, type, options),\n };\n\n const list = schema.examples ? examplesId<T>(id) : undefined;\n\n const handleChange = (val: string) =>\n onFieldChange(val === '' ? options.emptyValue : val);\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n const isNumeric = inputType === 'number' || inputType === 'integer';\n\n // Normalize value to string for the input\n let inputValue: string;\n if (isNumeric) {\n inputValue = value || value === 0 ? String(value) : '';\n } else {\n inputValue = value === null || value === undefined ? '' : String(value);\n }\n\n return (\n <>\n <TextField\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n isRequired={required}\n isDisabled={disabled}\n isReadOnly={readonly}\n isInvalid={hasError}\n value={inputValue}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id, !!schema.examples)}\n list={list}\n {...restInputProps}\n />\n {children}\n {Array.isArray(schema.examples) ? (\n <datalist id={examplesId<T>(id)}>\n {(schema.examples as string[])\n .concat(\n schema.default && !schema.examples.includes(schema.default)\n ? ([schema.default] as string[])\n : [],\n )\n .map((example: any) => {\n return <option key={example} value={example} />;\n })}\n </datalist>\n ) : null}\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,iBAAA,CAItB;AAAA,EACA,EAAA;AAAA,E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-1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckboxWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/CheckboxWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n labelValue,\n RJSFSchema,\n schemaRequiresTrueValue,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Checkbox } from '@backstage/ui';\n\nexport default function CheckboxWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n const {\n id,\n value,\n disabled,\n readonly,\n label,\n hideLabel,\n schema,\n onChange: onFieldChange,\n } = props;\n\n const required = schemaRequiresTrueValue<S>(schema);\n\n const handleChange = (checked: boolean) => {\n onFieldChange(checked);\n };\n\n return (\n <Checkbox\n name={id}\n isSelected={typeof value === 'undefined' ? false : Boolean(value)}\n isRequired={required}\n isDisabled={disabled || readonly}\n onChange={handleChange}\n >\n {labelValue(label, hideLabel || !label)}\n </Checkbox>\n );\n}\n"],"names":[],"mappings":";;;;AAyBA,SAAwB,eAItB,KAAA,EAA6B;AAC7B,EAAA,MAAM;AAAA,IACJ,EAAA;AAAA,IACA,KAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,KAAA;AAAA,IACA,SAAA;AAAA,IACA,MAAA;AAAA,IACA,QAAA,EAAU;AAAA,GACZ,GAAI,KAAA;AAEJ,EAAA,MAAM,QAAA,GAAW,wBAA2B,MAAM,CAAA;AAElD,EAAA,MAAM,YAAA,GAAe,CAAC,OAAA,KAAqB;AACzC,IAAA,aAAA,CAAc,OAAO,CAAA;AAAA,EACvB,CAAA;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAM,EAAA;AAAA,MACN,YAAY,OAAO,KAAA,KAAU,WAAA,GAAc,KAAA,GAAQ,QAAQ,KAAK,CAAA;AAAA,MAChE,UAAA,EAAY,QAAA;AAAA,MACZ,YAAY,QAAA,IAAY,QAAA;AAAA,MACxB,QAAA,EAAU,YAAA;AAAA,MAET,QAAA,EAAA,UAAA,CAAW,KAAA,EAAO,SAAA,IAAa,CAAC,KAAK;AAAA;AAAA,GACxC;AAEJ
|
|
1
|
+
{"version":3,"file":"CheckboxWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/CheckboxWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n labelValue,\n RJSFSchema,\n schemaRequiresTrueValue,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Checkbox } from '@backstage/ui';\n\nexport default function CheckboxWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n const {\n id,\n value,\n disabled,\n readonly,\n label,\n hideLabel,\n schema,\n onChange: onFieldChange,\n } = props;\n\n const required = schemaRequiresTrueValue<S>(schema);\n\n const handleChange = (checked: boolean) => {\n onFieldChange(checked);\n };\n\n return (\n <Checkbox\n name={id}\n isSelected={typeof value === 'undefined' ? false : Boolean(value)}\n isRequired={required}\n isDisabled={disabled || readonly}\n onChange={handleChange}\n >\n {labelValue(label, hideLabel || !label)}\n </Checkbox>\n );\n}\n"],"names":[],"mappings":";;;;AAyBA,SAAwB,eAItB,KAAA,EAA6B;AAC7B,EAAA,MAAM;AAAA,IACJ,EAAA;AAAA,IACA,KAAA;AAAA,IACA,QAAA;AAAA,IACA,QAAA;AAAA,IACA,KAAA;AAAA,IACA,SAAA;AAAA,IACA,MAAA;AAAA,IACA,QAAA,EAAU;AAAA,GACZ,GAAI,KAAA;AAEJ,EAAA,MAAM,QAAA,GAAW,wBAA2B,MAAM,CAAA;AAElD,EAAA,MAAM,YAAA,GAAe,CAAC,OAAA,KAAqB;AACzC,IAAA,aAAA,CAAc,OAAO,CAAA;AAAA,EACvB,CAAA;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAM,EAAA;AAAA,MACN,YAAY,OAAO,KAAA,KAAU,WAAA,GAAc,KAAA,GAAQ,QAAQ,KAAK,CAAA;AAAA,MAChE,UAAA,EAAY,QAAA;AAAA,MACZ,YAAY,QAAA,IAAY,QAAA;AAAA,MACxB,QAAA,EAAU,YAAA;AAAA,MAET,QAAA,EAAA,UAAA,CAAW,KAAA,EAAO,SAAA,IAAa,CAAC,KAAK;AAAA;AAAA,GACxC;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckboxesWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/CheckboxesWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n FormContextType,\n optionId,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Checkbox, CheckboxGroup } from '@backstage/ui';\n\nexport default function CheckboxesWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n label,\n required,\n disabled,\n readonly,\n options,\n value,\n onChange: onFieldChange,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, enumDisabled } = options;\n\n const selectedKeys = Array.isArray(value) ? value.map(String) : [];\n const hasError = rawErrors.length > 0;\n\n const handleChange = (keys: string[]) => {\n const next =\n enumOptions\n ?.filter(option => keys.includes(String(option.value)))\n .map(option => option.value) ?? [];\n onFieldChange(next as T);\n };\n\n return (\n <CheckboxGroup\n label={label}\n isRequired={required}\n isInvalid={hasError}\n isDisabled={disabled || readonly}\n value={selectedKeys}\n onChange={handleChange}\n aria-describedby={ariaDescribedByIds<T>(id)}\n >\n {enumOptions?.map((option, index) => {\n const itemDisabled =\n Array.isArray(enumDisabled) &&\n enumDisabled.indexOf(option.value) !== -1;\n return (\n <Checkbox\n key={optionId(id, index)}\n value={String(option.value)}\n isDisabled={itemDisabled}\n >\n {option.label}\n </Checkbox>\n );\n })}\n </CheckboxGroup>\n );\n}\n"],"names":[],"mappings":";;;;AAyBA,SAAwB,gBAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,OAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,WAAA,EAAa,YAAA,EAAa,GAAI,OAAA;AAEtC,EAAA,MAAM,YAAA,GAAe,MAAM,OAAA,CAAQ,KAAK,IAAI,KAAA,CAAM,GAAA,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sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n FormContextType,\n optionId,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Checkbox, CheckboxGroup } from '@backstage/ui';\n\nexport default function CheckboxesWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n label,\n required,\n disabled,\n readonly,\n options,\n value,\n onChange: onFieldChange,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, enumDisabled } = options;\n\n const selectedKeys = Array.isArray(value) ? value.map(String) : [];\n const hasError = rawErrors.length > 0;\n\n const handleChange = (keys: string[]) => {\n const next =\n enumOptions\n ?.filter(option => keys.includes(String(option.value)))\n .map(option => option.value) ?? [];\n onFieldChange(next as T);\n };\n\n return (\n <CheckboxGroup\n label={label}\n isRequired={required}\n isInvalid={hasError}\n isDisabled={disabled || readonly}\n value={selectedKeys}\n onChange={handleChange}\n aria-describedby={ariaDescribedByIds<T>(id)}\n >\n {enumOptions?.map((option, index) => {\n const itemDisabled =\n Array.isArray(enumDisabled) &&\n enumDisabled.indexOf(option.value) !== -1;\n return (\n <Checkbox\n key={optionId(id, index)}\n value={String(option.value)}\n isDisabled={itemDisabled}\n >\n {option.label}\n </Checkbox>\n );\n })}\n </CheckboxGroup>\n );\n}\n"],"names":[],"mappings":";;;;AAyBA,SAAwB,gBAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA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EAAY,YAAA;AAAA,YAEX,QAAA,EAAA,MAAA,CAAO;AAAA,WAAA;AAAA,UAJH,QAAA,CAAS,IAAI,KAAK;AAAA,SAKzB;AAAA,MAEJ,CAAC;AAAA;AAAA,GACH;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ColorWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/ColorWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function ColorWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"color\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,YAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,OAAA,EAAQ,CAAA;AACpD
|
|
1
|
+
{"version":3,"file":"ColorWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/ColorWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function ColorWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"color\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,YAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,OAAA,EAAQ,CAAA;AACpD;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateInput.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateInput.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { CSSProperties, ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { FieldLabel } from '@backstage/ui';\n\n// Native fallback until BUI ships DatePicker/TimePicker components.\nconst baseStyle: CSSProperties = {\n display: 'flex',\n alignItems: 'center',\n height: '2rem',\n padding: '0 var(--bui-space-3)',\n borderRadius: 'var(--bui-radius-2)',\n border: '1px solid var(--bui-border-2)',\n backgroundColor: 'var(--bui-bg-neutral-1)',\n fontSize: 'var(--bui-font-size-3)',\n fontFamily: 'var(--bui-font-regular)',\n fontWeight: 400,\n color: 'var(--bui-fg-primary)',\n transition: 'border-color 0.2s ease-in-out',\n width: '100%',\n boxSizing: 'border-box' as const,\n outline: 'none',\n WebkitAppearance: 'none' as const,\n MozAppearance: 'none' as const,\n appearance: 'none' as const,\n};\n\ninterface DateInputProps<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n> extends WidgetProps<T, S, F> {\n inputType: 'date' | 'datetime-local' | 'time';\n}\n\nexport default function DateInput<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n label,\n required,\n disabled,\n readonly,\n value,\n autofocus,\n schema,\n options = {},\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n rawErrors = [],\n inputType,\n}: DateInputProps<T, S, F>) {\n const handleChange = (event: ChangeEvent<HTMLInputElement>) =>\n onFieldChange(\n event.target.value === '' ? options.emptyValue : event.target.value,\n );\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n const stringValue = String(value ?? '');\n\n return (\n <>\n {(label || schema.title) && (\n <FieldLabel\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n htmlFor={id}\n />\n )}\n <input\n id={id}\n name={id}\n type={inputType}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n disabled={disabled}\n readOnly={readonly}\n value={stringValue}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n aria-invalid={hasError}\n style={{\n ...baseStyle,\n ...(disabled && {\n opacity: 0.5,\n cursor: 'not-allowed',\n borderColor: 'var(--bui-border-disabled)',\n }),\n ...(hasError && {\n borderColor: 'var(--bui-fg-danger)',\n }),\n }}\n />\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA0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U,MAAA,GAAS,CAAA;AACpC,EAAA,MAAM,WAAA,GAAc,MAAA,CAAO,KAAA,IAAS,EAAE,CAAA;AAEtC,EAAA,uBACE,IAAA,CAAA,QAAA,EAAA,EACI,QAAA,EAAA;AAAA,IAAA,CAAA,KAAA,IAAS,OAAO,KAAA,qBAChB,GAAA;AAAA,MAAC,UAAA;AAAA,MAAA;AAAA,QACC,KAAA,EAAO,SAAS,MAAA,CAAO,KAAA;AAAA,QACvB,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,QACxC,OAAA,EAAS;AAAA;AAAA,KACX;AAAA,oBAEF,GAAA;AAAA,MAAC,OAAA;AAAA,MAAA;AAAA,QACC,EAAA;AAAA,QACA,IAAA,EAAM,EAAA;AAAA,QACN,IAAA,EAAM,SAAA;AAAA,QAEN,SAAA,EAAW,SAAA;AAAA,QACX,QAAA;AAAA,QACA,QAAA,EAAU,QAAA;AAAA,QACV,KAAA,EAAO,WAAA;AAAA,QACP,QAAA,EAAU,YAAA;AAAA,QACV,MAAA,EAAQ,UAAA;AAAA,QACR,OAAA,EAAS,WAAA;AAAA,QACT,kBAAA,EAAkB,mBAAsB,EAAE,CAAA;AAAA,QAC1C,cAAA,EAAc,QAAA;AAAA,QACd,KAAA,EAAO;AAAA,UACL,GAAG,SAAA;AAAA,UACH,GAAI,QAAA,IAAY;AAAA,YACd,OAAA,EAAS,GAAA;AAAA,YACT,MAAA,EAAQ,aAAA;AAAA,YACR,WAAA,EAAa;AAAA,WACf;AAAA,UACA,GAAI,QAAA,IAAY;AAAA,YACd,WAAA,EAAa;AAAA;AACf;AACF;AAAA;AACF,GAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"DateInput.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateInput.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { CSSProperties, ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { FieldLabel } from '@backstage/ui';\n\n// Native fallback until BUI ships DatePicker/TimePicker components.\nconst baseStyle: CSSProperties = {\n display: 'flex',\n alignItems: 'center',\n height: '2rem',\n padding: '0 var(--bui-space-3)',\n borderRadius: 'var(--bui-radius-2)',\n border: '1px solid var(--bui-border-2)',\n backgroundColor: 'var(--bui-bg-neutral-1)',\n fontSize: 'var(--bui-font-size-3)',\n fontFamily: 'var(--bui-font-regular)',\n fontWeight: 400,\n color: 'var(--bui-fg-primary)',\n transition: 'border-color 0.2s ease-in-out',\n width: '100%',\n boxSizing: 'border-box' as const,\n outline: 'none',\n WebkitAppearance: 'none' as const,\n MozAppearance: 'none' as const,\n appearance: 'none' as const,\n};\n\ninterface DateInputProps<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n> extends WidgetProps<T, S, F> {\n inputType: 'date' | 'datetime-local' | 'time';\n}\n\nexport default function DateInput<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n label,\n required,\n disabled,\n readonly,\n value,\n autofocus,\n schema,\n options = {},\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n rawErrors = [],\n inputType,\n}: DateInputProps<T, S, F>) {\n const handleChange = (event: ChangeEvent<HTMLInputElement>) =>\n onFieldChange(\n event.target.value === '' ? options.emptyValue : event.target.value,\n );\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n const stringValue = String(value ?? '');\n\n return (\n <>\n {(label || schema.title) && (\n <FieldLabel\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n htmlFor={id}\n />\n )}\n <input\n id={id}\n name={id}\n type={inputType}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n disabled={disabled}\n readOnly={readonly}\n value={stringValue}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n aria-invalid={hasError}\n style={{\n ...baseStyle,\n ...(disabled && {\n opacity: 0.5,\n cursor: 'not-allowed',\n borderColor: 'var(--bui-border-disabled)',\n }),\n ...(hasError && {\n borderColor: 'var(--bui-fg-danger)',\n }),\n }}\n />\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,MAAM,SAAA,GAA2B;AAAA,EAC/B,OAAA,EAAS,MAAA;AAAA,EACT,UAAA,EAAY,QAAA;AAAA,EACZ,MAAA,EAAQ,MAAA;AAAA,EACR,OAAA,EAAS,sBAAA;AAAA,EACT,YAAA,EAAc,qBAAA;AAAA,EACd,MAAA,EAAQ,+BAAA;AAAA,EACR,eAAA,EAAiB,yBAAA;AAAA,EACjB,QAAA,EAAU,wBAAA;AAAA,EACV,UAAA,EAAY,yBAAA;AAAA,EACZ,UAAA,EAAY,GAAA;AAAA,EACZ,KAAA,EAAO,uBAAA;AAAA,EACP,UAAA,EAAY,+BAAA;AAAA,EACZ,KAAA,EAAO,MAAA;AAAA,EACP,SAAA,EAAW,YAAA;AAAA,EACX,OAAA,EAAS,MAAA;AAAA,EACT,gBAAA,EAAkB,MAAA;AAAA,EAClB,aAAA,EAAe,MAAA;AAAA,EACf,UAAA,EAAY;AACd,CAAA;AAUA,SAAwB,SAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,SAAA;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sB,EAAE,CAAA;AAAA,QAC1C,cAAA,EAAc,QAAA;AAAA,QACd,KAAA,EAAO;AAAA,UACL,GAAG,SAAA;AAAA,UACH,GAAI,QAAA,IAAY;AAAA,YACd,OAAA,EAAS,GAAA;AAAA,YACT,MAAA,EAAQ,aAAA;AAAA,YACR,WAAA,EAAa;AAAA,WACf;AAAA,UACA,GAAI,QAAA,IAAY;AAAA,YACd,WAAA,EAAa;AAAA;AACf;AACF;AAAA;AACF,GAAA,EACF,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateTimeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateTimeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function DateTimeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"datetime-local\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,eAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,gBAAA,EAAiB,CAAA;AAC1D
|
|
1
|
+
{"version":3,"file":"DateTimeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateTimeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function DateTimeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"datetime-local\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,eAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,gBAAA,EAAiB,CAAA;AAC1D;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function DateWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"date\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,MAAA,EAAO,CAAA;AAChD
|
|
1
|
+
{"version":3,"file":"DateWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/DateWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function DateWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"date\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,MAAA,EAAO,CAAA;AAChD;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmailWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/EmailWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function EmailWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"email\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,YAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,OAAA,EAAQ,CAAA;AACpD
|
|
1
|
+
{"version":3,"file":"EmailWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/EmailWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function EmailWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"email\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,YAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,OAAA,EAAQ,CAAA;AACpD;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/FileWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ChangeEvent, useCallback } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\n\nfunction processFile(\n file: File,\n): Promise<{ dataURL: string; name: string; size: number; type: string }> {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = () => {\n resolve({\n dataURL: reader.result as string,\n name: file.name,\n size: file.size,\n type: file.type,\n });\n };\n reader.onerror = reject;\n reader.readAsDataURL(file);\n });\n}\n\nfunction processFiles(files: FileList): Promise<any> {\n return Promise.all(Array.from(files).map(processFile));\n}\n\nexport default function FileWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n readonly,\n disabled,\n required,\n multiple,\n onChange,\n options,\n}: WidgetProps<T, S, F>) {\n const handleChange = useCallback(\n (event: ChangeEvent<HTMLInputElement>) => {\n if (!event.target.files || readonly || disabled) {\n return;\n }\n processFiles(event.target.files).then(filesInfo => {\n onChange(multiple ? filesInfo : filesInfo[0]);\n });\n },\n [multiple, readonly, disabled, onChange],\n );\n\n return (\n <input\n id={id}\n name={id}\n type=\"file\"\n disabled={readonly || disabled}\n onChange={handleChange}\n defaultValue=\"\"\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={options.autofocus as boolean}\n multiple={multiple}\n required={required}\n accept={options.accept as string | undefined}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAS,YACP,IAAA,EACwE;AACxE,EAAA,OAAO,IAAI,OAAA,CAAQ,CAAC,OAAA,EAAS,MAAA,KAAW;AACtC,IAAA,MAAM,MAAA,GAAS,IAAI,UAAA,EAAW;AAC9B,IAAA,MAAA,CAAO,SAAS,MAAM;AACpB,MAAA,OAAA,CAAQ;AAAA,QACN,SAAS,MAAA,CAAO,MAAA;AAAA,QAChB,MAAM,IAAA,CAAK,IAAA;AAAA,QACX,MAAM,IAAA,CAAK,IAAA;AAAA,QACX,MAAM,IAAA,CAAK;AAAA,OACZ,CAAA;AAAA,IACH,CAAA;AACA,IAAA,MAAA,CAAO,OAAA,GAAU,MAAA;AACjB,IAAA,MAAA,CAAO,cAAc,IAAI,CAAA;AAAA,EAC3B,CAAC,CAAA;AACH;AAEA,SAAS,aAAa,KAAA,EAA+B;AACnD,EAAA,OAAO,OAAA,CAAQ,IAAI,KAAA,CAAM,IAAA,CAAK,KAAK,CAAA,CAAE,GAAA,CAAI,WAAW,CAAC,CAAA;AACvD;AAEA,SAAwB,UAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF,CAAA,EAAyB;AACvB,EAAA,MAAM,YAAA,GAAe,WAAA;AAAA,IACnB,CAAC,KAAA,KAAyC;AACxC,MAAA,IAAI,CAAC,KAAA,CAAM,MAAA,CAAO,KAAA,IAAS,YAAY,QAAA,EAAU;AAC/C,QAAA;AAAA,MACF;AACA,MAAA,YAAA,CAAa,KAAA,CAAM,MAAA,CAAO,KAAK,CAAA,CAAE,KAAK,CAAA,SAAA,KAAa;AACjD,QAAA,QAAA,CAAS,QAAA,GAAW,SAAA,GAAY,SAAA,CAAU,CAAC,CAAC,CAAA;AAAA,MAC9C,CAAC,CAAA;AAAA,IACH,CAAA;AAAA,IACA,CAAC,QAAA,EAAU,QAAA,EAAU,QAAA,EAAU,QAAQ;AAAA,GACzC;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,OAAA;AAAA,IAAA;AAAA,MACC,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,IAAA,EAAK,MAAA;AAAA,MACL,UAAU,QAAA,IAAY,QAAA;AAAA,MACtB,QAAA,EAAU,YAAA;AAAA,MACV,YAAA,EAAa,EAAA;AAAA,MAEb,WAAW,OAAA,CAAQ,SAAA;AAAA,MACnB,QAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAQ,OAAA,CAAQ,MAAA;AAAA,MAChB,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ
|
|
1
|
+
{"version":3,"file":"FileWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/FileWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ChangeEvent, useCallback } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\n\nfunction processFile(\n file: File,\n): Promise<{ dataURL: string; name: string; size: number; type: string }> {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = () => {\n resolve({\n dataURL: reader.result as string,\n name: file.name,\n size: file.size,\n type: file.type,\n });\n };\n reader.onerror = reject;\n reader.readAsDataURL(file);\n });\n}\n\nfunction processFiles(files: FileList): Promise<any> {\n return Promise.all(Array.from(files).map(processFile));\n}\n\nexport default function FileWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n readonly,\n disabled,\n required,\n multiple,\n onChange,\n options,\n}: WidgetProps<T, S, F>) {\n const handleChange = useCallback(\n (event: ChangeEvent<HTMLInputElement>) => {\n if (!event.target.files || readonly || disabled) {\n return;\n }\n processFiles(event.target.files).then(filesInfo => {\n onChange(multiple ? filesInfo : filesInfo[0]);\n });\n },\n [multiple, readonly, disabled, onChange],\n );\n\n return (\n <input\n id={id}\n name={id}\n type=\"file\"\n disabled={readonly || disabled}\n onChange={handleChange}\n defaultValue=\"\"\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={options.autofocus as boolean}\n multiple={multiple}\n required={required}\n accept={options.accept as string | undefined}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAS,YACP,IAAA,EACwE;AACxE,EAAA,OAAO,IAAI,OAAA,CAAQ,CAAC,OAAA,EAAS,MAAA,KAAW;AACtC,IAAA,MAAM,MAAA,GAAS,IAAI,UAAA,EAAW;AAC9B,IAAA,MAAA,CAAO,SAAS,MAAM;AACpB,MAAA,OAAA,CAAQ;AAAA,QACN,SAAS,MAAA,CAAO,MAAA;AAAA,QAChB,MAAM,IAAA,CAAK,IAAA;AAAA,QACX,MAAM,IAAA,CAAK,IAAA;AAAA,QACX,MAAM,IAAA,CAAK;AAAA,OACZ,CAAA;AAAA,IACH,CAAA;AACA,IAAA,MAAA,CAAO,OAAA,GAAU,MAAA;AACjB,IAAA,MAAA,CAAO,cAAc,IAAI,CAAA;AAAA,EAC3B,CAAC,CAAA;AACH;AAEA,SAAS,aAAa,KAAA,EAA+B;AACnD,EAAA,OAAO,OAAA,CAAQ,IAAI,KAAA,CAAM,IAAA,CAAK,KAAK,CAAA,CAAE,GAAA,CAAI,WAAW,CAAC,CAAA;AACvD;AAEA,SAAwB,UAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF,CAAA,EAAyB;AACvB,EAAA,MAAM,YAAA,GAAe,WAAA;AAAA,IACnB,CAAC,KAAA,KAAyC;AACxC,MAAA,IAAI,CAAC,KAAA,CAAM,MAAA,CAAO,KAAA,IAAS,YAAY,QAAA,EAAU;AAC/C,QAAA;AAAA,MACF;AACA,MAAA,YAAA,CAAa,KAAA,CAAM,MAAA,CAAO,KAAK,CAAA,CAAE,KAAK,CAAA,SAAA,KAAa;AACjD,QAAA,QAAA,CAAS,QAAA,GAAW,SAAA,GAAY,SAAA,CAAU,CAAC,CAAC,CAAA;AAAA,MAC9C,CAAC,CAAA;AAAA,IACH,CAAA;AAAA,IACA,CAAC,QAAA,EAAU,QAAA,EAAU,QAAA,EAAU,QAAQ;AAAA,GACzC;AAEA,EAAA,uBACE,GAAA;AAAA,IAAC,OAAA;AAAA,IAAA;AAAA,MACC,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,IAAA,EAAK,MAAA;AAAA,MACL,UAAU,QAAA,IAAY,QAAA;AAAA,MACtB,QAAA,EAAU,YAAA;AAAA,MACV,YAAA,EAAa,EAAA;AAAA,MAEb,WAAW,OAAA,CAAQ,SAAA;AAAA,MACnB,QAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAQ,OAAA,CAAQ,MAAA;AAAA,MAChB,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HiddenWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/HiddenWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\n\nexport default function HiddenWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, value }: WidgetProps<T, S, F>) {\n return (\n <input\n type=\"hidden\"\n id={id}\n name={id}\n value={typeof value === 'undefined' ? '' : value}\n />\n );\n}\n"],"names":[],"mappings":";;AAsBA,SAAwB,YAAA,CAItB,EAAE,EAAA,EAAI,KAAA,EAAM,EAAyB;AACrC,EAAA,uBACE,GAAA;AAAA,IAAC,OAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAK,QAAA;AAAA,MACL,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,KAAA,EAAO,OAAO,KAAA,KAAU,WAAA,GAAc,EAAA,GAAK;AAAA;AAAA,GAC7C;AAEJ
|
|
1
|
+
{"version":3,"file":"HiddenWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/HiddenWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\n\nexport default function HiddenWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({ id, value }: WidgetProps<T, S, F>) {\n return (\n <input\n type=\"hidden\"\n id={id}\n name={id}\n value={typeof value === 'undefined' ? '' : value}\n />\n );\n}\n"],"names":[],"mappings":";;AAsBA,SAAwB,YAAA,CAItB,EAAE,EAAA,EAAI,KAAA,EAAM,EAAyB;AACrC,EAAA,uBACE,GAAA;AAAA,IAAC,OAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAK,QAAA;AAAA,MACL,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,KAAA,EAAO,OAAO,KAAA,KAAU,WAAA,GAAc,EAAA,GAAK;AAAA;AAAA,GAC7C;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PasswordWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/PasswordWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { PasswordField } from '@backstage/ui';\n\nexport default function PasswordWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n placeholder,\n required,\n readonly,\n disabled,\n label,\n value,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n autofocus,\n options,\n schema,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const handleChange = (val: string) =>\n onFieldChange(val === '' ? options.emptyValue : val);\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n\n return (\n <PasswordField\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n isRequired={required}\n isDisabled={disabled}\n isReadOnly={readonly}\n isInvalid={hasError}\n value={value || ''}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,cAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,SAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,YAAA,GAAe,CAAC,GAAA,KACpB,aAAA,CAAc,QAAQ,EAAA,GAAK,OAAA,CAAQ,aAAa,GAAG,CAAA;AACrD,EAAA,MAAM,UAAA,GAAa,MAAM,WAAA,CAAY,EAAA,EAAI,KAAK,CAAA;AAC9C,EAAA,MAAM,WAAA,GAAc,MAAM,YAAA,CAAa,EAAA,EAAI,KAAK,CAAA;AAEhD,EAAA,MAAM,QAAA,GAAW,UAAU,MAAA,GAAS,CAAA;AAEpC,EAAA,uBACE,GAAA;AAAA,IAAC,aAAA;AAAA,IAAA;AAAA,MACC,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,KAAA,EAAO,SAAS,MAAA,CAAO,KAAA;AAAA,MACvB,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,MACxC,WAAA;AAAA,MAEA,SAAA,EAAW,SAAA;AAAA,MACX,UAAA,EAAY,QAAA;AAAA,MACZ,UAAA,EAAY,QAAA;AAAA,MACZ,UAAA,EAAY,QAAA;AAAA,MACZ,SAAA,EAAW,QAAA;AAAA,MACX,OAAO,KAAA,IAAS,EAAA;AAAA,MAChB,QAAA,EAAU,YAAA;AAAA,MACV,MAAA,EAAQ,UAAA;AAAA,MACR,OAAA,EAAS,WAAA;AAAA,MACT,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ
|
|
1
|
+
{"version":3,"file":"PasswordWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/PasswordWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { PasswordField } from '@backstage/ui';\n\nexport default function PasswordWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n placeholder,\n required,\n readonly,\n disabled,\n label,\n value,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n autofocus,\n options,\n schema,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const handleChange = (val: string) =>\n onFieldChange(val === '' ? options.emptyValue : val);\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n\n return (\n <PasswordField\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n isRequired={required}\n isDisabled={disabled}\n isReadOnly={readonly}\n isInvalid={hasError}\n value={value || ''}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;AAwBA,SAAwB,cAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,SAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,YAAA,GAAe,CAAC,GAAA,KACpB,aAAA,CAAc,QAAQ,EAAA,GAAK,OAAA,CAAQ,aAAa,GAAG,CAAA;AACrD,EAAA,MAAM,UAAA,GAAa,MAAM,WAAA,CAAY,EAAA,EAAI,KAAK,CAAA;AAC9C,EAAA,MAAM,WAAA,GAAc,MAAM,YAAA,CAAa,EAAA,EAAI,KAAK,CAAA;AAEhD,EAAA,MAAM,QAAA,GAAW,UAAU,MAAA,GAAS,CAAA;AAEpC,EAAA,uBACE,GAAA;AAAA,IAAC,aAAA;AAAA,IAAA;AAAA,MACC,EAAA;AAAA,MACA,IAAA,EAAM,EAAA;AAAA,MACN,KAAA,EAAO,SAAS,MAAA,CAAO,KAAA;AAAA,MACvB,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,MACxC,WAAA;AAAA,MAEA,SAAA,EAAW,SAAA;AAAA,MACX,UAAA,EAAY,QAAA;AAAA,MACZ,UAAA,EAAY,QAAA;AAAA,MACZ,UAAA,EAAY,QAAA;AAAA,MACZ,SAAA,EAAW,QAAA;AAAA,MACX,OAAO,KAAA,IAAS,EAAA;AAAA,MAChB,QAAA,EAAU,YAAA;AAAA,MACV,MAAA,EAAQ,UAAA;AAAA,MACR,OAAA,EAAS,WAAA;AAAA,MACT,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RadioWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/RadioWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n enumOptionsIndexForValue,\n enumOptionsValueForIndex,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { RadioGroup, Radio } from '@backstage/ui';\n\nexport default function RadioWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options,\n required,\n value,\n disabled,\n readonly,\n label,\n onChange: onFieldChange,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, enumDisabled, emptyValue } = options;\n\n const handleChange = (newValue: string) => {\n const actualValue = enumOptionsValueForIndex<S>(\n newValue,\n enumOptions,\n emptyValue,\n );\n onFieldChange(actualValue);\n };\n\n const selectedIndex =\n enumOptionsIndexForValue<S>(value, enumOptions) ?? undefined;\n const hasError = rawErrors.length > 0;\n\n return (\n <RadioGroup\n name={id}\n label={label}\n secondaryLabel={required ? 'Required' : undefined}\n value={selectedIndex !== undefined ? String(selectedIndex) : ''}\n onChange={handleChange}\n isRequired={required}\n isDisabled={disabled || readonly}\n isInvalid={hasError}\n aria-describedby={ariaDescribedByIds<T>(id)}\n >\n {enumOptions?.map(({ value: optionValue, label: optionLabel }, index) => {\n const itemDisabled =\n Array.isArray(enumDisabled) &&\n enumDisabled.indexOf(optionValue) !== -1;\n\n return (\n <Radio key={index} value={String(index)} isDisabled={itemDisabled}>\n {optionLabel}\n </Radio>\n );\n })}\n </RadioGroup>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,WAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,OAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,WAAA,EAAa,YAAA,EAAc,UAAA,EAAW,GAAI,OAAA;AAElD,EAAA,MAAM,YAAA,GAAe,CAAC,QAAA,KAAqB;AACzC,IAAA,MAAM,WAAA,GAAc,wBAAA;AAAA,MAClB,QAAA;AAAA,MACA,WAAA;AAAA,MACA;AAAA,KACF;AACA,IAAA,aAAA,CAAc,WAAW,CAAA;AAAA,EAC3B,CAAA;AAEA,EAAA,MAAM,aAAA,GACJ,wBAAA,CAA4B,KAAA,EAAO,WAAW,CAAA,IAAK,MAAA;AACrD,EAAA,MAAM,QAAA,GAAW,UAAU,MAAA,GAAS,CAAA;AAEpC,EAAA,uBACE,GAAA;AAAA,IAAC,UAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAM,EAAA;AAAA,MACN,KAAA;AAAA,MACA,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,MACxC,KAAA,EAAO,aAAA,KAAkB,MAAA,GAAY,MAAA,CAAO,aAAa,CAAA,GAAI,EAAA;AAAA,MAC7D,QAAA,EAAU,YAAA;AAAA,MACV,UAAA,EAAY,QAAA;AAAA,MACZ,YAAY,QAAA,IAAY,QAAA;AAAA,MACxB,SAAA,EAAW,QAAA;AAAA,MACX,kBAAA,EAAkB,mBAAsB,EAAE,CAAA;AAAA,MAEzC,QAAA,EAAA,WAAA,EAAa,IAAI,CAAC,EAAE,OAAO,WAAA,EAAa,KAAA,EAAO,WAAA,EAAY,EAAG,KAAA,KAAU;AACvE,QAAA,MAAM,YAAA,GACJ,MAAM,OAAA,CAAQ,YAAY,KAC1B,YAAA,CAAa,OAAA,CAAQ,WAAW,CAAA,KAAM,EAAA;AAExC,QAAA,uBACE,GAAA,CAAC,SAAkB,KAAA,EAAO,MAAA,CAAO,KAAK,CAAA,EAAG,UAAA,EAAY,YAAA,EAClD,QAAA,EAAA,WAAA,EAAA,EADS,KAEZ,CAAA;AAAA,MAEJ,CAAC;AAAA;AAAA,GACH;AAEJ
|
|
1
|
+
{"version":3,"file":"RadioWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/RadioWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n enumOptionsIndexForValue,\n enumOptionsValueForIndex,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { RadioGroup, Radio } from '@backstage/ui';\n\nexport default function RadioWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options,\n required,\n value,\n disabled,\n readonly,\n label,\n onChange: onFieldChange,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, enumDisabled, emptyValue } = options;\n\n const handleChange = (newValue: string) => {\n const actualValue = enumOptionsValueForIndex<S>(\n newValue,\n enumOptions,\n emptyValue,\n );\n onFieldChange(actualValue);\n };\n\n const selectedIndex =\n enumOptionsIndexForValue<S>(value, enumOptions) ?? undefined;\n const hasError = rawErrors.length > 0;\n\n return (\n <RadioGroup\n name={id}\n label={label}\n secondaryLabel={required ? 'Required' : undefined}\n value={selectedIndex !== undefined ? String(selectedIndex) : ''}\n onChange={handleChange}\n isRequired={required}\n isDisabled={disabled || readonly}\n isInvalid={hasError}\n aria-describedby={ariaDescribedByIds<T>(id)}\n >\n {enumOptions?.map(({ value: optionValue, label: optionLabel }, index) => {\n const itemDisabled =\n Array.isArray(enumDisabled) &&\n enumDisabled.indexOf(optionValue) !== -1;\n\n return (\n <Radio key={index} value={String(index)} isDisabled={itemDisabled}>\n {optionLabel}\n </Radio>\n );\n })}\n </RadioGroup>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,WAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,OAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,WAAA,EAAa,YAAA,EAAc,UAAA,EAAW,GAAI,OAAA;AAElD,EAAA,MAAM,YAAA,GAAe,CAAC,QAAA,KAAqB;AACzC,IAAA,MAAM,WAAA,GAAc,wBAAA;AAAA,MAClB,QAAA;AAAA,MACA,WAAA;AAAA,MACA;AAAA,KACF;AACA,IAAA,aAAA,CAAc,WAAW,CAAA;AAAA,EAC3B,CAAA;AAEA,EAAA,MAAM,aAAA,GACJ,wBAAA,CAA4B,KAAA,EAAO,WAAW,CAAA,IAAK,MAAA;AACrD,EAAA,MAAM,QAAA,GAAW,UAAU,MAAA,GAAS,CAAA;AAEpC,EAAA,uBACE,GAAA;AAAA,IAAC,UAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAM,EAAA;AAAA,MACN,KAAA;AAAA,MACA,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,MACxC,KAAA,EAAO,aAAA,KAAkB,MAAA,GAAY,MAAA,CAAO,aAAa,CAAA,GAAI,EAAA;AAAA,MAC7D,QAAA,EAAU,YAAA;AAAA,MACV,UAAA,EAAY,QAAA;AAAA,MACZ,YAAY,QAAA,IAAY,QAAA;AAAA,MACxB,SAAA,EAAW,QAAA;AAAA,MACX,kBAAA,EAAkB,mBAAsB,EAAE,CAAA;AAAA,MAEzC,QAAA,EAAA,WAAA,EAAa,IAAI,CAAC,EAAE,OAAO,WAAA,EAAa,KAAA,EAAO,WAAA,EAAY,EAAG,KAAA,KAAU;AACvE,QAAA,MAAM,YAAA,GACJ,MAAM,OAAA,CAAQ,YAAY,KAC1B,YAAA,CAAa,OAAA,CAAQ,WAAW,CAAA,KAAM,EAAA;AAExC,QAAA,uBACE,GAAA,CAAC,SAAkB,KAAA,EAAO,MAAA,CAAO,KAAK,CAAA,EAAG,UAAA,EAAY,YAAA,EAClD,QAAA,EAAA,WAAA,EAAA,EADS,KAEZ,CAAA;AAAA,MAEJ,CAAC;AAAA;AAAA,GACH;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RangeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/RangeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n rangeSpec,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Flex, Text } from '@backstage/ui';\n\nexport default function RangeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n value,\n readonly,\n disabled,\n schema,\n label,\n required,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n}: WidgetProps<T, S, F>) {\n const { min, max, step } = rangeSpec<S>(schema);\n\n const handleChange = ({\n target: { value: inputValue },\n }: ChangeEvent<HTMLInputElement>) => onFieldChange(parseFloat(inputValue));\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n return (\n <Flex align=\"center\" gap=\"4\">\n <input\n id={id}\n name={id}\n type=\"range\"\n disabled={disabled || readonly}\n min={min}\n max={max}\n step={step}\n value={value ?? min}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-label={label}\n aria-describedby={ariaDescribedByIds<T>(id)}\n required={required}\n style={{ flex: 1 }}\n />\n <Text\n variant=\"body-medium\"\n style={{ minWidth: '3rem', textAlign: 'right' }}\n >\n {value ?? min}\n </Text>\n </Flex>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,WAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,MAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS;AACX,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,GAAA,EAAK,GAAA,EAAK,IAAA,EAAK,GAAI,UAAa,MAAM,CAAA;AAE9C,EAAA,MAAM,eAAe,CAAC;AAAA,IACpB,MAAA,EAAQ,EAAE,KAAA,EAAO,UAAA;AAAW,GAC9B,KAAqC,aAAA,CAAc,UAAA,CAAW,UAAU,CAAC,CAAA;AACzE,EAAA,MAAM,UAAA,GAAa,MAAM,WAAA,CAAY,EAAA,EAAI,KAAK,CAAA;AAC9C,EAAA,MAAM,WAAA,GAAc,MAAM,YAAA,CAAa,EAAA,EAAI,KAAK,CAAA;AAEhD,EAAA,uBACE,IAAA,CAAC,IAAA,EAAA,EAAK,KAAA,EAAM,QAAA,EAAS,KAAI,GAAA,EACvB,QAAA,EAAA;AAAA,oBAAA,GAAA;AAAA,MAAC,OAAA;AAAA,MAAA;AAAA,QACC,EAAA;AAAA,QACA,IAAA,EAAM,EAAA;AAAA,QACN,IAAA,EAAK,OAAA;AAAA,QACL,UAAU,QAAA,IAAY,QAAA;AAAA,QACtB,GAAA;AAAA,QACA,GAAA;AAAA,QACA,IAAA;AAAA,QACA,OAAO,KAAA,IAAS,GAAA;AAAA,QAChB,QAAA,EAAU,YAAA;AAAA,QACV,MAAA,EAAQ,UAAA;AAAA,QACR,OAAA,EAAS,WAAA;AAAA,QACT,YAAA,EAAY,KAAA;AAAA,QACZ,kBAAA,EAAkB,mBAAsB,EAAE,CAAA;AAAA,QAC1C,QAAA;AAAA,QACA,KAAA,EAAO,EAAE,IAAA,EAAM,CAAA;AAAE;AAAA,KACnB;AAAA,oBACA,GAAA;AAAA,MAAC,IAAA;AAAA,MAAA;AAAA,QACC,OAAA,EAAQ,aAAA;AAAA,QACR,KAAA,EAAO,EAAE,QAAA,EAAU,MAAA,EAAQ,WAAW,OAAA,EAAQ;AAAA,QAE7C,QAAA,EAAA,KAAA,IAAS;AAAA;AAAA;AACZ,GAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"RangeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/RangeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n rangeSpec,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Flex, Text } from '@backstage/ui';\n\nexport default function RangeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n value,\n readonly,\n disabled,\n schema,\n label,\n required,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n}: WidgetProps<T, S, F>) {\n const { min, max, step } = rangeSpec<S>(schema);\n\n const handleChange = ({\n target: { value: inputValue },\n }: ChangeEvent<HTMLInputElement>) => onFieldChange(parseFloat(inputValue));\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n return (\n <Flex align=\"center\" gap=\"4\">\n <input\n id={id}\n name={id}\n type=\"range\"\n disabled={disabled || readonly}\n min={min}\n max={max}\n step={step}\n value={value ?? min}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-label={label}\n aria-describedby={ariaDescribedByIds<T>(id)}\n required={required}\n style={{ flex: 1 }}\n />\n <Text\n variant=\"body-medium\"\n style={{ minWidth: '3rem', textAlign: 'right' }}\n >\n {value ?? min}\n </Text>\n </Flex>\n );\n}\n"],"names":[],"mappings":";;;;AA0BA,SAAwB,WAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,MAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAA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QAAA,EAAA,KAAA,IAAS;AAAA;AAAA;AACZ,GAAA,EACF,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/SelectWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n enumOptionsIndexForValue,\n enumOptionsValueForIndex,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Select } from '@backstage/ui';\nimport overrides from './selectOverrides.module.css';\n\nexport default function SelectWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options,\n required,\n disabled,\n readonly,\n value,\n multiple,\n label,\n schema,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, emptyValue } = options;\n\n const handleChange = (newValue: string) => {\n const actualIndex = newValue === '' ? '' : newValue;\n onFieldChange(\n enumOptionsValueForIndex<S>(actualIndex, enumOptions, emptyValue),\n );\n };\n\n const handleBlur = () =>\n onFieldBlur(\n id,\n enumOptionsValueForIndex<S>(value, enumOptions, emptyValue),\n );\n const handleFocus = () =>\n onFieldFocus(\n id,\n enumOptionsValueForIndex<S>(value, enumOptions, emptyValue),\n );\n\n const selectedIndex = enumOptionsIndexForValue<S>(value, enumOptions);\n const hasError = rawErrors.length > 0;\n\n const selectOptions =\n enumOptions?.map(({ label: optionLabel }, index) => ({\n value: String(index),\n label: optionLabel,\n })) || [];\n\n if (!multiple && schema.default === undefined) {\n selectOptions.unshift({\n value: '',\n label: (options.placeholder as string) || 'Select an option',\n });\n }\n\n return (\n <Select\n className={overrides.select}\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n options={selectOptions}\n selectedKey={selectedIndex !== undefined ? String(selectedIndex) : ''}\n onSelectionChange={key => {\n const selected = key ? String(key) : '';\n handleChange(selected);\n }}\n isRequired={required}\n isDisabled={disabled || readonly}\n isInvalid={hasError}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;;AA2BA,SAAwB,YAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,OAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,MAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,WAAA,EAAa,UAAA,EAAW,GAAI,OAAA;AAEpC,EAAA,MAAM,YAAA,GAAe,CAAC,QAAA,KAAqB;AACzC,IAAA,MAAM,WAAA,GAAc,QAAA,KAAa,EAAA,GAAK,EAAA,GAAK,QAAA;AAC3C,IAAA,aAAA;AAAA,MACE,wBAAA,CAA4B,WAAA,EAAa,WAAA,EAAa,UAAU;AAAA,KAClE;AAAA,EACF,CAAA;AAEA,EAAA,MAAM,aAAa,MACjB,WAAA;AAAA,IACE,EAAA;AAAA,IACA,wBAAA,CAA4B,KAAA,EAAO,WAAA,EAAa,UAAU;AAAA,GAC5D;AACF,EAAA,MAAM,cAAc,MAClB,YAAA;AAAA,IACE,EAAA;AAAA,IACA,wB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AAA,MACR,OAAA,EAAS,WAAA;AAAA,MACT,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ
|
|
1
|
+
{"version":3,"file":"SelectWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/SelectWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ariaDescribedByIds,\n enumOptionsIndexForValue,\n enumOptionsValueForIndex,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { Select } from '@backstage/ui';\nimport overrides from './selectOverrides.module.css';\n\nexport default function SelectWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options,\n required,\n disabled,\n readonly,\n value,\n multiple,\n label,\n schema,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const { enumOptions, emptyValue } = options;\n\n const handleChange = (newValue: string) => {\n const actualIndex = newValue === '' ? '' : newValue;\n onFieldChange(\n enumOptionsValueForIndex<S>(actualIndex, enumOptions, emptyValue),\n );\n };\n\n const handleBlur = () =>\n onFieldBlur(\n id,\n enumOptionsValueForIndex<S>(value, enumOptions, emptyValue),\n );\n const handleFocus = () =>\n onFieldFocus(\n id,\n enumOptionsValueForIndex<S>(value, enumOptions, emptyValue),\n );\n\n const selectedIndex = enumOptionsIndexForValue<S>(value, enumOptions);\n const hasError = rawErrors.length > 0;\n\n const selectOptions =\n enumOptions?.map(({ label: optionLabel }, index) => ({\n value: String(index),\n label: optionLabel,\n })) || [];\n\n if (!multiple && schema.default === undefined) {\n selectOptions.unshift({\n value: '',\n label: (options.placeholder as string) || 'Select an option',\n });\n }\n\n return (\n <Select\n className={overrides.select}\n id={id}\n name={id}\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n options={selectOptions}\n selectedKey={selectedIndex !== undefined ? String(selectedIndex) : ''}\n onSelectionChange={key => {\n const selected = key ? String(key) : '';\n handleChange(selected);\n }}\n isRequired={required}\n isDisabled={disabled || readonly}\n isInvalid={hasError}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n />\n );\n}\n"],"names":[],"mappings":";;;;;AA2BA,SAAwB,YAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,OAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,MAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,YAAY;AACd,CAAA,EAAyB;AACvB,EAAA,MAAM,EAAE,WAAA,EAAa,UAAA,EAAW,GAAI,OAAA;AAEpC,EAAA,MAAM,YAAA,GAAe,CAAC,QAAA,KAAqB;AACzC,IAAA,MAAM,WAAA,GAAc,QAAA,KAAa,EAAA,GAAK,EAAA,GAAK,QAAA;AAC3C,IAAA,aAAA;AAAA,MACE,wBAAA,CAA4B,WAAA,EAAa,WAAA,EAAa,UAAU;AAAA,KAClE;AAAA,EACF,CAAA;AAEA,EAAA,MAAM,aAAa,MACjB,WAAA;AAAA,IACE,EAAA;AAAA,IACA,wBAAA,CAA4B,KAAA,EAAO,WAAA,EAAa,UAAU;AAAA,GAC5D;AACF,EAAA,MAAM,cAAc,MAClB,YAAA;AAAA,IACE,EAAA;AAAA,IACA,w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AAAA,MACR,OAAA,EAAS,WAAA;AAAA,MACT,kBAAA,EAAkB,mBAAsB,EAAE;AAAA;AAAA,GAC5C;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TextWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function TextWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,CAAA;AACvC
|
|
1
|
+
{"version":3,"file":"TextWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TextWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function TextWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,CAAA;AACvC;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextareaWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TextareaWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { CSSProperties, ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { FieldLabel } from '@backstage/ui';\n\n// Matches the outlined style used by BUI PasswordField: sits on the same\n// neutral-1 surface as the form and uses a visible border to read as an input.\nconst baseStyle: CSSProperties = {\n display: 'flex',\n alignItems: 'flex-start',\n padding: 'var(--bui-space-3)',\n borderRadius: 'var(--bui-radius-3)',\n border: '1px solid var(--bui-border-2)',\n backgroundColor: 'var(--bui-bg-neutral-1)',\n fontSize: 'var(--bui-font-size-3)',\n fontFamily: 'var(--bui-font-regular)',\n fontWeight: 400,\n lineHeight: '1.5',\n color: 'var(--bui-fg-primary)',\n transition: 'border-color 0.2s ease-in-out',\n width: '100%',\n resize: 'vertical',\n boxSizing: 'border-box' as const,\n outline: 'none',\n WebkitAppearance: 'none' as const,\n MozAppearance: 'none' as const,\n appearance: 'none' as const,\n};\n\nexport default function TextareaWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options = {},\n placeholder,\n required,\n value,\n disabled,\n readonly,\n label,\n autofocus,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n schema,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const handleChange = (event: ChangeEvent<HTMLTextAreaElement>) =>\n onFieldChange(\n event.target.value === '' ? options.emptyValue : event.target.value,\n );\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n\n return (\n <>\n {(label || schema.title) && (\n <FieldLabel\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n htmlFor={id}\n />\n )}\n <textarea\n id={id}\n name={id}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n disabled={disabled}\n readOnly={readonly}\n value={value || ''}\n rows={(options.rows as number) || 3}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n aria-invalid={hasError}\n style={{\n ...baseStyle,\n ...(disabled && {\n opacity: 0.5,\n cursor: 'not-allowed',\n borderColor: 'var(--bui-border-disabled)',\n }),\n ...(hasError && {\n borderColor: 'var(--bui-fg-danger)',\n }),\n }}\n />\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA2BA,MAAM,SAAA,GAA2B;AAAA,EAC/B,OAAA,EAAS,MAAA;AAAA,EACT,UAAA,EAAY,YAAA;AAAA,EACZ,OAAA,EAAS,oBAAA;AAAA,EACT,YAAA,EAAc,qBAAA;AAAA,EACd,MAAA,EAAQ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AA,MAAC,UAAA;AAAA,MAAA;AAAA,QACC,KAAA,EAAO,SAAS,MAAA,CAAO,KAAA;AAAA,QACvB,cAAA,EAAgB,WAAW,UAAA,GAAa,MAAA;AAAA,QACxC,OAAA,EAAS;AAAA;AAAA,KACX;AAAA,oBAEF,GAAA;AAAA,MAAC,UAAA;AAAA,MAAA;AAAA,QACC,EAAA;AAAA,QACA,IAAA,EAAM,EAAA;AAAA,QACN,WAAA;AAAA,QAEA,SAAA,EAAW,SAAA;AAAA,QACX,QAAA;AAAA,QACA,QAAA,EAAU,QAAA;AAAA,QACV,OAAO,KAAA,IAAS,EAAA;AAAA,QAChB,IAAA,EAAO,QAAQ,IAAA,IAAmB,CAAA;AAAA,QAClC,QAAA,EAAU,YAAA;AAAA,QACV,MAAA,EAAQ,UAAA;AAAA,QACR,OAAA,EAAS,WAAA;AAAA,QACT,kBAAA,EAAkB,mBAAsB,EAAE,CAAA;AAAA,QAC1C,cAAA,EAAc,QAAA;AAAA,QACd,KAAA,EAAO;AAAA,UACL,GAAG,SAAA;AAAA,UACH,GAAI,QAAA,IAAY;AAAA,YACd,OAAA,EAAS,GAAA;AAAA,YACT,MAAA,EAAQ,aAAA;AAAA,YACR,WAAA,EAAa;AAAA,WACf;AAAA,UACA,GAAI,QAAA,IAAY;AAAA,YACd,WAAA,EAAa;AAAA;AACf;AACF;AAAA;AACF,GAAA,EACF,CAAA;AAEJ
|
|
1
|
+
{"version":3,"file":"TextareaWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TextareaWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { CSSProperties, ChangeEvent } from 'react';\nimport {\n ariaDescribedByIds,\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport { FieldLabel } from '@backstage/ui';\n\n// Matches the outlined style used by BUI PasswordField: sits on the same\n// neutral-1 surface as the form and uses a visible border to read as an input.\nconst baseStyle: CSSProperties = {\n display: 'flex',\n alignItems: 'flex-start',\n padding: 'var(--bui-space-3)',\n borderRadius: 'var(--bui-radius-3)',\n border: '1px solid var(--bui-border-2)',\n backgroundColor: 'var(--bui-bg-neutral-1)',\n fontSize: 'var(--bui-font-size-3)',\n fontFamily: 'var(--bui-font-regular)',\n fontWeight: 400,\n lineHeight: '1.5',\n color: 'var(--bui-fg-primary)',\n transition: 'border-color 0.2s ease-in-out',\n width: '100%',\n resize: 'vertical',\n boxSizing: 'border-box' as const,\n outline: 'none',\n WebkitAppearance: 'none' as const,\n MozAppearance: 'none' as const,\n appearance: 'none' as const,\n};\n\nexport default function TextareaWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>({\n id,\n options = {},\n placeholder,\n required,\n value,\n disabled,\n readonly,\n label,\n autofocus,\n onChange: onFieldChange,\n onBlur: onFieldBlur,\n onFocus: onFieldFocus,\n schema,\n rawErrors = [],\n}: WidgetProps<T, S, F>) {\n const handleChange = (event: ChangeEvent<HTMLTextAreaElement>) =>\n onFieldChange(\n event.target.value === '' ? options.emptyValue : event.target.value,\n );\n const handleBlur = () => onFieldBlur(id, value);\n const handleFocus = () => onFieldFocus(id, value);\n\n const hasError = rawErrors.length > 0;\n\n return (\n <>\n {(label || schema.title) && (\n <FieldLabel\n label={label || schema.title}\n secondaryLabel={required ? 'Required' : undefined}\n htmlFor={id}\n />\n )}\n <textarea\n id={id}\n name={id}\n placeholder={placeholder}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autofocus}\n disabled={disabled}\n readOnly={readonly}\n value={value || ''}\n rows={(options.rows as number) || 3}\n onChange={handleChange}\n onBlur={handleBlur}\n onFocus={handleFocus}\n aria-describedby={ariaDescribedByIds<T>(id)}\n aria-invalid={hasError}\n style={{\n ...baseStyle,\n ...(disabled && {\n opacity: 0.5,\n cursor: 'not-allowed',\n borderColor: 'var(--bui-border-disabled)',\n }),\n ...(hasError && {\n borderColor: 'var(--bui-fg-danger)',\n }),\n }}\n />\n </>\n );\n}\n"],"names":[],"mappings":";;;;AA2BA,MAAM,SAAA,GAA2B;AAAA,EAC/B,OAAA,EAAS,MAAA;AAAA,EACT,UAAA,EAAY,YAAA;AAAA,EACZ,OAAA,EAAS,oBAAA;AAAA,EACT,YAAA,EAAc,qBAAA;AAAA,EACd,MAAA,EAAQ,+BAAA;AAAA,EACR,eAAA,EAAiB,yBAAA;AAAA,EACjB,QAAA,EAAU,wBAAA;AAAA,EACV,UAAA,EAAY,yBAAA;AAAA,EACZ,UAAA,EAAY,GAAA;AAAA,EACZ,UAAA,EAAY,KAAA;AAAA,EACZ,KAAA,EAAO,uBAAA;AAAA,EACP,UAAA,EAAY,+BAAA;AAAA,EACZ,KAAA,EAAO,MAAA;AAAA,EACP,MAAA,EAAQ,UAAA;AAAA,EACR,SAAA,EAAW,YAAA;AAAA,EACX,OAAA,EAAS,MAAA;AAAA,EACT,gBAAA,EAAkB,MAAA;AAAA,EAClB,aAAA,EAAe,MAAA;AAAA,EACf,UAAA,EAAY;AACd,CAAA;AAEA,SAAwB,cAAA,CAItB;AAAA,EACA,EAAA;AAAA,EACA,UAAU,EAAC;AAAA,EACX,WAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,SAAA;AAAA,EACA,QAAA,EAAU,aAAA;AAAA,EACV,MAAA,EAAQ,WAAA;AAAA,EACR,OAAA,EAAS,YAAA;AAAA,EACT,MAAA;AAAA,EACA,YAAY;AACd,CAAA,EAA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EAAa;AAAA,WACf;AAAA,UACA,GAAI,QAAA,IAAY;AAAA,YACd,WAAA,EAAa;AAAA;AACf;AACF;AAAA;AACF,GAAA,EACF,CAAA;AAEJ;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TimeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TimeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function TimeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"time\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,MAAA,EAAO,CAAA;AAChD
|
|
1
|
+
{"version":3,"file":"TimeWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/TimeWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport DateInput from './DateInput';\n\nexport default function TimeWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <DateInput {...props} inputType=\"time\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,WAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,SAAA,EAAA,EAAW,GAAG,KAAA,EAAO,WAAU,MAAA,EAAO,CAAA;AAChD;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"URLWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/URLWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function URLWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"url\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,UAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,KAAA,EAAM,CAAA;AAClD
|
|
1
|
+
{"version":3,"file":"URLWidget.esm.js","sources":["../../../../../../src/next/components/Form/BuiTheme/widgets/URLWidget.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n FormContextType,\n RJSFSchema,\n StrictRJSFSchema,\n WidgetProps,\n} from '@rjsf/utils';\nimport BaseInputTemplate from './BaseInputTemplate';\n\nexport default function URLWidget<\n T = any,\n S extends StrictRJSFSchema = RJSFSchema,\n F extends FormContextType = any,\n>(props: WidgetProps<T, S, F>) {\n return <BaseInputTemplate {...props} type=\"url\" />;\n}\n"],"names":[],"mappings":";;;AAuBA,SAAwB,UAItB,KAAA,EAA6B;AAC7B,EAAA,uBAAO,GAAA,CAAC,iBAAA,EAAA,EAAmB,GAAG,KAAA,EAAO,MAAK,KAAA,EAAM,CAAA;AAClD;;"}
|