{"version":3,"file":"initFormSchema-D9Eiiizz.js","sources":["../../../../Coloplast.UI/src/shared/utils/initFormSchema.js"],"sourcesContent":["import RichTextHtmlElement from 'shared/components/FormKitBuilderContainer/FormElements/RichTextHtmlElement.vue';\r\nimport { plugin, defaultConfig } from \"@formkit/vue\";\r\nimport { iconCheckmark, iconRadio, iconSearch } from \"@coloplast/design-system/dist/exports/icons\";\r\nimport { createProPlugin, mask, autocomplete, dropdown, taglist } from '@formkit/pro'\r\nimport scrollToErrors from 'multisite/formkit.config';\r\nimport maskLengthValidation from 'shared/components/FormKitBuilderContainer/formkitMask.config'\r\nimport \"@coloplast/design-system/dist/components/formkit/formkit.css\";\r\nimport { generateClasses } from \"@formkit/themes\";\r\n\r\nexport function initFormKitSchema(app) {\r\n\r\n\tconst proPlugin = createProPlugin('fk-570552d805b', {\r\n\t\tmask,\r\n\t\tautocomplete,\r\n\t\tdropdown,\r\n\t\ttaglist\r\n\t});\r\n\r\n\tapp.component('RichTextHtmlElementCmp', RichTextHtmlElement);\r\n\tapp.use(\r\n\t\tplugin,\r\n\t\tdefaultConfig({\r\n\t\t\t/* You'll need to register the design system icons you'd like to use in the FormKit inputs */\r\n\t\t\ticons: {\r\n\t\t\t\tcheck: iconCheckmark,\r\n\t\t\t\tsearch: iconSearch,\r\n checkboxDecorator: iconCheckmark,\r\n radioDecorator: iconRadio,\r\n\t\t\t},\r\n\t\t\tplugins: [proPlugin, scrollToErrors, maskLengthValidation],\r\n\t\t\tconfig: {\r\n\t\t\t\tclasses: generateClasses({\r\n\t\t\t\t\t/* We reset button and submit styles, and instead point them to the design system button classes */\r\n\t\t\t\t\tbutton: {\r\n\t\t\t\t\t\tinput: \"$reset ds-button ds-button--primary\",\r\n\t\t\t\t\t},\r\n\t\t\t\t\tsubmit: {\r\n\t\t\t\t\t\tinput: \"$reset ds-button ds-button--primary\",\r\n\t\t\t\t\t},\r\n\t\t\t\t}),\r\n\t\t\t}\r\n\t\t}),\r\n\t);\r\n}\r\n\r\n"],"names":["initFormKitSchema","app","proPlugin","createProPlugin","mask","autocomplete","dropdown","taglist","RichTextHtmlElement","plugin","defaultConfig","iconCheckmark","iconSearch","iconRadio","scrollToErrors","maskLengthValidation","generateClasses"],"mappings":"sKASO,SAASA,EAAkBC,EAAK,CAEtC,MAAMC,EAAYC,EAAgB,iBAAkB,CACrD,KAAEC,EACF,aAAEC,EACF,SAAEC,EACF,QAAEC,CACF,CAAE,EAEDN,EAAI,UAAU,yBAA0BO,CAAmB,EAC3DP,EAAI,IACHQ,EACAC,EAAc,CAEb,MAAO,CACN,MAAOC,EACP,OAAQC,EACI,kBAAmBD,EACnB,eAAgBE,CAC5B,EACD,QAAS,CAACX,EAAWY,EAAgBC,CAAoB,EACzD,OAAQ,CACP,QAASC,EAAgB,CAExB,OAAQ,CACP,MAAO,qCACP,EACD,OAAQ,CACP,MAAO,qCACP,CACN,CAAK,CACD,CACJ,CAAG,CACH,CACA"}