@zenpatient-org/healthspan-marketing-ui 0.2.40 → 0.2.42

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 (22) hide show
  1. package/dist/components/PriceDisplay/PriceDisplay.cjs.js +1 -1
  2. package/dist/components/PriceDisplay/PriceDisplay.d.ts +0 -1
  3. package/dist/components/PriceDisplay/PriceDisplay.es.js +46 -41
  4. package/dist/modules/IndividualProductCard/components/Features/Features.cjs.js +1 -1
  5. package/dist/modules/IndividualProductCard/components/Features/Features.es.js +31 -30
  6. package/dist/modules/IndividualProductCard/components/Features/features.module.css +2 -2
  7. package/dist/modules/IndividualProductCardV2/IndividualProductCardV2.cjs.js +1 -1
  8. package/dist/modules/IndividualProductCardV2/IndividualProductCardV2.d.ts +2 -2
  9. package/dist/modules/IndividualProductCardV2/IndividualProductCardV2.es.js +85 -55
  10. package/dist/modules/IndividualProductCardV2/individualProductCardV2.module.css +16 -0
  11. package/dist/modules/IndividualProductCardV2/types.d.ts +16 -8
  12. package/dist/modules/YourProtocol/YourProtocol.cjs.js +1 -1
  13. package/dist/modules/YourProtocol/YourProtocol.d.ts +8 -3
  14. package/dist/modules/YourProtocol/YourProtocol.es.js +33 -44
  15. package/dist/modules/YourProtocol/types.d.ts +2 -11
  16. package/dist/modules/YourProtocol/yourProtocol.module.css +124 -54
  17. package/package.json +1 -1
  18. package/dist/modules/YourProtocol/components/ProtocolTags/ProtocolTags.cjs.js +0 -1
  19. package/dist/modules/YourProtocol/components/ProtocolTags/ProtocolTags.d.ts +0 -7
  20. package/dist/modules/YourProtocol/components/ProtocolTags/ProtocolTags.es.js +0 -37
  21. package/dist/modules/YourProtocol/components/ProtocolTags/index.d.ts +0 -1
  22. package/dist/modules/YourProtocol/components/ProtocolTags/protocolTags.module.css +0 -37
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),s=require("../Typography/Typography.cjs.js"),e=require("../../src/components/PriceDisplay/priceDisplay.module.css"),c=require("../../utils/cn/cn.cjs.js"),o=require("../../utils/periodView.cjs.js"),l=({items:i})=>a.jsx("div",{className:e.root,children:i.map((r,n)=>a.jsxs("div",{className:c.cn(e.container,r.display==="double"?e.double:e.single),children:[a.jsx(s.Typography,{as:"p",defaultVariant:"bodySm",className:e.description,children:r.description}),a.jsxs("div",{className:e.priceWrapper,children:[!!r.prefix&&a.jsx(s.Typography,{as:"p",defaultVariant:"bodySm",className:e.prefix,children:r.prefix}),a.jsxs("div",{className:e.priceAmount,children:[a.jsx(s.Typography,{as:"p",defaultVariant:"headingXl",mobileVariant:"headingLg",className:e.price,children:(r.price/100).toFixed(0)}),a.jsx(s.Typography,{as:"p",defaultVariant:"headingXs",mobileVariant:"headingXxs",className:e.currency,children:"$"}),r.period!=="none"&&a.jsxs(s.Typography,{as:"p",defaultVariant:"labelMd",className:e.period,children:["/",o.shortPeriod(r.period)]})]})]})]},n))});exports.PriceDisplay=l;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime"),s=require("../Typography/Typography.cjs.js"),e=require("../../src/components/PriceDisplay/priceDisplay.module.css"),l=require("../../utils/cn/cn.cjs.js"),o=require("../../utils/periodView.cjs.js"),c=({items:i})=>{if(!i||i.length===0)return null;const n=i.length>1?"double":"single";return r.jsx("div",{className:e.root,children:i.map(a=>r.jsxs("div",{className:l.cn(e.container,n==="double"?e.double:e.single),children:[r.jsx(s.Typography,{as:"p",defaultVariant:"bodySm",className:e.description,children:a.description}),r.jsxs("div",{className:e.priceWrapper,children:[!!a.prefix&&r.jsx(s.Typography,{as:"p",defaultVariant:"bodySm",className:e.prefix,children:a.prefix}),r.jsxs("div",{className:e.priceAmount,children:[r.jsx(s.Typography,{as:"p",defaultVariant:"headingXl",mobileVariant:"headingLg",className:e.price,children:(a.price/100).toFixed(0)}),r.jsx(s.Typography,{as:"p",defaultVariant:"headingXs",mobileVariant:"headingXxs",className:e.currency,children:"$"}),a.period!=="none"&&r.jsxs(s.Typography,{as:"p",defaultVariant:"labelMd",className:e.period,children:["/",o.shortPeriod(a.period)]})]})]})]},a.description))})};exports.PriceDisplay=c;
@@ -1,7 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
 
