@wikicasa-dev/components 1.2.14 → 1.2.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AccessibleSelect.vue_vue_type_script_setup_true_lang-BoZC-MRc.cjs +1 -0
- package/dist/AccessibleSelect.vue_vue_type_script_setup_true_lang-cO2THN1r.js +204 -0
- package/dist/ArrowIcon-BAw-0KtW.js +28 -0
- package/dist/ArrowIcon-p3-glcm0.cjs +1 -0
- package/dist/BaseAccordion.vue_vue_type_script_setup_true_lang-CoE2D2rV.js +19 -0
- package/dist/BaseAccordion.vue_vue_type_script_setup_true_lang-f0Al20X4.cjs +1 -0
- package/dist/BaseAccordionBtn.vue_vue_type_script_setup_true_lang-B5N_3-gi.js +54 -0
- package/dist/BaseAccordionBtn.vue_vue_type_script_setup_true_lang-D9D4w7Mn.cjs +1 -0
- package/dist/BaseAccordionContent.vue_vue_type_script_setup_true_lang-N7oILwdv.js +32 -0
- package/dist/BaseAccordionContent.vue_vue_type_script_setup_true_lang-U3YQw0dV.cjs +1 -0
- package/dist/BaseAccordionItem.vue_vue_type_script_setup_true_lang-34wcOXN7.js +106 -0
- package/dist/BaseAccordionItem.vue_vue_type_script_setup_true_lang-CkRPO2NI.cjs +1 -0
- package/dist/BaseAutocomplete.vue_vue_type_script_setup_true_lang-CVOeKK-H.js +173 -0
- package/dist/BaseAutocomplete.vue_vue_type_script_setup_true_lang-LiuIZMOu.cjs +1 -0
- package/dist/BaseButton.vue_vue_type_script_setup_true_lang-8iapE8e5.cjs +1 -0
- package/dist/BaseButton.vue_vue_type_script_setup_true_lang-hyGBRoUS.js +75 -0
- package/dist/BaseDropDown.vue_vue_type_script_setup_true_lang-BdoYFj6h.cjs +1 -0
- package/dist/BaseDropDown.vue_vue_type_script_setup_true_lang-t-jias47.js +111 -0
- package/dist/CheckboxGroup.vue_vue_type_script_setup_true_lang-B28hp87l.js +93 -0
- package/dist/CheckboxGroup.vue_vue_type_script_setup_true_lang-BkB2KUyO.cjs +1 -0
- package/dist/CloseIcon-B0iqXdWk.cjs +1 -0
- package/dist/CloseIcon-o6CokGLA.js +38 -0
- package/dist/DefaultValues-S0CTWW-b.cjs +1 -0
- package/dist/DefaultValues-k7iQWtC2.js +9 -0
- package/dist/IntersectionObservable.vue_vue_type_script_setup_true_lang-D3wBzHZD.js +24 -0
- package/dist/IntersectionObservable.vue_vue_type_script_setup_true_lang-JNuYyviS.cjs +1 -0
- package/dist/IntersectionObserver.vue_vue_type_script_setup_true_lang-Bwf1jUFo.cjs +1 -0
- package/dist/IntersectionObserver.vue_vue_type_script_setup_true_lang-CQHjzQc3.js +52 -0
- package/dist/SelectItem.vue_vue_type_script_setup_true_lang-3ie26G8n.cjs +1 -0
- package/dist/SelectItem.vue_vue_type_script_setup_true_lang-BOLdDTLM.js +42 -0
- package/dist/SwiperCarousel.vue_vue_type_style_index_0_lang-CQsYG4_e.cjs +5 -0
- package/dist/SwiperCarousel.vue_vue_type_style_index_0_lang-DUANcQKT.js +716 -0
- package/dist/_plugin-vue_export-helper-BHFhmbuH.cjs +1 -0
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
- package/dist/autoplay-Dyvby5gX.cjs +1 -0
- package/dist/controller-Dyvby5gX.cjs +1 -0
- package/dist/free-mode-Dyvby5gX.cjs +1 -0
- package/dist/{index-1oh628Cu.js → index-6DJ6N4f8.js} +2 -2
- package/dist/index-Dz30IWWY.cjs +1 -0
- package/dist/lib/UIKit/AccessibleSelect.cjs +1 -0
- package/dist/lib/UIKit/AccessibleSelect.js +4 -0
- package/dist/lib/UIKit/Accordion/BaseAccordion.cjs +1 -0
- package/dist/lib/UIKit/Accordion/BaseAccordion.js +4 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionBtn.cjs +1 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionBtn.js +4 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionContent.cjs +1 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionContent.js +4 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionItem.cjs +1 -0
- package/dist/lib/UIKit/Accordion/BaseAccordionItem.js +4 -0
- package/dist/lib/UIKit/BaseAlert.cjs +1 -0
- package/dist/lib/UIKit/BaseAlert.js +23 -0
- package/dist/lib/UIKit/BaseAutocomplete.cjs +1 -0
- package/dist/lib/UIKit/BaseAutocomplete.js +4 -0
- package/dist/lib/UIKit/BaseBadge.cjs +1 -0
- package/dist/lib/UIKit/BaseBadge.js +20 -0
- package/dist/lib/UIKit/BaseBtModal.cjs +1 -0
- package/dist/lib/UIKit/BaseBtModal.js +179 -0
- package/dist/lib/UIKit/BaseBtModal.vue.d.ts +172 -0
- package/dist/lib/UIKit/BaseButton.cjs +1 -0
- package/dist/lib/UIKit/BaseButton.js +4 -0
- package/dist/lib/UIKit/BaseCard.cjs +1 -0
- package/dist/lib/UIKit/BaseCard.js +33 -0
- package/dist/lib/UIKit/BaseComplexToggle.cjs +1 -0
- package/dist/lib/UIKit/BaseComplexToggle.js +139 -0
- package/dist/lib/UIKit/BaseDropDown.cjs +1 -0
- package/dist/lib/UIKit/BaseDropDown.js +4 -0
- package/dist/lib/UIKit/BaseFloatingLabel.cjs +1 -0
- package/dist/lib/UIKit/BaseFloatingLabel.js +48 -0
- package/dist/lib/UIKit/BaseIcon.cjs +1 -0
- package/dist/lib/UIKit/BaseIcon.js +40 -0
- package/dist/lib/UIKit/BaseInput.cjs +1 -0
- package/dist/lib/UIKit/BaseInput.js +276 -0
- package/dist/{src → lib}/UIKit/BaseInput.vue.d.ts +3 -3
- package/dist/lib/UIKit/BaseNavItem.cjs +1 -0
- package/dist/lib/UIKit/BaseNavItem.js +58 -0
- package/dist/lib/UIKit/BasePagination.cjs +1 -0
- package/dist/lib/UIKit/BasePagination.js +151 -0
- package/dist/lib/UIKit/BasePaper.cjs +1 -0
- package/dist/lib/UIKit/BasePaper.js +14 -0
- package/dist/lib/UIKit/BaseSelect/SelectItem.cjs +1 -0
- package/dist/lib/UIKit/BaseSelect/SelectItem.js +4 -0
- package/dist/lib/UIKit/BaseSlider.cjs +8 -0
- package/dist/lib/UIKit/BaseSlider.js +261 -0
- package/dist/lib/UIKit/BaseSnackbar.cjs +1 -0
- package/dist/lib/UIKit/BaseSnackbar.js +79 -0
- package/dist/lib/UIKit/BaseSnackbar.vue.d.ts +56 -0
- package/dist/lib/UIKit/BaseTab.cjs +1 -0
- package/dist/lib/UIKit/BaseTab.js +78 -0
- package/dist/lib/UIKit/BaseTextarea.cjs +1 -0
- package/dist/lib/UIKit/BaseTextarea.js +142 -0
- package/dist/{src → lib}/UIKit/BaseTextarea.vue.d.ts +2 -2
- package/dist/lib/UIKit/BaseToggle.cjs +1 -0
- package/dist/lib/UIKit/BaseToggle.js +44 -0
- package/dist/lib/UIKit/BaseTooltip.cjs +1 -0
- package/dist/lib/UIKit/BaseTooltip.js +53 -0
- package/dist/lib/UIKit/BaseUploadFile.cjs +1 -0
- package/dist/lib/UIKit/BaseUploadFile.js +70 -0
- package/dist/lib/UIKit/Checkbox/CheckboxBtn.cjs +1 -0
- package/dist/lib/UIKit/Checkbox/CheckboxBtn.js +74 -0
- package/dist/lib/UIKit/Checkbox/CheckboxGroup.cjs +1 -0
- package/dist/lib/UIKit/Checkbox/CheckboxGroup.js +4 -0
- package/dist/lib/UIKit/Radio/RadioButton.cjs +1 -0
- package/dist/lib/UIKit/Radio/RadioButton.js +59 -0
- package/dist/lib/UIKit/Radio/RadioGroup.cjs +1 -0
- package/dist/lib/UIKit/Radio/RadioGroup.js +66 -0
- package/dist/lib/UIKit/StaticSpinner.cjs +1 -0
- package/dist/lib/UIKit/StaticSpinner.js +31 -0
- package/dist/lib/components/IntersectionObserver/IntersectionObservable.cjs +1 -0
- package/dist/lib/components/IntersectionObserver/IntersectionObservable.js +4 -0
- package/dist/lib/components/IntersectionObserver/IntersectionObserver.cjs +1 -0
- package/dist/lib/components/IntersectionObserver/IntersectionObserver.js +4 -0
- package/dist/lib/components/carousel/SwiperCarousel.cjs +1 -0
- package/dist/lib/components/carousel/SwiperCarousel.js +4 -0
- package/dist/lib/composables/useBreakpoints.cjs +1 -0
- package/dist/lib/composables/useBreakpoints.js +21 -0
- package/dist/lib/composables/useFloatingLabel.cjs +1 -0
- package/dist/lib/composables/useFloatingLabel.js +33 -0
- package/dist/lib/composables/useKeyboardController.cjs +1 -0
- package/dist/lib/composables/useKeyboardController.js +41 -0
- package/dist/lib/index.cjs +1 -0
- package/dist/lib/index.js +66 -0
- package/dist/navigation-Dyvby5gX.cjs +1 -0
- package/dist/pagination-Dyvby5gX.cjs +1 -0
- package/dist/poppins/poppins-v13-latin-300.eot +0 -0
- package/dist/poppins/poppins-v13-latin-300.svg +321 -0
- package/dist/poppins/poppins-v13-latin-300.ttf +0 -0
- package/dist/poppins/poppins-v13-latin-300.woff +0 -0
- package/dist/poppins/poppins-v13-latin-300.woff2 +0 -0
- package/dist/poppins/poppins-v13-latin-500.eot +0 -0
- package/dist/poppins/poppins-v13-latin-500.svg +323 -0
- package/dist/poppins/poppins-v13-latin-500.ttf +0 -0
- package/dist/poppins/poppins-v13-latin-500.woff +0 -0
- package/dist/poppins/poppins-v13-latin-500.woff2 +0 -0
- package/dist/poppins/poppins-v13-latin-600.eot +0 -0
- package/dist/poppins/poppins-v13-latin-600.svg +322 -0
- package/dist/poppins/poppins-v13-latin-600.ttf +0 -0
- package/dist/poppins/poppins-v13-latin-600.woff +0 -0
- package/dist/poppins/poppins-v13-latin-600.woff2 +0 -0
- package/dist/poppins/poppins-v13-latin-regular.eot +0 -0
- package/dist/poppins/poppins-v13-latin-regular.svg +323 -0
- package/dist/poppins/poppins-v13-latin-regular.ttf +0 -0
- package/dist/poppins/poppins-v13-latin-regular.woff +0 -0
- package/dist/poppins/poppins-v13-latin-regular.woff2 +0 -0
- package/dist/style.css +1 -1
- package/dist/thumbs-Dyvby5gX.cjs +1 -0
- package/dist/utilities-CBCDB5EB.js +1558 -0
- package/dist/utilities-gwVlEyWn.cjs +3 -0
- package/package.json +4 -3
- package/dist/components.js +0 -35
- package/dist/components.umd.cjs +0 -14
- package/dist/index-BYiujdKM.js +0 -4872
- package/dist/src/components/Pera.stories.d.ts +0 -6
- package/dist/src/components/base/BaseEmptyButton.stories.d.ts +0 -6
- package/dist/src/components/base/StaticSpinner.stories.d.ts +0 -6
- package/dist/src/components/input/TripleSelect.stories.d.ts +0 -6
- package/dist/src/components/insert/QualityScore.stories.d.ts +0 -6
- package/dist/src/stories/Button.stories.d.ts +0 -63
- package/dist/src/stories/Header.stories.d.ts +0 -66
- package/dist/src/stories/Page.stories.d.ts +0 -19
- package/dist/src/svgIcons/AboutUsIcon.d.ts +0 -3
- package/dist/src/svgIcons/ArrowIcon.d.ts +0 -3
- package/dist/src/svgIcons/BarChartIcon.d.ts +0 -3
- package/dist/src/svgIcons/BellIcon.d.ts +0 -3
- package/dist/src/svgIcons/BulbIcon.d.ts +0 -3
- package/dist/src/svgIcons/CloseIcon.d.ts +0 -3
- package/dist/src/svgIcons/DefaultValues.d.ts +0 -8
- package/dist/src/svgIcons/DeleteIcon.d.ts +0 -3
- package/dist/src/svgIcons/DrawIcon.d.ts +0 -3
- package/dist/src/svgIcons/GermanyFlagIcon.d.ts +0 -3
- package/dist/src/svgIcons/HeartIcon.d.ts +0 -3
- package/dist/src/svgIcons/HidePswIcon.d.ts +0 -3
- package/dist/src/svgIcons/ItalyFlagIcon.d.ts +0 -3
- package/dist/src/svgIcons/LocationIcon.d.ts +0 -3
- package/dist/src/svgIcons/LogoutIcon.d.ts +0 -3
- package/dist/src/svgIcons/MailIcon.d.ts +0 -3
- package/dist/src/svgIcons/MapIcon.d.ts +0 -3
- package/dist/src/svgIcons/NewsIcon.d.ts +0 -3
- package/dist/src/svgIcons/NotesIcon.d.ts +0 -3
- package/dist/src/svgIcons/PhoneIcon.d.ts +0 -3
- package/dist/src/svgIcons/PhotoIcon.d.ts +0 -3
- package/dist/src/svgIcons/PinIcon.d.ts +0 -3
- package/dist/src/svgIcons/PlanIcon.d.ts +0 -3
- package/dist/src/svgIcons/PlusIcon.d.ts +0 -3
- package/dist/src/svgIcons/PrestigeIcon.d.ts +0 -3
- package/dist/src/svgIcons/PrintIcon.d.ts +0 -3
- package/dist/src/svgIcons/ProfileIcon.d.ts +0 -3
- package/dist/src/svgIcons/QuotesIcon.d.ts +0 -3
- package/dist/src/svgIcons/RequestIcon.d.ts +0 -3
- package/dist/src/svgIcons/SearchIcon.d.ts +0 -3
- package/dist/src/svgIcons/ShareIcon.d.ts +0 -3
- package/dist/src/svgIcons/SuitcaseIcon.d.ts +0 -3
- package/dist/src/svgIcons/TieIcon.d.ts +0 -3
- package/dist/src/svgIcons/TourIcon.d.ts +0 -3
- package/dist/src/svgIcons/UkFlagIcon.d.ts +0 -3
- package/dist/src/svgIcons/ValuationIcon.d.ts +0 -3
- package/dist/src/svgIcons/VideoIcon.d.ts +0 -3
- package/dist/src/svgIcons/ViewPswIcon.d.ts +0 -3
- package/dist/src/svgIcons/WarningIcon.d.ts +0 -3
- package/dist/src/svgIcons/WarningIconRounded.d.ts +0 -3
- package/dist/src/svgIcons/WikiNerdIcon.d.ts +0 -3
- package/dist/src/svgIcons/WkAppIcon.d.ts +0 -3
- package/dist/vite.config.d.ts +0 -2
- package/dist/{src → lib}/UIKit/AccessibleSelect.vue.d.ts +2 -2
- package/dist/{src → lib}/UIKit/Accordion/BaseAccordion.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/Accordion/BaseAccordionBtn.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/Accordion/BaseAccordionContent.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/Accordion/BaseAccordionItem.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/BaseAlert.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseAutocomplete.vue.d.ts +9 -9
- package/dist/{src → lib}/UIKit/BaseBadge.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseButton.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseCard.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseComplexToggle.vue.d.ts +2 -2
- package/dist/{src → lib}/UIKit/BaseDropDown.vue.d.ts +2 -2
- package/dist/{src → lib}/UIKit/BaseFloatingLabel.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/BaseIcon.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseNavItem.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BasePagination.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BasePaper.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseSelect/SelectItem.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/BaseSlider.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseTab.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/BaseToggle.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/BaseTooltip.vue.d.ts +1 -1
- package/dist/{src → lib}/UIKit/BaseUploadFile.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/Checkbox/CheckboxBtn.vue.d.ts +2 -2
- package/dist/{src → lib}/UIKit/Checkbox/CheckboxGroup.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/Radio/RadioButton.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/Radio/RadioGroup.vue.d.ts +0 -0
- package/dist/{src → lib}/UIKit/StaticSpinner.vue.d.ts +1 -1
- /package/dist/{src → lib}/components/IntersectionObserver/IntersectionObservable.vue.d.ts +0 -0
- /package/dist/{src → lib}/components/IntersectionObserver/IntersectionObserver.vue.d.ts +0 -0
- /package/dist/{src → lib}/components/carousel/SwiperCarousel.vue.d.ts +0 -0
- /package/dist/{src → lib}/composables/useBreakpoints.d.ts +0 -0
- /package/dist/{src → lib}/composables/useFloatingLabel.d.ts +0 -0
- /package/dist/{src → lib}/composables/useKeyboardController.d.ts +0 -0
- /package/dist/{src → lib}/index.d.ts +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const t=require("vue"),o=require("../../_plugin-vue_export-helper-BHFhmbuH.cjs"),a=t.defineComponent({name:"BaseComplexToggle",props:{labels:{type:Object,required:!0},modelValue:{type:String,default:""},type:{type:String,default:"full"},mode:{type:String,default:""},btnBgColor:{type:String,default:"uikit-bg-w-lavender-bordered"},borderContainerColor:{type:String||"uikit-border-w-secondary",default:"uikit-border-w-secondary"}},emits:["update:modelValue"],data(){return{texActiveToggleColor:"uikit-text-white"}},computed:{leftBtn(){return this.$refs.leftBtn},rightBtn(){return this.$refs.rightBtn},dynamicBg(){return this.$refs.dynamicBg}},created(){["uikit-bg-w-cultured-bordered","uikit-bg-w-gray","uikit-bg-w-warning","uikit-bg-w-lavender-bordered"].includes(this.btnBgColor)&&(this.texActiveToggleColor="uikit-text-w-black")},mounted(){this.btnBgColor&&(this.labels.leftToggle.checked?(this.moveDynamicBgToLeft(),this.emitLeftLabel()):this.labels.rightToggle.checked&&(this.moveDynamicBgToRight(),this.emitRightLabel()))},methods:{handleToggle(e){!this.leftBtn||!this.rightBtn||(e==="left-btn"?(this.moveDynamicBgToLeft(),this.$emit("update:modelValue",this.labels.leftToggle.label)):(this.moveDynamicBgToRight(),this.$emit("update:modelValue",this.labels.rightToggle.label)))},moveDynamicBgToLeft(){this.dynamicBg?.classList.remove("translateX-right"),this.dynamicBg?.classList.add("translateX-left"),this.leftBtn?.classList.add("base-complex-toggle-active",this.texActiveToggleColor),this.rightBtn?.classList.remove("base-complex-toggle-active",this.texActiveToggleColor)},moveDynamicBgToRight(){this.dynamicBg?.classList.remove("translateX-left"),this.dynamicBg?.classList.add("translateX-right"),this.rightBtn?.classList.add("base-complex-toggle-active",this.texActiveToggleColor),this.leftBtn?.classList.remove("base-complex-toggle-active",this.texActiveToggleColor)},emitLeftLabel(){this.$emit("update:modelValue",this.labels.leftToggle.label)},emitRightLabel(){this.$emit("update:modelValue",this.labels.rightToggle.label)}}}),s=["id","data-cy"],r=["data-cy"],g=["src","alt"],n=["innerHTML"],c=["data-cy"],d=["src","alt"],u=["innerHTML"];function h(e,l,b,f,p,k){return t.openBlock(),t.createElementBlock("div",{id:e.$attrs.id||"","data-cy":e.$attrs["data-cy"]||"",class:t.normalizeClass(["base-complex-toggle uikit-relative uikit-flex uikit-justify-center uikit-p-0",[e.mode,e.borderContainerColor]])},[t.createElementVNode("div",{ref:"leftBtn","data-cy":`bct-left-btn${e.labels.leftToggle.label?`-${e.labels.leftToggle.label}`:""}`,class:"left-button uikit-flex uikit-flex-1 uikit-items-center uikit-justify-center hover:uikit-cursor-pointer",onClick:l[0]||(l[0]=t.withModifiers(i=>e.handleToggle("left-btn"),["stop"]))},[e.labels.leftToggle.icon?(t.openBlock(),t.createElementBlock("img",{key:0,class:"base-complex-toggle-icon uikit-relative uikit-z-10 uikit-mr-10px",src:e.labels.leftToggle.icon.src,alt:e.labels.leftToggle.icon.alt,width:"15",height:"15"},null,8,g)):t.createCommentVNode("",!0),t.createElementVNode("span",{ref:"leftToggleLabel",class:"base-complex-toggle-label uikit-relative uikit-z-10",innerHTML:e.labels.leftToggle.label},null,8,n)],8,r),t.createElementVNode("div",{ref:"rightBtn","data-cy":`bct-right-btn${e.labels.rightToggle.label?`-${e.labels.rightToggle.label}`:""}`,class:"right-button uikit-flex uikit-flex-1 uikit-items-center uikit-justify-center hover:uikit-cursor-pointer",onClick:l[1]||(l[1]=t.withModifiers(i=>e.handleToggle("right-btn"),["stop"]))},[e.labels.rightToggle.icon?(t.openBlock(),t.createElementBlock("img",{key:0,class:"base-complex-toggle-icon uikit-relative uikit-z-10 uikit-mr-10px",src:e.labels.rightToggle.icon.src,alt:e.labels.rightToggle.icon.alt,width:"15",height:"15"},null,8,d)):t.createCommentVNode("",!0),t.createElementVNode("span",{ref:"rightToggleLabel",class:"base-complex-toggle-label uikit-relative uikit-z-10",innerHTML:e.labels.rightToggle.label},null,8,u)],8,c),t.createElementVNode("div",{ref:"dynamicBg",class:t.normalizeClass(["uikit-absolute uikit-transition-all uikit-duration-200 uikit-ease-out",[e.type==="full"?"base-complex-toggle-active-bg":"base-complex-toggle-active-padded-bg",e.btnBgColor,e.mode]])},null,2)],10,s)}const m=o._export_sfc(a,[["render",h],["__scopeId","data-v-43af3dd4"]]);module.exports=m;
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
import { defineComponent as n, openBlock as l, createElementBlock as o, normalizeClass as a, createElementVNode as t, withModifiers as s, createCommentVNode as r } from "vue";
|
|
2
|
+
import { _ as d } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
const c = n({
|
|
4
|
+
name: "BaseComplexToggle",
|
|
5
|
+
props: {
|
|
6
|
+
labels: {
|
|
7
|
+
type: Object,
|
|
8
|
+
required: !0
|
|
9
|
+
},
|
|
10
|
+
modelValue: { type: String, default: "" },
|
|
11
|
+
type: { type: String, default: "full" },
|
|
12
|
+
mode: { type: String, default: "" },
|
|
13
|
+
btnBgColor: {
|
|
14
|
+
type: String,
|
|
15
|
+
default: "uikit-bg-w-lavender-bordered"
|
|
16
|
+
},
|
|
17
|
+
borderContainerColor: {
|
|
18
|
+
type: String || "uikit-border-w-secondary",
|
|
19
|
+
default: "uikit-border-w-secondary"
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
emits: ["update:modelValue"],
|
|
23
|
+
data() {
|
|
24
|
+
return {
|
|
25
|
+
texActiveToggleColor: "uikit-text-white"
|
|
26
|
+
};
|
|
27
|
+
},
|
|
28
|
+
computed: {
|
|
29
|
+
leftBtn() {
|
|
30
|
+
return this.$refs.leftBtn;
|
|
31
|
+
},
|
|
32
|
+
rightBtn() {
|
|
33
|
+
return this.$refs.rightBtn;
|
|
34
|
+
},
|
|
35
|
+
dynamicBg() {
|
|
36
|
+
return this.$refs.dynamicBg;
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
created() {
|
|
40
|
+
[
|
|
41
|
+
"uikit-bg-w-cultured-bordered",
|
|
42
|
+
"uikit-bg-w-gray",
|
|
43
|
+
"uikit-bg-w-warning",
|
|
44
|
+
"uikit-bg-w-lavender-bordered"
|
|
45
|
+
].includes(this.btnBgColor) && (this.texActiveToggleColor = "uikit-text-w-black");
|
|
46
|
+
},
|
|
47
|
+
mounted() {
|
|
48
|
+
this.btnBgColor && (this.labels.leftToggle.checked ? (this.moveDynamicBgToLeft(), this.emitLeftLabel()) : this.labels.rightToggle.checked && (this.moveDynamicBgToRight(), this.emitRightLabel()));
|
|
49
|
+
},
|
|
50
|
+
methods: {
|
|
51
|
+
handleToggle(e) {
|
|
52
|
+
!this.leftBtn || !this.rightBtn || (e === "left-btn" ? (this.moveDynamicBgToLeft(), this.$emit("update:modelValue", this.labels.leftToggle.label)) : (this.moveDynamicBgToRight(), this.$emit("update:modelValue", this.labels.rightToggle.label)));
|
|
53
|
+
},
|
|
54
|
+
moveDynamicBgToLeft() {
|
|
55
|
+
this.dynamicBg?.classList.remove("translateX-right"), this.dynamicBg?.classList.add("translateX-left"), this.leftBtn?.classList.add(
|
|
56
|
+
"base-complex-toggle-active",
|
|
57
|
+
this.texActiveToggleColor
|
|
58
|
+
), this.rightBtn?.classList.remove(
|
|
59
|
+
"base-complex-toggle-active",
|
|
60
|
+
this.texActiveToggleColor
|
|
61
|
+
);
|
|
62
|
+
},
|
|
63
|
+
moveDynamicBgToRight() {
|
|
64
|
+
this.dynamicBg?.classList.remove("translateX-left"), this.dynamicBg?.classList.add("translateX-right"), this.rightBtn?.classList.add(
|
|
65
|
+
"base-complex-toggle-active",
|
|
66
|
+
this.texActiveToggleColor
|
|
67
|
+
), this.leftBtn?.classList.remove(
|
|
68
|
+
"base-complex-toggle-active",
|
|
69
|
+
this.texActiveToggleColor
|
|
70
|
+
);
|
|
71
|
+
},
|
|
72
|
+
emitLeftLabel() {
|
|
73
|
+
this.$emit("update:modelValue", this.labels.leftToggle.label);
|
|
74
|
+
},
|
|
75
|
+
emitRightLabel() {
|
|
76
|
+
this.$emit("update:modelValue", this.labels.rightToggle.label);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}), u = ["id", "data-cy"], h = ["data-cy"], b = ["src", "alt"], m = ["innerHTML"], f = ["data-cy"], p = ["src", "alt"], k = ["innerHTML"];
|
|
80
|
+
function T(e, i, v, y, B, L) {
|
|
81
|
+
return l(), o("div", {
|
|
82
|
+
id: e.$attrs.id || "",
|
|
83
|
+
"data-cy": e.$attrs["data-cy"] || "",
|
|
84
|
+
class: a(["base-complex-toggle uikit-relative uikit-flex uikit-justify-center uikit-p-0", [e.mode, e.borderContainerColor]])
|
|
85
|
+
}, [
|
|
86
|
+
t("div", {
|
|
87
|
+
ref: "leftBtn",
|
|
88
|
+
"data-cy": `bct-left-btn${e.labels.leftToggle.label ? `-${e.labels.leftToggle.label}` : ""}`,
|
|
89
|
+
class: "left-button uikit-flex uikit-flex-1 uikit-items-center uikit-justify-center hover:uikit-cursor-pointer",
|
|
90
|
+
onClick: i[0] || (i[0] = s((g) => e.handleToggle("left-btn"), ["stop"]))
|
|
91
|
+
}, [
|
|
92
|
+
e.labels.leftToggle.icon ? (l(), o("img", {
|
|
93
|
+
key: 0,
|
|
94
|
+
class: "base-complex-toggle-icon uikit-relative uikit-z-10 uikit-mr-10px",
|
|
95
|
+
src: e.labels.leftToggle.icon.src,
|
|
96
|
+
alt: e.labels.leftToggle.icon.alt,
|
|
97
|
+
width: "15",
|
|
98
|
+
height: "15"
|
|
99
|
+
}, null, 8, b)) : r("", !0),
|
|
100
|
+
t("span", {
|
|
101
|
+
ref: "leftToggleLabel",
|
|
102
|
+
class: "base-complex-toggle-label uikit-relative uikit-z-10",
|
|
103
|
+
innerHTML: e.labels.leftToggle.label
|
|
104
|
+
}, null, 8, m)
|
|
105
|
+
], 8, h),
|
|
106
|
+
t("div", {
|
|
107
|
+
ref: "rightBtn",
|
|
108
|
+
"data-cy": `bct-right-btn${e.labels.rightToggle.label ? `-${e.labels.rightToggle.label}` : ""}`,
|
|
109
|
+
class: "right-button uikit-flex uikit-flex-1 uikit-items-center uikit-justify-center hover:uikit-cursor-pointer",
|
|
110
|
+
onClick: i[1] || (i[1] = s((g) => e.handleToggle("right-btn"), ["stop"]))
|
|
111
|
+
}, [
|
|
112
|
+
e.labels.rightToggle.icon ? (l(), o("img", {
|
|
113
|
+
key: 0,
|
|
114
|
+
class: "base-complex-toggle-icon uikit-relative uikit-z-10 uikit-mr-10px",
|
|
115
|
+
src: e.labels.rightToggle.icon.src,
|
|
116
|
+
alt: e.labels.rightToggle.icon.alt,
|
|
117
|
+
width: "15",
|
|
118
|
+
height: "15"
|
|
119
|
+
}, null, 8, p)) : r("", !0),
|
|
120
|
+
t("span", {
|
|
121
|
+
ref: "rightToggleLabel",
|
|
122
|
+
class: "base-complex-toggle-label uikit-relative uikit-z-10",
|
|
123
|
+
innerHTML: e.labels.rightToggle.label
|
|
124
|
+
}, null, 8, k)
|
|
125
|
+
], 8, f),
|
|
126
|
+
t("div", {
|
|
127
|
+
ref: "dynamicBg",
|
|
128
|
+
class: a(["uikit-absolute uikit-transition-all uikit-duration-200 uikit-ease-out", [
|
|
129
|
+
e.type === "full" ? "base-complex-toggle-active-bg" : "base-complex-toggle-active-padded-bg",
|
|
130
|
+
e.btnBgColor,
|
|
131
|
+
e.mode
|
|
132
|
+
]])
|
|
133
|
+
}, null, 2)
|
|
134
|
+
], 10, u);
|
|
135
|
+
}
|
|
136
|
+
const w = /* @__PURE__ */ d(c, [["render", T], ["__scopeId", "data-v-43af3dd4"]]);
|
|
137
|
+
export {
|
|
138
|
+
w as default
|
|
139
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("../../BaseDropDown.vue_vue_type_script_setup_true_lang-BdoYFj6h.cjs");module.exports=e._sfc_main;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),l=require("../../_plugin-vue_export-helper-BHFhmbuH.cjs"),a=e.defineComponent({name:"BaseFloatingLabel",props:{labelState:{type:String,default:()=>"inline-label"},isValid:{type:Boolean,default:()=>null},labelText:{type:String,required:!0},disabled:{type:[String,Boolean],default:!1}},emits:["click"]}),s=["for"],n=["innerHTML"];function o(t,i,u,d,p,c){return e.openBlock(),e.createElementBlock("label",{for:t.$attrs.for,class:e.normalizeClass(["uikit-absolute uikit-left-15px uikit-h-5",[t.labelState,{"uikit-text-w-secondary":t.disabled},t.$attrs["label-classes"]]]),onClick:i[0]||(i[0]=e.withModifiers(k=>t.$emit("click"),["stop"]))},[e.createElementVNode("span",{class:e.normalizeClass(["uikit-text uikit-font-medium uikit-text-w-black",{"!uikit-text-w-secondary":t.disabled}]),innerHTML:t.labelText},null,10,n),t.$attrs.required?(e.openBlock(),e.createElementBlock("sup",{key:0,class:e.normalizeClass(["-uikit-top-[0.3rem] uikit-text uikit-text-w-primary",{"uikit-text-w-secondary":t.disabled}])}," *",2)):e.createCommentVNode("",!0)],10,s)}const r=l._export_sfc(a,[["render",o],["__scopeId","data-v-43f9c9a0"]]);module.exports=r;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { defineComponent as s, openBlock as a, createElementBlock as l, normalizeClass as t, withModifiers as o, createElementVNode as n, createCommentVNode as r } from "vue";
|
|
2
|
+
import { _ as d } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
const u = s({
|
|
4
|
+
name: "BaseFloatingLabel",
|
|
5
|
+
props: {
|
|
6
|
+
labelState: {
|
|
7
|
+
type: String,
|
|
8
|
+
default: () => "inline-label"
|
|
9
|
+
},
|
|
10
|
+
isValid: {
|
|
11
|
+
type: Boolean,
|
|
12
|
+
default: () => null
|
|
13
|
+
},
|
|
14
|
+
labelText: {
|
|
15
|
+
type: String,
|
|
16
|
+
required: !0
|
|
17
|
+
},
|
|
18
|
+
disabled: {
|
|
19
|
+
type: [String, Boolean],
|
|
20
|
+
default: !1
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
emits: ["click"]
|
|
24
|
+
}), p = ["for"], f = ["innerHTML"];
|
|
25
|
+
function k(e, i, c, m, b, y) {
|
|
26
|
+
return a(), l("label", {
|
|
27
|
+
for: e.$attrs.for,
|
|
28
|
+
class: t(["uikit-absolute uikit-left-15px uikit-h-5", [
|
|
29
|
+
e.labelState,
|
|
30
|
+
{ "uikit-text-w-secondary": e.disabled },
|
|
31
|
+
e.$attrs["label-classes"]
|
|
32
|
+
]]),
|
|
33
|
+
onClick: i[0] || (i[0] = o(($) => e.$emit("click"), ["stop"]))
|
|
34
|
+
}, [
|
|
35
|
+
n("span", {
|
|
36
|
+
class: t(["uikit-text uikit-font-medium uikit-text-w-black", { "!uikit-text-w-secondary": e.disabled }]),
|
|
37
|
+
innerHTML: e.labelText
|
|
38
|
+
}, null, 10, f),
|
|
39
|
+
e.$attrs.required ? (a(), l("sup", {
|
|
40
|
+
key: 0,
|
|
41
|
+
class: t(["-uikit-top-[0.3rem] uikit-text uikit-text-w-primary", { "uikit-text-w-secondary": e.disabled }])
|
|
42
|
+
}, " *", 2)) : r("", !0)
|
|
43
|
+
], 10, p);
|
|
44
|
+
}
|
|
45
|
+
const g = /* @__PURE__ */ d(u, [["render", k], ["__scopeId", "data-v-43f9c9a0"]]);
|
|
46
|
+
export {
|
|
47
|
+
g as default
|
|
48
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const t=require("vue"),a=require("../../_plugin-vue_export-helper-BHFhmbuH.cjs"),i=t.defineComponent({name:"BaseIcon",props:{lazyLoading:{type:Boolean,default:!1},altAttribute:{type:String,default:""},iconName:{type:String,default:""},iconType:{type:String,default:"icon-md"},iconClass:{type:String,default:"uikit-mr-5px"}}}),n=["id","alt","src","width","height","loading"];function s(e,o,l,d,p,c){return t.openBlock(),t.createElementBlock("img",{id:e.$attrs.id,class:t.normalizeClass(["uikit-inline-block",e.iconType,e.iconClass]),alt:e.altAttribute||e.$attrs.alt,style:t.normalizeStyle(e.$attrs.style),src:e.$attrs.src?e.$attrs.src:"",width:e.$attrs.width,height:e.$attrs.height,loading:e.lazyLoading?"lazy":"eager"},null,14,n)}const r=a._export_sfc(i,[["render",s],["__scopeId","data-v-844863bf"]]);module.exports=r;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { defineComponent as e, openBlock as a, createElementBlock as i, normalizeClass as n, normalizeStyle as o } from "vue";
|
|
2
|
+
import { _ as s } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
const r = e({
|
|
4
|
+
name: "BaseIcon",
|
|
5
|
+
props: {
|
|
6
|
+
lazyLoading: { type: Boolean, default: !1 },
|
|
7
|
+
altAttribute: {
|
|
8
|
+
type: String,
|
|
9
|
+
default: ""
|
|
10
|
+
},
|
|
11
|
+
iconName: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: ""
|
|
14
|
+
},
|
|
15
|
+
iconType: {
|
|
16
|
+
type: String,
|
|
17
|
+
default: "icon-md"
|
|
18
|
+
},
|
|
19
|
+
iconClass: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: "uikit-mr-5px"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}), l = ["id", "alt", "src", "width", "height", "loading"];
|
|
25
|
+
function d(t, p, c, f, m, u) {
|
|
26
|
+
return a(), i("img", {
|
|
27
|
+
id: t.$attrs.id,
|
|
28
|
+
class: n(["uikit-inline-block", t.iconType, t.iconClass]),
|
|
29
|
+
alt: t.altAttribute || t.$attrs.alt,
|
|
30
|
+
style: o(t.$attrs.style),
|
|
31
|
+
src: t.$attrs.src ? t.$attrs.src : "",
|
|
32
|
+
width: t.$attrs.width,
|
|
33
|
+
height: t.$attrs.height,
|
|
34
|
+
loading: t.lazyLoading ? "lazy" : "eager"
|
|
35
|
+
}, null, 14, l);
|
|
36
|
+
}
|
|
37
|
+
const h = /* @__PURE__ */ s(r, [["render", d], ["__scopeId", "data-v-844863bf"]]);
|
|
38
|
+
export {
|
|
39
|
+
h as default
|
|
40
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const d=require("./BaseFloatingLabel.cjs"),p=require("../composables/useFloatingLabel.cjs"),t=require("vue"),k=require("../../_plugin-vue_export-helper-BHFhmbuH.cjs"),b=t.defineComponent({name:"BaseInput",components:{BaseFloatingLabel:d},inheritAttrs:!1,props:{inputClass:{type:[String,Array],required:!1,default:""},inputType:{type:String,default:"text-input"},labelText:{type:String,default:""},border:{type:Boolean,default:!0},radius:{type:Boolean,default:!0},modelValue:{type:[String,Number]},feedback:{type:Object},isValid:{type:Boolean,default:null},auto:{type:Boolean,default:!0},keepFloatingLabel:{type:Boolean,default:!1},formatter:{type:Object,default:null}},emits:["update:modelValue","click","keydown-enter-pressed","focusin","focusout","keydown"],setup(e,i){const{labelState:l,setInitialLabelState:o,handleFocusIn:r,handleFocusOut:u,setInlineLabel:n,setFloatingLabel:a}=p.useFloatingLabel(i.emit);return{labelState:l,setInitialLabelState:o,handleFocusIn:r,handleFocusOut:u,setInlineLabel:n,setFloatingLabel:a}},data(){return{type:"",feedbackObj:{},pointerDownListener:e=>{e.preventDefault()}}},computed:{passwordIcon(){return document?document.querySelector("[data-type='password-icon']"):null}},watch:{feedback(){this.normalizeFeedbackProp()},modelValue(e){if(e){const i=this.$refs.baseInput;if(!i)return;!i.value&&this.formatter&&(e=i.value);const l=this.updateInputValue(i,e);this.$emit("update:modelValue",l)}else this.$refs.baseInput.value="";e!=null&&`${e}`.length>0&&this.auto&&this.labelState!=="floating-label"?this.labelState="floating-label":(e==null||e==null)&&(this.labelState="inline-label")},keepFloatingLabel(e){e?this.setFloatingLabel():this.handleFocusOut(this.modelValue,!0,this.auto)}},created(){this.type=this.$attrs.type,this.normalizeFeedbackProp(),this.setInitialLabelState(this.modelValue)},mounted(){if((this.modelValue!=null||this.modelValue!=null)&&(this.$refs.baseInput.value=`${this.modelValue}`),this.formatter){const e=this.updateInputValue(this.$refs.baseInput,`${this.modelValue}`);this.$emit("update:modelValue",e)}this.setPointerOutListener()},unmounted(){this.passwordIcon?.removeEventListener("pointerdown",this.pointerDownListener)},methods:{select(){this.$refs.baseInput.select()},setPointerOutListener(){if(this.$attrs.type!=="password")return;const e=this.passwordIcon;e&&e.addEventListener("pointerdown",this.pointerDownListener)},handleFloatingLabelClick(){this.$refs.baseInput.focus()},normalizeFeedbackProp(){this.feedback&&(this.feedbackObj=this.feedback,this.feedback.valid&&typeof this.feedback.valid=="string"&&(this.feedbackObj.valid=[this.feedback.valid]),this.feedback.invalid&&typeof this.feedback.invalid=="string"&&(this.feedbackObj.invalid=[this.feedback.invalid]))},updateInputValue(e,i){if(!i)return e.value="","";let l="";return this.formatter&&this.formatter.unFormatFn?l=`${this.formatter.unFormatFn(i)}`:l=i,this.formatter?e.value=this.formatter.formatFn(l):e.value=l,l},handleInputChange({target:e}){if(this.inputType==="select")return;const i=e,l=this.updateInputValue(i,i.value);this.$emit("update:modelValue",l)},handleClick(e){this.$emit("click",e)},handleClean(){this.$emit("update:modelValue",""),this.setInlineLabel()},handleShowPasswd(){this.type==="password"?this.type="text":this.type==="text"&&(this.type="password")}}}),h=["id","data-cy","name","autocomplete","disabled","aria-labelledby","readonly","type","pattern","min","max","maxlength","inputmode","placeholder"],f={key:0,class:"uikit-invisible uikit-float-none uikit-mb-2 uikit-ml-2 uikit-block uikit-h-3 uikit-w-auto uikit-max-w-full uikit-overflow-hidden uikit-whitespace-nowrap uikit-p-0 uikit-text uikit-transition-[max-width] uikit-duration-[50ms] uikit-ease-out"},m=["innerHTML"],$=["innerHTML"],c=["innerHTML"],v={class:"under-label uikit-absolute uikit-text-12"};function y(e,i,l,o,r,u){const n=t.resolveComponent("base-floating-label");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["input-wrapper uikit-relative uikit-inline-block uikit-w-full [&.has-right-icon.is-invalid_.text-input-icon]:uikit-mr-25px [&.has-right-icon.is-valid_.text-input-icon]:uikit-mr-25px",[e.$attrs.class,{"uikit-mt-10px":e.labelText},{"floating-label":e.labelText},e.labelState==="floating-label"?"floating-state":"inline-state",{"has-right-icon":e.$attrs["with-right-icon"]!==void 0?e.$attrs["with-right-icon"]:!!e.$slots.righticon},{"has-left-icon":e.$attrs["with-left-icon"]!==void 0?e.$attrs["with-left-icon"]:!!e.$slots.leftIcon},{"is-invalid":e.isValid===!1,"is-valid":e.isValid}]])},[t.renderSlot(e.$slots,"leftIcon",{},void 0,!0),t.renderSlot(e.$slots,"righticon",{handleClean:e.handleClean,handleShowPasswd:e.handleShowPasswd,curType:e.type},void 0,!0),t.createElementVNode("input",{id:e.$attrs.id,ref:"baseInput","data-cy":e.$attrs["data-cy"],name:e.$attrs.name,class:t.normalizeClass(["uikit-peer uikit-h-[42px] uikit-truncate !uikit-border-none uikit-bg-no-repeat focus:uikit-shadow-none focus:uikit-outline-none",[{"uikit-rounded-xs":e.radius},{"input-element uikit-block uikit-h-12 uikit-w-full uikit-appearance-none uikit-px-4 uikit-py-2 uikit-outline-0":e.inputType==="text-input"},{"uikit-text-w-secondary":e.$attrs.disabled},{"is-invalid invalid-bg !uikit-pr-9":e.isValid===!1,"is-valid valid-bg !uikit-pr-9":e.isValid},{"uikit-pr-[42px]":e.$attrs["with-right-icon"]!==void 0?e.$attrs["with-right-icon"]:!!e.$slots.righticon},{"uikit-pl-[42px]":e.$attrs["with-left-icon"]!==void 0?e.$attrs["with-left-icon"]:!!e.$slots.leftIcon},e.inputClass]]),autocomplete:e.$attrs.autocomplete==="on"?"on":"off",disabled:e.$attrs.disabled,"aria-labelledby":e.$attrs.id,readonly:e.$attrs.readonly,type:e.type,pattern:e.$attrs.pattern,min:e.$attrs.min,max:e.$attrs.max,maxlength:e.$attrs.maxlength,inputmode:e.$attrs.inputmode,placeholder:e.$attrs.placeholder,onClick:i[0]||(i[0]=(...a)=>e.handleClick&&e.handleClick(...a)),onFocusin:i[1]||(i[1]=t.withModifiers(()=>e.handleFocusIn(),["stop"])),onFocusout:i[2]||(i[2]=t.withModifiers(a=>!e.keepFloatingLabel&&e.handleFocusOut(e.modelValue,!1,e.auto),["stop"])),onInput:i[3]||(i[3]=t.withModifiers((...a)=>e.handleInputChange&&e.handleInputChange(...a),["stop"])),onKeydown:[i[4]||(i[4]=t.withKeys(a=>e.$emit("keydown-enter-pressed"),["enter"])),i[5]||(i[5]=a=>e.$emit("keydown",a))]},null,42,h),t.createElementVNode("fieldset",{class:t.normalizeClass(["uikit-pointer-events-none uikit-absolute -uikit-top-[5px] uikit-bottom-0 uikit-left-0 uikit-right-0 uikit-m-0 uikit-h-12 uikit-overflow-hidden uikit-px-2 uikit-py-0 uikit-text-left",[{"uikit-border uikit-border-solid uikit-transition-[border] uikit-duration-100 uikit-ease-out peer-focus:uikit-border-2 peer-focus:uikit-border-w-primary peer-focus:[&.is-invalid]:uikit-border-w-danger":e.border,"uikit-rounded-xs":e.radius,"is-invalid uikit-border-w-danger":e.isValid===!1,"is-valid uikit-border-w-primary":e.isValid,"uikit-border-w-secondary":e.isValid===null&&e.border},{"no-floating-label uikit-top-0":!e.labelText},e.$attrs["fieldset-classes"]]])},[e.labelText?(t.openBlock(),t.createElementBlock("legend",f,[t.createElementVNode("span",{class:t.normalizeClass(["visible-label uikit-opacity-0",[{"uikit-mx-5px":e.labelText},{"uikit-visible uikit-inline-block":e.labelState==="floating-label"},{"uikit-invisible uikit-hidden":e.labelState==="inline-label"}]]),innerHTML:e.labelText},null,10,m)])):t.createCommentVNode("",!0)],2),e.labelText?(t.openBlock(),t.createBlock(n,{key:0,for:e.$attrs.id,"label-text":e.labelText,"label-state":e.labelState,"is-valid":e.isValid,required:e.$attrs.required,disabled:e.$attrs.disabled,"label-classes":e.$attrs["label-classes"],onClick:e.handleFloatingLabelClick},null,8,["for","label-text","label-state","is-valid","required","disabled","label-classes","onClick"])):t.createCommentVNode("",!0),e.isValid===!1?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(e.feedbackObj.invalid,(a,s)=>(t.openBlock(),t.createElementBlock("div",{key:`${e.$attrs.id}_invalid_${s}`,class:"uikit-mt-1 uikit-text-12 uikit-text-w-danger",innerHTML:a},null,8,$))),128)):e.isValid===!0?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:2},t.renderList(e.feedbackObj.valid,(a,s)=>(t.openBlock(),t.createElementBlock("div",{key:`${e.$attrs.id}_valid_${s}`,class:"uikit-mt-1 uikit-text-12 uikit-text-w-primary",innerHTML:a},null,8,c))),128)):t.createCommentVNode("",!0),t.createElementVNode("div",v,[t.renderSlot(e.$slots,"under-label",{},void 0,!0)])],2)}const g=k._export_sfc(b,[["render",y],["__scopeId","data-v-e7a41e1a"]]);module.exports=g;
|
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
import v from "./BaseFloatingLabel.js";
|
|
2
|
+
import { useFloatingLabel as y } from "../composables/useFloatingLabel.js";
|
|
3
|
+
import { defineComponent as w, resolveComponent as g, openBlock as l, createElementBlock as s, normalizeClass as n, renderSlot as d, createElementVNode as o, withModifiers as p, withKeys as V, createCommentVNode as k, createBlock as c, Fragment as m, renderList as $ } from "vue";
|
|
4
|
+
import { _ as I } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
5
|
+
const F = w({
|
|
6
|
+
name: "BaseInput",
|
|
7
|
+
components: { BaseFloatingLabel: v },
|
|
8
|
+
inheritAttrs: !1,
|
|
9
|
+
props: {
|
|
10
|
+
inputClass: { type: [String, Array], required: !1, default: "" },
|
|
11
|
+
inputType: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: "text-input"
|
|
14
|
+
},
|
|
15
|
+
labelText: { type: String, default: "" },
|
|
16
|
+
border: { type: Boolean, default: !0 },
|
|
17
|
+
radius: { type: Boolean, default: !0 },
|
|
18
|
+
modelValue: { type: [String, Number] },
|
|
19
|
+
feedback: { type: Object },
|
|
20
|
+
isValid: { type: Boolean, default: null },
|
|
21
|
+
auto: { type: Boolean, default: !0 },
|
|
22
|
+
keepFloatingLabel: { type: Boolean, default: !1 },
|
|
23
|
+
formatter: {
|
|
24
|
+
type: Object,
|
|
25
|
+
default: null
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
emits: [
|
|
29
|
+
"update:modelValue",
|
|
30
|
+
"click",
|
|
31
|
+
"keydown-enter-pressed",
|
|
32
|
+
"focusin",
|
|
33
|
+
"focusout",
|
|
34
|
+
"keydown"
|
|
35
|
+
],
|
|
36
|
+
setup(e, t) {
|
|
37
|
+
const {
|
|
38
|
+
labelState: a,
|
|
39
|
+
setInitialLabelState: b,
|
|
40
|
+
handleFocusIn: h,
|
|
41
|
+
handleFocusOut: f,
|
|
42
|
+
setInlineLabel: r,
|
|
43
|
+
setFloatingLabel: i
|
|
44
|
+
} = y(t.emit);
|
|
45
|
+
return {
|
|
46
|
+
labelState: a,
|
|
47
|
+
setInitialLabelState: b,
|
|
48
|
+
handleFocusIn: h,
|
|
49
|
+
handleFocusOut: f,
|
|
50
|
+
setInlineLabel: r,
|
|
51
|
+
setFloatingLabel: i
|
|
52
|
+
};
|
|
53
|
+
},
|
|
54
|
+
data() {
|
|
55
|
+
return {
|
|
56
|
+
type: "",
|
|
57
|
+
//a valid input type
|
|
58
|
+
feedbackObj: {},
|
|
59
|
+
pointerDownListener: (e) => {
|
|
60
|
+
e.preventDefault();
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
|
+
},
|
|
64
|
+
computed: {
|
|
65
|
+
passwordIcon() {
|
|
66
|
+
return document ? document.querySelector("[data-type='password-icon']") : null;
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
watch: {
|
|
70
|
+
feedback() {
|
|
71
|
+
this.normalizeFeedbackProp();
|
|
72
|
+
},
|
|
73
|
+
modelValue(e) {
|
|
74
|
+
if (e) {
|
|
75
|
+
const t = this.$refs.baseInput;
|
|
76
|
+
if (!t)
|
|
77
|
+
return;
|
|
78
|
+
!t.value && this.formatter && (e = t.value);
|
|
79
|
+
const a = this.updateInputValue(t, e);
|
|
80
|
+
this.$emit("update:modelValue", a);
|
|
81
|
+
} else
|
|
82
|
+
this.$refs.baseInput.value = "";
|
|
83
|
+
e != null && `${e}`.length > 0 && this.auto && this.labelState !== "floating-label" ? this.labelState = "floating-label" : (e == null || e == null) && (this.labelState = "inline-label");
|
|
84
|
+
},
|
|
85
|
+
//Manually moving the floating label
|
|
86
|
+
keepFloatingLabel(e) {
|
|
87
|
+
e ? this.setFloatingLabel() : this.handleFocusOut(this.modelValue, !0, this.auto);
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
created() {
|
|
91
|
+
this.type = this.$attrs.type, this.normalizeFeedbackProp(), this.setInitialLabelState(this.modelValue);
|
|
92
|
+
},
|
|
93
|
+
mounted() {
|
|
94
|
+
if ((this.modelValue != null || this.modelValue != null) && (this.$refs.baseInput.value = `${this.modelValue}`), this.formatter) {
|
|
95
|
+
const e = this.updateInputValue(
|
|
96
|
+
this.$refs.baseInput,
|
|
97
|
+
`${this.modelValue}`
|
|
98
|
+
);
|
|
99
|
+
this.$emit("update:modelValue", e);
|
|
100
|
+
}
|
|
101
|
+
this.setPointerOutListener();
|
|
102
|
+
},
|
|
103
|
+
unmounted() {
|
|
104
|
+
this.passwordIcon?.removeEventListener(
|
|
105
|
+
"pointerdown",
|
|
106
|
+
this.pointerDownListener
|
|
107
|
+
);
|
|
108
|
+
},
|
|
109
|
+
methods: {
|
|
110
|
+
select() {
|
|
111
|
+
this.$refs.baseInput.select();
|
|
112
|
+
},
|
|
113
|
+
/**
|
|
114
|
+
* Prevents the default behaviour of pointerout so the clicked element won't make lose the focus to the input element
|
|
115
|
+
* */
|
|
116
|
+
setPointerOutListener() {
|
|
117
|
+
if (this.$attrs.type !== "password")
|
|
118
|
+
return;
|
|
119
|
+
const e = this.passwordIcon;
|
|
120
|
+
e && e.addEventListener("pointerdown", this.pointerDownListener);
|
|
121
|
+
},
|
|
122
|
+
handleFloatingLabelClick() {
|
|
123
|
+
this.$refs.baseInput.focus();
|
|
124
|
+
},
|
|
125
|
+
normalizeFeedbackProp() {
|
|
126
|
+
this.feedback && (this.feedbackObj = this.feedback, this.feedback.valid && typeof this.feedback.valid == "string" && (this.feedbackObj.valid = [this.feedback.valid]), this.feedback.invalid && typeof this.feedback.invalid == "string" && (this.feedbackObj.invalid = [this.feedback.invalid]));
|
|
127
|
+
},
|
|
128
|
+
updateInputValue(e, t) {
|
|
129
|
+
if (!t)
|
|
130
|
+
return e.value = "", "";
|
|
131
|
+
let a = "";
|
|
132
|
+
return this.formatter && this.formatter.unFormatFn ? a = `${this.formatter.unFormatFn(t)}` : a = t, this.formatter ? e.value = this.formatter.formatFn(a) : e.value = a, a;
|
|
133
|
+
},
|
|
134
|
+
handleInputChange({ target: e }) {
|
|
135
|
+
if (this.inputType === "select")
|
|
136
|
+
return;
|
|
137
|
+
const t = e, a = this.updateInputValue(t, t.value);
|
|
138
|
+
this.$emit("update:modelValue", a);
|
|
139
|
+
},
|
|
140
|
+
handleClick(e) {
|
|
141
|
+
this.$emit("click", e);
|
|
142
|
+
},
|
|
143
|
+
handleClean() {
|
|
144
|
+
this.$emit("update:modelValue", ""), this.setInlineLabel();
|
|
145
|
+
},
|
|
146
|
+
handleShowPasswd() {
|
|
147
|
+
this.type === "password" ? this.type = "text" : this.type === "text" && (this.type = "password");
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
}), L = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby", "readonly", "type", "pattern", "min", "max", "maxlength", "inputmode", "placeholder"], C = {
|
|
151
|
+
key: 0,
|
|
152
|
+
class: "uikit-invisible uikit-float-none uikit-mb-2 uikit-ml-2 uikit-block uikit-h-3 uikit-w-auto uikit-max-w-full uikit-overflow-hidden uikit-whitespace-nowrap uikit-p-0 uikit-text uikit-transition-[max-width] uikit-duration-[50ms] uikit-ease-out"
|
|
153
|
+
}, S = ["innerHTML"], T = ["innerHTML"], O = ["innerHTML"], B = { class: "under-label uikit-absolute uikit-text-12" };
|
|
154
|
+
function j(e, t, a, b, h, f) {
|
|
155
|
+
const r = g("base-floating-label");
|
|
156
|
+
return l(), s("div", {
|
|
157
|
+
class: n(["input-wrapper uikit-relative uikit-inline-block uikit-w-full [&.has-right-icon.is-invalid_.text-input-icon]:uikit-mr-25px [&.has-right-icon.is-valid_.text-input-icon]:uikit-mr-25px", [
|
|
158
|
+
e.$attrs.class,
|
|
159
|
+
{ "uikit-mt-10px": e.labelText },
|
|
160
|
+
{ "floating-label": e.labelText },
|
|
161
|
+
e.labelState === "floating-label" ? "floating-state" : "inline-state",
|
|
162
|
+
{
|
|
163
|
+
"has-right-icon": e.$attrs["with-right-icon"] !== void 0 ? e.$attrs["with-right-icon"] : !!e.$slots.righticon
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
"has-left-icon": e.$attrs["with-left-icon"] !== void 0 ? e.$attrs["with-left-icon"] : !!e.$slots.leftIcon
|
|
167
|
+
},
|
|
168
|
+
{ "is-invalid": e.isValid === !1, "is-valid": e.isValid }
|
|
169
|
+
]])
|
|
170
|
+
}, [
|
|
171
|
+
d(e.$slots, "leftIcon", {}, void 0, !0),
|
|
172
|
+
d(e.$slots, "righticon", {
|
|
173
|
+
handleClean: e.handleClean,
|
|
174
|
+
handleShowPasswd: e.handleShowPasswd,
|
|
175
|
+
curType: e.type
|
|
176
|
+
}, void 0, !0),
|
|
177
|
+
o("input", {
|
|
178
|
+
id: e.$attrs.id,
|
|
179
|
+
ref: "baseInput",
|
|
180
|
+
"data-cy": e.$attrs["data-cy"],
|
|
181
|
+
name: e.$attrs.name,
|
|
182
|
+
class: n(["uikit-peer uikit-h-[42px] uikit-truncate !uikit-border-none uikit-bg-no-repeat focus:uikit-shadow-none focus:uikit-outline-none", [
|
|
183
|
+
{ "uikit-rounded-xs": e.radius },
|
|
184
|
+
{
|
|
185
|
+
"input-element uikit-block uikit-h-12 uikit-w-full uikit-appearance-none uikit-px-4 uikit-py-2 uikit-outline-0": e.inputType === "text-input"
|
|
186
|
+
},
|
|
187
|
+
{ "uikit-text-w-secondary": e.$attrs.disabled },
|
|
188
|
+
{
|
|
189
|
+
"is-invalid invalid-bg !uikit-pr-9": e.isValid === !1,
|
|
190
|
+
"is-valid valid-bg !uikit-pr-9": e.isValid
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
"uikit-pr-[42px]": e.$attrs["with-right-icon"] !== void 0 ? e.$attrs["with-right-icon"] : !!e.$slots.righticon
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"uikit-pl-[42px]": e.$attrs["with-left-icon"] !== void 0 ? e.$attrs["with-left-icon"] : !!e.$slots.leftIcon
|
|
197
|
+
},
|
|
198
|
+
e.inputClass
|
|
199
|
+
]]),
|
|
200
|
+
autocomplete: e.$attrs.autocomplete === "on" ? "on" : "off",
|
|
201
|
+
disabled: e.$attrs.disabled,
|
|
202
|
+
"aria-labelledby": e.$attrs.id,
|
|
203
|
+
readonly: e.$attrs.readonly,
|
|
204
|
+
type: e.type,
|
|
205
|
+
pattern: e.$attrs.pattern,
|
|
206
|
+
min: e.$attrs.min,
|
|
207
|
+
max: e.$attrs.max,
|
|
208
|
+
maxlength: e.$attrs.maxlength,
|
|
209
|
+
inputmode: e.$attrs.inputmode,
|
|
210
|
+
placeholder: e.$attrs.placeholder,
|
|
211
|
+
onClick: t[0] || (t[0] = (...i) => e.handleClick && e.handleClick(...i)),
|
|
212
|
+
onFocusin: t[1] || (t[1] = p(() => e.handleFocusIn(), ["stop"])),
|
|
213
|
+
onFocusout: t[2] || (t[2] = p((i) => !e.keepFloatingLabel && e.handleFocusOut(e.modelValue, !1, e.auto), ["stop"])),
|
|
214
|
+
onInput: t[3] || (t[3] = p((...i) => e.handleInputChange && e.handleInputChange(...i), ["stop"])),
|
|
215
|
+
onKeydown: [
|
|
216
|
+
t[4] || (t[4] = V((i) => e.$emit("keydown-enter-pressed"), ["enter"])),
|
|
217
|
+
t[5] || (t[5] = (i) => e.$emit("keydown", i))
|
|
218
|
+
]
|
|
219
|
+
}, null, 42, L),
|
|
220
|
+
o("fieldset", {
|
|
221
|
+
class: n(["uikit-pointer-events-none uikit-absolute -uikit-top-[5px] uikit-bottom-0 uikit-left-0 uikit-right-0 uikit-m-0 uikit-h-12 uikit-overflow-hidden uikit-px-2 uikit-py-0 uikit-text-left", [
|
|
222
|
+
{
|
|
223
|
+
"uikit-border uikit-border-solid uikit-transition-[border] uikit-duration-100 uikit-ease-out peer-focus:uikit-border-2 peer-focus:uikit-border-w-primary peer-focus:[&.is-invalid]:uikit-border-w-danger": e.border,
|
|
224
|
+
"uikit-rounded-xs": e.radius,
|
|
225
|
+
"is-invalid uikit-border-w-danger": e.isValid === !1,
|
|
226
|
+
"is-valid uikit-border-w-primary": e.isValid,
|
|
227
|
+
"uikit-border-w-secondary": e.isValid === null && e.border
|
|
228
|
+
},
|
|
229
|
+
{ "no-floating-label uikit-top-0": !e.labelText },
|
|
230
|
+
e.$attrs["fieldset-classes"]
|
|
231
|
+
]])
|
|
232
|
+
}, [
|
|
233
|
+
e.labelText ? (l(), s("legend", C, [
|
|
234
|
+
o("span", {
|
|
235
|
+
class: n(["visible-label uikit-opacity-0", [
|
|
236
|
+
{ "uikit-mx-5px": e.labelText },
|
|
237
|
+
{
|
|
238
|
+
"uikit-visible uikit-inline-block": e.labelState === "floating-label"
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
"uikit-invisible uikit-hidden": e.labelState === "inline-label"
|
|
242
|
+
}
|
|
243
|
+
]]),
|
|
244
|
+
innerHTML: e.labelText
|
|
245
|
+
}, null, 10, S)
|
|
246
|
+
])) : k("", !0)
|
|
247
|
+
], 2),
|
|
248
|
+
e.labelText ? (l(), c(r, {
|
|
249
|
+
key: 0,
|
|
250
|
+
for: e.$attrs.id,
|
|
251
|
+
"label-text": e.labelText,
|
|
252
|
+
"label-state": e.labelState,
|
|
253
|
+
"is-valid": e.isValid,
|
|
254
|
+
required: e.$attrs.required,
|
|
255
|
+
disabled: e.$attrs.disabled,
|
|
256
|
+
"label-classes": e.$attrs["label-classes"],
|
|
257
|
+
onClick: e.handleFloatingLabelClick
|
|
258
|
+
}, null, 8, ["for", "label-text", "label-state", "is-valid", "required", "disabled", "label-classes", "onClick"])) : k("", !0),
|
|
259
|
+
e.isValid === !1 ? (l(!0), s(m, { key: 1 }, $(e.feedbackObj.invalid, (i, u) => (l(), s("div", {
|
|
260
|
+
key: `${e.$attrs.id}_invalid_${u}`,
|
|
261
|
+
class: "uikit-mt-1 uikit-text-12 uikit-text-w-danger",
|
|
262
|
+
innerHTML: i
|
|
263
|
+
}, null, 8, T))), 128)) : e.isValid === !0 ? (l(!0), s(m, { key: 2 }, $(e.feedbackObj.valid, (i, u) => (l(), s("div", {
|
|
264
|
+
key: `${e.$attrs.id}_valid_${u}`,
|
|
265
|
+
class: "uikit-mt-1 uikit-text-12 uikit-text-w-primary",
|
|
266
|
+
innerHTML: i
|
|
267
|
+
}, null, 8, O))), 128)) : k("", !0),
|
|
268
|
+
o("div", B, [
|
|
269
|
+
d(e.$slots, "under-label", {}, void 0, !0)
|
|
270
|
+
])
|
|
271
|
+
], 2);
|
|
272
|
+
}
|
|
273
|
+
const z = /* @__PURE__ */ I(F, [["render", j], ["__scopeId", "data-v-e7a41e1a"]]);
|
|
274
|
+
export {
|
|
275
|
+
z as default
|
|
276
|
+
};
|
|
@@ -72,7 +72,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
72
72
|
handleClick(e: Event): void;
|
|
73
73
|
handleClean(): void;
|
|
74
74
|
handleShowPasswd(): void;
|
|
75
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("
|
|
75
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:modelValue" | "focusout" | "focusin" | "keydown" | "keydown-enter-pressed")[], "click" | "update:modelValue" | "focusout" | "focusin" | "keydown" | "keydown-enter-pressed", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
76
76
|
inputClass: {
|
|
77
77
|
type: (ArrayConstructor | StringConstructor)[];
|
|
78
78
|
required: false;
|
|
@@ -120,10 +120,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
120
120
|
default: null;
|
|
121
121
|
};
|
|
122
122
|
}>> & {
|
|
123
|
-
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
124
|
-
onClick?: ((...args: any[]) => any) | undefined;
|
|
125
123
|
onFocusin?: ((...args: any[]) => any) | undefined;
|
|
126
124
|
onFocusout?: ((...args: any[]) => any) | undefined;
|
|
125
|
+
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
126
|
+
onClick?: ((...args: any[]) => any) | undefined;
|
|
127
127
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
128
128
|
"onKeydown-enter-pressed"?: ((...args: any[]) => any) | undefined;
|
|
129
129
|
}, {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const o=require("./BaseIcon.cjs"),e=require("vue"),r=require("../../_plugin-vue_export-helper-BHFhmbuH.cjs"),n=e.defineComponent({name:"BaseNavItem",components:{BaseIcon:o},props:{text:{type:String},iconName:{type:String},iconClass:{type:String,default:"uikit-mr-5px"},navItemCustomClass:{type:String},isActive:{type:Boolean,default:!1}},emits:["click"],watch:{isActive(t){const i=this.$refs["base-nav-item"];t?i.classList.add("active"):i.classList.remove("active")}}}),c=["id"];function l(t,i,p,m,d,b){const s=e.resolveComponent("base-icon");return e.openBlock(),e.createElementBlock("li",{id:`${t.$attrs.id}`,class:e.normalizeClass(["uikit-group/tabs uikit-relative uikit-flex uikit-cursor-pointer uikit-items-center uikit-pb-5px disabled:uikit-border-transparent disabled:uikit-bg-transparent disabled:uikit-text-gray-600",[t.navItemCustomClass]]),onClick:i[0]||(i[0]=a=>t.$emit("click",a))},[t.iconName?(e.openBlock(),e.createBlock(s,{key:0,"alt-attribute":"icon","icon-name":t.iconName,"icon-class":t.iconClass},null,8,["icon-name","icon-class"])):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},()=>[e.createElementVNode("a",{ref:"base-nav-item",class:"after:uikit-absolute after:uikit-bottom-0 after:uikit-left-0 after:uikit-w-full after:uikit-content-[''] group-hover/tabs:after:uikit-border-b-2 group-hover/tabs:after:uikit-border-b-w-primary group-hover/tabs:after:[border-bottom-style:solid]"},e.toDisplayString(t.text),513)],!0)],10,c)}const u=r._export_sfc(n,[["render",l],["__scopeId","data-v-d19a9a40"]]);module.exports=u;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import s from "./BaseIcon.js";
|
|
2
|
+
import { defineComponent as r, resolveComponent as n, openBlock as i, createElementBlock as l, normalizeClass as c, createBlock as m, createCommentVNode as u, renderSlot as p, createElementVNode as d, toDisplayString as f } from "vue";
|
|
3
|
+
import { _ as b } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
+
const k = r({
|
|
5
|
+
name: "BaseNavItem",
|
|
6
|
+
components: { BaseIcon: s },
|
|
7
|
+
props: {
|
|
8
|
+
text: {
|
|
9
|
+
type: String
|
|
10
|
+
},
|
|
11
|
+
iconName: {
|
|
12
|
+
type: String
|
|
13
|
+
},
|
|
14
|
+
iconClass: {
|
|
15
|
+
type: String,
|
|
16
|
+
default: "uikit-mr-5px"
|
|
17
|
+
},
|
|
18
|
+
navItemCustomClass: {
|
|
19
|
+
type: String
|
|
20
|
+
},
|
|
21
|
+
isActive: {
|
|
22
|
+
type: Boolean,
|
|
23
|
+
default: !1
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
emits: ["click"],
|
|
27
|
+
watch: {
|
|
28
|
+
isActive(t) {
|
|
29
|
+
const e = this.$refs["base-nav-item"];
|
|
30
|
+
t ? e.classList.add("active") : e.classList.remove("active");
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}), v = ["id"];
|
|
34
|
+
function g(t, e, C, y, $, N) {
|
|
35
|
+
const a = n("base-icon");
|
|
36
|
+
return i(), l("li", {
|
|
37
|
+
id: `${t.$attrs.id}`,
|
|
38
|
+
class: c(["uikit-group/tabs uikit-relative uikit-flex uikit-cursor-pointer uikit-items-center uikit-pb-5px disabled:uikit-border-transparent disabled:uikit-bg-transparent disabled:uikit-text-gray-600", [t.navItemCustomClass]]),
|
|
39
|
+
onClick: e[0] || (e[0] = (o) => t.$emit("click", o))
|
|
40
|
+
}, [
|
|
41
|
+
t.iconName ? (i(), m(a, {
|
|
42
|
+
key: 0,
|
|
43
|
+
"alt-attribute": "icon",
|
|
44
|
+
"icon-name": t.iconName,
|
|
45
|
+
"icon-class": t.iconClass
|
|
46
|
+
}, null, 8, ["icon-name", "icon-class"])) : u("", !0),
|
|
47
|
+
p(t.$slots, "default", {}, () => [
|
|
48
|
+
d("a", {
|
|
49
|
+
ref: "base-nav-item",
|
|
50
|
+
class: "after:uikit-absolute after:uikit-bottom-0 after:uikit-left-0 after:uikit-w-full after:uikit-content-[''] group-hover/tabs:after:uikit-border-b-2 group-hover/tabs:after:uikit-border-b-w-primary group-hover/tabs:after:[border-bottom-style:solid]"
|
|
51
|
+
}, f(t.text), 513)
|
|
52
|
+
], !0)
|
|
53
|
+
], 10, v);
|
|
54
|
+
}
|
|
55
|
+
const _ = /* @__PURE__ */ b(k, [["render", g], ["__scopeId", "data-v-d19a9a40"]]);
|
|
56
|
+
export {
|
|
57
|
+
_ as default
|
|
58
|
+
};
|