@codeandfunction/callaloo 4.9.5 → 4.9.6
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/callaloo.global.js +1 -1
- package/dist/chunks/{CLButton.vue_vue_type_style_index_0_lang-3vGTMU-k.js → CLButton.vue_vue_type_style_index_0_lang-hEXnJ7H1.js} +1 -1
- package/dist/chunks/{CLCalendar.vue_vue_type_style_index_0_lang-BAfGE35e.js → CLCalendar.vue_vue_type_style_index_0_lang-BqrGuMVB.js} +1 -1
- package/dist/chunks/{CLCard.vue_vue_type_style_index_0_lang-DPQxSLkQ.js → CLCard.vue_vue_type_style_index_0_lang-BGKjh5vA.js} +1 -1
- package/dist/chunks/CLIcon.vue_vue_type_style_index_0_lang-Cjt6fX90.js +2 -0
- package/dist/chunks/{CLLink.vue_vue_type_style_index_0_lang-CCyY39MJ.js → CLLink.vue_vue_type_style_index_0_lang-C9_EwMBi.js} +1 -1
- package/dist/chunks/{CLModal.vue_vue_type_style_index_0_lang-CwdYGfO9.js → CLModal.vue_vue_type_style_index_0_lang-DroQPRWC.js} +1 -1
- package/dist/chunks/{CLNavLink.vue_vue_type_script_setup_true_lang-Ds2aJNK9.js → CLNavLink.vue_vue_type_script_setup_true_lang-Dqr8A_2Z.js} +1 -1
- package/dist/chunks/{CLPill.vue_vue_type_style_index_0_lang-BVsLNnfE.js → CLPill.vue_vue_type_style_index_0_lang-DCtH-u0_.js} +1 -1
- package/dist/chunks/{CLToast.vue_vue_type_style_index_0_lang-BIehrtqC.js → CLToast.vue_vue_type_style_index_0_lang-CtXJMlF9.js} +1 -1
- package/dist/components/Buttons/CLButton/CLButton.js +1 -1
- package/dist/components/CLIcon/CLIcon.js +1 -1
- package/dist/components/Containers/CLCard/CLCard.js +1 -1
- package/dist/components/Containers/CLCarousel/CLCarousel.js +1 -1
- package/dist/components/Containers/CLDisclosure/CLDisclosure.js +1 -1
- package/dist/components/Form/CLCalendar/CLCalendar.js +1 -1
- package/dist/components/Form/CLCheckbox/CLCheckbox.js +1 -1
- package/dist/components/Form/CLInput/CLInput.js +1 -1
- package/dist/components/Form/CLInputDatePicker/CLInputDatePicker.js +1 -1
- package/dist/components/Form/CLSelect/CLSelect.js +1 -1
- package/dist/components/Indicators/CLBanner/CLBanner.js +1 -1
- package/dist/components/Indicators/CLPill/CLPill.js +1 -1
- package/dist/components/Modals/CLModal/CLModal.js +1 -1
- package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.js +1 -1
- package/dist/components/Navigation/CLLink/CLLink.js +1 -1
- package/dist/components/Navigation/CLNavLink/CLNavLink.js +1 -1
- package/dist/components/Navigation/CLNavSection/CLNavSection.js +1 -1
- package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.js +1 -1
- package/dist/components/Popups/CLToast/CLToast.js +1 -1
- package/dist/components/Providers/CLToastProvider/CLToastProvider.js +1 -1
- package/dist/composables/useDatePicker.js +1 -1
- package/package.json +1 -1
- package/dist/chunks/CLIcon.vue_vue_type_style_index_0_lang-yF4CdZbV.js +0 -2
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
2
|
import './CLLink.css';
|
|
3
|
-
import{_ as e}from"../../../chunks/CLLink.vue_vue_type_style_index_0_lang-
|
|
3
|
+
import{_ as e}from"../../../chunks/CLLink.vue_vue_type_style_index_0_lang-C9_EwMBi.js";export{e as CLLink,e as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
|
-
import{_ as a}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-
|
|
2
|
+
import{_ as a}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-Dqr8A_2Z.js";export{a as CLNavLink,a as default};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
2
|
import './CLNavSection.css';
|
|
3
|
-
import{defineComponent as e,computed as t,createElementBlock as a,openBlock as l,normalizeClass as r,unref as n,Fragment as i,renderList as o,createVNode as s,withCtx as c,createTextVNode as _,toDisplayString as u}from"vue";import{_ as d}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-
|
|
3
|
+
import{defineComponent as e,computed as t,createElementBlock as a,openBlock as l,normalizeClass as r,unref as n,Fragment as i,renderList as o,createVNode as s,withCtx as c,createTextVNode as _,toDisplayString as u}from"vue";import{_ as d}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-Dqr8A_2Z.js";import{_ as p}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CMXJdE-D.js";import{CLOrientation as f,CLColors as m}from"../../../index.js";const v=["data-testid"],k=/* @__PURE__ */e({name:"CLNavSection",__name:"CLNavSection",props:{color:{default:m.Primary},navItems:{},testId:{default:"clll-nav-section"},type:{default:f.Horizontal}},setup(e){const f=e,m="clll-nav-section",k=t(()=>[m,`${m}--${f.type}`]);return(t,f)=>(l(),a("ul",{class:r(n(k)),"data-testid":e.testId},[(l(!0),a(i,null,o(e.navItems,(t,r)=>(l(),a("li",{key:`link-${t.id}-${r}`,class:"clll-nav-section__item"},[s(n(d),{id:t.id,"aria-label":t.ariaLabel,color:e.color,external:t.external,href:t.href,rel:t.rel,target:t.target,"on-click":t.onClick},{default:c(()=>[s(n(p),{as:"span"},{default:c(()=>[_(u(t.label),1)]),_:2},1024)]),_:2},1032,["id","aria-label","color","external","href","rel","target","on-click"])]))),128))],10,v))}});export{k as CLNavSection,k as default};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
2
|
import './CLDropdownMenu.css';
|
|
3
|
-
import{defineComponent as e,ref as o,computed as t,onBeforeUnmount as n,createElementBlock as a,openBlock as d,normalizeClass as r,createVNode as l,createCommentVNode as i,unref as s,withCtx as u,createTextVNode as c,toDisplayString as p,normalizeStyle as b,renderSlot as f}from"vue";import{u as m,a as _,f as v,o as w,s as h}from"../../../chunks/floating-ui.vue-C0JWy0Dz.js";import{_ as y}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-
|
|
3
|
+
import{defineComponent as e,ref as o,computed as t,onBeforeUnmount as n,createElementBlock as a,openBlock as d,normalizeClass as r,createVNode as l,createCommentVNode as i,unref as s,withCtx as u,createTextVNode as c,toDisplayString as p,normalizeStyle as b,renderSlot as f}from"vue";import{u as m,a as _,f as v,o as w,s as h}from"../../../chunks/floating-ui.vue-C0JWy0Dz.js";import{_ as y}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-hEXnJ7H1.js";import{_ as g}from"../../../chunks/CLCard.vue_vue_type_style_index_0_lang-BGKjh5vA.js";import{c as B,i as $}from"../../../chunks/helper-C542dSLs.js";import{useDropdown as z}from"../../../composables/useDropdown.js";import{useEsc as x}from"../../../composables/useEsc.js";import{CLPlacement as I,CLIconSizes as k,CLIconNames as E,CLColorVariants as L,CLSizes as C,CLColors as D}from"../../../index.js";const S=["data-testid"],H=["id","aria-labelledby","aria-hidden"],j=/* @__PURE__ */e({name:"CLDropdownMenu",__name:"CLDropdownMenu",props:{buttonAriaLabel:{},buttonBorderRadius:{},buttonBusy:{type:Boolean},buttonColor:{default:D.Secondary},buttonDisabled:{type:Boolean},buttonHeight:{default:"auto"},buttonSize:{default:C.Small},buttonVariant:{default:L.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean},containerBordered:{type:Boolean,default:!0},containerBorderRadius:{},containerElevated:{type:Boolean,default:!1},contentWidth:{default:"auto"},dropdownId:{},iconAfter:{default:E.ChevronDown},iconBefore:{},iconSize:{default:k.Tiny},isOpen:{type:Boolean,default:!1},label:{},onCloseHandler:{},onOpenHandler:{},placement:{default:I.BottomStart},testId:{default:"clll-dropdown-menu"},zIndex:{default:30}},setup(e,{expose:I}){const k=e;let E=o(),C=o();const j=o(),O=o(),W=o(k.isOpen),R=o(k.placement),A="clll-dropdown-menu",M=t(()=>"auto"===k.zIndex||B(k.zIndex)?k.zIndex:k.zIndex.toString()),V=e=>{e&&(E.value=e)},G=e=>{e&&(C.value=e)},N=()=>{T.value?F():q()},{open:T,openDropdown:q,closeDropdown:F,clearEventListeners:J}=z({triggerElem:E,dropdownRef:O,openDropdownHandler:()=>{W.value=!0,k?.onOpenHandler?.(),P(),$&&document.addEventListener("click",Q)},closeDropdownHandler:()=>{W.value=!1,k?.onCloseHandler?.(),$&&document.removeEventListener("click",Q),U(),J()}});I({close:()=>{F(),J(),U()},open:()=>{q()}});const{floatingStyles:K,update:P}=m(j,O,{middleware:[v(),w(10),h()],placement:R,open:W,whileElementsMounted:_}),Q=e=>{W.value&&O.value?.contains(e?.target)&&F()},{clearEventListeners:U}=x({escHandler:F,triggerElem:E});return n(()=>{$&&document.removeEventListener("click",Q),U(),J()}),(o,t)=>(d(),a("div",{class:r([`${A}__menu`]),"data-testid":e.testId},[l(s(y),{id:`${A}__toggle--${e.dropdownId}`,ref_key:"anchor",ref:j,"aria-controls":`${A}--${e.dropdownId}`,"aria-expanded":s(W)||e.isOpen,"aria-label":e.buttonAriaLabel,busy:e.buttonBusy,disabled:e.buttonDisabled||e.buttonBusy,class:r(`${A}__toggle`),color:e.buttonColor,"border-radius":e.buttonBorderRadius,"forward-ref":V,height:e.buttonHeight,"icon-after":e.iconAfter,"icon-before":e.iconBefore,"icon-size":e.iconSize,size:e.buttonSize,"test-id":`${A}__toggle`,variant:e.buttonVariant,width:e.buttonWidth,wrap:e.buttonWrapped,"on-click":N},{default:u(()=>[c(p(e.label),1)]),_:1},8,["id","aria-controls","aria-expanded","aria-label","busy","disabled","class","color","border-radius","height","icon-after","icon-before","icon-size","size","test-id","variant","width","wrap"]),s(W)||e.isOpen?(d(),a("div",{key:0,id:`${A}--${e.dropdownId}`,ref_key:"dropdownElem",ref:O,"aria-labelledby":`${A}__toggle--${e.dropdownId}`,"aria-hidden":!(s(W)||e.isOpen),class:r([`${A}__dropdown`,`${A}__dropdown--${s(R)}`]),style:b({...s(K),zIndex:s(M)})},[l(s(g),{bordered:e.containerBordered,"border-radius":e.containerBorderRadius,color:s(D).Neutral,elevated:e.containerElevated,"forward-ref":G,padded:!1,"test-id":`${A}__content`,variant:s(L).Ghost,width:e.contentWidth},{default:u(()=>[f(o.$slots,"content")]),_:3},8,["bordered","border-radius","color","elevated","test-id","variant","width"])],14,H)):i("",!0)],10,S))}});export{j as CLDropdownMenu,j as default};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
2
|
import './CLToast.css';
|
|
3
|
-
import{_ as s}from"../../../chunks/CLToast.vue_vue_type_style_index_0_lang-
|
|
3
|
+
import{_ as s}from"../../../chunks/CLToast.vue_vue_type_style_index_0_lang-CtXJMlF9.js";export{s as CLToast,s as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import '../../../assets/core.css';
|
|
2
|
-
import{defineComponent as s,ref as i,provide as o,createElementBlock as e,openBlock as r,createBlock as a,createCommentVNode as t,renderSlot as d,unref as u,mergeProps as l}from"vue";import{_ as m}from"../../../chunks/CLToast.vue_vue_type_style_index_0_lang-
|
|
2
|
+
import{defineComponent as s,ref as i,provide as o,createElementBlock as e,openBlock as r,createBlock as a,createCommentVNode as t,renderSlot as d,unref as u,mergeProps as l}from"vue";import{_ as m}from"../../../chunks/CLToast.vue_vue_type_style_index_0_lang-CtXJMlF9.js";import{T as n}from"../../../chunks/context-JmPivI9V.js";const v={class:"clll-toast-provider"},p=/* @__PURE__ */s({name:"CLToastProvider",__name:"CLToastProvider",props:{borderRadius:{},dismissTimer:{},position:{}},setup(s){const p=s,T=i({}),_=i(!1),c=()=>{_.value=!1,T.value={}};return o(n,{visible:_,showToast:s=>{T.value={...s,borderRadius:s.borderRadius??p.borderRadius,dismissTimer:s.dismissTimer??p.dismissTimer,position:s.position??p.position},_.value=!0},hideToast:c}),(s,i)=>(r(),e("div",v,[_.value?(r(),a(u(m),l({key:0},T.value,{"on-dismiss":c}),null,16)):t("",!0),d(s.$slots,"default")]))}});export{p as CLToastProvider,n as ToastInjectionKey,p as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import '../assets/core.css';
|
|
2
|
-
import{ref as e,
|
|
2
|
+
import{ref as e,onMounted as a,computed as t,unref as l}from"vue";const u=({appliedEnd:u,appliedStart:n,isRange:r=!0}={})=>{const o=e(/* @__PURE__ */new Date),v=e(null),i=e(null),g=e(!1);a(()=>{g.value=!0});const d=e=>`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`,D=e=>/* @__PURE__ */new Date(`${e}T00:00:00`),s=e=>g.value?D(e).toLocaleDateString("default",{day:"numeric",month:"long",weekday:"long",year:"numeric"}):e,c=e=>{const a=D(e);return`${a.getMonth()+1}/${String(a.getDate())}`},h=e=>{const a=D(e);return`${a.getMonth()+1}/${String(a.getDate())}/${String(a.getFullYear()).slice(-2)}`},f=()=>{const e=n?.value?D(n.value):/* @__PURE__ */new Date;o.value=new Date(e.getFullYear(),e.getMonth(),1)},$=t(()=>{if(!g.value){return`${o.value.getMonth()+1}/${o.value.getFullYear()}`}return o.value.toLocaleString("default",{month:"long",year:"numeric"})}),S=t(()=>{const e=n?.value??null,a=u?.value??null;if(!e)return;if(!l(r))return h(e);if(!a)return h(e);return D(e).getFullYear()!==D(a).getFullYear()?`${h(e)} - ${h(a)}`:`${c(e)} - ${c(a)}`}),m=e=>i.value===e,M=e=>v.value===e,w=e=>!!l(r)&&(!!i.value&&(v.value?e>=i.value&&e<=v.value:e===i.value));return{calendarGrid:t(()=>{const e=o.value.getFullYear(),a=o.value.getMonth(),t=new Date(e,a,1),l=new Date(e,a+1,0).getDate(),u=new Date(e,a,0).getDate(),n=t.getDay(),r=[];for(let o=0;o<n;o++){const t=u-(n-1-o),l=d(new Date(e,a-1,t));r.push({day:t,date:l,isOutsideMonth:!0})}for(let o=1;o<=l;o++){const t=d(new Date(e,a,o));r.push({day:o,date:t,isOutsideMonth:!1})}let v=1;for(;r.length<42;){const t=d(new Date(e,a+1,v));r.push({day:v,date:t,isOutsideMonth:!0}),v++}return r}),cancelDraft:()=>{i.value=n?.value??null,v.value=u?.value??null},clearDraft:()=>{n&&(n.value=null),u&&(u.value=null),i.value=null,v.value=null},currentDate:o,currentMonthLabel:$,draftEnd:v,draftStart:i,formatDateToISO:d,formatHumanDate:e=>g.value?D(e).toLocaleDateString("default",{day:"numeric",month:"short",year:"numeric"}):e,formatLongDate:s,formatShortNoYear:c,formatShortWithYear:h,getDayAriaLabel:e=>l(r)?m(e)?`${s(e)} (start date)`:M(e)?`${s(e)} (end date)`:w(e)?`${s(e)} (in range)`:s(e):m(e)?`${s(e)} (selected)`:s(e),handleNextMonth:()=>{o.value=new Date(o.value.getFullYear(),o.value.getMonth()+1,1)},handlePrevMonth:()=>{o.value=new Date(o.value.getFullYear(),o.value.getMonth()-1,1)},initializeDraft:()=>{f(),i.value=n?.value??null,v.value=u?.value??null},isDraftEnd:M,isDraftStart:m,isInDraftRange:w,isoToLocalDate:D,onDayClick:e=>{if(e)return l(r)?!i.value||i.value&&v.value?(i.value=e,void(v.value=null)):e<i.value?(v.value=i.value,void(i.value=e)):void(v.value=e):(i.value=e,void(v.value=null))},rangeLabel:S,setCalendarMonthToAppliedOrToday:f,weekDays:["Su","Mo","Tu","We","Th","Fr","Sa"]}};export{u as useDatePicker};
|
package/package.json
CHANGED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import '../components/CLIcon/CLIcon.css';
|
|
2
|
-
import{defineComponent as e,ref as t,computed as l,watch as o,onMounted as n,createElementBlock as i,openBlock as r,normalizeStyle as a,normalizeClass as s,unref as c,createElementVNode as d}from"vue";import{CLMode as u,CLColors as m,CLColorVariants as f,CLIconSizes as p}from"../index.js";import{g as h}from"./utils-DVxwAjJ4.js";import{useTheme as v}from"../composables/useTheme.js";import{i as g}from"./helper-C542dSLs.js";const y=({color:e=m.Neutral})=>{const{colors:t,darkMode:l}=v(),o=l.value?u.Dark:u.Light,n=h({color:e,colors:t.value,mode:o,variant:f.Text});return{"--clll-icon-color":n?.textBody??"inherit"}},L=["data-testid"],X=["height","width"],w=["href"],B=/* @__PURE__ */e({name:"CLIcon",__name:"CLIcon",props:{color:{default:m.Neutral},filled:{type:Boolean,default:!1},name:{},size:{default:p.Small},testId:{default:"clll-icon"}},setup(e){const u=e,m="clll-icon",f={[p.Tiny]:20,[p.Small]:24,[p.Medium]:28,[p.Large]:32,[p.XL]:36,[p.XXL]:40,[p.XXXL]:44,[p.XXXXL]:48},h=/* @__PURE__ */new Map,v=t(!1),B=l(()=>u.filled?u.name.endsWith("-filled")?u.name:u.name.replace("tabler:","tabler:")+"-filled":u.name),I=l(()=>{const e=B.value;if(!u.filled||e===u.name)return e;return(e=>{if(!g)return!1;if(h.has(e))return h.get(e);const t=document.getElementById("clll-icons");if(!t)return!1;const l=document.getElementById(e),o=null!==l&&t.contains(l);return h.set(e,o),o})(e)?e:u.name}),x=l(()=>[m,`${m}--${u.name}`,`${m}--${u.size}`,{[`${m}--filled`]:u.filled&&I.value===B.value}]),$=l(()=>({...y({color:u.color}),width:f[u.size]+4+"px",height:f[u.size]+4+"px"}));o(()=>v.value,e=>{e&&h.clear()});return n(()=>{(async()=>{if(!g)return;let e=document.getElementById("clll-icons");if(e)v.value=!0;else try{const t=/* #__PURE__ */Object.assign({"/src/icons.svg":()=>import("./icons-6SVrmx7c.js").then(e=>e.default)})["/src/icons.svg"];if(!t)return;const l=await t();if(e=document.getElementById("clll-icons"),e)return void(v.value=!0);const o=document.createElement("div");o.id="clll-icons",o.style.display="none",o.innerHTML=l.toString();const n=()=>{document.body.insertBefore(o,document.body.childNodes[0]),v.value=!0};"loading"===document.readyState?window.addEventListener("DOMContentLoaded",n,{once:!0}):n()}catch(t){console.error("[Callaloo] Failed to load icon sprite:",t)}})()}),(t,l)=>(r(),i("span",{class:s(c(x)),"data-testid":e.testId,style:a(c($))},[(r(),i("svg",{"aria-hidden":"true",class:s(`${m}-sprite`),height:f[e.size],width:f[e.size],viewBox:"0 0 24 24"},[d("use",{href:`#${c(I)}`},null,8,w)],10,X))],14,L))}});export{B as _};
|