quirk-ui 0.1.37 → 0.1.38

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.
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../index23.css');const c=require("react/jsx-runtime"),s=require("react"),Ce=require("../../../arrow-left-4E3t8axP.cjs"),Se=require("../../../arrow-right-DO6S4vfx.cjs"),ke="_carousel_1v597_1",Ee="_noPointerEvents_1v597_21",De="_trackContainer_1v597_25",Ie="_track_1v597_25",Xe="_isMounted_1v597_39",je="_page_1v597_44",Ne="_controls_1v597_54",Re="_indicators_1v597_65",Ae="_indicator_1v597_65",Te="_active_1v597_87",Le="_buttons_1v597_106",We="_prev_1v597_111",Pe="_disabled_1v597_111",qe="_next_1v597_112",ze="_expandable_1v597_142",r={carousel:ke,noPointerEvents:Ee,trackContainer:De,track:Ie,isMounted:Xe,page:je,controls:Ne,indicators:Re,indicator:Ae,active:Te,buttons:Le,prev:We,disabled:Pe,next:qe,expandable:ze};function Ye({items:m,itemsPerPage:v=3,itemsPerRow:G=3,autoplay:J=!1,autoplayInterval:T=3,className:Q,parentRef:Z,siblingRef:p,isSplit:L=!1,isExpandable:ee=!1,ariaLabel:te="Carousel"}){const[i,_]=s.useState(0),[u,$]=s.useState(0),[M,I]=s.useState(0),[a,ne]=s.useState(v),[w,se]=s.useState(!1),[W,oe]=s.useState(J),[C,ae]=s.useState(!1),[re,ce]=s.useState(!1),le=s.useRef(null),h=s.useRef(null),b=s.useRef(null),S=Z,[x,X]=s.useState(!1),[P,q]=s.useState(null),[k,z]=s.useState(null),[Y,B]=s.useState(null),[ie,H]=s.useState(!1),[g,K]=s.useState(null),[j,O]=s.useState(null),ue=e=>{Math.abs((j??0)-(g??0))>25&&(e.stopPropagation(),e.preventDefault())},de=e=>{K(e.clientX)},he=e=>{g!==null&&Math.abs(e.clientX-g)>5&&(H(!0),O(e.clientX))},fe=()=>{if(!g||!j){N();return}const e=g-j;Math.abs(e)>50&&(e>0?E():D()),N()},ve=()=>{N()},N=()=>{H(!1),K(null),O(null)},pe=e=>{e.key==="ArrowLeft"?(e.preventDefault(),D()):e.key==="ArrowRight"?(e.preventDefault(),E()):e.key==="Home"?(e.preventDefault(),f(0)):e.key==="End"&&(e.preventDefault(),f(l-1))},_e=e=>{z(e.touches[0].clientX),q(e.touches[0].clientY),X(!1)},U=s.useRef(null);s.useEffect(()=>{ce(!0)},[]),s.useEffect(()=>{const e=U.current;if(!e)return;const t=n=>{const o=n.touches[0].clientX-(k??0),d=n.touches[0].clientY-(P??0);!x&&Math.abs(o)>Math.abs(d)&&X(!0),x&&(n.preventDefault(),B(n.touches[0].clientX))};return e.addEventListener("touchmove",t,{passive:!0}),()=>{e.removeEventListener("touchmove",t)}},[x,k,P]);const Me=()=>{if(k===null||Y===null)return;const e=k-Y;Math.abs(e)>50&&(e>0?E():D()),z(null),B(null),q(null),X(!1)},we=(e,t)=>{const n=[];for(let o=0;o<e.length;o+=t)n.push(e.slice(o,o+t));return n};s.useLayoutEffect(()=>{if(typeof window<"u"){const e=()=>{const t=window.innerWidth<768,n=t?1:v;se(t),ne(t?1:v),_(o=>Math.min(o,Math.ceil(m.length/n)-1))};return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}},[v]);const R=Math.ceil(a/G),V=we(m,a),l=V.length,me=3*16,be=3*16,xe=s.useCallback(e=>{if(e&&!C){const t=e.getBoundingClientRect().width;t>0&&t!==M&&(I(t),ae(!0))}},[M,C]);s.useEffect(()=>{var e,t,n,o;if(C&&u>0&&h.current&&((t=(e=h.current.children[0])==null?void 0:e.children[0])!=null&&t.children[0])){const y=((o=(n=h.current.children[0])==null?void 0:n.children[0])==null?void 0:o.children[0]).getBoundingClientRect().width;y>0&&y!==M&&I(y)}},[u,C,M]),s.useEffect(()=>{const e=new ResizeObserver(t=>{var n,o;for(let d of t)if(d.contentRect){w?$(d.contentRect.width-be):L?p!=null&&p.current?$(d.contentRect.width-((n=p==null?void 0:p.current)==null?void 0:n.offsetWidth)-me):$(d.contentRect.width):($(d.contentRect.width),I(((o=h==null?void 0:h.current)==null?void 0:o.children[0].children[0].children[0].getBoundingClientRect().width)??0));const y=w?1:v;_($e=>Math.min($e,Math.ceil(m.length/y)-1))}});return S!=null&&S.current&&e.observe(S.current),()=>e.disconnect()},[w,L,m]);const A=()=>{b.current&&clearInterval(b.current),oe(!1)},E=()=>{A(),_(e=>Math.min(e+1,l-1))},D=()=>{A(),_(e=>Math.max(e-1,0))},f=e=>{A(),_(e)},ge=()=>u?`translateX(-${i*u}px)`:"translateX(0px)",F=()=>{_(e=>e>=l-1?0:e+1)};s.useEffect(()=>(W&&(b.current=setInterval(F,T*1e3)),()=>{b.current&&clearInterval(b.current)}),[W,T,F]);const ye={"--max-item-width":`${(u-(a-1)*16)/a}px`};return c.jsxs("div",{className:`${Q??""} ${r.carousel}`,ref:le,role:"region","aria-label":te,"aria-roledescription":"carousel",tabIndex:0,onKeyDown:pe,style:{outline:"none"},children:[c.jsx("div",{ref:U,className:`${r.trackContainer} ${ie||x?r.noPointerEvents:""}`,style:{maxWidth:`${u}px`,touchAction:x?"none":"pan-y"},onTouchStart:_e,onTouchEnd:Me,onMouseDown:de,onMouseMove:he,onMouseUp:fe,onMouseLeave:ve,children:c.jsx("div",{ref:h,className:`${r.track} ${re?r.isMounted:""}`,style:{width:`${l*100}%`,transform:ge()},id:"carousel-track","aria-live":"polite","aria-atomic":"true","aria-label":`Slide ${i+1} of ${l}`,children:V.map((e,t)=>c.jsx("div",{className:`${r.page} ${ee?r.expandable:""}`,style:{display:R>1?"grid":"flex",gridTemplateColumns:`repeat(${Math.ceil(a/R)}, 1fr)`,gridTemplateRows:`repeat(${R}, 1fr)`,width:`${u}px`,margin:`${a>1?"unset":"0 auto"}`,justifyContent:`${a>1?"unset":"center"}`},children:e.map((n,o)=>c.jsx("div",{ref:t===0&&o===0?xe:null,onClickCapture:ue,style:{...ye,display:a>1?"unset":"flex",justifyContent:a>1?"unset":"center",alignItems:a>1?"unset":"center",flexBasis:a>1?w?"100%":`${(u-(a-1)*16)/a}px`:"unset",width:a>1?w?`${u/a-16}px`:"unset":"100%"},children:n},o))},t))})}),l>1&&c.jsxs("div",{className:r.controls,style:{maxWidth:M>0&&v===1&&!w?`${M}px`:"unset"},children:[c.jsx("div",{className:r.indicators,role:"tablist","aria-label":"Slide indicators",children:Array.from({length:l}).map((e,t)=>c.jsx("button",{role:"tab","aria-selected":t===i,"aria-label":`Slide ${t+1} of ${l}`,"aria-controls":"carousel-track",tabIndex:t===i?0:-1,className:`${r.indicator} ${t===i?r.active:""}`,onClick:()=>f(t),onKeyDown:n=>{n.key==="ArrowRight"?(n.preventDefault(),f(Math.min(t+1,l-1))):n.key==="ArrowLeft"?(n.preventDefault(),f(Math.max(t-1,0))):n.key==="Home"?(n.preventDefault(),f(0)):n.key==="End"&&(n.preventDefault(),f(l-1))}},t))}),c.jsxs("div",{className:r.buttons,children:[c.jsx("button",{"aria-label":"Previous slide",className:`${r.prev} ${i===0?r.disabled:""}`,onClick:D,disabled:i===0,children:c.jsx(Ce.ArrowLeft,{size:36})}),c.jsx("button",{"aria-label":"Next slide",className:`${r.next} ${i>=l-1?r.disabled:""}`,onClick:E,disabled:i>=m.length-a,children:c.jsx(Se.ArrowRight,{size:36})})]})]})]})}exports.Carousel=Ye;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../index23.css');const c=require("react/jsx-runtime"),s=require("react"),Ce=require("../../../arrow-left-4E3t8axP.cjs"),Se=require("../../../arrow-right-DO6S4vfx.cjs"),ke="_carousel_1v597_1",Ee="_noPointerEvents_1v597_21",De="_trackContainer_1v597_25",Ie="_track_1v597_25",Xe="_isMounted_1v597_39",je="_page_1v597_44",Ne="_controls_1v597_54",Re="_indicators_1v597_65",Ae="_indicator_1v597_65",Te="_active_1v597_87",Le="_buttons_1v597_106",We="_prev_1v597_111",Pe="_disabled_1v597_111",qe="_next_1v597_112",ze="_expandable_1v597_142",r={carousel:ke,noPointerEvents:Ee,trackContainer:De,track:Ie,isMounted:Xe,page:je,controls:Ne,indicators:Re,indicator:Ae,active:Te,buttons:Le,prev:We,disabled:Pe,next:qe,expandable:ze};function Ye({items:m,itemsPerPage:v=3,itemsPerRow:G=3,autoplay:J=!1,autoplayInterval:T=3,className:Q,parentRef:Z,siblingRef:p,isSplit:L=!1,isExpandable:ee=!1,ariaLabel:te="Carousel"}){const[i,_]=s.useState(0),[u,$]=s.useState(0),[M,I]=s.useState(0),[o,ne]=s.useState(v),[w,se]=s.useState(!1),[W,ae]=s.useState(J),[C,oe]=s.useState(!1),[re,ce]=s.useState(!1),le=s.useRef(null),h=s.useRef(null),b=s.useRef(null),S=Z,[x,X]=s.useState(!1),[P,q]=s.useState(null),[k,z]=s.useState(null),[Y,B]=s.useState(null),[ie,H]=s.useState(!1),[g,K]=s.useState(null),[j,O]=s.useState(null),ue=e=>{Math.abs((j??0)-(g??0))>25&&(e.stopPropagation(),e.preventDefault())},de=e=>{K(e.clientX)},he=e=>{g!==null&&Math.abs(e.clientX-g)>5&&(H(!0),O(e.clientX))},fe=()=>{if(!g||!j){N();return}const e=g-j;Math.abs(e)>50&&(e>0?E():D()),N()},ve=()=>{N()},N=()=>{H(!1),K(null),O(null)},pe=e=>{e.key==="ArrowLeft"?(e.preventDefault(),D()):e.key==="ArrowRight"?(e.preventDefault(),E()):e.key==="Home"?(e.preventDefault(),f(0)):e.key==="End"&&(e.preventDefault(),f(l-1))},_e=e=>{z(e.touches[0].clientX),q(e.touches[0].clientY),X(!1)},U=s.useRef(null);s.useEffect(()=>{ce(!0)},[]),s.useEffect(()=>{const e=U.current;if(!e)return;const t=n=>{const a=n.touches[0].clientX-(k??0),d=n.touches[0].clientY-(P??0);!x&&Math.abs(a)>Math.abs(d)&&X(!0),x&&(n.preventDefault(),B(n.touches[0].clientX))};return e.addEventListener("touchmove",t,{passive:!0}),()=>{e.removeEventListener("touchmove",t)}},[x,k,P]);const Me=()=>{if(k===null||Y===null)return;const e=k-Y;Math.abs(e)>50&&(e>0?E():D()),z(null),B(null),q(null),X(!1)},we=(e,t)=>{const n=[];for(let a=0;a<e.length;a+=t)n.push(e.slice(a,a+t));return n};s.useLayoutEffect(()=>{if(typeof window<"u"){const e=()=>{const t=window.innerWidth<768,n=t?1:v;se(t),ne(t?1:v),_(a=>Math.min(a,Math.ceil(m.length/n)-1))};return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}},[v]);const R=Math.ceil(o/G),V=we(m,o),l=V.length,me=3*16,be=3*16,xe=s.useCallback(e=>{if(e&&!C){const t=e.getBoundingClientRect().width;t>0&&t!==M&&(I(t),oe(!0))}},[M,C]);s.useEffect(()=>{var e,t,n,a;if(C&&u>0&&h.current&&((t=(e=h.current.children[0])==null?void 0:e.children[0])!=null&&t.children[0])){const y=((a=(n=h.current.children[0])==null?void 0:n.children[0])==null?void 0:a.children[0]).getBoundingClientRect().width;y>0&&y!==M&&I(y)}},[u,C,M]),s.useEffect(()=>{const e=new ResizeObserver(t=>{var n,a;for(let d of t)if(d.contentRect){w?$(d.contentRect.width-be):L?p!=null&&p.current?$(d.contentRect.width-((n=p==null?void 0:p.current)==null?void 0:n.offsetWidth)-me):$(d.contentRect.width):($(d.contentRect.width),I(((a=h==null?void 0:h.current)==null?void 0:a.children[0].children[0].children[0].getBoundingClientRect().width)??0));const y=w?1:v;_($e=>Math.min($e,Math.ceil(m.length/y)-1))}});return S!=null&&S.current&&e.observe(S.current),()=>e.disconnect()},[w,L,m]);const A=()=>{b.current&&clearInterval(b.current),ae(!1)},E=()=>{A(),_(e=>Math.min(e+1,l-1))},D=()=>{A(),_(e=>Math.max(e-1,0))},f=e=>{A(),_(e)},ge=()=>u?`translateX(-${i*u}px)`:"translateX(0px)",F=()=>{_(e=>e>=l-1?0:e+1)};s.useEffect(()=>(W&&(b.current=setInterval(F,T*1e3)),()=>{b.current&&clearInterval(b.current)}),[W,T,F]);const ye={"--max-item-width":`${(u-(o-1)*16)/o}px`};return c.jsxs("div",{className:`${Q??""} ${r.carousel}`,ref:le,role:"region","aria-label":te,"aria-roledescription":"carousel",tabIndex:0,onKeyDown:pe,style:{outline:"none"},children:[c.jsx("div",{ref:U,className:`${r.trackContainer} ${ie||x?r.noPointerEvents:""}`,style:{maxWidth:`${u}px`,touchAction:x?"none":"pan-y"},onTouchStart:_e,onTouchEnd:Me,onMouseDown:de,onMouseMove:he,onMouseUp:fe,onMouseLeave:ve,children:c.jsx("div",{ref:h,className:`${r.track} ${re?r.isMounted:""}`,style:{width:`${l*100}%`,transform:ge()},id:"carousel-track","aria-live":"polite","aria-atomic":"true","aria-label":`Slide ${i+1} of ${l}`,children:V.map((e,t)=>c.jsx("div",{className:`${r.page} ${ee?r.expandable:""}`,style:{display:R>1?"grid":"flex",gridTemplateColumns:`repeat(${Math.ceil(o/R)}, 1fr)`,gridTemplateRows:`repeat(${R}, 1fr)`,width:`${u}px`,margin:`${o>1?"unset":"0 auto"}`,justifyContent:`${o>1?"unset":"center"}`},children:e.map((n,a)=>c.jsx("div",{ref:t===0&&a===0?xe:null,onClickCapture:ue,style:{...ye,display:o>1?"unset":"flex",justifyContent:o>1?"unset":"center",alignItems:o>1?"unset":"flex-start",flexBasis:o>1?w?"100%":`${(u-(o-1)*16)/o}px`:"unset",width:o>1?w?`${u/o-16}px`:"unset":"100%"},children:n},a))},t))})}),l>1&&c.jsxs("div",{className:r.controls,style:{maxWidth:M>0&&v===1&&!w?`${M}px`:"unset"},children:[c.jsx("div",{className:r.indicators,role:"tablist","aria-label":"Slide indicators",children:Array.from({length:l}).map((e,t)=>c.jsx("button",{role:"tab","aria-selected":t===i,"aria-label":`Slide ${t+1} of ${l}`,"aria-controls":"carousel-track",tabIndex:t===i?0:-1,className:`${r.indicator} ${t===i?r.active:""}`,onClick:()=>f(t),onKeyDown:n=>{n.key==="ArrowRight"?(n.preventDefault(),f(Math.min(t+1,l-1))):n.key==="ArrowLeft"?(n.preventDefault(),f(Math.max(t-1,0))):n.key==="Home"?(n.preventDefault(),f(0)):n.key==="End"&&(n.preventDefault(),f(l-1))}},t))}),c.jsxs("div",{className:r.buttons,children:[c.jsx("button",{"aria-label":"Previous slide",className:`${r.prev} ${i===0?r.disabled:""}`,onClick:D,disabled:i===0,children:c.jsx(Ce.ArrowLeft,{size:36})}),c.jsx("button",{"aria-label":"Next slide",className:`${r.next} ${i>=l-1?r.disabled:""}`,onClick:E,disabled:i>=m.length-o,children:c.jsx(Se.ArrowRight,{size:36})})]})]})]})}exports.Carousel=Ye;
@@ -1,4 +1,4 @@
1
- import { jsxs as P, jsx as l } from "react/jsx-runtime";
1
+ import { jsxs as P, jsx as c } from "react/jsx-runtime";
2
2
  import { useState as a, useRef as A, useEffect as C, useLayoutEffect as De, useCallback as Ie } from "react";
