"use strict";
// The require scope
var __webpack_require__ = {};
/************************************************************************/ // webpack/runtime/compat_get_default_export
(()=>{
    // getDefaultExport function for compatibility with non-ESM modules
    __webpack_require__.n = function(module) {
        var getter = module && module.__esModule ? function() {
            return module['default'];
        } : function() {
            return module;
        };
        __webpack_require__.d(getter, {
            a: getter
        });
        return getter;
    };
})();
// webpack/runtime/define_property_getters
(()=>{
    __webpack_require__.d = function(exports1, definition) {
        for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
            enumerable: true,
            get: definition[key]
        });
    };
})();
// webpack/runtime/has_own_property
(()=>{
    __webpack_require__.o = function(obj, prop) {
        return Object.prototype.hasOwnProperty.call(obj, prop);
    };
})();
// webpack/runtime/make_namespace_object
(()=>{
    // define __esModule on exports
    __webpack_require__.r = function(exports1) {
        if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
            value: 'Module'
        });
        Object.defineProperty(exports1, '__esModule', {
            value: true
        });
    };
})();
/************************************************************************/ var __webpack_exports__ = {};
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);
// EXPORTS
__webpack_require__.d(__webpack_exports__, {
    formFieldExamples: ()=>/* binding */ formFieldExamples,
    radioGroupExamples: ()=>/* binding */ radioGroupExamples,
    FormFieldExamples: ()=>/* binding */ FormFieldExamples
});
const external_react_namespaceObject = require("react");
var external_react_default = /*#__PURE__*/ __webpack_require__.n(external_react_namespaceObject);
const react_namespaceObject = require("@chakra-ui/react");
const external_yup_namespaceObject = require("yup");
const external_Form_js_namespaceObject = require("./Form.js");
var external_Form_js_default = /*#__PURE__*/ __webpack_require__.n(external_Form_js_namespaceObject);
const formFieldExamples = [
    {
        name: 'radiocard',
        fieldType: 'radio',
        label: 'Radio cards',
        description: 'Field description text',
        schema: external_yup_namespaceObject.string().required('Select a provider'),
        defaultValue: 'AWS',
        isAttached: false,
        options: [
            'AWS',
            'GCP',
            'Azure'
        ].map((provider)=>({
                value: provider,
                label: /*#__PURE__*/ external_react_default().createElement(react_namespaceObject.Stack, {
                    py: 2
                }, /*#__PURE__*/ external_react_default().createElement(react_namespaceObject.Heading, {
                    size: "sm"
                }, provider), /*#__PURE__*/ external_react_default().createElement(react_namespaceObject.Tag, {
                    size: "sm",
                    colorScheme: "gray",
                    width: "max-content"
                }, "Private"), /*#__PURE__*/ external_react_default().createElement(react_namespaceObject.Text, {
                    fontSize: "sm"
                }, "Lorem ipsum dolor sit amet consectetur adipisicing elit. Officiis, vero!"))
            }))
    },
    {
        name: 'radio',
        fieldType: 'radio',
        label: 'Radio buttons',
        schema: external_yup_namespaceObject.string().required(),
        defaultValue: '1',
        isAttached: true,
        options: [
            {
                value: '1',
                label: 'Option 1'
            },
            {
                value: '2',
                label: 'Option 2'
            },
            {
                value: '3',
                label: 'Option 3'
            },
            {
                value: '4',
                label: 'Option 4',
                disabled: true
            }
        ]
    },
    {
        name: 'multiselect',
        fieldType: 'select',
        label: 'Multiple select',
        placeholder: 'Select options',
        defaultValue: [
            {
                label: 'us-east-1',
                value: 'us-east-1'
            },
            {
                label: 'us-east-2',
                value: 'us-east-2'
            }
        ],
        /**
     * When the select is in multi mode, the schema is an array of objects with a label and value property.
     * When the select is in single mode, the schema is just an object with a label and value property.
     */ schema: external_yup_namespaceObject.array(external_yup_namespaceObject.object({
            label: external_yup_namespaceObject.string(),
            value: external_yup_namespaceObject.string()
        })).required('Provide a list of regions'),
        options: [
            {
                label: 'Europe',
                options: [
                    {
                        label: 'eu-central-1',
                        value: 'eu-central-1'
                    }
                ]
            },
            {
                label: 'US',
                options: [
                    {
                        label: 'us-east-1',
                        value: 'us-east-1'
                    },
                    {
                        label: 'us-east-2',
                        value: 'us-east-2'
                    }
                ]
            }
        ],
        isMulti: true
    },
    {
        name: 'singleselect',
        fieldType: 'select',
        label: 'Single select',
        placeholder: 'Select 1 option',
        schema: external_yup_namespaceObject.object({
            label: external_yup_namespaceObject.string(),
            value: external_yup_namespaceObject.string()
        }).required('Provide a region'),
        options: [
            {
                label: 'Europe',
                options: [
                    {
                        label: 'eu-central-1',
                        value: 'eu-central-1'
                    }
                ]
            },
            {
                label: 'US',
                options: [
                    {
                        label: 'us-east-1',
                        value: 'us-east-1'
                    },
                    {
                        label: 'us-east-2',
                        value: 'us-east-2'
                    }
                ]
            }
        ]
    },
    {
        name: 'columnSelect',
        fieldType: 'columnSelect',
        label: 'Column select',
        placeholder: 'Select 1 tier',
        schema: external_yup_namespaceObject.object({
            label: external_yup_namespaceObject.string(),
            value: external_yup_namespaceObject.string()
        }).required('Provide a tier'),
        headerColumns: [
            'Tier',
            'Max write',
            'Max read'
        ],
        singleValueText: {
            tier: 'Tier',
            maxWrite: 'max write',
            maxRead: 'max read'
        },
        firstTextPosition: 'left',
        options: [
            {
                label: '1',
                value: '1',
                tier: '1',
                maxWrite: '20 MBps',
                maxRead: '60 MBps'
            },
            {
                label: '2',
                value: '2',
                tier: '2',
                maxWrite: '50 MBps',
                maxRead: '150 MBps'
            },
            {
                label: '3',
                value: '3',
                tier: '3',
                maxWrite: '100 MBps',
                maxRead: '200 MBps'
            },
            {
                label: '4',
                value: '4',
                tier: '4',
                maxWrite: '200 MBps',
                maxRead: '400 MBps'
            },
            {
                label: '5',
                value: '5',
                tier: '5',
                maxWrite: '400 MBps',
                maxRead: '800 MBps'
            },
            {
                label: '6',
                value: '6',
                tier: '6',
                maxWrite: '1 GBps',
                maxRead: '1 GBps'
            },
            {
                label: '7',
                value: '7',
                tier: '7',
                maxWrite: '3 GBps',
                maxRead: '3 GBps'
            },
            {
                label: '8',
                value: '8',
                tier: '8',
                maxWrite: '5 GBps',
                maxRead: '5 GBps'
            },
            {
                label: '9',
                value: '9',
                tier: '9',
                maxWrite: '7 GBps',
                maxRead: '7 GBps'
            }
        ]
    },
    {
        name: 'text',
        fieldType: 'text',
        label: 'Text',
        placeholder: 'Enter your text',
        schema: external_yup_namespaceObject.string().required()
    },
    {
        name: 'displaySection',
        fieldType: 'displaySection',
        label: 'Display Section',
        heading: 'Display Section',
        description: 'Display Section description',
        schema: external_yup_namespaceObject.string().required()
    },
    {
        name: 'passwordField',
        fieldType: 'password',
        placeholder: '12345',
        label: 'password field label',
        schema: external_yup_namespaceObject.string().required()
    }
];
const radioGroupExamples = [
    {
        name: 'radioGroupCardSelectable',
        fieldType: 'radio',
        label: 'radioGroupCardSelectable',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '2',
        options: [
            {
                value: '1',
                label: 'Selectable'
            },
            {
                value: '2',
                label: 'Selected'
            }
        ]
    },
    {
        name: 'radioGroupCardDisabled',
        fieldType: 'radio',
        label: 'radioGroupCardDisabled',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '4',
        options: [
            {
                value: '3',
                label: 'Disabled',
                disabled: true
            },
            {
                value: '4',
                label: 'Disabled + selected',
                disabled: true
            }
        ]
    },
    {
        name: 'radioGroupCardError',
        fieldType: 'radio',
        label: 'radioGroupCardError',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '6',
        options: [
            {
                value: '5',
                label: 'Unselected + error',
                invalid: true
            },
            {
                value: '6',
                label: 'Selected + error',
                invalid: true
            }
        ]
    },
    {
        name: 'radioGroupCircleSelectable',
        fieldType: 'radio',
        radioVariant: 'circle',
        radioStackDirection: 'column',
        label: 'radioGroupCircleSelectable',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '2',
        options: [
            {
                value: '1',
                label: 'Selectable'
            },
            {
                value: '2',
                label: 'Selected'
            }
        ]
    },
    {
        name: 'radioGroupCircleDisabled',
        fieldType: 'radio',
        radioVariant: 'circle',
        radioStackDirection: 'column',
        label: 'radioGroupCircleDisabled',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '4',
        options: [
            {
                value: '3',
                label: 'Disabled',
                disabled: true
            },
            {
                value: '4',
                label: 'Disabled + selected',
                disabled: true
            }
        ]
    },
    {
        name: 'radioGroupCircleError',
        fieldType: 'radio',
        radioVariant: 'circle',
        radioStackDirection: 'column',
        label: 'radioGroupCircleError',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '6',
        options: [
            {
                value: '5',
                label: 'Unselected + error',
                invalid: true
            },
            {
                value: '6',
                label: 'Selected + error',
                invalid: true
            }
        ]
    },
    {
        name: 'radioGroupCircleStackDirectionRow',
        fieldType: 'radio',
        radioVariant: 'circle',
        radioStackDirection: 'row',
        label: 'radioGroupCircleStackDirectionRow',
        placeholder: 'Placeholder',
        description: 'description',
        footerDescription: 'footer description',
        help: 'help text',
        schema: external_yup_namespaceObject.string().required('Select an option'),
        defaultValue: '2',
        options: [
            {
                value: '1',
                label: 'Selectable'
            },
            {
                value: '2',
                label: 'Selected'
            }
        ]
    }
];
const FormFieldExamples = ()=>/*#__PURE__*/ external_react_default().createElement(external_Form_js_default(), {
        onValid: (values)=>console.log('onValid values: ', values),
        onInvalid: (values)=>console.warn('onInvalid values: ', values),
        fields: formFieldExamples,
        button: {
            label: 'confirm_create_cluster_deployment',
            text: 'Next'
        },
        developerView: true
    });
var __webpack_export_target__ = exports;
for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
    value: true
});
