@momo-webplatform/mobase 0.2.85 → 0.2.87

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/index.js CHANGED
@@ -269,7 +269,7 @@ import*as Io from"react";import{ChevronDownIcon as Sm}from"@heroicons/react/20/s
269
269
  .list-features-2 .feature-item {
270
270
  background: linear-gradient(180deg, #FAFAFA 0%, rgba(255, 255, 255, 1) 91%);
271
271
  }
272
- `})]}),pl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-8 md:grid-cols-3 lg:gap-12",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 w-full flex-1",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),fl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x("div",{className:"grid grid-cols-1 gap-0 lg:grid-cols-10 lg:gap-12",children:[x("div",{className:"lg:col-span-4 lg:flex lg:flex-col lg:justify-center",children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"left",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:r("text-center lg:mb-0 lg:text-left",e?.className)}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:`hidden lg:flex ${t?.className}`,align:"left"})]}),x("div",{className:"lg:col-span-6",children:[o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:grid-cols-2 md:gap-5",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col rounded-lg border border-gray-200 bg-white p-5",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:`flex lg:hidden ${t?.className}`,align:"center"})]})]}),gl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features mx-auto grid max-w-4xl grid-cols-1 gap-5 md:grid-cols-2",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col rounded-lg border border-gray-200 bg-white p-7",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),ul=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-8 md:grid-cols-2 lg:grid-cols-3 lg:gap-x-7 lg:gap-y-10",children:o?.map((a,i)=>x("div",{className:"feature-item relative w-full",children:[a?.image&&f("div",{className:"h-12 w-12",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-sm text-gray-500",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),vl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>{let a=o?.length||0,i={default:"md:basis-1/5",special:"md:basis-1/4"},n={6:3,7:4,8:4},l=a>=1&&a<=4||[6,7,8].includes(a)?i.special:i.default,m=n[a]??-1,c=(d,p)=>{let g=d?.btnLink?"a":"div",v=d?.btnLink?{href:d.btnLink,target:d?.newTab?"_blank":"_self",rel:"noopener noreferrer",title:d?.btnName}:{};return f("div",{className:r("basis-1/2 px-2 lg:px-5",l,p===m&&"md:break-after-row",d?.btnLink&&"group cursor-pointer"),children:x(g,{...v,className:"feature-item relative flex w-full flex-col items-center gap-3",children:[d?.image&&f("div",{className:"h-16 w-16 transition-transform duration-300 group-hover:scale-105",children:f("img",{src:d?.image,alt:d?.name,className:"h-full w-full object-contain",loading:"lazy"})}),x("div",{className:"w-full flex-1 text-center",children:[d?.name&&f("h3",{className:"text-base duration-300 group-hover:text-pink-500",children:q(d.name)}),d?.description&&f("div",{className:"mt-2 text-sm text-gray-500",children:q(d.description)})]})]})},p)};return x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features -mx-2 flex flex-wrap justify-center gap-y-10 lg:-mx-5",children:o.map((d,p)=>c(d,p))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})},xl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:grid-cols-3",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col overflow-hidden rounded-xl bg-gray-100",children:[x("div",{className:"flex w-full flex-1 flex-col p-5",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]}),a?.image&&f("div",{className:"w-full",style:{aspectRatio:"347/220"},children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),hl=({dataHeading:e,dataFeatures:o,dataButtons:t,dataBanner:a})=>x("div",{className:"grid grid-cols-1 gap-10 lg:grid-cols-10 lg:gap-14",children:[f("div",{className:"flex items-center lg:col-span-6",children:x("div",{className:"w-full",children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"left",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:r("text-center lg:text-left",e?.className)}),o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:auto-cols-auto md:grid-cols-2",children:o?.map((i,n)=>x("div",{className:"feature-item relative flex w-full flex-col",children:[i?.image&&f("div",{className:"h-10 w-10",children:f("img",{src:i?.image,alt:i?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[i?.name&&f("h3",{className:"text-lg font-semibold",children:q(i.name)}),i?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(i.description)})]}),i?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:i.btnLink,btnName:i?.btnName,newTab:i?.newTab})})]})]},n))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"left"})]})}),a&&f("div",{className:"flex items-center lg:col-span-4",children:f("div",{className:"mx-auto w-full max-w-xs md:max-w-md",children:f(H,{ratio:a?.ratio||1,className:"w-full",children:f("img",{src:a?.src,alt:a?.alt,loading:"lazy",className:"h-full w-full object-cover"})})})})]}),bl=({dataHeading:e,dataFeatures:o,dataBanner:t,dataButtons:a})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),f("div",{className:r("relative flex items-center",t&&"lg:min-h-[590px]"),children:o&&x("div",{className:r("list-features grid grid-cols-1 gap-8 md:grid-cols-2",t?"lg:flex lg:flex-row lg:flex-wrap lg:gap-x-0 lg:gap-y-16":"mx-auto max-w-4xl"),children:[o?.map((i,n)=>x("div",{className:r("feature-item relative w-full",t&&"lg:basis-1/2 odd:lg:pr-48 even:lg:pl-48"),children:[i?.image&&f("div",{className:"h-12 w-12",children:f("img",{src:i?.image,alt:i?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[i?.name&&f("h3",{className:"text-lg font-semibold",children:q(i.name)}),i?.description&&f("div",{className:"mt-2 text-gray-500",children:q(i.description)})]}),i?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:i.btnLink,btnName:i?.btnName,newTab:i?.newTab})})]})]},n)),t&&x("div",{className:"absolute left-1/2 top-1/2 mx-auto hidden w-72 -translate-x-1/2 -translate-y-1/2 lg:flex lg:items-end lg:justify-center lg:p-1.5 xl:p-2",style:{aspectRatio:"352/721"},children:[f("div",{className:"mockup-bg pointer-events-none absolute inset-0 h-full w-full select-none",style:{background:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-240809173159-638588215193226459.png) no-repeat bottom center/contain"}}),f("div",{className:"h-full w-full overflow-hidden bg-gray-100",style:{borderRadius:"30px"},children:f("img",{src:t?.src,alt:t?.alt,className:"h-full w-full object-contain"})})]})]})}),a&&f(b,{isFullInMobile:a?.isFullInMobile,buttons:a?.buttons,className:a?.className,align:"center"})]}),yl=({dataHeading:e,dataFeatures:o,dataButtons:t,dataBanner:a})=>{let[i,n]=Mg(0),s=pa();return x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&x("div",{className:"grid grid-cols-1 gap-10 md:grid-cols-2 lg:gap-14",children:[f("div",{children:o&&f("div",{className:"list-features w-full md:border-l-2 md:border-gray-200",children:f(ct,{type:"single",collapsible:s,onValueChange:l=>{let m=parseInt(l);isNaN(m)||n(m)},defaultValue:i.toString(),children:o?.map((l,m)=>x(dt,{value:m.toString(),className:"feature-item group relative flex w-full flex-col border-y-0 border-b last:border-b-0 md:-ml-0.5 md:border-b-0 md:border-l-2 md:border-gray-200 md:pl-5 md:[&[data-state=open]]:border-pink-500",children:[f(pt,{className:"text-left text-lg font-semibold md:group-first:pt-0 md:group-last:pb-0 [&>svg]:md:hidden",children:q(l.name||"")}),x(ft,{children:[l?.description&&f("div",{className:"text-muted-foreground mb-3",children:q(l.description||"")}),l?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:l.btnLink,btnName:l?.btnName,newTab:l?.newTab})}),l?.image&&!a&&f("div",{className:"mx-auto mt-5 w-full max-w-xs md:hidden",children:f(H,{ratio:1,className:"w-full",children:f("img",{src:l?.image,alt:l?.name,className:"h-full w-full object-contain"})})})]})]},m))})})}),f("div",{className:r(a?"flex":"hidden md:flex"),children:f("div",{className:"mx-auto w-full max-w-xs md:max-w-md",children:a?f(H,{ratio:a?.ratio||1,className:"w-full",children:f("img",{src:a?.src,alt:a?.alt,loading:"lazy",className:"h-full w-full object-cover"})}):f("div",{className:"hidden md:flex",children:o?.[i]?.image?f(H,{ratio:1,className:"w-full",children:f("img",{src:o?.[i]?.image,alt:o?.[i]?.name,className:"h-full w-full object-contain",loading:"lazy"})}):f("div",{className:"h-0 w-0"})})})})]}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})};import{Fragment as Hg,jsx as ve}from"react/jsx-runtime";var Ag=({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})=>{switch(e){case 1:return ve(Ki,{dataHeading:o,dataFeatures:t,dataButtons:a});case 2:return ve(dl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 3:return ve(pl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 4:return ve(fl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 5:return ve(gl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 6:return ve(ul,{dataHeading:o,dataFeatures:t,dataButtons:a});case 7:return ve(vl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 8:return ve(xl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 9:return ve(hl,{dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i});case 10:return ve(bl,{dataHeading:o,dataFeatures:t,dataBanner:i,dataButtons:a});case 11:return ve(yl,{dataHeading:o,dataFeatures:t,dataBanner:i,dataButtons:a});default:return ve(Ki,{dataHeading:o,dataFeatures:t,dataButtons:a})}},Lg=({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})=>ve(Hg,{children:Ag({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})}),Eg=({template:e=1,background:o,className:t,idSection:a,dataHeading:i,dataFeatures:n,dataButtons:s,dataBanner:l})=>ve(O,{className:t,idSection:a,background:o,children:ve(Lg,{template:e,dataHeading:i,dataFeatures:n,dataButtons:s,dataBanner:l})});import{StarIcon as Wg}from"@heroicons/react/24/solid";import er from"html-react-parser";import Gg from"lodash";import{useEffect as zg,useState as Ji}from"react";import{animate as wl,motion as Fg,useMotionValue as _g}from"motion/react";import Bg from"react-use-measure";import{jsx as Vg,jsxs as Og}from"react/jsx-runtime";function Xa({children:e,gap:o=16,speed:t=100,speedOnHover:a,direction:i="horizontal",reverse:n=!1,className:s,classNameMotion:l}){let[m,c]=Ji(t),[d,{width:p,height:g}]=Bg(),v=_g(0),[C,M]=Ji(!1),[I,z]=Ji(0);zg(()=>{let A,N=(i==="horizontal"?p:g)+o,re=n?-N/2:0,Q=n?0:-N/2,Wt=Math.abs(Q-re)/m;if(C){let Do=Math.abs(v.get()-Q)/m;A=wl(v,[v.get(),Q],{ease:"linear",duration:Do,onComplete:()=>{M(!1),z(Cm=>Cm+1)}})}else A=wl(v,[re,Q],{ease:"linear",duration:Wt,repeat:1/0,repeatType:"loop",repeatDelay:0,onRepeat:()=>{v.set(re)}});return A?.stop},[I,v,m,p,g,o,C,i,n]);let $=a?{onHoverStart:()=>{M(!0),c(a)},onHoverEnd:()=>{M(!0),c(t)},onTouchStart:()=>{M(!0),c(a)},onTouchEnd:()=>{M(!0),c(t)}}:{};return Vg("div",{className:r("overflow-hidden",s),children:Og(Fg.div,{className:r("flex w-max",l),style:{...i==="horizontal"?{x:v,paddingLeft:o}:{y:v},gap:`${o}px`,flexDirection:i==="horizontal"?"row":"column"},ref:d,...$,children:[e,e]})})}var Ya=["bg-red-500","bg-blue-500","bg-green-500","bg-yellow-500","bg-purple-500","bg-pink-500","bg-orange-500","bg-green-700"],Za=({name:e=""})=>{let o=e?.trim()?.split(/\s+/)||[];return o?.length>1?`${o?.[o?.length-2]?.[0]?.toUpperCase()}${o?.[o?.length-1]?.[0]?.toUpperCase()}`:o?.[0]?.[0]?.toUpperCase()||""},Ka=(e,o)=>o[e%o.length];import{Fragment as Pl,jsx as ee,jsxs as Co}from"react/jsx-runtime";var $g=({avatar:e="",name:o="",index:t=0})=>{if(Gg.isEmpty(e)){let a=Za({name:o})??"",i=Ka(t,Ya);return ee("div",{className:r("flex h-9 w-9 shrink-0 items-center justify-center overflow-hidden rounded-full font-semibold text-white ",i),children:a})}return ee("div",{className:"h-9 w-9 shrink-0 overflow-hidden rounded-full",children:ee("img",{src:e,loading:"lazy",className:"h-full w-full object-cover",alt:o})})},Nl=({testimonial:e,className:o,index:t})=>ee("div",{className:r("testimonial-item",o),children:Co("div",{className:"relative h-full rounded-xl border border-gray-100 bg-white px-5 pb-10 pt-4 shadow-md sm:px-5",children:[Co("div",{className:"flex flex-nowrap items-center space-x-2",children:[ee($g,{avatar:e.avatar,name:e.name,index:t}),Co("div",{className:"min-w-0 flex-1 pl-1",children:[ee("div",{className:"overflow-hidden text-ellipsis whitespace-nowrap text-sm font-semibold text-gray-700",children:e.name}),e?.position&&ee("div",{className:"text-xs font-normal text-pink-500",children:er(e.position)})]})]}),Co("div",{className:"mt-3",children:[e?.shortTitle&&ee("div",{className:"text-sm font-bold text-gray-700",children:er(e.shortTitle)}),e?.description&&ee("div",{className:"relative mt-1 max-h-full overflow-hidden text-sm leading-normal text-gray-600",children:er(e.description)})]}),Co("div",{className:"absolute bottom-0 left-0 right-0 flex items-center justify-between space-x-2 p-4 md:px-5",children:[e?.date&&ee("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&ee("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(a,i)=>ee(Wg,{className:`h-4 w-4 ${i<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},i))})]})]})}),tr=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>{let a=o?.length??0,i=a>3;return Co(Pl,{children:[e&&ee(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),a>0&&ee(Pl,{children:i?ee("div",{className:"relative -mx-5 overflow-hidden md:mx-0",children:ee(Xa,{direction:"horizontal",speed:70,speedOnHover:.05,gap:24,className:"pb-1.5",children:o?.map((n,s)=>ee(Nl,{testimonial:n,index:s,className:"mb-2 w-64 md:w-96"},`testimonial-${s}`))})}):ee("div",{className:"-mx-5 flex snap-x snap-mandatory flex-nowrap gap-y-6 space-x-5 overflow-hidden overflow-x-auto px-5 pb-3 md:-mx-3 md:w-full md:flex-wrap md:justify-center md:space-x-0",children:o?.map((n,s)=>ee(Nl,{testimonial:n,index:s,className:"shrink-0 basis-10/12 snap-center md:px-3 lg:basis-1/3"},`testimonial-${s}`))})}),t&&ee(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})};import{StarIcon as Cl}from"@heroicons/react/24/solid";import or from"html-react-parser";import{Fragment as Ug,jsx as L,jsxs as $e}from"react/jsx-runtime";var Qg=({className:e})=>L("svg",{width:"42",height:"36",className:e,viewBox:"0 0 42 36",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:L("path",{d:"M23.8986 36V25.1748C23.8986 18.3776 25.3972 12.8392 28.3944 8.55944C31.4704 4.1958 36.0056 1.34266 42 0V8.18182C39.3183 8.85315 37.1887 10.1119 35.6113 11.958C34.0338 13.7203 33.0084 15.8601 32.5352 18.3776H39.6338V36H23.8986ZM0 36V25.1748C0 18.3776 1.49859 12.8392 4.49577 8.55944C7.57183 4.1958 12.0676 1.34266 17.9831 0V8.18182C15.3014 8.85315 13.1718 10.1119 11.5944 11.958C10.0169 13.7203 8.99155 15.8601 8.51831 18.3776H15.6169V36H0Z",fill:"#F95396"})}),jg=({testimonial:e,className:o})=>L("div",{className:r("testimonial-item shadow-small relative h-full w-full cursor-grab select-none overflow-hidden rounded-xl bg-white p-5 md:p-10",o),children:$e("div",{className:"flex h-full md:space-x-10",children:[e?.avatar&&L("div",{className:"relative hidden w-52 flex-none grow-0 items-start md:flex",children:L(H,{ratio:2/3,className:"w-full",children:L("img",{src:e?.avatar,alt:e?.name,loading:"lazy",className:"h-full w-full object-contain"})})}),$e("div",{className:"flex grow flex-col justify-between gap-y-5 md:gap-y-6",children:[$e("div",{className:"flex flex-none items-end space-x-2 md:order-2 lg:space-x-6",children:[$e("div",{className:"grow",children:[e?.name&&L("div",{className:"text-sm font-bold md:text-base",children:e.name}),e?.position&&L("div",{className:"mt-1 text-xs font-normal text-gray-500",children:or(e.position)})]}),(e?.date||Number(e?.rating)>0)&&$e("div",{className:"hidden flex-none grow-0 text-right md:grid md:grid-cols-1 md:gap-1",children:[e?.date&&L("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&L("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(t,a)=>L(Cl,{className:`h-4 w-4 flex-none ${a<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},a))})]}),e?.avatar&&L("div",{className:"relative w-28 flex-none grow-0 md:hidden",children:L(H,{ratio:2/3,className:"w-full",children:L("img",{src:e?.avatar,alt:e?.name,loading:"lazy",className:"h-full w-full object-contain"})})})]}),$e("div",{className:"flex flex-1 flex-col md:flex-none",children:[$e("div",{className:"flex-1",children:[$e("div",{className:"mb-1.5 flex flex-none space-x-3",children:[L(Qg,{className:"h-5 w-5 md:h-6 md:w-6"}),e?.shortTitle&&L("div",{className:"flex-none text-base font-medium md:text-lg",children:or(e.shortTitle)})]}),e?.description&&L("blockquote",{className:"relative flex-1 text-justify text-base",children:or(e.description)})]}),(e?.date||Number(e?.rating)>0)&&$e("div",{className:r("mt-2 flex flex-none items-center space-x-2 md:hidden",e?.date&&e?.rating?"justify-between":"justify-end"),children:[e?.date&&L("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&L("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(t,a)=>L(Cl,{className:`h-4 w-4 flex-none ${a<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},a))})]})]})]})]})}),Rl=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>$e(Ug,{children:[e&&L(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),(o??[]).length>0&&$e(we,{className:"w-full",children:[L(Ne,{classNameContent:"!overflow-visible",className:"-ml-5 md:-ml-6",children:o?.map((a,i)=>L(Pe,{className:"basis-full pl-5 md:pl-6 lg:basis-10/12 xl:basis-9/12",children:L(jg,{testimonial:a})},i))}),(o??[]).length>1&&L(xa,{className:"mt-8"})]}),t&&L(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]});import{StarIcon as qg}from"@heroicons/react/24/solid";import ar from"html-react-parser";import Xg from"lodash";import{Fragment as kl,jsx as B,jsxs as oo}from"react/jsx-runtime";var Yg=({avatar:e="",name:o="",index:t=0})=>{if(Xg.isEmpty(e)){let a=Za({name:o})??"",i=Ka(t,Ya);return B("div",{className:r("flex h-9 w-9 shrink-0 items-center justify-center overflow-hidden rounded-full font-semibold text-white",i),children:a})}return B("div",{className:"h-9 w-9 shrink-0 overflow-hidden rounded-full",children:B("img",{src:e,loading:"lazy",className:"h-full w-full object-cover",alt:o})})},Tl=({testimonial:e,className:o,index:t})=>B("div",{className:r("testimonial-item",o),children:oo("div",{className:"relative h-full rounded-xl border border-gray-100 bg-white px-5 pb-10 pt-4 shadow-md sm:px-5",children:[oo("div",{className:"flex flex-nowrap items-center space-x-2",children:[B(Yg,{avatar:e.avatar,name:e.name,index:t}),oo("div",{className:"flex-1 pl-1",children:[B("div",{className:"overflow-hidden text-ellipsis whitespace-nowrap text-sm font-semibold text-gray-700",children:e.name}),e?.position&&B("div",{className:"text-xs font-normal text-pink-500",children:ar(e.position)})]})]}),oo("div",{className:"mt-3",children:[e?.shortTitle&&B("div",{className:"text-sm font-bold text-gray-700",children:ar(e.shortTitle)}),e?.description&&B("div",{className:"relative mt-1 max-h-full overflow-hidden text-sm leading-normal text-gray-600",children:ar(e.description)})]}),oo("div",{className:"absolute bottom-0 left-0 right-0 flex items-center justify-between space-x-2 p-4 md:px-5",children:[e?.date&&B("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&B("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(a,i)=>B(qg,{className:`h-4 w-4 ${i<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},i))})]})]})}),Sl=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>{let a=o?.length??0,i=a>3,n={lg:[{reverse:!1,speed:40},{reverse:!0,speed:50},{reverse:!1,speed:30}],md:[{reverse:!1,speed:30},{reverse:!0,speed:40}],sm:[{reverse:!1,speed:30}]},s=l=>B(kl,{children:l.map((m,c)=>B(Xa,{direction:"vertical",reverse:m.reverse,speed:m.speed,speedOnHover:.05,gap:24,className:"px-0.5",classNameMotion:"w-full",children:o?.map((d,p)=>B(Tl,{testimonial:d,index:p,className:"px-0 first:pl-0 last:pr-0"},`testimonial-${c}-${p}`))},`slider-${c}`))});return oo(kl,{children:[e&&B(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),a>0&&B(so,{children:i?oo("div",{className:"mark-vertical-marquee relative h-[600px] overflow-hidden",children:[B(je,{greaterThanOrEqual:"lg",className:"grid w-full grid-cols-3 gap-6",children:s(n.lg)}),B(je,{between:["sm","lg"],className:"grid w-full grid-cols-2 gap-6",children:s(n.md)}),B(je,{between:["xs","sm"],className:"grid w-full grid-cols-1 gap-6",children:s(n.sm)})]}):B("div",{className:"flex w-full flex-wrap justify-center gap-y-6 md:-mx-3",children:o?.map((l,m)=>B(Tl,{testimonial:l,index:m,className:"basis-full md:basis-1/2 md:px-3 lg:basis-1/3"},`testimonial-${m}`))})}),t&&B(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"}),B("style",{children:`
272
+ `})]}),pl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-8 md:grid-cols-3 lg:gap-12",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 w-full flex-1",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),fl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x("div",{className:"grid grid-cols-1 gap-0 lg:grid-cols-10 lg:gap-12",children:[x("div",{className:"lg:col-span-4 lg:flex lg:flex-col lg:justify-center",children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"left",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:r("text-center lg:mb-0 lg:text-left",e?.className)}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:`hidden lg:flex ${t?.className}`,align:"left"})]}),x("div",{className:"lg:col-span-6",children:[o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:grid-cols-2 md:gap-5",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col rounded-lg border border-gray-200 bg-white p-5",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:`flex lg:hidden ${t?.className}`,align:"center"})]})]}),gl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features mx-auto grid max-w-4xl grid-cols-1 gap-5 md:grid-cols-2",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col rounded-lg border border-gray-200 bg-white p-7",children:[a?.image&&f("div",{className:"h-16 w-16",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-4 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),ul=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-8 md:grid-cols-2 lg:grid-cols-3 lg:gap-x-7 lg:gap-y-10",children:o?.map((a,i)=>x("div",{className:"feature-item relative w-full",children:[a?.image&&f("div",{className:"h-12 w-12",children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-sm text-gray-500",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),vl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>{let a=o?.length||0,i={default:"md:basis-1/5",special:"md:basis-1/4"},n={6:3,7:4,8:4},l=a>=1&&a<=4||[6,7,8].includes(a)?i.special:i.default,m=n[a]??-1,c=(d,p)=>{let g=d?.btnLink?"a":"div",v=d?.btnLink?{href:d.btnLink,target:d?.newTab?"_blank":"_self",rel:"noopener noreferrer",title:d?.btnName}:{};return f("div",{className:r("basis-1/2 px-2 lg:px-5",l,p===m&&"md:break-after-row",d?.btnLink&&"group cursor-pointer"),children:x(g,{...v,className:"feature-item relative flex w-full flex-col items-center gap-3",children:[d?.image&&f("div",{className:"h-16 w-16 transition-transform duration-300 group-hover:scale-105",children:f("img",{src:d?.image,alt:d?.name,className:"h-full w-full object-contain",loading:"lazy"})}),x("div",{className:"w-full flex-1 text-center",children:[d?.name&&f("h3",{className:"text-base duration-300 group-hover:text-pink-500",children:q(d.name)}),d?.description&&f("div",{className:"mt-2 text-sm text-gray-500",children:q(d.description)})]})]})},p)};return x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features -mx-2 flex flex-wrap justify-center gap-y-10 lg:-mx-5",children:o.map((d,p)=>c(d,p))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})},xl=({dataHeading:e,dataFeatures:o,dataButtons:t})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:grid-cols-3",children:o?.map((a,i)=>x("div",{className:"feature-item relative flex w-full flex-col overflow-hidden rounded-xl bg-gray-100",children:[x("div",{className:"flex w-full flex-1 flex-col p-5",children:[x("div",{className:"flex-1",children:[a?.name&&f("h3",{className:"text-lg font-semibold",children:q(a.name)}),a?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(a.description)})]}),a?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:a.btnLink,btnName:a?.btnName,newTab:a?.newTab})})]}),a?.image&&f("div",{className:"w-full",style:{aspectRatio:"347/220"},children:f("img",{src:a?.image,alt:a?.name,className:"h-full w-full object-contain"})})]},i))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]}),hl=({dataHeading:e,dataFeatures:o,dataButtons:t,dataBanner:a})=>x("div",{className:"grid grid-cols-1 gap-10 lg:grid-cols-10 lg:gap-14",children:[f("div",{className:"flex items-center lg:col-span-6",children:x("div",{className:"w-full",children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"left",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:r("text-center lg:text-left",e?.className)}),o&&f("div",{className:"list-features grid grid-cols-1 gap-6 md:auto-cols-auto md:grid-cols-2",children:o?.map((i,n)=>x("div",{className:"feature-item relative flex w-full flex-col",children:[i?.image&&f("div",{className:"h-10 w-10",children:f("img",{src:i?.image,alt:i?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[i?.name&&f("h3",{className:"text-lg font-semibold",children:q(i.name)}),i?.description&&f("div",{className:"mt-2 text-base text-gray-600",children:q(i.description)})]}),i?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:i.btnLink,btnName:i?.btnName,newTab:i?.newTab})})]})]},n))}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"left"})]})}),a&&f("div",{className:"flex items-center lg:col-span-4",children:f("div",{className:"mx-auto w-full max-w-xs md:max-w-md",children:f(H,{ratio:a?.ratio||1,className:"w-full",children:f("img",{src:a?.src,alt:a?.alt,loading:"lazy",className:"h-full w-full object-cover"})})})})]}),bl=({dataHeading:e,dataFeatures:o,dataBanner:t,dataButtons:a})=>x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),f("div",{className:r("relative flex items-center",t&&"lg:min-h-[590px]"),children:o&&x("div",{className:r("list-features grid grid-cols-1 gap-8 md:grid-cols-2",t?"lg:flex lg:flex-row lg:flex-wrap lg:gap-x-0 lg:gap-y-16":"mx-auto max-w-4xl"),children:[o?.map((i,n)=>x("div",{className:r("feature-item relative w-full",t&&"lg:basis-1/2 odd:lg:pr-48 even:lg:pl-48"),children:[i?.image&&f("div",{className:"h-12 w-12",children:f("img",{src:i?.image,alt:i?.name,className:"h-full w-full object-contain"})}),x("div",{className:"mt-3 flex w-full flex-1 flex-col",children:[x("div",{className:"flex-1",children:[i?.name&&f("h3",{className:"text-lg font-semibold",children:q(i.name)}),i?.description&&f("div",{className:"mt-2 text-gray-500",children:q(i.description)})]}),i?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:i.btnLink,btnName:i?.btnName,newTab:i?.newTab})})]})]},n)),t&&x("div",{className:"absolute left-1/2 top-1/2 mx-auto hidden w-72 -translate-x-1/2 -translate-y-1/2 lg:flex lg:items-end lg:justify-center lg:p-1.5 xl:p-2",style:{aspectRatio:"352/721"},children:[f("div",{className:"mockup-bg pointer-events-none absolute inset-0 h-full w-full select-none",style:{background:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-240809173159-638588215193226459.png) no-repeat bottom center/contain"}}),f("div",{className:"h-full w-full overflow-hidden bg-gray-100",style:{borderRadius:"30px"},children:f("img",{src:t?.src,alt:t?.alt,className:"h-full w-full object-contain"})})]})]})}),a&&f(b,{isFullInMobile:a?.isFullInMobile,buttons:a?.buttons,className:a?.className,align:"center"})]}),yl=({dataHeading:e,dataFeatures:o,dataButtons:t,dataBanner:a})=>{let[i,n]=Mg(0),s=pa();return x(Tt,{children:[e&&f(h,{tagline:e?.tagline,title:e?.title,description:e?.description,tagHeading:e?.tagHeading,align:"center",colorScheme:e?.colorScheme||"pink",sizeHeading:e?.sizeHeading,className:e?.className}),o&&x("div",{className:"grid grid-cols-1 gap-10 md:grid-cols-2 lg:gap-14",children:[f("div",{children:f("div",{className:"list-features w-full md:border-l-2 md:border-gray-200",children:f(ct,{type:"single",collapsible:s,onValueChange:l=>{let m=parseInt(l);isNaN(m)||n(m)},defaultValue:i.toString(),children:o?.map((l,m)=>x(dt,{value:m.toString(),className:"feature-item group relative flex w-full flex-col border-y-0 border-b last:border-b-0 md:-ml-0.5 md:border-b-0 md:border-l-2 md:border-gray-200 md:pl-5 md:[&[data-state=open]]:border-pink-500",children:[f(pt,{className:"text-left text-lg font-semibold md:group-first:pt-0 md:group-last:pb-0 [&>svg]:md:hidden",children:q(l.name||"")}),x(ft,{children:[l?.description&&f("div",{className:"text-muted-foreground mb-3",children:q(l.description||"")}),l?.btnLink&&f("div",{className:"mt-4",children:f(rt,{btnLink:l.btnLink,btnName:l?.btnName,newTab:l?.newTab})}),l?.image&&!a?.src&&f("div",{className:"mx-auto mt-5 w-full max-w-xs md:hidden",children:f(H,{ratio:1,className:"w-full",children:f("img",{src:l?.image,alt:l?.name,className:"h-full w-full object-contain"})})})]})]},m))})})}),f("div",{className:r(a?.src?"flex":"hidden md:flex"),children:f("div",{className:"mx-auto w-full max-w-xs md:max-w-md",children:a?.src?f(H,{ratio:a?.ratio||1,className:"w-full",children:f("img",{src:a?.src,alt:a?.alt,loading:"lazy",className:"h-full w-full object-cover"})}):f("div",{className:"hidden md:flex",children:o?.[i]?.image?f(H,{ratio:1,className:"w-full",children:f("img",{src:o?.[i]?.image,alt:o?.[i]?.name,className:"h-full w-full object-contain",loading:"lazy"})}):f("div",{className:"h-0 w-0"})})})})]}),t&&f(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})};import{Fragment as Hg,jsx as ve}from"react/jsx-runtime";var Ag=({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})=>{switch(e){case 1:return ve(Ki,{dataHeading:o,dataFeatures:t,dataButtons:a});case 2:return ve(dl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 3:return ve(pl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 4:return ve(fl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 5:return ve(gl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 6:return ve(ul,{dataHeading:o,dataFeatures:t,dataButtons:a});case 7:return ve(vl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 8:return ve(xl,{dataHeading:o,dataFeatures:t,dataButtons:a});case 9:return ve(hl,{dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i});case 10:return ve(bl,{dataHeading:o,dataFeatures:t,dataBanner:i,dataButtons:a});case 11:return ve(yl,{dataHeading:o,dataFeatures:t,dataBanner:i,dataButtons:a});default:return ve(Ki,{dataHeading:o,dataFeatures:t,dataButtons:a})}},Lg=({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})=>ve(Hg,{children:Ag({template:e,dataHeading:o,dataFeatures:t,dataButtons:a,dataBanner:i})}),Eg=({template:e=1,background:o,className:t,idSection:a,dataHeading:i,dataFeatures:n,dataButtons:s,dataBanner:l})=>ve(O,{className:t,idSection:a,background:o,children:ve(Lg,{template:e,dataHeading:i,dataFeatures:n,dataButtons:s,dataBanner:l})});import{StarIcon as Wg}from"@heroicons/react/24/solid";import er from"html-react-parser";import Gg from"lodash";import{useEffect as zg,useState as Ji}from"react";import{animate as wl,motion as Fg,useMotionValue as _g}from"motion/react";import Bg from"react-use-measure";import{jsx as Vg,jsxs as Og}from"react/jsx-runtime";function Xa({children:e,gap:o=16,speed:t=100,speedOnHover:a,direction:i="horizontal",reverse:n=!1,className:s,classNameMotion:l}){let[m,c]=Ji(t),[d,{width:p,height:g}]=Bg(),v=_g(0),[C,M]=Ji(!1),[I,z]=Ji(0);zg(()=>{let A,N=(i==="horizontal"?p:g)+o,re=n?-N/2:0,Q=n?0:-N/2,Wt=Math.abs(Q-re)/m;if(C){let Do=Math.abs(v.get()-Q)/m;A=wl(v,[v.get(),Q],{ease:"linear",duration:Do,onComplete:()=>{M(!1),z(Cm=>Cm+1)}})}else A=wl(v,[re,Q],{ease:"linear",duration:Wt,repeat:1/0,repeatType:"loop",repeatDelay:0,onRepeat:()=>{v.set(re)}});return A?.stop},[I,v,m,p,g,o,C,i,n]);let $=a?{onHoverStart:()=>{M(!0),c(a)},onHoverEnd:()=>{M(!0),c(t)},onTouchStart:()=>{M(!0),c(a)},onTouchEnd:()=>{M(!0),c(t)}}:{};return Vg("div",{className:r("overflow-hidden",s),children:Og(Fg.div,{className:r("flex w-max",l),style:{...i==="horizontal"?{x:v,paddingLeft:o}:{y:v},gap:`${o}px`,flexDirection:i==="horizontal"?"row":"column"},ref:d,...$,children:[e,e]})})}var Ya=["bg-red-500","bg-blue-500","bg-green-500","bg-yellow-500","bg-purple-500","bg-pink-500","bg-orange-500","bg-green-700"],Za=({name:e=""})=>{let o=e?.trim()?.split(/\s+/)||[];return o?.length>1?`${o?.[o?.length-2]?.[0]?.toUpperCase()}${o?.[o?.length-1]?.[0]?.toUpperCase()}`:o?.[0]?.[0]?.toUpperCase()||""},Ka=(e,o)=>o[e%o.length];import{Fragment as Pl,jsx as ee,jsxs as Co}from"react/jsx-runtime";var $g=({avatar:e="",name:o="",index:t=0})=>{if(Gg.isEmpty(e)){let a=Za({name:o})??"",i=Ka(t,Ya);return ee("div",{className:r("flex h-9 w-9 shrink-0 items-center justify-center overflow-hidden rounded-full font-semibold text-white ",i),children:a})}return ee("div",{className:"h-9 w-9 shrink-0 overflow-hidden rounded-full",children:ee("img",{src:e,loading:"lazy",className:"h-full w-full object-cover",alt:o})})},Nl=({testimonial:e,className:o,index:t})=>ee("div",{className:r("testimonial-item",o),children:Co("div",{className:"relative h-full rounded-xl border border-gray-100 bg-white px-5 pb-10 pt-4 shadow-md sm:px-5",children:[Co("div",{className:"flex flex-nowrap items-center space-x-2",children:[ee($g,{avatar:e.avatar,name:e.name,index:t}),Co("div",{className:"min-w-0 flex-1 pl-1",children:[ee("div",{className:"overflow-hidden text-ellipsis whitespace-nowrap text-sm font-semibold text-gray-700",children:e.name}),e?.position&&ee("div",{className:"text-xs font-normal text-pink-500",children:er(e.position)})]})]}),Co("div",{className:"mt-3",children:[e?.shortTitle&&ee("div",{className:"text-sm font-bold text-gray-700",children:er(e.shortTitle)}),e?.description&&ee("div",{className:"relative mt-1 max-h-full overflow-hidden text-sm leading-normal text-gray-600",children:er(e.description)})]}),Co("div",{className:"absolute bottom-0 left-0 right-0 flex items-center justify-between space-x-2 p-4 md:px-5",children:[e?.date&&ee("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&ee("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(a,i)=>ee(Wg,{className:`h-4 w-4 ${i<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},i))})]})]})}),tr=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>{let a=o?.length??0,i=a>3;return Co(Pl,{children:[e&&ee(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),a>0&&ee(Pl,{children:i?ee("div",{className:"relative -mx-5 overflow-hidden md:mx-0",children:ee(Xa,{direction:"horizontal",speed:70,speedOnHover:.05,gap:24,className:"pb-1.5",children:o?.map((n,s)=>ee(Nl,{testimonial:n,index:s,className:"mb-2 w-64 md:w-96"},`testimonial-${s}`))})}):ee("div",{className:"-mx-5 flex snap-x snap-mandatory flex-nowrap gap-y-6 space-x-5 overflow-hidden overflow-x-auto px-5 pb-3 md:-mx-3 md:w-full md:flex-wrap md:justify-center md:space-x-0",children:o?.map((n,s)=>ee(Nl,{testimonial:n,index:s,className:"shrink-0 basis-10/12 snap-center md:px-3 lg:basis-1/3"},`testimonial-${s}`))})}),t&&ee(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]})};import{StarIcon as Cl}from"@heroicons/react/24/solid";import or from"html-react-parser";import{Fragment as Ug,jsx as L,jsxs as $e}from"react/jsx-runtime";var Qg=({className:e})=>L("svg",{width:"42",height:"36",className:e,viewBox:"0 0 42 36",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:L("path",{d:"M23.8986 36V25.1748C23.8986 18.3776 25.3972 12.8392 28.3944 8.55944C31.4704 4.1958 36.0056 1.34266 42 0V8.18182C39.3183 8.85315 37.1887 10.1119 35.6113 11.958C34.0338 13.7203 33.0084 15.8601 32.5352 18.3776H39.6338V36H23.8986ZM0 36V25.1748C0 18.3776 1.49859 12.8392 4.49577 8.55944C7.57183 4.1958 12.0676 1.34266 17.9831 0V8.18182C15.3014 8.85315 13.1718 10.1119 11.5944 11.958C10.0169 13.7203 8.99155 15.8601 8.51831 18.3776H15.6169V36H0Z",fill:"#F95396"})}),jg=({testimonial:e,className:o})=>L("div",{className:r("testimonial-item shadow-small relative h-full w-full cursor-grab select-none overflow-hidden rounded-xl bg-white p-5 md:p-10",o),children:$e("div",{className:"flex h-full md:space-x-10",children:[e?.avatar&&L("div",{className:"relative hidden w-52 flex-none grow-0 items-start md:flex",children:L(H,{ratio:2/3,className:"w-full",children:L("img",{src:e?.avatar,alt:e?.name,loading:"lazy",className:"h-full w-full object-contain"})})}),$e("div",{className:"flex grow flex-col justify-between gap-y-5 md:gap-y-6",children:[$e("div",{className:"flex flex-none items-end space-x-2 md:order-2 lg:space-x-6",children:[$e("div",{className:"grow",children:[e?.name&&L("div",{className:"text-sm font-bold md:text-base",children:e.name}),e?.position&&L("div",{className:"mt-1 text-xs font-normal text-gray-500",children:or(e.position)})]}),(e?.date||Number(e?.rating)>0)&&$e("div",{className:"hidden flex-none grow-0 text-right md:grid md:grid-cols-1 md:gap-1",children:[e?.date&&L("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&L("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(t,a)=>L(Cl,{className:`h-4 w-4 flex-none ${a<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},a))})]}),e?.avatar&&L("div",{className:"relative w-28 flex-none grow-0 md:hidden",children:L(H,{ratio:2/3,className:"w-full",children:L("img",{src:e?.avatar,alt:e?.name,loading:"lazy",className:"h-full w-full object-contain"})})})]}),$e("div",{className:"flex flex-1 flex-col md:flex-none",children:[$e("div",{className:"flex-1",children:[$e("div",{className:"mb-1.5 flex flex-none space-x-3",children:[L(Qg,{className:"h-5 w-5 md:h-6 md:w-6"}),e?.shortTitle&&L("div",{className:"flex-none text-base font-medium md:text-lg",children:or(e.shortTitle)})]}),e?.description&&L("blockquote",{className:"relative flex-1 text-justify text-base",children:or(e.description)})]}),(e?.date||Number(e?.rating)>0)&&$e("div",{className:r("mt-2 flex flex-none items-center space-x-2 md:hidden",e?.date&&e?.rating?"justify-between":"justify-end"),children:[e?.date&&L("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&L("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(t,a)=>L(Cl,{className:`h-4 w-4 flex-none ${a<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},a))})]})]})]})]})}),Rl=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>$e(Ug,{children:[e&&L(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),(o??[]).length>0&&$e(we,{className:"w-full",children:[L(Ne,{classNameContent:"!overflow-visible",className:"-ml-5 md:-ml-6",children:o?.map((a,i)=>L(Pe,{className:"basis-full pl-5 md:pl-6 lg:basis-10/12 xl:basis-9/12",children:L(jg,{testimonial:a})},i))}),(o??[]).length>1&&L(xa,{className:"mt-8"})]}),t&&L(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"})]});import{StarIcon as qg}from"@heroicons/react/24/solid";import ar from"html-react-parser";import Xg from"lodash";import{Fragment as kl,jsx as B,jsxs as oo}from"react/jsx-runtime";var Yg=({avatar:e="",name:o="",index:t=0})=>{if(Xg.isEmpty(e)){let a=Za({name:o})??"",i=Ka(t,Ya);return B("div",{className:r("flex h-9 w-9 shrink-0 items-center justify-center overflow-hidden rounded-full font-semibold text-white",i),children:a})}return B("div",{className:"h-9 w-9 shrink-0 overflow-hidden rounded-full",children:B("img",{src:e,loading:"lazy",className:"h-full w-full object-cover",alt:o})})},Tl=({testimonial:e,className:o,index:t})=>B("div",{className:r("testimonial-item",o),children:oo("div",{className:"relative h-full rounded-xl border border-gray-100 bg-white px-5 pb-10 pt-4 shadow-md sm:px-5",children:[oo("div",{className:"flex flex-nowrap items-center space-x-2",children:[B(Yg,{avatar:e.avatar,name:e.name,index:t}),oo("div",{className:"flex-1 pl-1",children:[B("div",{className:"overflow-hidden text-ellipsis whitespace-nowrap text-sm font-semibold text-gray-700",children:e.name}),e?.position&&B("div",{className:"text-xs font-normal text-pink-500",children:ar(e.position)})]})]}),oo("div",{className:"mt-3",children:[e?.shortTitle&&B("div",{className:"text-sm font-bold text-gray-700",children:ar(e.shortTitle)}),e?.description&&B("div",{className:"relative mt-1 max-h-full overflow-hidden text-sm leading-normal text-gray-600",children:ar(e.description)})]}),oo("div",{className:"absolute bottom-0 left-0 right-0 flex items-center justify-between space-x-2 p-4 md:px-5",children:[e?.date&&B("div",{className:"text-xs text-gray-400",children:e.date}),Number(e?.rating)>0&&B("div",{className:"flex flex-nowrap space-x-0.5 text-sm",children:Array.from({length:5},(a,i)=>B(qg,{className:`h-4 w-4 ${i<Number(e.rating)?"text-yellow-400":"text-gray-200"}`},i))})]})]})}),Sl=({dataHeading:e,dataTestimonials:o,dataButtons:t})=>{let a=o?.length??0,i=a>3,n={lg:[{reverse:!1,speed:40},{reverse:!0,speed:50},{reverse:!1,speed:30}],md:[{reverse:!1,speed:30},{reverse:!0,speed:40}],sm:[{reverse:!1,speed:30}]},s=l=>B(kl,{children:l.map((m,c)=>B(Xa,{direction:"vertical",reverse:m.reverse,speed:m.speed,speedOnHover:.05,gap:24,className:"px-0.5",classNameMotion:"w-full",children:o?.map((d,p)=>B(Tl,{testimonial:d,index:p,className:"px-0 first:pl-0 last:pr-0"},`testimonial-${c}-${p}`))},`slider-${c}`))});return oo(kl,{children:[e&&B(h,{tagline:e.tagline,title:e.title,description:e.description,tagHeading:e.tagHeading,align:"center",colorScheme:e.colorScheme||"pink",sizeHeading:e.sizeHeading,className:e.className}),a>0&&B(so,{children:i?oo("div",{className:"mark-vertical-marquee relative h-[600px] overflow-hidden",children:[B(je,{greaterThanOrEqual:"lg",className:"grid w-full grid-cols-3 gap-6",children:s(n.lg)}),B(je,{between:["sm","lg"],className:"grid w-full grid-cols-2 gap-6",children:s(n.md)}),B(je,{between:["xs","sm"],className:"grid w-full grid-cols-1 gap-6",children:s(n.sm)})]}):B("div",{className:"flex w-full flex-wrap justify-center gap-y-6 md:-mx-3",children:o?.map((l,m)=>B(Tl,{testimonial:l,index:m,className:"basis-full md:basis-1/2 md:px-3 lg:basis-1/3"},`testimonial-${m}`))})}),t&&B(b,{isFullInMobile:t?.isFullInMobile,buttons:t?.buttons,className:t?.className,align:"center"}),B("style",{children:`
273
273
  .mark-vertical-marquee {
274
274
  mask: linear-gradient(transparent, black 16px, black calc(100% - 16px), transparent);
275
275
  }
@@ -304,12 +304,11 @@ import*as Io from"react";import{ChevronDownIcon as Sm}from"@heroicons/react/20/s
304
304
  .animate-caret-blink {
305
305
  animation: caret-blink 1.25s ease-out infinite;
306
306
  }
307
- `})]})]})});tm.displayName="InputOTPSlot";var om=no.forwardRef(({...e},o)=>So("div",{ref:o,role:"separator",...e,children:So(c0,{className:"text-gray-400"})}));om.displayName="InputOTPSeparator";import{useEffect as nm,useRef as h0,useState as sm}from"react";import{toPng as b0}from"html-to-image";import ca from"react";import{LucideMessageCircleQuestion as f0}from"lucide-react";import{QRCodeSVG as g0}from"qrcode.react";async function am(e){return new Promise((o,t)=>{let a=new window.Image;a.crossOrigin="Anonymous",a.onload=function(){let i=document.createElement("canvas");i.width=a.width,i.height=a.height;let n=i.getContext("2d");if(!n){t("Kh\xF4ng l\u1EA5y \u0111\u01B0\u1EE3c context c\u1EE7a canvas");return}n.drawImage(a,0,0);let s=i.toDataURL("image/png");o(s)},a.onerror=function(i){t(i)},a.src=e})}import{jsx as Qe,jsxs as Ot}from"react/jsx-runtime";var d0=({isQrForAll:e=!1,shortTitle:o,className:t=""})=>Ot("div",{className:`grid grid-cols-1 gap-y-6 py-8 text-sm ${t}`,children:[Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917091602-637359309621891617.png",alt:"Step 1"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 1 :"}),Qe("div",{className:"mt-1 text-gray-500",children:e?"M\u1EDF app MoMo ho\u1EB7c \u1EE9ng d\u1EE5ng ng\xE2n h\xE0ng/v\xED \u0111i\u1EC7n t\u1EED ch\u1EA5p nh\u1EADn m\xE3 v\u1EA1ch t\u1EEB QR \u0110a N\u0103ng":"M\u1EDF \u1EE9ng d\u1EE5ng camera m\u1EB7c \u0111\u1ECBnh ho\u1EB7c \u1EE9ng d\u1EE5ng h\u1ED7 tr\u1EE3 QR code c\u1EE7a b\u1EA1n"})]})]}),Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917091443-637359308837905996.png",alt:"Step 2"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 2 :"}),Qe("div",{className:"mt-1 text-gray-500",children:"Qu\xE9t m\xE3 QR Code theo h\xECnh b\xEAn ph\u1EA3i"})]})]}),Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917090146-637359301062519803.png",alt:"Step 3"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 3 :"}),Ot("div",{className:"mt-1 text-gray-500",children:["B\u1EA5m v\xE0o th\xF4ng b\xE1o hi\u1EC3n th\u1ECB \u0111\u1EC3 t\u1EA3i \u1EE9ng d\u1EE5ng ho\u1EB7c ",o||"Truy c\u1EADp ngay"]})]})]})]}),gr=d0;import{jsx as ma,jsxs as im}from"react/jsx-runtime";var p0=({children:e,title:o="H\u01B0\u1EDBng d\u1EABn thanh to\xE1n",isQrForAll:t=!1,shortTitle:a,open:i,onOpenChange:n})=>im(_e,{open:i,onOpenChange:n,children:[ma(Lo,{asChild:!0,children:e}),im(Ie,{position:"bottom",children:[ma(co,{children:ma(po,{children:o})}),ma(qe,{children:ma(gr,{isQrForAll:t,shortTitle:a})})]})]}),ur=p0;import{Fragment as ti,jsx as P,jsxs as me}from"react/jsx-runtime";var u0=({img:e="",children:o,isQrForAll:t,onQrLoaded:a,dateExpired:i,priceOrder:n})=>me(ti,{children:[me("div",{className:"qrcode__scan__container relative h-[350px] select-none md:h-[280px]",children:[me("div",{className:"flex w-full items-center justify-center space-x-2 md:hidden",children:[P("img",{src:"https://homepage.momocdn.net/pwa/images/logoMomox50.png",width:28,height:28,alt:"QR all",className:"shrink-0 select-none"}),P("div",{className:"h-[14px] w-[2px] shrink-0 select-none bg-gray-200"}),P("img",{src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250711102030-638878260300337990.png",width:56,height:56,alt:"QR all",className:"shrink-0 select-none"})]}),me("div",{className:"qrcode__scan",children:[P("div",{className:"qrcode__gradient invisible select-none opacity-0 md:visible md:opacity-100",children:P("img",{alt:"step 1",className:"img-fluid",src:"https://homepage.momocdn.net/jk/momo2020/img/qrcode/qrcode-gradient.png"})}),P("div",{className:"qrcode__border invisible select-none opacity-0 md:visible md:opacity-100",children:P("img",{alt:"step 2",className:"img-fluid",src:"https://homepage.momocdn.net/jk/momo2020/img/qrcode/border-qrcode.svg"})}),P("div",{className:"qrcode__image select-none p-4",children:e?P("img",{alt:"step 3",className:"img-fluid d-block mx-auto",src:e,loading:"lazy",onLoad:a}):ca.Children.map(o,s=>(ca.isValidElement(s),s))})]}),n&&me("div",{className:"text-sm text-gray-900 md:hidden",children:[P("div",{className:"",children:"Th\xF4ng tin thanh to\xE1n"}),P("div",{className:"text-base font-bold text-gray-900",children:n})]})]}),i&&me("div",{className:r("mt-3 text-sm text-gray-900 md:hidden"),children:[P("span",{children:"M\xE3 h\u1EBFt h\u1EA1n v\xE0o: "}),P("span",{className:"font-semibold",children:i})]}),P("div",{className:"mt-4 hidden text-sm font-semibold text-gray-900 md:block",children:t?me(ti,{children:[P("img",{src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250710143736-638877550567721225.png",width:220,height:28,className:"mx-auto",alt:"QR all"}),P("div",{className:"mt-3",children:"Nh\u1EADn ti\u1EC1n t\u1EEB m\u1ECDi V\xED \u0110i\u1EC7n T\u1EED v\xE0 Ng\xE2n H\xE0ng"})]}):me(ti,{children:[P("svg",{xmlns:"http://www.w3.org/2000/svg",className:"mr-1 inline h-6 w-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:P("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v1m6 11h2m-6 0h-2v4m0-11v3m0 0h.01M12 12h4.01M16 20h4M4 12h4m12 0h.01M5 8h2a1 1 0 001-1V5a1 1 0 00-1-1H5a1 1 0 00-1 1v2a1 1 0 001 1zm12 0h2a1 1 0 001-1V5a1 1 0 00-1-1h-2a1 1 0 00-1 1v2a1 1 0 001 1zM5 20h2a1 1 0 001-1v-2a1 1 0 00-1-1H5a1 1 0 00-1 1v2a1 1 0 001 1z"})}),"S\u1EED d\u1EE5ng App MoMo ho\u1EB7c",P("br",{}),"\u1EE9ng d\u1EE5ng Camera h\u1ED7 tr\u1EE3 QR code \u0111\u1EC3 qu\xE9t m\xE3."]})})]}),v0=({img:e="",children:o,isQrForAll:t,onQrLoaded:a,qrImageBase64:i,dateExpired:n,priceOrder:s})=>me(ti,{children:[P("div",{className:r(i&&"opacity-0 md:opacity-100"),children:P(u0,{dateExpired:n,priceOrder:s,img:e,isQrForAll:t,onQrLoaded:a,children:o})}),P("style",{children:`
307
+ `})]})]})});tm.displayName="InputOTPSlot";var om=no.forwardRef(({...e},o)=>So("div",{ref:o,role:"separator",...e,children:So(c0,{className:"text-gray-400"})}));om.displayName="InputOTPSeparator";import{useEffect as nm,useRef as h0,useState as sm}from"react";import{toPng as b0}from"html-to-image";import ca from"react";import{LucideMessageCircleQuestion as f0}from"lucide-react";import{QRCodeSVG as g0}from"qrcode.react";async function am(e){return new Promise((o,t)=>{let a=new window.Image;a.crossOrigin="Anonymous",a.onload=function(){let i=document.createElement("canvas");i.width=a.width,i.height=a.height;let n=i.getContext("2d");if(!n){t("Kh\xF4ng l\u1EA5y \u0111\u01B0\u1EE3c context c\u1EE7a canvas");return}n.drawImage(a,0,0);let s=i.toDataURL("image/png");o(s)},a.onerror=function(i){t(i)},a.src=e})}import{jsx as Qe,jsxs as Ot}from"react/jsx-runtime";var d0=({isQrForAll:e=!1,shortTitle:o,className:t=""})=>Ot("div",{className:`grid grid-cols-1 gap-y-6 py-8 text-sm ${t}`,children:[Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917091602-637359309621891617.png",alt:"Step 1"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 1 :"}),Qe("div",{className:"mt-1 text-gray-500",children:e?"M\u1EDF app MoMo ho\u1EB7c \u1EE9ng d\u1EE5ng ng\xE2n h\xE0ng/v\xED \u0111i\u1EC7n t\u1EED ch\u1EA5p nh\u1EADn m\xE3 v\u1EA1ch t\u1EEB QR \u0110a N\u0103ng":"M\u1EDF \u1EE9ng d\u1EE5ng camera m\u1EB7c \u0111\u1ECBnh ho\u1EB7c \u1EE9ng d\u1EE5ng h\u1ED7 tr\u1EE3 QR code c\u1EE7a b\u1EA1n"})]})]}),Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917091443-637359308837905996.png",alt:"Step 2"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 2 :"}),Qe("div",{className:"mt-1 text-gray-500",children:"Qu\xE9t m\xE3 QR Code theo h\xECnh b\xEAn ph\u1EA3i"})]})]}),Ot("div",{className:"flex flex-nowrap items-center",children:[Qe("div",{className:"relative aspect-[2/3] flex-none overflow-hidden",children:Qe("img",{className:"w-20",loading:"lazy",src:"https://homepage.momocdn.net/images/s/momo-upload-api-200917090146-637359301062519803.png",alt:"Step 3"})}),Ot("div",{className:"flex-1 pl-4",children:[Qe("div",{className:"step font-semibold text-gray-800",children:"B\u01B0\u1EDBc 3 :"}),Ot("div",{className:"mt-1 text-gray-500",children:["B\u1EA5m v\xE0o th\xF4ng b\xE1o hi\u1EC3n th\u1ECB \u0111\u1EC3 t\u1EA3i \u1EE9ng d\u1EE5ng ho\u1EB7c ",o||"Truy c\u1EADp ngay"]})]})]})]}),gr=d0;import{jsx as ma,jsxs as im}from"react/jsx-runtime";var p0=({children:e,title:o="H\u01B0\u1EDBng d\u1EABn thanh to\xE1n",isQrForAll:t=!1,shortTitle:a,open:i,onOpenChange:n})=>im(_e,{open:i,onOpenChange:n,children:[ma(Lo,{asChild:!0,children:e}),im(Ie,{position:"bottom",children:[ma(co,{children:ma(po,{children:o})}),ma(qe,{children:ma(gr,{isQrForAll:t,shortTitle:a})})]})]}),ur=p0;import{Fragment as ti,jsx as P,jsxs as me}from"react/jsx-runtime";var u0=({img:e="",children:o,isQrForAll:t,onQrLoaded:a,dateExpired:i,priceOrder:n})=>me(ti,{children:[me("div",{className:"qrcode__scan__container relative h-auto select-none md:h-[280px]",children:[me("div",{className:"flex justify-center items-center space-x-2 w-full md:hidden",children:[P("img",{src:"https://homepage.momocdn.net/pwa/images/logoMomox50.png",width:28,height:28,alt:"QR all",className:"select-none shrink-0"}),P("div",{className:"h-[14px] w-[2px] shrink-0 select-none bg-gray-200"}),P("img",{src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250711102030-638878260300337990.png",width:56,height:56,alt:"QR all",className:"select-none shrink-0"})]}),me("div",{className:"qrcode__scan",children:[P("div",{className:"invisible opacity-0 select-none qrcode__gradient md:visible md:opacity-100",children:P("img",{alt:"step 1",className:"img-fluid",src:"https://homepage.momocdn.net/jk/momo2020/img/qrcode/qrcode-gradient.png"})}),P("div",{className:"invisible opacity-0 select-none qrcode__border md:visible md:opacity-100",children:P("img",{alt:"step 2",className:"img-fluid",src:"https://homepage.momocdn.net/jk/momo2020/img/qrcode/border-qrcode.svg"})}),P("div",{className:"p-4 select-none qrcode__image",children:e?P("img",{alt:"step 3",className:"mx-auto img-fluid d-block",src:e,loading:"lazy",onLoad:a}):ca.Children.map(o,s=>(ca.isValidElement(s),s))})]}),n&&me("div",{className:"text-sm text-gray-900 md:hidden",children:[P("div",{className:"",children:"Th\xF4ng tin thanh to\xE1n"}),P("div",{className:"text-base font-bold text-gray-900",children:n})]})]}),i&&me("div",{className:r("mt-3 text-sm text-gray-900 md:hidden"),children:[P("span",{children:"M\xE3 h\u1EBFt h\u1EA1n v\xE0o: "}),P("span",{className:"font-semibold",children:i})]}),P("div",{className:"hidden mt-4 text-sm font-semibold text-gray-900 md:block",children:t?me(ti,{children:[P("img",{src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250710143736-638877550567721225.png",width:220,height:28,className:"mx-auto",alt:"QR all"}),P("div",{className:"mt-3",children:"Nh\u1EADn ti\u1EC1n t\u1EEB m\u1ECDi V\xED \u0110i\u1EC7n T\u1EED v\xE0 Ng\xE2n H\xE0ng"})]}):me(ti,{children:[P("svg",{xmlns:"http://www.w3.org/2000/svg",className:"inline mr-1 w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:P("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v1m6 11h2m-6 0h-2v4m0-11v3m0 0h.01M12 12h4.01M16 20h4M4 12h4m12 0h.01M5 8h2a1 1 0 001-1V5a1 1 0 00-1-1H5a1 1 0 00-1 1v2a1 1 0 001 1zm12 0h2a1 1 0 001-1V5a1 1 0 00-1-1h-2a1 1 0 00-1 1v2a1 1 0 001 1zM5 20h2a1 1 0 001-1v-2a1 1 0 00-1-1H5a1 1 0 00-1 1v2a1 1 0 001 1z"})}),"S\u1EED d\u1EE5ng App MoMo ho\u1EB7c",P("br",{}),"\u1EE9ng d\u1EE5ng Camera h\u1ED7 tr\u1EE3 QR code \u0111\u1EC3 qu\xE9t m\xE3."]})})]}),v0=({img:e="",children:o,isQrForAll:t,onQrLoaded:a,qrImageBase64:i,dateExpired:n,priceOrder:s})=>me(ti,{children:[P("div",{className:r(i&&"opacity-0 md:opacity-100"),children:P(u0,{dateExpired:n,priceOrder:s,img:e,isQrForAll:t,onQrLoaded:a,children:o})}),P("style",{children:`
308
308
  .qrcode__scan__container {
309
309
  padding: 15px;
310
310
  background-color: white;
311
311
  width: 280px;
312
- height: 280px;
313
312
  border-radius: 20px;
314
313
  border-radius: 15px;
315
314
  margin: 0 auto;
@@ -373,7 +372,7 @@ import*as Io from"react";import{ChevronDownIcon as Sm}from"@heroicons/react/20/s
373
372
  transform: translate3d(0, 30%, 0);
374
373
  }
375
374
  }
376
- `})]}),x0=({isQrForAll:e,qrImage:o,qrLink:t,logoQr:a="https://homepage.momocdn.net/img/momo-upload-api-231211171009-638379114093056419.png",expired:i,loading:n,onQrLoaded:s,qrImageBase64:l,qrCodeRef:m,dateExpired:c,priceOrder:d,titleOrder:p})=>{let[g,v]=ca.useState(void 0);return ca.useEffect(()=>{a?am(a).then(v).catch(()=>v(void 0)):v(void 0)},[a]),ca.useEffect(()=>{t&&g&&typeof s=="function"&&!o&&s()},[t,g,s,o]),me("div",{className:"relative z-[1] rounded-lg",children:[me("div",{className:"relative z-[1] bg-pink-50 bg-repeat-y px-5 py-6 text-center",style:{backgroundImage:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-250714113823-638880899039487085.png) ",backgroundPosition:"right bottom",backgroundSize:"auto 30px"},ref:m,children:[P("h2",{className:r(" mb-2 hidden select-all text-base font-bold text-gray-900 md:block",l&&"opacity-0 md:opacity-100"),children:p||"Qu\xE9t QR \u0111\u1EC3 thanh to\xE1n"}),l&&P("div",{className:"visible absolute left-0 right-0 top-0 z-20 cursor-pointer opacity-100 md:opacity-0",children:P("img",{src:l,alt:"QR Code"})}),P("div",{className:"relative flex select-none flex-col items-center",children:me(v0,{qrImageBase64:l,img:o,isQrForAll:e,onQrLoaded:s,dateExpired:c,priceOrder:d,children:[t&&g&&!o&&P(g0,{value:t,size:215,imageSettings:{src:`${g}`,height:40,width:40,excavate:!0},level:"H"}),i&&P("div",{className:"absolute inset-0 z-10 flex size-full flex-col items-center justify-center bg-white/90",children:P("span",{className:"text-lg font-bold text-pink-600",children:"QR Code \u0111\xE3 h\u1EBFt h\u1EA1n"})}),n&&P("div",{className:"absolute inset-0 z-10 flex size-full flex-col items-center justify-center bg-white/90",children:P($i,{size:"lg"})})]})})]}),me("div",{className:"qrcode__guide relative z-10 select-none bg-pink-50 bg-repeat-y px-5 pb-5 text-center",style:{backgroundImage:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-250714113823-638880899039487085.png) ",backgroundPosition:"right top",backgroundSize:"auto 30px"},children:[me("div",{className:r("qrcode__guide absolute -top-24 right-20 z-50 cursor-pointer select-none md:opacity-0",l&&"opacity-100 md:opacity-0"),children:[me("div",{className:"ripple size-5 rounded-full",children:[P("div",{className:"ripple-1"}),P("div",{className:"ripple-2"})]}),P("img",{className:"qrcode__hand relative z-10 -mt-1 size-7 select-none object-contain drop-shadow-lg",src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250714154408-638881046482607959.png",alt:"Momo Hand Icon"})]}),P("div",{className:"mb-2 text-sm font-semibold text-pink-600 md:hidden",children:"Nh\u1EA5n gi\u1EEF QR \u0111\u1EC3 l\u01B0u"}),P(ur,{isQrForAll:!0,shortTitle:"Thanh to\xE1n ngay",title:"H\u01B0\u1EDBng d\u1EABn thanh to\xE1n QR",children:me("div",{className:"flex cursor-pointer items-center justify-center space-x-1 text-center text-sm font-semibold text-pink-600",children:[P("div",{children:"H\u01B0\u1EDBng d\u1EABn thanh to\xE1n"})," ",P(f0,{className:"size-4"})," "]})}),P("style",{children:`
375
+ `})]}),x0=({isQrForAll:e,qrImage:o,qrLink:t,logoQr:a="https://homepage.momocdn.net/img/momo-upload-api-231211171009-638379114093056419.png",expired:i,loading:n,onQrLoaded:s,qrImageBase64:l,qrCodeRef:m,dateExpired:c,priceOrder:d,titleOrder:p})=>{let[g,v]=ca.useState(void 0);return ca.useEffect(()=>{a?am(a).then(v).catch(()=>v(void 0)):v(void 0)},[a]),ca.useEffect(()=>{t&&g&&typeof s=="function"&&!o&&s()},[t,g,s,o]),me("div",{className:"relative z-[1] rounded-lg",children:[me("div",{className:"relative z-[1] bg-pink-50 bg-repeat-y px-5 py-6 text-center",style:{backgroundImage:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-250714113823-638880899039487085.png) ",backgroundPosition:"right bottom",backgroundSize:"auto 30px"},ref:m,children:[P("h2",{className:r(" mb-2 hidden select-all text-base font-bold text-gray-900 md:block",l&&"opacity-0 md:opacity-100"),children:p||"Qu\xE9t QR \u0111\u1EC3 thanh to\xE1n"}),l&&P("div",{className:"absolute top-0 right-0 left-0 visible z-20 opacity-100 cursor-pointer md:select-none md:opacity-0",children:P("img",{src:l,alt:"QR Code"})}),P("div",{className:"flex relative flex-col items-center select-none",children:me(v0,{qrImageBase64:l,img:o,isQrForAll:e,onQrLoaded:s,dateExpired:c,priceOrder:d,children:[t&&g&&!o&&P(g0,{value:t,size:215,imageSettings:{src:`${g}`,height:40,width:40,excavate:!0},level:"H"}),i&&P("div",{className:"flex absolute inset-0 z-10 flex-col justify-center items-center size-full bg-white/90",children:P("span",{className:"text-lg font-bold text-pink-600",children:"QR Code \u0111\xE3 h\u1EBFt h\u1EA1n"})}),n&&P("div",{className:"flex absolute inset-0 z-10 flex-col justify-center items-center size-full bg-white/90",children:P($i,{size:"lg"})})]})})]}),me("div",{className:"relative z-10 px-5 pb-5 text-center bg-pink-50 bg-repeat-y select-none qrcode__guide",style:{backgroundImage:"url(https://homepage.momocdn.net/img/momo-amazone-s3-api-250714113823-638880899039487085.png) ",backgroundPosition:"right top",backgroundSize:"auto 30px"},children:[me("div",{className:r("qrcode__guide absolute -top-24 right-20 z-50 cursor-pointer select-none md:opacity-0",l&&"opacity-100 md:opacity-0"),children:[me("div",{className:"rounded-full ripple size-5",children:[P("div",{className:"ripple-1"}),P("div",{className:"ripple-2"})]}),P("img",{className:"object-contain relative z-10 -mt-1 drop-shadow-lg select-none qrcode__hand size-7",src:"https://homepage.momocdn.net/img/momo-amazone-s3-api-250714154408-638881046482607959.png",alt:"Momo Hand Icon"})]}),P("div",{className:"mb-2 text-sm font-semibold text-pink-600 md:hidden",children:"Nh\u1EA5n gi\u1EEF QR \u0111\u1EC3 l\u01B0u"}),P(ur,{isQrForAll:!0,shortTitle:"Thanh to\xE1n ngay",title:"H\u01B0\u1EDBng d\u1EABn thanh to\xE1n QR",children:me("div",{className:"flex justify-center items-center space-x-1 text-sm font-semibold text-center text-pink-600 cursor-pointer",children:[P("div",{children:"H\u01B0\u1EDBng d\u1EABn thanh to\xE1n"})," ",P(f0,{className:"size-4"})," "]})}),P("style",{children:`
377
376
  .ripple {
378
377
  box-sizing: border-box;
379
378
  position: relative;