3
3
  import { A as Xe } from "../../../arrow-left-BIJvHwNQ.js";
4
4
  import { A as Ae } from "../../../arrow-right-QEwnX3Sk.js";
@@ -32,7 +32,7 @@ function Je({
32
32
  isExpandable: se = !1,
33
33
  ariaLabel: oe = "Carousel"
34
34
  }) {
35
- const [i, m] = a(0), [d, x] = a(0), [_, N] = a(0), [o, re] = a(v), [M, ae] = a(!1), [j, ce] = a(ee), [k, le] = a(!1), [ie, de] = a(!1), ue = A(null), h = A(null), b = A(null), E = ne, [y, S] = a(!1), [B, H] = a(null), [D, K] = a(null), [U, O] = a(null), [he, V] = a(!1), [g, q] = a(null), [T, F] = a(null), fe = (e) => {
35
+ const [i, m] = a(0), [d, x] = a(0), [_, N] = a(0), [o, re] = a(v), [M, ae] = a(!1), [j, le] = a(ee), [k, ce] = a(!1), [ie, de] = a(!1), ue = A(null), h = A(null), b = A(null), E = ne, [y, S] = a(!1), [B, H] = a(null), [D, K] = a(null), [U, O] = a(null), [he, V] = a(!1), [g, q] = a(null), [T, F] = a(null), fe = (e) => {
36
36
  Math.abs((T ?? 0) - (g ?? 0)) > 25 && (e.stopPropagation(), e.preventDefault());
37
37
  }, ve = (e) => {
38
38
  q(e.clientX);
@@ -50,7 +50,7 @@ function Je({
50
50
  }, W = () => {
51
51
  V(!1), q(null), F(null);
52
52
  }, Me = (e) => {
53
- e.key === "ArrowLeft" ? (e.preventDefault(), X()) : e.key === "ArrowRight" ? (e.preventDefault(), I()) : e.key === "Home" ? (e.preventDefault(), f(0)) : e.key === "End" && (e.preventDefault(), f(c - 1));
53
+ e.key === "ArrowLeft" ? (e.preventDefault(), X()) : e.key === "ArrowRight" ? (e.preventDefault(), I()) : e.key === "Home" ? (e.preventDefault(), f(0)) : e.key === "End" && (e.preventDefault(), f(l - 1));
54
54
  }, we = (e) => {
55
55
  K(e.touches[0].clientX), H(e.touches[0].clientY), S(!1);
56
56
  }, G = A(null);
@@ -88,11 +88,11 @@ function Je({
88
88
  return e(), window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
89
89
  }
90
90
  }, [v]);
91
- const L = Math.ceil(o / Z), J = ye(w, o), c = J.length, ge = 3 * 16, $e = 3 * 16, Ce = Ie(
91
+ const L = Math.ceil(o / Z), J = ye(w, o), l = J.length, ge = 3 * 16, $e = 3 * 16, Ce = Ie(
92
92
  (e) => {
93
93
  if (e && !k) {
94
94
  const t = e.getBoundingClientRect().width;
95
- t > 0 && t !== _ && (N(t), le(!0));
95
+ t > 0 && t !== _ && (N(t), ce(!0));
96
96
  }
97
97
  },
98
98
  [_, k]
@@ -122,15 +122,15 @@ function Je({
122
122
  return E != null && E.current && e.observe(E.current), () => e.disconnect();
123
123
  }, [M, Y, w]);
124
124
  const R = () => {
125
- b.current && clearInterval(b.current), ce(!1);
125
+ b.current && clearInterval(b.current), le(!1);
126
126
  }, I = () => {
127
- R(), m((e) => Math.min(e + 1, c - 1));
127
+ R(), m((e) => Math.min(e + 1, l - 1));
128
128
  }, X = () => {
129
129
  R(), m((e) => Math.max(e - 1, 0));
130
130
  }, f = (e) => {
131
131
  R(), m(e);
132
132
  }, xe = () => d ? `translateX(-${i * d}px)` : "translateX(0px)", Q = () => {
133
- m((e) => e >= c - 1 ? 0 : e + 1);
133
+ m((e) => e >= l - 1 ? 0 : e + 1);
134
134
  };
135
135
  C(() => (j && (b.current = setInterval(
136
136
  Q,
@@ -153,7 +153,7 @@ function Je({
153
153
  onKeyDown: Me,
154
154
  style: { outline: "none" },
155
155
  children: [
156
- /* @__PURE__ */ l(
156
+ /* @__PURE__ */ c(
157
157
  "div",
158
158
  {
159
159
  ref: G,
@@ -168,17 +168,17 @@ function Je({
168
168
  onMouseMove: pe,
169
169
  onMouseUp: me,
170
170
  onMouseLeave: _e,
171
- children: /* @__PURE__ */ l(
171
+ children: /* @__PURE__ */ c(
172
172
  "div",
173
173
  {
174
174
  ref: h,
175
175
  className: `${r.track} ${ie ? r.isMounted : ""}`,
176
- style: { width: `${c * 100}%`, transform: xe() },
176
+ style: { width: `${l * 100}%`, transform: xe() },
177
177
  id: "carousel-track",
178
178
  "aria-live": "polite",
179
179
  "aria-atomic": "true",
180
- "aria-label": `Slide ${i + 1} of ${c}`,
181
- children: J.map((e, t) => /* @__PURE__ */ l(
180
+ "aria-label": `Slide ${i + 1} of ${l}`,
181
+ children: J.map((e, t) => /* @__PURE__ */ c(
182
182
  "div",
183
183
  {
184
184
  className: `${r.page} ${se ? r.expandable : ""}`,
@@ -192,7 +192,7 @@ function Je({
192
192
  margin: `${o > 1 ? "unset" : "0 auto"}`,
193
193
  justifyContent: `${o > 1 ? "unset" : "center"}`
194
194
  },
195
- children: e.map((n, s) => /* @__PURE__ */ l(
195
+ children: e.map((n, s) => /* @__PURE__ */ c(
196
196
  "div",
197
197
  {
198
198
  ref: t === 0 && s === 0 ? Ce : null,
@@ -201,7 +201,7 @@ function Je({
201
201
  ...ke,
202
202
  display: o > 1 ? "unset" : "flex",
203
203
  justifyContent: o > 1 ? "unset" : "center",
204
- alignItems: o > 1 ? "unset" : "center",
204
+ alignItems: o > 1 ? "unset" : "flex-start",
205
205
  flexBasis: o > 1 ? M ? "100%" : `${(d - (o - 1) * 16) / o}px` : "unset",
206
206
  width: o > 1 ? M ? `${d / o - 16}px` : "unset" : "100%"
207
207
  },
@@ -216,7 +216,7 @@ function Je({
216
216
  )
217
217
  }
218
218
  ),
219
- c > 1 && /* @__PURE__ */ P(
219
+ l > 1 && /* @__PURE__ */ P(
220
220
  "div",
221
221
  {
222
222
  className: r.controls,
@@ -224,24 +224,24 @@ function Je({
224
224
  maxWidth: _ > 0 && v === 1 && !M ? `${_}px` : "unset"
225
225
  },
226
226
  children: [
227
- /* @__PURE__ */ l(
227
+ /* @__PURE__ */ c(
228
228
  "div",
229
229
  {
230
230
  className: r.indicators,
231
231
  role: "tablist",
232
232
  "aria-label": "Slide indicators",
233
- children: Array.from({ length: c }).map((e, t) => /* @__PURE__ */ l(
233
+ children: Array.from({ length: l }).map((e, t) => /* @__PURE__ */ c(
234
234
  "button",
235
235
  {
236
236
  role: "tab",
237
237
  "aria-selected": t === i,
238
- "aria-label": `Slide ${t + 1} of ${c}`,
238
+ "aria-label": `Slide ${t + 1} of ${l}`,
239
239
  "aria-controls": "carousel-track",
240
240
  tabIndex: t === i ? 0 : -1,
241
241
  className: `${r.indicator} ${t === i ? r.active : ""}`,
242
242
  onClick: () => f(t),
243
243
  onKeyDown: (n) => {
244
- n.key === "ArrowRight" ? (n.preventDefault(), f(Math.min(t + 1, c - 1))) : n.key === "ArrowLeft" ? (n.preventDefault(), f(Math.max(t - 1, 0))) : n.key === "Home" ? (n.preventDefault(), f(0)) : n.key === "End" && (n.preventDefault(), f(c - 1));
244
+ n.key === "ArrowRight" ? (n.preventDefault(), f(Math.min(t + 1, l - 1))) : n.key === "ArrowLeft" ? (n.preventDefault(), f(Math.max(t - 1, 0))) : n.key === "Home" ? (n.preventDefault(), f(0)) : n.key === "End" && (n.preventDefault(), f(l - 1));
245
245
  }
246
246
  },
247
247
  t
@@ -249,24 +249,24 @@ function Je({
249
249
  }
250
250
  ),
251
251
  /* @__PURE__ */ P("div", { className: r.buttons, children: [
252
- /* @__PURE__ */ l(
252
+ /* @__PURE__ */ c(
253
253
  "button",
254
254
  {
255
255
  "aria-label": "Previous slide",
256
256
  className: `${r.prev} ${i === 0 ? r.disabled : ""}`,
257
257
  onClick: X,
258
258
  disabled: i === 0,
259
- children: /* @__PURE__ */ l(Xe, { size: 36 })
259
+ children: /* @__PURE__ */ c(Xe, { size: 36 })
260
260
  }
261
261
  ),
262
- /* @__PURE__ */ l(
262
+ /* @__PURE__ */ c(
263
263
  "button",
264
264
  {
265
265
  "aria-label": "Next slide",
266
- className: `${r.next} ${i >= c - 1 ? r.disabled : ""}`,
266
+ className: `${r.next} ${i >= l - 1 ? r.disabled : ""}`,
267
267
  onClick: I,
268
268
  disabled: i >= w.length - o,
269
- children: /* @__PURE__ */ l(Ae, { size: 36 })
269
+ children: /* @__PURE__ */ c(Ae, { size: 36 })
270
270
  }
271
271
  )
272
272
  ] })
package/dist/index60.css CHANGED
@@ -1 +1 @@
1
- ._item_1pa3m_1{display:flex;flex-direction:column;gap:var(--spacing-md);text-decoration:none;overflow:hidden;transition:border-color .3s ease-in-out;max-width:var(--max-item-width)}._item_1pa3m_1:hover{border-color:var(--color-primary-100)}._item_1pa3m_1:hover ._itemImage_1pa3m_14 img{transform:scale(1.05)}._item_1pa3m_1:hover ._itemTitle_1pa3m_20 h3{color:var(--color-primary-100)}._item_1pa3m_1:hover ._callToAction_1pa3m_26 ._label_1pa3m_27{opacity:1;transform:translateY(0);color:#fff}._item_1pa3m_1:hover ._callToAction_1pa3m_26 ._icon_1pa3m_33{color:var(--color-primary-100)}._item_1pa3m_1._single_1pa3m_39._first_1pa3m_40 ._itemContent_1pa3m_41{flex:.5}._item_1pa3m_1._single_1pa3m_39._first_1pa3m_40 ._itemImage_1pa3m_14{min-height:350px;flex:1}._item_1pa3m_1._twoColumn_1pa3m_52 ._itemImage_1pa3m_14{flex:.5}._item_1pa3m_1._twoColumn_1pa3m_52 ._itemContent_1pa3m_41{flex:1}._item_1pa3m_1._first_1pa3m_40._featuredTop_1pa3m_63 ._itemImage_1pa3m_14{min-height:350px;flex:1}._item_1pa3m_1._first_1pa3m_40._featuredTop_1pa3m_63 ._itemContent_1pa3m_41{flex:.5}._item_1pa3m_1._first_1pa3m_40._featuredLeft_1pa3m_74 ._itemImage_1pa3m_14{min-height:350px}._item_1pa3m_1._first_1pa3m_40._featuredLeft_1pa3m_74 ._itemContent_1pa3m_41{flex:1}._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredLeft_1pa3m_74 ._itemImage_1pa3m_14,._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredTop_1pa3m_63 ._itemImage_1pa3m_14{flex:.5;height:auto;max-height:175px}@media (max-width: 767px){._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredLeft_1pa3m_74 ._itemImage_1pa3m_14,._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredTop_1pa3m_63 ._itemImage_1pa3m_14{max-height:200px}}._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredLeft_1pa3m_74 ._itemContent_1pa3m_41,._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredTop_1pa3m_63 ._itemContent_1pa3m_41{flex:1}._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40)._featuredTop_1pa3m_63 ._itemImage_1pa3m_14{flex:1}@media (max-width: 767px){._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40){flex-direction:column}._item_1pa3m_1:not(._item_1pa3m_1._first_1pa3m_40) ._itemExcerpt_1pa3m_113{display:block}}@media (max-width: 767px){._item_1pa3m_1 ._itemImage_1pa3m_14{flex:unset!important;max-height:200px;height:200px;min-height:unset!important}._item_1pa3m_1 ._itemContent_1pa3m_41{display:flex!important}}._itemContent_1pa3m_41{display:flex;flex-direction:column;gap:var(--spacing-sm);color:var(--color-text-primary);flex:1;width:100%}._itemContent_1pa3m_41 h3{flex:1;font-size:var(--font-size-lg);margin-bottom:0;transition:color .3s ease-in-out}._itemContent_1pa3m_41 p{text-decoration:none}._itemTitle_1pa3m_20{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-lg)}._itemImage_1pa3m_14{width:100%;aspect-ratio:16 / 9;position:relative;overflow:hidden;border-radius:var(--radius-md);line-height:0}._itemImage_1pa3m_14 img{width:100%;height:100%;object-fit:cover;transition:transform .3s ease-in-out}._imagePlaceholder_1pa3m_180{flex:1;width:100%;aspect-ratio:16 / 9;position:relative;overflow:hidden;border-radius:var(--radius-md);background-color:var(--color-secondary-25)}._callToAction_1pa3m_26{position:relative;display:flex;align-items:center;justify-content:flex-end;gap:var(--spacing-sm)}._callToAction_1pa3m_26 ._icon_1pa3m_33{display:flex;align-items:center;justify-content:center;width:25px;height:25px;background-color:transparent;color:var(--color-text-primary);transition:color .3s ease-in-out,background-color .3s ease-in-out,border-color .3s ease-in-out}._callToAction_1pa3m_26 ._label_1pa3m_27{color:var(--color-primary-100);font-weight:var(--font-weight-semibold);opacity:0;transform:translateY(10px);transition:opacity .3s ease-in-out,transform .3s ease-in-out}._category_1pa3m_229{text-transform:capitalize;position:absolute;top:.75rem;left:.75rem;height:30px;display:flex;align-items:center;color:#fff;padding:var(--spacing-sm) var(--spacing-md);border-radius:var(--radius-full);z-index:2;font-size:var(--font-size-sm);background:#00000080;backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}._itemEyebrow_1pa3m_248{width:fit-content;font-size:var(--font-size-sm);text-transform:capitalize}
1
+ ._item_1vn4l_1{display:flex;flex-direction:column;gap:var(--spacing-md);text-decoration:none;overflow:hidden;transition:border-color .3s ease-in-out;max-width:var(--max-item-width)}._item_1vn4l_1:hover{border-color:var(--color-primary-100)}._item_1vn4l_1:hover ._itemImage_1vn4l_14 img{transform:scale(1.05)}._item_1vn4l_1:hover ._itemTitle_1vn4l_20 h3{color:var(--color-primary-100)}._item_1vn4l_1:hover ._callToAction_1vn4l_26 ._label_1vn4l_27{opacity:1;transform:translateY(0);color:#fff}._item_1vn4l_1:hover ._callToAction_1vn4l_26 ._icon_1vn4l_33{color:var(--color-primary-100)}._item_1vn4l_1._single_1vn4l_39._first_1vn4l_40 ._itemContent_1vn4l_41{flex:.5}._item_1vn4l_1._single_1vn4l_39._first_1vn4l_40 ._itemImage_1vn4l_14{min-height:350px;flex:1}._item_1vn4l_1._twoColumn_1vn4l_52 ._itemImage_1vn4l_14{flex:.5}._item_1vn4l_1._twoColumn_1vn4l_52 ._itemContent_1vn4l_41{flex:1}._item_1vn4l_1._first_1vn4l_40._featuredTop_1vn4l_63 ._itemImage_1vn4l_14{min-height:350px;flex:1}._item_1vn4l_1._first_1vn4l_40._featuredTop_1vn4l_63 ._itemContent_1vn4l_41{flex:.5}._item_1vn4l_1._first_1vn4l_40._featuredLeft_1vn4l_74 ._itemImage_1vn4l_14{min-height:350px}._item_1vn4l_1._first_1vn4l_40._featuredLeft_1vn4l_74 ._itemContent_1vn4l_41{flex:1}._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredLeft_1vn4l_74 ._itemImage_1vn4l_14,._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredTop_1vn4l_63 ._itemImage_1vn4l_14{flex:.5;height:auto;max-height:175px}@media (max-width: 767px){._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredLeft_1vn4l_74 ._itemImage_1vn4l_14,._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredTop_1vn4l_63 ._itemImage_1vn4l_14{max-height:200px}}._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredLeft_1vn4l_74 ._itemContent_1vn4l_41,._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredTop_1vn4l_63 ._itemContent_1vn4l_41{flex:1}._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40)._featuredTop_1vn4l_63 ._itemImage_1vn4l_14{flex:1}@media (max-width: 767px){._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40){flex-direction:column}._item_1vn4l_1:not(._item_1vn4l_1._first_1vn4l_40) ._itemExcerpt_1vn4l_113{display:block}}@media (max-width: 767px){._item_1vn4l_1 ._itemImage_1vn4l_14{flex:unset!important;max-height:200px;height:200px;min-height:unset!important}._item_1vn4l_1 ._itemContent_1vn4l_41{display:flex!important}}._itemContent_1vn4l_41{display:flex;flex-direction:column;gap:var(--spacing-sm);color:var(--color-text-primary);flex:1;width:100%}._itemContent_1vn4l_41 h3{flex:1;font-size:var(--font-size-lg);margin-bottom:0;transition:color .3s ease-in-out}._itemContent_1vn4l_41 p{text-decoration:none}._itemTitle_1vn4l_20{display:flex;align-items:flex-start;justify-content:space-between;gap:var(--spacing-lg)}._itemImage_1vn4l_14{width:100%;aspect-ratio:16 / 9;position:relative;overflow:hidden;border-radius:var(--radius-md);line-height:0}._itemImage_1vn4l_14 img{width:100%;height:100%;object-fit:cover;transition:transform .3s ease-in-out}._imagePlaceholder_1vn4l_180{flex:1;width:100%;aspect-ratio:16 / 9;position:relative;overflow:hidden;border-radius:var(--radius-md);background-color:var(--color-secondary-25)}._callToAction_1vn4l_26{position:relative;display:flex;align-items:center;justify-content:flex-end;gap:var(--spacing-sm)}._callToAction_1vn4l_26 ._icon_1vn4l_33{display:flex;align-items:center;justify-content:center;width:25px;height:25px;background-color:transparent;color:var(--color-text-primary);transition:color .3s ease-in-out,background-color .3s ease-in-out,border-color .3s ease-in-out}._callToAction_1vn4l_26 ._label_1vn4l_27{color:var(--color-primary-100);font-weight:var(--font-weight-semibold);opacity:0;transform:translateY(10px);transition:opacity .3s ease-in-out,transform .3s ease-in-out}._category_1vn4l_229{text-transform:capitalize;position:absolute;top:.75rem;left:.75rem;height:30px;display:flex;align-items:center;color:#fff;padding:var(--spacing-sm) var(--spacing-md);border-radius:var(--radius-full);z-index:2;font-size:var(--font-size-sm);background:#00000080;backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}._itemEyebrow_1vn4l_248{width:fit-content;font-size:var(--font-size-sm);text-transform:capitalize}
@@ -1,6 +1,6 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../index.css');require('../../../index60.css');const t=require("react/jsx-runtime");;/* empty css */require("react");require("../../../core/components/Avatar/index.cjs");const j=require("../../../core/components/Badge/index.cjs");require("../../../core/components/Checkbox/index.cjs");require("react-dom");require("../../../core/components/Tabs/index.cjs");require("../../../core/tokens/theme.cjs");const v=require("../../../core/context/ThemeContext.cjs"),C=require("../../../createLucideIcon-DpotSgUx.cjs");/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../index.css');require('../../../index60.css');const t=require("react/jsx-runtime");;/* empty css */require("react");require("../../../core/components/Avatar/index.cjs");const f=require("../../../core/components/Badge/index.cjs");require("../../../core/components/Checkbox/index.cjs");require("react-dom");require("../../../core/components/Tabs/index.cjs");require("../../../core/tokens/theme.cjs");const j=require("../../../core/context/ThemeContext.cjs"),C=require("../../../createLucideIcon-DpotSgUx.cjs");/**
2
2
  * @license lucide-react v0.488.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
5
5
  * See the LICENSE file in the root directory of this source tree.
6
- */const T=[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]],N=C.createLucideIcon("arrow-up-right",T),q="_item_1pa3m_1",k="_itemImage_1pa3m_14",I="_itemTitle_1pa3m_20",b="_callToAction_1pa3m_26",A="_icon_1pa3m_33",w="_single_1pa3m_39",E="_first_1pa3m_40",U="_itemContent_1pa3m_41",B="_itemExcerpt_1pa3m_113",P="_imagePlaceholder_1pa3m_180",z="_category_1pa3m_229",L="_itemEyebrow_1pa3m_248",r={item:q,itemImage:k,itemTitle:I,callToAction:b,icon:A,single:w,first:E,itemContent:U,itemExcerpt:B,imagePlaceholder:P,category:z,itemEyebrow:L};function M(e,c){var s;if(e!=null&&e.imageUrls)return c==="dark"?((s=e.imageUrls.dark)==null?void 0:s.medium)??e.imageUrls.default.medium:e.imageUrls.default.medium}function $(e,c){var a,l,n,i;const s=c==="dark"?"darkImage":"defaultImage";return((l=(a=e==null?void 0:e[s])==null?void 0:a.asset)==null?void 0:l.altText)??((i=(n=e==null?void 0:e[s])==null?void 0:n.asset)==null?void 0:i.description)??"Card image"}function F(e){var a,l;const c=((a=e.categories)==null?void 0:a.find(n=>{var i,o;return!((o=(i=n.slug)==null?void 0:i.current)!=null&&o.startsWith("library/type"))}))??null,s=((l=e.categories)==null?void 0:l.find(n=>{var i,o;return(o=(i=n.slug)==null?void 0:i.current)==null?void 0:o.startsWith("library/type")}))??null;return{mainCategory:c,typeCategory:s}}function S({href:e,className:c,children:s}){return t.jsx("a",{href:e,className:c,children:s})}function W({article:e,className:c="",index:s,layout:a,limit:l,renderImage:n,renderLink:i}){const{mode:o}=v.useTheme(),u=`/blog/articles/${e.slug.current}`,m=M(e.featuredImage,o),_=$(e.featuredImage,o),{mainCategory:p,typeCategory:g}=F(e),x=[r.item,c,s===0?r.first:"",l===1?r.single:"",a??""].filter(Boolean).join(" "),h=t.jsxs("div",{className:r.itemImage,children:[g&&t.jsx("div",{className:r.category,children:g.title}),m?n?n({src:m,alt:_,fill:!0,sizes:"(max-width: 767px) 650px, 300px",priority:!0}):t.jsx("img",{src:m,alt:_,style:{width:"100%",height:"100%",objectFit:"cover"}}):t.jsx("div",{className:r.imagePlaceholder})]}),y=t.jsxs(t.Fragment,{children:[h,t.jsxs("div",{className:r.itemContent,children:[p&&t.jsx(j.Badge,{className:r.itemEyebrow,text:p.title,variant:"muted"}),t.jsxs("div",{className:r.itemTitle,children:[t.jsx("h3",{children:e.title}),t.jsx("div",{className:r.callToAction,children:t.jsx("div",{className:r.icon,children:t.jsx(N,{size:45})})})]}),e.excerpt&&t.jsx("p",{className:r.itemExcerpt,children:e.excerpt})]})]}),f=i?({children:d})=>i({href:u,className:x,children:d}):({children:d})=>t.jsx(S,{href:u,className:x,children:d});return t.jsx(f,{children:y})}exports.BlogArticleCard=W;
6
+ */const T=[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]],N=C.createLucideIcon("arrow-up-right",T),q="_item_1vn4l_1",k="_itemImage_1vn4l_14",I="_itemTitle_1vn4l_20",b="_callToAction_1vn4l_26",A="_icon_1vn4l_33",w="_single_1vn4l_39",E="_first_1vn4l_40",U="_itemContent_1vn4l_41",B="_itemExcerpt_1vn4l_113",P="_imagePlaceholder_1vn4l_180",z="_category_1vn4l_229",L="_itemEyebrow_1vn4l_248",r={item:q,itemImage:k,itemTitle:I,callToAction:b,icon:A,single:w,first:E,itemContent:U,itemExcerpt:B,imagePlaceholder:P,category:z,itemEyebrow:L};function M(e,i){var n;if(e!=null&&e.imageUrls)return i==="dark"?((n=e.imageUrls.dark)==null?void 0:n.medium)??e.imageUrls.default.medium:e.imageUrls.default.medium}function $(e,i){var l,a,c,s;const n=i==="dark"?"darkImage":"defaultImage";return((a=(l=e==null?void 0:e[n])==null?void 0:l.asset)==null?void 0:a.altText)??((s=(c=e==null?void 0:e[n])==null?void 0:c.asset)==null?void 0:s.description)??"Card image"}function F(e){var l,a;const i=((l=e.categories)==null?void 0:l.find(c=>{var s,o;return!((o=(s=c.slug)==null?void 0:s.current)!=null&&o.startsWith("library/type"))}))??null,n=((a=e.categories)==null?void 0:a.find(c=>{var s,o;return(o=(s=c.slug)==null?void 0:s.current)==null?void 0:o.startsWith("library/type")}))??null;return{mainCategory:i,typeCategory:n}}function S({href:e,className:i,children:n}){return t.jsx("a",{href:e,className:i,children:n})}function W({article:e,className:i="",index:n,layout:l,limit:a,renderImage:c,renderLink:s}){const{mode:o}=j.useTheme(),u=`/blog/articles/${e.slug.current}`,m=M(e.featuredImage,o),_=$(e.featuredImage,o),{mainCategory:g,typeCategory:x}=F(e),v=[r.item,i,n===0?r.first:"",a===1?r.single:"",l??""].filter(Boolean).join(" "),h=t.jsxs("div",{className:r.itemImage,children:[x&&t.jsx("div",{className:r.category,children:x.title}),m?c?c({src:m,alt:_,fill:!0,sizes:"(max-width: 767px) 650px, 300px",priority:!0}):t.jsx("img",{src:m,alt:_,style:{width:"100%",height:"100%",objectFit:"cover"}}):t.jsx("div",{className:r.imagePlaceholder})]}),y=t.jsxs(t.Fragment,{children:[h,t.jsxs("div",{className:r.itemContent,children:[g&&t.jsx(f.Badge,{className:r.itemEyebrow,text:g.title,variant:"muted"}),t.jsxs("div",{className:r.itemTitle,children:[t.jsx("h3",{children:e.title}),t.jsx("div",{className:r.callToAction,children:t.jsx("div",{className:r.icon,children:t.jsx(N,{size:45})})})]}),e.excerpt&&t.jsx("p",{className:r.itemExcerpt,children:e.excerpt})]})]}),p=s?({children:d})=>s({href:u,className:v,children:d}):({children:d})=>t.jsx(S,{href:u,className:v,children:d});return t.jsx(p,{children:y})}exports.BlogArticleCard=W;
@@ -1,4 +1,4 @@
1
- import { jsxs as l, jsx as i, Fragment as x } from "react/jsx-runtime";
1
+ import { jsxs as m, jsx as i, Fragment as x } from "react/jsx-runtime";
2
2
  import '../../../index.css';import '../../../index60.css';/* empty css */
3
3
  import "react";
4
4
  import "../../../core/components/Avatar/index.mjs";
@@ -18,7 +18,7 @@ import { c as k } from "../../../createLucideIcon-C8GTh_Qx.js";
18
18
  const T = [
19
19
  ["path", { d: "M7 7h10v10", key: "1tivn9" }],
20
20
  ["path", { d: "M7 17 17 7", key: "1vkiza" }]
21
- ], I = k("arrow-up-right", T), b = "_item_1pa3m_1", w = "_itemImage_1pa3m_14", A = "_itemTitle_1pa3m_20", E = "_callToAction_1pa3m_26", U = "_icon_1pa3m_33", j = "_single_1pa3m_39", B = "_first_1pa3m_40", P = "_itemContent_1pa3m_41", z = "_itemExcerpt_1pa3m_113", L = "_imagePlaceholder_1pa3m_180", F = "_category_1pa3m_229", M = "_itemEyebrow_1pa3m_248", e = {
21
+ ], I = k("arrow-up-right", T), b = "_item_1vn4l_1", w = "_itemImage_1vn4l_14", A = "_itemTitle_1vn4l_20", E = "_callToAction_1vn4l_26", U = "_icon_1vn4l_33", j = "_single_1vn4l_39", B = "_first_1vn4l_40", P = "_itemContent_1vn4l_41", z = "_itemExcerpt_1vn4l_113", L = "_imagePlaceholder_1vn4l_180", F = "_category_1vn4l_229", M = "_itemEyebrow_1vn4l_248", e = {
22
22
  item: b,
23
23
  itemImage: w,
24
24
  itemTitle: A,
@@ -32,55 +32,55 @@ const T = [
32
32
  category: F,
33
33
  itemEyebrow: M
34
34
  };
35
- function W(t, n) {
36
- var o;
35
+ function W(t, r) {
36
+ var n;
37
37
  if (t != null && t.imageUrls)
38
- return n === "dark" ? ((o = t.imageUrls.dark) == null ? void 0 : o.medium) ?? t.imageUrls.default.medium : t.imageUrls.default.medium;
38
+ return r === "dark" ? ((n = t.imageUrls.dark) == null ? void 0 : n.medium) ?? t.imageUrls.default.medium : t.imageUrls.default.medium;
39
39
  }
40
- function D(t, n) {
41
- var a, m, s, r;
42
- const o = n === "dark" ? "darkImage" : "defaultImage";
43
- return ((m = (a = t == null ? void 0 : t[o]) == null ? void 0 : a.asset) == null ? void 0 : m.altText) ?? ((r = (s = t == null ? void 0 : t[o]) == null ? void 0 : s.asset) == null ? void 0 : r.description) ?? "Card image";
40
+ function D(t, r) {
41
+ var l, a, s, o;
42
+ const n = r === "dark" ? "darkImage" : "defaultImage";
43
+ return ((a = (l = t == null ? void 0 : t[n]) == null ? void 0 : l.asset) == null ? void 0 : a.altText) ?? ((o = (s = t == null ? void 0 : t[n]) == null ? void 0 : s.asset) == null ? void 0 : o.description) ?? "Card image";
44
44
  }
45
45
  function R(t) {
46
- var a, m;
47
- const n = ((a = t.categories) == null ? void 0 : a.find(
46
+ var l, a;
47
+ const r = ((l = t.categories) == null ? void 0 : l.find(
48
48
  (s) => {
49
- var r, c;
50
- return !((c = (r = s.slug) == null ? void 0 : r.current) != null && c.startsWith("library/type"));
49
+ var o, c;
50
+ return !((c = (o = s.slug) == null ? void 0 : o.current) != null && c.startsWith("library/type"));
51
51
  }
52
- )) ?? null, o = ((m = t.categories) == null ? void 0 : m.find(
52
+ )) ?? null, n = ((a = t.categories) == null ? void 0 : a.find(
53
53
  (s) => {
54
- var r, c;
55
- return (c = (r = s.slug) == null ? void 0 : r.current) == null ? void 0 : c.startsWith("library/type");
54
+ var o, c;
55
+ return (c = (o = s.slug) == null ? void 0 : o.current) == null ? void 0 : c.startsWith("library/type");
56
56
  }
57
57
  )) ?? null;
58
- return { mainCategory: n, typeCategory: o };
58
+ return { mainCategory: r, typeCategory: n };
59
59
  }
60
60
  function $({
61
61
  href: t,
62
- className: n,
63
- children: o
62
+ className: r,
63
+ children: n
64
64
  }) {
65
- return /* @__PURE__ */ i("a", { href: t, className: n, children: o });
65
+ return /* @__PURE__ */ i("a", { href: t, className: r, children: n });
66
66
  }
67
67
  function tt({
68
68
  article: t,
69
- className: n = "",
70
- index: o,
71
- layout: a,
72
- limit: m,
69
+ className: r = "",
70
+ index: n,
71
+ layout: l,
72
+ limit: a,
73
73
  renderImage: s,
74
- renderLink: r
74
+ renderLink: o
75
75
  }) {
76
- const { mode: c } = N(), _ = `/blog/articles/${t.slug.current}`, d = W(t.featuredImage, c), u = D(t.featuredImage, c), { mainCategory: g, typeCategory: h } = R(t), f = [
76
+ const { mode: c } = N(), p = `/blog/articles/${t.slug.current}`, d = W(t.featuredImage, c), u = D(t.featuredImage, c), { mainCategory: v, typeCategory: g } = R(t), h = [
77
77
  e.item,
78
- n,
79
- o === 0 ? e.first : "",
80
- m === 1 ? e.single : "",
81
- a ?? ""
82
- ].filter(Boolean).join(" "), y = /* @__PURE__ */ l("div", { className: e.itemImage, children: [
83
- h && /* @__PURE__ */ i("div", { className: e.category, children: h.title }),
78
+ r,
79
+ n === 0 ? e.first : "",
80
+ a === 1 ? e.single : "",
81
+ l ?? ""
82
+ ].filter(Boolean).join(" "), f = /* @__PURE__ */ m("div", { className: e.itemImage, children: [
83
+ g && /* @__PURE__ */ i("div", { className: e.category, children: g.title }),
84
84
  d ? s ? s({
85
85
  src: d,
86
86
  alt: u,
@@ -95,25 +95,25 @@ function tt({
95
95
  style: { width: "100%", height: "100%", objectFit: "cover" }
96
96
  }
97
97
  ) : /* @__PURE__ */ i("div", { className: e.imagePlaceholder })
98
- ] }), v = /* @__PURE__ */ l(x, { children: [
99
- y,
100
- /* @__PURE__ */ l("div", { className: e.itemContent, children: [
101
- g && /* @__PURE__ */ i(
98
+ ] }), y = /* @__PURE__ */ m(x, { children: [
99
+ f,
100
+ /* @__PURE__ */ m("div", { className: e.itemContent, children: [
101
+ v && /* @__PURE__ */ i(
102
102
  C,
103
103
  {
104
104
  className: e.itemEyebrow,
105
- text: g.title,
105
+ text: v.title,
106
106
  variant: "muted"
107
107
  }
108
108
  ),
109
- /* @__PURE__ */ l("div", { className: e.itemTitle, children: [
109
+ /* @__PURE__ */ m("div", { className: e.itemTitle, children: [
110
110
  /* @__PURE__ */ i("h3", { children: t.title }),
111
111
  /* @__PURE__ */ i("div", { className: e.callToAction, children: /* @__PURE__ */ i("div", { className: e.icon, children: /* @__PURE__ */ i(I, { size: 45 }) }) })
112
112
  ] }),
113
113
  t.excerpt && /* @__PURE__ */ i("p", { className: e.itemExcerpt, children: t.excerpt })
114
114
  ] })
115
115
  ] });
116
- return /* @__PURE__ */ i(r ? ({ children: p }) => r({ href: _, className: f, children: p }) : ({ children: p }) => /* @__PURE__ */ i($, { href: _, className: f, children: p }), { children: v });
116
+ return /* @__PURE__ */ i(o ? ({ children: _ }) => o({ href: p, className: h, children: _ }) : ({ children: _ }) => /* @__PURE__ */ i($, { href: p, className: h, children: _ }), { children: y });
117
117
  }
118
118
  export {
119
119
  tt as BlogArticleCard
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "quirk-ui",
3
3
  "private": false,
4
- "version": "0.1.37",
4
+ "version": "0.1.38",
5
5
  "type": "module",
6
6
  "exports": {
7
7
  ".": {