3
3
  export type PriceDisplayProps = {
4
- display: 'single' | 'double';
5
4
  description: string;
6
5
  prefix?: string;
7
6
  price: number;
@@ -1,47 +1,52 @@
1
- import { jsx as e, jsxs as s } from "react/jsx-runtime";
1
+ import { jsx as a, jsxs as n } from "react/jsx-runtime";
2
2
  import { Typography as i } from "../Typography/Typography.es.js";
3
- import a from "../../components/PriceDisplay/priceDisplay.module.css";
4
- import { cn as o } from "../../utils/cn/cn.es.js";
5
- import { shortPeriod as n } from "../../utils/periodView.es.js";
6
- const f = ({ items: d }) => /* @__PURE__ */ e("div", { className: a.root, children: d.map((r, l) => /* @__PURE__ */ s(
7
- "div",
8
- {
9
- className: o(a.container, r.display === "double" ? a.double : a.single),
10
- children: [
11
- /* @__PURE__ */ e(i, { as: "p", defaultVariant: "bodySm", className: a.description, children: r.description }),
12
- /* @__PURE__ */ s("div", { className: a.priceWrapper, children: [
13
- !!r.prefix && /* @__PURE__ */ e(i, { as: "p", defaultVariant: "bodySm", className: a.prefix, children: r.prefix }),
14
- /* @__PURE__ */ s("div", { className: a.priceAmount, children: [
15
- /* @__PURE__ */ e(
16
- i,
17
- {
18
- as: "p",
19
- defaultVariant: "headingXl",
20
- mobileVariant: "headingLg",
21
- className: a.price,
22
- children: (r.price / 100).toFixed(0)
23
- }
24
- ),
25
- /* @__PURE__ */ e(
26
- i,
27
- {
28
- as: "p",
29
- defaultVariant: "headingXs",
30
- mobileVariant: "headingXxs",
31
- className: a.currency,
32
- children: "$"
33
- }
34
- ),
35
- r.period !== "none" && /* @__PURE__ */ s(i, { as: "p", defaultVariant: "labelMd", className: a.period, children: [
36
- "/",
37
- n(r.period)
3
+ import e from "../../components/PriceDisplay/priceDisplay.module.css";
4
+ import { cn as d } from "../../utils/cn/cn.es.js";
5
+ import { shortPeriod as s } from "../../utils/periodView.es.js";
6
+ const f = ({ items: l }) => {
7
+ if (!l || l.length === 0)
8
+ return null;
9
+ const o = l.length > 1 ? "double" : "single";
10
+ return /* @__PURE__ */ a("div", { className: e.root, children: l.map((r) => /* @__PURE__ */ n(
11
+ "div",
12
+ {
13
+ className: d(e.container, o === "double" ? e.double : e.single),
14
+ children: [
15
+ /* @__PURE__ */ a(i, { as: "p", defaultVariant: "bodySm", className: e.description, children: r.description }),
16
+ /* @__PURE__ */ n("div", { className: e.priceWrapper, children: [
17
+ !!r.prefix && /* @__PURE__ */ a(i, { as: "p", defaultVariant: "bodySm", className: e.prefix, children: r.prefix }),
18
+ /* @__PURE__ */ n("div", { className: e.priceAmount, children: [
19
+ /* @__PURE__ */ a(
20
+ i,
21
+ {
22
+ as: "p",
23
+ defaultVariant: "headingXl",
24
+ mobileVariant: "headingLg",
25
+ className: e.price,
26
+ children: (r.price / 100).toFixed(0)
27
+ }
28
+ ),
29
+ /* @__PURE__ */ a(
30
+ i,
31
+ {
32
+ as: "p",
33
+ defaultVariant: "headingXs",
34
+ mobileVariant: "headingXxs",
35
+ className: e.currency,
36
+ children: "$"
37
+ }
38
+ ),
39
+ r.period !== "none" && /* @__PURE__ */ n(i, { as: "p", defaultVariant: "labelMd", className: e.period, children: [
40
+ "/",
41
+ s(r.period)
42
+ ] })
38
43
  ] })
39
44
  ] })
40
- ] })
41
- ]
42
- },
43
- l
44
- )) });
45
+ ]
46
+ },
47
+ r.description
48
+ )) });
49
+ };
45
50
  export {
46
51
  f as PriceDisplay
47
52
  };
@@ -1 +1 @@
1
- "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),l=require("react"),y=require("../../../../utils/cn/cn.cjs.js"),t=require("../../../../src/modules/IndividualProductCard/components/Features/features.module.css"),g=require("../../../../components/TypeBadge/TypeBadge.cjs.js"),a=require("../../../../components/Typography/Typography.cjs.js"),p=require("../../../../components/Superscript/Superscript.cjs.js"),m=require("../../../../components/IconBracket/IconBracket.cjs.js"),S=({features:u})=>{const[n,d]=l.useState([]),b=l.useCallback(e=>{d(r=>r.includes(e)?r.filter(c=>c!==e):[...r,e])},[]);return s.jsx("div",{className:t.root,children:u.map((e,r)=>{const c=e.description&&e.collapsible,i=!!e.description,o=s.jsxs("div",{className:t.labelWrapper,children:[s.jsx(g.TypeBadge,{type:e.type},r),s.jsxs(a.Typography,{className:t.label,as:"h4",defaultVariant:i?"bodySm":"bodyMd",mobileVariant:i?"labelMd":"bodySm",weight:"regular",children:[e.label,e.labelSuperscript&&!isNaN(e.labelSuperscript)&&s.jsx(p.Superscript,{value:e.labelSuperscript.toString()})]})]});return s.jsxs("div",{className:t.feature,children:[c?s.jsxs("button",{className:t.header,onClick:()=>b(r),children:[o,s.jsx(m.IconBracket,{variant:n.includes(r)?"close":"plus",size:"sm"})]}):o,i&&s.jsxs(a.Typography,{as:"p",defaultVariant:"bodyXs",className:y.cn(t.description,{[t.descriptionActive]:n.includes(r)||!c}),weight:"regular",children:[e.description,e.descriptionSuperscript&&!isNaN(e.descriptionSuperscript)&&s.jsx(p.Superscript,{value:e.descriptionSuperscript.toString()})]})]},`${e.label}-${r}`)})})};exports.Features=S;
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),o=require("react"),y=require("../../../../utils/cn/cn.cjs.js"),t=require("../../../../src/modules/IndividualProductCard/components/Features/features.module.css"),g=require("../../../../components/TypeBadge/TypeBadge.cjs.js"),l=require("../../../../components/Typography/Typography.cjs.js"),a=require("../../../../components/Superscript/Superscript.cjs.js"),m=require("../../../../components/IconBracket/IconBracket.cjs.js"),S=({features:p})=>{const[i,u]=o.useState([]),d=o.useCallback(e=>{u(r=>r.includes(e)?r.filter(c=>c!==e):[...r,e])},[]);return s.jsx("div",{className:t.root,children:p.map((e,r)=>{const c=e.description&&e.collapsible,b=!!e.description,n=s.jsxs("div",{className:t.labelWrapper,children:[s.jsx(g.TypeBadge,{type:e.type},r),s.jsxs(l.Typography,{className:t.label,as:"span",defaultVariant:"bodyMd",mobileVariant:"bodySm",weight:"regular",children:[e.label,e.labelSuperscript&&!isNaN(e.labelSuperscript)&&s.jsx(a.Superscript,{value:e.labelSuperscript.toString()})]})]});return s.jsxs("div",{className:t.feature,children:[c?s.jsxs("button",{className:t.header,onClick:()=>d(r),children:[n,s.jsx(m.IconBracket,{variant:i.includes(r)?"close":"plus",size:"md"})]}):n,b&&s.jsxs(l.Typography,{as:"p",defaultVariant:"bodySm",mobileVariant:"bodyXs",className:y.cn(t.description,{[t.descriptionActive]:i.includes(r)||!c}),weight:"regular",children:[e.description,e.descriptionSuperscript&&!isNaN(e.descriptionSuperscript)&&s.jsx(a.Superscript,{value:e.descriptionSuperscript.toString()})]})]},`${e.label}-${r}`)})})};exports.Features=S;
@@ -1,55 +1,56 @@
1
1
  "use client";
2
- import { jsx as e, jsxs as l } from "react/jsx-runtime";
2
+ import { jsx as t, jsxs as e } from "react/jsx-runtime";
3
3
  import { useState as u, useCallback as g } from "react";
4
- import { cn as h } from "../../../../utils/cn/cn.es.js";
5
- import r from "../../../../modules/IndividualProductCard/components/Features/features.module.css";
6
- import { TypeBadge as S } from "../../../../components/TypeBadge/TypeBadge.es.js";
4
+ import { cn as S } from "../../../../utils/cn/cn.es.js";
5
+ import s from "../../../../modules/IndividualProductCard/components/Features/features.module.css";
6
+ import { TypeBadge as h } from "../../../../components/TypeBadge/TypeBadge.es.js";
7
7
  import { Typography as a } from "../../../../components/Typography/Typography.es.js";
8
- import { Superscript as n } from "../../../../components/Superscript/Superscript.es.js";
8
+ import { Superscript as p } from "../../../../components/Superscript/Superscript.es.js";
9
9
  import { IconBracket as y } from "../../../../components/IconBracket/IconBracket.es.js";
10
- const w = ({ features: m }) => {
11
- const [c, d] = u([]), b = g((s) => {
12
- d((i) => i.includes(s) ? i.filter((t) => t !== s) : [...i, s]);
10
+ const w = ({ features: n }) => {
11
+ const [o, m] = u([]), d = g((i) => {
12
+ m((r) => r.includes(i) ? r.filter((l) => l !== i) : [...r, i]);
13
13
  }, []);
14
- return /* @__PURE__ */ e("div", { className: r.root, children: m.map((s, i) => {
15
- const t = s.description && s.collapsible, o = !!s.description, p = /* @__PURE__ */ l("div", { className: r.labelWrapper, children: [
16
- /* @__PURE__ */ e(S, { type: s.type }, i),
17
- /* @__PURE__ */ l(
14
+ return /* @__PURE__ */ t("div", { className: s.root, children: n.map((i, r) => {
15
+ const l = i.description && i.collapsible, b = !!i.description, c = /* @__PURE__ */ e("div", { className: s.labelWrapper, children: [
16
+ /* @__PURE__ */ t(h, { type: i.type }, r),
17
+ /* @__PURE__ */ e(
18
18
  a,
19
19
  {
20
- className: r.label,
21
- as: "h4",
22
- defaultVariant: o ? "bodySm" : "bodyMd",
23
- mobileVariant: o ? "labelMd" : "bodySm",
20
+ className: s.label,
21
+ as: "span",
22
+ defaultVariant: "bodyMd",
23
+ mobileVariant: "bodySm",
24
24
  weight: "regular",
25
25
  children: [
26
- s.label,
27
- s.labelSuperscript && !isNaN(s.labelSuperscript) && /* @__PURE__ */ e(n, { value: s.labelSuperscript.toString() })
26
+ i.label,
27
+ i.labelSuperscript && !isNaN(i.labelSuperscript) && /* @__PURE__ */ t(p, { value: i.labelSuperscript.toString() })
28
28
  ]
29
29
  }
30
30
  )
31
31
  ] });
32
- return /* @__PURE__ */ l("div", { className: r.feature, children: [
33
- t ? /* @__PURE__ */ l("button", { className: r.header, onClick: () => b(i), children: [
34
- p,
35
- /* @__PURE__ */ e(y, { variant: c.includes(i) ? "close" : "plus", size: "sm" })
36
- ] }) : p,
37
- o && /* @__PURE__ */ l(
32
+ return /* @__PURE__ */ e("div", { className: s.feature, children: [
33
+ l ? /* @__PURE__ */ e("button", { className: s.header, onClick: () => d(r), children: [
34
+ c,
35
+ /* @__PURE__ */ t(y, { variant: o.includes(r) ? "close" : "plus", size: "md" })
36
+ ] }) : c,
37
+ b && /* @__PURE__ */ e(
38
38
  a,
39
39
  {
40
40
  as: "p",
41
- defaultVariant: "bodyXs",
42
- className: h(r.description, {
43
- [r.descriptionActive]: c.includes(i) || !t
41
+ defaultVariant: "bodySm",
42
+ mobileVariant: "bodyXs",
43
+ className: S(s.description, {
44
+ [s.descriptionActive]: o.includes(r) || !l
44
45
  }),
45
46
  weight: "regular",
46
47
  children: [
47
- s.description,
48
- s.descriptionSuperscript && !isNaN(s.descriptionSuperscript) && /* @__PURE__ */ e(n, { value: s.descriptionSuperscript.toString() })
48
+ i.description,
49
+ i.descriptionSuperscript && !isNaN(i.descriptionSuperscript) && /* @__PURE__ */ t(p, { value: i.descriptionSuperscript.toString() })
49
50
  ]
50
51
  }
51
52
  )
52
- ] }, `${s.label}-${i}`);
53
+ ] }, `${i.label}-${r}`);
53
54
  }) });
54
55
  };
55
56
  export {
@@ -24,7 +24,7 @@
24
24
  align-items: center;
25
25
  justify-content: space-between;
26
26
  padding: 0;
27
- gap: 12px;
27
+ gap: 8px;
28
28
  border: none;
29
29
  background: none;
30
30
  box-shadow: none;
@@ -59,7 +59,7 @@
59
59
  }
60
60
 
61
61
  .descriptionActive {
62
- margin-top: 12px;
62
+ margin-top: 8px;
63
63
  line-height: var(--line-height-lg);
64
64
  color: var(--color-text-secondary);
65
65
  }
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),o=require("../../types/analytics/analytics.cjs.js"),l=require("../../utils/cn/cn.cjs.js"),a=require("../../src/modules/IndividualProductCardV2/individualProductCardV2.module.css"),g=require("../../components/ImageGallery/ImageGallery.cjs.js"),d=require("../../components/RatingPreview/RatingPreview.cjs.js"),s=require("../../components/Typography/Typography.cjs.js"),v=require("../IndividualProductCard/components/Features/Features.cjs.js"),_=require("../../components/PlainFeaturesGroup/PlainFeaturesGroup.cjs.js"),P=require("../../components/PriceDisplay/PriceDisplay.cjs.js"),q=require("../../components/Button/Button.cjs.js"),b=require("../../components/Quote/Quote.cjs.js"),N=({zenpatientId:u,signupUrl:n,name:p,description:y,label:m,images:h,features:j,quote:t,priceDisplay:i,featuresGroup:r,ratingPreview:c})=>{const x={event:o.EAnalyticsEvent.ctaClicked,type:o.EAnalyticsEventType.interaction,component:"Pricing",payload:{ctaLabel:"GET STARTED",ctaLink:n,productId:u}};return e.jsx("section",{className:a.root,children:e.jsxs("div",{className:a.mainContainer,children:[e.jsxs("div",{className:a.leftColumn,children:[e.jsx(g.ImageGallery,{images:h,label:m}),e.jsx("div",{className:l.cn(a.ratingContainer,a.mobileOnly),children:e.jsx(d.RatingPreview,{...c})}),t&&e.jsx("div",{className:a.quoteWrapper,children:e.jsx(b.Quote,{...t})})]}),e.jsxs("div",{className:a.rightColumn,children:[e.jsxs("div",{className:a.header,children:[e.jsx(s.Typography,{as:"h1",defaultVariant:"displayXs",mobileVariant:"headingLg",children:p}),e.jsx(s.Typography,{as:"p",defaultVariant:"bodyMd",mobileVariant:"bodySm",className:a.description,children:y})]}),e.jsx(v.Features,{features:j}),r&&e.jsx(_.PlainFeaturesGroup,{...r}),i&&e.jsx(P.PriceDisplay,{items:i}),e.jsx("div",{className:l.cn(a.ratingContainer,a.desktopOnly),children:e.jsx(d.RatingPreview,{...c})}),e.jsxs("div",{className:a.actions,children:[e.jsx(q.Button,{as:"a",variant:"primary",size:"lg",href:n,analyticsProps:x,children:"Get started"}),e.jsx(s.Typography,{as:"p",defaultVariant:"labelMd",className:a.hsaFsaText,children:"HSA/FSA Eligible"})]})]})]})})};exports.IndividualProductCardV2=N;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),d=require("../../types/analytics/analytics.cjs.js"),P=require("../../utils/cn/cn.cjs.js"),i=require("../../src/modules/IndividualProductCardV2/individualProductCardV2.module.css"),G=require("../../components/ImageGallery/ImageGallery.cjs.js"),_=require("../../components/RatingPreview/RatingPreview.cjs.js"),u=require("../../components/Typography/Typography.cjs.js"),I=require("../IndividualProductCard/components/Features/Features.cjs.js"),D=require("../../components/PlainFeaturesGroup/PlainFeaturesGroup.cjs.js"),V=require("../../components/PriceDisplay/PriceDisplay.cjs.js"),F=require("../IndividualProductCard/components/PlanCard/PlanCard.cjs.js"),k=require("../../components/Button/Button.cjs.js"),R=require("../../components/Quote/Quote.cjs.js"),B=t=>{const{zenpatientId:p,signupUrl:c,name:S,description:q,label:f,images:N,features:T,quote:y,featuresGroup:m,ratingPreview:v,view:r,button:a}=t,n=r==="plans_list"?t.plans:void 0,E=n&&n.length>0,h=r==="plans_list"?t.selectedPlanId:void 0,o=n==null?void 0:n.find(s=>s.id===h),g=o?`${(a==null?void 0:a.link)||c}?defaultDurationSelection=${o==null?void 0:o.durationAmount}`:(a==null?void 0:a.link)||c,x=r==="pricing_display"?t.priceDisplay:void 0,C={event:d.EAnalyticsEvent.ctaClicked,type:d.EAnalyticsEventType.interaction,component:"Pricing",payload:{ctaLabel:(a==null?void 0:a.text)||"GET STARTED",ctaLink:g||c,productId:p}},A=s=>{var j;if(r!=="plans_list"||!t.onSelectPlan)return;t.onSelectPlan(s);const l=n==null?void 0:n.find(w=>w.id===s),b={event:d.EAnalyticsEvent.userSelectedPlan,location:"IPCv2",type:d.EAnalyticsEventType.interaction,payload:{productId:p,planId:s,planPrice:l==null?void 0:l.price,planDuration:l==null?void 0:l.duration}};(j=window.eventBus)==null||j.emit("analytics",b)};return e.jsx("section",{className:i.root,children:e.jsxs("div",{className:i.mainContainer,children:[e.jsxs("div",{className:i.leftColumn,children:[e.jsx(G.ImageGallery,{images:N,label:f}),e.jsx("div",{className:P.cn(i.ratingContainer,i.mobileOnly),children:e.jsx(_.RatingPreview,{...v})}),y&&e.jsx("div",{className:i.quoteWrapper,children:e.jsx(R.Quote,{...y})})]}),e.jsxs("div",{className:i.rightColumn,children:[e.jsxs("div",{className:i.header,children:[e.jsx(u.Typography,{as:"h1",defaultVariant:"displayXs",mobileVariant:"headingLg",children:S}),e.jsx(u.Typography,{as:"p",defaultVariant:"bodyMd",mobileVariant:"bodySm",className:i.description,children:q})]}),e.jsx(I.Features,{features:T}),m&&e.jsx(D.PlainFeaturesGroup,{...m}),r==="pricing_display"&&x&&e.jsx(V.PriceDisplay,{items:x}),r==="plans_list"&&E&&e.jsx("div",{className:i.plansSection,children:e.jsxs("div",{className:i.plans,children:[e.jsx(u.Typography,{as:"h4",defaultVariant:"labelSm",emphasis:!0,weight:"regular",children:"Subscribe & Save"}),n.map(s=>e.jsx(F.PlanCard,{plan:s,onSelect:A,isActive:h===s.id},s.id))]})}),e.jsx("div",{className:P.cn(i.ratingContainer,i.desktopOnly),children:e.jsx(_.RatingPreview,{...v})}),e.jsxs("div",{className:i.actions,children:[e.jsx(k.Button,{as:"a",variant:"primary",size:"lg",href:g||c,analyticsProps:C,children:(a==null?void 0:a.text)||"Get started"}),e.jsx(u.Typography,{as:"p",defaultVariant:"labelMd",className:i.hsaFsaText,children:"HSA/FSA Eligible"})]})]})]})})};exports.IndividualProductCardV2=B;
@@ -1,3 +1,3 @@
1
- import { TIndividualProductCardV2Base } from './types';
1
+ import { TIndividualProductCardV2View } from './types';
2
2
 
3
- export declare const IndividualProductCardV2: ({ zenpatientId, signupUrl, name, description, label, images, features, quote, priceDisplay, featuresGroup, ratingPreview, }: TIndividualProductCardV2Base) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const IndividualProductCardV2: (props: TIndividualProductCardV2View) => import("react/jsx-runtime").JSX.Element;
@@ -1,79 +1,109 @@
1
- import { jsx as a, jsxs as e } from "react/jsx-runtime";
2
- import { EAnalyticsEventType as N, EAnalyticsEvent as b } from "../../types/analytics/analytics.es.js";
3
- import { cn as m } from "../../utils/cn/cn.es.js";
4
- import i from "../../modules/IndividualProductCardV2/individualProductCardV2.module.css";
5
- import { ImageGallery as g } from "../../components/ImageGallery/ImageGallery.es.js";
6
- import { RatingPreview as c } from "../../components/RatingPreview/RatingPreview.es.js";
7
- import { Typography as r } from "../../components/Typography/Typography.es.js";
8
- import { Features as E } from "../IndividualProductCard/components/Features/Features.es.js";
9
- import { PlainFeaturesGroup as C } from "../../components/PlainFeaturesGroup/PlainFeaturesGroup.es.js";
10
- import { PriceDisplay as A } from "../../components/PriceDisplay/PriceDisplay.es.js";
11
- import { Button as T } from "../../components/Button/Button.es.js";
12
- import { Quote as V } from "../../components/Quote/Quote.es.js";
13
- const z = ({
14
- zenpatientId: d,
15
- signupUrl: t,
16
- name: p,
17
- description: h,
18
- label: y,
19
- images: f,
20
- features: v,
21
- quote: n,
22
- priceDisplay: o,
23
- featuresGroup: l,
24
- ratingPreview: s
25
- }) => {
26
- const u = {
27
- event: b.ctaClicked,
28
- type: N.interaction,
1
+ import { jsx as i, jsxs as o } from "react/jsx-runtime";
2
+ import { EAnalyticsEventType as S, EAnalyticsEvent as N } from "../../types/analytics/analytics.es.js";
3
+ import { cn as C } from "../../utils/cn/cn.es.js";
4
+ import e from "../../modules/IndividualProductCardV2/individualProductCardV2.module.css";
5
+ import { ImageGallery as G } from "../../components/ImageGallery/ImageGallery.es.js";
6
+ import { RatingPreview as A } from "../../components/RatingPreview/RatingPreview.es.js";
7
+ import { Typography as m } from "../../components/Typography/Typography.es.js";
8
+ import { Features as F } from "../IndividualProductCard/components/Features/Features.es.js";
9
+ import { PlainFeaturesGroup as L } from "../../components/PlainFeaturesGroup/PlainFeaturesGroup.es.js";
10
+ import { PriceDisplay as j } from "../../components/PriceDisplay/PriceDisplay.es.js";
11
+ import { PlanCard as q } from "../IndividualProductCard/components/PlanCard/PlanCard.es.js";
12
+ import { Button as z } from "../../components/Button/Button.es.js";
13
+ import { Quote as B } from "../../components/Quote/Quote.es.js";
14
+ const ii = (r) => {
15
+ const {
16
+ zenpatientId: p,
17
+ signupUrl: c,
18
+ name: E,
19
+ description: b,
20
+ label: V,
21
+ images: k,
22
+ features: w,
23
+ quote: h,
24
+ featuresGroup: u,
25
+ ratingPreview: v,
26
+ view: l,
27
+ button: a
28
+ } = r, t = l === "plans_list" ? r.plans : void 0, x = t && t.length > 0, f = l === "plans_list" ? r.selectedPlanId : void 0, d = t == null ? void 0 : t.find((n) => n.id === f), y = d ? `${(a == null ? void 0 : a.link) || c}?defaultDurationSelection=${d == null ? void 0 : d.durationAmount}` : (a == null ? void 0 : a.link) || c, g = l === "pricing_display" ? r.priceDisplay : void 0, D = {
29
+ event: N.ctaClicked,
30
+ type: S.interaction,
29
31
  component: "Pricing",
30
32
  payload: {
31
- ctaLabel: "GET STARTED",
32
- ctaLink: t,
33
- productId: d
33
+ ctaLabel: (a == null ? void 0 : a.text) || "GET STARTED",
34
+ ctaLink: y || c,
35
+ productId: p
34
36
  }
37
+ }, I = (n) => {
38
+ var P;
39
+ if (l !== "plans_list" || !r.onSelectPlan) return;
40
+ r.onSelectPlan(n);
41
+ const s = t == null ? void 0 : t.find((_) => _.id === n), T = {
42
+ event: N.userSelectedPlan,
43
+ location: "IPCv2",
44
+ type: S.interaction,
45
+ payload: {
46
+ productId: p,
47
+ planId: n,
48
+ planPrice: s == null ? void 0 : s.price,
49
+ planDuration: s == null ? void 0 : s.duration
50
+ }
51
+ };
52
+ (P = window.eventBus) == null || P.emit("analytics", T);
35
53
  };
36
- return /* @__PURE__ */ a("section", { className: i.root, children: /* @__PURE__ */ e("div", { className: i.mainContainer, children: [
37
- /* @__PURE__ */ e("div", { className: i.leftColumn, children: [
38
- /* @__PURE__ */ a(g, { images: f, label: y }),
39
- /* @__PURE__ */ a("div", { className: m(i.ratingContainer, i.mobileOnly), children: /* @__PURE__ */ a(c, { ...s }) }),
40
- n && /* @__PURE__ */ a("div", { className: i.quoteWrapper, children: /* @__PURE__ */ a(V, { ...n }) })
54
+ return /* @__PURE__ */ i("section", { className: e.root, children: /* @__PURE__ */ o("div", { className: e.mainContainer, children: [
55
+ /* @__PURE__ */ o("div", { className: e.leftColumn, children: [
56
+ /* @__PURE__ */ i(G, { images: k, label: V }),
57
+ /* @__PURE__ */ i("div", { className: C(e.ratingContainer, e.mobileOnly), children: /* @__PURE__ */ i(A, { ...v }) }),
58
+ h && /* @__PURE__ */ i("div", { className: e.quoteWrapper, children: /* @__PURE__ */ i(B, { ...h }) })
41
59
  ] }),
42
- /* @__PURE__ */ e("div", { className: i.rightColumn, children: [
43
- /* @__PURE__ */ e("div", { className: i.header, children: [
44
- /* @__PURE__ */ a(r, { as: "h1", defaultVariant: "displayXs", mobileVariant: "headingLg", children: p }),
45
- /* @__PURE__ */ a(
46
- r,
60
+ /* @__PURE__ */ o("div", { className: e.rightColumn, children: [
61
+ /* @__PURE__ */ o("div", { className: e.header, children: [
62
+ /* @__PURE__ */ i(m, { as: "h1", defaultVariant: "displayXs", mobileVariant: "headingLg", children: E }),
63
+ /* @__PURE__ */ i(
64
+ m,
47
65
  {
48
66
  as: "p",
49
67
  defaultVariant: "bodyMd",
50
68
  mobileVariant: "bodySm",
51
- className: i.description,
52
- children: h
69
+ className: e.description,
70
+ children: b
53
71
  }
54
72
  )
55
73
  ] }),
56
- /* @__PURE__ */ a(E, { features: v }),
57
- l && /* @__PURE__ */ a(C, { ...l }),
58
- o && /* @__PURE__ */ a(A, { items: o }),
59
- /* @__PURE__ */ a("div", { className: m(i.ratingContainer, i.desktopOnly), children: /* @__PURE__ */ a(c, { ...s }) }),
60
- /* @__PURE__ */ e("div", { className: i.actions, children: [
61
- /* @__PURE__ */ a(
62
- T,
74
+ /* @__PURE__ */ i(F, { features: w }),
75
+ u && /* @__PURE__ */ i(L, { ...u }),
76
+ l === "pricing_display" && g && /* @__PURE__ */ i(j, { items: g }),
77
+ l === "plans_list" && x && /* @__PURE__ */ i("div", { className: e.plansSection, children: /* @__PURE__ */ o("div", { className: e.plans, children: [
78
+ /* @__PURE__ */ i(m, { as: "h4", defaultVariant: "labelSm", emphasis: !0, weight: "regular", children: "Subscribe & Save" }),
79
+ t.map((n) => /* @__PURE__ */ i(
80
+ q,
81
+ {
82
+ plan: n,
83
+ onSelect: I,
84
+ isActive: f === n.id
85
+ },
86
+ n.id
87
+ ))
88
+ ] }) }),
89
+ /* @__PURE__ */ i("div", { className: C(e.ratingContainer, e.desktopOnly), children: /* @__PURE__ */ i(A, { ...v }) }),
90
+ /* @__PURE__ */ o("div", { className: e.actions, children: [
91
+ /* @__PURE__ */ i(
92
+ z,
63
93
  {
64
94
  as: "a",
65
95
  variant: "primary",
66
96
  size: "lg",
67
- href: t,
68
- analyticsProps: u,
69
- children: "Get started"
97
+ href: y || c,
98
+ analyticsProps: D,
99
+ children: (a == null ? void 0 : a.text) || "Get started"
70
100
  }
71
101
  ),
72
- /* @__PURE__ */ a(r, { as: "p", defaultVariant: "labelMd", className: i.hsaFsaText, children: "HSA/FSA Eligible" })
102
+ /* @__PURE__ */ i(m, { as: "p", defaultVariant: "labelMd", className: e.hsaFsaText, children: "HSA/FSA Eligible" })
73
103
  ] })
74
104
  ] })
75
105
  ] }) });
76
106
  };
77
107
  export {
78
- z as IndividualProductCardV2
108
+ ii as IndividualProductCardV2
79
109
  };
@@ -77,6 +77,22 @@
77
77
  border-radius: var(--border-radius-xs);
78
78
  }
79
79
 
80
+ .plansSection {
81
+ grid-area: plans;
82
+ display: flex;
83
+ flex-direction: column;
84
+ gap: 24px;
85
+ padding-top: 12px;
86
+ }
87
+
88
+ .plans {
89
+ display: flex;
90
+ flex-direction: column;
91
+ width: 100%;
92
+ gap: 12px;
93
+ }
94
+
95
+
80
96
  @media (width <= 1024px) {
81
97
  .mainContainer {
82
98
  padding: 2rem 1rem;
@@ -24,7 +24,6 @@ export type TPriceDisplayComponentView = {
24
24
  price: number;
25
25
  period: 'none' | 'month' | 'quarter' | 'year';
26
26
  prefix?: string;
27
- display: 'single' | 'double';
28
27
  };
29
28
  export type TInternalPlainFeatureItemView = {
30
29
  text: string;
@@ -49,12 +48,25 @@ export type TIndividualProductCardV2Base = {
49
48
  label?: string;
50
49
  rating?: TReviewsStats;
51
50
  quote?: TQuoteComponentView;
52
- priceDisplay?: Array<TPriceDisplayComponentView>;
53
51
  featuresGroup?: TPlainFeaturesGroupView;
54
52
  ratingPreview?: TRatingPreviewView;
53
+ button: {
54
+ text: string;
55
+ link: string;
56
+ };
55
57
  };
56
58
  export type TIndividualProductCardBasicV2View = TIndividualProductCardV2Base & {
57
- plansView?: 'single';
59
+ view?: 'basic';
60
+ };
61
+ export type TIndividualProductCardPricingV2View = TIndividualProductCardV2Base & {
62
+ view?: 'pricing_display';
63
+ priceDisplay?: Array<TPriceDisplayComponentView>;
64
+ };
65
+ export type TIndividualProductCardPlansV2View = TIndividualProductCardV2Base & {
66
+ view?: 'plans_list';
67
+ plans?: Array<TProductPlan>;
68
+ selectedPlanId?: string;
69
+ onSelectPlan?: (planId: TProductPlan['id']) => void;
58
70
  };
59
71
  export type TProductPlan = {
60
72
  id: string;
@@ -67,8 +79,4 @@ export type TProductPlan = {
67
79
  durationAmount?: number;
68
80
  featured?: boolean;
69
81
  };
70
- export type TIndividualProductCardPricingV2View = TIndividualProductCardV2Base & {
71
- plansView?: 'pricing';
72
- plans?: Array<TProductPlan>;
73
- };
74
- export type TIndividualProductCardV2View = TIndividualProductCardBasicV2View | TIndividualProductCardPricingV2View;
82
+ export type TIndividualProductCardV2View = TIndividualProductCardBasicV2View | TIndividualProductCardPricingV2View | TIndividualProductCardPlansV2View;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),m=require("../../utils/cn/cn.cjs.js"),s=require("../../src/modules/YourProtocol/yourProtocol.module.css"),c=require("../../types/analytics/analytics.cjs.js"),p=require("../../components/HighlightedTitle/HighlightedTitle.cjs.js"),g=require("./components/ProtocolTags/ProtocolTags.cjs.js"),h=require("../../components/Callback/Callback.cjs.js"),y=({title:a,image:l,tags:d,callbackView:t})=>{var o,n,i,r;const u={event:c.EAnalyticsEvent.ctaClicked,type:c.EAnalyticsEventType.interaction,component:"YourProtocol",element:"Callback",payload:{ctaLink:(o=t==null?void 0:t.signupUrl)!=null?o:""}};return e.jsx("section",{className:s.root,children:e.jsxs("div",{className:s.container,children:[e.jsxs("div",{className:s.content,children:[e.jsx(p.HighlightedTitle,{title:a,className:s.title,defaultVariant:"displaySm",mobileVariant:"headingXl"}),e.jsx(g.ProtocolTags,{tags:d}),t&&e.jsx("div",{className:s.callback,children:e.jsx(h.Callback,{title:t.title,description:(n=t.description)!=null?n:"",price:(i=t.price)!=null?i:"",image:t.image,button:{href:(r=t.signupUrl)!=null?r:"",as:"a",analyticsProps:u},size:"sm",shape:t.shape})})]}),e.jsx("img",{src:l,alt:"Your Protocol",className:m.cn(s.image,s.desktop),width:481})]})})};exports.YourProtocol=y;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),a=require("../../src/modules/YourProtocol/yourProtocol.module.css"),n=require("../../types/analytics/analytics.cjs.js"),h=require("../../components/HighlightedTitle/HighlightedTitle.cjs.js"),y=require("../../components/Icon/Icon.cjs.js"),r=require("../../components/Typography/Typography.cjs.js"),g=require("../../components/Button/Button.cjs.js"),j=({title:t,image:o,tags:c,button:s,colorScheme:l="light"})=>{const d={event:n.EAnalyticsEvent.ctaClicked,type:n.EAnalyticsEventType.interaction,component:"YourProtocol",element:"Callback",payload:{ctaLink:(s==null?void 0:s.link)||"no_link"}},p=l==="dark"?"secondary":"primary";return e.jsx("section",{className:a.root,"data-scheme":l,children:e.jsxs("div",{className:a.container,children:[e.jsx(h.HighlightedTitle,{title:t,className:a.title,defaultVariant:"displayMd",mobileVariant:"headingXl",colorScheme:l}),c.length>0&&e.jsx("div",{className:a.tagsList,children:c.map((i,m)=>e.jsxs("div",{className:a.tagItem,children:[i.icon&&e.jsx("div",{className:a.iconWrapper,children:e.jsx(y.Icon,{name:i.icon,className:a.icon})}),e.jsxs("div",{className:a.tagText,children:[e.jsx(r.Typography,{className:a.tagLabel,as:"p",defaultVariant:"headingXs",children:i.label}),i.description&&e.jsx(r.Typography,{className:a.tagDescription,as:"p",defaultVariant:"bodyMd",children:i.description})]})]},m))}),(s==null?void 0:s.link)&&(s==null?void 0:s.label)&&e.jsx("div",{className:a.callbackButton,children:e.jsx(g.Button,{href:s.link,as:"a",analyticsProps:d,size:"lg",variant:p,children:s.label})}),e.jsx("img",{src:o,alt:"Your Protocol",className:a.image})]})})};exports.YourProtocol=j;
@@ -1,11 +1,16 @@
1
1
  import { ReactNode } from 'react';
2
- import { TCallbackView, TTagView } from './types';
2
+ import { TTagView } from './types';
3
+ import { TColorScheme } from '../../types/common';
3
4
 
4
5
  type Props = {
5
6
  title: ReactNode;
6
7
  tags: Array<TTagView>;
7
- callbackView: TCallbackView | null;
8
+ button?: {
9
+ label: string;
10
+ link: string;
11
+ };
8
12
  image: string;
13
+ colorScheme?: TColorScheme;
9
14
  };
10
- export declare const YourProtocol: ({ title, image, tags, callbackView }: Props) => import("react/jsx-runtime").JSX.Element;
15
+ export declare const YourProtocol: ({ title, image, tags, button, colorScheme }: Props) => import("react/jsx-runtime").JSX.Element;
11
16
  export {};
@@ -1,53 +1,42 @@
1
- import { jsx as r, jsxs as m } from "react/jsx-runtime";
2
- import { cn as c } from "../../utils/cn/cn.es.js";
3
- import o from "../../modules/YourProtocol/yourProtocol.module.css";
4
- import { EAnalyticsEventType as h, EAnalyticsEvent as g } from "../../types/analytics/analytics.es.js";
5
- import { HighlightedTitle as f } from "../../components/HighlightedTitle/HighlightedTitle.es.js";
6
- import { ProtocolTags as u } from "./components/ProtocolTags/ProtocolTags.es.js";
7
- import { Callback as y } from "../../components/Callback/Callback.es.js";
8
- const Y = ({ title: a, image: p, tags: d, callbackView: t }) => {
9
- var e, i, s, n;
10
- const l = {
11
- event: g.ctaClicked,
1
+ import { jsx as e, jsxs as s } from "react/jsx-runtime";
2
+ import a from "../../modules/YourProtocol/yourProtocol.module.css";
3
+ import { EAnalyticsEventType as h, EAnalyticsEvent as y } from "../../types/analytics/analytics.es.js";
4
+ import { HighlightedTitle as N } from "../../components/HighlightedTitle/HighlightedTitle.es.js";
5
+ import { Icon as f } from "../../components/Icon/Icon.es.js";
6
+ import { Typography as n } from "../../components/Typography/Typography.es.js";
7
+ import { Button as v } from "../../components/Button/Button.es.js";
8
+ const L = ({ title: o, image: m, tags: c, button: i, colorScheme: r = "light" }) => {
9
+ const d = {
10
+ event: y.ctaClicked,
12
11
  type: h.interaction,
13
12
  component: "YourProtocol",
14
13
  element: "Callback",
15
14
  payload: {
16
- ctaLink: (e = t == null ? void 0 : t.signupUrl) != null ? e : ""
15
+ ctaLink: (i == null ? void 0 : i.link) || "no_link"
17
16
  }
18
- };
19
- return /* @__PURE__ */ r("section", { className: o.root, children: /* @__PURE__ */ m("div", { className: o.container, children: [
20
- /* @__PURE__ */ m("div", { className: o.content, children: [
21
- /* @__PURE__ */ r(
22
- f,
23
- {
24
- title: a,
25
- className: o.title,
26
- defaultVariant: "displaySm",
27
- mobileVariant: "headingXl"
28
- }
29
- ),
30
- /* @__PURE__ */ r(u, { tags: d }),
31
- t && /* @__PURE__ */ r("div", { className: o.callback, children: /* @__PURE__ */ r(
32
- y,
33
- {
34
- title: t.title,
35
- description: (i = t.description) != null ? i : "",
36
- price: (s = t.price) != null ? s : "",
37
- image: t.image,
38
- button: {
39
- href: (n = t.signupUrl) != null ? n : "",
40
- as: "a",
41
- analyticsProps: l
42
- },
43
- size: "sm",
44
- shape: t.shape
45
- }
46
- ) })
47
- ] }),
48
- /* @__PURE__ */ r("img", { src: p, alt: "Your Protocol", className: c(o.image, o.desktop), width: 481 })
17
+ }, t = r === "dark" ? "secondary" : "primary";
18
+ return /* @__PURE__ */ e("section", { className: a.root, "data-scheme": r, children: /* @__PURE__ */ s("div", { className: a.container, children: [
19
+ /* @__PURE__ */ e(
20
+ N,
21
+ {
22
+ title: o,
23
+ className: a.title,
24
+ defaultVariant: "displayMd",
25
+ mobileVariant: "headingXl",
26
+ colorScheme: r
27
+ }
28
+ ),
29
+ c.length > 0 && /* @__PURE__ */ e("div", { className: a.tagsList, children: c.map((l, p) => /* @__PURE__ */ s("div", { className: a.tagItem, children: [
30
+ l.icon && /* @__PURE__ */ e("div", { className: a.iconWrapper, children: /* @__PURE__ */ e(f, { name: l.icon, className: a.icon }) }),
31
+ /* @__PURE__ */ s("div", { className: a.tagText, children: [
32
+ /* @__PURE__ */ e(n, { className: a.tagLabel, as: "p", defaultVariant: "headingXs", children: l.label }),
33
+ l.description && /* @__PURE__ */ e(n, { className: a.tagDescription, as: "p", defaultVariant: "bodyMd", children: l.description })
34
+ ] })
35
+ ] }, p)) }),
36
+ (i == null ? void 0 : i.link) && (i == null ? void 0 : i.label) && /* @__PURE__ */ e("div", { className: a.callbackButton, children: /* @__PURE__ */ e(v, { href: i.link, as: "a", analyticsProps: d, size: "lg", variant: t, children: i.label }) }),
37
+ /* @__PURE__ */ e("img", { src: m, alt: "Your Protocol", className: a.image })
49
38
  ] }) });
50
39
  };
51
40
  export {
52
- Y as YourProtocol
41
+ L as YourProtocol
53
42
  };
@@ -1,16 +1,7 @@
1
- import { CallbackShape } from '../../components/Callback';
1
+ import { EIconName } from '../../components/Icon/constants';
2
2
 
3
3
  export type TTagView = {
4
4
  label: string;
5
5
  description?: string;
6
- };
7
- export type TCallbackView = {
8
- title: string;
9
- description?: string;
10
- price: string | null;
11
- signupUrl?: string;
12
- image: string;
13
- buttonLabel: string;
14
- size: string;
15
- shape: CallbackShape;
6
+ icon?: EIconName;
16
7
  };
@@ -1,98 +1,168 @@
1
1
  .root {
2
- display: flex;
3
2
  width: 100%;
4
- align-items: center;
3
+ display: flex;
5
4
  justify-content: center;
5
+ align-items: center;
6
+ }
7
+
8
+ .root[data-scheme='dark'] {
9
+ background-color: var(--color-bg-base-dark);
6
10
  }
7
11
 
8
12
  .container {
9
13
  width: 100%;
10
- min-width: 0;
14
+ display: grid;
15
+ grid-template-columns: 1fr auto;
16
+ grid-template-rows: auto auto auto;
17
+ gap: 32px;
18
+ padding: 70px 120px;
11
19
  max-width: var(--content-max-width);
12
- display: flex;
13
- justify-content: center;
14
- align-items: flex-start;
15
- gap: var(--spacing-96);
16
- padding: var(--spacing-120);
17
- box-sizing: border-box;
20
+ align-items: start;
18
21
  }
19
22
 
20
- .content {
23
+ .title {
24
+ grid-column: 1;
25
+ grid-row: 1;
26
+ }
27
+
28
+ .tagsList {
29
+ grid-column: 1;
30
+ grid-row: 2;
21
31
  display: flex;
22
- width: 623px;
23
- min-width: 0;
24
32
  flex-direction: column;
25
- gap: var(--spacing-32);
26
- flex: 1 0 0;
27
33
  }
28
34
 
29
- .title {
30
- margin: 80px 0 0;
31
- max-width: 623px;
35
+ .callbackButton {
36
+ grid-column: 1;
37
+ grid-row: 3;
32
38
  }
33
39
 
34
40
  .image {
35
- flex-shrink: 1;
36
- width: 481px;
37
- border-radius: var(--border-radius-lg);
41
+ grid-column: 2;
42
+ grid-row: 1 / 4;
43
+ width: 477px;
44
+ height: 636px;
45
+ object-fit: cover;
46
+ border-radius: 19px;
47
+ }
48
+
49
+ .title,
50
+ .tagsList,
51
+ .callbackButton {
52
+ width: 100%;
53
+ max-width: 627px;
38
54
  }
39
55
 
40
- .mobile {
41
- display: none;
56
+ .tagItem {
57
+ padding: 16px 0;
58
+ display: flex;
59
+ gap: 16px;
60
+ border-bottom: 1px solid var(--border-color-light);
42
61
  }
43
62
 
44
- @media screen and (width <= 1300px) {
45
- .container {
46
- gap: var(--spacing-64);
47
- padding: var(--spacing-64) var(--spacing-20);
48
- }
63
+ .root[data-scheme='dark'] .tagItem {
64
+ border-bottom: 1px solid var(--border-color-alpha-white-10);
65
+ }
49
66
 
50
- .content {
51
- width: 500px;
52
- }
67
+ .tagItem:last-child {
68
+ border-bottom: none;
69
+ }
53
70
 
54
- .image {
55
- width: auto;
56
- height: 440px;
57
- }
71
+ .tagText {
72
+ display: flex;
73
+ flex-direction: column;
74
+ align-items: flex-start;
75
+ gap: 8px;
58
76
  }
59
77
 
60
- @media screen and (width <= 1024px) {
78
+ .tagLabel {
79
+ color: var(--color-text-primary);
80
+ }
81
+
82
+ .tagDescription {
83
+ color: var(--color-text-secondary);
84
+ }
85
+
86
+ /* Dark mode overrides */
87
+ .root[data-scheme='dark'] .tagLabel {
88
+ color: var(--color-text-primary-inverted);
89
+ }
90
+
91
+ .root[data-scheme='dark'] .tagDescription {
92
+ color: var(--color-text-secondary-inverted);
93
+ }
94
+
95
+ .iconWrapper {
96
+ display: flex;
97
+ width: 52px;
98
+ height: 52px;
99
+ padding: 12px;
100
+ border-radius: 7.8px;
101
+ background: var(--Gradient-01, linear-gradient(93deg, #81b1e2 8.06%, #2666a6 160.95%));
102
+ }
103
+
104
+ .root[data-scheme='dark'] .iconWrapper {
105
+ background:
106
+ linear-gradient(0deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.1) 100%),
107
+ var(--Background-fill-neutral-dark, #1a1a1a);
108
+ }
109
+
110
+ .icon {
111
+ width: 28px;
112
+ height: 28px;
113
+ color: var(--color-white);
114
+ }
115
+
116
+ @media (max-width: 1300px) {
61
117
  .container {
62
118
  grid-template-columns: 1fr;
63
- padding: var(--spacing-64) var(--spacing-20);
119
+ grid-template-rows: auto auto auto auto;
120
+ padding: 64px 17px;
64
121
  }
65
122
 
66
- .content {
123
+ .title {
124
+ grid-column: 1;
125
+ grid-row: 1;
126
+ max-width: 685px;
127
+ }
128
+
129
+ .image {
130
+ grid-column: 1;
131
+ grid-row: 2;
67
132
  width: 100%;
68
- align-items: center;
133
+ height: 350px;
69
134
  }
70
135
 
71
- .title {
72
- margin: 0;
73
- text-align: center;
136
+ .tagsList {
137
+ grid-column: 1;
138
+ grid-row: 3;
74
139
  }
75
140
 
76
- .content {
77
- gap: 16px;
141
+ .tagsList,
142
+ .callbackButton {
143
+ max-width: unset;
78
144
  }
79
145
 
80
- .callback {
81
- margin-top: var(--spacing-48);
146
+ .callbackButton {
147
+ grid-column: 1;
148
+ grid-row: 4;
82
149
  }
150
+ }
83
151
 
84
- .mobile {
85
- display: block;
152
+ @media (max-width: 768px) {
153
+ .container {
154
+ gap: 20px;
86
155
  }
87
156
 
88
- .desktop {
89
- display: none;
157
+ .tagItem {
158
+ padding: 24px 0;
90
159
  }
91
- }
92
160
 
93
- @media screen and (width <= 768px) {
94
- .callback {
95
- max-width: 513px;
96
- width: 100%;
161
+ .image {
162
+ height: 240px;
163
+ }
164
+
165
+ .title {
166
+ max-width: 335px;
97
167
  }
98
168
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zenpatient-org/healthspan-marketing-ui",
3
- "version": "0.2.40",
3
+ "version": "0.2.42",
4
4
  "description": "Design system",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.es.js",
@@ -1 +0,0 @@
1
- "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),r=require("react"),i=require("../../../../utils/cn/cn.cjs.js"),c=require("../../../../src/modules/YourProtocol/components/ProtocolTags/protocolTags.module.css"),p=require("../../../../components/Tag/Tag.cjs.js"),t=require("../../../../components/Typography/Typography.cjs.js"),m=({tags:o})=>{var n;const[a,d]=r.useState(((n=o[0])==null?void 0:n.label)||null),l=r.useMemo(()=>{var e;return(e=o.find(u=>u.label===a))==null?void 0:e.description},[a,o]);return s.jsxs("div",{className:c.root,children:[s.jsx("div",{className:c.tags,children:o.map(e=>s.jsx(p.Tag,{value:e.label,size:"md",active:e.label===a,onClick:d,children:e.label},e.label))}),l&&s.jsxs(s.Fragment,{children:[s.jsx(t.Typography,{as:"p",defaultVariant:"bodyLg",className:i.cn(c.description,c.desktop),children:l}),s.jsx(t.Typography,{as:"p",defaultVariant:"bodyMd",className:i.cn(c.description,c.mobile),children:l})]})]})};exports.ProtocolTags=m;
@@ -1,7 +0,0 @@
1
- import { TTagView } from '../../types';
2
-
3
- type Props = {
4
- tags: Array<TTagView>;
5
- };
6
- export declare const ProtocolTags: ({ tags }: Props) => import("react/jsx-runtime").JSX.Element;
7
- export {};
@@ -1,37 +0,0 @@
1
- "use client";
2
- import { jsxs as t, jsx as o, Fragment as p } from "react/jsx-runtime";
3
- import { useState as b, useMemo as f } from "react";
4
- import { cn as c } from "../../../../utils/cn/cn.es.js";
5
- import l from "../../../../modules/YourProtocol/components/ProtocolTags/protocolTags.module.css";
6
- import { Tag as u } from "../../../../components/Tag/Tag.es.js";
7
- import { Typography as n } from "../../../../components/Typography/Typography.es.js";
8
- const V = ({ tags: i }) => {
9
- var s;
10
- const [r, m] = b(((s = i[0]) == null ? void 0 : s.label) || null), a = f(
11
- () => {
12
- var e;
13
- return (e = i.find((d) => d.label === r)) == null ? void 0 : e.description;
14
- },
15
- [r, i]
16
- );
17
- return /* @__PURE__ */ t("div", { className: l.root, children: [
18
- /* @__PURE__ */ o("div", { className: l.tags, children: i.map((e) => /* @__PURE__ */ o(
19
- u,
20
- {
21
- value: e.label,
22
- size: "md",
23
- active: e.label === r,
24
- onClick: m,
25
- children: e.label
26
- },
27
- e.label
28
- )) }),
29
- a && /* @__PURE__ */ t(p, { children: [
30
- /* @__PURE__ */ o(n, { as: "p", defaultVariant: "bodyLg", className: c(l.description, l.desktop), children: a }),
31
- /* @__PURE__ */ o(n, { as: "p", defaultVariant: "bodyMd", className: c(l.description, l.mobile), children: a })
32
- ] })
33
- ] });
34
- };
35
- export {
36
- V as ProtocolTags
37
- };
@@ -1 +0,0 @@
1
- export { ProtocolTags } from './ProtocolTags';
@@ -1,37 +0,0 @@
1
- .root {
2
- display: flex;
3
- flex-direction: column;
4
- gap: var(--spacing-32);
5
- max-width: 100%;
6
- }
7
-
8
- .tags {
9
- display: flex;
10
- gap: var(--spacing-8);
11
- flex-wrap: nowrap;
12
- overflow-x: auto;
13
- scrollbar-width: none;
14
-
15
- &::-webkit-scrollbar {
16
- display: none;
17
- }
18
- }
19
-
20
- .mobile {
21
- display: none;
22
- }
23
-
24
- @media screen and (width <= 768px) {
25
- .root {
26
- margin-top: var(--spacing-20);
27
- gap: var(--spacing-16);
28
- }
29
-
30
- .mobile {
31
- display: block;
32
- }
33
-
34
- .desktop {
35
- display: none;
36
- }
37
- }