@volverjs/ui-vue 0.0.9 → 0.0.10-beta.10
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/README.md +64 -1
- package/auto-imports.d.ts +1 -1
- package/bin/icons.cjs +1 -1
- package/bin/icons.js +34 -19
- package/dist/components/VvAccordion/VvAccordion.es.js +33 -4
- package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
- package/dist/components/VvAccordion/VvAccordion.vue.d.ts +4 -4
- package/dist/components/VvAccordion/index.d.ts +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +75 -27
- package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +5 -5
- package/dist/components/VvAction/VvAction.es.js +26 -4
- package/dist/components/VvAction/VvAction.umd.js +1 -1
- package/dist/components/VvAction/VvAction.vue.d.ts +17 -4
- package/dist/components/VvAction/index.d.ts +5 -0
- package/dist/components/VvAlert/VvAlert.es.js +96 -45
- package/dist/components/VvAlert/VvAlert.umd.js +1 -1
- package/dist/components/VvAlert/VvAlert.vue.d.ts +4 -4
- package/dist/components/VvAlertGroup/VvAlertGroup.es.js +136 -66
- package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
- package/dist/components/VvAlertGroup/VvAlertGroup.vue.d.ts +4 -4
- package/dist/components/VvAvatar/VvAvatar.es.js +22 -1
- package/dist/components/VvAvatar/VvAvatar.umd.js +1 -1
- package/dist/components/VvAvatarGroup/VvAvatarGroup.es.js +79 -28
- package/dist/components/VvAvatarGroup/VvAvatarGroup.umd.js +1 -1
- package/dist/components/VvBadge/VvBadge.es.js +39 -8
- package/dist/components/VvBadge/VvBadge.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +224 -41
- package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +14 -3
- package/dist/components/VvBreadcrumb/index.d.ts +2 -9
- package/dist/components/VvButton/VvButton.es.js +70 -25
- package/dist/components/VvButton/VvButton.umd.js +1 -1
- package/dist/components/VvButton/VvButton.vue.d.ts +25 -9
- package/dist/components/VvButton/index.d.ts +5 -0
- package/dist/components/VvButtonGroup/VvButtonGroup.es.js +33 -6
- package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
- package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +6 -6
- package/dist/components/VvCard/VvCard.es.js +47 -16
- package/dist/components/VvCard/VvCard.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.es.js +35 -7
- package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +8 -8
- package/dist/components/VvCheckbox/index.d.ts +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +106 -51
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +7 -7
- package/dist/components/VvCheckboxGroup/index.d.ts +1 -1
- package/dist/components/VvCombobox/VvCombobox.es.js +635 -400
- package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
- package/dist/components/VvCombobox/VvCombobox.vue.d.ts +112 -112
- package/dist/components/VvCombobox/index.d.ts +32 -32
- package/dist/components/VvDialog/VvDialog.es.js +65 -27
- package/dist/components/VvDialog/VvDialog.umd.js +1 -1
- package/dist/components/VvDialog/VvDialog.vue.d.ts +4 -4
- package/dist/components/VvDropdown/VvDropdown.es.js +87 -46
- package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
- package/dist/components/VvDropdown/VvDropdown.vue.d.ts +203 -189
- package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +12 -0
- package/dist/components/VvDropdown/index.d.ts +32 -32
- package/dist/components/VvDropdownAction/VvDropdownAction.es.js +46 -12
- package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
- package/dist/components/VvDropdownItem/VvDropdownItem.es.js +13 -7
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.es.js +28 -1
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.umd.js +1 -1
- package/dist/components/VvDropdownOption/VvDropdownOption.es.js +40 -8
- package/dist/components/VvDropdownOption/VvDropdownOption.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.es.js +1 -1
- package/dist/components/VvIcon/VvIcon.umd.js +1 -1
- package/dist/components/VvInputText/VvInputClearAction.d.ts +1 -1
- package/dist/components/VvInputText/VvInputText.es.js +149 -99
- package/dist/components/VvInputText/VvInputText.umd.js +1 -1
- package/dist/components/VvInputText/VvInputText.vue.d.ts +10 -10
- package/dist/components/VvInputText/index.d.ts +8 -2
- package/dist/components/VvNav/VvNav.es.js +115 -63
- package/dist/components/VvNav/VvNav.umd.js +1 -1
- package/dist/components/VvNav/VvNav.vue.d.ts +31 -12
- package/dist/components/VvNav/VvNavItem.vue.d.ts +9 -0
- package/dist/components/VvNav/index.d.ts +1 -12
- package/dist/components/VvNavItem/VvNavItem.es.js +413 -0
- package/dist/components/VvNavItem/VvNavItem.umd.js +1 -0
- package/dist/components/VvNavSeparator/VvNavSeparator.es.js +24 -0
- package/dist/components/VvNavSeparator/VvNavSeparator.umd.js +1 -0
- package/dist/components/VvProgress/VvProgress.es.js +33 -6
- package/dist/components/VvProgress/VvProgress.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.es.js +35 -7
- package/dist/components/VvRadio/VvRadio.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.vue.d.ts +8 -8
- package/dist/components/VvRadio/index.d.ts +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.es.js +106 -51
- package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +7 -7
- package/dist/components/VvRadioGroup/index.d.ts +1 -1
- package/dist/components/VvSelect/VvSelect.es.js +159 -99
- package/dist/components/VvSelect/VvSelect.umd.js +1 -1
- package/dist/components/VvSelect/VvSelect.vue.d.ts +13 -13
- package/dist/components/VvSelect/index.d.ts +1 -1
- package/dist/components/VvTab/VvTab.es.js +214 -99
- package/dist/components/VvTab/VvTab.umd.js +1 -1
- package/dist/components/VvTab/VvTab.vue.d.ts +40 -11
- package/dist/components/VvTab/index.d.ts +9 -3
- package/dist/components/VvTextarea/VvTextarea.es.js +123 -77
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
- package/dist/components/VvTextarea/VvTextarea.vue.d.ts +10 -10
- package/dist/components/VvTooltip/VvTooltip.es.js +40 -9
- package/dist/components/VvTooltip/VvTooltip.umd.js +1 -1
- package/dist/components/index.es.js +1593 -1012
- package/dist/components/index.umd.js +1 -1
- package/dist/composables/group/useInjectedGroupState.d.ts +1 -1
- package/dist/composables/useOptions.d.ts +1 -1
- package/dist/composables/useVolver.d.ts +1 -1
- package/dist/directives/index.d.ts +3 -5
- package/dist/directives/index.es.js +60 -23
- package/dist/directives/index.umd.js +1 -1
- package/dist/directives/v-tooltip.es.js +58 -18
- package/dist/directives/v-tooltip.umd.js +1 -1
- package/dist/icons.es.js +3 -3
- package/dist/icons.umd.js +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.es.js +19 -16
- package/dist/index.umd.js +1 -1
- package/dist/props/index.d.ts +58 -34
- package/dist/stories/AccordionGroup/AccordionGroup.stories.d.ts +50 -15
- package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +332 -83
- package/dist/stories/Combobox/Combobox.settings.d.ts +8 -0
- package/dist/stories/Combobox/ComboboxOptions.stories.d.ts +1 -0
- package/dist/stories/InputText/InputTextMask.stories.d.ts +1 -1
- package/dist/stories/Tab/Tab.settings.d.ts +4 -37
- package/dist/types/alert.d.ts +13 -0
- package/dist/types/floating-ui.d.ts +6 -0
- package/dist/types/generic.d.ts +4 -0
- package/dist/types/group.d.ts +37 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/nav.d.ts +17 -0
- package/package.json +61 -52
- package/src/Volver.ts +22 -16
- package/src/assets/icons/detailed.json +1 -1
- package/src/assets/icons/normal.json +1 -1
- package/src/assets/icons/simple.json +1 -1
- package/src/components/VvAccordion/VvAccordion.vue +2 -2
- package/src/components/VvAction/VvAction.vue +5 -2
- package/src/components/VvBreadcrumb/VvBreadcrumb.vue +20 -19
- package/src/components/VvBreadcrumb/index.ts +2 -8
- package/src/components/VvCombobox/VvCombobox.vue +32 -33
- package/src/components/VvCombobox/index.ts +4 -0
- package/src/components/VvInputText/VvInputText.vue +2 -2
- package/src/components/VvNav/VvNav.vue +30 -50
- package/src/components/VvNav/VvNavItem.vue +18 -0
- package/src/components/VvNav/VvNavSeparator.vue +11 -0
- package/src/components/VvNav/index.ts +2 -15
- package/src/components/VvSelect/VvSelect.vue +4 -4
- package/src/components/VvTab/VvTab.vue +63 -35
- package/src/components/VvTab/index.ts +10 -4
- package/src/components/VvTextarea/VvTextarea.vue +1 -1
- package/src/composables/useOptions.ts +2 -2
- package/src/composables/useUniqueId.ts +2 -2
- package/src/directives/index.ts +1 -4
- package/src/directives/v-tooltip.ts +19 -10
- package/src/index.ts +3 -1
- package/src/props/index.ts +27 -3
- package/src/stories/Button/ButtonModifiers.stories.ts +4 -14
- package/src/stories/Combobox/Combobox.settings.ts +8 -0
- package/src/stories/Combobox/ComboboxOptions.stories.ts +18 -0
- package/src/stories/InputText/InputTextMask.stories.ts +1 -1
- package/src/stories/Nav/Nav.settings.ts +3 -4
- package/src/stories/Nav/Nav.test.ts +4 -15
- package/src/stories/Tab/Tab.settings.ts +9 -9
- package/src/stories/Tab/Tab.stories.ts +2 -2
- package/src/stories/Tab/Tab.test.ts +6 -14
- package/src/stories/argTypes.ts +1 -1
- package/src/types/generic.ts +6 -0
- package/src/types/index.ts +5 -0
- package/src/types/nav.ts +19 -0
- package/src/utils/ObjectUtilities.ts +3 -2
- package/dist/components/VvNav/VvNavItemTitle.vue.d.ts +0 -6
- package/dist/components/VvNavItemTitle/VvNavItemTitle.es.js +0 -19
- package/dist/components/VvNavItemTitle/VvNavItemTitle.umd.js +0 -1
- package/src/components/VvNav/VvNavItemTitle.vue +0 -11
- package/src/components/VvNav/VvNavSeparator.ts +0 -8
- package/src/types/generic.d.ts +0 -6
- /package/dist/components/VvNav/{VvNavSeparator.d.ts → VvNavSeparator.vue.d.ts} +0 -0
- /package/src/types/{alert.d.ts → alert.ts} +0 -0
- /package/src/types/{floating-ui.d.ts → floating-ui.ts} +0 -0
- /package/src/types/{group.d.ts → group.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@iconify/vue"),require("
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@iconify/vue"),require("uid")):"function"==typeof define&&define.amd?define(["vue","mitt","@iconify/vue","uid"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).VvAlertGroup=t(e.vue,e.mitt,e.vue$1,e.uid)}(this,(function(e,t,o,r){"use strict";var l=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(l||{}),n=(e=>(e.before="before",e.after="after",e))(n||{}),i=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(i||{}),a=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(a||{});const s=Symbol.for("volver"),c=Symbol.for("alertGroup"),u=(Boolean,Boolean,Boolean,Boolean,{modifiers:[String,Array]}),d={icon:{type:[String,Object]},iconPosition:{type:String,default:n.before,validation:e=>Object.values(n).includes(e)}},v={id:[String,Number]};function f(t,o,r){return e.computed((()=>{const l={[t]:!0},n="string"==typeof(null==o?void 0:o.value)?o.value.split(" "):null==o?void 0:o.value;return n&&Array.isArray(n)&&n.forEach((e=>{e&&(l[`${t}--${e}`]=!0)})),r&&Object.keys(r.value).forEach((o=>{l[`${t}--${o}`]=e.unref(r.value[o])})),l}))}l.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,i.button,a.button;const p={...u,name:{type:String,required:!0},items:{type:Array,default:()=>[]},stack:{type:Boolean,default:!1},reverse:{type:Boolean,default:!1},inline:{type:String,default:void 0},block:{type:String,default:void 0},position:{type:String,default:void 0},transition:{type:String,default:void 0}},m=(o,r)=>{const l=function({name:o}){const r=t();return e.provide(c,{name:o,bus:r}),r}({name:e.computed((()=>o.name))});(o.block&&!o.inline||!o.block&&o.inline)&&console.warn("[VvAlertGroup]: block and inline props must coexist at the same time.");const n=e.computed((()=>{const t=[f("vv-alert-group",e.computed((()=>o.modifiers)),e.computed((()=>({stack:o.stack,reverse:o.reverse,absolute:"absolute"===o.position,fixed:"fixed"===o.position})))).value];return o.inline&&o.block&&t.push(`vv-alert-group--${o.block}-${o.inline}`),t})),i=e.computed((()=>o.transition?o.transition:o.position?"start"===o.inline?"vv-alert--fade-inline-start":"end"===o.inline?"vv-alert--fade-inline-end":"top"===o.block?"vv-alert--fade-block-top":"bottom"===o.block?"vv-alert--fade-block-bottom":"vv-alert--fade":"vv-alert--fade"));return l.on("close",(e=>{r("close",e)})),{hasTransition:i,hasProps:e.computed((()=>({class:n.value})))}},b={color:String,width:{type:[String,Number]},height:{type:[String,Number]},name:{type:String,required:!0},provider:{type:String},prefix:{type:String,default:"normal"},src:String,horizontalFlip:Boolean,verticalFlip:Boolean,flip:String,mode:String,inline:Boolean,rotate:[Number,String],onLoad:Function,svg:String,modifiers:{type:[String,Array]}};const g=e.defineComponent({name:"VvIcon",props:b,setup(t){const r=t,l=e.computed((()=>"string"==typeof r.rotate?parseFloat(r.rotate):r.rotate)),n=e.ref(!0),i=e.inject(s),{modifiers:a}=e.toRefs(r),c=f("vv-icon",a),u=e.computed((()=>r.provider||(null==i?void 0:i.iconsProvider))),d=e.computed((()=>{const e=r.name??"",t=`@${u.value}:${r.prefix}:${e}`;if(o.iconExists(t))return t;const l=null==i?void 0:i.iconsCollections.find((t=>{const r=`@${u.value}:${t.prefix}:${e}`;return o.iconExists(r)}));return l?`@${u.value}:${l.prefix}:${e}`:e}));function v(e){const t=function(e){let t;if("undefined"==typeof window){const{JSDOM:e}=require("jsdom");t=(new e).window}return(t?new t.DOMParser:new window.DOMParser).parseFromString(e,"text/html").querySelector("svg")}(e),l=(null==t?void 0:t.innerHTML.trim())||"";t&&l&&o.addIcon(`@${u.value}:${r.prefix}:${r.name}`,{body:l,height:t.viewBox.baseVal.height,width:t.viewBox.baseVal.width})}return i&&r.src&&!o.iconExists(`@${u.value}:${r.prefix}:${r.name}`)&&(n.value=!1,i.fetchIcon(r.src).then((e=>{e&&(v(e),n.value=!0)})).catch((e=>{throw new Error(`Error during fetch icon: ${null==e?void 0:e.message}`)}))),r.svg&&v(r.svg),(t,r)=>e.unref(n)?(e.openBlock(),e.createBlock(e.unref(o.Icon),e.mergeProps({key:0,class:e.unref(c)},{inline:t.inline,width:t.width,height:t.height,horizontalFlip:t.horizontalFlip,verticalFlip:t.verticalFlip,flip:t.flip,rotate:e.unref(l),color:t.color,onLoad:t.onLoad,icon:e.unref(d)}),null,16,["class"])):e.createCommentVNode("v-if",!0)}});const y={...v,...u,...d,dismissable:{type:Boolean,default:!1},autoClose:{type:Number,default:0},closeLabel:{type:String,default:"Close"},title:{type:String,default:void 0},content:{type:String,default:void 0},footer:{type:String,default:void 0},role:{type:String,default:"alert"}},h=(t,o)=>{const{bus:l}=e.inject(c,{}),n=(i=e.computed((()=>t.id)),e.computed((()=>String((null==i?void 0:i.value)||r.uid()))));var i;const a=e.computed((()=>`${n.value}-title`)),s=e.computed((()=>"string"==typeof t.icon?{name:t.icon}:t.icon)),u=f("vv-alert",e.computed((()=>t.modifiers)),e.computed((()=>({dismissable:t.autoClose>0||t.dismissable,"auto-close":t.autoClose>0,hover:m.value})))),d=e.computed((()=>({"--alert-duration":`${t.autoClose}ms`}))),v=()=>{p&&clearTimeout(p),o("close",n.value),null==l||l.emit("close",n.value)};let p;e.watch((()=>t.autoClose),(e=>{e>0?p=setTimeout(v,e):p&&clearTimeout(p)}),{immediate:!0});const m=e.ref(!1),b=e.withModifiers((()=>{m.value=!0,p&&clearTimeout(p)}),["passive"]),g=e.withModifiers((()=>{m.value=!1,t.autoClose>0&&(p=setTimeout(v,t.autoClose))}),["passive"]);return{close:v,hasIcon:s,hasTitleId:a,hasProps:e.computed((()=>({onMouseover:b,onMouseleave:g,class:u.value,style:d.value,role:t.role,"aria-labelledby":a.value})))}},k={key:0,class:"vv-alert__header"},S=["id"],$=["aria-label"],B=[e.createElementVNode("div",{class:"vv-alert__close-mask"},null,-1)],w={key:1,class:"vv-alert__content"},x={key:2,class:"vv-alert__footer"},C=e.defineComponent({name:"VvAlert",props:y,emits:["close"],setup(t,{expose:o,emit:r}){const l=t,{hasProps:n,hasTitleId:i,hasIcon:a,close:s}=h(l,r);return o({close:s}),(t,o)=>(e.openBlock(),e.createElementBlock("div",e.normalizeProps(e.guardReactiveProps(e.unref(n))),[t.$slots.header||t.$slots.title||t.$slots.close||t.$slots["title::before"]||t.$slots["title::after"]||t.title||t.dismissable||t.autoClose?(e.openBlock(),e.createElementBlock("div",k,[e.unref(a)?(e.openBlock(),e.createBlock(g,e.mergeProps({key:0},e.unref(a),{class:"vv-alert__icon"}),null,16)):e.createCommentVNode("v-if",!0),e.renderSlot(t.$slots,"header",{},(()=>[e.renderSlot(t.$slots,"title::before"),t.$slots.title||t.title?(e.openBlock(),e.createElementBlock("strong",{key:0,id:e.unref(i),class:"vv-alert__title"},[e.renderSlot(t.$slots,"title",{},(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]))],8,S)):e.createCommentVNode("v-if",!0),e.renderSlot(t.$slots,"title::after")])),e.renderSlot(t.$slots,"close",e.normalizeProps(e.guardReactiveProps({close:e.unref(s)})),(()=>[t.dismissable||t.autoClose?(e.openBlock(),e.createElementBlock("button",{key:0,class:"vv-alert__close",type:"button","aria-label":t.closeLabel,onClick:o[0]||(o[0]=e.withModifiers(((...t)=>e.unref(s)&&e.unref(s)(...t)),["stop"]))},B,8,$)):e.createCommentVNode("v-if",!0)]))])):e.createCommentVNode("v-if",!0),t.$slots.default||t.content?(e.openBlock(),e.createElementBlock("div",w,[e.renderSlot(t.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(t.content),1)]))])):e.createCommentVNode("v-if",!0),t.$slots.footer||t.footer?(e.openBlock(),e.createElementBlock("div",x,[e.renderSlot(t.$slots,"footer",{},(()=>[e.createTextVNode(e.toDisplayString(t.footer),1)]))])):e.createCommentVNode("v-if",!0)],16))}});return e.defineComponent({name:"VvAlertGroup",props:p,emits:["close","before-enter","after-leave","enter","after-enter","enter-cancelled","before-leave","leave","leave-cancelled"],setup(t,{emit:o}){const r=t,{hasProps:l,hasTransition:n}=m(r,o),i={"before-enter":()=>{o("before-enter")},"after-leave":()=>{o("after-leave")},enter:()=>{o("enter")},"after-enter":()=>{o("after-enter")},"enter-cancelled":()=>{o("enter-cancelled")},"before-leave":()=>{o("before-leave")},leave:()=>{o("leave")},"leave-cancelled":()=>{o("leave-cancelled")}};return(t,o)=>(e.openBlock(),e.createElementBlock("div",e.normalizeProps(e.guardReactiveProps(e.unref(l))),[e.renderSlot(t.$slots,"before"),e.createVNode(e.TransitionGroup,e.mergeProps({tag:"div",role:"group",name:e.unref(n),class:"vv-alert-group__list"},e.toHandlers(i)),{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default",{},(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(t=>(e.openBlock(),e.createBlock(C,e.mergeProps(t,{key:t.id}),null,16)))),128))]))])),_:3},16,["name"]),e.renderSlot(t.$slots,"after")],16))}})}));
|
|
@@ -32,7 +32,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
32
32
|
default: undefined;
|
|
33
33
|
};
|
|
34
34
|
modifiers: globalThis.PropType<string | string[]>;
|
|
35
|
-
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin,
|
|
35
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
36
|
+
[x: string]: (...args: any[]) => void;
|
|
37
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
36
38
|
name: {
|
|
37
39
|
type: StringConstructor;
|
|
38
40
|
required: boolean;
|
|
@@ -66,9 +68,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
66
68
|
default: undefined;
|
|
67
69
|
};
|
|
68
70
|
modifiers: globalThis.PropType<string | string[]>;
|
|
69
|
-
}
|
|
70
|
-
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
71
|
-
}, {
|
|
71
|
+
}>>, {
|
|
72
72
|
reverse: boolean;
|
|
73
73
|
items: import(".").AlertItem[];
|
|
74
74
|
transition: string;
|
|
@@ -33,6 +33,13 @@ var ButtonType = /* @__PURE__ */ ((ButtonType2) => {
|
|
|
33
33
|
ButtonType2["reset"] = "reset";
|
|
34
34
|
return ButtonType2;
|
|
35
35
|
})(ButtonType || {});
|
|
36
|
+
var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
37
|
+
ActionTag2["nuxtLink"] = "nuxt-link";
|
|
38
|
+
ActionTag2["routerLink"] = "router-link";
|
|
39
|
+
ActionTag2["a"] = "a";
|
|
40
|
+
ActionTag2["button"] = "button";
|
|
41
|
+
return ActionTag2;
|
|
42
|
+
})(ActionTag || {});
|
|
36
43
|
var AnchorTarget = /* @__PURE__ */ ((AnchorTarget2) => {
|
|
37
44
|
AnchorTarget2["_blank"] = "_blank";
|
|
38
45
|
AnchorTarget2["_self"] = "_self";
|
|
@@ -79,6 +86,12 @@ const ActiveProps = {
|
|
|
79
86
|
*/
|
|
80
87
|
active: Boolean
|
|
81
88
|
};
|
|
89
|
+
const CurrentProps = {
|
|
90
|
+
/**
|
|
91
|
+
* Whether the item is current
|
|
92
|
+
*/
|
|
93
|
+
current: Boolean
|
|
94
|
+
};
|
|
82
95
|
const PressedProps = {
|
|
83
96
|
/**
|
|
84
97
|
* Whether the item is pressed
|
|
@@ -209,6 +222,7 @@ const ModifiersProps = {
|
|
|
209
222
|
...LabelProps,
|
|
210
223
|
...PressedProps,
|
|
211
224
|
...ActiveProps,
|
|
225
|
+
...CurrentProps,
|
|
212
226
|
...LinkProps,
|
|
213
227
|
/**
|
|
214
228
|
* Button type
|
|
@@ -224,6 +238,13 @@ const ModifiersProps = {
|
|
|
224
238
|
ariaLabel: {
|
|
225
239
|
type: String,
|
|
226
240
|
default: void 0
|
|
241
|
+
},
|
|
242
|
+
/**
|
|
243
|
+
* Default tag for the action
|
|
244
|
+
*/
|
|
245
|
+
defaultTag: {
|
|
246
|
+
type: String,
|
|
247
|
+
default: ActionTag.button
|
|
227
248
|
}
|
|
228
249
|
});
|
|
229
250
|
const VvAvatarProps = {
|
|
@@ -276,7 +297,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
276
297
|
key: 0,
|
|
277
298
|
src: _ctx.imgSrc,
|
|
278
299
|
alt: "avatar"
|
|
279
|
-
}, null, 8, _hoisted_2)) : createCommentVNode("", true)
|
|
300
|
+
}, null, 8, _hoisted_2)) : createCommentVNode("v-if", true)
|
|
280
301
|
])
|
|
281
302
|
], 10, _hoisted_1);
|
|
282
303
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue")):"function"==typeof define&&define.amd?define(["vue"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvAvatar=o(e.vue)}(this,(function(e){"use strict";var o=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(o||{}),t=(e=>(e.before="before",e.after="after",e))(t||{}),
|
|
1
|
+
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue")):"function"==typeof define&&define.amd?define(["vue"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvAvatar=o(e.vue)}(this,(function(e){"use strict";var o=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(o||{}),t=(e=>(e.before="before",e.after="after",e))(t||{}),n=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(n||{}),r=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(r||{});Boolean,Boolean,Boolean,Boolean;const a={modifiers:[String,Array]};t.before,o.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,n.button,r.button;const l={...a,imgSrc:String};const i=["role","aria-label"],u=["src"];return e.defineComponent({__name:"VvAvatar",props:l,setup(o){const t=o,{modifiers:n}=e.toRefs(t),r=function(o,t,n){return e.computed((()=>{const r={[o]:!0},a="string"==typeof(null==t?void 0:t.value)?t.value.split(" "):null==t?void 0:t.value;return a&&Array.isArray(a)&&a.forEach((e=>{e&&(r[`${o}--${e}`]=!0)})),n&&Object.keys(n.value).forEach((t=>{r[`${o}--${t}`]=e.unref(n.value[t])})),r}))}("vv-avatar",n);return(o,t)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(e.unref(r)),role:o.imgSrc?void 0:"img","aria-label":o.imgSrc?void 0:"avatar"},[e.renderSlot(o.$slots,"default",{},(()=>[o.imgSrc?(e.openBlock(),e.createElementBlock("img",{key:0,src:o.imgSrc,alt:"avatar"},null,8,u)):e.createCommentVNode("v-if",!0)]))],10,i))}})}));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { computed, unref, defineComponent, toRefs, openBlock, createElementBlock, normalizeClass, renderSlot, createCommentVNode, Fragment, renderList, createBlock, mergeProps, withCtx, toDisplayString, createTextVNode } from "vue";
|
|
2
|
-
import {
|
|
2
|
+
import { uid } from "uid";
|
|
3
3
|
var Strategy = /* @__PURE__ */ ((Strategy2) => {
|
|
4
4
|
Strategy2["absolute"] = "absolute";
|
|
5
5
|
Strategy2["fixed"] = "fixed";
|
|
@@ -34,6 +34,13 @@ var ButtonType = /* @__PURE__ */ ((ButtonType2) => {
|
|
|
34
34
|
ButtonType2["reset"] = "reset";
|
|
35
35
|
return ButtonType2;
|
|
36
36
|
})(ButtonType || {});
|
|
37
|
+
var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
38
|
+
ActionTag2["nuxtLink"] = "nuxt-link";
|
|
39
|
+
ActionTag2["routerLink"] = "router-link";
|
|
40
|
+
ActionTag2["a"] = "a";
|
|
41
|
+
ActionTag2["button"] = "button";
|
|
42
|
+
return ActionTag2;
|
|
43
|
+
})(ActionTag || {});
|
|
37
44
|
var AnchorTarget = /* @__PURE__ */ ((AnchorTarget2) => {
|
|
38
45
|
AnchorTarget2["_blank"] = "_blank";
|
|
39
46
|
AnchorTarget2["_self"] = "_self";
|
|
@@ -80,6 +87,12 @@ const ActiveProps = {
|
|
|
80
87
|
*/
|
|
81
88
|
active: Boolean
|
|
82
89
|
};
|
|
90
|
+
const CurrentProps = {
|
|
91
|
+
/**
|
|
92
|
+
* Whether the item is current
|
|
93
|
+
*/
|
|
94
|
+
current: Boolean
|
|
95
|
+
};
|
|
83
96
|
const PressedProps = {
|
|
84
97
|
/**
|
|
85
98
|
* Whether the item is pressed
|
|
@@ -210,6 +223,7 @@ const ModifiersProps = {
|
|
|
210
223
|
...LabelProps,
|
|
211
224
|
...PressedProps,
|
|
212
225
|
...ActiveProps,
|
|
226
|
+
...CurrentProps,
|
|
213
227
|
...LinkProps,
|
|
214
228
|
/**
|
|
215
229
|
* Button type
|
|
@@ -225,6 +239,13 @@ const ModifiersProps = {
|
|
|
225
239
|
ariaLabel: {
|
|
226
240
|
type: String,
|
|
227
241
|
default: void 0
|
|
242
|
+
},
|
|
243
|
+
/**
|
|
244
|
+
* Default tag for the action
|
|
245
|
+
*/
|
|
246
|
+
defaultTag: {
|
|
247
|
+
type: String,
|
|
248
|
+
default: ActionTag.button
|
|
228
249
|
}
|
|
229
250
|
});
|
|
230
251
|
const VvAvatarGroupProps = {
|
|
@@ -296,13 +317,13 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
296
317
|
key: 0,
|
|
297
318
|
src: _ctx.imgSrc,
|
|
298
319
|
alt: "avatar"
|
|
299
|
-
}, null, 8, _hoisted_2)) : createCommentVNode("", true)
|
|
320
|
+
}, null, 8, _hoisted_2)) : createCommentVNode("v-if", true)
|
|
300
321
|
])
|
|
301
322
|
], 10, _hoisted_1$1);
|
|
302
323
|
};
|
|
303
324
|
}
|
|
304
325
|
});
|
|
305
|
-
const useUniqueId = (id) => computed(() => String((id == null ? void 0 : id.value) ||
|
|
326
|
+
const useUniqueId = (id) => computed(() => String((id == null ? void 0 : id.value) || uid()));
|
|
306
327
|
const _hoisted_1 = { key: 0 };
|
|
307
328
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
308
329
|
__name: "VvAvatarGroup",
|
|
@@ -335,34 +356,64 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
335
356
|
});
|
|
336
357
|
});
|
|
337
358
|
return (_ctx, _cache) => {
|
|
338
|
-
return openBlock(), createElementBlock(
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
359
|
+
return openBlock(), createElementBlock(
|
|
360
|
+
"span",
|
|
361
|
+
{
|
|
362
|
+
class: normalizeClass(unref(bemCssClasses))
|
|
363
|
+
},
|
|
364
|
+
[
|
|
365
|
+
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
366
|
+
(openBlock(true), createElementBlock(
|
|
367
|
+
Fragment,
|
|
368
|
+
null,
|
|
369
|
+
renderList(unref(avatarItems), (avatarItem) => {
|
|
370
|
+
return openBlock(), createBlock(
|
|
371
|
+
_sfc_main$1,
|
|
372
|
+
mergeProps({
|
|
373
|
+
key: avatarItem.key
|
|
374
|
+
}, {
|
|
375
|
+
modifiers: avatarItem.modifiers,
|
|
376
|
+
imgSrc: avatarItem.imgSrc
|
|
377
|
+
}),
|
|
378
|
+
{
|
|
379
|
+
default: withCtx(() => [
|
|
380
|
+
avatarItem.text ? (openBlock(), createElementBlock(
|
|
381
|
+
"span",
|
|
382
|
+
_hoisted_1,
|
|
383
|
+
toDisplayString(avatarItem.text),
|
|
384
|
+
1
|
|
385
|
+
/* TEXT */
|
|
386
|
+
)) : createCommentVNode("v-if", true)
|
|
387
|
+
]),
|
|
388
|
+
_: 2
|
|
389
|
+
/* DYNAMIC */
|
|
390
|
+
},
|
|
391
|
+
1040
|
|
392
|
+
/* FULL_PROPS, DYNAMIC_SLOTS */
|
|
393
|
+
);
|
|
394
|
+
}),
|
|
395
|
+
128
|
|
396
|
+
/* KEYED_FRAGMENT */
|
|
397
|
+
)),
|
|
398
|
+
(unref(totalItems) || unref(items).length) > unref(toShow) ? (openBlock(), createBlock(_sfc_main$1, {
|
|
399
|
+
key: 0,
|
|
400
|
+
modifiers: `${unref(stringModifiers)} surface bordered`
|
|
345
401
|
}, {
|
|
346
|
-
modifiers: avatarItem.modifiers,
|
|
347
|
-
imgSrc: avatarItem.imgSrc
|
|
348
|
-
}), {
|
|
349
402
|
default: withCtx(() => [
|
|
350
|
-
|
|
403
|
+
createTextVNode(
|
|
404
|
+
toDisplayString(`+${(unref(totalItems) || unref(items).length) - unref(toShow)}`),
|
|
405
|
+
1
|
|
406
|
+
/* TEXT */
|
|
407
|
+
)
|
|
351
408
|
]),
|
|
352
|
-
_:
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
createTextVNode(toDisplayString(`+${(unref(totalItems) || unref(items).length) - unref(toShow)}`), 1)
|
|
361
|
-
]),
|
|
362
|
-
_: 1
|
|
363
|
-
}, 8, ["modifiers"])) : createCommentVNode("", true)
|
|
364
|
-
])
|
|
365
|
-
], 2);
|
|
409
|
+
_: 1
|
|
410
|
+
/* STABLE */
|
|
411
|
+
}, 8, ["modifiers"])) : createCommentVNode("v-if", true)
|
|
412
|
+
])
|
|
413
|
+
],
|
|
414
|
+
2
|
|
415
|
+
/* CLASS */
|
|
416
|
+
);
|
|
366
417
|
};
|
|
367
418
|
}
|
|
368
419
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue"),require("
|
|
1
|
+
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue"),require("uid")):"function"==typeof define&&define.amd?define(["vue","uid"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvAvatarGroup=o(e.vue,e.uid)}(this,(function(e,o){"use strict";var t=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(t||{}),r=(e=>(e.before="before",e.after="after",e))(r||{}),a=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(a||{}),n=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(n||{});Boolean,Boolean,Boolean,Boolean;const l={modifiers:[String,Array]};r.before,t.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,a.button,n.button;const i={...l,items:{type:Array,default:()=>[],required:!0},toShow:{type:Number,default:3},totalItems:{type:Number},avatarModifiers:[String,Array]},u={...l,imgSrc:String};function s(o,t,r){return e.computed((()=>{const a={[o]:!0},n="string"==typeof(null==t?void 0:t.value)?t.value.split(" "):null==t?void 0:t.value;return n&&Array.isArray(n)&&n.forEach((e=>{e&&(a[`${o}--${e}`]=!0)})),r&&Object.keys(r.value).forEach((t=>{a[`${o}--${t}`]=e.unref(r.value[t])})),a}))}const f=["role","aria-label"],d=["src"],m=e.defineComponent({__name:"VvAvatar",props:u,setup(o){const t=o,{modifiers:r}=e.toRefs(t),a=s("vv-avatar",r);return(o,t)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(e.unref(a)),role:o.imgSrc?void 0:"img","aria-label":o.imgSrc?void 0:"avatar"},[e.renderSlot(o.$slots,"default",{},(()=>[o.imgSrc?(e.openBlock(),e.createElementBlock("img",{key:0,src:o.imgSrc,alt:"avatar"},null,8,d)):e.createCommentVNode("v-if",!0)]))],10,f))}}),c={key:0};return e.defineComponent({__name:"VvAvatarGroup",props:i,setup(t){const r=t,{modifiers:a,items:n,toShow:l,totalItems:i,avatarModifiers:u}=e.toRefs(r),f=s("vv-avatar-group",a),d=e.computed((()=>(null==u?void 0:u.value)&&Array.isArray(null==u?void 0:u.value)?u.value.join(" "):(null==u?void 0:u.value)||"")),v=e.computed((()=>n.value.slice(0,l.value).map((t=>{let r=[],a=[];return(null==u?void 0:u.value)&&(r=Array.isArray(null==u?void 0:u.value)?null==u?void 0:u.value:[null==u?void 0:u.value]),t.modifiers&&(a=Array.isArray(t.modifiers)?t.modifiers:[t.modifiers]),{...t,key:t.key||e.computed((()=>String((null==n?void 0:n.value)||o.uid()))).value,modifiers:[...r,...a]};var n}))));return(o,t)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(e.unref(f))},[e.renderSlot(o.$slots,"default",{},(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(v),(o=>(e.openBlock(),e.createBlock(m,e.mergeProps({key:o.key},{modifiers:o.modifiers,imgSrc:o.imgSrc}),{default:e.withCtx((()=>[o.text?(e.openBlock(),e.createElementBlock("span",c,e.toDisplayString(o.text),1)):e.createCommentVNode("v-if",!0)])),_:2},1040)))),128)),(e.unref(i)||e.unref(n).length)>e.unref(l)?(e.openBlock(),e.createBlock(m,{key:0,modifiers:`${e.unref(d)} surface bordered`},{default:e.withCtx((()=>[e.createTextVNode(e.toDisplayString("+"+((e.unref(i)||e.unref(n).length)-e.unref(l))),1)])),_:1},8,["modifiers"])):e.createCommentVNode("v-if",!0)]))],2))}})}));
|
|
@@ -33,6 +33,13 @@ var ButtonType = /* @__PURE__ */ ((ButtonType2) => {
|
|
|
33
33
|
ButtonType2["reset"] = "reset";
|
|
34
34
|
return ButtonType2;
|
|
35
35
|
})(ButtonType || {});
|
|
36
|
+
var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
37
|
+
ActionTag2["nuxtLink"] = "nuxt-link";
|
|
38
|
+
ActionTag2["routerLink"] = "router-link";
|
|
39
|
+
ActionTag2["a"] = "a";
|
|
40
|
+
ActionTag2["button"] = "button";
|
|
41
|
+
return ActionTag2;
|
|
42
|
+
})(ActionTag || {});
|
|
36
43
|
var AnchorTarget = /* @__PURE__ */ ((AnchorTarget2) => {
|
|
37
44
|
AnchorTarget2["_blank"] = "_blank";
|
|
38
45
|
AnchorTarget2["_self"] = "_self";
|
|
@@ -79,6 +86,12 @@ const ActiveProps = {
|
|
|
79
86
|
*/
|
|
80
87
|
active: Boolean
|
|
81
88
|
};
|
|
89
|
+
const CurrentProps = {
|
|
90
|
+
/**
|
|
91
|
+
* Whether the item is current
|
|
92
|
+
*/
|
|
93
|
+
current: Boolean
|
|
94
|
+
};
|
|
82
95
|
const PressedProps = {
|
|
83
96
|
/**
|
|
84
97
|
* Whether the item is pressed
|
|
@@ -209,6 +222,7 @@ const ModifiersProps = {
|
|
|
209
222
|
...LabelProps,
|
|
210
223
|
...PressedProps,
|
|
211
224
|
...ActiveProps,
|
|
225
|
+
...CurrentProps,
|
|
212
226
|
...LinkProps,
|
|
213
227
|
/**
|
|
214
228
|
* Button type
|
|
@@ -224,6 +238,13 @@ const ModifiersProps = {
|
|
|
224
238
|
ariaLabel: {
|
|
225
239
|
type: String,
|
|
226
240
|
default: void 0
|
|
241
|
+
},
|
|
242
|
+
/**
|
|
243
|
+
* Default tag for the action
|
|
244
|
+
*/
|
|
245
|
+
defaultTag: {
|
|
246
|
+
type: String,
|
|
247
|
+
default: ActionTag.button
|
|
227
248
|
}
|
|
228
249
|
});
|
|
229
250
|
const VvBadgeProps = {
|
|
@@ -264,14 +285,24 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
264
285
|
const { modifiers } = toRefs(props);
|
|
265
286
|
const bemCssClasses = useModifiers("vv-badge", modifiers);
|
|
266
287
|
return (_ctx, _cache) => {
|
|
267
|
-
return openBlock(), createElementBlock(
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
288
|
+
return openBlock(), createElementBlock(
|
|
289
|
+
"span",
|
|
290
|
+
{
|
|
291
|
+
class: normalizeClass(unref(bemCssClasses)),
|
|
292
|
+
role: "status"
|
|
293
|
+
},
|
|
294
|
+
[
|
|
295
|
+
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
296
|
+
createTextVNode(
|
|
297
|
+
toDisplayString(_ctx.value),
|
|
298
|
+
1
|
|
299
|
+
/* TEXT */
|
|
300
|
+
)
|
|
301
|
+
])
|
|
302
|
+
],
|
|
303
|
+
2
|
|
304
|
+
/* CLASS */
|
|
305
|
+
);
|
|
275
306
|
};
|
|
276
307
|
}
|
|
277
308
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue")):"function"==typeof define&&define.amd?define(["vue"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvBadge=o(e.vue)}(this,(function(e){"use strict";var o=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(o||{}),t=(e=>(e.before="before",e.after="after",e))(t||{}),n=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(n||{});Boolean,Boolean,Boolean;const
|
|
1
|
+
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue")):"function"==typeof define&&define.amd?define(["vue"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvBadge=o(e.vue)}(this,(function(e){"use strict";var o=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(o||{}),t=(e=>(e.before="before",e.after="after",e))(t||{}),n=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(n||{}),r=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(r||{});Boolean,Boolean,Boolean,Boolean;const l={modifiers:[String,Array]};t.before,o.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,n.button,r.button;const a={...l,value:[String,Number]};return e.defineComponent({name:"VvBadge",props:a,setup(o){const t=o,{modifiers:n}=e.toRefs(t),r=function(o,t,n){return e.computed((()=>{const r={[o]:!0},l="string"==typeof(null==t?void 0:t.value)?t.value.split(" "):null==t?void 0:t.value;return l&&Array.isArray(l)&&l.forEach((e=>{e&&(r[`${o}--${e}`]=!0)})),n&&Object.keys(n.value).forEach((t=>{r[`${o}--${t}`]=e.unref(n.value[t])})),r}))}("vv-badge",n);return(o,t)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(e.unref(r)),role:"status"},[e.renderSlot(o.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(o.value),1)]))],2))}})}));
|