@zenpatient-org/healthspan-marketing-ui 0.1.157 → 0.1.158

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,50 +1,60 @@
1
1
  "use client";
2
- import { jsxs as i, jsx as r } from "react/jsx-runtime";
3
- import { Icon as c } from "../../../../components/Icon/Icon.es.js";
2
+ import { jsxs as r, jsx as a } from "react/jsx-runtime";
3
+ import { Icon as n } from "../../../../components/Icon/Icon.es.js";
4
4
  import { EIconName as l } from "../../../../components/Icon/constants.es.js";
5
5
  import { RadioButton as m } from "../../../../components/RadioButton/RadioButton.es.js";
6
6
  import { Typography as t } from "../../../../components/Typography/Typography.es.js";
7
7
  import { Label as h } from "../../../../components/Label/Label.es.js";
8
- import { cn as o } from "../../../../utils/cn/cn.es.js";
9
- import { formatUnits as n } from "../../../../utils/formatUnits/formatUnits.es.js";
10
- import e from "./planCard.module.css.es.js";
11
- const C = ({ plan: a, isActive: s, onSelect: d }) => /* @__PURE__ */ i("button", { className: o(e.root, s && e.active), onClick: () => d(a.id), children: [
12
- a.featured && /* @__PURE__ */ r(h, { color: "black", className: e.label, size: "sm", children: "Most popular" }),
13
- /* @__PURE__ */ i("div", { className: e.planContainer, children: [
14
- /* @__PURE__ */ i("div", { className: e.planInfo, children: [
15
- /* @__PURE__ */ r(m, { checked: s }),
16
- /* @__PURE__ */ i("div", { className: e.planDetails, children: [
17
- /* @__PURE__ */ r(t, { as: "h4", defaultVariant: "bodySm", emphasis: !0, align: "left", children: a.label }),
18
- !!a.savingsPercentage && /* @__PURE__ */ i(t, { as: "p", defaultVariant: "labelXs", weight: "regular", className: e.description, children: [
8
+ import { cn as s } from "../../../../utils/cn/cn.es.js";
9
+ import { formatUnits as c } from "../../../../utils/formatUnits/formatUnits.es.js";
10
+ import i from "./planCard.module.css.es.js";
11
+ const C = ({ plan: e, isActive: o, onSelect: d }) => /* @__PURE__ */ r("button", { className: s(i.root, o && i.active), onClick: () => d(e.id), children: [
12
+ e.featured && /* @__PURE__ */ a(h, { color: "black", className: i.label, size: "sm", children: "Most popular" }),
13
+ /* @__PURE__ */ r("div", { className: i.planContainer, children: [
14
+ /* @__PURE__ */ r("div", { className: i.planInfo, children: [
15
+ /* @__PURE__ */ a(m, { checked: o }),
16
+ /* @__PURE__ */ r("div", { className: i.planDetails, children: [
17
+ /* @__PURE__ */ a(t, { as: "h4", defaultVariant: "bodySm", emphasis: !0, align: "left", children: e.label }),
18
+ !!e.savingsPercentage && /* @__PURE__ */ r(t, { as: "p", defaultVariant: "labelXs", weight: "regular", className: i.savings, children: [
19
19
  "Save ",
20
- a.savingsPercentage,
20
+ e.savingsPercentage,
21
21
  "%"
22
22
  ] })
23
23
  ] })
24
24
  ] }),
25
- /* @__PURE__ */ i("div", { className: e.priceDetails, children: [
26
- /* @__PURE__ */ i("div", { className: o(e.priceContainer), children: [
27
- a.price !== a.totalPrice && /* @__PURE__ */ r(t, { as: "p", defaultVariant: "bodySm", weight: "regular", className: e.totalPrice, children: n(a.price, "usd", 0) }),
28
- /* @__PURE__ */ r(t, { as: "p", defaultVariant: "bodySm", emphasis: !0, className: e.price, children: n(a.totalPrice, "usd", 0) })
29
- ] }),
30
- !!a.monthlyPrice && /* @__PURE__ */ i(t, { as: "p", defaultVariant: "labelXs", weight: "regular", className: e.description, children: [
31
- n(a.monthlyPrice, "usd", 0),
25
+ /* @__PURE__ */ r("div", { className: i.priceDetails, children: [
26
+ !!e.monthlyPrice && /* @__PURE__ */ r(t, { as: "p", defaultVariant: "bodySm", weight: "regular", className: i.description, children: [
27
+ c(e.monthlyPrice, "usd", 0),
32
28
  "/mo"
29
+ ] }),
30
+ /* @__PURE__ */ r("div", { className: s(i.priceContainer), children: [
31
+ e.price !== e.totalPrice && /* @__PURE__ */ a(t, { as: "p", defaultVariant: "labelXs", weight: "regular", className: i.totalPrice, children: c(e.price, "usd", 0) }),
32
+ /* @__PURE__ */ a(
33
+ t,
34
+ {
35
+ as: "p",
36
+ defaultVariant: !e.monthlyPrice && e.price === e.totalPrice ? "bodySm" : "labelXs",
37
+ className: s(i.price, {
38
+ [i.description]: !e.monthlyPrice && e.price === e.totalPrice
39
+ }),
40
+ children: c(e.totalPrice, "usd", 0)
41
+ }
42
+ )
33
43
  ] })
34
44
  ] })
35
45
  ] }),
36
- !!a.duration && a.duration !== "one-time" && /* @__PURE__ */ r("div", { className: o(e.benefitsContainer, s && e.benefitsActive), children: /* @__PURE__ */ i("div", { className: e.benefitsContent, children: [
37
- /* @__PURE__ */ i("div", { className: e.benefit, children: [
38
- /* @__PURE__ */ r(c, { name: l.ARROW_RETURN, className: e.benefitIcon }),
39
- /* @__PURE__ */ i(t, { as: "p", defaultVariant: "bodyXs", children: [
46
+ !!e.duration && e.duration !== "one-time" && /* @__PURE__ */ a("div", { className: s(i.benefitsContainer, o && i.benefitsActive), children: /* @__PURE__ */ r("div", { className: i.benefitsContent, children: [
47
+ /* @__PURE__ */ r("div", { className: i.benefit, children: [
48
+ /* @__PURE__ */ a(n, { name: l.ARROW_RETURN, className: i.benefitIcon }),
49
+ /* @__PURE__ */ r(t, { as: "p", defaultVariant: "bodyXs", children: [
40
50
  "Delivered every",
41
51
  " ",
42
- a.durationAmount && a.durationAmount > 1 ? `${a.durationAmount} months` : "month"
52
+ e.durationAmount && e.durationAmount > 1 ? `${e.durationAmount} months` : "month"
43
53
  ] })
44
54
  ] }),
45
- /* @__PURE__ */ i("div", { className: e.benefit, children: [
46
- /* @__PURE__ */ r(c, { name: l.CALENDAR, className: e.benefitIcon }),
47
- /* @__PURE__ */ r(t, { as: "p", defaultVariant: "bodyXs", children: "Modify or cancel anytime" })
55
+ /* @__PURE__ */ r("div", { className: i.benefit, children: [
56
+ /* @__PURE__ */ a(n, { name: l.CALENDAR, className: i.benefitIcon }),
57
+ /* @__PURE__ */ a(t, { as: "p", defaultVariant: "bodyXs", children: "Modify or cancel anytime" })
48
58
  ] })
49
59
  ] }) })
50
60
  ] });
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="planCard-module__root___zp7Tv",n="planCard-module__active___Jfcov",t="planCard-module__label___QCNmN",a="planCard-module__planContainer___11Plm",o="planCard-module__planInfo___WnxmB",_="planCard-module__planDetails___3SReq",i="planCard-module__priceDetails___76mLM",l="planCard-module__priceContainer___RLU3v",r="planCard-module__description___aIuab",c="planCard-module__totalPrice___KJB6P",s="planCard-module__benefitsContainer___YkMqx",p="planCard-module__benefitsActive___yxSvM",d="planCard-module__benefitsContent___PEjLg",C="planCard-module__benefit___L4KF1",b="planCard-module__benefitIcon___IVAlB",f={root:e,active:n,label:t,planContainer:a,planInfo:o,planDetails:_,priceDetails:i,priceContainer:l,description:r,totalPrice:c,benefitsContainer:s,benefitsActive:p,benefitsContent:d,benefit:C,benefitIcon:b};exports.active=n;exports.benefit=C;exports.benefitIcon=b;exports.benefitsActive=p;exports.benefitsContainer=s;exports.benefitsContent=d;exports.default=f;exports.description=r;exports.label=t;exports.planContainer=a;exports.planDetails=_;exports.planInfo=o;exports.priceContainer=l;exports.priceDetails=i;exports.root=e;exports.totalPrice=c;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="planCard-module__root___zp7Tv",n="planCard-module__active___Jfcov",t="planCard-module__label___QCNmN",a="planCard-module__planContainer___11Plm",_="planCard-module__planInfo___WnxmB",o="planCard-module__planDetails___3SReq",i="planCard-module__priceDetails___76mLM",l="planCard-module__priceContainer___RLU3v",r="planCard-module__savings___6EX3u",s="planCard-module__price___oJOrP",c="planCard-module__description___aIuab",p="planCard-module__totalPrice___KJB6P",d="planCard-module__benefitsContainer___YkMqx",C="planCard-module__benefitsActive___yxSvM",b="planCard-module__benefitsContent___PEjLg",f="planCard-module__benefit___L4KF1",u="planCard-module__benefitIcon___IVAlB",m={root:e,active:n,label:t,planContainer:a,planInfo:_,planDetails:o,priceDetails:i,priceContainer:l,savings:r,price:s,description:c,totalPrice:p,benefitsContainer:d,benefitsActive:C,benefitsContent:b,benefit:f,benefitIcon:u};exports.active=n;exports.benefit=f;exports.benefitIcon=u;exports.benefitsActive=C;exports.benefitsContainer=d;exports.benefitsContent=b;exports.default=m;exports.description=c;exports.label=t;exports.planContainer=a;exports.planDetails=o;exports.planInfo=_;exports.price=s;exports.priceContainer=l;exports.priceDetails=i;exports.root=e;exports.savings=r;exports.totalPrice=p;
@@ -1,4 +1,4 @@
1
- const n = "planCard-module__root___zp7Tv", e = "planCard-module__active___Jfcov", _ = "planCard-module__label___QCNmN", t = "planCard-module__planContainer___11Plm", a = "planCard-module__planInfo___WnxmB", o = "planCard-module__planDetails___3SReq", l = "planCard-module__priceDetails___76mLM", i = "planCard-module__priceContainer___RLU3v", r = "planCard-module__description___aIuab", c = "planCard-module__totalPrice___KJB6P", s = "planCard-module__benefitsContainer___YkMqx", p = "planCard-module__benefitsActive___yxSvM", d = "planCard-module__benefitsContent___PEjLg", C = "planCard-module__benefit___L4KF1", f = "planCard-module__benefitIcon___IVAlB", b = {
1
+ const n = "planCard-module__root___zp7Tv", e = "planCard-module__active___Jfcov", _ = "planCard-module__label___QCNmN", t = "planCard-module__planContainer___11Plm", a = "planCard-module__planInfo___WnxmB", o = "planCard-module__planDetails___3SReq", l = "planCard-module__priceDetails___76mLM", i = "planCard-module__priceContainer___RLU3v", r = "planCard-module__savings___6EX3u", s = "planCard-module__price___oJOrP", c = "planCard-module__description___aIuab", p = "planCard-module__totalPrice___KJB6P", d = "planCard-module__benefitsContainer___YkMqx", C = "planCard-module__benefitsActive___yxSvM", m = "planCard-module__benefitsContent___PEjLg", f = "planCard-module__benefit___L4KF1", u = "planCard-module__benefitIcon___IVAlB", b = {
2
2
  root: n,
3
3
  active: e,
4
4
  label: _,
@@ -7,29 +7,33 @@ const n = "planCard-module__root___zp7Tv", e = "planCard-module__active___Jfcov"
7
7
  planDetails: o,
8
8
  priceDetails: l,
9
9
  priceContainer: i,
10
- description: r,
11
- totalPrice: c,
12
- benefitsContainer: s,
13
- benefitsActive: p,
14
- benefitsContent: d,
15
- benefit: C,
16
- benefitIcon: f
10
+ savings: r,
11
+ price: s,
12
+ description: c,
13
+ totalPrice: p,
14
+ benefitsContainer: d,
15
+ benefitsActive: C,
16
+ benefitsContent: m,
17
+ benefit: f,
18
+ benefitIcon: u
17
19
  };
18
20
  export {
19
21
  e as active,
20
- C as benefit,
21
- f as benefitIcon,
22
- p as benefitsActive,
23
- s as benefitsContainer,
24
- d as benefitsContent,
22
+ f as benefit,
23
+ u as benefitIcon,
24
+ C as benefitsActive,
25
+ d as benefitsContainer,
26
+ m as benefitsContent,
25
27
  b as default,
26
- r as description,
28
+ c as description,
27
29
  _ as label,
28
30
  t as planContainer,
29
31
  o as planDetails,
30
32
  a as planInfo,
33
+ s as price,
31
34
  i as priceContainer,
32
35
  l as priceDetails,
33
36
  n as root,
34
- c as totalPrice
37
+ r as savings,
38
+ p as totalPrice
35
39
  };
@@ -1 +1 @@
1
- "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),f=require("react"),y=require("../../node_modules/gsap/index.cjs.js"),p=require("../../node_modules/gsap/Flip.cjs.js"),N=require("../../node_modules/@gsap/react/src/index.cjs.js"),R=require("../../pageComponents/Bubbles/Bubbles.cjs.js"),q=require("../../pageComponents/Gradient/Gradient.cjs.js"),b=require("../../components/HighlightedTitle/HighlightedTitle.cjs.js"),C=require("../../utils/cn/cn.cjs.js"),x=require("../../components/Typography/Typography.cjs.js"),_=require("../../components/Icon/Icon.cjs.js"),t=require("./SlidingTabsGallery.module.css.cjs.js");y.gsap.registerPlugin(p.Flip);const S=({title:j,tabs:o,withBubbles:m})=>{const s=f.useRef(null),a=f.useRef(null),[l,h]=f.useState(o[0]);N.useGSAP(()=>{const i=s.current,n=a.current,u=r=>{if(i&&n&&r){const T=n.getBoundingClientRect(),g=r.getBoundingClientRect();y.gsap.set(i,{left:g.left-T.left,top:g.top-T.top,width:g.width,height:g.height})}};if(n&&n.children.length>1){const r=n.children[1];r&&u(r)}let c;const d=()=>{clearTimeout(c),c=setTimeout(()=>{if(i&&n&&n.children.length>1&&o.length>0){const r=n.children[1];r&&(u(r),h(o[0]))}},250)};return window.addEventListener("resize",d),()=>{clearTimeout(c),window.removeEventListener("resize",d)}},{dependencies:[o,h],scope:a});const v=(i,n)=>{if(i===l)return;const u=p.Flip.getState(s.current);if(h(i),s.current&&a.current&&a.current.children.length>n+1){const c=a.current.children[n+1];if(c){const d=a.current.getBoundingClientRect(),r=c.getBoundingClientRect();s.current.style.left=`${r.left-d.left}px`,s.current.style.top=`${r.top-d.top}px`,s.current.style.width=`${r.width}px`,s.current.style.height=`${r.height}px`}}p.Flip.from(u,{targets:s.current,duration:.3,ease:"power1.inOut"})};return e.jsxs("section",{className:t.default.root,children:[m&&e.jsx(R.Bubbles,{className:t.default.bubbles}),e.jsxs("div",{className:t.default.container,children:[e.jsx(b.HighlightedTitle,{as:"div",title:j,className:t.default.header,colorScheme:"dark"}),e.jsxs("div",{className:t.default.content,children:[l.image&&e.jsx("div",{className:t.default.imageWrap,children:e.jsx("img",{src:l.image,alt:"Total Care",className:t.default.image})}),e.jsx("div",{className:t.default.tabsContainer,children:e.jsxs("div",{ref:a,className:t.default.tabs,children:[e.jsx("div",{ref:s,id:"marker",className:t.default.marker}),o.map((i,n)=>e.jsxs("button",{className:C.cn(t.default.tab,{[t.default.active]:l===i}),onClick:()=>v(i,n),children:[i.icon&&e.jsx(x.Typography,{defaultVariant:"displayMd",className:t.default.icon,children:e.jsx(_.Icon,{name:i.icon})}),e.jsx(x.Typography,{defaultVariant:"displayMd",className:t.default.hideMobile,children:i.label})]},i.label))]})}),l.description&&e.jsx("div",{className:t.default.description,children:e.jsx(b.HighlightedTitle,{as:"div",defaultVariant:"bodyXl",mobileVariant:"bodyMd",className:t.default.descriptionText,title:l.description,colorScheme:"dark"})})]})]}),m&&e.jsx(q.Gradient,{variant:"blue"})]})};exports.SlidingTabsGallery=S;
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),g=require("react"),x=require("../../node_modules/gsap/index.cjs.js"),h=require("../../node_modules/gsap/Flip.cjs.js"),j=require("../../node_modules/@gsap/react/src/index.cjs.js"),N=require("../../pageComponents/Bubbles/Bubbles.cjs.js"),v=require("../../pageComponents/Gradient/Gradient.cjs.js"),m=require("../../components/HighlightedTitle/HighlightedTitle.cjs.js"),q=require("../../utils/cn/cn.cjs.js"),b=require("../../components/Typography/Typography.cjs.js"),C=require("../../components/Icon/Icon.cjs.js"),t=require("./SlidingTabsGallery.module.css.cjs.js");x.gsap.registerPlugin(h.Flip);const R=({title:y,tabs:d,withBubbles:p})=>{const r=g.useRef(null),l=g.useRef(null),[c,f]=g.useState(d[0]);j.useGSAP(()=>{const i=r.current,n=l.current,u=a=>{if(i&&n&&a){const o=n.getBoundingClientRect(),s=a.getBoundingClientRect();x.gsap.set(i,{left:s.left-o.left,top:s.top-o.top,width:s.width,height:s.height})}};if(n&&n.children.length>1){const a=n.children[1];a&&u(a)}},{dependencies:[d,f],scope:l});const T=(i,n)=>{if(i===c)return;const u=h.Flip.getState(r.current);if(f(i),r.current&&l.current&&l.current.children.length>n+1){const a=l.current.children[n+1];if(a){const o=l.current.getBoundingClientRect(),s=a.getBoundingClientRect();r.current.style.left=`${s.left-o.left}px`,r.current.style.top=`${s.top-o.top}px`,r.current.style.width=`${s.width}px`,r.current.style.height=`${s.height}px`}}h.Flip.from(u,{targets:r.current,duration:.3,ease:"power1.inOut"})};return e.jsxs("section",{className:t.default.root,children:[p&&e.jsx(N.Bubbles,{className:t.default.bubbles}),e.jsxs("div",{className:t.default.container,children:[e.jsx(m.HighlightedTitle,{as:"div",title:y,className:t.default.header,colorScheme:"dark"}),e.jsxs("div",{className:t.default.content,children:[c.image&&e.jsx("div",{className:t.default.imageWrap,children:e.jsx("img",{src:c.image,alt:"Total Care",className:t.default.image})}),e.jsx("div",{className:t.default.tabsContainer,children:e.jsxs("div",{ref:l,className:t.default.tabs,children:[e.jsx("div",{ref:r,id:"marker",className:t.default.marker}),d.map((i,n)=>e.jsxs("button",{className:q.cn(t.default.tab,{[t.default.active]:c===i}),onClick:()=>T(i,n),children:[i.icon&&e.jsx(b.Typography,{defaultVariant:"displayMd",className:t.default.icon,children:e.jsx(C.Icon,{name:i.icon})}),e.jsx(b.Typography,{defaultVariant:"displayMd",className:t.default.hideMobile,children:i.label})]},i.label))]})}),c.description&&e.jsx("div",{className:t.default.description,children:e.jsx(m.HighlightedTitle,{as:"div",defaultVariant:"bodyXl",mobileVariant:"bodyMd",className:t.default.descriptionText,title:c.description,colorScheme:"dark"})})]})]}),p&&e.jsx(v.Gradient,{variant:"blue"})]})};exports.SlidingTabsGallery=R;
@@ -1,106 +1,94 @@
1
1
  "use client";
2
- import { jsxs as m, jsx as n } from "react/jsx-runtime";
3
- import { useRef as T, useState as k } from "react";
4
- import { gsap as y } from "../../node_modules/gsap/index.es.js";
5
- import { Flip as f } from "../../node_modules/gsap/Flip.es.js";
6
- import { useGSAP as w } from "../../node_modules/@gsap/react/src/index.es.js";
7
- import { Bubbles as S } from "../../pageComponents/Bubbles/Bubbles.es.js";
8
- import { Gradient as x } from "../../pageComponents/Gradient/Gradient.es.js";
2
+ import { jsxs as d, jsx as r } from "react/jsx-runtime";
3
+ import { useRef as g, useState as R } from "react";
4
+ import { gsap as v } from "../../node_modules/gsap/index.es.js";
5
+ import { Flip as u } from "../../node_modules/gsap/Flip.es.js";
6
+ import { useGSAP as T } from "../../node_modules/@gsap/react/src/index.es.js";
7
+ import { Bubbles as k } from "../../pageComponents/Bubbles/Bubbles.es.js";
8
+ import { Gradient as S } from "../../pageComponents/Gradient/Gradient.es.js";
9
9
  import { HighlightedTitle as b } from "../../components/HighlightedTitle/HighlightedTitle.es.js";
10
- import { cn as B } from "../../utils/cn/cn.es.js";
10
+ import { cn as x } from "../../utils/cn/cn.es.js";
11
11
  import { Typography as N } from "../../components/Typography/Typography.es.js";
12
- import { Icon as M } from "../../components/Icon/Icon.es.js";
12
+ import { Icon as B } from "../../components/Icon/Icon.es.js";
13
13
  import e from "./SlidingTabsGallery.module.css.es.js";
14
- y.registerPlugin(f);
15
- const I = ({ title: C, tabs: l, withBubbles: g }) => {
16
- const o = T(null), a = T(null), [c, p] = k(l[0]);
17
- w(
14
+ v.registerPlugin(u);
15
+ const O = ({ title: y, tabs: m, withBubbles: h }) => {
16
+ const n = g(null), o = g(null), [s, f] = R(m[0]);
17
+ T(
18
18
  () => {
19
- const t = o.current, r = a.current, u = (i) => {
20
- if (t && r && i) {
21
- const v = r.getBoundingClientRect(), h = i.getBoundingClientRect();
22
- y.set(t, {
23
- left: h.left - v.left,
24
- top: h.top - v.top,
25
- width: h.width,
26
- height: h.height
19
+ const t = n.current, i = o.current, p = (c) => {
20
+ if (t && i && c) {
21
+ const l = i.getBoundingClientRect(), a = c.getBoundingClientRect();
22
+ v.set(t, {
23
+ left: a.left - l.left,
24
+ top: a.top - l.top,
25
+ width: a.width,
26
+ height: a.height
27
27
  });
28
28
  }
29
29
  };
30
- if (r && r.children.length > 1) {
31
- const i = r.children[1];
32
- i && u(i);
30
+ if (i && i.children.length > 1) {
31
+ const c = i.children[1];
32
+ c && p(c);
33
33
  }
34
- let s;
35
- const d = () => {
36
- clearTimeout(s), s = setTimeout(() => {
37
- if (t && r && r.children.length > 1 && l.length > 0) {
38
- const i = r.children[1];
39
- i && (u(i), p(l[0]));
40
- }
41
- }, 250);
42
- };
43
- return window.addEventListener("resize", d), () => {
44
- clearTimeout(s), window.removeEventListener("resize", d);
45
- };
46
34
  },
47
- { dependencies: [l, p], scope: a }
35
+ { dependencies: [m, f], scope: o }
48
36
  );
49
- const R = (t, r) => {
50
- if (t === c) return;
51
- const u = f.getState(o.current);
52
- if (p(t), o.current && a.current && a.current.children.length > r + 1) {
53
- const s = a.current.children[r + 1];
54
- if (s) {
55
- const d = a.current.getBoundingClientRect(), i = s.getBoundingClientRect();
56
- o.current.style.left = `${i.left - d.left}px`, o.current.style.top = `${i.top - d.top}px`, o.current.style.width = `${i.width}px`, o.current.style.height = `${i.height}px`;
37
+ const C = (t, i) => {
38
+ if (t === s) return;
39
+ const p = u.getState(n.current);
40
+ if (f(t), n.current && o.current && o.current.children.length > i + 1) {
41
+ const c = o.current.children[i + 1];
42
+ if (c) {
43
+ const l = o.current.getBoundingClientRect(), a = c.getBoundingClientRect();
44
+ n.current.style.left = `${a.left - l.left}px`, n.current.style.top = `${a.top - l.top}px`, n.current.style.width = `${a.width}px`, n.current.style.height = `${a.height}px`;
57
45
  }
58
46
  }
59
- f.from(u, {
60
- targets: o.current,
47
+ u.from(p, {
48
+ targets: n.current,
61
49
  duration: 0.3,
62
50
  ease: "power1.inOut"
63
51
  });
64
52
  };
65
- return /* @__PURE__ */ m("section", { className: e.root, children: [
66
- g && /* @__PURE__ */ n(S, { className: e.bubbles }),
67
- /* @__PURE__ */ m("div", { className: e.container, children: [
68
- /* @__PURE__ */ n(b, { as: "div", title: C, className: e.header, colorScheme: "dark" }),
69
- /* @__PURE__ */ m("div", { className: e.content, children: [
70
- c.image && /* @__PURE__ */ n("div", { className: e.imageWrap, children: /* @__PURE__ */ n("img", { src: c.image, alt: "Total Care", className: e.image }) }),
71
- /* @__PURE__ */ n("div", { className: e.tabsContainer, children: /* @__PURE__ */ m("div", { ref: a, className: e.tabs, children: [
72
- /* @__PURE__ */ n("div", { ref: o, id: "marker", className: e.marker }),
73
- l.map((t, r) => /* @__PURE__ */ m(
53
+ return /* @__PURE__ */ d("section", { className: e.root, children: [
54
+ h && /* @__PURE__ */ r(k, { className: e.bubbles }),
55
+ /* @__PURE__ */ d("div", { className: e.container, children: [
56
+ /* @__PURE__ */ r(b, { as: "div", title: y, className: e.header, colorScheme: "dark" }),
57
+ /* @__PURE__ */ d("div", { className: e.content, children: [
58
+ s.image && /* @__PURE__ */ r("div", { className: e.imageWrap, children: /* @__PURE__ */ r("img", { src: s.image, alt: "Total Care", className: e.image }) }),
59
+ /* @__PURE__ */ r("div", { className: e.tabsContainer, children: /* @__PURE__ */ d("div", { ref: o, className: e.tabs, children: [
60
+ /* @__PURE__ */ r("div", { ref: n, id: "marker", className: e.marker }),
61
+ m.map((t, i) => /* @__PURE__ */ d(
74
62
  "button",
75
63
  {
76
- className: B(e.tab, {
77
- [e.active]: c === t
64
+ className: x(e.tab, {
65
+ [e.active]: s === t
78
66
  }),
79
- onClick: () => R(t, r),
67
+ onClick: () => C(t, i),
80
68
  children: [
81
- t.icon && /* @__PURE__ */ n(N, { defaultVariant: "displayMd", className: e.icon, children: /* @__PURE__ */ n(M, { name: t.icon }) }),
82
- /* @__PURE__ */ n(N, { defaultVariant: "displayMd", className: e.hideMobile, children: t.label })
69
+ t.icon && /* @__PURE__ */ r(N, { defaultVariant: "displayMd", className: e.icon, children: /* @__PURE__ */ r(B, { name: t.icon }) }),
70
+ /* @__PURE__ */ r(N, { defaultVariant: "displayMd", className: e.hideMobile, children: t.label })
83
71
  ]
84
72
  },
85
73
  t.label
86
74
  ))
87
75
  ] }) }),
88
- c.description && /* @__PURE__ */ n("div", { className: e.description, children: /* @__PURE__ */ n(
76
+ s.description && /* @__PURE__ */ r("div", { className: e.description, children: /* @__PURE__ */ r(
89
77
  b,
90
78
  {
91
79
  as: "div",
92
80
  defaultVariant: "bodyXl",
93
81
  mobileVariant: "bodyMd",
94
82
  className: e.descriptionText,
95
- title: c.description,
83
+ title: s.description,
96
84
  colorScheme: "dark"
97
85
  }
98
86
  ) })
99
87
  ] })
100
88
  ] }),
101
- g && /* @__PURE__ */ n(x, { variant: "blue" })
89
+ h && /* @__PURE__ */ r(S, { variant: "blue" })
102
90
  ] });
103
91
  };
104
92
  export {
105
- I as SlidingTabsGallery
93
+ O as SlidingTabsGallery
106
94
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zenpatient-org/healthspan-marketing-ui",
3
- "version": "0.1.157",
3
+ "version": "0.1.158",
4
4
  "description": "Design system",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.es.js",