JezK
Edit File: view.js
(()=>{"use strict";var e={5338:(e,t,a)=>{var s=a(5795);t.H=s.createRoot,s.hydrateRoot},5795:e=>{e.exports=window.ReactDOM}},t={};const a=window.React;var s=function a(s){var r=t[s];if(void 0!==r)return r.exports;var n=t[s]={exports:{}};return e[s](n,n.exports,a),n.exports}(5338);const r=e=>{try{const t=new URL(e);return["http:","https:"].includes(t.protocol)?t.toString():null}catch(t){return"string"==typeof e&&e.startsWith("/")&&!e.startsWith("//")?e:null}};const n="linear-gradient(135deg, #0040E3, #18D4FD)",c=e=>{const t=r(e);if(!t)return"none";return`url('${t.replace(/['"()]/g,"")}')`},l=(e,t)=>{return null==(a=t)||""===a||Array.isArray(a)&&0===a.length||"object"==typeof a&&0===Object.keys(a).length||"string"==typeof a&&""===a.trim()||"number"==typeof a&&0===a?"":`${e}: ${t};`;var a},o=(e,t=!0,a=!0,s=!0)=>{const{type:r="solid",color:o="",gradient:i=n,image:p={},position:m="center center",attachment:d="",repeat:b="no-repeat",size:u="",overlayColor:h=""}=e||{};return"gradient"===r&&a?l("background",i):"image"===r&&s?`background: ${c(p?.url)};\n\t\t\t\t${l("background-color",h)}\n\t\t\t\t${l("background-position",m)}\n\t\t\t\t${l("background-size",u)}\n\t\t\t\t${l("background-repeat",b)}\n\t\t\t\t${l("background-attachment",d)}\n\t\t\t\t${l("background-repeat",b)}\n\t\t\t\tbackground-blend-mode: overlay;`:t&&l("background",o)},i=(e,t,a=!0)=>{const{fontFamily:s="Default",fontCategory:r="sans-serif",fontVariant:n=400,fontWeight:c,isUploadFont:o=!0,fontSize:i={desktop:null,tablet:null,mobile:null},fontStyle:p,textTransform:m,textDecoration:d,lineHeight:b,letterSpace:u}=t||{},h=!a||!s||"Default"===s,g=i?.desktop||i,v=i?.tablet||g,E=i?.mobile||v,y=e=>{const t=String(e);return["px","em","rem","%","vh","vw"].some((e=>t.endsWith(e)))?t:"number"==typeof e?`${t}px`:""},f=`\n\t\t${h?"":`font-family: '${s}', ${r};`}\n\t\t${l("font-weight",c)}\n\t\t${l("font-size",y(g))}\n\t\t${l("font-style",p)}\n\t\t${l("text-transform",m)}\n\t\t${l("text-decoration",d)}\n\t\t${l("line-height",b)}\n\t\t${l("letter-spacing",u)}\n\t`,w=n&&400!==n?"400i"===n?":ital@1":n?.includes("00i")?`: ital, wght@1, ${n?.replace("00i","00")} `:`: wght@${n} `:"",$=h?"":`https://fonts.googleapis.com/css2?family=${s?.split(" ").join("+")}${w.replace(/ /g,"")}&display=swap`;return{googleFontLink:!o||h?"":`@import url(${$});`,styles:`${e}{\n\t\t\t${f}\n\t\t}\n\t\t@media only screen and (max-width: 1024px) {\n\t\t\t${e}{\n\t\t\t\t${l("font-size",y(v))}\n\t\t\t}\n\t\t}\n\t\t@media only screen and (max-width: 640px) {\n\t\t\t${e}{\n\t\t\t\t${l("font-size",y(E))}\n\t\t\t}\n\t\t}`.replace(/\s+/g," ").trim()}},p=e=>{if(!e)return"";if("string"==typeof e)return e;if("object"==typeof e&&!Array.isArray(e)){const t=["top","right","bottom","left"];return t.map((t=>e[t]||"")).every((e=>!e))?"":t.map((t=>e[t]||"0")).join(" ")}return""},m=({attributes:e,id:t})=>{const{wrapper:s,titleStyle:r,subtitleStyle:n,badgeStyle:c,featureTitleStyle:l,featureDescStyle:m,captionStyle:d,primaryBtnStyle:b,secondaryBtnStyle:u,featureIconStyle:h,layout:g}=e,v=`${`#${t}`} .bpsc-app-showcase-section`,E=`${v} .bpsc-as-container`,y=`${v} .bpsc-as-badge`,f=`${v} .bpsc-as-title`,w=`${v} .bpsc-as-subtitle`,$=`${v} .bpsc-as-feature-title`,N=`${v} .bpsc-as-feature-desc`,x=`${v} .bpsc-as-caption`,k=`${v} .bpsc-as-feature-icon`,B=`${v} .bpsc-as-btn-primary`,C=`${v} .bpsc-as-btn-secondary`;return(0,a.createElement)("style",{dangerouslySetInnerHTML:{__html:`\n\t\t\t${i("",r?.typo)?.googleFontLink}\n\t\t\t${i("",n?.typo)?.googleFontLink}\n\t\t\t${i("",c?.typo)?.googleFontLink}\n\t\t\t${i("",l?.typo)?.googleFontLink}\n\t\t\t${i("",m?.typo)?.googleFontLink}\n\t\t\t${i("",d?.typo)?.googleFontLink}\n\t\t\t${i("",b?.typo)?.googleFontLink}\n\t\t\t${i("",u?.typo)?.googleFontLink}\n\n\t\t\t${i(f,r?.typo)?.styles}\n\t\t\t${i(w,n?.typo)?.styles}\n\t\t\t${i(y,c?.typo)?.styles}\n\t\t\t${i($,l?.typo)?.styles}\n\t\t\t${i(N,m?.typo)?.styles}\n\t\t\t${i(x,d?.typo)?.styles}\n\t\t\t${i(B,b?.typo)?.styles}\n\t\t\t${i(C,u?.typo)?.styles}\n\n\t\t\t${v} {\n\t\t\t\t${o(s?.bg)}\n\t\t\t\tpadding: ${p(s?.padding?.desktop)};\n\t\t\t}\n\n\t\t\t${E} {\n\t\t\t\tmax-width: ${g?.maxWidth||"1200px"};\n\t\t\t\tmargin: 0 auto;\n\t\t\t}\n\n\t\t\t${y} {\n\t\t\t\tbackground-color: ${c?.backgroundColor};\n\t\t\t\tcolor: ${c?.textColor};\n\t\t\t\tborder-radius: ${p(c?.borderRadius)};\n\t\t\t}\n\n\t\t\t${f} {\n\t\t\t\tcolor: ${r?.color};\n\t\t\t}\n\n\t\t\t${w} {\n\t\t\t\tcolor: ${n?.color};\n\t\t\t}\n\n\t\t\t${$} {\n\t\t\t\tcolor: ${l?.color};\n\t\t\t}\n\n\t\t\t${N} {\n\t\t\t\tcolor: ${m?.color};\n\t\t\t}\n\n\t\t\t${x} {\n\t\t\t\tcolor: ${d?.color};\n\t\t\t}\n\n\t\t\t${k} {\n\t\t\t\tcolor: ${h?.color};\n\t\t\t\tbackground-color: ${h?.backgroundColor};\n\t\t\t\twidth: calc( ${h?.size} * 2 );\n\t\t\t\theight: calc( ${h?.size} * 2 );\n\t\t\t\tflex-shrink: 0;\n\t\t\t}\n\n\t\t\t${k} svg {\n\t\t\t\twidth: ${h?.size};\n\t\t\t\theight: ${h?.size};\n\t\t\t}\n\n\t\t\t${B} {\n\t\t\t\tbackground-color: ${b?.backgroundColor};\n\t\t\t\tcolor: ${b?.textColor};\n\t\t\t\tborder-radius: ${p(b?.borderRadius)};\n\t\t\t\tpadding: ${p(b?.padding?.desktop)};\n\t\t\t}\n\n\t\t\t${B}:hover {\n\t\t\t\tbackground-color: ${b?.hoverBackgroundColor};\n\t\t\t\tcolor: ${b?.hoverTextColor};\n\t\t\t}\n\n\t\t\t${C} {\n\t\t\t\tbackground-color: ${u?.backgroundColor};\n\t\t\t\tcolor: ${u?.textColor};\n\t\t\t\tborder-radius: ${p(u?.borderRadius)};\n\t\t\t\tpadding: ${p(u?.padding?.desktop)};\n\t\t\t\tborder: ${u?.borderWidth||"2px"} solid ${u?.borderColor||"#6366f1"};\n\t\t\t}\n\n\t\t\t${C}:hover {\n\t\t\t\tbackground-color: ${u?.hoverBackgroundColor};\n\t\t\t\tcolor: ${u?.hoverTextColor};\n\t\t\t}\n\n\t\t\t@media (min-width: 641px) and (max-width: 1024px) {\n\t\t\t\t${v} {\n\t\t\t\t\tpadding: ${p(s?.padding?.tablet)};\n\t\t\t\t}\n\t\t\t\t${B} {\n\t\t\t\t\tpadding: ${p(b?.padding?.tablet)};\n\t\t\t\t}\n\t\t\t\t${C} {\n\t\t\t\t\tpadding: ${p(u?.padding?.tablet)};\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t@media (max-width: 640px) {\n\t\t\t\t${v} {\n\t\t\t\t\tpadding: ${p(s?.padding?.mobile)};\n\t\t\t\t}\n\t\t\t\t${B} {\n\t\t\t\t\tpadding: ${p(b?.padding?.mobile)};\n\t\t\t\t}\n\t\t\t\t${C} {\n\t\t\t\t\tpadding: ${p(u?.padding?.mobile)};\n\t\t\t\t}\n\t\t\t}\n\t\t`}})},d=window.wp.element,b=({deviceFrame:e,screenshot:t,className:s=""})=>{const{type:r="phone",colorScheme:n="dark",customColor:c="#1a1a2e",showShadow:l=!0,shadowColor:o="rgba(0,0,0,0.25)"}=e||{},{url:i="",alt:p=""}=t||{};let m="#1a1a2e";"light"===n?m="#e5e7eb":"custom"===n&&(m=c);const d=l?{filter:`drop-shadow(0 24px 48px ${o})`}:{};return"phone"===r?(0,a.createElement)("div",{className:`bpsc-as-device-wrap bpsc-as-device-phone ${s}`,style:d},(0,a.createElement)("div",{className:"bpsc-as-phone-shell",style:{"--bpsc-frame-color":m},role:"img","aria-label":p||"App screenshot in phone frame"},(0,a.createElement)("div",{className:"bpsc-as-phone-notch","aria-hidden":"true"}),(0,a.createElement)("div",{className:"bpsc-as-phone-screen"},i?(0,a.createElement)("img",{src:i,alt:p,className:"bpsc-as-screenshot-img",loading:"lazy"}):(0,a.createElement)("div",{className:"bpsc-as-screenshot-placeholder","aria-hidden":"true"},(0,a.createElement)("span",null,p||"Screenshot"))),(0,a.createElement)("div",{className:"bpsc-as-phone-btn","aria-hidden":"true"}))):"tablet"===r?(0,a.createElement)("div",{className:`bpsc-as-device-wrap bpsc-as-device-tablet ${s}`,style:d},(0,a.createElement)("div",{className:"bpsc-as-tablet-shell",style:{"--bpsc-frame-color":m},role:"img","aria-label":p||"App screenshot in tablet frame"},(0,a.createElement)("div",{className:"bpsc-as-tablet-camera","aria-hidden":"true"}),(0,a.createElement)("div",{className:"bpsc-as-tablet-screen"},i?(0,a.createElement)("img",{src:i,alt:p,className:"bpsc-as-screenshot-img",loading:"lazy"}):(0,a.createElement)("div",{className:"bpsc-as-screenshot-placeholder","aria-hidden":"true"},(0,a.createElement)("span",null,p||"Screenshot"))),(0,a.createElement)("div",{className:"bpsc-as-tablet-home-btn","aria-hidden":"true"}))):"browser"===r?(0,a.createElement)("div",{className:`bpsc-as-device-wrap bpsc-as-device-browser ${s}`,style:d},(0,a.createElement)("div",{className:"bpsc-as-browser-shell",style:{"--bpsc-frame-color":m},role:"img","aria-label":p||"App screenshot in browser frame"},(0,a.createElement)("div",{className:"bpsc-as-browser-chrome","aria-hidden":"true"},(0,a.createElement)("div",{className:"bpsc-as-browser-dots"},(0,a.createElement)("span",{className:"bpsc-as-dot bpsc-as-dot-red"}),(0,a.createElement)("span",{className:"bpsc-as-dot bpsc-as-dot-yellow"}),(0,a.createElement)("span",{className:"bpsc-as-dot bpsc-as-dot-green"})),(0,a.createElement)("div",{className:"bpsc-as-browser-url-bar"},(0,a.createElement)("span",{className:"bpsc-as-url-text"},"yourapp.com/dashboard"))),(0,a.createElement)("div",{className:"bpsc-as-browser-screen"},i?(0,a.createElement)("img",{src:i,alt:p,className:"bpsc-as-screenshot-img",loading:"lazy"}):(0,a.createElement)("div",{className:"bpsc-as-screenshot-placeholder","aria-hidden":"true"},(0,a.createElement)("span",null,p||"Screenshot"))))):(0,a.createElement)("div",{className:`bpsc-as-device-wrap bpsc-as-device-none ${s}`,style:d},i?(0,a.createElement)("img",{src:i,alt:p,className:"bpsc-as-screenshot-img bpsc-as-no-frame-img",loading:"lazy"}):(0,a.createElement)("div",{className:"bpsc-as-screenshot-placeholder","aria-hidden":"true"},(0,a.createElement)("span",null,p||"Screenshot")))},u=((0,a.createElement)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"1em",width:"1em",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{fill:"none",d:"M0 0h24v24H0z"}),(0,a.createElement)("path",{d:"M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"})),{check:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"})),shield:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 10.99h7c-.53 4.12-3.28 7.79-7 8.94V12H5V6.3l7-3.11v8.8z"})),bolt:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M7 2v11h3v9l7-12h-4l4-8z"})),star:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"})),heart:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"})),chart:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M5 9.2h3V19H5zM10.6 5h2.8v14h-2.8zm5.6 8H19v6h-2.8z"})),users:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"})),lock:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"})),globe:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z"})),settings:(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M19.14,12.94c0.04-0.3,0.06-0.61,0.06-0.94c0-0.32-0.02-0.64-0.07-0.94l2.03-1.58c0.18-0.14,0.23-0.41,0.12-0.61 l-1.92-3.32c-0.12-0.22-0.37-0.29-0.59-0.22l-2.39,0.96c-0.5-0.38-1.03-0.7-1.62-0.94L14.4,2.81c-0.04-0.24-0.24-0.41-0.48-0.41 h-3.84c-0.24,0-0.43,0.17-0.47,0.41L9.25,5.35C8.66,5.59,8.12,5.92,7.63,6.29L5.24,5.33c-0.22-0.08-0.47,0-0.59,0.22L2.74,8.87 C2.62,9.08,2.66,9.34,2.86,9.48l2.03,1.58C4.84,11.36,4.8,11.69,4.8,12s0.02,0.64,0.07,0.94l-2.03,1.58 c-0.18,0.14-0.23,0.41-0.12,0.61l1.92,3.32c0.12,0.22,0.37,0.29,0.59,0.22l2.39-0.96c0.5,0.38,1.03,0.7,1.62,0.94l0.36,2.54 c0.05,0.24,0.24,0.41,0.48,0.41h3.84c0.24,0,0.44-0.17,0.47-0.41l0.36-2.54c0.59-0.24,1.13-0.56,1.62-0.94l2.39,0.96 c0.22,0.08,0.47,0,0.59-0.22l1.92-3.32c0.12-0.22,0.07-0.47-0.12-0.61L19.14,12.94z M12,15.6c-1.98,0-3.6-1.62-3.6-3.6 s1.62-3.6,3.6-3.6s3.6,1.62,3.6,3.6S13.98,15.6,12,15.6z"}))}),h=({featureList:e=[],columns:t=1,dark:s=!1})=>e.length?(0,a.createElement)("ul",{className:`bpsc-as-feature-list bpsc-as-feature-cols-${t}${s?" bpsc-as-feature-dark":""}`,"aria-label":"Feature highlights"},e.map(((e,t)=>{const s=u[e.icon]||u.check;return(0,a.createElement)("li",{key:e.id||t,className:"bpsc-as-feature-item"},(0,a.createElement)("div",{className:"bpsc-as-feature-icon","aria-hidden":"true"},s),(0,a.createElement)("div",{className:"bpsc-as-feature-text"},e.title&&(0,a.createElement)("span",{className:"bpsc-as-feature-title"},e.title),e.description&&(0,a.createElement)("span",{className:"bpsc-as-feature-desc"},e.description)))}))):null,g=["http","https","mailto","tel","sms","ftp","ftps"],v=(e,t="#")=>{if(!e)return t;const a=String(e).split("").filter((e=>{const t=e.charCodeAt(0);return!(t<32||127===t||t>=8203&&t<=8205||65279===t)})).join("").trim();if(""===a)return t;if(/^(\/|\.|#|\?)/.test(a))return a;const s=a.match(/^([a-zA-Z][a-zA-Z0-9+.-]*):/);return s?g.includes(s[1].toLowerCase())?a:t:a},E=(new Set(["svg","g","defs","symbol","use","title","desc","path","rect","circle","ellipse","line","polyline","polygon","text","tspan","textpath","lineargradient","radialgradient","stop","clippath","mask","pattern","filter","fegaussianblur","feoffset","feblend","femerge","femergenode","fecolormatrix","fecomposite","feflood","i","span","b","strong","em","small","br","div","p","img"]),new Set(["viewbox","xmlns","xmlns:xlink","version","width","height","class","id","fill","fill-rule","fill-opacity","clip-rule","clip-path","stroke","stroke-width","stroke-linecap","stroke-linejoin","stroke-opacity","stroke-dasharray","stroke-dashoffset","stroke-miterlimit","d","points","x","y","x1","y1","x2","y2","cx","cy","r","rx","ry","transform","transform-origin","opacity","offset","stop-color","stop-opacity","gradientunits","gradienttransform","patternunits","maskunits","clippathunits","preserveaspectratio","aria-hidden","aria-label","role","focusable","style","font-size","font-family","font-weight","text-anchor","dominant-baseline","mix-blend-mode","vector-effect","paint-order","shape-rendering","alt","src","title","data-name","xml:space"]),({attributes:e})=>{const{content:t,elements:s,deviceFrame:r,layout:n}=e,{badgeText:c,title:l,subtitle:o,screenshots:i,featureList:p,primaryBtnText:m,primaryBtnUrl:u,primaryBtnTarget:g,secondaryBtnText:E,secondaryBtnUrl:y,secondaryBtnTarget:f}=t,{isBadge:w,isTitle:$,isSubtitle:N,isFeatureList:x,isPrimaryBtn:k,isSecondaryBtn:B}=s,C=n?.imagePosition||"right",L=n?.featureColumns||1,S=i?.[0]||{url:"",alt:"App screenshot"},z=(0,a.createElement)("div",{className:"bpsc-as-split-content"},w&&c&&(0,a.createElement)("div",{className:"bpsc-as-badge-wrap"},(0,a.createElement)("span",{className:"bpsc-as-badge"},c)),$&&l&&(0,a.createElement)("h2",{className:"bpsc-as-title"},l),N&&o&&(0,a.createElement)("p",{className:"bpsc-as-subtitle"},o),x&&p?.length>0&&(0,a.createElement)(h,{featureList:p,columns:L}),(k||B)&&(0,a.createElement)("div",{className:"bpsc-as-btn-group"},k&&m&&(0,a.createElement)("a",{href:v(u||"#"),target:g||"_self",rel:"_blank"===g?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-primary"},m),B&&E&&(0,a.createElement)("a",{href:v(y||"#"),target:f||"_self",rel:"_blank"===f?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-secondary"},E))),F=(0,a.createElement)("div",{className:"bpsc-as-split-device"},(0,a.createElement)(b,{deviceFrame:r,screenshot:S}),S.caption&&(0,a.createElement)("p",{className:"bpsc-as-caption"},S.caption));return(0,a.createElement)("section",{className:"bpsc-app-showcase-section bpsc-as-style-1"},(0,a.createElement)("div",{className:"bpsc-as-container"},(0,a.createElement)("div",{className:"bpsc-as-split-grid"+("left"===C?" bpsc-as-img-left":" bpsc-as-img-right")},"left"===C?(0,a.createElement)(d.Fragment,null,F,z):(0,a.createElement)(d.Fragment,null,z,F))))}),y=({attributes:e})=>{const{content:t,elements:s,deviceFrame:r}=e,{badgeText:n,title:c,subtitle:l,screenshots:o,featureList:i,primaryBtnText:p,primaryBtnUrl:m,primaryBtnTarget:d,secondaryBtnText:u,secondaryBtnUrl:g,secondaryBtnTarget:E}=t,{isBadge:y,isTitle:f,isSubtitle:w,isFeatureList:$,isPrimaryBtn:N,isSecondaryBtn:x}=s,k=o?.[0]||{url:"",alt:"App screenshot"};return(0,a.createElement)("section",{className:"bpsc-app-showcase-section bpsc-as-style-2"},(0,a.createElement)("div",{className:"bpsc-as-container"},(0,a.createElement)("div",{className:"bpsc-as-centered-header"},y&&n&&(0,a.createElement)("div",{className:"bpsc-as-badge-wrap"},(0,a.createElement)("span",{className:"bpsc-as-badge"},n)),f&&c&&(0,a.createElement)("h2",{className:"bpsc-as-title"},c),w&&l&&(0,a.createElement)("p",{className:"bpsc-as-subtitle"},l),(N||x)&&(0,a.createElement)("div",{className:"bpsc-as-btn-group bpsc-as-btn-group-center"},N&&p&&(0,a.createElement)("a",{href:v(m||"#"),target:d||"_self",rel:"_blank"===d?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-primary"},p),x&&u&&(0,a.createElement)("a",{href:v(g||"#"),target:E||"_self",rel:"_blank"===E?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-secondary"},u))),(0,a.createElement)("div",{className:"bpsc-as-center-device-wrap"},(0,a.createElement)(b,{deviceFrame:{...r,type:"tablet"},screenshot:k}),k.caption&&(0,a.createElement)("p",{className:"bpsc-as-caption bpsc-as-caption-center"},k.caption)),$&&i?.length>0&&(0,a.createElement)("div",{className:"bpsc-as-chips-row"},(0,a.createElement)(h,{featureList:i,columns:1}))))},f=({attributes:e})=>{const{content:t,elements:s,deviceFrame:r}=e,{badgeText:n,title:c,subtitle:l,screenshots:o,featureList:i,primaryBtnText:p,primaryBtnUrl:m}=t,{isBadge:d,isTitle:h,isSubtitle:g,isFeatureList:E,isPrimaryBtn:y}=s,f=o?.[0]||{url:"",alt:"App screenshot"};return(0,a.createElement)("section",{className:"bpsc-app-showcase-section bpsc-as-style-3"},(0,a.createElement)("div",{className:"bpsc-as-container"},(0,a.createElement)("div",{className:"bpsc-as-centered-header"},d&&n&&(0,a.createElement)("div",{className:"bpsc-as-badge-wrap"},(0,a.createElement)("span",{className:"bpsc-as-badge"},n)),h&&c&&(0,a.createElement)("h2",{className:"bpsc-as-title"},c),g&&l&&(0,a.createElement)("p",{className:"bpsc-as-subtitle"},l)),(0,a.createElement)("div",{className:"bpsc-as-browser-wrap"},(0,a.createElement)(b,{deviceFrame:{...r,type:"browser"},screenshot:f})),E&&i?.length>0&&(0,a.createElement)("div",{className:"bpsc-as-feature-card-grid"},i.map(((e,t)=>{const s=u[e.icon]||u.check;return(0,a.createElement)("div",{key:e.id||t,className:"bpsc-as-feature-card"},(0,a.createElement)("div",{className:"bpsc-as-feature-icon","aria-hidden":"true"},s),(0,a.createElement)("div",{className:"bpsc-as-feature-card-body"},e.title&&(0,a.createElement)("h3",{className:"bpsc-as-feature-title"},e.title),e.description&&(0,a.createElement)("p",{className:"bpsc-as-feature-desc"},e.description)))}))),y&&p&&(0,a.createElement)("div",{className:"bpsc-as-btn-group bpsc-as-btn-group-center",style:{marginTop:"40px"}},(0,a.createElement)("a",{href:v(m||"#"),target:"_self",className:"bpsc-as-btn bpsc-as-btn-primary"},p))))},w=({attributes:e})=>{const{content:t,elements:s,deviceFrame:r}=e,{badgeText:n,title:c,subtitle:l,screenshots:o,featureList:i,primaryBtnText:p,primaryBtnUrl:m,primaryBtnTarget:d,secondaryBtnText:h,secondaryBtnUrl:g,secondaryBtnTarget:E}=t,{isBadge:y,isTitle:f,isSubtitle:w,isFeatureList:$,isPrimaryBtn:N,isSecondaryBtn:x}=s,k=o?.[0]||{url:"",alt:"App screenshot"};return(0,a.createElement)("section",{className:"bpsc-app-showcase-section bpsc-as-style-4"},(0,a.createElement)("div",{className:"bpsc-as-dark-bg","aria-hidden":"true"}),(0,a.createElement)("div",{className:"bpsc-as-container"},(0,a.createElement)("div",{className:"bpsc-as-centered-header bpsc-as-header-dark"},y&&n&&(0,a.createElement)("div",{className:"bpsc-as-badge-wrap"},(0,a.createElement)("span",{className:"bpsc-as-badge bpsc-as-badge-dark"},n)),f&&c&&(0,a.createElement)("h2",{className:"bpsc-as-title bpsc-as-title-dark"},c),w&&l&&(0,a.createElement)("p",{className:"bpsc-as-subtitle bpsc-as-subtitle-dark"},l)),(0,a.createElement)("div",{className:"bpsc-as-spotlight-device"},(0,a.createElement)("div",{className:"bpsc-as-glow-ring","aria-hidden":"true"}),(0,a.createElement)(b,{deviceFrame:{...r,showShadow:!0,shadowColor:"rgba(99,102,241,0.4)"},screenshot:k}),k.caption&&(0,a.createElement)("p",{className:"bpsc-as-caption bpsc-as-caption-dark bpsc-as-caption-center"},k.caption)),$&&i?.length>0&&(0,a.createElement)("div",{className:"bpsc-as-dark-grid"},i.map(((e,t)=>{const s=u[e.icon]||u.check;return(0,a.createElement)("div",{key:e.id||t,className:"bpsc-as-dark-grid-item"},(0,a.createElement)("div",{className:"bpsc-as-feature-icon bpsc-as-feature-icon-dark","aria-hidden":"true"},s),e.title&&(0,a.createElement)("h3",{className:"bpsc-as-feature-title bpsc-as-title-dark"},e.title),e.description&&(0,a.createElement)("p",{className:"bpsc-as-feature-desc bpsc-as-subtitle-dark"},e.description))}))),(N||x)&&(0,a.createElement)("div",{className:"bpsc-as-btn-group bpsc-as-btn-group-center",style:{marginTop:"40px"}},N&&p&&(0,a.createElement)("a",{href:v(m||"#"),target:d||"_self",rel:"_blank"===d?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-primary"},p),x&&h&&(0,a.createElement)("a",{href:v(g||"#"),target:E||"_self",rel:"_blank"===E?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-secondary bpsc-as-btn-secondary-dark"},h))))},$=({screenshots:e=[],deviceFrame:t,showDots:s=!0,showArrows:r=!0,showCaption:n=!0})=>{const[c,l]=(0,d.useState)(0);if(!e.length)return null;const o=e.length,i=e[c];return(0,a.createElement)("div",{className:"bpsc-as-carousel-wrap"},(0,a.createElement)("div",{className:"bpsc-as-carousel-frame"},(0,a.createElement)(b,{deviceFrame:t,screenshot:i}),r&&o>1&&(0,a.createElement)(a.Fragment,null,(0,a.createElement)("button",{type:"button",className:"bpsc-as-carousel-btn bpsc-as-carousel-prev",onClick:()=>l((e=>(e-1+o)%o)),"aria-label":"Previous screenshot"},(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"}))),(0,a.createElement)("button",{type:"button",className:"bpsc-as-carousel-btn bpsc-as-carousel-next",onClick:()=>l((e=>(e+1)%o)),"aria-label":"Next screenshot"},(0,a.createElement)("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},(0,a.createElement)("path",{d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}))))),n&&i.caption&&(0,a.createElement)("p",{className:"bpsc-as-caption"},i.caption),s&&o>1&&(0,a.createElement)("div",{className:"bpsc-as-carousel-dots",role:"tablist","aria-label":"Screenshot navigation"},e.map(((e,t)=>(0,a.createElement)("button",{key:e.id||t,type:"button",role:"tab","aria-selected":t===c,className:"bpsc-as-dot-btn"+(t===c?" bpsc-as-dot-active":""),onClick:()=>l(t),"aria-label":`Screenshot ${t+1}${e.alt?": "+e.alt:""}`})))))},N=({attributes:e})=>{const{content:t,elements:s,deviceFrame:r,carousel:n}=e,{badgeText:c,title:l,subtitle:o,screenshots:i,featureList:p,primaryBtnText:m,primaryBtnUrl:d,primaryBtnTarget:b}=t,{isBadge:u,isTitle:g,isSubtitle:E,isFeatureList:y,isPrimaryBtn:f}=s;return(0,a.createElement)("section",{className:"bpsc-app-showcase-section bpsc-as-style-5"},(0,a.createElement)("div",{className:"bpsc-as-container"},(0,a.createElement)("div",{className:"bpsc-as-gallery-grid"},(0,a.createElement)("div",{className:"bpsc-as-gallery-content"},u&&c&&(0,a.createElement)("div",{className:"bpsc-as-badge-wrap"},(0,a.createElement)("span",{className:"bpsc-as-badge"},c)),g&&l&&(0,a.createElement)("h2",{className:"bpsc-as-title"},l),E&&o&&(0,a.createElement)("p",{className:"bpsc-as-subtitle"},o),y&&p?.length>0&&(0,a.createElement)(h,{featureList:p,columns:1}),f&&m&&(0,a.createElement)("div",{className:"bpsc-as-btn-group",style:{marginTop:"32px"}},(0,a.createElement)("a",{href:v(d||"#"),target:b||"_self",rel:"_blank"===b?"noopener noreferrer":void 0,className:"bpsc-as-btn bpsc-as-btn-primary"},m))),(0,a.createElement)("div",{className:"bpsc-as-gallery-device"},(0,a.createElement)($,{screenshots:i||[],deviceFrame:r,showDots:!1!==n?.showDots,showArrows:!1!==n?.showArrows,showCaption:!0})))))},x=({attributes:e})=>{const{themeStyle:t}=e,s=t?.theme||"style-1";return(0,a.createElement)(a.Fragment,null,"style-1"===s&&(0,a.createElement)(E,{attributes:e}),"style-2"===s&&(0,a.createElement)(y,{attributes:e}),"style-3"===s&&(0,a.createElement)(f,{attributes:e}),"style-4"===s&&(0,a.createElement)(w,{attributes:e}),"style-5"===s&&(0,a.createElement)(N,{attributes:e}))};document.addEventListener("DOMContentLoaded",(()=>{document.querySelectorAll(".wp-block-bpsc-app-showcase-section").forEach((e=>{const t=JSON.parse(e.dataset.attributes);(0,s.H)(e).render((0,a.createElement)(a.Fragment,null,(0,a.createElement)(m,{attributes:t,id:e.id}),(0,a.createElement)(x,{attributes:t}))),e?.removeAttribute("data-attributes")}))}))})();