PageSourceSearch

https://www.sociallibra.com/_next/static/chunks/1610-96205ce8de9bd984.js

js sociallibra.com collected 2026-09-24 14:53:35 UTC 10,674 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1610],{10183:(e,t,r)=>{function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"en-US",r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(!e)return"N/A";try{return new Date(e).toLocaleString(t,{dateStyle:"medium",timeStyle:r?"short":void 0,hour12:!0})}catch(t){return e.toString()}}function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"USD",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"en-US",a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:2;return new Intl.NumberFormat(r,{style:"currency",currency:t.toUpperCase(),maximumFractionDigits:a}).format(e)}function n(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"en-US";return new Intl.NumberFormat(t).format(e)}function l(e){if(!e)return null;let t=new Date,r=new Date(e).getTime()-t.getTime();return r<=0?0:Math.ceil(r/864e5)}r.d(t,{Yq:()=>a,ZV:()=>n,le:()=>l,vv:()=>s})},29214:(e,t,r)=>{r.d(t,{E:()=>n});var a=r(95155),s=r(25016);function n(e){let{className:t,...r}=e;return(0,a.jsx)("div",{className:(0,s.cn)("animate-pulse rounded-md bg-muted",t),...r})}},38446:(e,t,r)=>{r.d(t,{UK:()=>c,kb:()=>d,tk:()=>o,yT:()=>i});var a=r(12115),s=r(63354),n=r(87005);function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{autoFetch:r=!0}=t,[s,n]=(0,a.useState)(void 0),[l,i]=(0,a.useState)(!1),[c,o]=(0,a.useState)(null),d=(0,a.useCallback)(async t=>{i(!0),o(null);try{let r=await e();n(r),null==t||t(r)}catch(e){o(e)}finally{i(!1)}},[e]);return(0,a.useEffect)(()=>{r&&d()},[d,r]),{data:s,isLoading:l,error:c,refetch:d}}function i(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=(0,s.RC)();return l((0,a.useCallback)(async()=>{let t=(0,n.N)(r);if(!t)throw Error("Checkout endpoint is not of right format");t.searchParams.set("action","pricing_data"),e&&t.searchParams.set("topupPlanId",String(e));let a=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!a.ok)throw Error("Error fetching pricing data: ".concat(a.statusText));return await a.json()},[r,e]),{autoFetch:t})}function c(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return l((0,a.useCallback)(async()=>{let t=(0,n.N)(e);if(!t)throw Error("Portal endpoint is not of right format");t.searchParams.set("action","portal_data");let r=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!r.ok)throw Error("Error fetching portal data: ".concat(r.statusText));return await r.json()},[e]),{autoFetch:t})}function o(e){return l((0,a.useCallback)(async()=>{let t=(0,n.N)(e);if(!t)throw Error("Restore purchase endpoint is not of right format");t.searchParams.set("action","restore_purchase");let r=await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"}});if(!r.ok)throw Error("Error restoring purchase: ".concat(r.statusText));return await r.json()},[e]),{autoFetch:!1})}function d(e){let[t,r]=(0,a.useState)(!1);return{execute:(0,a.useCallback)(async t=>{r(!0);try{let r=(0,n.N)(e);if(!r)throw Error("Authenticated endpoint is not of right format");let a=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok)throw Error("Error performing action: ".concat(a.statusText));return await a.json()}finally{r(!1)}},[e]),loading:t}}},61962:(e,t,r)=>{r.d(t,{n:()=>g});var a=r(95155),s=r(12115),n=r(81989),l=r(10183),i=r(78661),c=r(33431),o=r(93736),d=r(47321),u=r(25016);let f=s.forwardRef((e,t)=>{let{className:r,orientation:s="horizontal",decorative:n=!0,...l}=e;return(0,a.jsx)(d.b,{ref:t,decorative:n,orientation:s,className:(0,u.cn)("shrink-0 bg-border","horizontal"===s?"h-[1px] w-full":"h-full w-[1px]",r),...l})});f.displayName=d.b.displayName;var m=r(63354),h=r(45949);let p=(0,s.forwardRef)((e,t)=>(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"none",viewBox:"0 0 21 21",ref:t,...e,children:(0,a.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M18.39 5.08a1 1 0 0 1 0 1.414l-10 10a1 1 0 0 1-1.415 0l-5-5A1 1 0 1 1 3.39 10.08l4.293 4.293 9.293-9.293a1 1 0 0 1 1.415 0Z",clipRule:"evenodd"})}));function x(e){let{plan:t,trial:r=!1,onCheckout:s}=e,n=(0,m.Q5)(),l=(0,h.Ym)();return(0,a.jsxs)(i.Zp,{className:"relative flex flex-col h-full gap-2",children:[(0,a.jsxs)(i.aR,{className:"text-center",children:[(0,a.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[(0,a.jsx)(i.ZB,{className:"text-xl",children:t.title}),r&&(0,a.jsx)(o.E,{variant:"secondary",className:"text-xs",children:"free"===r?l.pricing.freeTrial():l.pricing.paidTrial()})]}),t.description?(0,a.jsx)(i.BT,{className:"text-sm",children:t.description}):null]}),(0,a.jsxs)(i.Wu,{className:"flex-1",children:[(0,a.jsx)("div",{className:"flex flex-col items-center",children:(0,a.jsxs)("div",{className:"flex items-baseline gap-2 mb-2 justify-center",children:[(0,a.jsx)("div",{className:"text-3xl font-bold",children:t.price}),(0,a.jsx)("div",{className:"text-sm text-muted-foreground",children:l.pricing.billingSeparator()}),(0,a.jsx)("div",{className:"text-sm text-muted-foreground",children:l.pricing.monthly()})]})}),t.features.length?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(f,{className:"my-4"}),(0,a.jsx)("ul",{className:"space-y-2 px-2",children:t.features.map((e,t)=>(0,a.jsxs)("li",{className:"flex items-start gap-2 text-sm",children:[(0,a.jsx)("span",{children:(0,a.jsx)(p,{className:"h-4 w-4 mt-0.5 text-primary"})}),(0,a.jsxs)("span",{className:"flex flex-col flex-nowrap",children:[(0,a.jsx)("span",{className:"font-semibold",children:e.title}),e.value?(0,a.jsx)("span",{className:"text-muted-foreground",children:e.value}):null]})]},t))})]}):null]}),(0,a.jsx)(i.wL,{className:"mt-6",children:(0,a.jsx)(c.$,{className:"w-full",variant:t.featured?"default":"outline",size:"lg",onClick:()=>{null==s||s(),n.open({plan_id:t.id,pricing_id:t.pricing_id,trial:r})}
1,children:r?l.pricing.action.trial():l.pricing.action.upgrade()})})]})}function g(e){let{plans:t,trial:r=!1,currency:i=n.UM.USD,onCheckout:c}=e,o=s.useMemo(()=>{let e=[];return t.forEach(t=>{var r,a,s,c,o;let d=null==(r=t.pricing)?void 0:r.find(e=>(0,n.vu)(e.currency)===i&&!0!==e.is_hidden&&(e.monthly_price||e.annual_price));if(!d)return;let{annual_price:u,monthly_price:f}=d,m=Math.min((null!=(s=(0,n.$J)(u))?s:1/0)/12,null!=(c=(0,n.$J)(f))?c:1/0),h=[];null==(a=t.features)||a.forEach(e=>{e.title&&h.push({title:e.title,value:e.value})}),e.push({id:t.id,pricing_id:d.id,title:t.title,description:t.description,featured:null!=(o=t.is_featured)&&o,price:(0,l.vv)(m,i),features:h})}),e},[t,i]);return 0===o.length?(0,a.jsx)("p",{children:"No plans found that supports subscription"}):(0,a.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:o.map(e=>(0,a.jsx)(x,{plan:e,trial:r,onCheckout:c},e.id))})}},62264:(e,t,r)=>{r.d(t,{Subscribe:()=>f});var a=r(95155);r(12115);var s=r(45949),n=r(38446),l=r(29214),i=r(78661);let c=[1,2,3],o=[1,2,3,4];function d(e){let{type:t="subscription"}=e;return(0,a.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:c.map(e=>(0,a.jsxs)(i.Zp,{className:"flex flex-col h-full gap-2",children:[(0,a.jsxs)(i.aR,{className:"items-center gap-2",children:[(0,a.jsx)(l.E,{className:"h-6 w-2/3"}),(0,a.jsx)(l.E,{className:"h-4 w-1/2"})]}),(0,a.jsxs)(i.Wu,{className:"flex-1",children:[(0,a.jsxs)("div",{className:"flex items-baseline gap-2 mb-4 justify-center",children:[(0,a.jsx)(l.E,{className:"h-8 w-16"}),(0,a.jsx)(l.E,{className:"h-4 w-10"})]}),"subscription"===t?(0,a.jsx)("div",{className:"flex flex-col gap-3 px-2",children:o.map(e=>(0,a.jsxs)("div",{className:"flex items-start gap-2",children:[(0,a.jsx)(l.E,{className:"h-4 w-4 mt-0.5 rounded-full"}),(0,a.jsx)(l.E,{className:"h-4 w-full"})]},e))}):(0,a.jsx)(l.E,{className:"h-4 w-3/4 mx-auto"})]}),(0,a.jsx)(i.wL,{className:"mt-6",children:(0,a.jsx)(l.E,{className:"h-10 w-full rounded-lg"})})]},e))})}var u=r(61962);function f(e){var t;let r=(0,s.Ym)(),{data:l,error:i,isLoading:c}=(0,n.yT)(null,!0),{onCheckout:o,children:f}=e;return(0,a.jsxs)("div",{className:"mb-4 max-w-4xl mx-auto",children:[f,c||!l?(0,a.jsx)(d,{}):i?(0,a.jsxs)("div",{className:"text-center text-destructive",children:[r.pricing.error.fetchingData(),": ",i.message]}):(0,a.jsx)(u.n,{plans:null!=(t=null==l?void 0:l.plans)?t:[],onCheckout:o})]})}},62307:(e,t,r)=>{r.d(t,{default:()=>o});var a=r(95155),s=r(12284),n=r(12115),l=r(18720),i=r(18955),c=r(38966);function o(e){let t=(0,i.c)("Checkout"),r=(0,c.rd)(),o=n.useCallback(()=>{l.toast.success(t("subscriptionUpdated")),r.refresh()},[r,t]);return(0,a.jsx)(s.s,{onAfterSync:o,checkout:e.checkout,endpoint:"https://www.sociallibra.com//api/checkout",children:e.children})}},78661:(e,t,r)=>{r.d(t,{BT:()=>o,Wu:()=>d,ZB:()=>c,Zp:()=>l,aR:()=>i,wL:()=>u});var a=r(95155),s=r(12115),n=r(25016);let l=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("rounded-lg border bg-card text-card-foreground shadow-sm",r),...s})});l.displayName="Card";let i=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("flex flex-col space-y-1.5 p-6",r),...s})});i.displayName="CardHeader";let c=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("text-2xl font-semibold leading-none tracking-tight",r),...s})});c.displayName="CardTitle";let o=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("text-sm text-muted-foreground",r),...s})});o.displayName="CardDescription";let d=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("p-6 pt-0",r),...s})});d.displayName="CardContent";let u=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)("div",{ref:t,className:(0,n.cn)("flex items-center p-6 pt-0",r),...s})});u.displayName="CardFooter"},93736:(e,t,r)=>{r.d(t,{E:()=>i});var a=r(95155);r(12115);var s=r(83101),n=r(25016);let l=(0,s.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function i(e){let{className:t,variant:r,...s}=e;return(0,a.jsx)("div",{className:(0,n.cn)(l({variant:r}),t),...s})}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.