@wisemen/vue-core-design-system 1.14.1 → 1.14.2
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/index.cjs +4 -2
- package/dist/index.js +5 -4
- package/package.json +5 -5
package/dist/index.cjs
CHANGED
|
@@ -269,7 +269,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
269
269
|
border-transparent
|
|
270
270
|
focus-visible:outline-fg-brand-primary
|
|
271
271
|
data-interactive:hover:bg-fg-primary/5
|
|
272
|
-
`}}}}),av=(0,f.defineComponent)({__name:`IconButtonIcon`,props:{icon:{}},setup(e){let t=e,{iconButtonStyle:n}=rv();return(e,r)=>t.icon===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createBlock)((0,f.resolveDynamicComponent)(t.icon),{key:0,class:(0,f.normalizeClass)((0,f.unref)(n).icon())},null,8,[`class`]))}}),ov=[`type`,`form`,`aria-disabled`,`disabled`,`aria-busy`,`aria-label`,`data-interactive`],X=(0,f.defineComponent)({inheritAttrs:!1,__name:`IconButton`,props:{isLoading:{type:Boolean,default:!1},isTooltipDisabled:{type:Boolean,default:!1},form:{default:null},icon:{},label:{},size:{default:`md`},tooltipLabel:{default:null},type:{default:`button`},variant:{default:`primary`},isDisabled:{type:Boolean,default:!1},disabledReason:{default:null},keyboardShortcut:{default:null}},emits:[`click`],setup(e,{emit:t}){let n=e,r=t,i=(0,f.useAttrs)(),a=(0,f.computed)(()=>iv({isLoading:n.isLoading,class:i.class,size:n.size,variant:n.variant}));function o(e){if(n.isLoading){e.preventDefault();return}r(`click`,e)}let s=(0,f.computed)(()=>n.isDisabled&&n.disabledReason!==null?!1:n.isTooltipDisabled),c=(0,f.computed)(()=>n.isDisabled&&n.disabledReason!==null?n.disabledReason:n.tooltipLabel??n.label);return nv({iconButtonStyle:a}),(e,t)=>((0,f.openBlock)(),(0,f.createBlock)(W,{"is-disabled":s.value,label:c.value,"keyboard-shortcut":n.keyboardShortcut},{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`button`,(0,f.mergeProps)((0,f.unref)(i),{type:n.type,form:n.form??void 0,"aria-disabled":n.isLoading,disabled:n.isDisabled,"aria-busy":n.isLoading,"aria-label":n.label,"data-interactive":!n.isDisabled&&!n.isLoading||void 0,class:a.value.root(),onClick:o}),[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)(a.value.container())},[(0,f.createVNode)(To,{class:(0,f.normalizeClass)(a.value.loader())},null,8,[`class`]),(0,f.createVNode)((0,f.unref)(I),{class:(0,f.normalizeClass)(a.value.rowLayout()),gap:`sm`},{default:(0,f.withCtx)(()=>[(0,f.createVNode)(av,{icon:n.icon},null,8,[`icon`])]),_:1},8,[`class`])],2)],16,ov)]),_:1},8,[`is-disabled`,`label`,`keyboard-shortcut`]))}}),sv=(0,f.defineComponent)({__name:`FormFieldGrid`,props:{lg:{},md:{},sm:{},variant:{default:`ghost`}},setup(e){let t=e,n=(0,f.computed)(()=>t.md??t.lg);return(e,r)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,{class:(0,f.normalizeClass)([{"rounded-2xl bg-secondary p-2xl":t.variant===`card`},`@container/form-field-grid w-full`])},[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)([{"grid-cols-1":t.sm===1,"grid-cols-2":t.sm===2,"grid-cols-3":t.sm===3,"@md/form-field-grid:grid-cols-1":n.value===1,"@md/form-field-grid:grid-cols-2":n.value===2,"@md/form-field-grid:grid-cols-3":n.value===3,"@lg/form-field-grid:grid-cols-1":t.lg===1,"@lg/form-field-grid:grid-cols-2":t.lg===2,"@lg/form-field-grid:grid-cols-3":t.lg===3},`grid gap-lg`]),role:`group`},[(0,f.renderSlot)(e.$slots,`default`)],2)],2))}}),cv=(0,f.defineComponent)({__name:`FormFieldGroup`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(G),{class:`w-full`,gap:`xl`},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3}))}}),lv=(0,f.defineComponent)({__name:`FormFieldSeperator`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)($o),{class:`mx-auto w-full max-w-3xl`}))}}),uv={class:`text-sm font-medium text-primary`},dv={key:0,class:`mt-sm text-xs text-tertiary`},fv=(0,f.defineComponent)({__name:`FormFieldSet`,props:{title:{},isStacked:{type:Boolean,default:!1},description:{default:null},horizontalAlignment:{default:`start`},variant:{default:`ghost`}},setup(e){let t=e;return(e,n)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,{class:(0,f.normalizeClass)([{"rounded-2xl bg-secondary p-2xl":t.variant===`card`},`@container/fieldset mx-auto w-full max-w-3xl`])},[(0,f.createElementVNode)(`section`,{class:(0,f.normalizeClass)([{"@xl/fieldset:grid-cols-[20rem_auto]":!t.isStacked},`grid gap-x-8xl gap-y-2xl`])},[(0,f.createElementVNode)(`header`,null,[(0,f.createVNode)((0,f.unref)(I),null,{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`h2`,uv,(0,f.toDisplayString)(t.title),1),t.isStacked?((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)($o),{key:0,class:`flex-1`})):(0,f.createCommentVNode)(``,!0)]),_:1}),t.description===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createElementBlock)(`p`,dv,(0,f.toDisplayString)(t.description),1))]),(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)([{"items-start":t.horizontalAlignment===`start`,"items-end":t.horizontalAlignment===`end`},`ml-auto flex w-full flex-col overflow-hidden p-xxs`])},[(0,f.renderSlot)(e.$slots,`default`)],2)],2)],2))}}),pv=(0,f.defineComponent)({__name:`FormLayout`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(G),{gap:`2xl`,align:`stretch`},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3}))}}),[mv,hv]=F(`formContext`),[gv,_v]=F(`dialogContext`),vv=V({slots:{body:`
|
|
272
|
+
`}}}}),av=(0,f.defineComponent)({__name:`IconButtonIcon`,props:{icon:{}},setup(e){let t=e,{iconButtonStyle:n}=rv();return(e,r)=>t.icon===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createBlock)((0,f.resolveDynamicComponent)(t.icon),{key:0,class:(0,f.normalizeClass)((0,f.unref)(n).icon())},null,8,[`class`]))}}),ov=[`type`,`form`,`aria-disabled`,`disabled`,`aria-busy`,`aria-label`,`data-interactive`],X=(0,f.defineComponent)({inheritAttrs:!1,__name:`IconButton`,props:{isLoading:{type:Boolean,default:!1},isTooltipDisabled:{type:Boolean,default:!1},form:{default:null},icon:{},label:{},size:{default:`md`},tooltipLabel:{default:null},type:{default:`button`},variant:{default:`primary`},isDisabled:{type:Boolean,default:!1},disabledReason:{default:null},keyboardShortcut:{default:null}},emits:[`click`],setup(e,{emit:t}){let n=e,r=t,i=(0,f.useAttrs)(),a=(0,f.computed)(()=>iv({isLoading:n.isLoading,class:i.class,size:n.size,variant:n.variant}));function o(e){if(n.isLoading){e.preventDefault();return}r(`click`,e)}let s=(0,f.computed)(()=>n.isDisabled&&n.disabledReason!==null?!1:n.isTooltipDisabled),c=(0,f.computed)(()=>n.isDisabled&&n.disabledReason!==null?n.disabledReason:n.tooltipLabel??n.label);return nv({iconButtonStyle:a}),(e,t)=>((0,f.openBlock)(),(0,f.createBlock)(W,{"is-disabled":s.value,label:c.value,"keyboard-shortcut":n.keyboardShortcut},{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`button`,(0,f.mergeProps)((0,f.unref)(i),{type:n.type,form:n.form??void 0,"aria-disabled":n.isLoading,disabled:n.isDisabled,"aria-busy":n.isLoading,"aria-label":n.label,"data-interactive":!n.isDisabled&&!n.isLoading||void 0,class:a.value.root(),onClick:o}),[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)(a.value.container())},[(0,f.createVNode)(To,{class:(0,f.normalizeClass)(a.value.loader())},null,8,[`class`]),(0,f.createVNode)((0,f.unref)(I),{class:(0,f.normalizeClass)(a.value.rowLayout()),gap:`sm`},{default:(0,f.withCtx)(()=>[(0,f.createVNode)(av,{icon:n.icon},null,8,[`icon`])]),_:1},8,[`class`])],2)],16,ov)]),_:1},8,[`is-disabled`,`label`,`keyboard-shortcut`]))}}),sv=(0,f.defineComponent)({__name:`FormFieldGrid`,props:{lg:{},md:{},sm:{},variant:{default:`ghost`}},setup(e){let t=e,n=(0,f.computed)(()=>t.md??t.lg);return(e,r)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,{class:(0,f.normalizeClass)([{"rounded-2xl bg-secondary p-2xl":t.variant===`card`},`@container/form-field-grid w-full`])},[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)([{"grid-cols-1":t.sm===1,"grid-cols-2":t.sm===2,"grid-cols-3":t.sm===3,"@md/form-field-grid:grid-cols-1":n.value===1,"@md/form-field-grid:grid-cols-2":n.value===2,"@md/form-field-grid:grid-cols-3":n.value===3,"@lg/form-field-grid:grid-cols-1":t.lg===1,"@lg/form-field-grid:grid-cols-2":t.lg===2,"@lg/form-field-grid:grid-cols-3":t.lg===3},`grid gap-lg`]),role:`group`},[(0,f.renderSlot)(e.$slots,`default`)],2)],2))}}),cv=(0,f.defineComponent)({__name:`FormFieldGroup`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(G),{class:`w-full`,gap:`xl`,align:`stretch`},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3}))}}),lv=(0,f.defineComponent)({__name:`FormFieldSeperator`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)($o),{class:`mx-auto w-full max-w-3xl`}))}}),uv={class:`text-sm font-medium text-primary`},dv={key:0,class:`mt-sm text-xs text-tertiary`},fv=(0,f.defineComponent)({__name:`FormFieldSet`,props:{title:{},isStacked:{type:Boolean,default:!1},description:{default:null},horizontalAlignment:{default:`start`},variant:{default:`ghost`}},setup(e){let t=e;return(e,n)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,{class:(0,f.normalizeClass)([{"rounded-2xl bg-secondary p-2xl":t.variant===`card`},`@container/fieldset mx-auto w-full max-w-3xl`])},[(0,f.createElementVNode)(`section`,{class:(0,f.normalizeClass)([{"@xl/fieldset:grid-cols-[20rem_auto]":!t.isStacked},`grid gap-x-8xl gap-y-2xl`])},[(0,f.createElementVNode)(`header`,null,[(0,f.createVNode)((0,f.unref)(I),null,{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`h2`,uv,(0,f.toDisplayString)(t.title),1),t.isStacked?((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)($o),{key:0,class:`flex-1`})):(0,f.createCommentVNode)(``,!0)]),_:1}),t.description===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createElementBlock)(`p`,dv,(0,f.toDisplayString)(t.description),1))]),(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)([{"items-start":t.horizontalAlignment===`start`,"items-end":t.horizontalAlignment===`end`},`ml-auto flex w-full flex-col overflow-hidden p-xxs`])},[(0,f.renderSlot)(e.$slots,`default`)],2)],2)],2))}}),pv=(0,f.defineComponent)({__name:`FormLayout`,setup(e){return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(G),{gap:`2xl`,align:`stretch`},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3}))}}),[mv,hv]=F(`formContext`),[gv,_v]=F(`dialogContext`),vv=V({slots:{body:`
|
|
273
273
|
flex-1 overflow-y-auto px-xl pt-xs pb-xl
|
|
274
274
|
group-has-data-dialog-footer/dialog:pb-xs
|
|
275
275
|
`,chin:`
|
|
@@ -937,7 +937,9 @@ Example: <UIConfigProvider :file-upload-adapter="myAdapter"><UIBaseFileUploadRoo
|
|
|
937
937
|
rounded-sm outline-fg-brand-primary
|
|
938
938
|
focus-visible:outline-2
|
|
939
939
|
disabled:cursor-not-allowed
|
|
940
|
-
`,t.class))},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3},8,[`class`]))}});function Lk(){let e=(0,f.ref)(!1),t=(0,f.shallowRef)(null),n=(0,f.computed)(()=>t.value?.isOpen.value??!1);function r(){t.value?.toggle()}function i(n,r,i){t.value={isOpen:n,isToggleHidden:i,toggle:r},e.value=!0}function a(){t.value=null,e.value=!1}fE({hasDetailPane:e,isOpen:n,isToggleHidden:(0,f.computed)(()=>t.value?.isToggleHidden??!1),registerDetailPane:i,toggle:r,unregisterDetailPane:a})}var Rk=(0,f.defineComponent)({__name:`DashboardPageHeaderBreadcrumbs`,props:{breadcrumbs:{}},setup(e){let t=e;return(e,n)=>t.breadcrumbs.length>0?((0,f.openBlock)(),(0,f.createBlock)(gT,{key:0},{default:(0,f.withCtx)(()=>[((0,f.openBlock)(!0),(0,f.createElementBlock)(f.Fragment,null,(0,f.renderList)(t.breadcrumbs,(e,n)=>((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:`${e.label}-${n}`},[(0,f.createVNode)(mT,{icon:e.icon,to:e.to,label:e.label},null,8,[`icon`,`to`,`label`]),n<t.breadcrumbs.length-1?((0,f.openBlock)(),(0,f.createBlock)(_T,{key:0})):(0,f.createCommentVNode)(``,!0)],64))),128))]),_:1})):(0,f.createCommentVNode)(``,!0)}}),zk=(0,f.defineComponent)({__name:`DashboardPageHeaderSidebarToggle`,setup(e){let{isSidebarOpen:t}=Q(),n=(0,g.useI18n)(),r=(0,p.createAction)({id:`toggle-main-sidebar`,name:()=>n.t(`action.global.toggle_main_sidebar.name`),execute:()=>{a()},group:(0,p.useActionGroup)().navigation,icon:()=>t.value?Yn:Ln,keyboardShortcut:{key:`B`,mod:!0},keywords:n.t(`action.global.toggle_main_sidebar.keywords`).split(` `)}),i=(0,f.computed)(()=>t.value?n.t(`component.dashboard_page_header_sidebar_toggle.collapse`):n.t(`component.dashboard_page_header_sidebar_toggle.expand`));function a(){t.value=!t.value}return(e,n)=>((0,f.openBlock)(),(0,f.createBlock)(W,{label:i.value,"keyboard-shortcut":{key:`B`,mod:!0}},{default:(0,f.withCtx)(()=>[(0,f.createVNode)(Cs,{action:(0,f.unref)(r),"is-current-context-only":!1},{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(Z),null,{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(h.Toggle),{"model-value":(0,f.unref)(t),"data-state":(0,f.unref)(t)?`open`:`closed`,class:`group/toggle -ml-xxs flex size-6 items-center justify-center rounded-sm duration-150 hover:bg-secondary-hover`},{default:(0,f.withCtx)(()=>[...n[0]||=[(0,f.createElementVNode)(`div`,{class:`flex h-3 w-3.5 justify-start rounded-[0.1875rem] border border-fg-tertiary p-[0.09375rem] duration-150 group-data-[state=open]/toggle:border-fg-tertiary dark:group-data-[state=open]/toggle:border-fg-secondary`},[(0,f.createElementVNode)(`div`,{class:`h-full w-0.5 rounded-[1px] bg-fg-tertiary duration-150 group-data-[state=open]/toggle:w-1 group-data-[state=open]/toggle:bg-fg-tertiary dark:group-data-[state=open]/toggle:bg-fg-secondary`})],-1)]]),_:1},8,[`model-value`,`data-state`])]),_:1})]),_:1},8,[`action`])]),_:1},8,[`label`]))}}),Bk={type:`button`,class:`flex h-7 w-full max-w-60 items-center gap-sm rounded-md! bg-fg-primary/4 pr-sm pl-md duration-100 hover:bg-fg-primary/7 hover:brightness-98 dark:bg-primary/90 dark:hover:bg-primary/90 dark:hover:brightness-110`},Vk={class:`flex-1 truncate text-left text-xxs text-placeholder`},Hk=(0,f.defineComponent)({__name:`TopBarCommandMenuSearch`,setup(e){let t=(0,g.useI18n)(),n=bS();return(e,r)=>((0,f.openBlock)(),(0,f.createBlock)(Cs,{action:(0,f.unref)(n),"is-current-context-only":!0},{default:(0,f.withCtx)(({keyboardShortcut:e})=>[(0,f.createVNode)(Z,null,{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`button`,Bk,[(0,f.createVNode)((0,f.unref)(hr),{class:`size-3.5 shrink-0 text-quaternary`}),(0,f.createElementVNode)(`span`,Vk,(0,f.toDisplayString)((0,f.unref)(t).t(`component.top_bar.search`)),1),e===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createBlock)(di,{key:0,"keyboard-shortcut":e,"is-key-hold-visualization-enabled":!0},null,8,[`keyboard-shortcut`]))])]),_:2},1024)]),_:1},8,[`action`]))}});function Uk(){let e=(0,y.useRouter)(),t=(0,f.ref)(e.options.history.state),n=(0,f.computed)(()=>t.value.back!==null),r=(0,f.computed)(()=>t.value.forward!==null);e.afterEach(()=>{t.value=e.options.history.state});function i(){n.value&&e.back()}function a(){r.value&&e.forward()}return{canGoBack:n,canGoForward:r,goBack:i,goForward:a}}var Wk=(0,f.defineComponent)({__name:`TopBarNavigationArrows`,setup(e){let t=(0,g.useI18n)(),{canGoBack:n,canGoForward:r,goBack:i,goForward:a}=Uk();return(e,o)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(I),{gap:`xxs`},{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(X),{icon:(0,f.unref)(Pt),"is-disabled":!(0,f.unref)(n),label:(0,f.unref)(t).t(`component.top_bar.navigation.back`),"keyboard-shortcut":{key:`ArrowLeft`,mod:!0},variant:`tertiary`,size:`sm`,onClick:(0,f.unref)(i)},null,8,[`icon`,`is-disabled`,`label`,`onClick`]),(0,f.createVNode)((0,f.unref)(X),{icon:(0,f.unref)(Rt),"is-disabled":!(0,f.unref)(r),label:(0,f.unref)(t).t(`component.top_bar.navigation.forward`),"keyboard-shortcut":{key:`ArrowRight`,mod:!0},variant:`tertiary`,size:`sm`,onClick:(0,f.unref)(a)},null,8,[`icon`,`is-disabled`,`label`,`onClick`])]),_:1}))}}),Gk={class:`flex shrink-0 items-center px-xl pb-md`},Kk={class:`flex flex-1 items-center`},qk={class:`sr-only`},Jk={key:3,class:`ml-lg text-xs text-primary`},Yk={class:`flex flex-1 items-center justify-center`},Xk={class:`flex h-full flex-1 items-center justify-end`},Zk=(0,f.defineComponent)({__name:`TopBar`,setup(e){let{showNavigationArrowsInTopBar:t}=J(),{title:n,breadcrumbs:r}=gE(),{hasDetailPane:i,isToggleHidden:a}=pE();return(e,o)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,Gk,[(0,f.createElementVNode)(`div`,Kk,[(0,f.createVNode)(zk),(0,f.unref)(r).length>0||(0,f.unref)(n)!==null?((0,f.openBlock)(),(0,f.createBlock)($o,{key:0,class:`ml-sm h-4`,orientation:`vertical`})):(0,f.createCommentVNode)(``,!0),(0,f.unref)(t)?((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:1},[(0,f.createVNode)(Wk,{class:`ml-sm`}),(0,f.unref)(r).length>0||(0,f.unref)(n)!==null?((0,f.openBlock)(),(0,f.createBlock)($o,{key:0,class:`ml-sm h-4`,orientation:`vertical`})):(0,f.createCommentVNode)(``,!0)],64)):(0,f.createCommentVNode)(``,!0),(0,f.unref)(r).length>0?((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:2},[(0,f.createElementVNode)(`h1`,qk,(0,f.toDisplayString)((0,f.unref)(n)),1),(0,f.createVNode)(Rk,{breadcrumbs:(0,f.unref)(r),class:`ml-lg`},null,8,[`breadcrumbs`])],64)):(0,f.unref)(n)===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createElementBlock)(`h1`,Jk,(0,f.toDisplayString)((0,f.unref)(n)),1))]),(0,f.createElementVNode)(`div`,Yk,[(0,f.createVNode)(Hk)]),(0,f.createElementVNode)(`div`,Xk,[(0,f.renderSlot)(e.$slots,`actions`),(0,f.unref)(i)&&!(0,f.unref)(a)?((0,f.openBlock)(),(0,f.createBlock)(QE,{key:0})):(0,f.createCommentVNode)(``,!0)])]))}}),Qk=(0,f.defineComponent)({__name:`MainContent`,setup(e){let{isFloatingSidebar:t,isSidebarOpen:n,collapsedVariant:r,sidebarWidth:i}=Q(),a=np();Lk();let{isBrandedActive:o}=Gx(),s=(0,f.computed)(()=>t.value?`0.5rem`:r.value===`minified`||n.value?i.value:`0.5rem`);return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(_.Motion),{initial:{paddingLeft:s.value},animate:{paddingLeft:s.value},transition:{duration:(0,f.unref)(a)?0:.3,type:`spring`,bounce:0},class:(0,f.normalizeClass)([(0,f.unref)(o)?null:`bg-secondary`,`flex size-full flex-col overflow-hidden p-md`])},{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)((0,f.unref)(o)?[`default`,`branded`]:null)},[(0,f.createVNode)(Zk,null,{actions:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`top-bar-actions`)]),_:3})],2),(0,f.renderSlot)(e.$slots,`default`)]),_:3},8,[`initial`,`animate`,`transition`,`class`]))}}),$k={},eA={width:`360`,height:`585`,viewBox:`0 0 360 585`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,class:`pointer-events-none absolute bottom-0 left-0`};function tA(e,t){return(0,f.openBlock)(),(0,f.createElementBlock)(`svg`,eA,[...t[0]||=[(0,f.createStaticVNode)(`<g opacity="0.4" filter="url(#filter0_f_5410_8853)"><path d="M-39 642L13.5 84L74.5 525L276 577.5L-39 642Z" class="fill-corner-highlight"></path></g><defs><filter id="filter0_f_5410_8853" x="-123" y="0" width="483" height="726" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur stdDeviation="42" result="effect1_foregroundBlur_5410_8853"></feGaussianBlur></filter></defs>`,2)]])}var nA=H($k,[[`render`,tA]]),rA=(0,f.defineComponent)({__name:`MainLayout`,props:{variant:{default:`default`}},setup(e){let t=e,
|
|
940
|
+
`,t.class))},{default:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`default`)]),_:3},8,[`class`]))}});function Lk(){let e=(0,f.ref)(!1),t=(0,f.shallowRef)(null),n=(0,f.computed)(()=>t.value?.isOpen.value??!1);function r(){t.value?.toggle()}function i(n,r,i){t.value={isOpen:n,isToggleHidden:i,toggle:r},e.value=!0}function a(){t.value=null,e.value=!1}fE({hasDetailPane:e,isOpen:n,isToggleHidden:(0,f.computed)(()=>t.value?.isToggleHidden??!1),registerDetailPane:i,toggle:r,unregisterDetailPane:a})}var Rk=(0,f.defineComponent)({__name:`DashboardPageHeaderBreadcrumbs`,props:{breadcrumbs:{}},setup(e){let t=e;return(e,n)=>t.breadcrumbs.length>0?((0,f.openBlock)(),(0,f.createBlock)(gT,{key:0},{default:(0,f.withCtx)(()=>[((0,f.openBlock)(!0),(0,f.createElementBlock)(f.Fragment,null,(0,f.renderList)(t.breadcrumbs,(e,n)=>((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:`${e.label}-${n}`},[(0,f.createVNode)(mT,{icon:e.icon,to:e.to,label:e.label},null,8,[`icon`,`to`,`label`]),n<t.breadcrumbs.length-1?((0,f.openBlock)(),(0,f.createBlock)(_T,{key:0})):(0,f.createCommentVNode)(``,!0)],64))),128))]),_:1})):(0,f.createCommentVNode)(``,!0)}}),zk=(0,f.defineComponent)({__name:`DashboardPageHeaderSidebarToggle`,setup(e){let{isSidebarOpen:t}=Q(),n=(0,g.useI18n)(),r=(0,p.createAction)({id:`toggle-main-sidebar`,name:()=>n.t(`action.global.toggle_main_sidebar.name`),execute:()=>{a()},group:(0,p.useActionGroup)().navigation,icon:()=>t.value?Yn:Ln,keyboardShortcut:{key:`B`,mod:!0},keywords:n.t(`action.global.toggle_main_sidebar.keywords`).split(` `)}),i=(0,f.computed)(()=>t.value?n.t(`component.dashboard_page_header_sidebar_toggle.collapse`):n.t(`component.dashboard_page_header_sidebar_toggle.expand`));function a(){t.value=!t.value}return(e,n)=>((0,f.openBlock)(),(0,f.createBlock)(W,{label:i.value,"keyboard-shortcut":{key:`B`,mod:!0}},{default:(0,f.withCtx)(()=>[(0,f.createVNode)(Cs,{action:(0,f.unref)(r),"is-current-context-only":!1},{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(Z),null,{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(h.Toggle),{"model-value":(0,f.unref)(t),"data-state":(0,f.unref)(t)?`open`:`closed`,class:`group/toggle -ml-xxs flex size-6 items-center justify-center rounded-sm duration-150 hover:bg-secondary-hover`},{default:(0,f.withCtx)(()=>[...n[0]||=[(0,f.createElementVNode)(`div`,{class:`flex h-3 w-3.5 justify-start rounded-[0.1875rem] border border-fg-tertiary p-[0.09375rem] duration-150 group-data-[state=open]/toggle:border-fg-tertiary dark:group-data-[state=open]/toggle:border-fg-secondary`},[(0,f.createElementVNode)(`div`,{class:`h-full w-0.5 rounded-[1px] bg-fg-tertiary duration-150 group-data-[state=open]/toggle:w-1 group-data-[state=open]/toggle:bg-fg-tertiary dark:group-data-[state=open]/toggle:bg-fg-secondary`})],-1)]]),_:1},8,[`model-value`,`data-state`])]),_:1})]),_:1},8,[`action`])]),_:1},8,[`label`]))}}),Bk={type:`button`,class:`flex h-7 w-full max-w-60 items-center gap-sm rounded-md! bg-fg-primary/4 pr-sm pl-md duration-100 hover:bg-fg-primary/7 hover:brightness-98 dark:bg-primary/90 dark:hover:bg-primary/90 dark:hover:brightness-110`},Vk={class:`flex-1 truncate text-left text-xxs text-placeholder`},Hk=(0,f.defineComponent)({__name:`TopBarCommandMenuSearch`,setup(e){let t=(0,g.useI18n)(),n=bS();return(e,r)=>((0,f.openBlock)(),(0,f.createBlock)(Cs,{action:(0,f.unref)(n),"is-current-context-only":!0},{default:(0,f.withCtx)(({keyboardShortcut:e})=>[(0,f.createVNode)(Z,null,{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`button`,Bk,[(0,f.createVNode)((0,f.unref)(hr),{class:`size-3.5 shrink-0 text-quaternary`}),(0,f.createElementVNode)(`span`,Vk,(0,f.toDisplayString)((0,f.unref)(t).t(`component.top_bar.search`)),1),e===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createBlock)(di,{key:0,"keyboard-shortcut":e,"is-key-hold-visualization-enabled":!0},null,8,[`keyboard-shortcut`]))])]),_:2},1024)]),_:1},8,[`action`]))}});function Uk(){let e=(0,y.useRouter)(),t=(0,f.ref)(e.options.history.state),n=(0,f.computed)(()=>t.value.back!==null),r=(0,f.computed)(()=>t.value.forward!==null);e.afterEach(()=>{t.value=e.options.history.state});function i(){n.value&&e.back()}function a(){r.value&&e.forward()}return{canGoBack:n,canGoForward:r,goBack:i,goForward:a}}var Wk=(0,f.defineComponent)({__name:`TopBarNavigationArrows`,setup(e){let t=(0,g.useI18n)(),{canGoBack:n,canGoForward:r,goBack:i,goForward:a}=Uk();return(e,o)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(I),{gap:`xxs`},{default:(0,f.withCtx)(()=>[(0,f.createVNode)((0,f.unref)(X),{icon:(0,f.unref)(Pt),"is-disabled":!(0,f.unref)(n),label:(0,f.unref)(t).t(`component.top_bar.navigation.back`),"keyboard-shortcut":{key:`ArrowLeft`,mod:!0},variant:`tertiary`,size:`sm`,onClick:(0,f.unref)(i)},null,8,[`icon`,`is-disabled`,`label`,`onClick`]),(0,f.createVNode)((0,f.unref)(X),{icon:(0,f.unref)(Rt),"is-disabled":!(0,f.unref)(r),label:(0,f.unref)(t).t(`component.top_bar.navigation.forward`),"keyboard-shortcut":{key:`ArrowRight`,mod:!0},variant:`tertiary`,size:`sm`,onClick:(0,f.unref)(a)},null,8,[`icon`,`is-disabled`,`label`,`onClick`])]),_:1}))}}),Gk={class:`flex shrink-0 items-center px-xl pb-md`},Kk={class:`flex flex-1 items-center`},qk={class:`sr-only`},Jk={key:3,class:`ml-lg text-xs text-primary`},Yk={class:`flex flex-1 items-center justify-center`},Xk={class:`flex h-full flex-1 items-center justify-end`},Zk=(0,f.defineComponent)({__name:`TopBar`,setup(e){let{showNavigationArrowsInTopBar:t}=J(),{title:n,breadcrumbs:r}=gE(),{hasDetailPane:i,isToggleHidden:a}=pE();return(e,o)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,Gk,[(0,f.createElementVNode)(`div`,Kk,[(0,f.createVNode)(zk),(0,f.unref)(r).length>0||(0,f.unref)(n)!==null?((0,f.openBlock)(),(0,f.createBlock)($o,{key:0,class:`ml-sm h-4`,orientation:`vertical`})):(0,f.createCommentVNode)(``,!0),(0,f.unref)(t)?((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:1},[(0,f.createVNode)(Wk,{class:`ml-sm`}),(0,f.unref)(r).length>0||(0,f.unref)(n)!==null?((0,f.openBlock)(),(0,f.createBlock)($o,{key:0,class:`ml-sm h-4`,orientation:`vertical`})):(0,f.createCommentVNode)(``,!0)],64)):(0,f.createCommentVNode)(``,!0),(0,f.unref)(r).length>0?((0,f.openBlock)(),(0,f.createElementBlock)(f.Fragment,{key:2},[(0,f.createElementVNode)(`h1`,qk,(0,f.toDisplayString)((0,f.unref)(n)),1),(0,f.createVNode)(Rk,{breadcrumbs:(0,f.unref)(r),class:`ml-lg`},null,8,[`breadcrumbs`])],64)):(0,f.unref)(n)===null?(0,f.createCommentVNode)(``,!0):((0,f.openBlock)(),(0,f.createElementBlock)(`h1`,Jk,(0,f.toDisplayString)((0,f.unref)(n)),1))]),(0,f.createElementVNode)(`div`,Yk,[(0,f.createVNode)(Hk)]),(0,f.createElementVNode)(`div`,Xk,[(0,f.renderSlot)(e.$slots,`actions`),(0,f.unref)(i)&&!(0,f.unref)(a)?((0,f.openBlock)(),(0,f.createBlock)(QE,{key:0})):(0,f.createCommentVNode)(``,!0)])]))}}),Qk=(0,f.defineComponent)({__name:`MainContent`,setup(e){let{isFloatingSidebar:t,isSidebarOpen:n,collapsedVariant:r,sidebarWidth:i}=Q(),a=np();Lk();let{isBrandedActive:o}=Gx(),s=(0,f.computed)(()=>t.value?`0.5rem`:r.value===`minified`||n.value?i.value:`0.5rem`);return(e,t)=>((0,f.openBlock)(),(0,f.createBlock)((0,f.unref)(_.Motion),{initial:{paddingLeft:s.value},animate:{paddingLeft:s.value},transition:{duration:(0,f.unref)(a)?0:.3,type:`spring`,bounce:0},class:(0,f.normalizeClass)([(0,f.unref)(o)?null:`bg-secondary`,`flex size-full flex-col overflow-hidden p-md`])},{default:(0,f.withCtx)(()=>[(0,f.createElementVNode)(`div`,{class:(0,f.normalizeClass)((0,f.unref)(o)?[`default`,`branded`]:null)},[(0,f.createVNode)(Zk,null,{actions:(0,f.withCtx)(()=>[(0,f.renderSlot)(e.$slots,`top-bar-actions`)]),_:3})],2),(0,f.renderSlot)(e.$slots,`default`)]),_:3},8,[`initial`,`animate`,`transition`,`class`]))}}),$k={},eA={width:`360`,height:`585`,viewBox:`0 0 360 585`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,class:`pointer-events-none absolute bottom-0 left-0`};function tA(e,t){return(0,f.openBlock)(),(0,f.createElementBlock)(`svg`,eA,[...t[0]||=[(0,f.createStaticVNode)(`<g opacity="0.4" filter="url(#filter0_f_5410_8853)"><path d="M-39 642L13.5 84L74.5 525L276 577.5L-39 642Z" class="fill-corner-highlight"></path></g><defs><filter id="filter0_f_5410_8853" x="-123" y="0" width="483" height="726" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"></feBlend><feGaussianBlur stdDeviation="42" result="effect1_foregroundBlur_5410_8853"></feGaussianBlur></filter></defs>`,2)]])}var nA=H($k,[[`render`,tA]]),rA=(0,f.defineComponent)({__name:`MainLayout`,props:{variant:{default:`default`}},setup(e){let t=e,n=(0,f.computed)(()=>t.variant===`branded`);return Ux({isBrandedActive:n,variant:(0,f.computed)(()=>t.variant)}),(e,t)=>((0,f.openBlock)(),(0,f.createElementBlock)(`div`,{class:(0,f.normalizeClass)([n.value?`
|
|
941
|
+
light:bg-linear-to-tr light:from-brand-950 light:to-brand-800
|
|
942
|
+
`:null,`relative flex h-dvh w-full overflow-hidden`])},[(0,f.renderSlot)(e.$slots,`default`),(0,f.createVNode)(nA,{class:(0,f.normalizeClass)(n.value?`light:hidden`:null)},null,8,[`class`])],2))}}),iA=V({slots:{input:`
|
|
941
943
|
size-full truncate bg-transparent px-md text-xs text-primary outline-none
|
|
942
944
|
placeholder:text-placeholder
|
|
943
945
|
read-only:cursor-default
|
package/dist/index.js
CHANGED
|
@@ -20430,7 +20430,8 @@ var [lS, uS] = K("buttonContext"), dS = Z({
|
|
|
20430
20430
|
setup(e) {
|
|
20431
20431
|
return (e, t) => (A(), s(R($), {
|
|
20432
20432
|
class: "w-full",
|
|
20433
|
-
gap: "xl"
|
|
20433
|
+
gap: "xl",
|
|
20434
|
+
align: "stretch"
|
|
20434
20435
|
}, {
|
|
20435
20436
|
default: H(() => [P(e.$slots, "default")]),
|
|
20436
20437
|
_: 3
|
|
@@ -33570,11 +33571,11 @@ var wP = /*#__PURE__*/ _u(xP, [["render", CP]]), TP = /* @__PURE__ */ h({
|
|
|
33570
33571
|
__name: "MainLayout",
|
|
33571
33572
|
props: { variant: { default: "default" } },
|
|
33572
33573
|
setup(e) {
|
|
33573
|
-
let t = e,
|
|
33574
|
+
let t = e, n = o(() => t.variant === "branded");
|
|
33574
33575
|
return uE({
|
|
33575
|
-
isBrandedActive:
|
|
33576
|
+
isBrandedActive: n,
|
|
33576
33577
|
variant: o(() => t.variant)
|
|
33577
|
-
}), (e, t) => (A(), l("div", { class: E([
|
|
33578
|
+
}), (e, t) => (A(), l("div", { class: E([n.value ? "\n light:bg-linear-to-tr light:from-brand-950 light:to-brand-800\n " : null, "relative flex h-dvh w-full overflow-hidden"]) }, [P(e.$slots, "default"), m(wP, { class: E(n.value ? "light:hidden" : null) }, null, 8, ["class"])], 2));
|
|
33578
33579
|
}
|
|
33579
33580
|
}), EP = Z({
|
|
33580
33581
|
slots: {
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
6
|
"type": "module",
|
|
7
|
-
"version": "1.14.
|
|
7
|
+
"version": "1.14.2",
|
|
8
8
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
@@ -66,9 +66,9 @@
|
|
|
66
66
|
"vue-component-type-helpers": "3.3.0",
|
|
67
67
|
"vue-sonner": "2.0.9",
|
|
68
68
|
"@wisemen/vue-core-api-utils": "2.0.5",
|
|
69
|
-
"@wisemen/vue-core-
|
|
69
|
+
"@wisemen/vue-core-utils": "0.1.1",
|
|
70
70
|
"@wisemen/vue-core-icons": "0.0.3",
|
|
71
|
-
"@wisemen/vue-core-
|
|
71
|
+
"@wisemen/vue-core-dates": "1.1.0"
|
|
72
72
|
},
|
|
73
73
|
"devDependencies": {
|
|
74
74
|
"@chromatic-com/storybook": "5.0.2",
|
|
@@ -102,11 +102,11 @@
|
|
|
102
102
|
"vue-router": "^4.6.4",
|
|
103
103
|
"vue-tsc": "3.2.2",
|
|
104
104
|
"zod": "4.3.5",
|
|
105
|
-
"@wisemen/vue-core-actions": "0.2.2",
|
|
106
105
|
"@wisemen/eslint-config-vue": "2.1.4",
|
|
106
|
+
"@wisemen/vue-core-actions": "0.2.2",
|
|
107
107
|
"@wisemen/vue-core-dates": "1.1.0",
|
|
108
108
|
"formango": "3.2.5",
|
|
109
|
-
"@wisemen/vue-core-tailwind-config": "0.1.
|
|
109
|
+
"@wisemen/vue-core-tailwind-config": "0.1.1"
|
|
110
110
|
},
|
|
111
111
|
"scripts": {
|
|
112
112
|
"build": "vite build",
|