@codeandfunction/callaloo 5.15.1 → 5.16.0

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.
Files changed (80) hide show
  1. package/dist/assets/CLFormField.css +1 -0
  2. package/dist/assets/CLInputMessages.css +1 -1
  3. package/dist/callaloo.global.js +1 -1
  4. package/dist/chunks/{CLA11yButton.vue_vue_type_style_index_0_lang-BnJRXVwW.js → CLA11yButton.vue_vue_type_style_index_0_lang-BQBmDfM8.js} +1 -1
  5. package/dist/chunks/CLButton.vue_vue_type_style_index_0_lang-pE0JrYmS.js +2 -0
  6. package/dist/chunks/CLCalendar.vue_vue_type_style_index_0_lang-PiGGhTHo.js +2 -0
  7. package/dist/chunks/{CLCard.vue_vue_type_style_index_0_lang-D3JriMVx.js → CLCard.vue_vue_type_style_index_0_lang-CY-Qr_CV.js} +1 -1
  8. package/dist/chunks/{CLFormCharCounter.vue_vue_type_style_index_0_lang-hB5Ua5Ta.js → CLFormCharCounter.vue_vue_type_style_index_0_lang-D3Ao581E.js} +1 -1
  9. package/dist/chunks/CLFormField.vue_vue_type_style_index_0_lang-Rf_Mo_VS.js +2 -0
  10. package/dist/chunks/{CLFormLabel.vue_vue_type_script_setup_true_lang-D7UZMu_6.js → CLFormLabel.vue_vue_type_script_setup_true_lang-DoM5X-sA.js} +1 -1
  11. package/dist/chunks/{CLHeading.vue_vue_type_style_index_0_lang-Bp0Hmc-g.js → CLHeading.vue_vue_type_style_index_0_lang-PCOhAZkN.js} +1 -1
  12. package/dist/chunks/{CLIcon.vue_vue_type_style_index_0_lang-BN_rKLKK.js → CLIcon.vue_vue_type_style_index_0_lang-BmRKmzSl.js} +1 -1
  13. package/dist/chunks/CLInputMessages.vue_vue_type_style_index_0_lang-gkHODA90.js +2 -0
  14. package/dist/chunks/{CLLink.vue_vue_type_style_index_0_lang-DoqyJ8FL.js → CLLink.vue_vue_type_style_index_0_lang-B94b55if.js} +1 -1
  15. package/dist/chunks/{CLModal.vue_vue_type_style_index_0_lang-DNUsoevN.js → CLModal.vue_vue_type_style_index_0_lang-DLUfvRC_.js} +1 -1
  16. package/dist/chunks/{CLNavLink.vue_vue_type_script_setup_true_lang-B2DxfBQx.js → CLNavLink.vue_vue_type_script_setup_true_lang-BXjSe15F.js} +1 -1
  17. package/dist/chunks/{CLPill.vue_vue_type_style_index_0_lang-mVxJKPLS.js → CLPill.vue_vue_type_style_index_0_lang-BjrbTAI3.js} +1 -1
  18. package/dist/chunks/{CLSkeleton.vue_vue_type_style_index_0_lang-B6zTBcne.js → CLSkeleton.vue_vue_type_style_index_0_lang-DAHFJ7wZ.js} +1 -1
  19. package/dist/chunks/{CLSpinner.vue_vue_type_style_index_0_lang-C70Q-aOu.js → CLSpinner.vue_vue_type_style_index_0_lang-B4PAMCz6.js} +1 -1
  20. package/dist/chunks/{CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js → CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js} +1 -1
  21. package/dist/chunks/{CLToast.vue_vue_type_style_index_0_lang-D2V4LMvh.js → CLToast.vue_vue_type_style_index_0_lang-D7KGFx9t.js} +1 -1
  22. package/dist/chunks/{index-DwjW-Z-U.js → index-DsloP0ml.js} +1 -1
  23. package/dist/chunks/{index-C9S3C1LU.js → index-wkMXT2wB.js} +1 -1
  24. package/dist/chunks/{utils-CYyJsKfZ.js → utils-BVrLpGWo.js} +1 -1
  25. package/dist/chunks/utils-BfamOHei.js +1 -0
  26. package/dist/chunks/{utils-FFu1_F8K.js → utils-BolqCol3.js} +1 -1
  27. package/dist/chunks/utils-CGcDgs5c.js +1 -0
  28. package/dist/chunks/{utils-D1egvxnD.js → utils-D0LERx2k.js} +1 -1
  29. package/dist/chunks/{utils-BDThP-Sb.js → utils-jYeghjKF.js} +1 -1
  30. package/dist/components/Buttons/CLA11yButton/CLA11yButton.js +1 -1
  31. package/dist/components/Buttons/CLButton/CLButton.css +1 -1
  32. package/dist/components/Buttons/CLButton/CLButton.js +1 -1
  33. package/dist/components/CLIcon/CLIcon.js +1 -1
  34. package/dist/components/CLTable/CLTable.js +1 -1
  35. package/dist/components/Containers/CLCard/CLCard.js +1 -1
  36. package/dist/components/Containers/CLCarousel/CLCarousel.js +1 -1
  37. package/dist/components/Containers/CLDisclosure/CLDisclosure.js +1 -1
  38. package/dist/components/Containers/CLDrawer/CLDrawer.js +1 -1
  39. package/dist/components/Form/CLCalendar/CLCalendar.js +1 -1
  40. package/dist/components/Form/CLCheckbox/CLCheckbox.js +1 -1
  41. package/dist/components/Form/CLInput/CLInput.js +1 -1
  42. package/dist/components/Form/CLInputDatePicker/CLInputDatePicker.js +1 -1
  43. package/dist/components/Form/CLInputTimePicker/CLInputTimePicker.js +1 -1
  44. package/dist/components/Form/CLRadioButton/CLRadioButton.js +1 -1
  45. package/dist/components/Form/CLSelect/CLSelect.js +1 -1
  46. package/dist/components/Form/CLTextArea/CLTextArea.js +1 -1
  47. package/dist/components/Form/CLTimePicker/CLTimePicker.js +1 -1
  48. package/dist/components/Indicators/CLBadge/CLBadge.js +1 -1
  49. package/dist/components/Indicators/CLBanner/CLBanner.js +1 -1
  50. package/dist/components/Indicators/CLPill/CLPill.js +1 -1
  51. package/dist/components/Indicators/CLProgress/CLProgress.js +1 -1
  52. package/dist/components/Loading/CLSkeleton/CLSkeleton.js +1 -1
  53. package/dist/components/Loading/CLSpinner/CLSpinner.js +1 -1
  54. package/dist/components/Modals/CLModal/CLModal.js +1 -1
  55. package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.css +1 -1
  56. package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.js +1 -1
  57. package/dist/components/Modals/CLModalDatePicker/CLModalDatePicker.vue.d.ts +13 -1
  58. package/dist/components/Modals/CLModalDatePicker/index.d.ts +1 -0
  59. package/dist/components/Modals/CLModalTimePicker/CLModalTimePicker.css +1 -1
  60. package/dist/components/Modals/CLModalTimePicker/CLModalTimePicker.js +1 -1
  61. package/dist/components/Modals/CLModalTimePicker/CLModalTimePicker.vue.d.ts +13 -1
  62. package/dist/components/Modals/CLModalTimePicker/index.d.ts +4 -0
  63. package/dist/components/Navigation/CLLink/CLLink.js +1 -1
  64. package/dist/components/Navigation/CLNavLink/CLNavLink.js +1 -1
  65. package/dist/components/Navigation/CLNavSection/CLNavSection.js +1 -1
  66. package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.js +1 -1
  67. package/dist/components/Popups/CLToast/CLToast.js +1 -1
  68. package/dist/components/Providers/CLThemeProvider/CLThemeProvider.js +1 -1
  69. package/dist/components/Providers/CLToastProvider/CLToastProvider.js +1 -1
  70. package/dist/components/Typography/CLHeading/CLHeading.js +1 -1
  71. package/dist/components/Typography/CLText/CLText.js +1 -1
  72. package/dist/composables/useTheme.js +1 -1
  73. package/dist/index.js +1 -1
  74. package/dist/styles.css +1 -1
  75. package/package.json +1 -1
  76. package/dist/chunks/CLButton.vue_vue_type_style_index_0_lang-hSiZPrZr.js +0 -2
  77. package/dist/chunks/CLCalendar.vue_vue_type_style_index_0_lang-BsB4QKTu.js +0 -2
  78. package/dist/chunks/CLInputMessages.vue_vue_type_style_index_0_lang-CtGriC2l.js +0 -2
  79. package/dist/chunks/utils-DBWrbn3p.js +0 -1
  80. package/dist/chunks/utils-DxfNBBvx.js +0 -1
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLTimePicker.css';
3
- import{defineComponent as e,mergeModels as l,useCssVars as a,ref as t,useModel as u,toRef as i,watch as s,createElementBlock as o,openBlock as r,normalizeStyle as d,normalizeClass as n,unref as c,createCommentVNode as p,createElementVNode as m,createVNode as v,withCtx as _,createTextVNode as b,toDisplayString as f,withDirectives as y,isRef as g,vModelText as h}from"vue";import{_ as $}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js";import{d as x,a as M}from"../../../chunks/index-DwjW-Z-U.js";import{t as S}from"../../../chunks/utils-BDThP-Sb.js";import{useTimePicker as k}from"../../../composables/useTimePicker.js";import{useTheme as H}from"../../../composables/useTheme.js";const P=["data-testid"],D=["disabled"],I=["disabled"],T=["disabled"],j=["disabled"],B=/* @__PURE__ */e({name:"CLTimePicker",__name:"CLTimePicker",props:/* @__PURE__ */l({color:{default:x.Primary},disabled:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},headerLabel:{default:"Enter time"},testId:{default:"clll-time-picker"},use24Hour:{type:Boolean,default:!1},width:{default:"auto"}},{modelValue:{},modelModifiers:{}}),emits:/* @__PURE__ */l(["time-select"],["update:modelValue"]),setup(e,{expose:l,emit:B}){a(e=>({v6249f3d5:e.width}));const L=e,C=B,V=H(),A="clll-time-picker",F=t(null),N=u(e,"modelValue"),w=t(N.value??null),{cancelDraft:z,clearDraft:U,draftHour:E,draftMinute:O,draftPeriod:q,formatTimeObject:G,getFormattedDraft:J,initializeDraft:K,parseTime:Q}=k({appliedTime:w,use24Hour:i(L,"use24Hour")});s(N,e=>{w.value=e??null,K()},{immediate:!0});const R=e=>{let l=e.target.value.replace(/\D/g,"");if(!l)return void(E.value="");let a=parseInt(l,10);L.use24Hour?a>23&&(a=23):(a>12&&(a=12),a<1&&l.length>=2&&(a=1)),E.value=String(a).padStart(l.length>=2?2:l.length,"0")},W=()=>{F.value="hour"},X=()=>{if(F.value=null,E.value&&"0"!==E.value&&"00"!==E.value){const e=parseInt(E.value,10);E.value=String(e).padStart(2,"0")}else E.value=L.use24Hour?"00":"12";ae()},Y=e=>{let l=e.target.value.replace(/\D/g,"");if(!l)return void(O.value="");let a=parseInt(l,10);a>59&&(a=59),O.value=String(a).padStart(l.length>=2?2:l.length,"0")},Z=()=>{F.value="minute"},ee=()=>{if(F.value=null,O.value){const e=parseInt(O.value,10);O.value=String(e).padStart(2,"0")}else O.value="00";ae()},le=e=>{L.disabled||L.busy||(q.value=e,ae())},ae=()=>{const e=J();C("time-select",e)};return l({apply:()=>{const e=J();w.value=e,N.value=e},cancel:()=>{z()},draftHour:E,draftMinute:O,draftPeriod:q,getFormattedDraft:J,initializeDraft:K,reset:()=>{U(),w.value=null,N.value=null}}),(l,a)=>(r(),o("div",{class:n([A,e.fluid?`${A}--fluid`:""]),"data-testid":e.testId,style:d(c(S)({color:e.color,theme:c(V)}))},[e.headerLabel?(r(),o("div",{key:0,class:n(`${A}__header`)},[v(c($),{type:c(M).Small,color:c(x).Neutral,medium:""},{default:_(()=>[b(f(e.headerLabel),1)]),_:1},8,["type","color"])],2)):p("",!0),m("div",{class:n(`${A}__controls`)},[m("div",{class:n(`${A}__unit-container`)},[m("div",{class:n([`${A}__box`,"hour"===F.value?`${A}__box--active`:""])},[y(m("input",{"onUpdate:modelValue":a[0]||(a[0]=e=>g(E)?E.value=e:null),type:"text",inputmode:"numeric",maxlength:"2",disabled:e.disabled||e.busy,class:n(`${A}__input`),"aria-label":"Hour input",onInput:R,onFocus:W,onBlur:X},null,42,D),[[h,c(E)]])],2),v(c($),{type:c(M).Small,color:c(x).Neutral,class:n(`${A}__sublabel`)},{default:_(()=>[...a[4]||(a[4]=[b(" Hour ",-1)])]),_:1},8,["type","color","class"])],2),m("div",{class:n(`${A}__separator`)},":",2),m("div",{class:n(`${A}__unit-container`)},[m("div",{class:n([`${A}__box`,"minute"===F.value?`${A}__box--active`:""])},[y(m("input",{"onUpdate:modelValue":a[1]||(a[1]=e=>g(O)?O.value=e:null),type:"text",inputmode:"numeric",maxlength:"2",disabled:e.disabled||e.busy,class:n(`${A}__input`),"aria-label":"Minute input",onInput:Y,onFocus:Z,onBlur:ee},null,42,I),[[h,c(O)]])],2),v(c($),{type:c(M).Small,color:c(x).Neutral,class:n(`${A}__sublabel`)},{default:_(()=>[...a[5]||(a[5]=[b(" Minute ",-1)])]),_:1},8,["type","color","class"])],2),e.use24Hour?p("",!0):(r(),o("div",{key:0,class:n(`${A}__period-toggle`)},[m("button",{type:"button",class:n([`${A}__period-btn`,"AM"===c(q)?`${A}__period-btn--active`:""]),disabled:e.disabled||e.busy,"aria-label":"Select AM",onClick:a[2]||(a[2]=e=>le("AM"))}," AM ",10,T),m("button",{type:"button",class:n([`${A}__period-btn`,"PM"===c(q)?`${A}__period-btn--active`:""]),disabled:e.disabled||e.busy,"aria-label":"Select PM",onClick:a[3]||(a[3]=e=>le("PM"))}," PM ",10,j)],2))],2)],14,P))}});export{B as CLTimePicker,B as default};
3
+ import{defineComponent as e,mergeModels as l,useCssVars as t,ref as a,useModel as u,toRef as i,watch as s,createElementBlock as o,openBlock as r,normalizeStyle as d,normalizeClass as n,unref as c,createCommentVNode as p,createElementVNode as m,createVNode as v,withCtx as _,createTextVNode as b,toDisplayString as f,withDirectives as y,isRef as g,vModelText as h}from"vue";import{_ as $}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js";import{b as x,d as M}from"../../../chunks/index-DsloP0ml.js";import{t as S}from"../../../chunks/utils-jYeghjKF.js";import{useTimePicker as k}from"../../../composables/useTimePicker.js";import{useTheme as H}from"../../../composables/useTheme.js";const P=["data-testid"],D=["disabled"],I=["disabled"],T=["disabled"],j=["disabled"],B=/* @__PURE__ */e({name:"CLTimePicker",__name:"CLTimePicker",props:/* @__PURE__ */l({color:{default:x.Primary},disabled:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},headerLabel:{default:"Enter time"},testId:{default:"clll-time-picker"},use24Hour:{type:Boolean,default:!1},width:{default:"auto"}},{modelValue:{},modelModifiers:{}}),emits:/* @__PURE__ */l(["time-select"],["update:modelValue"]),setup(e,{expose:l,emit:B}){t(e=>({v6249f3d5:e.width}));const L=e,C=B,V=H(),A="clll-time-picker",F=a(null),N=u(e,"modelValue"),w=a(N.value??null),{cancelDraft:z,clearDraft:U,draftHour:E,draftMinute:O,draftPeriod:q,formatTimeObject:G,getFormattedDraft:J,initializeDraft:K,parseTime:Q}=k({appliedTime:w,use24Hour:i(L,"use24Hour")});s(N,e=>{w.value=e??null,K()},{immediate:!0});const R=e=>{let l=e.target.value.replace(/\D/g,"");if(!l)return void(E.value="");let t=parseInt(l,10);L.use24Hour?t>23&&(t=23):(t>12&&(t=12),t<1&&l.length>=2&&(t=1)),E.value=String(t).padStart(l.length>=2?2:l.length,"0")},W=()=>{F.value="hour"},X=()=>{if(F.value=null,E.value&&"0"!==E.value&&"00"!==E.value){const e=parseInt(E.value,10);E.value=String(e).padStart(2,"0")}else E.value=L.use24Hour?"00":"12";te()},Y=e=>{let l=e.target.value.replace(/\D/g,"");if(!l)return void(O.value="");let t=parseInt(l,10);t>59&&(t=59),O.value=String(t).padStart(l.length>=2?2:l.length,"0")},Z=()=>{F.value="minute"},ee=()=>{if(F.value=null,O.value){const e=parseInt(O.value,10);O.value=String(e).padStart(2,"0")}else O.value="00";te()},le=e=>{L.disabled||L.busy||(q.value=e,te())},te=()=>{const e=J();C("time-select",e)};return l({apply:()=>{const e=J();w.value=e,N.value=e},cancel:()=>{z()},draftHour:E,draftMinute:O,draftPeriod:q,getFormattedDraft:J,initializeDraft:K,reset:()=>{U(),w.value=null,N.value=null}}),(l,t)=>(r(),o("div",{class:n([A,e.fluid?`${A}--fluid`:""]),"data-testid":e.testId,style:d(c(S)({color:e.color,theme:c(V)}))},[e.headerLabel?(r(),o("div",{key:0,class:n(`${A}__header`)},[v(c($),{type:c(M).Small,color:c(x).Neutral,medium:""},{default:_(()=>[b(f(e.headerLabel),1)]),_:1},8,["type","color"])],2)):p("",!0),m("div",{class:n(`${A}__controls`)},[m("div",{class:n(`${A}__unit-container`)},[m("div",{class:n([`${A}__box`,"hour"===F.value?`${A}__box--active`:""])},[y(m("input",{"onUpdate:modelValue":t[0]||(t[0]=e=>g(E)?E.value=e:null),type:"text",inputmode:"numeric",maxlength:"2",disabled:e.disabled||e.busy,class:n(`${A}__input`),"aria-label":"Hour input",onInput:R,onFocus:W,onBlur:X},null,42,D),[[h,c(E)]])],2),v(c($),{type:c(M).Small,color:c(x).Neutral,class:n(`${A}__sublabel`)},{default:_(()=>[...t[4]||(t[4]=[b(" Hour ",-1)])]),_:1},8,["type","color","class"])],2),m("div",{class:n(`${A}__separator`)},":",2),m("div",{class:n(`${A}__unit-container`)},[m("div",{class:n([`${A}__box`,"minute"===F.value?`${A}__box--active`:""])},[y(m("input",{"onUpdate:modelValue":t[1]||(t[1]=e=>g(O)?O.value=e:null),type:"text",inputmode:"numeric",maxlength:"2",disabled:e.disabled||e.busy,class:n(`${A}__input`),"aria-label":"Minute input",onInput:Y,onFocus:Z,onBlur:ee},null,42,I),[[h,c(O)]])],2),v(c($),{type:c(M).Small,color:c(x).Neutral,class:n(`${A}__sublabel`)},{default:_(()=>[...t[5]||(t[5]=[b(" Minute ",-1)])]),_:1},8,["type","color","class"])],2),e.use24Hour?p("",!0):(r(),o("div",{key:0,class:n(`${A}__period-toggle`)},[m("button",{type:"button",class:n([`${A}__period-btn`,"AM"===c(q)?`${A}__period-btn--active`:""]),disabled:e.disabled||e.busy,"aria-label":"Select AM",onClick:t[2]||(t[2]=e=>le("AM"))}," AM ",10,T),m("button",{type:"button",class:n([`${A}__period-btn`,"PM"===c(q)?`${A}__period-btn--active`:""]),disabled:e.disabled||e.busy,"aria-label":"Select PM",onClick:t[3]||(t[3]=e=>le("PM"))}," PM ",10,j)],2))],2)],14,P))}});export{B as CLTimePicker,B as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLBadge.css';
3
- import{defineComponent as t,computed as a,createElementBlock as e,openBlock as l,normalizeStyle as r,normalizeClass as s,unref as d,createElementVNode as o,toDisplayString as i}from"vue";import{c as n,d as u}from"../../../chunks/index-DwjW-Z-U.js";import{b as c}from"../../../chunks/utils-D1egvxnD.js";const m=["data-testid"],f=/* @__PURE__ */t({name:"CLBadge",__name:"CLBadge",props:{borderRadius:{},color:{default:u.Neutral},elevated:{type:Boolean,default:!1},label:{},limit:{},testId:{default:"clll-badge"},variant:{default:n.Soft}},setup(t){const n=t,u="clll-badge",f=a(()=>{const t=n.limit??0,a=n.label??"";return t&&a.toString().length>t?`${a.toString().slice(0,t)}+`:a}),p=a(()=>[u,n.borderRadius?`${u}--${n.borderRadius}`:"",n.elevated?`${u}--elevated`:"",`${u}--${n.color}--${n.variant}`]);return(a,n)=>(l(),e("div",{class:s(d(p)),"data-testid":t.testId,style:r(d(c)({color:t.color,variant:t.variant}))},[o("span",{class:s(`${u}__count`)},i(d(f)),3)],14,m))}});export{f as CLBadge,f as default};
3
+ import{defineComponent as t,computed as a,createElementBlock as e,openBlock as l,normalizeStyle as r,normalizeClass as s,unref as o,createElementVNode as d,toDisplayString as i}from"vue";import{a as n,b as u}from"../../../chunks/index-DsloP0ml.js";import{b as c}from"../../../chunks/utils-D0LERx2k.js";const m=["data-testid"],b=/* @__PURE__ */t({name:"CLBadge",__name:"CLBadge",props:{borderRadius:{},color:{default:u.Neutral},elevated:{type:Boolean,default:!1},label:{},limit:{},testId:{default:"clll-badge"},variant:{default:n.Soft}},setup(t){const n=t,u="clll-badge",b=a(()=>{const t=n.limit??0,a=n.label??"";return t&&a.toString().length>t?`${a.toString().slice(0,t)}+`:a}),f=a(()=>[u,n.borderRadius?`${u}--${n.borderRadius}`:"",n.elevated?`${u}--elevated`:"",`${u}--${n.color}--${n.variant}`]);return(a,n)=>(l(),e("div",{class:s(o(f)),"data-testid":t.testId,style:r(o(c)({color:t.color,variant:t.variant}))},[d("span",{class:s(`${u}__count`)},i(o(b)),3)],14,m))}});export{b as CLBadge,b as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLBanner.css';
3
- import{defineComponent as e,computed as a,createBlock as t,openBlock as o,unref as i,withCtx as s,createElementVNode as n,normalizeStyle as l,normalizeClass as r,createElementBlock as d,createCommentVNode as u,createTextVNode as c,toDisplayString as _,createVNode as b}from"vue";import{_ as y}from"../../../chunks/CLA11yButton.vue_vue_type_style_index_0_lang-BnJRXVwW.js";import{_ as m}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-hSiZPrZr.js";import{_ as f}from"../../../chunks/CLHeading.vue_vue_type_style_index_0_lang-Bp0Hmc-g.js";import{_ as k}from"../../../chunks/CLSkeleton.vue_vue_type_style_index_0_lang-B6zTBcne.js";import{_ as p}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js";import{c as v,d as g,i as h,l as $,a as L,C,e as x,f as B}from"../../../chunks/index-DwjW-Z-U.js";import{a as j}from"../../../chunks/utils-D1egvxnD.js";const S=["data-testid"],D=/* @__PURE__ */e({name:"CLBanner",__name:"CLBanner",props:{actionLabel:{},align:{default:h.Left},ariaLabel:{},bordered:{type:Boolean,default:!0},borderRadius:{},busy:{type:Boolean,default:!1},color:{default:g.Neutral},height:{default:"auto"},message:{},onAction:{},onClick:{},onDismiss:{},rounded:{type:Boolean,default:!0},testId:{default:"clll-banner"},title:{},width:{default:"100%"},variant:{default:v.Soft}},setup(e){const g=e,h="clll-banner",D=a(()=>[h,g.actionLabel?`${h}--actionable`:"",g.busy?`${h}--busy`:`${h}--ready`,g.bordered&&g.variant!==v.Ghost?`${h}--bordered`:"",g.borderRadius?`${h}--${g.borderRadius}`:"",g.onDismiss?`${h}--dismissable`:"",`${h}--${g.color}--${g.variant}`,`${h}--align-${g.align}`,g.rounded?`${h}--rounded`:`${h}--box`]);return(a,g)=>(o(),t(i(y),{color:e.color,enabled:!(!e.onClick||!e.ariaLabel),rounded:e.rounded},{default:s(()=>[n("div",{class:r(i(D)),"data-testid":e.testId,style:l({...i(j)({color:e.color,variant:e.variant}),width:e.width,height:e.height})},[n("div",{class:r(`${h}__content`)},[n("div",{class:r(`${h}__nested_content`)},[e.busy?(o(),t(i(k),{key:0,"border-radius":e.borderRadius,height:"28px","test-id":`${h}__skeleton-title`},null,8,["border-radius","test-id"])):u("",!0),e.busy?(o(),t(i(k),{key:1,"border-radius":e.borderRadius,width:"70%",height:"20px","test-id":`${h}__skeleton-message`},null,8,["border-radius","test-id"])):u("",!0),e.title&&!e.busy?(o(),t(i(f),{key:2,align:e.align,color:e.color,type:i($).Section},{default:s(()=>[c(_(e.title),1)]),_:1},8,["align","color","type"])):u("",!0),e.message&&!e.busy?(o(),t(i(p),{key:3,align:e.align,color:e.color,type:i(L).Summary},{default:s(()=>[c(_(e.message),1)]),_:1},8,["align","color","type"])):u("",!0)],2),e.onAction&&e.actionLabel?(o(),d("div",{key:0,class:r(`${h}__action-button`)},[b(i(m),{color:e.color,"border-radius":e.borderRadius,"on-click":e.onAction,"test-id":`${h}__action-button`,variant:e.variant===i(v).Solid?i(v).Soft:i(v).Solid},{default:s(()=>[c(_(e.actionLabel),1)]),_:1},8,["color","border-radius","on-click","test-id","variant"])],2)):u("",!0)],2),e.onDismiss?(o(),d("div",{key:0,class:r(`${h}__dismiss-button`)},[b(i(m),{"aria-label":"Dismiss banner",color:e.color,"icon-before":i(B).Delete,"icon-size":i(x).Tiny,"on-click":e.onDismiss,size:i(C).Tiny,"test-id":`${h}__dismiss-button`,variant:e.variant},null,8,["color","icon-before","icon-size","on-click","size","test-id","variant"])],2)):u("",!0),e.onClick&&e.ariaLabel?(o(),d("button",{key:1,class:"sr-only","data-expand-click-area":"",onClick:g[0]||(g[0]=(...a)=>e.onClick&&e.onClick(...a))},_(e.ariaLabel),1)):u("",!0)],14,S)]),_:1},8,["color","enabled","rounded"]))}});export{D as CLBanner,D as default};
3
+ import{defineComponent as e,computed as a,createBlock as t,openBlock as o,unref as i,withCtx as s,createElementVNode as n,normalizeStyle as l,normalizeClass as r,createElementBlock as d,createCommentVNode as u,createTextVNode as c,toDisplayString as _,createVNode as b}from"vue";import{_ as y}from"../../../chunks/CLA11yButton.vue_vue_type_style_index_0_lang-BQBmDfM8.js";import{_ as m}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-pE0JrYmS.js";import{_ as f}from"../../../chunks/CLHeading.vue_vue_type_style_index_0_lang-PCOhAZkN.js";import{_ as k}from"../../../chunks/CLSkeleton.vue_vue_type_style_index_0_lang-DAHFJ7wZ.js";import{_ as p}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js";import{a as v,b as g,i as h,l as $,d as L,c as C,e as x,f as B}from"../../../chunks/index-DsloP0ml.js";import{a as j}from"../../../chunks/utils-D0LERx2k.js";const S=["data-testid"],D=/* @__PURE__ */e({name:"CLBanner",__name:"CLBanner",props:{actionLabel:{},align:{default:h.Left},ariaLabel:{},bordered:{type:Boolean,default:!0},borderRadius:{},busy:{type:Boolean,default:!1},color:{default:g.Neutral},height:{default:"auto"},message:{},onAction:{},onClick:{},onDismiss:{},rounded:{type:Boolean,default:!0},testId:{default:"clll-banner"},title:{},width:{default:"100%"},variant:{default:v.Soft}},setup(e){const g=e,h="clll-banner",D=a(()=>[h,g.actionLabel?`${h}--actionable`:"",g.busy?`${h}--busy`:`${h}--ready`,g.bordered&&g.variant!==v.Ghost?`${h}--bordered`:"",g.borderRadius?`${h}--${g.borderRadius}`:"",g.onDismiss?`${h}--dismissable`:"",`${h}--${g.color}--${g.variant}`,`${h}--align-${g.align}`,g.rounded?`${h}--rounded`:`${h}--box`]);return(a,g)=>(o(),t(i(y),{color:e.color,enabled:!(!e.onClick||!e.ariaLabel),rounded:e.rounded},{default:s(()=>[n("div",{class:r(i(D)),"data-testid":e.testId,style:l({...i(j)({color:e.color,variant:e.variant}),width:e.width,height:e.height})},[n("div",{class:r(`${h}__content`)},[n("div",{class:r(`${h}__nested_content`)},[e.busy?(o(),t(i(k),{key:0,"border-radius":e.borderRadius,height:"28px","test-id":`${h}__skeleton-title`},null,8,["border-radius","test-id"])):u("",!0),e.busy?(o(),t(i(k),{key:1,"border-radius":e.borderRadius,width:"70%",height:"20px","test-id":`${h}__skeleton-message`},null,8,["border-radius","test-id"])):u("",!0),e.title&&!e.busy?(o(),t(i(f),{key:2,align:e.align,color:e.color,type:i($).Section},{default:s(()=>[c(_(e.title),1)]),_:1},8,["align","color","type"])):u("",!0),e.message&&!e.busy?(o(),t(i(p),{key:3,align:e.align,color:e.color,type:i(L).Summary},{default:s(()=>[c(_(e.message),1)]),_:1},8,["align","color","type"])):u("",!0)],2),e.onAction&&e.actionLabel?(o(),d("div",{key:0,class:r(`${h}__action-button`)},[b(i(m),{color:e.color,"border-radius":e.borderRadius,"on-click":e.onAction,"test-id":`${h}__action-button`,variant:e.variant===i(v).Solid?i(v).Soft:i(v).Solid},{default:s(()=>[c(_(e.actionLabel),1)]),_:1},8,["color","border-radius","on-click","test-id","variant"])],2)):u("",!0)],2),e.onDismiss?(o(),d("div",{key:0,class:r(`${h}__dismiss-button`)},[b(i(m),{"aria-label":"Dismiss banner",color:e.color,"icon-before":i(B).Delete,"icon-size":i(x).Tiny,"on-click":e.onDismiss,size:i(C).Tiny,"test-id":`${h}__dismiss-button`,variant:e.variant},null,8,["color","icon-before","icon-size","on-click","size","test-id","variant"])],2)):u("",!0),e.onClick&&e.ariaLabel?(o(),d("button",{key:1,class:"sr-only","data-expand-click-area":"",onClick:g[0]||(g[0]=(...a)=>e.onClick&&e.onClick(...a))},_(e.ariaLabel),1)):u("",!0)],14,S)]),_:1},8,["color","enabled","rounded"]))}});export{D as CLBanner,D as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLPill.css';
3
- import{_ as e}from"../../../chunks/CLPill.vue_vue_type_style_index_0_lang-mVxJKPLS.js";export{e as CLPill,e as default};
3
+ import{_ as e}from"../../../chunks/CLPill.vue_vue_type_style_index_0_lang-BjrbTAI3.js";export{e as CLPill,e as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLProgress.css';
3
- import{defineComponent as e,mergeModels as s,useModel as t,computed as a,createElementBlock as l,openBlock as o,normalizeStyle as r,normalizeClass as d,unref as u,createCommentVNode as i,createElementVNode as n,createVNode as m,withCtx as c,createTextVNode as _,toDisplayString as p}from"vue";import{_ as f}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js";import{a as v,d as y,C as $}from"../../../chunks/index-DwjW-Z-U.js";import{c as g}from"../../../chunks/utils-D1egvxnD.js";import{useTheme as b}from"../../../composables/useTheme.js";const h=["data-testid"],C=/* @__PURE__ */e({name:"CLProgress",__name:"CLProgress",props:/* @__PURE__ */s({color:{default:y.Primary},inverted:{type:Boolean,default:!1},rounded:{type:Boolean,default:!0},size:{default:$.Medium},status:{type:Boolean,default:!1},testId:{default:"clll-progress"}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const s=e,$=b(),C=t(e,"modelValue"),j="clll-progress",k=a(()=>[j,`${j}--${s.color}`,`${j}--${s.size}`,s.inverted?`${j}--inverted`:"",s.rounded?`${j}--rounded`:`${j}--not-rounded`]),x=a(()=>`${C.value}%`);return(s,t)=>(o(),l("div",{class:d(u(k)),"data-testid":e.testId,style:r({...u(g)({color:e.color,theme:u($)}),"--clll-progress-value":C.value})},[e.status?(o(),l("div",{key:0,class:d(`${j}__status__container`)},[n("div",{class:d(`${j}__status__label`)},[m(u(f),{color:u(y).Neutral,type:u(v).Summary},{default:c(()=>[_(p(u(x)),1)]),_:1},8,["color","type"])],2)],2)):i("",!0),n("div",{class:d(`${j}__bar-container`)},[n("div",{class:d(`${j}__bar`)},null,2)],2)],14,h))}});export{C as CLProgress,C as default};
3
+ import{defineComponent as e,mergeModels as s,useModel as t,computed as l,createElementBlock as o,openBlock as a,normalizeStyle as r,normalizeClass as d,unref as u,createCommentVNode as i,createElementVNode as n,createVNode as m,withCtx as c,createTextVNode as _,toDisplayString as p}from"vue";import{_ as f}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js";import{d as v,b as y,c as $}from"../../../chunks/index-DsloP0ml.js";import{c as g}from"../../../chunks/utils-D0LERx2k.js";import{useTheme as b}from"../../../composables/useTheme.js";const h=["data-testid"],j=/* @__PURE__ */e({name:"CLProgress",__name:"CLProgress",props:/* @__PURE__ */s({color:{default:y.Primary},inverted:{type:Boolean,default:!1},rounded:{type:Boolean,default:!0},size:{default:$.Medium},status:{type:Boolean,default:!1},testId:{default:"clll-progress"}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const s=e,$=b(),j=t(e,"modelValue"),k="clll-progress",x=l(()=>[k,`${k}--${s.color}`,`${k}--${s.size}`,s.inverted?`${k}--inverted`:"",s.rounded?`${k}--rounded`:`${k}--not-rounded`]),C=l(()=>`${j.value}%`);return(s,t)=>(a(),o("div",{class:d(u(x)),"data-testid":e.testId,style:r({...u(g)({color:e.color,theme:u($)}),"--clll-progress-value":j.value})},[e.status?(a(),o("div",{key:0,class:d(`${k}__status__container`)},[n("div",{class:d(`${k}__status__label`)},[m(u(f),{color:u(y).Neutral,type:u(v).Summary},{default:c(()=>[_(p(u(C)),1)]),_:1},8,["color","type"])],2)],2)):i("",!0),n("div",{class:d(`${k}__bar-container`)},[n("div",{class:d(`${k}__bar`)},null,2)],2)],14,h))}});export{j as CLProgress,j as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLSkeleton.css';
3
- import{_ as e}from"../../../chunks/CLSkeleton.vue_vue_type_style_index_0_lang-B6zTBcne.js";export{e as CLSkeleton,e as default};
3
+ import{_ as e}from"../../../chunks/CLSkeleton.vue_vue_type_style_index_0_lang-DAHFJ7wZ.js";export{e as CLSkeleton,e as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLSpinner.css';
3
- import{_ as e}from"../../../chunks/CLSpinner.vue_vue_type_style_index_0_lang-C70Q-aOu.js";export{e as CLSpinner,e as default};
3
+ import{_ as e}from"../../../chunks/CLSpinner.vue_vue_type_style_index_0_lang-B4PAMCz6.js";export{e as CLSpinner,e as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLModal.css';
3
- import{_ as a}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DNUsoevN.js";export{a as CLModal,a as default};
3
+ import{_ as a}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DLUfvRC_.js";export{a as CLModal,a as default};
@@ -1 +1 @@
1
- .clll-date-picker-modal{box-sizing:border-box}.clll-date-picker-modal--fluid{width:100%}.clll-date-picker-modal__footer-actions{display:flex;justify-content:space-between;align-items:center;width:100%}.clll-date-picker-modal__footer-right{display:flex;gap:var(--clll-unit-2)}
1
+ .clll-date-picker-modal{position:relative;overflow:hidden;border-radius:0;flex:none;display:inline-flex;align-items:center;box-sizing:border-box;align-items:flex-start;overflow:visible}.clll-date-picker-modal__hidden-input{position:absolute;bottom:0;left:0;width:100%;height:1px;opacity:0;pointer-events:none;z-index:-1}.clll-date-picker-modal.clll-date-picker-modal--haslabel .clll-date-picker-modal__label .clll-text.clll-date-picker-modal__label--required:after{position:relative;top:var(--clll-unit-1);content:"*";font-size:var(--clll-unit-4_5);font-weight:500;font-family:var(--clll-font-family);-webkit-font-smoothing:antialiased;color:var(--clll-input-required-asterisk-color, red);text-decoration:unset;margin-inline-start:var(--clll-unit-0_5);box-sizing:content-box;line-height:0}.clll-date-picker-modal.clll-date-picker-modal--vertical{flex-direction:column}.clll-date-picker-modal.clll-date-picker-modal--vertical.clll-date-picker-modal--haslabel>:not([hidden])~:not([hidden]){margin-top:var(--clll-unit-1_5)}.clll-date-picker-modal.clll-date-picker-modal--horizontal.clll-date-picker-modal--haslabel{flex-direction:row;align-items:center;flex-wrap:wrap}.clll-date-picker-modal.clll-date-picker-modal--horizontal.clll-date-picker-modal--haslabel .clll-date-picker-modal__label,.clll-date-picker-modal.clll-date-picker-modal--horizontal.clll-date-picker-modal--haslabel .clll-button{width:50%}.clll-date-picker-modal--fluid{width:100%}.clll-date-picker-modal__footer-actions{display:flex;justify-content:space-between;align-items:center;width:100%}.clll-date-picker-modal__footer-right{display:flex;gap:var(--clll-unit-2)}
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLModalDatePicker.css';
3
- import{defineComponent as e,mergeModels as a,ref as t,computed as d,useModel as l,onMounted as o,onBeforeUnmount as i,createElementBlock as r,openBlock as u,normalizeClass as n,unref as s,createVNode as b,withCtx as c,createTextVNode as f,toDisplayString as p,createElementVNode as v,nextTick as m}from"vue";import{_ as y}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-hSiZPrZr.js";import{_}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DNUsoevN.js";import{_ as L}from"../../../chunks/CLCalendar.vue_vue_type_style_index_0_lang-BsB4QKTu.js";import{C as X,e as k,f as g,h,c as $,d as R}from"../../../chunks/index-DwjW-Z-U.js";import{i as B}from"../../../chunks/helper-BlxFN3eF.js";import{useDatePicker as C}from"../../../composables/useDatePicker.js";const w=["data-testid"],S=/* @__PURE__ */e({name:"CLModalDatePicker",__name:"CLModalDatePicker",props:/* @__PURE__ */a({buttonAriaLabel:{default:void 0},buttonBorderRadius:{default:void 0},buttonColor:{default:R.Primary},buttonLabel:{default:"Select dates"},buttonSize:{default:X.Small},buttonVariant:{default:$.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},id:{},isRange:{type:Boolean,default:!0},onBlur:{type:Function,default:void 0},onChange:{type:Function,default:void 0},onFocus:{type:Function,default:void 0},onReset:{},testId:{default:"clll-date-picker-modal"},title:{default:"Select dates"}},{modelValue:{default:()=>({end:null,start:null})},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const a=e,S="clll-date-picker-modal",z=t(!1),V=d(()=>`date-picker-modal-${a.id}`),x=t(),M=l(e,"modelValue"),{rangeLabel:E}=C({appliedStart:d(()=>M.value?.start??null),appliedEnd:d(()=>M.value?.end??null),isRange:a.isRange}),F=t(!1),j=()=>{B&&(F.value=window.innerWidth<480)},P=()=>{if(a.disabled||a.busy)return;j(),z.value=!0,m(()=>{x.value?.initializeDraft()});const e=new FocusEvent("focus",{bubbles:!0,cancelable:!0});a.onFocus?.(e)},D=()=>{z.value=!1,x.value?.cancel();const e=new FocusEvent("blur",{bubbles:!0,cancelable:!0});a.onBlur?.(e)},W=()=>{x.value?.apply(),z.value=!1,a.onChange?.()},A=()=>{x.value?.reset(),a.onReset?.()},I=d(()=>F.value);o(()=>{B&&(j(),window.addEventListener("resize",j))}),i(()=>{B&&window.removeEventListener("resize",j)});const N={[X.Tiny]:k.Tiny,[X.Small]:k.Small,[X.Medium]:k.Medium,[X.Large]:k.Large,[X.XL]:k.XL,[X.XXL]:k.XXL,[X.XXXL]:k.XXXL,[X.XXXXL]:k.XXXXL},G=d(()=>[S,a.buttonBorderRadius?`${S}--${a.buttonBorderRadius}`:"",a.busy?`${S}--busy`:`${S}--ready`,`${S}--${a.buttonColor}`,`${S}--${a.buttonSize}`,`${S}--${a.buttonVariant}`,a.disabled||a.busy?`${S}--disabled`:`${S}--active`,a.fluid?`${S}--fluid`:`${S}--fixed`]),T=d(()=>{const e=x.value?.draftStart,t=x.value?.draftEnd;return a.isRange?!!e&&!!t:!!e});return(a,t)=>(u(),r("div",{class:n(s(G)),"data-testid":e.testId},[b(s(y),{"aria-label":e.buttonAriaLabel||"Open date picker","border-radius":e.buttonBorderRadius,busy:e.busy,color:e.buttonColor,disabled:e.disabled||e.busy,"icon-before":s(g).Calendar,"icon-size":N[e.buttonSize],"on-click":P,"test-id":`${e.testId}__trigger`,size:e.buttonSize,variant:e.buttonVariant,width:e.buttonWidth,wrap:e.buttonWrapped},{default:c(()=>[f(p(s(E)||e.buttonLabel),1)]),_:1},8,["aria-label","border-radius","busy","color","disabled","icon-before","icon-size","test-id","size","variant","width","wrap"]),b(s(_),{"border-radius":s(I)?s(h).None:s(h).Medium,fullscreen:s(I),"is-open":s(z),"max-width":"336px","modal-id":s(V),"on-close":D,title:e.title},{body:c(()=>[b(s(L),{ref_key:"calendarRef",ref:x,modelValue:M.value,"onUpdate:modelValue":t[0]||(t[0]=e=>M.value=e),busy:e.busy,disabled:e.disabled,fluid:s(I),"is-range":e.isRange},null,8,["modelValue","busy","disabled","fluid","is-range"])]),footer:c(()=>[v("div",{class:n(`${S}__footer-actions`)},[b(s(y),{"border-radius":e.buttonBorderRadius,color:s(R).Neutral,"on-click":D,variant:s($).Ghost},{default:c(()=>[...t[1]||(t[1]=[f(" Cancel ",-1)])]),_:1},8,["border-radius","color","variant"]),v("div",{class:n(`${S}__footer-right`)},[b(s(y),{"border-radius":e.buttonBorderRadius,color:s(R).Neutral,disabled:!s(x)?.draftStart&&!s(x)?.draftEnd,"on-click":A,variant:s($).Ghost},{default:c(()=>[...t[2]||(t[2]=[f(" Reset ",-1)])]),_:1},8,["border-radius","color","disabled","variant"]),b(s(y),{"border-radius":e.buttonBorderRadius,color:s(R).Primary,disabled:!s(T),"on-click":W},{default:c(()=>[...t[3]||(t[3]=[f(" Apply ",-1)])]),_:1},8,["border-radius","color","disabled"])],2)],2)]),_:1},8,["border-radius","fullscreen","is-open","modal-id","title"])],10,w))}});export{S as CLModalDatePicker,S as default};
3
+ import{defineComponent as e,mergeModels as a,ref as t,computed as l,useModel as i,onMounted as d,onBeforeUnmount as o,createBlock as r,openBlock as u,withCtx as n,createElementVNode as s,normalizeClass as b,unref as c,createCommentVNode as f,createVNode as p,createElementBlock as m,createTextVNode as _,toDisplayString as v,nextTick as y}from"vue";import{_ as h}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-pE0JrYmS.js";import{_ as L}from"../../../chunks/CLFormField.vue_vue_type_style_index_0_lang-Rf_Mo_VS.js";import{_ as k}from"../../../chunks/CLFormLabel.vue_vue_type_script_setup_true_lang-DoM5X-sA.js";import{_ as $}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DLUfvRC_.js";import{_ as g}from"../../../chunks/CLCalendar.vue_vue_type_style_index_0_lang-PiGGhTHo.js";import{c as X,e as C,f as B,h as R,a as z,b as S}from"../../../chunks/index-DsloP0ml.js";import{a as w}from"../../../chunks/index-wkMXT2wB.js";import{i as x}from"../../../chunks/helper-BlxFN3eF.js";import{useDatePicker as q}from"../../../composables/useDatePicker.js";const F=["data-testid"],V=["name","value","required"],j=/* @__PURE__ */e({name:"CLModalDatePicker",__name:"CLModalDatePicker",props:/* @__PURE__ */a({buttonAriaLabel:{default:void 0},buttonBorderRadius:{default:void 0},buttonColor:{default:S.Primary},buttonLabel:{default:"Select dates"},buttonSize:{default:X.Small},buttonVariant:{default:z.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},id:{},isRange:{type:Boolean,default:!0},label:{default:void 0},name:{default:void 0},onBlur:{type:Function,default:void 0},onChange:{type:Function,default:void 0},onFocus:{type:Function,default:void 0},onReset:{},orientation:{default:w.Vertical},required:{type:Boolean,default:!1},testId:{default:"clll-date-picker-modal"},title:{default:"Select dates"}},{modelValue:{default:()=>({end:null,start:null})},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const a=e,j="clll-date-picker-modal",M=t(!1),E=l(()=>`date-picker-modal-${a.id}`),P=t(),D=i(e,"modelValue"),{rangeLabel:W}=q({appliedStart:l(()=>D.value?.start??null),appliedEnd:l(()=>D.value?.end??null),isRange:a.isRange}),A=t(!1),I=()=>{x&&(A.value=window.innerWidth<480)},N=()=>{if(a.disabled||a.busy)return;I(),M.value=!0,y(()=>{P.value?.initializeDraft()});const e=new FocusEvent("focus",{bubbles:!0,cancelable:!0});a.onFocus?.(e)},G=()=>{M.value=!1,P.value?.cancel();const e=new FocusEvent("blur",{bubbles:!0,cancelable:!0});a.onBlur?.(e)},T=()=>{P.value?.apply(),M.value=!1,a.onChange?.()},H=()=>{P.value?.reset(),a.onReset?.()},O=l(()=>A.value);d(()=>{x&&(I(),window.addEventListener("resize",I))}),o(()=>{x&&window.removeEventListener("resize",I)});const U={[X.Tiny]:C.Tiny,[X.Small]:C.Small,[X.Medium]:C.Medium,[X.Large]:C.Large,[X.XL]:C.XL,[X.XXL]:C.XXL,[X.XXXL]:C.XXXL,[X.XXXXL]:C.XXXXL},J=l(()=>[j,a.buttonBorderRadius?`${j}--${a.buttonBorderRadius}`:"",a.busy?`${j}--busy`:`${j}--ready`,`${j}--${a.buttonColor}`,`${j}--${a.buttonSize}`,`${j}--${a.buttonVariant}`,a.disabled||a.busy?`${j}--disabled`:`${j}--active`,a.fluid||a.orientation===w.Horizontal?`${j}--fluid`:`${j}--fixed`,a.label?`${j}--haslabel`:"",a.orientation?`${j}--${a.orientation}`:"",a.required?`${j}--required`:`${j}--optional`]),K=l(()=>{const e=P.value?.draftStart,t=P.value?.draftEnd;return a.isRange?!!e&&!!t:!!e});return(a,t)=>(u(),r(L,{fluid:e.fluid,orientation:e.orientation},{default:n(()=>[s("div",{class:b(c(J)),"data-testid":e.testId},[e.label?(u(),r(k,{key:0,"css-prefix":j,"html-for":e.id,label:e.label,required:e.required,size:e.buttonSize,onClick:N},null,8,["html-for","label","required","size"])):f("",!0),p(c(h),{id:e.id,"aria-label":e.buttonAriaLabel||"Open date picker","border-radius":e.buttonBorderRadius,busy:e.busy,color:e.buttonColor,disabled:e.disabled||e.busy,"icon-before":c(B).Calendar,"icon-size":U[e.buttonSize],"on-click":N,"test-id":`${e.testId}__trigger`,size:e.buttonSize,variant:e.buttonVariant,width:e.buttonWidth,wrap:e.buttonWrapped},{default:n(()=>[_(v(c(W)||e.buttonLabel),1)]),_:1},8,["id","aria-label","border-radius","busy","color","disabled","icon-before","icon-size","test-id","size","variant","width","wrap"]),e.name||e.required?(u(),m("input",{key:1,class:b(`${j}__hidden-input`),name:e.name,value:c(W)||"",required:e.required,tabindex:"-1","aria-hidden":"true"},null,10,V)):f("",!0),p(c($),{"border-radius":c(O)?c(R).None:c(R).Medium,fullscreen:c(O),"is-open":c(M),"max-width":"336px","modal-id":c(E),"on-close":G,title:e.title},{body:n(()=>[p(c(g),{ref_key:"calendarRef",ref:P,modelValue:D.value,"onUpdate:modelValue":t[0]||(t[0]=e=>D.value=e),busy:e.busy,disabled:e.disabled,fluid:c(O),"is-range":e.isRange},null,8,["modelValue","busy","disabled","fluid","is-range"])]),footer:n(()=>[s("div",{class:b(`${j}__footer-actions`)},[p(c(h),{"border-radius":e.buttonBorderRadius,color:c(S).Neutral,"on-click":G,variant:c(z).Ghost},{default:n(()=>[...t[1]||(t[1]=[_(" Cancel ",-1)])]),_:1},8,["border-radius","color","variant"]),s("div",{class:b(`${j}__footer-right`)},[p(c(h),{"border-radius":e.buttonBorderRadius,color:c(S).Neutral,disabled:!c(P)?.draftStart&&!c(P)?.draftEnd,"on-click":H,variant:c(z).Ghost},{default:n(()=>[...t[2]||(t[2]=[_(" Reset ",-1)])]),_:1},8,["border-radius","color","disabled","variant"]),p(c(h),{"border-radius":e.buttonBorderRadius,color:c(S).Primary,disabled:!c(K),"on-click":T},{default:n(()=>[...t[3]||(t[3]=[_(" Apply ",-1)])]),_:1},8,["border-radius","color","disabled"])],2)],2)]),_:1},8,["border-radius","fullscreen","is-open","modal-id","title"])],10,F)]),_:1},8,["fluid","orientation"]))}});export{j as CLModalDatePicker,j as default};
@@ -1,4 +1,4 @@
1
- import { CLBorderRadius, CLColors, CLColorVariants, CLGenericFocusFunction, CLGenericFunction, CLSizes } from '../../../index.ts';
1
+ import { CLBorderRadius, CLColors, CLColorVariants, CLGenericFocusFunction, CLGenericFunction, CLOrientation, CLSizes } from '../../../index.ts';
2
2
  export interface CLModalDatePickerProps {
3
3
  /** Sets the aria-label on the trigger button. It should be used when there is no label present. */
4
4
  buttonAriaLabel?: string;
@@ -26,6 +26,10 @@ export interface CLModalDatePickerProps {
26
26
  id: string;
27
27
  /** Whether to allow range selection or single date selection. */
28
28
  isRange?: boolean;
29
+ /** The label text to be displayed which is associated to the date picker. */
30
+ label?: string;
31
+ /** A string representing name of the date picker submitted with form. */
32
+ name?: string;
29
33
  /** A callback function which handles when the date picker loses focus. */
30
34
  onBlur?: CLGenericFocusFunction;
31
35
  /** A callback function which handles when the date picker value changes. */
@@ -34,6 +38,10 @@ export interface CLModalDatePickerProps {
34
38
  onFocus?: CLGenericFocusFunction;
35
39
  /** A callback function which handles when the date picker is reset. */
36
40
  onReset?: CLGenericFunction;
41
+ /** Sets the label position to be above or to the left of the form element. The property can be one of `CLOrientation` */
42
+ orientation?: CLOrientation;
43
+ /** Set the required state. */
44
+ required?: boolean;
37
45
  /** Sets a custom ID used for unit tests. */
38
46
  testId?: string;
39
47
  /** The title content of the Modal. */
@@ -62,13 +70,17 @@ declare const _default: import('vue').DefineComponent<{
62
70
  }>, {
63
71
  fluid: boolean;
64
72
  testId: string;
73
+ name: string;
74
+ label: string;
65
75
  title: string;
66
76
  onFocus: CLGenericFocusFunction;
67
77
  onBlur: CLGenericFocusFunction;
68
78
  onChange: CLGenericFunction;
79
+ required: boolean;
69
80
  busy: boolean;
70
81
  disabled: boolean;
71
82
  isRange: boolean;
83
+ orientation: CLOrientation;
72
84
  buttonAriaLabel: string;
73
85
  buttonBorderRadius: CLBorderRadius;
74
86
  buttonColor: CLColors;
@@ -2,3 +2,4 @@ import { default as CLModalDatePickerComponent } from './CLModalDatePicker.vue';
2
2
  export { CLModalDatePickerComponent as CLModalDatePicker };
3
3
  export default CLModalDatePickerComponent;
4
4
  export type CLModalDatePicker = InstanceType<typeof CLModalDatePickerComponent>;
5
+ export type { CLModalDatePickerProps } from './CLModalDatePicker.vue';
@@ -1 +1 @@
1
- .clll-time-picker-modal{box-sizing:border-box}.clll-time-picker-modal--fluid{width:100%}.clll-time-picker-modal__footer-actions{display:flex;justify-content:space-between;align-items:center;width:100%}.clll-time-picker-modal__footer-right{display:flex;gap:var(--clll-unit-2)}
1
+ .clll-time-picker-modal{position:relative;overflow:hidden;border-radius:0;flex:none;display:inline-flex;align-items:center;box-sizing:border-box;align-items:flex-start;overflow:visible}.clll-time-picker-modal__hidden-input{position:absolute;bottom:0;left:0;width:100%;height:1px;opacity:0;pointer-events:none;z-index:-1}.clll-time-picker-modal.clll-time-picker-modal--haslabel .clll-time-picker-modal__label .clll-text.clll-time-picker-modal__label--required:after{position:relative;top:var(--clll-unit-1);content:"*";font-size:var(--clll-unit-4_5);font-weight:500;font-family:var(--clll-font-family);-webkit-font-smoothing:antialiased;color:var(--clll-input-required-asterisk-color, red);text-decoration:unset;margin-inline-start:var(--clll-unit-0_5);box-sizing:content-box;line-height:0}.clll-time-picker-modal.clll-time-picker-modal--vertical{flex-direction:column}.clll-time-picker-modal.clll-time-picker-modal--vertical.clll-time-picker-modal--haslabel>:not([hidden])~:not([hidden]){margin-top:var(--clll-unit-1_5)}.clll-time-picker-modal.clll-time-picker-modal--horizontal.clll-time-picker-modal--haslabel{flex-direction:row;align-items:center;flex-wrap:wrap}.clll-time-picker-modal.clll-time-picker-modal--horizontal.clll-time-picker-modal--haslabel .clll-time-picker-modal__label,.clll-time-picker-modal.clll-time-picker-modal--horizontal.clll-time-picker-modal--haslabel .clll-button{width:50%}.clll-time-picker-modal--fluid{width:100%}.clll-time-picker-modal__footer-actions{display:flex;justify-content:space-between;align-items:center;width:100%}.clll-time-picker-modal__footer-right{display:flex;gap:var(--clll-unit-2)}
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLModalTimePicker.css';
3
- import{defineComponent as e,mergeModels as t,ref as o,computed as a,useModel as l,onMounted as i,onBeforeUnmount as u,createElementBlock as d,openBlock as r,normalizeClass as s,createVNode as n,unref as b,withCtx as c,createTextVNode as m,toDisplayString as f,createElementVNode as p,nextTick as v}from"vue";import{_ as y}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-hSiZPrZr.js";import{CLTimePicker as _}from"../../Form/CLTimePicker/CLTimePicker.js";import{_ as L}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DNUsoevN.js";import{C as k,e as h,f as X,h as $,c as B,d as C}from"../../../chunks/index-DwjW-Z-U.js";import{useTimePicker as w}from"../../../composables/useTimePicker.js";import{i as z}from"../../../chunks/helper-BlxFN3eF.js";const R=["data-testid"],g=/* @__PURE__ */e({name:"CLModalTimePicker",__name:"CLModalTimePicker",props:/* @__PURE__ */t({buttonAriaLabel:{default:void 0},buttonBorderRadius:{default:void 0},buttonColor:{default:C.Primary},buttonLabel:{default:"Select time"},buttonSize:{default:k.Small},buttonVariant:{default:B.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},id:{},onBlur:{type:Function,default:void 0},onChange:{type:Function,default:void 0},onFocus:{type:Function,default:void 0},onReset:{type:Function,default:void 0},testId:{default:"clll-time-picker-modal"},title:{default:"Select time"},use24Hour:{type:Boolean,default:!1}},{modelValue:{default:null},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,g="clll-time-picker-modal",S=o(!1),F=a(()=>`time-picker-modal-${t.id}`),V=o(),P=l(e,"modelValue"),{formattedLabel:T}=w({appliedTime:P,use24Hour:t.use24Hour}),x=o(!1),M=()=>{z&&(x.value=window.innerWidth<480)},j=()=>{if(t.disabled||t.busy)return;M(),S.value=!0,v(()=>{V.value?.initializeDraft()});const e=new FocusEvent("focus",{bubbles:!0,cancelable:!0});t.onFocus?.(e)},W=()=>{S.value=!1,V.value?.cancel();const e=new FocusEvent("blur",{bubbles:!0,cancelable:!0});t.onBlur?.(e)},E=()=>{V.value?.apply(),S.value=!1,t.onChange?.()},H=()=>{V.value?.reset(),t.onReset?.(),t.onChange?.()},A=a(()=>x.value);i(()=>{z&&(M(),window.addEventListener("resize",M))}),u(()=>{z&&window.removeEventListener("resize",M)});const I={[k.Tiny]:h.Tiny,[k.Small]:h.Small,[k.Medium]:h.Medium,[k.Large]:h.Large,[k.XL]:h.XL,[k.XXL]:h.XXL,[k.XXXL]:h.XXXL,[k.XXXXL]:h.XXXXL},N=a(()=>[g,t.buttonBorderRadius?`${g}--${t.buttonBorderRadius}`:"",t.busy?`${g}--busy`:`${g}--ready`,`${g}--${t.buttonColor}`,`${g}--${t.buttonSize}`,`${g}--${t.buttonVariant}`,t.disabled||t.busy?`${g}--disabled`:`${g}--active`,t.fluid?`${g}--fluid`:`${g}--fixed`]);return(t,o)=>(r(),d("div",{class:s(N.value),"data-testid":e.testId},[n(b(y),{"aria-label":e.buttonAriaLabel||"Open time picker","border-radius":e.buttonBorderRadius,busy:e.busy,color:e.buttonColor,disabled:e.disabled||e.busy,"icon-before":b(X).Clock,"icon-size":I[e.buttonSize],"on-click":j,"test-id":`${e.testId}__trigger`,size:e.buttonSize,variant:e.buttonVariant,width:e.buttonWidth,wrap:e.buttonWrapped},{default:c(()=>[m(f(b(T)||e.buttonLabel),1)]),_:1},8,["aria-label","border-radius","busy","color","disabled","icon-before","icon-size","test-id","size","variant","width","wrap"]),n(b(L),{"border-radius":A.value?b($).None:b($).Medium,fullscreen:A.value,"is-open":S.value,"max-width":"340px","modal-id":F.value,"on-close":W,title:e.title},{body:c(()=>[n(b(_),{ref_key:"timePickerRef",ref:V,modelValue:P.value,"onUpdate:modelValue":o[0]||(o[0]=e=>P.value=e),busy:e.busy,disabled:e.disabled,fluid:A.value,"use24-hour":e.use24Hour},null,8,["modelValue","busy","disabled","fluid","use24-hour"])]),footer:c(()=>[p("div",{class:s(`${g}__footer-actions`)},[n(b(y),{"border-radius":e.buttonBorderRadius,color:b(C).Neutral,variant:b(B).Ghost,"on-click":W},{default:c(()=>[...o[1]||(o[1]=[m(" Cancel ",-1)])]),_:1},8,["border-radius","color","variant"]),p("div",{class:s(`${g}__footer-right`)},[n(b(y),{"border-radius":e.buttonBorderRadius,color:b(C).Neutral,variant:b(B).Ghost,"on-click":H},{default:c(()=>[...o[2]||(o[2]=[m(" Reset ",-1)])]),_:1},8,["border-radius","color","variant"]),n(b(y),{"border-radius":e.buttonBorderRadius,color:b(C).Primary,"on-click":E},{default:c(()=>[...o[3]||(o[3]=[m(" Apply ",-1)])]),_:1},8,["border-radius","color"])],2)],2)]),_:1},8,["border-radius","fullscreen","is-open","modal-id","title"])],10,R))}});export{g as CLModalTimePicker,g as default};
3
+ import{defineComponent as e,mergeModels as t,ref as a,computed as o,useModel as i,onMounted as l,onBeforeUnmount as u,createBlock as r,openBlock as d,withCtx as n,createElementVNode as s,normalizeClass as b,createCommentVNode as c,createVNode as m,createElementBlock as f,unref as p,createTextVNode as v,toDisplayString as _,nextTick as y}from"vue";import{_ as h}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-pE0JrYmS.js";import{_ as k}from"../../../chunks/CLFormField.vue_vue_type_style_index_0_lang-Rf_Mo_VS.js";import{_ as L}from"../../../chunks/CLFormLabel.vue_vue_type_script_setup_true_lang-DoM5X-sA.js";import{CLTimePicker as $}from"../../Form/CLTimePicker/CLTimePicker.js";import{_ as X}from"../../../chunks/CLModal.vue_vue_type_style_index_0_lang-DLUfvRC_.js";import{c as C,e as B,f as z,h as w,a as g,b as F}from"../../../chunks/index-DsloP0ml.js";import{a as x}from"../../../chunks/index-wkMXT2wB.js";import{useTimePicker as R}from"../../../composables/useTimePicker.js";import{i as S}from"../../../chunks/helper-BlxFN3eF.js";const q=["data-testid"],V=["name","value","required"],j=/* @__PURE__ */e({name:"CLModalTimePicker",__name:"CLModalTimePicker",props:/* @__PURE__ */t({buttonAriaLabel:{default:void 0},buttonBorderRadius:{default:void 0},buttonColor:{default:F.Primary},buttonLabel:{default:"Select time"},buttonSize:{default:C.Small},buttonVariant:{default:g.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean,default:!1},busy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},id:{},label:{default:void 0},name:{default:void 0},onBlur:{type:Function,default:void 0},onChange:{type:Function,default:void 0},onFocus:{type:Function,default:void 0},onReset:{type:Function,default:void 0},orientation:{default:x.Vertical},required:{type:Boolean,default:!1},testId:{default:"clll-time-picker-modal"},title:{default:"Select time"},use24Hour:{type:Boolean,default:!1}},{modelValue:{default:null},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,j="clll-time-picker-modal",P=a(!1),T=o(()=>`time-picker-modal-${t.id}`),M=a(),H=i(e,"modelValue"),{formattedLabel:W}=R({appliedTime:H,use24Hour:t.use24Hour}),E=a(!1),A=()=>{S&&(E.value=window.innerWidth<480)},I=()=>{if(t.disabled||t.busy)return;A(),P.value=!0,y(()=>{M.value?.initializeDraft()});const e=new FocusEvent("focus",{bubbles:!0,cancelable:!0});t.onFocus?.(e)},N=()=>{P.value=!1,M.value?.cancel();const e=new FocusEvent("blur",{bubbles:!0,cancelable:!0});t.onBlur?.(e)},G=()=>{M.value?.apply(),P.value=!1,t.onChange?.()},D=()=>{M.value?.reset(),t.onReset?.(),t.onChange?.()},O=o(()=>E.value);l(()=>{S&&(A(),window.addEventListener("resize",A))}),u(()=>{S&&window.removeEventListener("resize",A)});const U={[C.Tiny]:B.Tiny,[C.Small]:B.Small,[C.Medium]:B.Medium,[C.Large]:B.Large,[C.XL]:B.XL,[C.XXL]:B.XXL,[C.XXXL]:B.XXXL,[C.XXXXL]:B.XXXXL},J=o(()=>[j,t.buttonBorderRadius?`${j}--${t.buttonBorderRadius}`:"",t.busy?`${j}--busy`:`${j}--ready`,`${j}--${t.buttonColor}`,`${j}--${t.buttonSize}`,`${j}--${t.buttonVariant}`,t.disabled||t.busy?`${j}--disabled`:`${j}--active`,t.fluid||t.orientation===x.Horizontal?`${j}--fluid`:`${j}--fixed`,t.label?`${j}--haslabel`:"",t.orientation?`${j}--${t.orientation}`:"",t.required?`${j}--required`:`${j}--optional`]);return(t,a)=>(d(),r(k,{fluid:e.fluid,orientation:e.orientation},{default:n(()=>[s("div",{class:b(J.value),"data-testid":e.testId},[e.label?(d(),r(L,{key:0,"css-prefix":j,"html-for":e.id,label:e.label,required:e.required,size:e.buttonSize,onClick:I},null,8,["html-for","label","required","size"])):c("",!0),m(p(h),{id:e.id,"aria-label":e.buttonAriaLabel||"Open time picker","border-radius":e.buttonBorderRadius,busy:e.busy,color:e.buttonColor,disabled:e.disabled||e.busy,"icon-before":p(z).Clock,"icon-size":U[e.buttonSize],"on-click":I,"test-id":`${e.testId}__trigger`,size:e.buttonSize,variant:e.buttonVariant,width:e.buttonWidth,wrap:e.buttonWrapped},{default:n(()=>[v(_(p(W)||e.buttonLabel),1)]),_:1},8,["id","aria-label","border-radius","busy","color","disabled","icon-before","icon-size","test-id","size","variant","width","wrap"]),e.name||e.required?(d(),f("input",{key:1,class:b(`${j}__hidden-input`),name:e.name,value:p(W)||"",required:e.required,tabindex:"-1","aria-hidden":"true"},null,10,V)):c("",!0),m(p(X),{"border-radius":O.value?p(w).None:p(w).Medium,fullscreen:O.value,"is-open":P.value,"max-width":"340px","modal-id":T.value,"on-close":N,title:e.title},{body:n(()=>[m(p($),{ref_key:"timePickerRef",ref:M,modelValue:H.value,"onUpdate:modelValue":a[0]||(a[0]=e=>H.value=e),busy:e.busy,disabled:e.disabled,fluid:O.value,"use24-hour":e.use24Hour},null,8,["modelValue","busy","disabled","fluid","use24-hour"])]),footer:n(()=>[s("div",{class:b(`${j}__footer-actions`)},[m(p(h),{"border-radius":e.buttonBorderRadius,color:p(F).Neutral,variant:p(g).Ghost,"on-click":N},{default:n(()=>[...a[1]||(a[1]=[v(" Cancel ",-1)])]),_:1},8,["border-radius","color","variant"]),s("div",{class:b(`${j}__footer-right`)},[m(p(h),{"border-radius":e.buttonBorderRadius,color:p(F).Neutral,variant:p(g).Ghost,"on-click":D},{default:n(()=>[...a[2]||(a[2]=[v(" Reset ",-1)])]),_:1},8,["border-radius","color","variant"]),m(p(h),{"border-radius":e.buttonBorderRadius,color:p(F).Primary,"on-click":G},{default:n(()=>[...a[3]||(a[3]=[v(" Apply ",-1)])]),_:1},8,["border-radius","color"])],2)],2)]),_:1},8,["border-radius","fullscreen","is-open","modal-id","title"])],10,q)]),_:1},8,["fluid","orientation"]))}});export{j as CLModalTimePicker,j as default};
@@ -1,4 +1,4 @@
1
- import { CLBorderRadius, CLColors, CLColorVariants, CLGenericFocusFunction, CLGenericFunction, CLSizes } from '../../../index.ts';
1
+ import { CLBorderRadius, CLColors, CLColorVariants, CLGenericFocusFunction, CLGenericFunction, CLOrientation, CLSizes } from '../../../index.ts';
2
2
  export interface CLModalTimePickerProps {
3
3
  /** Sets aria-label on trigger button. */
4
4
  buttonAriaLabel?: string;
@@ -24,6 +24,10 @@ export interface CLModalTimePickerProps {
24
24
  fluid?: boolean;
25
25
  /** Unique ID, required. */
26
26
  id: string;
27
+ /** The label text to be displayed which is associated to the time picker. */
28
+ label?: string;
29
+ /** A string representing name of the time picker submitted with form. */
30
+ name?: string;
27
31
  /** Callback when focus is lost. */
28
32
  onBlur?: CLGenericFocusFunction;
29
33
  /** Callback when value changes. */
@@ -32,6 +36,10 @@ export interface CLModalTimePickerProps {
32
36
  onFocus?: CLGenericFocusFunction;
33
37
  /** Callback when reset is triggered. */
34
38
  onReset?: CLGenericFunction;
39
+ /** Sets the label position to be above or to the left of the form element. The property can be one of `CLOrientation` */
40
+ orientation?: CLOrientation;
41
+ /** Set the required state. */
42
+ required?: boolean;
35
43
  /** Custom test ID. */
36
44
  testId?: string;
37
45
  /** Modal header title. */
@@ -50,14 +58,18 @@ declare const _default: import('vue').DefineComponent<{
50
58
  }>, {
51
59
  fluid: boolean;
52
60
  testId: string;
61
+ name: string;
62
+ label: string;
53
63
  title: string;
54
64
  onFocus: CLGenericFocusFunction;
55
65
  onBlur: CLGenericFocusFunction;
56
66
  onChange: CLGenericFunction;
57
67
  onReset: CLGenericFunction;
58
68
  use24Hour: boolean;
69
+ required: boolean;
59
70
  busy: boolean;
60
71
  disabled: boolean;
72
+ orientation: CLOrientation;
61
73
  buttonAriaLabel: string;
62
74
  buttonBorderRadius: CLBorderRadius;
63
75
  buttonColor: CLColors;
@@ -10,14 +10,18 @@ export declare const CLModalTimePicker: import('vue').DefineComponent<{
10
10
  }>, {
11
11
  fluid: boolean;
12
12
  testId: string;
13
+ name: string;
14
+ label: string;
13
15
  title: string;
14
16
  onFocus: import('../../..').CLGenericFocusFunction;
15
17
  onBlur: import('../../..').CLGenericFocusFunction;
16
18
  onChange: import('../../..').CLGenericFunction;
17
19
  onReset: import('../../..').CLGenericFunction;
18
20
  use24Hour: boolean;
21
+ required: boolean;
19
22
  busy: boolean;
20
23
  disabled: boolean;
24
+ orientation: import('@codeandfunction/callaloo-types').CLOrientation;
21
25
  buttonAriaLabel: string;
22
26
  buttonBorderRadius: import('@codeandfunction/callaloo-tokens').CLBorderRadius;
23
27
  buttonColor: import('@codeandfunction/callaloo-tokens').CLColors;
@@ -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-DoqyJ8FL.js";export{e as CLLink,e as default};
3
+ import{_ as e}from"../../../chunks/CLLink.vue_vue_type_style_index_0_lang-B94b55if.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-B2DxfBQx.js";export{a as CLNavLink,a as default};
2
+ import{_ as a}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-BXjSe15F.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 s,renderList as i,createVNode as o,withCtx as c,createTextVNode as u,toDisplayString as d}from"vue";import{_}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-B2DxfBQx.js";import{_ as m}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js";import{d as p}from"../../../chunks/index-DwjW-Z-U.js";import{f}from"../../../chunks/index-C9S3C1LU.js";const v=["data-testid"],k=/* @__PURE__ */e({name:"CLNavSection",__name:"CLNavSection",props:{color:{default:p.Primary},navItems:{},testId:{default:"clll-nav-section"},type:{default:f.Horizontal}},setup(e){const p=e,f="clll-nav-section",k=t(()=>[f,`${f}--${p.type}`]);return(t,p)=>(l(),a("ul",{class:r(n(k)),"data-testid":e.testId},[(l(!0),a(s,null,i(e.navItems,(t,r)=>(l(),a("li",{key:`link-${t.id}-${r}`,class:"clll-nav-section__item"},[o(n(_),{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(()=>[o(n(m),{as:"span"},{default:c(()=>[u(d(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};
3
+ import{defineComponent as e,computed as t,createElementBlock as a,openBlock as l,normalizeClass as r,unref as n,Fragment as s,renderList as i,createVNode as o,withCtx as c,createTextVNode as u,toDisplayString as d}from"vue";import{_}from"../../../chunks/CLNavLink.vue_vue_type_script_setup_true_lang-BXjSe15F.js";import{_ as m}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js";import{b as p}from"../../../chunks/index-DsloP0ml.js";import{a as f}from"../../../chunks/index-wkMXT2wB.js";const v=["data-testid"],k=/* @__PURE__ */e({name:"CLNavSection",__name:"CLNavSection",props:{color:{default:p.Primary},navItems:{},testId:{default:"clll-nav-section"},type:{default:f.Horizontal}},setup(e){const p=e,f="clll-nav-section",k=t(()=>[f,`${f}--${p.type}`]);return(t,p)=>(l(),a("ul",{class:r(n(k)),"data-testid":e.testId},[(l(!0),a(s,null,i(e.navItems,(t,r)=>(l(),a("li",{key:`link-${t.id}-${r}`,class:"clll-nav-section__item"},[o(n(_),{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(()=>[o(n(m),{as:"span"},{default:c(()=>[u(d(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 t,computed as o,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 f,renderSlot as b}from"vue";import{u as m,a as _,f as v,o as w,s as g}from"../../../chunks/floating-ui.vue-C0JWy0Dz.js";import{_ as h}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-hSiZPrZr.js";import{_ as y}from"../../../chunks/CLCard.vue_vue_type_style_index_0_lang-D3JriMVx.js";import{b as B,i as $}from"../../../chunks/helper-BlxFN3eF.js";import{useDropdown as z}from"../../../composables/useDropdown.js";import{useEsc as k}from"../../../composables/useEsc.js";import{n as x,e as C,f as I,c as E,C as L,d as D,i as S}from"../../../chunks/index-DwjW-Z-U.js";const H=["data-testid"],j=["id","aria-labelledby","aria-hidden"],O=/* @__PURE__ */e({name:"CLDropdownMenu",__name:"CLDropdownMenu",props:{buttonAlign:{default:S.Center},buttonAriaLabel:{},buttonBorderRadius:{},buttonBusy:{type:Boolean},buttonColor:{default:D.Secondary},buttonDisabled:{type:Boolean},buttonHeight:{default:"auto"},buttonSize:{default:L.Small},buttonVariant:{default:E.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean},containerBordered:{type:Boolean,default:!0},containerBorderRadius:{},containerElevated:{type:Boolean,default:!1},contentWidth:{default:"auto"},dropdownId:{},fluid:{type:Boolean,default:!1},iconAfter:{default:I.ChevronDown},iconBefore:{},iconSize:{default:C.Tiny},isOpen:{type:Boolean,default:!1},label:{},onCloseHandler:{},onOpenHandler:{},placement:{default:x.BottomStart},testId:{default:"clll-dropdown-menu"},zIndex:{default:30}},setup(e,{expose:x}){const C=e;let I=t(),L=t();const S=t(),O=t(),A=t(C.isOpen),W=t(C.placement),R="clll-dropdown-menu",M=o(()=>"auto"===C.zIndex||B(C.zIndex)?C.zIndex:C.zIndex.toString()),V=e=>{e&&(I.value=e)},G=e=>{e&&(L.value=e)},N=()=>{T.value?F():q()},{open:T,openDropdown:q,closeDropdown:F,clearEventListeners:J}=z({triggerElem:I,dropdownRef:O,openDropdownHandler:()=>{A.value=!0,C?.onOpenHandler?.(),P(),$&&document.addEventListener("click",Q)},closeDropdownHandler:()=>{A.value=!1,C?.onCloseHandler?.(),$&&document.removeEventListener("click",Q),U(),J()}});x({close:()=>{F(),J(),U()},open:()=>{q()}});const{floatingStyles:K,update:P}=m(S,O,{middleware:[v(),w(10),g()],placement:W,open:A,whileElementsMounted:_}),Q=e=>{A.value&&O.value?.contains(e?.target)&&F()},{clearEventListeners:U}=k({escHandler:F,triggerElem:I});return n(()=>{$&&document.removeEventListener("click",Q),U(),J()}),(t,o)=>(d(),a("div",{class:r([`${R}__menu`,e.fluid?`${R}__menu--fluid`:""]),"data-testid":e.testId},[l(s(h),{id:`${R}__toggle--${e.dropdownId}`,ref_key:"anchor",ref:S,"aria-controls":`${R}--${e.dropdownId}`,"aria-expanded":s(A)||e.isOpen,"aria-label":e.buttonAriaLabel,"align-content":e.buttonAlign,busy:e.buttonBusy,disabled:e.buttonDisabled||e.buttonBusy,class:r(`${R}__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":`${R}__toggle`,variant:e.buttonVariant,width:e.fluid?"100%":e.buttonWidth,wrap:e.buttonWrapped,"on-click":N},{default:u(()=>[c(p(e.label),1)]),_:1},8,["id","aria-controls","aria-expanded","aria-label","align-content","busy","disabled","class","color","border-radius","height","icon-after","icon-before","icon-size","size","test-id","variant","width","wrap"]),s(A)||e.isOpen?(d(),a("div",{key:0,id:`${R}--${e.dropdownId}`,ref_key:"dropdownElem",ref:O,"aria-labelledby":`${R}__toggle--${e.dropdownId}`,"aria-hidden":!(s(A)||e.isOpen),class:r([`${R}__dropdown`,`${R}__dropdown--${s(W)}`]),style:f({...s(K),zIndex:s(M)})},[l(s(y),{bordered:e.containerBordered,"border-radius":e.containerBorderRadius,color:s(D).Neutral,elevated:e.containerElevated,"forward-ref":G,padded:!1,"test-id":`${R}__content`,variant:s(E).Ghost,width:e.contentWidth},{default:u(()=>[b(t.$slots,"content")]),_:3},8,["bordered","border-radius","color","elevated","test-id","variant","width"])],14,j)):i("",!0)],10,H))}});export{O as CLDropdownMenu,O as default};
3
+ import{defineComponent as e,ref as t,computed as o,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 f,renderSlot as b}from"vue";import{u as m,a as _,f as v,o as w,s as g}from"../../../chunks/floating-ui.vue-C0JWy0Dz.js";import{_ as h}from"../../../chunks/CLButton.vue_vue_type_style_index_0_lang-pE0JrYmS.js";import{_ as y}from"../../../chunks/CLCard.vue_vue_type_style_index_0_lang-CY-Qr_CV.js";import{b as B,i as $}from"../../../chunks/helper-BlxFN3eF.js";import{useDropdown as z}from"../../../composables/useDropdown.js";import{useEsc as k}from"../../../composables/useEsc.js";import{n as x,e as I,f as C,a as E,c as L,b as D,i as S}from"../../../chunks/index-DsloP0ml.js";const H=["data-testid"],j=["id","aria-labelledby","aria-hidden"],O=/* @__PURE__ */e({name:"CLDropdownMenu",__name:"CLDropdownMenu",props:{buttonAlign:{default:S.Center},buttonAriaLabel:{},buttonBorderRadius:{},buttonBusy:{type:Boolean},buttonColor:{default:D.Secondary},buttonDisabled:{type:Boolean},buttonHeight:{default:"auto"},buttonSize:{default:L.Small},buttonVariant:{default:E.Soft},buttonWidth:{default:"auto"},buttonWrapped:{type:Boolean},containerBordered:{type:Boolean,default:!0},containerBorderRadius:{},containerElevated:{type:Boolean,default:!1},contentWidth:{default:"auto"},dropdownId:{},fluid:{type:Boolean,default:!1},iconAfter:{default:C.ChevronDown},iconBefore:{},iconSize:{default:I.Tiny},isOpen:{type:Boolean,default:!1},label:{},onCloseHandler:{},onOpenHandler:{},placement:{default:x.BottomStart},testId:{default:"clll-dropdown-menu"},zIndex:{default:30}},setup(e,{expose:x}){const I=e;let C=t(),L=t();const S=t(),O=t(),A=t(I.isOpen),W=t(I.placement),R="clll-dropdown-menu",M=o(()=>"auto"===I.zIndex||B(I.zIndex)?I.zIndex:I.zIndex.toString()),V=e=>{e&&(C.value=e)},G=e=>{e&&(L.value=e)},N=()=>{T.value?F():q()},{open:T,openDropdown:q,closeDropdown:F,clearEventListeners:J}=z({triggerElem:C,dropdownRef:O,openDropdownHandler:()=>{A.value=!0,I?.onOpenHandler?.(),P(),$&&document.addEventListener("click",Q)},closeDropdownHandler:()=>{A.value=!1,I?.onCloseHandler?.(),$&&document.removeEventListener("click",Q),U(),J()}});x({close:()=>{F(),J(),U()},open:()=>{q()}});const{floatingStyles:K,update:P}=m(S,O,{middleware:[v(),w(10),g()],placement:W,open:A,whileElementsMounted:_}),Q=e=>{A.value&&O.value?.contains(e?.target)&&F()},{clearEventListeners:U}=k({escHandler:F,triggerElem:C});return n(()=>{$&&document.removeEventListener("click",Q),U(),J()}),(t,o)=>(d(),a("div",{class:r([`${R}__menu`,e.fluid?`${R}__menu--fluid`:""]),"data-testid":e.testId},[l(s(h),{id:`${R}__toggle--${e.dropdownId}`,ref_key:"anchor",ref:S,"aria-controls":`${R}--${e.dropdownId}`,"aria-expanded":s(A)||e.isOpen,"aria-label":e.buttonAriaLabel,"align-content":e.buttonAlign,busy:e.buttonBusy,disabled:e.buttonDisabled||e.buttonBusy,class:r(`${R}__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":`${R}__toggle`,variant:e.buttonVariant,width:e.fluid?"100%":e.buttonWidth,wrap:e.buttonWrapped,"on-click":N},{default:u(()=>[c(p(e.label),1)]),_:1},8,["id","aria-controls","aria-expanded","aria-label","align-content","busy","disabled","class","color","border-radius","height","icon-after","icon-before","icon-size","size","test-id","variant","width","wrap"]),s(A)||e.isOpen?(d(),a("div",{key:0,id:`${R}--${e.dropdownId}`,ref_key:"dropdownElem",ref:O,"aria-labelledby":`${R}__toggle--${e.dropdownId}`,"aria-hidden":!(s(A)||e.isOpen),class:r([`${R}__dropdown`,`${R}__dropdown--${s(W)}`]),style:f({...s(K),zIndex:s(M)})},[l(s(y),{bordered:e.containerBordered,"border-radius":e.containerBorderRadius,color:s(D).Neutral,elevated:e.containerElevated,"forward-ref":G,padded:!1,"test-id":`${R}__content`,variant:s(E).Ghost,width:e.contentWidth},{default:u(()=>[b(t.$slots,"content")]),_:3},8,["bordered","border-radius","color","elevated","test-id","variant","width"])],14,j)):i("",!0)],10,H))}});export{O as CLDropdownMenu,O 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-D2V4LMvh.js";export{s as CLToast,s as default};
3
+ import{_ as s}from"../../../chunks/CLToast.vue_vue_type_style_index_0_lang-D7KGFx9t.js";export{s as CLToast,s as default};
@@ -1,2 +1,2 @@
1
1
  import '../../../assets/core.css';
2
- import{ref as e,defineComponent as o,provide as t,onMounted as a,onBeforeUnmount as r,watch as s,createBlock as l,openBlock as d,resolveDynamicComponent as i,normalizeStyle as n,normalizeClass as c,unref as u,withCtx as m,renderSlot as f}from"vue";import{D as h,p as k}from"../../../chunks/index-DwjW-Z-U.js";import{T as v}from"../../../chunks/context-BrNC8CsD.js";import{i as p,c as M}from"../../../chunks/helper-BlxFN3eF.js";const g=/* @__PURE__ */o({__name:"CLThemeProvider",props:{tag:{default:"div"},themeConfig:{},autoDetectDarkMode:{type:Boolean,default:!0}},setup(o){const g=o,y=(o=>{const t=e(o?.borderRadius||h.borderRadius),a=e(o?.darkMode??h.darkMode),r=e(o?.fontFamily??h.fontFamily),s=k(h.colors,o?.colors),l=e(s);return{borderRadius:t,colors:l,darkMode:a,fontFamily:r,setBorderRadius:e=>{t.value=e},setColors:e=>{l.value={...l.value,...e}},setDarkMode:e=>{a.value=e},setFontFamily:e=>{r.value=e}}})(g.themeConfig);t(v,y);const{borderRadius:D,darkMode:C,fontFamily:F,setBorderRadius:R,setColors:b,setDarkMode:j,setFontFamily:L}=y;let x=null;const B=()=>{if(g.autoDetectDarkMode&&p){const e=M();j(e)}};return a(()=>{g.autoDetectDarkMode&&p&&(B(),x=window.matchMedia("(prefers-color-scheme: dark)"),x.addEventListener("change",B))}),r(()=>{x&&p&&x.removeEventListener("change",B)}),s(()=>g.themeConfig?.borderRadius,e=>{R(e)}),s(()=>g.themeConfig?.colors,e=>{e&&b(e)}),s(()=>g.themeConfig?.darkMode,e=>{void 0===e||g.autoDetectDarkMode||j(e)}),s(()=>g.themeConfig?.fontFamily,e=>{L(e)}),(e,t)=>(d(),l(i(o.tag),{class:c(["clll-theme-provider","--clll-color-theme-"+(u(C)?"dark":"light")]),style:n({"--clll-font-family":u(F),"--clll-default-radius":u(D)?`var(--clll-${u(D)})`:void 0})},{default:m(()=>[f(e.$slots,"default")]),_:3},8,["class","style"]))}});export{g as CLThemeProvider,h as DEFAULT_THEME,v as ThemeInjectionKey,g as default};
2
+ import{ref as e,defineComponent as o,provide as t,onMounted as a,onBeforeUnmount as r,watch as s,createBlock as l,openBlock as d,resolveDynamicComponent as i,normalizeStyle as n,normalizeClass as c,unref as u,withCtx as m,renderSlot as f}from"vue";import{D as h,p as k}from"../../../chunks/index-DsloP0ml.js";import{T as v}from"../../../chunks/context-BrNC8CsD.js";import{i as p,c as M}from"../../../chunks/helper-BlxFN3eF.js";const g=/* @__PURE__ */o({__name:"CLThemeProvider",props:{tag:{default:"div"},themeConfig:{},autoDetectDarkMode:{type:Boolean,default:!0}},setup(o){const g=o,y=(o=>{const t=e(o?.borderRadius||h.borderRadius),a=e(o?.darkMode??h.darkMode),r=e(o?.fontFamily??h.fontFamily),s=k(h.colors,o?.colors),l=e(s);return{borderRadius:t,colors:l,darkMode:a,fontFamily:r,setBorderRadius:e=>{t.value=e},setColors:e=>{l.value={...l.value,...e}},setDarkMode:e=>{a.value=e},setFontFamily:e=>{r.value=e}}})(g.themeConfig);t(v,y);const{borderRadius:D,darkMode:C,fontFamily:F,setBorderRadius:R,setColors:b,setDarkMode:j,setFontFamily:L}=y;let x=null;const B=()=>{if(g.autoDetectDarkMode&&p){const e=M();j(e)}};return a(()=>{g.autoDetectDarkMode&&p&&(B(),x=window.matchMedia("(prefers-color-scheme: dark)"),x.addEventListener("change",B))}),r(()=>{x&&p&&x.removeEventListener("change",B)}),s(()=>g.themeConfig?.borderRadius,e=>{R(e)}),s(()=>g.themeConfig?.colors,e=>{e&&b(e)}),s(()=>g.themeConfig?.darkMode,e=>{void 0===e||g.autoDetectDarkMode||j(e)}),s(()=>g.themeConfig?.fontFamily,e=>{L(e)}),(e,t)=>(d(),l(i(o.tag),{class:c(["clll-theme-provider","--clll-color-theme-"+(u(C)?"dark":"light")]),style:n({"--clll-font-family":u(F),"--clll-default-radius":u(D)?`var(--clll-${u(D)})`:void 0})},{default:m(()=>[f(e.$slots,"default")]),_:3},8,["class","style"]))}});export{g as CLThemeProvider,h as DEFAULT_THEME,v as ThemeInjectionKey,g 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-D2V4LMvh.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};
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-D7KGFx9t.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,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLHeading.css';
3
- import{_ as e}from"../../../chunks/CLHeading.vue_vue_type_style_index_0_lang-Bp0Hmc-g.js";export{e as CLHeading,e as default};
3
+ import{_ as e}from"../../../chunks/CLHeading.vue_vue_type_style_index_0_lang-PCOhAZkN.js";export{e as CLHeading,e as default};
@@ -1,3 +1,3 @@
1
1
  import '../../../assets/core.css';
2
2
  import './CLText.css';
3
- import{_ as e}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-BZQzsJMF.js";export{e as CLText,e as default};
3
+ import{_ as e}from"../../../chunks/CLText.vue_vue_type_style_index_0_lang-CdA4TW0N.js";export{e as CLText,e as default};
@@ -1,2 +1,2 @@
1
1
  import '../assets/core.css';
2
- import{T as o}from"../chunks/context-BrNC8CsD.js";import{ref as e,getCurrentInstance as r,inject as a}from"vue";import{D as n}from"../chunks/index-DwjW-Z-U.js";const s=e(n.borderRadius),t=e(n.darkMode),l=e(n.fontFamily),u=e(n.colors||{primary:{},secondary:{},neutral:{},danger:{},warning:{},success:{},info:{}}),m=()=>{const e=r(),n=e?.type.name||"(anonymous component)",m=a(o,null);return m||(console.warn(`[Callaloo]: useTheme() must be used within a <CLThemeProvider />. Called from component: ${n}`,(new Error).stack),{borderRadius:s,colors:u,darkMode:t,fontFamily:l,setBorderRadius:o=>{s.value=o},setColors:o=>{u.value={...u.value,...o}},setDarkMode:o=>{t.value=o},setFontFamily:o=>{l.value=o}})};export{m as useTheme};
2
+ import{ref as o,getCurrentInstance as e,inject as r}from"vue";import{D as a}from"../chunks/index-DsloP0ml.js";import{T as n}from"../chunks/context-BrNC8CsD.js";const s=o(a.borderRadius),t=o(a.darkMode),l=o(a.fontFamily),u=o(a.colors||{primary:{},secondary:{},neutral:{},danger:{},warning:{},success:{},info:{}}),m=()=>{const o=e(),a=o?.type.name||"(anonymous component)",m=r(n,null);return m||(console.warn(`[Callaloo]: useTheme() must be used within a <CLThemeProvider />. Called from component: ${a}`,(new Error).stack),{borderRadius:s,colors:u,darkMode:t,fontFamily:l,setBorderRadius:o=>{s.value=o},setColors:o=>{u.value={...u.value,...o}},setDarkMode:o=>{t.value=o},setFontFamily:o=>{l.value=o}})};export{m as useTheme};
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- export{i as CLAlign,h as CLBorderRadius,k as CLCardTypes,c as CLColorVariants,d as CLColors,m as CLDrawerPosition,l as CLHeadingTypes,f as CLIconNames,e as CLIconSizes,b as CLMode,n as CLPlacement,j as CLPosition,C as CLSizes,q as CLTableTypes,a as CLTextTypes,o as CLToastPosition}from"./chunks/index-DwjW-Z-U.js";export{C as CLCharCounterLayout,b as CLHeadingLevels,h as CLInputTypes,a as CLLinkTarget,d as CLLoading,i as CLMessageType,e as CLOrder,f as CLOrientation,c as CLOverflow,g as CLPaginationType}from"./chunks/index-C9S3C1LU.js";var s=/* @__PURE__ */(s=>(s.Button="button",s.Submit="submit",s))(s||{});export{s as CLButtonTypes};
1
+ export{i as CLAlign,h as CLBorderRadius,k as CLCardTypes,a as CLColorVariants,b as CLColors,m as CLDrawerPosition,l as CLHeadingTypes,f as CLIconNames,e as CLIconSizes,C as CLMode,n as CLPlacement,j as CLPosition,c as CLSizes,q as CLTableTypes,d as CLTextTypes,o as CLToastPosition}from"./chunks/index-DsloP0ml.js";export{C as CLCharCounterLayout,c as CLHeadingLevels,h as CLInputTypes,b as CLLinkTarget,e as CLLoading,i as CLMessageType,f as CLOrder,a as CLOrientation,d as CLOverflow,g as CLPaginationType}from"./chunks/index-wkMXT2wB.js";var s=/* @__PURE__ */(s=>(s.Button="button",s.Submit="submit",s))(s||{});export{s as CLButtonTypes};