@blocklet/pages-kit-inner-components 0.4.76 → 0.4.78

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- "use strict";var Ve=Object.create;var pe=Object.defineProperty;var Ge=Object.getOwnPropertyDescriptor;var De=Object.getOwnPropertyNames;var Je=Object.getPrototypeOf,Ke=Object.prototype.hasOwnProperty;var Xe=(e,t,o,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of De(t))!Ke.call(e,r)&&r!==o&&pe(e,r,{get:()=>t[r],enumerable:!(i=Ge(t,r))||i.enumerable});return e};var xe=(e,t,o)=>(o=e!=null?Ve(Je(e)):{},Xe(t||!e||!e.__esModule?pe(o,"default",{value:e,enumerable:!0}):o,e));const n=require("react/jsx-runtime"),w=require("./state-BjeG4kYg.js"),ke=require("@arcblock/ux/lib/Locale/context"),Ye=require("@arcblock/ux/lib/Result"),Qe=require("@blocklet/pages-kit/builtin/page/header"),Ze=require("@blocklet/ui-react/lib/Header"),_=require("@emotion/css"),Q=require("@emotion/react"),et=require("@emotion/styled"),p=require("@mui/material"),$e=require("ahooks"),tt=require("isomorphic-dompurify"),A=require("lodash"),nt=require("lodash/isEmpty"),g=require("react"),ot=require("react-helmet"),B=require("react-router-dom"),U=require("react-use"),P=require("ufo");require("@mui/icons-material");const K=require("@blocklet/ai-runtime/components"),rt=require("@mui/utils"),it=require("lodash/pick"),st=require("react-error-boundary"),ee=require("@iconify/react"),at=require("react-markdown"),ct=require("remark-gfm"),lt=require("@mui/lab"),$=require("@arcblock/ux/lib/Theme"),dt=require("@arcblock/react-hooks/lib/useBrowser"),ut=require("@arcblock/ux/lib/Colors"),re=require("@blocklet/pages-kit/components"),mt=require("@mui/material/useMediaQuery"),Se=require("@iconify-icon/react"),pt=require("@arcblock/ux/lib/Screenshot"),xt=require("lodash/omit"),ft=require("@arcblock/ux/lib/Button"),ht=require("is-uri"),X=require("pathe"),gt=require("@blocklet/embed/message"),bt=require("lodash/isEqual"),yt=require("@blocklet/embed/react"),jt=require("react-twitter-embed"),wt=require("@blocklet/ui-react/lib/Footer"),_t=require("webfontloader"),vt=require("@arcblock/did-connect/lib/Session"),S=e=>e&&e.__esModule?e:{default:e},Ce=S(Ye),kt=S(Ze),Be=S(et),$t=S(tt),St=S(nt),Ie=S(g),ie=S(it),Ct=S(at),Bt=S(ct),It=S(dt),fe=S(ut),Ne=S(mt),Nt=S(pt),q=S(xt),Pt=S(ft),te=S(ht),Rt=S(bt),Tt=S(wt),qt=S(_t);function Et(e,t,o,i){e.locales||(e.locales={}),e.locales[o]=e.locales[o]||{},e.locales[o].title=i.title??e.locales[o].title,e.locales[o].image=i.image??e.locales[o].image,e.locales[o].description=i.description??e.locales[o].description,Object.entries(i.sectionsData).forEach(([r,s])=>{var c,l,d,m;const a=Object.values(e.sections).find(u=>u.id===r||u.name===r);if(a&&a.isTemplateSection)if(a.locales=a.locales||{},a.locales[o]=a.locales[o]||{},a.component==="custom-component"){const u=(c=a.config)==null?void 0:c.componentId;if(!u)return;const f=((l=t.components[u])==null?void 0:l.data)||((m=(d=t.resources.components)==null?void 0:d[u])==null?void 0:m.component);if(!f)return;a.locales[o].properties=a.locales[o].properties||{},Object.entries(s||{}).forEach(([x,y])=>{var h,v;const j=((h=f==null?void 0:f.properties)==null?void 0:h[x])||Object.values((f==null?void 0:f.properties)||{}).find(b=>{var k;return((k=b.data)==null?void 0:k.key)===x});j&&(a.locales[o].properties[(v=j.data)==null?void 0:v.id]={value:y})})}else a.locales[o]={...a.locales[o],...s||{}}})}const zt=g.forwardRef(({onClick:e,...t},o)=>{const[i,r]=g.useState(!1),s=g.useCallback(async a=>{try{r(!0),await(e==null?void 0:e(a))}finally{r(!1)}},[e]);return n.jsx(lt.LoadingButton,{ref:o,...t,loading:t.loading||i,onClick:s})});function Wt({tip:e,tipSucceed:t,title:o,titleSucceed:i,icon:r,iconSucceed:s,autoReset:a,placement:c="top",...l}){const[d,m]=g.useState(!1),[u,f]=g.useState(),x=g.useRef(),y=()=>{f(void 0),a&&(x.current=window.setTimeout(()=>{m(!1)},3e3))},j=()=>{clearTimeout(x.current)},h=d?s:r,v=u?n.jsx(p.Box,{color:"error",children:u.message}):d&&t||e,b=d?i:o;return n.jsx(p.Tooltip,{title:v,disableInteractive:!0,placement:c,onClose:y,onOpen:j,children:n.jsx("span",{children:n.jsx(zt,{startIcon:h&&(typeof h=="string"?n.jsx(ee.Icon,{icon:h}):h),loadingPosition:h?"start":void 0,...l,onClick:async k=>{if(l.onClick)try{await l.onClick(k),m(!0)}catch(N){f(N)}},children:b})})})}const Lt=Ie.default.lazy(()=>import("react-syntax-highlighter").then(e=>({default:e.Prism}))),At=p.styled(e=>n.jsx(Ct.default,{...e,remarkPlugins:[Bt.default],components:{pre:Ot,code:({node:t,inline:o,className:i,children:r,...s})=>{if(!r)return null;const a=/language-(\w+)/.exec(i||"");return o?n.jsx(p.Box,{component:"code",className:i,...s,children:r}):n.jsx(p.Box,{component:Lt,language:a==null?void 0:a[1],...s,sx:{borderRadius:1},children:String(r).replace(/\n$/,"")})},table:({className:t,children:o})=>n.jsx(p.Box,{sx:{overflow:"auto",my:1},children:n.jsx("table",{className:t,children:o})})}}))`
1
+ "use strict";var Ve=Object.create;var pe=Object.defineProperty;var Ge=Object.getOwnPropertyDescriptor;var De=Object.getOwnPropertyNames;var Je=Object.getPrototypeOf,Ke=Object.prototype.hasOwnProperty;var Xe=(e,t,o,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of De(t))!Ke.call(e,r)&&r!==o&&pe(e,r,{get:()=>t[r],enumerable:!(i=Ge(t,r))||i.enumerable});return e};var xe=(e,t,o)=>(o=e!=null?Ve(Je(e)):{},Xe(t||!e||!e.__esModule?pe(o,"default",{value:e,enumerable:!0}):o,e));const n=require("react/jsx-runtime"),w=require("./state-BjeG4kYg.js"),ke=require("@arcblock/ux/lib/Locale/context"),Ye=require("@arcblock/ux/lib/Result"),Qe=require("@blocklet/pages-kit/builtin/page/header"),Ze=require("@blocklet/ui-react/lib/Header"),_=require("@emotion/css"),Q=require("@emotion/react"),et=require("@emotion/styled"),p=require("@mui/material"),$e=require("ahooks"),tt=require("isomorphic-dompurify"),A=require("lodash"),nt=require("lodash/isEmpty"),g=require("react"),ot=require("react-helmet"),B=require("react-router-dom"),U=require("react-use"),R=require("ufo");require("@mui/icons-material");const K=require("@blocklet/ai-runtime/components"),rt=require("@mui/utils"),it=require("lodash/pick"),st=require("react-error-boundary"),ee=require("@iconify/react"),at=require("react-markdown"),ct=require("remark-gfm"),lt=require("@mui/lab"),$=require("@arcblock/ux/lib/Theme"),dt=require("@arcblock/react-hooks/lib/useBrowser"),ut=require("@arcblock/ux/lib/Colors"),re=require("@blocklet/pages-kit/components"),mt=require("@mui/material/useMediaQuery"),Se=require("@iconify-icon/react"),pt=require("@arcblock/ux/lib/Screenshot"),xt=require("lodash/omit"),ft=require("@arcblock/ux/lib/Button"),ht=require("is-uri"),X=require("pathe"),gt=require("@blocklet/embed/message"),bt=require("lodash/isEqual"),yt=require("@blocklet/embed/react"),jt=require("react-twitter-embed"),wt=require("@blocklet/ui-react/lib/Footer"),_t=require("webfontloader"),vt=require("@arcblock/did-connect/lib/Session"),S=e=>e&&e.__esModule?e:{default:e},Ce=S(Ye),kt=S(Ze),Be=S(et),$t=S(tt),St=S(nt),Ie=S(g),ie=S(it),Ct=S(at),Bt=S(ct),It=S(dt),fe=S(ut),Ne=S(mt),Nt=S(pt),q=S(xt),Rt=S(ft),te=S(ht),Pt=S(bt),Tt=S(wt),qt=S(_t);function Et(e,t,o,i){e.locales||(e.locales={}),e.locales[o]=e.locales[o]||{},e.locales[o].title=i.title??e.locales[o].title,e.locales[o].image=i.image??e.locales[o].image,e.locales[o].description=i.description??e.locales[o].description,Object.entries(i.sectionsData).forEach(([r,s])=>{var c,l,d,m;const a=Object.values(e.sections).find(u=>u.id===r||u.name===r);if(a&&a.isTemplateSection)if(a.locales=a.locales||{},a.locales[o]=a.locales[o]||{},a.component==="custom-component"){const u=(c=a.config)==null?void 0:c.componentId;if(!u)return;const f=((l=t.components[u])==null?void 0:l.data)||((m=(d=t.resources.components)==null?void 0:d[u])==null?void 0:m.component);if(!f)return;a.locales[o].properties=a.locales[o].properties||{},Object.entries(s||{}).forEach(([x,y])=>{var h,v;const j=((h=f==null?void 0:f.properties)==null?void 0:h[x])||Object.values((f==null?void 0:f.properties)||{}).find(b=>{var k;return((k=b.data)==null?void 0:k.key)===x});j&&(a.locales[o].properties[(v=j.data)==null?void 0:v.id]={value:y})})}else a.locales[o]={...a.locales[o],...s||{}}})}const zt=g.forwardRef(({onClick:e,...t},o)=>{const[i,r]=g.useState(!1),s=g.useCallback(async a=>{try{r(!0),await(e==null?void 0:e(a))}finally{r(!1)}},[e]);return n.jsx(lt.LoadingButton,{ref:o,...t,loading:t.loading||i,onClick:s})});function Wt({tip:e,tipSucceed:t,title:o,titleSucceed:i,icon:r,iconSucceed:s,autoReset:a,placement:c="top",...l}){const[d,m]=g.useState(!1),[u,f]=g.useState(),x=g.useRef(),y=()=>{f(void 0),a&&(x.current=window.setTimeout(()=>{m(!1)},3e3))},j=()=>{clearTimeout(x.current)},h=d?s:r,v=u?n.jsx(p.Box,{color:"error",children:u.message}):d&&t||e,b=d?i:o;return n.jsx(p.Tooltip,{title:v,disableInteractive:!0,placement:c,onClose:y,onOpen:j,children:n.jsx("span",{children:n.jsx(zt,{startIcon:h&&(typeof h=="string"?n.jsx(ee.Icon,{icon:h}):h),loadingPosition:h?"start":void 0,...l,onClick:async k=>{if(l.onClick)try{await l.onClick(k),m(!0)}catch(N){f(N)}},children:b})})})}const Lt=Ie.default.lazy(()=>import("react-syntax-highlighter").then(e=>({default:e.Prism}))),At=p.styled(e=>n.jsx(Ct.default,{...e,remarkPlugins:[Bt.default],components:{pre:Ot,code:({node:t,inline:o,className:i,children:r,...s})=>{if(!r)return null;const a=/language-(\w+)/.exec(i||"");return o?n.jsx(p.Box,{component:"code",className:i,...s,children:r}):n.jsx(p.Box,{component:Lt,language:a==null?void 0:a[1],...s,sx:{borderRadius:1},children:String(r).replace(/\n$/,"")})},table:({className:t,children:o})=>n.jsx(p.Box,{sx:{overflow:"auto",my:1},children:n.jsx("table",{className:t,children:o})})}}))`
2
2
  width: 100%;
3
3
  overflow: hidden;
4
4
  word-break: break-word;
@@ -130,7 +130,7 @@
130
130
  margin-bottom: 40px;
131
131
  }
132
132
  }
133
- `;function H({title:e,description:t,descriptionMarkdown:o,actions:i,className:r="",classes:s={},prepend:a,append:c,level:l=2,tag:d,badge:m,center:u,logo:f,titleAppearance:x,descriptionAppearance:y,...j}){if(!e&&!t&&!i&&!m&&!d&&!a&&!c&&!f)return null;const h=Math.max(Math.min(5,l+1),1),v={1:"xl:!text-3xl lg:!text-2xl md:!text-xl",2:"xl:!text-2xl lg:!text-xl md:!text-lg",3:"xl:!text-2xl lg:!text-xl md:!text-lg",4:"xl:!text-xl lg:!text-lg md:!text-md",5:"xl:!text-lg md:!text-md sm:!text-sm",6:"!text-sm"},b=l===0?"big":`h${h}`,k=l===0;return n.jsxs(Ht,{className:_.cx("base-info","lg:text-left",u&&"!text-center",r),...j,children:[a&&n.jsx("div",{children:a}),(d||m)&&n.jsx("div",{className:_.cx("section__tag",(s==null?void 0:s.tag)||(s==null?void 0:s.badge)),children:d||m}),f&&n.jsx("img",{className:"w-[120px] m-auto mb-8",src:f,alt:"info",loading:"lazy"}),e&&n.jsx(p.Typography,{sx:{whiteSpace:"pre-wrap",mb:t?"2vw":0,...(x==null?void 0:x.color)&&{color:`${x.color} !important`}},className:_.cx("section__title","text-gray-800","dark:text-gray-50",s.title,"page-kit-section__title",k?"":"section__title_non_big"),component:`h${Math.max(l,1)}`,variant:b,children:e}),t&&(o?n.jsx(p.Box,{sx:{...(y==null?void 0:y.color)&&{color:`${y.color} !important`}},component:At,className:_.cx("section__description","text-gray-800","dark:text-gray-100",v[h],s.description,"page-kit-section__description"),children:t}):n.jsx(p.Typography,{sx:{whiteSpace:"pre-wrap",...(y==null?void 0:y.color)&&{color:`${y.color} !important`}},className:_.cx("section__description","text-gray-800","dark:text-gray-100",v[h],s.description,"page-kit-section__description"),component:"div",variant:"body1",gutterBottom:!0,children:t})),n.jsx(z,{actions:i,center:u,className:"mt-8"}),c&&n.jsx("div",{children:c})]})}const M=["actions","append","badge","tag","center","description","descriptionMarkdown","level","logo","prepend","title","titleAppearance","descriptionAppearance"];function Pe(e){if(e.type===g.Fragment){const o=(e.props.children||[]).filter(i=>g.isValidElement(i));return o.length===1?Pe(o[0]):o.length>1}return Array.isArray(e)}const R="&>*";function se({children:e,col:t,gap:o,className:i,align:r,sx:s,type:a,...c}={children:null,className:"",col:3,gap:void 0,sx:{},align:"center",type:"default"}){const l=$.useTheme(),d=Number(Math.floor(100/t*100)/100),m={center:"justify-center items-center",left:"justify-start items-center",right:"justify-end items-center",top:"justify-center items-start",bottom:"justify-center items-end","top-left":"justify-start items-start","top-right":"justify-end items-start","bottom-left":"justify-start items-end","bottom-right":"justify-end items-end"},u=m[r]||m.center;let x=o??({2:6,3:4,4:4,5:3,6:3}[t]||0);Pe(e)||(x=0);const j=(t-1)*x/t;let h={...s,gap:`${x}rem`};const v={[R]:{width:"100%"}},b={},k={},N={};switch(v.gap="1rem",b.gap=`${x/2}rem`,t){case 3:case 4:b[R]={width:`calc(50% - ${x/2}rem)`};break;case 5:case 6:v[R]={width:`calc(50% - ${x/2/2}rem)`},b[R]={width:`calc(50% - ${x/2/2}rem)`},k[R]={width:`calc(33.33% - ${x*2/3}rem)`};break}return h[R]={width:`calc(${d}% - ${j}rem)`},h[`@media (max-width: ${l.breakpoints.values.xl}px)`]=N,h[`@media (max-width: ${l.breakpoints.values.lg}px)`]=k,h[`@media (max-width: ${l.breakpoints.values.md}px)`]=b,h[`@media (max-width: ${l.breakpoints.values.sm}px)`]=v,a==="wall"&&(h={...s,gap:`${x}rem`},h[R]={width:`calc(${d}% - ${j}rem)`},v[R]={width:`calc(45% - ${x/2/2}rem)`},h[`@media (max-width: ${l.breakpoints.values.sm}px)`]=v),n.jsx(p.Box,{className:_.cx("flex flex-wrap flex-row h-full",u,i),sx:h,...c,children:e})}function Mt(){const e=navigator.userAgent.toLowerCase();return e.includes("safari")&&!e.includes("chrome")}function Ft(e=""){if(e.startsWith("data:image/svg+xml,"))return!0;const t=/^(((ht|f)tps?):\/\/)?([^!@#$%^&*?.\s-]([^!@#$%^&*?.\s]{0,63}[^!@#$%^&*?.\s])?\.)+[a-z]{2,6}\/?/,o=/^(\/|\.\/|\.\.\/)(?:[^/]+\/)*[^/]+$/;return t.test(e)||o.test(e)}function ne(e){return(e==null?void 0:e.endsWith(".mp4"))||(e==null?void 0:e.endsWith(".m4v"))||(e==null?void 0:e.endsWith(".webm"))}function Vt(e){return e!=null&&e.endsWith(".mp4")||e!=null&&e.endsWith(".m4v")?"video/mp4":e!=null&&e.endsWith(".webm")?"video/webm":void 0}function Gt(e){let t={};return typeof e=="string"?w.isGradient(e)?t.image=e:(t.image=w.getImageAbsoluteUrl(e),w.isColorString(e)&&(t.color=e,t.image="")):t=e,t}function Dt(){const[e,t]=g.useState(Date.now());return g.useEffect(()=>{const o=()=>{t(Date.now())};return document.addEventListener("visibilitychange",o),()=>{document.removeEventListener("visibilitychange",o)}},[]),e}function he(e,t,o,i,r){let s=null;const{color:a="",image:c}=Gt(t);return c&&Ft(c)?(delete o.backgroundColor,!(e.mobile.apple.device||Mt())&&ne(c)?s=n.jsx(p.Box,{component:"video",className:"section-bg",width:"100%",autoPlay:!0,loop:!0,muted:!0,controls:!1,playsInline:!0,poster:w.autoResizeImage(w.getImageAbsoluteUrl(i),1200,"quality"),src:ne(c)?c:w.autoResizeImage(c,1200,"quality"),sx:{position:"absolute",zIndex:-9999,right:0,left:0,top:0,width:"100%",height:"100%",objectFit:"cover"}},c):s=n.jsx(re.ResponsiveImage,{src:c,sizesAttr:{sm:600,md:900,lg:1200},className:"section-bg",alt:"",width:"100%",loading:"lazy",sx:{position:"absolute",zIndex:-9999,right:0,left:0,top:0,width:"100%",height:"100%",objectFit:"cover"}},r||c)):c?o.backgroundImage=`${c} !important`:a&&(o.backgroundColor=`${a} !important`),s}function Jt({autoWidth:e,children:t,...o}){return e?n.jsx(p.Box,{display:"flex",...o,children:t}):n.jsx(p.Container,{...o,children:t})}function F({dark:e=!1,children:t,className:o,sx:i={},boxed:r={show:!1},padding:s="normal",boxProps:a,type:c,...l}){const d={...i},m=Ne.default(x=>x.breakpoints.down("md"));e&&(d.color=fe.default.common.white,d.backgroundColor=`${fe.default.grey[900]} !important`);const u={none:"py-0",small:"py-5 md:py-8 lg:py-8 xl:py-12",normal:"py-10 md:py-15 lg:py-20 xl:py-25",large:"py-15 md:py-20 lg:py-25 xl:py-30"};r.show&&(d.display="flex");const f=g.useMemo(()=>!Number(l.boxMaxWidth)||m?{width:"100%"}:c==="wall"&&l.boxMaxWidth?{maxWidth:`${l.boxMaxWidth}px !important`,width:"100%"}:{width:"100%"},[l.boxMaxWidth,m,c]);return n.jsx(Kt,{component:"section",styles:{...d},className:_.cx("base-section","px-2 md:px-5 lg:px-5 xl:px-10",u[s],o,{dark:e}),...A.omit(l,"hoverStyle","boxMaxWidth","embedUrl","autoWidth","paddingXY","iframeHeight","titleAppearance","descriptionAppearance"),children:n.jsx(Jt,{autoWidth:l==null?void 0:l.autoWidth,className:_.cx("section-content h-full"),sx:f,children:r.show?n.jsx(Re,{...a,boxed:r,children:t}):t})})}function Re({background:e="",backgroundVideoPoster:t,children:o,sx:i={},boxed:r={show:!1},className:s="",styles:a={},...c}){const l={...a,...i};let d=null;const m=Ne.default(x=>x.breakpoints.up("sm")),u=It.default(),f=Dt();return e&&(d=he(u,e,l,t,f)),r.show&&(l.borderRadius="10px",l.padding===void 0&&(l.padding=m?"50px":"20px"),r!=null&&r.border&&(l.border="1px solid #c0c0c0"),r!=null&&r.background&&(d=he(u,r==null?void 0:r.background,l,r==null?void 0:r.backgroundVideoPoster,f))),n.jsxs(p.Box,{...c,sx:{...l,...d?{position:"relative",overflow:"hidden",zIndex:0}:{}},className:_.cx(s,(r==null?void 0:r.boxShadow)&&"shadow-xl"),children:[d,o]})}const Kt=$.styled(Re)`
133
+ `;function H({title:e,description:t,descriptionMarkdown:o,actions:i,className:r="",classes:s={},prepend:a,append:c,level:l=2,tag:d,badge:m,center:u,logo:f,titleAppearance:x,descriptionAppearance:y,...j}){if(!e&&!t&&!i&&!m&&!d&&!a&&!c&&!f)return null;const h=Math.max(Math.min(5,l+1),1),v={1:"xl:!text-3xl lg:!text-2xl md:!text-xl",2:"xl:!text-2xl lg:!text-xl md:!text-lg",3:"xl:!text-2xl lg:!text-xl md:!text-lg",4:"xl:!text-xl lg:!text-lg md:!text-md",5:"xl:!text-lg md:!text-md sm:!text-sm",6:"!text-sm"},b=l===0?"big":`h${h}`,k=l===0;return n.jsxs(Ht,{className:_.cx("base-info","lg:text-left",u&&"!text-center",r),...j,children:[a&&n.jsx("div",{children:a}),(d||m)&&n.jsx("div",{className:_.cx("section__tag",(s==null?void 0:s.tag)||(s==null?void 0:s.badge)),children:d||m}),f&&n.jsx("img",{className:"w-[120px] m-auto mb-8",src:f,alt:"info",loading:"lazy"}),e&&n.jsx(p.Typography,{sx:{whiteSpace:"pre-wrap",mb:t?"2vw":0,...(x==null?void 0:x.color)&&{color:`${x.color} !important`}},className:_.cx("section__title","text-gray-800","dark:text-gray-50",s.title,"page-kit-section__title",k?"":"section__title_non_big"),component:`h${Math.max(l,1)}`,variant:b,children:e}),t&&(o?n.jsx(p.Box,{sx:{...(y==null?void 0:y.color)&&{color:`${y.color} !important`}},component:At,className:_.cx("section__description","text-gray-800","dark:text-gray-100",v[h],s.description,"page-kit-section__description"),children:t}):n.jsx(p.Typography,{sx:{whiteSpace:"pre-wrap",...(y==null?void 0:y.color)&&{color:`${y.color} !important`}},className:_.cx("section__description","text-gray-800","dark:text-gray-100",v[h],s.description,"page-kit-section__description"),component:"div",variant:"body1",gutterBottom:!0,children:t})),n.jsx(z,{actions:i,center:u,className:"mt-8"}),c&&n.jsx("div",{children:c})]})}const M=["actions","append","badge","tag","center","description","descriptionMarkdown","level","logo","prepend","title","titleAppearance","descriptionAppearance"];function Re(e){if(e.type===g.Fragment){const o=(e.props.children||[]).filter(i=>g.isValidElement(i));return o.length===1?Re(o[0]):o.length>1}return Array.isArray(e)}const P="&>*";function se({children:e,col:t,gap:o,className:i,align:r,sx:s,type:a,...c}={children:null,className:"",col:3,gap:void 0,sx:{},align:"center",type:"default"}){const l=$.useTheme(),d=Number(Math.floor(100/t*100)/100),m={center:"justify-center items-center",left:"justify-start items-center",right:"justify-end items-center",top:"justify-center items-start",bottom:"justify-center items-end","top-left":"justify-start items-start","top-right":"justify-end items-start","bottom-left":"justify-start items-end","bottom-right":"justify-end items-end"},u=m[r]||m.center;let x=o??({2:6,3:4,4:4,5:3,6:3}[t]||0);Re(e)||(x=0);const j=(t-1)*x/t;let h={...s,gap:`${x}rem`};const v={[P]:{width:"100%"}},b={},k={},N={};switch(v.gap="1rem",b.gap=`${x/2}rem`,t){case 3:case 4:b[P]={width:`calc(50% - ${x/2}rem)`};break;case 5:case 6:v[P]={width:`calc(50% - ${x/2/2}rem)`},b[P]={width:`calc(50% - ${x/2/2}rem)`},k[P]={width:`calc(33.33% - ${x*2/3}rem)`};break}return h[P]={width:`calc(${d}% - ${j}rem)`},h[`@media (max-width: ${l.breakpoints.values.xl}px)`]=N,h[`@media (max-width: ${l.breakpoints.values.lg}px)`]=k,h[`@media (max-width: ${l.breakpoints.values.md}px)`]=b,h[`@media (max-width: ${l.breakpoints.values.sm}px)`]=v,a==="wall"&&(h={...s,gap:`${x}rem`},h[P]={width:`calc(${d}% - ${j}rem)`},v[P]={width:`calc(45% - ${x/2/2}rem)`},h[`@media (max-width: ${l.breakpoints.values.sm}px)`]=v),n.jsx(p.Box,{className:_.cx("flex flex-wrap flex-row h-full",u,i),sx:h,...c,children:e})}function Mt(){const e=navigator.userAgent.toLowerCase();return e.includes("safari")&&!e.includes("chrome")}function Ft(e=""){if(e.startsWith("data:image/svg+xml,"))return!0;const t=/^(((ht|f)tps?):\/\/)?([^!@#$%^&*?.\s-]([^!@#$%^&*?.\s]{0,63}[^!@#$%^&*?.\s])?\.)+[a-z]{2,6}\/?/,o=/^(\/|\.\/|\.\.\/)(?:[^/]+\/)*[^/]+$/;return t.test(e)||o.test(e)}function ne(e){return(e==null?void 0:e.endsWith(".mp4"))||(e==null?void 0:e.endsWith(".m4v"))||(e==null?void 0:e.endsWith(".webm"))}function Vt(e){return e!=null&&e.endsWith(".mp4")||e!=null&&e.endsWith(".m4v")?"video/mp4":e!=null&&e.endsWith(".webm")?"video/webm":void 0}function Gt(e){let t={};return typeof e=="string"?w.isGradient(e)?t.image=e:(t.image=w.getImageAbsoluteUrl(e),w.isColorString(e)&&(t.color=e,t.image="")):t=e,t}function Dt(){const[e,t]=g.useState(Date.now());return g.useEffect(()=>{const o=()=>{t(Date.now())};return document.addEventListener("visibilitychange",o),()=>{document.removeEventListener("visibilitychange",o)}},[]),e}function he(e,t,o,i,r){let s=null;const{color:a="",image:c}=Gt(t);return c&&Ft(c)?(delete o.backgroundColor,!(e.mobile.apple.device||Mt())&&ne(c)?s=n.jsx(p.Box,{component:"video",className:"section-bg",width:"100%",autoPlay:!0,loop:!0,muted:!0,controls:!1,playsInline:!0,poster:w.autoResizeImage(w.getImageAbsoluteUrl(i),1200,"quality"),src:ne(c)?c:w.autoResizeImage(c,1200,"quality"),sx:{position:"absolute",zIndex:-9999,right:0,left:0,top:0,width:"100%",height:"100%",objectFit:"cover"}},c):s=n.jsx(re.ResponsiveImage,{src:c,sizesAttr:{sm:600,md:900,lg:1200},className:"section-bg",alt:"",width:"100%",loading:"lazy",sx:{position:"absolute",zIndex:-9999,right:0,left:0,top:0,width:"100%",height:"100%",objectFit:"cover"}},r||c)):c?o.backgroundImage=`${c} !important`:a&&(o.backgroundColor=`${a} !important`),s}function Jt({autoWidth:e,children:t,...o}){return e?n.jsx(p.Box,{display:"flex",...o,children:t}):n.jsx(p.Container,{...o,children:t})}function F({dark:e=!1,children:t,className:o,sx:i={},boxed:r={show:!1},padding:s="normal",boxProps:a,type:c,...l}){const d={...i},m=Ne.default(x=>x.breakpoints.down("md"));e&&(d.color=fe.default.common.white,d.backgroundColor=`${fe.default.grey[900]} !important`);const u={none:"py-0",small:"py-5 md:py-8 lg:py-8 xl:py-12",normal:"py-10 md:py-15 lg:py-20 xl:py-25",large:"py-15 md:py-20 lg:py-25 xl:py-30"};r.show&&(d.display="flex");const f=g.useMemo(()=>!Number(l.boxMaxWidth)||m?{width:"100%"}:c==="wall"&&l.boxMaxWidth?{maxWidth:`${l.boxMaxWidth}px !important`,width:"100%"}:{width:"100%"},[l.boxMaxWidth,m,c]);return n.jsx(Kt,{component:"section",styles:{...d},className:_.cx("base-section","px-2 md:px-5 lg:px-5 xl:px-10",u[s],o,{dark:e}),...A.omit(l,"hoverStyle","boxMaxWidth","embedUrl","autoWidth","paddingXY","iframeHeight","titleAppearance","descriptionAppearance"),children:n.jsx(Jt,{autoWidth:l==null?void 0:l.autoWidth,className:_.cx("section-content h-full"),sx:f,children:r.show?n.jsx(Pe,{...a,boxed:r,children:t}):t})})}function Pe({background:e="",backgroundVideoPoster:t,children:o,sx:i={},boxed:r={show:!1},className:s="",styles:a={},...c}){const l={...a,...i};let d=null;const m=Ne.default(x=>x.breakpoints.up("sm")),u=It.default(),f=Dt();return e&&(d=he(u,e,l,t,f)),r.show&&(l.borderRadius="10px",l.padding===void 0&&(l.padding=m?"50px":"20px"),r!=null&&r.border&&(l.border="1px solid #c0c0c0"),r!=null&&r.background&&(d=he(u,r==null?void 0:r.background,l,r==null?void 0:r.backgroundVideoPoster,f))),n.jsxs(p.Box,{...c,sx:{...l,...d?{position:"relative",overflow:"hidden",zIndex:0}:{}},className:_.cx(s,(r==null?void 0:r.boxShadow)&&"shadow-xl"),children:[d,o]})}const Kt=$.styled(Pe)`
134
134
  &:nth-of-type(even) {
135
135
  background: #f8f8f8;
136
136
  }
@@ -182,7 +182,7 @@
182
182
  }
183
183
  `,ae=e=>typeof e=="string"&&/^[\w-_]+:[\w-_]+$/.test(e);function oe({icon:e,size:t="1rem",imageMeta:o,...i}){const r=window.isNaN(t)?t:`${t}px`;return ae(e)?n.jsx(Se.Icon,{icon:e}):n.jsx(sn,{component:on,imageMeta:o,className:"base-icon",icon:e,size:r,...i})}const sn=$.styled(p.Box)`
184
184
  flex-shrink: 0;
185
- `;function O({text:e,children:t,icon:o="",endIcon:i,color:r="primary",link:s="",href:a="",...c}){const l=o?n.jsx(oe,{icon:o}):null,d=i?n.jsx(oe,{icon:i}):null,m=s||a,u={...c};return m&&(u.href=m,te.default(m)&&(u.target=u.target||"_blank")),n.jsx(Pt.default,{startIcon:l,endIcon:d,color:r,...u,children:e||t})}function We({editing:e,text:t,...o}){const{pages:i=[]}=ze(),r=i.find(s=>s.id===(o.link||o.linkId));if(e)return n.jsx(O,{...q.default(o,["link","linkId"]),children:t});if(r){const s=r.path||"/";return n.jsx(B.Link,{to:s,children:n.jsx(O,{...q.default(o,["link","linkId"]),children:t})})}return n.jsx(O,{...q.default(o,"linkId"),children:t})}function T({type:e="",icon:t="",size:o="3rem",className:i="",...r}){return n.jsx(oe,{icon:t||e,size:o,className:_.cx("content-icon",i),...r})}T.propTypes={};T.defaultProps={type:"",icon:"",size:"3rem",color:"inherit",className:""};function an({to:e,base:t,children:o,className:i,activeClassName:r="active",target:s="auto",autoExternalMark:a=!1,useRouterLink:c,...l}){const{pages:d=[],locale:m=""}={},u=t?X.join("/",t):t||"";let f=s==="auto"?"_self":s,x=X.join(u,e);const y=a?te.default(x):!1;if(t)return x=X.join(u,m,e),n.jsx("a",{className:`no-underline ${i}`,href:P.withoutTrailingSlash(x),rel:"noreferrer noopener",target:f,...l,children:o});if(te.default(e))s==="auto"&&(f="_blank"),x=e;else{P.isRelative(x)&&(x=X.join(window.location.pathname,x));const j=P.parseURL(`${window.location.origin}${x}`),h=d.some(v=>v.pathname===j.pathname);if(c||h)return n.jsx(B.NavLink,{end:!0,to:P.withoutTrailingSlash(x),className:({isActive:v})=>_.cx(i,v?r:""),...l,children:o})}return n.jsxs("a",{className:`no-underline ${i}`,href:P.withoutTrailingSlash(x),rel:"noreferrer noopener",target:f,...l,children:[o,y&&n.jsx(T,{icon:"i-mdi:arrow-top-right",size:"0.9em",className:"smart-link__mark",style:{marginLeft:5}})]})}function G({prepend:e,append:t,children:o,className:i="",dark:r=!1,border:s=!0,...a}){let c={};const{pages:l=[]}=ze(),d=l.find(f=>f.id===a.link),m=!o||Ie.default.Children.toArray(o).every(f=>f===null);a.link&&(c={component:an,to:(d==null?void 0:d.path)||a.link,useRouterLink:!0});const u=r&&s;return n.jsxs(cn,{className:_.cx("base-card card",{"border-gray-200":s},{"dark:border-gray-500":u},{dark:r,"border-transparent":!s},i),...c,...q.default(a,["listType","dark","iconColor","link","hoverStyle","imageSize"]),children:[e,!m&&n.jsx("div",{className:"card__body",children:o}),t]})}const cn=$.styled(p.Box)`
185
+ `;function O({text:e,children:t,icon:o="",endIcon:i,color:r="primary",link:s="",href:a="",...c}){const l=o?n.jsx(oe,{icon:o}):null,d=i?n.jsx(oe,{icon:i}):null,m=s||a,u={...c};return m&&(u.href=m,te.default(m)&&(u.target=u.target||"_blank")),n.jsx(Rt.default,{startIcon:l,endIcon:d,color:r,...u,children:e||t})}function We({editing:e,text:t,...o}){const{pages:i=[]}=ze(),r=i.find(s=>s.id===(o.link||o.linkId));if(e)return n.jsx(O,{...q.default(o,["link","linkId"]),children:t});if(r){const s=r.path||"/";return n.jsx(B.Link,{to:s,children:n.jsx(O,{...q.default(o,["link","linkId"]),children:t})})}return n.jsx(O,{...q.default(o,"linkId"),children:t})}function T({type:e="",icon:t="",size:o="3rem",className:i="",...r}){return n.jsx(oe,{icon:t||e,size:o,className:_.cx("content-icon",i),...r})}T.propTypes={};T.defaultProps={type:"",icon:"",size:"3rem",color:"inherit",className:""};function an({to:e,base:t,children:o,className:i,activeClassName:r="active",target:s="auto",autoExternalMark:a=!1,useRouterLink:c,...l}){const{pages:d=[],locale:m=""}={},u=t?X.join("/",t):t||"";let f=s==="auto"?"_self":s,x=X.join(u,e);const y=a?te.default(x):!1;if(t)return x=X.join(u,m,e),n.jsx("a",{className:`no-underline ${i}`,href:R.withoutTrailingSlash(x),rel:"noreferrer noopener",target:f,...l,children:o});if(te.default(e))s==="auto"&&(f="_blank"),x=e;else{R.isRelative(x)&&(x=X.join(window.location.pathname,x));const j=R.parseURL(`${window.location.origin}${x}`),h=d.some(v=>v.pathname===j.pathname);if(c||h)return n.jsx(B.NavLink,{end:!0,to:R.withoutTrailingSlash(x),className:({isActive:v})=>_.cx(i,v?r:""),...l,children:o})}return n.jsxs("a",{className:`no-underline ${i}`,href:R.withoutTrailingSlash(x),rel:"noreferrer noopener",target:f,...l,children:[o,y&&n.jsx(T,{icon:"i-mdi:arrow-top-right",size:"0.9em",className:"smart-link__mark",style:{marginLeft:5}})]})}function G({prepend:e,append:t,children:o,className:i="",dark:r=!1,border:s=!0,...a}){let c={};const{pages:l=[]}=ze(),d=l.find(f=>f.id===a.link),m=!o||Ie.default.Children.toArray(o).every(f=>f===null);a.link&&(c={component:an,to:(d==null?void 0:d.path)||a.link,useRouterLink:!0});const u=r&&s;return n.jsxs(cn,{className:_.cx("base-card card",{"border-gray-200":s},{"dark:border-gray-500":u},{dark:r,"border-transparent":!s},i),...c,...q.default(a,["listType","dark","iconColor","link","hoverStyle","imageSize"]),children:[e,!m&&n.jsx("div",{className:"card__body",children:o}),t]})}const cn=$.styled(p.Box)`
186
186
  &.base-card {
187
187
  text-align: left;
188
188
  border-width: 1px;
@@ -470,15 +470,15 @@
470
470
  .card-simple .card__body::after {
471
471
  background: inherit !important;
472
472
  }
473
- `;function kn({section:e,...t}){const[{editing:o},i]=I(t,V),r=g.useMemo(()=>{var s;return{...q.default(i,["listBorder","list","iconSize","imageSize"]),list:(s=i.list)==null?void 0:s.map(a=>{var c,l;return{...q.default(a,"icon","iconColor"),image:["news","simple","default"].includes(i.type)&&a.icon?a.icon:a.image,actions:(l=(c=a.actions)==null?void 0:c.map)==null?void 0:l.call(c,d=>n.jsx(We,{...d,editing:o},d.id)),border:i.listBorder,iconSize:i.iconSize,imageSize:i.imageSize,hoverStyle:i.hoverStyle}})}},[i]);return n.jsx(vn,{style:o?{pointerEvents:"none"}:{},...r})}function $n({properties:e,section:t,locale:o,dev:i}){var r;return(r=t==null?void 0:t.config)!=null&&r.componentId?n.jsx(re.CustomComponentRenderer,{instanceId:t.id,componentId:t.config.componentId,blockletId:t.config.blockletId,blockletTitle:t.config.blockletTitle,componentName:t.config.componentName,locale:o,properties:e,dev:i}):n.jsx(p.Box,{textAlign:"center",py:2,children:n.jsx(p.Typography,{variant:"caption",color:"text.secondary",children:"Please select component to render"})})}function Sn({src:e,dataId:t,isEdit:o=!1,height:i="100%",onLoad:r=()=>{}}){return n.jsx(yt.EmbedIframe,{isEdit:o,embedId:t,src:e,height:i,onLoad:()=>{r()}})}function Cn({dataId:e,src:t,actions:o,center:i,onLoad:r,...s}){const[a,c]=I(s,M);return n.jsxs(F,{...c,children:[Object.keys(a).length>0&&n.jsx(H,{center:i,...a}),n.jsx(Sn,{dataId:e,src:t,onLoad:r,height:s.iframeHeight?`${s.iframeHeight}px`:"100%"}),n.jsx(z,{actions:o,center:i})]})}function Bn({section:e,id:t,src:o,...i}){const r=`${t}-${i.locale}`,[{editing:s},a]=I(i,V),c=g.useRef({}),l=JSON.parse(JSON.stringify(a)),{message:d}=gt.useMessage(r,"server"),m=$e.useLatest(JSON.parse(JSON.stringify(a.config)||"{}"));return g.useEffect(()=>{d&&d.onInit(()=>m.current)},[d]),g.useEffect(()=>{const u=JSON.parse(JSON.stringify(a.config)||"{}");Rt.default(c.current,u)||(c.current=u,d==null||d.send("config-set",u))},[d,a.config]),o?n.jsx(Cn,{...l,dataId:r,src:o,style:s?{pointerEvents:"none"}:{}}):n.jsx(In,{children:'Please set the "src" attribute for this block'})}const In=$.styled("div")`
473
+ `;function kn({section:e,...t}){const[{editing:o},i]=I(t,V),r=g.useMemo(()=>{var s;return{...q.default(i,["listBorder","list","iconSize","imageSize"]),list:(s=i.list)==null?void 0:s.map(a=>{var c,l;return{...q.default(a,"icon","iconColor"),image:["news","simple","default"].includes(i.type)&&a.icon?a.icon:a.image,actions:(l=(c=a.actions)==null?void 0:c.map)==null?void 0:l.call(c,d=>n.jsx(We,{...d,editing:o},d.id)),border:i.listBorder,iconSize:i.iconSize,imageSize:i.imageSize,hoverStyle:i.hoverStyle}})}},[i]);return n.jsx(vn,{style:o?{pointerEvents:"none"}:{},...r})}function $n({properties:e,section:t,locale:o,dev:i}){var r;return(r=t==null?void 0:t.config)!=null&&r.componentId?n.jsx(re.CustomComponentRenderer,{instanceId:t.id,componentId:t.config.componentId,blockletId:t.config.blockletId,blockletTitle:t.config.blockletTitle,componentName:t.config.componentName,locale:o,properties:e,dev:i}):n.jsx(p.Box,{textAlign:"center",py:2,children:n.jsx(p.Typography,{variant:"caption",color:"text.secondary",children:"Please select component to render"})})}function Sn({src:e,dataId:t,isEdit:o=!1,height:i="100%",onLoad:r=()=>{}}){return n.jsx(yt.EmbedIframe,{isEdit:o,embedId:t,src:e,height:i,onLoad:()=>{r()}})}function Cn({dataId:e,src:t,actions:o,center:i,onLoad:r,...s}){const[a,c]=I(s,M);return n.jsxs(F,{...c,children:[Object.keys(a).length>0&&n.jsx(H,{center:i,...a}),n.jsx(Sn,{dataId:e,src:t,onLoad:r,height:s.iframeHeight?`${s.iframeHeight}px`:"100%"}),n.jsx(z,{actions:o,center:i})]})}function Bn({section:e,id:t,src:o,...i}){const r=`${t}-${i.locale}`,[{editing:s},a]=I(i,V),c=g.useRef({}),l=JSON.parse(JSON.stringify(a)),{message:d}=gt.useMessage(r,"server"),m=$e.useLatest(JSON.parse(JSON.stringify(a.config)||"{}"));return g.useEffect(()=>{d&&d.onInit(()=>m.current)},[d]),g.useEffect(()=>{const u=JSON.parse(JSON.stringify(a.config)||"{}");Pt.default(c.current,u)||(c.current=u,d==null||d.send("config-set",u))},[d,a.config]),o?n.jsx(Cn,{...l,dataId:r,src:o,style:s?{pointerEvents:"none"}:{}}):n.jsx(In,{children:'Please set the "src" attribute for this block'})}const In=$.styled("div")`
474
474
  user-select: none;
475
475
  color: #999;
476
476
  padding: 8px;
477
477
  height: 200px;
478
- `,Nn=[/youtu\.be\/([^#&?]{11})/,/\?v=([^#&?]{11})/,/&v=([^#&?]{11})/,/embed\/([^#&?]{11})/,/\/v\/([^#&?]{11})/];function Pn(e){var t;if(/youtu\.?be/.test(e))for(const o of Nn){const i=(t=o.exec(e))==null?void 0:t[1];if(i)return i}}function Rn(e){const t=Pn(e);if(t)return`https://youtube.com/embed/${t}`}function Tn({src:e}){return g.useEffect(()=>{import("@lottiefiles/lottie-player")},[]),n.jsx("lottie-player",{autoplay:!0,loop:!0,mode:"normal",src:e})}function qn(e){return n.jsx(p.Box,{maxHeight:400,overflow:"hidden auto",children:n.jsx(jt.TwitterTimelineEmbed,{...e})})}function En({url:e}){const t=g.useRef(null),o=495,[i,r]=g.useState(t.current?t.current.offsetWidth*.5625:o),s=g.useCallback(()=>{const a=window.innerWidth>990?1:window.innerWidth>522?1.2:window.innerWidth>400?1.45:1.85,c=t.current?t.current.offsetWidth*.5625:o;return r(Math.floor(c*a))},[]);return g.useEffect(()=>{window.addEventListener("resize",s);const a=window.innerWidth>990?1:window.innerWidth>522?1.2:window.innerWidth>400?1.45:1.85,c=t.current?t.current.offsetWidth*.5625:o;return r(Math.floor(c*a)),function(){window.removeEventListener("resize",s)}},[i,s]),n.jsx(p.Box,{component:"iframe",ref:t,title:"youtube",width:"100%",height:`${i}px`,src:e,frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,sx:{display:"block"}})}const zn=$.styled(Xt)`
478
+ `,Nn=[/youtu\.be\/([^#&?]{11})/,/\?v=([^#&?]{11})/,/&v=([^#&?]{11})/,/embed\/([^#&?]{11})/,/\/v\/([^#&?]{11})/];function Rn(e){var t;if(/youtu\.?be/.test(e))for(const o of Nn){const i=(t=o.exec(e))==null?void 0:t[1];if(i)return i}}function Pn(e){const t=Rn(e);if(t)return`https://youtube.com/embed/${t}`}function Tn({src:e}){return g.useEffect(()=>{import("@lottiefiles/lottie-player")},[]),n.jsx("lottie-player",{autoplay:!0,loop:!0,mode:"normal",src:e})}function qn(e){return n.jsx(p.Box,{maxHeight:400,overflow:"hidden auto",children:n.jsx(jt.TwitterTimelineEmbed,{...e})})}function En({url:e}){const t=g.useRef(null),o=495,[i,r]=g.useState(t.current?t.current.offsetWidth*.5625:o),s=g.useCallback(()=>{const a=window.innerWidth>990?1:window.innerWidth>522?1.2:window.innerWidth>400?1.45:1.85,c=t.current?t.current.offsetWidth*.5625:o;return r(Math.floor(c*a))},[]);return g.useEffect(()=>{window.addEventListener("resize",s);const a=window.innerWidth>990?1:window.innerWidth>522?1.2:window.innerWidth>400?1.45:1.85,c=t.current?t.current.offsetWidth*.5625:o;return r(Math.floor(c*a)),function(){window.removeEventListener("resize",s)}},[i,s]),n.jsx(p.Box,{component:"iframe",ref:t,title:"youtube",width:"100%",height:`${i}px`,src:e,frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,sx:{display:"block"}})}const zn=$.styled(Xt)`
479
479
  .section__description {
480
480
  }
481
- `;function Wn({hasImage:e,fullSizeImage:t,boxed:o,videoPoster:i,imageMeta:r,imageOptimization:s,imageSize:a,section:c,...l}){var x,y;const[{editing:d},m]=I({...l,boxed:t?void 0:o},V);let u=Ln(m.image,i,t,r,s,a);e||(u=null);let f=null;return m.actions&&(f=(y=(x=m.actions)==null?void 0:x.map)==null?void 0:y.call(x,(j,h)=>n.jsx(We,{...j,editing:d},h))),n.jsx(zn,{...m,style:d?{pointerEvents:"none"}:{},image:u,fullSizeImage:e&&t,actions:f})}function Ln(e,t,o,i,r,s){if(e){if(e.endsWith(".json"))return n.jsx(Tn,{src:e});if(e.indexOf("twitter.com")!==-1)return n.jsx(qn,{sourceType:"url",url:e});const a=Rn(e);if(a)return n.jsx(En,{url:a});const{naturalWidth:c,naturalHeight:l,filename:d}=i||{};if(ne(e))return n.jsx("video",{width:c&&`${c}px`,height:l&&`${l}px`,controls:!0,autoPlay:!0,muted:!0,style:{display:"block",objectFit:s||"contain",borderRadius:"8px",width:"100%",height:"100%"},poster:w.autoResizeImage(w.getImageAbsoluteUrl(t),o?1200:540,r),children:n.jsx("source",{src:w.getImageAbsoluteUrl(e),type:Vt(e)})},e);const m=r==="quality"?1:.6;return n.jsx(re.ResponsiveImage,{src:w.getImageAbsoluteUrl(e),sizesAttr:{sm:600*m,md:450*m,lg:540*m,...o&&{md:900*m,lg:1200*m}},width:c&&`${c}px`,height:l&&`${l}px`,alt:d??e,style:{objectFit:s||"contain",display:"block",width:"100%",height:"100%"},loading:"lazy"})}return null}const An=["production","draft"];function Le({mode:e,version:t}={}){const o=t&&typeof t=="number"?{mode:e,version:t}:{mode:e};return w.api.get(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages`,{params:o}).then(i=>i.data)}function On({mode:e,pages:t}){return w.api.post(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages/publish`,{mode:e,pages:t}).then(o=>o.data)}function Un({locale:e,sort:t,page:o,limit:i,mode:r}={}){return w.api.get(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages/toc`,{params:{locale:e,sort:t,page:o,limit:i,mode:r}}).then(s=>s.data)}const je=20;function Hn({style:e,sort:t,section:o,...i}){const[{editing:r,locale:s},a]=I(i,V),[c,l]=I(a,M),[d,m]=g.useState(),u=g.useRef(!1),f=U.useUpdate(),x=B.useNavigate(),y=g.useCallback(async()=>{if(!u.current){u.current=!0,f();try{const j=d?Math.floor(d.list.length/je)+1:1,{list:h,total:v}=await Un({locale:s,sort:t,page:j,limit:je});m(b=>({list:((b==null?void 0:b.list)??[]).concat(h),total:v}))}finally{u.current=!1,f()}}},[d,s,t,f]);return U.useMount(()=>{y()}),n.jsxs(F,{...l,sx:r?{pointerEvents:"none"}:{},children:[Object.keys(c).length>0&&n.jsx(H,{...c}),d?n.jsxs(n.Fragment,{children:[n.jsx(p.Grid,{container:!0,spacing:2,justifyContent:"center",children:d==null?void 0:d.list.map(j=>n.jsx(p.Grid,{item:!0,xs:12,sm:e==="card"?6:12,md:e==="card"?3:12,children:n.jsxs(Mn,{elevation:0,className:_.cx(e==="card"&&"style-card"),onClick:r?void 0:()=>x(j.slug),children:[!!j.image&&n.jsx(p.CardMedia,{component:"img",alt:"",image:w.autoResizeImage(w.getImageAbsoluteUrl(j.image),540),loading:"lazy"}),n.jsxs(p.CardContent,{children:[n.jsx(p.Typography,{variant:"h6",component:"div",className:we,children:j.title||j.id}),n.jsx(p.Typography,{variant:"body2",className:we,children:j.description})]})]})},j.id))}),n.jsx(p.Box,{textAlign:"center",mt:2,children:d.total>d.list.length?n.jsx(O,{variant:"outlined",color:"secondary",onClick:y,loading:u.current,children:"More"}):n.jsx(O,{variant:"outlined",color:"secondary",disabled:!0,children:"No More"})})]}):n.jsx(p.Box,{p:2,textAlign:"center",children:n.jsx(p.CircularProgress,{size:24})})]})}const we=_.css`
481
+ `;function Wn({hasImage:e,fullSizeImage:t,boxed:o,videoPoster:i,imageMeta:r,imageOptimization:s,imageSize:a,section:c,...l}){var x,y;const[{editing:d},m]=I({...l,boxed:t?void 0:o},V);let u=Ln(m.image,i,t,r,s,a);e||(u=null);let f=null;return m.actions&&(f=(y=(x=m.actions)==null?void 0:x.map)==null?void 0:y.call(x,(j,h)=>n.jsx(We,{...j,editing:d},h))),n.jsx(zn,{...m,style:d?{pointerEvents:"none"}:{},image:u,fullSizeImage:e&&t,actions:f})}function Ln(e,t,o,i,r,s){if(e){if(e.endsWith(".json"))return n.jsx(Tn,{src:e});if(e.indexOf("twitter.com")!==-1)return n.jsx(qn,{sourceType:"url",url:e});const a=Pn(e);if(a)return n.jsx(En,{url:a});const{naturalWidth:c,naturalHeight:l,filename:d}=i||{};if(ne(e))return n.jsx("video",{width:c&&`${c}px`,height:l&&`${l}px`,controls:!0,autoPlay:!0,muted:!0,style:{display:"block",objectFit:s||"contain",borderRadius:"8px",width:"100%",height:"100%"},poster:w.autoResizeImage(w.getImageAbsoluteUrl(t),o?1200:540,r),children:n.jsx("source",{src:w.getImageAbsoluteUrl(e),type:Vt(e)})},e);const m=r==="quality"?1:.6;return n.jsx(re.ResponsiveImage,{src:w.getImageAbsoluteUrl(e),sizesAttr:{sm:600*m,md:450*m,lg:540*m,...o&&{md:900*m,lg:1200*m}},width:c&&`${c}px`,height:l&&`${l}px`,alt:d??e,style:{objectFit:s||"contain",display:"block",width:"100%",height:"100%"},loading:"lazy"})}return null}const An=["production","draft"];function Le({mode:e,version:t}={}){const o=t&&typeof t=="number"?{mode:e,version:t}:{mode:e};return w.api.get(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages`,{params:o}).then(i=>i.data)}function On({mode:e,pages:t}){return w.api.post(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages/publish`,{mode:e,pages:t}).then(o=>o.data)}function Un({locale:e,sort:t,page:o,limit:i,mode:r}={}){return w.api.get(`/api/${w.getProjectIdFromPathnameOrWindow()}/pages/toc`,{params:{locale:e,sort:t,page:o,limit:i,mode:r}}).then(s=>s.data)}const je=20;function Hn({style:e,sort:t,section:o,...i}){const[{editing:r,locale:s},a]=I(i,V),[c,l]=I(a,M),[d,m]=g.useState(),u=g.useRef(!1),f=U.useUpdate(),x=B.useNavigate(),y=g.useCallback(async()=>{if(!u.current){u.current=!0,f();try{const j=d?Math.floor(d.list.length/je)+1:1,{list:h,total:v}=await Un({locale:s,sort:t,page:j,limit:je});m(b=>({list:((b==null?void 0:b.list)??[]).concat(h),total:v}))}finally{u.current=!1,f()}}},[d,s,t,f]);return U.useMount(()=>{y()}),n.jsxs(F,{...l,sx:r?{pointerEvents:"none"}:{},children:[Object.keys(c).length>0&&n.jsx(H,{...c}),d?n.jsxs(n.Fragment,{children:[n.jsx(p.Grid,{container:!0,spacing:2,justifyContent:"center",children:d==null?void 0:d.list.map(j=>n.jsx(p.Grid,{item:!0,xs:12,sm:e==="card"?6:12,md:e==="card"?3:12,children:n.jsxs(Mn,{elevation:0,className:_.cx(e==="card"&&"style-card"),onClick:r?void 0:()=>x(j.slug),children:[!!j.image&&n.jsx(p.CardMedia,{component:"img",alt:"",image:w.autoResizeImage(w.getImageAbsoluteUrl(j.image),540),loading:"lazy"}),n.jsxs(p.CardContent,{children:[n.jsx(p.Typography,{variant:"h6",component:"div",className:we,children:j.title||j.id}),n.jsx(p.Typography,{variant:"body2",className:we,children:j.description})]})]})},j.id))}),n.jsx(p.Box,{textAlign:"center",mt:2,children:d.total>d.list.length?n.jsx(O,{variant:"outlined",color:"secondary",onClick:y,loading:u.current,children:"More"}):n.jsx(O,{variant:"outlined",color:"secondary",disabled:!0,children:"No More"})})]}):n.jsx(p.Box,{p:2,textAlign:"center",children:n.jsx(p.CircularProgress,{size:24})})]})}const we=_.css`
482
482
  display: -webkit-box;
483
483
  -webkit-box-orient: vertical;
484
484
  -webkit-line-clamp: 2;
@@ -530,13 +530,13 @@
530
530
  font-family: ${JSON.stringify(t)}, ${_e};
531
531
  }
532
532
  }
533
- `})}const{SessionProvider:uo,SessionContext:Qn,SessionConsumer:mo,withSession:po}=vt.createAuthServiceSessionContext();function ce(){return g.useContext(Qn)}function Zn(...e){var o;const{session:t}=ce();return e.includes((o=t.user)==null?void 0:o.role)}function eo(...e){var i;const{session:t}=ce(),o=Zn(...e);return((i=window.blocklet)==null?void 0:i.tenantMode)==="multiple"?!!t.user:o}function to(e){return e!=null}function no(){const[e]=B.useSearchParams(),{session:t}=ce(),o=eo("owner","admin","pagesEditor","member"),i=g.useMemo(()=>{const s=e.get("mode");return An.includes(s)?s:"production"},[e]),r=i==="production"?i:t.user?o?i:"production":null;return r?n.jsx(Oe,{mode:r}):null}function Oe({mode:e}){if(e!=="draft"){const t=window.__PAGE_STATE__;return t?n.jsx(Y,{mode:e,state:t}):n.jsx(ro,{mode:e,children:({state:o})=>n.jsx(Y,{mode:e,state:o})})}return n.jsx(oo,{children:({state:t})=>n.jsx(Y,{mode:e,state:t})})}const oo=g.lazy(()=>Promise.resolve().then(()=>require("./draft-data-CMqq2YH1.js")));function ro({mode:e,children:t}){const o=document.querySelector('meta[property="pages:version"]'),i=o==null?void 0:o.content,r=w.useProjectId(),s=g.useMemo(()=>{if(i==="{{pagesPublishedAt}}"){const l=localStorage.getItem(w.getProjectPageVersionKey(r??""));return Number(l)?Number(l):new Date().getTime()}return Number(i)},[i]),{loading:a,value:c}=U.useAsync(()=>Le({mode:e,version:s}),[e,s]);return a?n.jsx(Ae,{}):c?t({state:c}):null}function Y({mode:e,state:t}){var y,j,h,v;const{t:o,locale:i}=ke.useLocaleContext(),{pageIds:r,pages:s,supportedLocales:a,config:{defaultLocale:c},resources:l}=t,d=w.getAllComponents(t),m=g.useMemo(()=>a!=null&&a.some(b=>b.locale===i)?i:void 0,[i,a]),u=Object.values(s).find(b=>(b==null?void 0:b.slug)==="/")?void 0:Object.values(s)[0],f=g.useMemo(()=>r.map(b=>{const k=s[b];return k&&{id:k.id,path:P.joinURL("/",m||"",k.slug,e!=="production"?`?mode=${e}`:"")}}).filter(to),[r,s,m,e]),x=([...b])=>(e!=="production"&&b.unshift(n.jsx(g.Suspense,{fallback:n.jsx("div",{}),children:n.jsx(so,{mode:"production",state:t})})),b);return n.jsxs(en,{value:{pages:f},children:[n.jsxs(B.Routes,{children:[u&&n.jsx(B.Route,{index:!0,element:n.jsx(B.Navigate,{to:P.joinURL("/",m||"",u.slug)})}),r.map(b=>{const k=s[b];return k?n.jsx(B.Route,{path:P.joinURL(":projectIdOrSlug?",k.slug),element:n.jsx(Z,{mode:e,components:d,page:k,locale:m,defaultLocale:c,headerAddons:x})},k.id):null}),l.pages&&Object.values(l.pages).map(({blockletId:b,page:k})=>n.jsx(B.Route,{path:P.joinURL("/",`@${b}`,k.slug),element:n.jsx(Z,{mode:e,components:d,page:k,locale:m,defaultLocale:c,headerAddons:x})},k.id)),n.jsx(B.Route,{path:"*",element:n.jsx(p.Box,{width:"100vw",height:"100vh",display:"flex",justifyContent:"center",alignItems:"center",children:n.jsx(Ce.default,{style:{background:"inherit"},status:404,extra:n.jsx(Me,{href:"/",children:o("common.back")})})})})]}),e!=="production"&&n.jsx(Jn,{sx:{bgcolor:"info.light"},children:e}),n.jsx(Yn,{titleFontFamily:(j=(y=t.config)==null?void 0:y.fontFamily)==null?void 0:j.title,descriptionFontFamily:(v=(h=t.config)==null?void 0:h.fontFamily)==null?void 0:v.description})]})}function io({mode:e,state:t,path:o,pageData:i}){const{t:r,locale:s}=ke.useLocaleContext(),{pages:a,supportedLocales:c,config:{defaultLocale:l},resources:d}=t,m=Object.values(a).find(h=>(h==null?void 0:h.slug)===o),u=Object.values(d.pages||{}).find(h=>h.page.slug===o),f=g.useMemo(()=>c!=null&&c.some(h=>h.locale===s)?s:void 0,[s,c]),x=$e.useReactive({page:null});g.useEffect(()=>{const h=m||(u==null?void 0:u.page)||null;h?x.page=A.cloneDeep(h):x.page=null},[m,u]);const y=g.useRef();if(g.useEffect(()=>{A.isEqual(i,y.current)||i&&x.page&&(Et(x.page,t,f,i),y.current=A.cloneDeep(i))},[{}]),!m&&!(u!=null&&u.page))return n.jsx(p.Box,{width:"100vw",height:"100vh",display:"flex",justifyContent:"center",alignItems:"center",children:n.jsx(Ce.default,{style:{background:"inherit"},status:404,extra:n.jsx(Me,{href:"/",children:r("common.back")})})});const j=w.getAllComponents(t);return x.page?n.jsx(Z,{mode:e,components:j,page:x.page,locale:f,defaultLocale:l}):null}function Z({mode:e,components:t,page:o,locale:i,defaultLocale:r,headerAddons:s}){var h,v,b,k,N,W,J,le,de;const a=((h=o.locales)==null?void 0:h[i])??((v=o.locales)==null?void 0:v[r])??{},c=a.title||((b=window.blocklet)==null?void 0:b.appName),l=a.description||((k=window.blocklet)==null?void 0:k.appDescription),d=w.autoResizeImage(w.getImageAbsoluteUrl(a.image),540),{logo:m,brand:u,description:f,...x}=Qe.useHeaderState(),y=g.useMemo(()=>E=>{var L;let C=(s==null?void 0:s(E))??E;return C=((L=x.addons)==null?void 0:L.call(x,C))??C,C},[x.addons,s]),j=(N=a.header)!=null&&N.translucent?He:Ue;return n.jsxs(n.Fragment,{children:[!!a.backgroundColor&&n.jsx(Q.Global,{styles:Q.css`
533
+ `})}const{SessionProvider:uo,SessionContext:Qn,SessionConsumer:mo,withSession:po}=vt.createAuthServiceSessionContext();function ce(){return g.useContext(Qn)}function Zn(...e){var o;const{session:t}=ce();return e.includes((o=t.user)==null?void 0:o.role)}function eo(...e){var i;const{session:t}=ce(),o=Zn(...e);return((i=window.blocklet)==null?void 0:i.tenantMode)==="multiple"?!!t.user:o}function to(e){return e!=null}function no(){const[e]=B.useSearchParams(),{session:t}=ce(),o=eo("owner","admin","pagesEditor","member"),i=g.useMemo(()=>{const s=e.get("mode");return An.includes(s)?s:"production"},[e]),r=i==="production"?i:t.user?o?i:"production":null;return r?n.jsx(Oe,{mode:r}):null}function Oe({mode:e}){if(e!=="draft"){const t=window.__PAGE_STATE__;return t?n.jsx(Y,{mode:e,state:t}):n.jsx(ro,{mode:e,children:({state:o})=>n.jsx(Y,{mode:e,state:o})})}return n.jsx(oo,{children:({state:t})=>n.jsx(Y,{mode:e,state:t})})}const oo=g.lazy(()=>Promise.resolve().then(()=>require("./draft-data-CMqq2YH1.js")));function ro({mode:e,children:t}){const o=document.querySelector('meta[property="pages:version"]'),i=o==null?void 0:o.content,r=w.useProjectId(),s=g.useMemo(()=>{if(i==="{{pagesPublishedAt}}"){const l=localStorage.getItem(w.getProjectPageVersionKey(r??""));return Number(l)?Number(l):new Date().getTime()}return Number(i)},[i]),{loading:a,value:c}=U.useAsync(()=>Le({mode:e,version:s}),[e,s]);return a?n.jsx(Ae,{}):c?t({state:c}):null}function Y({mode:e,state:t}){var y,j,h,v;const{t:o,locale:i}=ke.useLocaleContext(),{pageIds:r,pages:s,supportedLocales:a,config:{defaultLocale:c},resources:l}=t,d=w.getAllComponents(t),m=g.useMemo(()=>a!=null&&a.some(b=>b.locale===i)?i:void 0,[i,a]),u=Object.values(s).find(b=>(b==null?void 0:b.slug)==="/")?void 0:Object.values(s)[0],f=g.useMemo(()=>r.map(b=>{const k=s[b];return k&&{id:k.id,path:R.joinURL("/",m||"",k.slug,e!=="production"?`?mode=${e}`:"")}}).filter(to),[r,s,m,e]),x=([...b])=>(e!=="production"&&b.unshift(n.jsx(g.Suspense,{fallback:n.jsx("div",{}),children:n.jsx(so,{mode:"production",state:t})})),b);return n.jsxs(en,{value:{pages:f},children:[n.jsxs(B.Routes,{children:[u&&n.jsx(B.Route,{index:!0,element:n.jsx(B.Navigate,{to:R.joinURL("/",m||"",u.slug)})}),r.map(b=>{const k=s[b];return k?n.jsx(B.Route,{path:R.joinURL(":projectIdOrSlug?",k.slug),element:n.jsx(Z,{mode:e,components:d,page:k,locale:m,defaultLocale:c,headerAddons:x})},k.id):null}),l.pages&&Object.values(l.pages).map(({blockletId:b,page:k})=>n.jsx(B.Route,{path:R.joinURL("/",`@${b}`,k.slug),element:n.jsx(Z,{mode:e,components:d,page:k,locale:m,defaultLocale:c,headerAddons:x})},k.id)),n.jsx(B.Route,{path:"*",element:n.jsx(p.Box,{width:"100vw",height:"100vh",display:"flex",justifyContent:"center",alignItems:"center",children:n.jsx(Ce.default,{style:{background:"inherit"},status:404,extra:n.jsx(Me,{href:"/",children:o("common.back")})})})})]}),e!=="production"&&n.jsx(Jn,{sx:{bgcolor:"info.light"},children:e}),n.jsx(Yn,{titleFontFamily:(j=(y=t.config)==null?void 0:y.fontFamily)==null?void 0:j.title,descriptionFontFamily:(v=(h=t.config)==null?void 0:h.fontFamily)==null?void 0:v.description})]})}function io({mode:e,state:t,path:o,pageData:i}){const{t:r,locale:s}=ke.useLocaleContext(),{pages:a,supportedLocales:c,config:{defaultLocale:l},resources:d}=t,m=Object.values(a).find(h=>(h==null?void 0:h.slug)===o),u=Object.values(d.pages||{}).find(h=>h.page.slug===o),f=g.useMemo(()=>c!=null&&c.some(h=>h.locale===s)?s:void 0,[s,c]),x=$e.useReactive({page:null});g.useEffect(()=>{const h=m||(u==null?void 0:u.page)||null;h?x.page=A.cloneDeep(h):x.page=null},[m,u]);const y=g.useRef();if(g.useEffect(()=>{A.isEqual(i,y.current)||i&&x.page&&(Et(x.page,t,f,i),y.current=A.cloneDeep(i))},[{}]),!m&&!(u!=null&&u.page))return n.jsx(p.Box,{width:"100vw",height:"100vh",display:"flex",justifyContent:"center",alignItems:"center",children:n.jsx(Ce.default,{style:{background:"inherit"},status:404,extra:n.jsx(Me,{href:"/",children:r("common.back")})})});const j=w.getAllComponents(t);return x.page?n.jsx(Z,{mode:e,components:j,page:x.page,locale:f,defaultLocale:l}):null}function Z({mode:e,components:t,page:o,locale:i,defaultLocale:r,headerAddons:s}){var h,v,b,k,N,W,J,le,de;const a=((h=o.locales)==null?void 0:h[i])??((v=o.locales)==null?void 0:v[r])??{},c=a.title||((b=window.blocklet)==null?void 0:b.appName),l=a.description||((k=window.blocklet)==null?void 0:k.appDescription),d=w.autoResizeImage(w.getImageAbsoluteUrl(a.image),540),{logo:m,brand:u,description:f,...x}=Qe.useHeaderState(),y=g.useMemo(()=>E=>{var L;let C=(s==null?void 0:s(E))??E;return C=((L=x.addons)==null?void 0:L.call(x,C))??C,C},[x.addons,s]),j=(N=a.header)!=null&&N.translucent?He:Ue;return n.jsxs(n.Fragment,{children:[!!a.backgroundColor&&n.jsx(Q.Global,{styles:Q.css`
534
534
  body {
535
535
  background-color: ${a.backgroundColor} !important;
536
536
  }
537
- `}),n.jsx(j,{hideNavMenu:!!((W=a.header)!=null&&W.hideNavMenus),translucentTextColor:(J=a.header)==null?void 0:J.translucentTextColor,...m?{logo:m}:{},...u?{brand:u}:{},...f?{description:f}:{},className:_.cx(((le=a.header)==null?void 0:le.sticky)&&"sticky","page-header"),maxWidth:!1,addons:y}),n.jsx(B.ScrollRestoration,{}),n.jsxs(ot.Helmet,{children:[n.jsx("title",{children:c}),n.jsx("meta",{name:"og:title",content:c}),n.jsx("meta",{name:"og:description",content:l}),n.jsx("meta",{name:"og:image",content:d}),n.jsx("meta",{name:"twitter:image:src",content:d}),n.jsx("meta",{name:"twitter:image",content:d}),n.jsx("meta",{property:"twitter:description",content:l}),n.jsx("meta",{property:"twitter:title",content:c}),n.jsx("meta",{name:"description",content:l})]}),n.jsx(p.Stack,{flexGrow:1,children:o.sectionIds.map(E=>{var ue,me;const C=o.sections[E];if(!C||C.visibility==="hidden")return null;const L=(ue=C.locales)==null?void 0:ue[i],Fe=((me=C.locales)==null?void 0:me[r])??{};return n.jsx(Vn,{id:E,type:C.component,mode:e,section:C,config:{...St.default(L)?Fe:L,locale:i,dev:e==="draft"?{mode:e,components:t,defaultLocale:r}:{mode:e}}},E)})}),!((de=a.footer)!=null&&de.hidden)&&n.jsx(Dn,{})]})}const so=g.lazy(()=>Promise.resolve().then(()=>require("./publish-button-DFR8IHQq.js"))),Ue=Be.default(kt.default)`
537
+ `}),n.jsx(j,{hideNavMenu:!!((W=a.header)!=null&&W.hideNavMenus),translucentTextColor:(J=a.header)==null?void 0:J.translucentTextColor,...m?{logo:m}:{},...u?{brand:u}:{},...f?{description:f}:{},className:_.cx(((le=a.header)==null?void 0:le.sticky)&&"sticky","page-header"),maxWidth:!1,addons:y}),n.jsx(B.ScrollRestoration,{}),n.jsxs(ot.Helmet,{children:[n.jsx("title",{children:c}),n.jsx("meta",{name:"og:title",content:c}),n.jsx("meta",{name:"og:description",content:l}),n.jsx("meta",{name:"og:image",content:d}),n.jsx("meta",{name:"twitter:image:src",content:d}),n.jsx("meta",{name:"twitter:image",content:d}),n.jsx("meta",{property:"twitter:description",content:l}),n.jsx("meta",{property:"twitter:title",content:c}),n.jsx("meta",{name:"description",content:l})]}),n.jsx(p.Stack,{flexGrow:1,children:o.sectionIds.map(E=>{var ue,me;const C=o.sections[E];if(!C||C.visibility==="hidden")return null;const L=(ue=C.locales)==null?void 0:ue[i],Fe=((me=C.locales)==null?void 0:me[r])??{};return n.jsx(Vn,{id:E,type:C.component,mode:e,section:C,config:{...St.default(L)?Fe:L,locale:i,dev:e==="draft"?{mode:e,components:t,defaultLocale:r}:{mode:e}}},E)})}),!((de=a.footer)!=null&&de.hidden)&&n.jsx(Dn,{})]})}const so=g.lazy(()=>Promise.resolve().then(()=>require("./publish-button-BT-w5Okt.js"))),Ue=Be.default(kt.default)`
538
538
  &.sticky {
539
539
  position: sticky;
540
540
  top: 0;
541
541
  }
542
- `;function ao({logo:e}){const[t,o]=g.useState(),{value:i}=U.useAsync(()=>new Promise(r=>{fetch("/.well-known/service/blocklet/logo-rect").then(s=>{const a=s.headers.get("content-type");a!=null&&a.includes("svg")&&s.text().then(c=>{o(c),r(null)}),r(s.url)})}),[]);if(e)return e;if(t)return n.jsx(p.Box,{sx:{filter:"initial !important"},dangerouslySetInnerHTML:{__html:$t.default.sanitize(t)}});if(i){const r=new URL(i);r.searchParams.set("imageFilter","convert"),r.searchParams.set("f","png"),r.searchParams.set("h","88"),r.searchParams.set("hash","00c22ff");const s=r.toString();return n.jsx("img",{src:s,alt:"logo"})}return null}function He({logo:e,translucentTextColor:t,...o}){const{y:i}=U.useWindowScroll();let r=Math.min(i/800,1),s="";if(r>.1){r=Math.max(r,.6);const a=Math.round(255*Math.min(1-r,.2));s=`rgb(${a}, ${a}, ${a})`}else s=t||"#EEEEEE";return n.jsx(Ue,{logo:n.jsx(ao,{logo:e}),...o,className:_.cx(r<=.7&&"reverse-color"),style:{backgroundColor:`rgba(255,255,255,${r})`,"--logo-invert":r<=.7?1-r/6:1-r},sx:{backdropFilter:r>=.6?"blur(10px)":"blur(0px)",transition:"all 0.3s ease",position:"fixed !important",left:0,top:0,right:0,bgcolor:"transparent","&.reverse-color":{".navmenu-root>.navmenu-sub>span,\n .navmenu-root>.navmenu-item,\n .header-addons>button,\n .header-addons>a,\n .header-addons>div>button":{color:`${s} !important`}},".header-logo > div":{filter:"invert(var(--logo-invert))"},".header-logo":{color:s}}})}const Me=Be.default(p.Button)``;exports.Home=no;exports.HomeView=Oe;exports.Loading=Ae;exports.PageRoutes=Y;exports.PageView=Z;exports.PageViewByPath=io;exports.TranslucentHeader=He;exports.getPages=Le;exports.publishPages=On;
542
+ `;function ao({logo:e}){const[t,o]=g.useState(),{value:i}=U.useAsync(()=>new Promise(r=>{fetch("/.well-known/service/blocklet/logo-rect").then(s=>{const a=s.headers.get("content-type");a!=null&&a.includes("svg")&&s.text().then(c=>{o(c),r(null)}),r(s.url)})}),[]);if(e)return e;if(t)return n.jsx(p.Box,{sx:{filter:"initial !important"},dangerouslySetInnerHTML:{__html:$t.default.sanitize(t)}});if(i){const r=new URL(i);r.searchParams.set("imageFilter","convert"),r.searchParams.set("f","png"),r.searchParams.set("h","80");const s=r.toString();return n.jsx("img",{src:s,alt:"logo"})}return null}function He({logo:e,translucentTextColor:t,...o}){const{y:i}=U.useWindowScroll();let r=Math.min(i/800,1),s="";if(r>.1){r=Math.max(r,.6);const a=Math.round(255*Math.min(1-r,.2));s=`rgb(${a}, ${a}, ${a})`}else s=t||"#EEEEEE";return n.jsx(Ue,{logo:n.jsx(ao,{logo:e}),...o,className:_.cx(r<=.7&&"reverse-color"),style:{backgroundColor:`rgba(255,255,255,${r})`,"--logo-invert":r<=.7?1-r/6:1-r},sx:{backdropFilter:r>=.6?"blur(10px)":"blur(0px)",transition:"all 0.3s ease",position:"fixed !important",left:0,top:0,right:0,bgcolor:"transparent","&.reverse-color":{".navmenu-root>.navmenu-sub>span,\n .navmenu-root>.navmenu-item,\n .header-addons>button,\n .header-addons>a,\n .header-addons>div>button":{color:`${s} !important`}},".header-logo > div":{filter:"invert(var(--logo-invert))"},".header-logo":{color:s}}})}const Me=Be.default(p.Button)``;exports.Home=no;exports.HomeView=Oe;exports.Loading=Ae;exports.PageRoutes=Y;exports.PageView=Z;exports.PageViewByPath=io;exports.TranslucentHeader=He;exports.getPages=Le;exports.publishPages=On;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),v=require("./state-BjeG4kYg.js"),q=require("@arcblock/ux/lib/Locale/context"),O=require("@arcblock/ux/lib/Toast"),S=require("@mui/icons-material"),E=require("@mui/lab"),s=require("@mui/material"),W=require("immer"),z=require("lodash/difference"),c=require("react"),_=require("react-use"),C=require("./home-BFxAZSGy.js"),M=t=>t&&t.__esModule?t:{default:t},A=M(O),D=M(z);function N(t){const[d,b]=c.useState(!1);return e.jsx(E.LoadingButton,{...t,loading:t.loading||d,onClick:i=>{var h;const m=(h=t.onClick)==null?void 0:h.call(t,i);m instanceof Promise&&(b(!0),m.finally(()=>{b(!1)}))}})}const R=s.createSvgIcon(e.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[e.jsx("path",{d:"M7.75732 16.2426L16.2426 7.75736",stroke:"#4B5563",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),e.jsx("path",{d:"M16.2426 16.2426L7.75732 7.75735",stroke:"#4B5563",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),"Close");function F(){const[t,d]=c.useState(),b=c.useMemo(()=>t?e.jsx(s.Dialog,{...t}):null,[t]),i=c.useCallback(()=>{d(void 0)},[]),m=c.useCallback(({title:h,content:g,cancelText:T="Cancel",okText:p="Ok",onOk:f,onClose:k,okIcon:L,okColor:n="primary",cancelColor:y="primary",DialogContentProps:u,form:x,...I})=>{d({...I,open:!0,children:e.jsxs("form",{onSubmit:P=>P.preventDefault(),children:[h&&e.jsxs(s.DialogTitle,{className:"between",zIndex:"appBar",bgcolor:"background.paper",sx:{borderBottom:"1px solid #E5E7EB"},children:[e.jsx(s.Box,{children:h}),e.jsx(s.IconButton,{size:"small",onClick:async()=>{i(),k==null||k()},children:e.jsx(R,{})})]}),g&&e.jsx(s.DialogContent,{...u,sx:{mt:-3,...u==null?void 0:u.sx},children:e.jsx(s.Box,{pt:3,children:g})}),e.jsxs(s.DialogActions,{children:[e.jsx(s.Button,{variant:"outlined",color:y||"primary",onClick:k??i,children:T}),e.jsx(N,{variant:"contained",color:n||"primary",startIcon:L,loadingPosition:L?"start":"center",onClick:async()=>{await(f==null?void 0:f()),i()},type:"submit",children:p})]})]}),onClose:k??i})},[i]);return{dialog:b,showDialog:m,closeDialog:i}}const H=c.forwardRef(({mode:t,state:d},b)=>{const{t:i}=q.useLocaleContext(),[m,h]=c.useState(!1),{dialog:g,showDialog:T}=F(),p=v.useProjectId(),f=c.useCallback(L=>{let n=[];T({title:i("maker.publishToProduction"),content:e.jsxs(s.Box,{sx:{minWidth:300},children:[e.jsx(s.Alert,{color:"warning",icon:e.jsx(S.Warning,{}),children:i("maker.publishToProductionTip")}),e.jsx(s.Box,{maxHeight:"50vh",overflow:"auto",mt:2,children:e.jsx(J,{state:d,toMode:t,onChange:y=>n=y,defaultPageIds:L})})]}),okText:i("maker.publish"),cancelText:i("common.cancel"),onOk:async()=>{var y,u;if((n==null?void 0:n.length)===0){const x=i("maker.publishSelectPagesMessage");throw A.default.error(x),new Error(x)}for(const x of n??d.pageIds){const I=d.pages[x];if(I){const P=(u=(y=v.checkPage(i,I,d))==null?void 0:y[0])==null?void 0:u.message;if(P)throw A.default.error(P),new Error(P)}}localStorage.setItem(v.getProjectPageVersionKey(p??""),String(new Date().getTime())),h(!0);try{await C.publishPages({mode:t,pages:n}),A.default.success(i("maker.publishSuccessMessage"))}catch(x){throw A.default.error(x.message),x}finally{h(!1)}}})},[t,d,i,p,T]);c.useImperativeHandle(b,()=>({openPublishDialog:f}));const k=c.useCallback(()=>{f()},[f]);return e.jsxs(e.Fragment,{children:[e.jsx(E.LoadingButton,{color:"primary",variant:"contained",size:"small",sx:{mr:2},onClick:k,loading:m,disabled:m,children:i("maker.publishToProduction")}),g]})});function J({state:t,toMode:d,onChange:b,defaultPageIds:i}){const{t:m,locale:h}=q.useLocaleContext(),[g,T]=c.useState(!1),[p,f]=c.useState(()=>i?Object.fromEntries(i.map(r=>[r,!0])):{}),{loading:k,error:L,value:n}=_.useAsync(()=>C.getPages({mode:d}),[d]);if(L)throw L;const y=c.useMemo(()=>JSON.parse(JSON.stringify(t.pageIds)).sort((a,j)=>{const o=t.pages[a],l=t.pages[j];return o!=null&&o.publishedAt&&new Date(o.publishedAt).getTime()<new Date(o.updatedAt).getTime()?-1:l!=null&&l.publishedAt&&new Date(l.publishedAt).getTime()<new Date(l.updatedAt).getTime()?1:new Date((o==null?void 0:o.updatedAt)??"").getTime()-new Date((l==null?void 0:l.updatedAt)??"").getTime()}),[t]),u=c.useMemo(()=>n?D.default(n.pageIds,t.pageIds):[],[t,n]),x=c.useMemo(()=>[...t.pageIds].concat(u),[t,u]),I=c.useCallback(r=>{f(a=>{const j=W.produce(a,o=>{g?(Object.assign(o,Object.fromEntries(x.map(l=>[l,!0]))),delete o[r]):o[r]?(delete o[r],u.includes(r)&&t.pageIds.filter(l=>{var w,B;return((w=t.pages[l])==null?void 0:w.slug)===((B=n==null?void 0:n.pages[r])==null?void 0:B.slug)}).forEach(l=>{delete o[l]})):(o[r]=!0,t.pageIds.includes(r)&&u.filter(l=>{var w,B;return((w=n==null?void 0:n.pages[l])==null?void 0:w.slug)===((B=t.pages[r])==null?void 0:B.slug)}).forEach(l=>{o[l]=!0}))});return T(D.default(x,Object.keys(j)).length===0),j})},[g,x,u,t,n]),P=c.useCallback(()=>{T(r=>(r&&f({}),!r))},[p]);return c.useEffect(()=>{b(g?null:Object.keys(p))},[g,p,b]),k?e.jsx(C.Loading,{sx:{my:4}}):e.jsxs(s.List,{disablePadding:!0,sx:{maxWidth:500},children:[e.jsx(s.ListItem,{sx:{position:"sticky",top:0,bgcolor:"background.paper",zIndex:1},disablePadding:!0,children:e.jsxs(s.ListItemButton,{onClick:P,dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g,tabIndex:-1})}),e.jsx(s.ListItemText,{primary:m("common.all")})]})}),y.map(r=>{var l,w;const a=t.pages[r];if(!a)return null;const j=v.checkPage(m,a,t),o=!a.publishedAt||a.updatedAt&&new Date(a.updatedAt).getTime()>new Date(a.publishedAt).getTime();return e.jsx(s.ListItem,{disablePadding:!0,secondaryAction:e.jsxs(e.Fragment,{children:[o&&e.jsx(s.Tooltip,{title:m("maker.pages.needPublish"),children:e.jsx(S.Sync,{fontSize:"small",sx:{color:"warning.main",fontSize:16,mr:.35}})}),!a.isPublic&&e.jsx(s.Tooltip,{title:m("maker.pages.notPublic"),children:e.jsx(S.VisibilityOff,{fontSize:"small",sx:{color:"warning.main",fontSize:16,mr:.35}})}),j&&e.jsx(v.PageErrorTip,{errors:j,children:e.jsx(S.Warning,{sx:{color:"error.dark",mr:.35}})})]}),children:e.jsxs(s.ListItemButton,{onClick:()=>I(r),dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g||!!p[r],tabIndex:-1})}),e.jsx(s.ListItemText,{primary:a.slug,secondary:(w=(l=a.locales)==null?void 0:l[h])==null?void 0:w.title,primaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"},secondaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"}})]})},r)}),u.map(r=>{var j,o;const a=n==null?void 0:n.pages[r];return a?e.jsx(s.ListItem,{disablePadding:!0,secondaryAction:e.jsx(s.Chip,{color:"warning",label:"deleted",size:"small"}),children:e.jsxs(s.ListItemButton,{onClick:()=>I(r),dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g||!!p[r],tabIndex:-1})}),e.jsx(s.ListItemText,{primary:a.slug,secondary:(o=(j=a.locales)==null?void 0:j[h])==null?void 0:o.title,primaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"},secondaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"}})]})},r):null})]})}exports.default=H;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),v=require("./state-BjeG4kYg.js"),q=require("@arcblock/ux/lib/Locale/context"),O=require("@arcblock/ux/lib/Toast"),S=require("@mui/icons-material"),E=require("@mui/lab"),s=require("@mui/material"),W=require("immer"),z=require("lodash/difference"),c=require("react"),_=require("react-use"),C=require("./home-D0r5jd24.js"),M=t=>t&&t.__esModule?t:{default:t},A=M(O),D=M(z);function N(t){const[d,b]=c.useState(!1);return e.jsx(E.LoadingButton,{...t,loading:t.loading||d,onClick:i=>{var h;const m=(h=t.onClick)==null?void 0:h.call(t,i);m instanceof Promise&&(b(!0),m.finally(()=>{b(!1)}))}})}const R=s.createSvgIcon(e.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[e.jsx("path",{d:"M7.75732 16.2426L16.2426 7.75736",stroke:"#4B5563",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),e.jsx("path",{d:"M16.2426 16.2426L7.75732 7.75735",stroke:"#4B5563",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),"Close");function F(){const[t,d]=c.useState(),b=c.useMemo(()=>t?e.jsx(s.Dialog,{...t}):null,[t]),i=c.useCallback(()=>{d(void 0)},[]),m=c.useCallback(({title:h,content:g,cancelText:T="Cancel",okText:p="Ok",onOk:f,onClose:k,okIcon:L,okColor:n="primary",cancelColor:y="primary",DialogContentProps:u,form:x,...I})=>{d({...I,open:!0,children:e.jsxs("form",{onSubmit:P=>P.preventDefault(),children:[h&&e.jsxs(s.DialogTitle,{className:"between",zIndex:"appBar",bgcolor:"background.paper",sx:{borderBottom:"1px solid #E5E7EB"},children:[e.jsx(s.Box,{children:h}),e.jsx(s.IconButton,{size:"small",onClick:async()=>{i(),k==null||k()},children:e.jsx(R,{})})]}),g&&e.jsx(s.DialogContent,{...u,sx:{mt:-3,...u==null?void 0:u.sx},children:e.jsx(s.Box,{pt:3,children:g})}),e.jsxs(s.DialogActions,{children:[e.jsx(s.Button,{variant:"outlined",color:y||"primary",onClick:k??i,children:T}),e.jsx(N,{variant:"contained",color:n||"primary",startIcon:L,loadingPosition:L?"start":"center",onClick:async()=>{await(f==null?void 0:f()),i()},type:"submit",children:p})]})]}),onClose:k??i})},[i]);return{dialog:b,showDialog:m,closeDialog:i}}const H=c.forwardRef(({mode:t,state:d},b)=>{const{t:i}=q.useLocaleContext(),[m,h]=c.useState(!1),{dialog:g,showDialog:T}=F(),p=v.useProjectId(),f=c.useCallback(L=>{let n=[];T({title:i("maker.publishToProduction"),content:e.jsxs(s.Box,{sx:{minWidth:300},children:[e.jsx(s.Alert,{color:"warning",icon:e.jsx(S.Warning,{}),children:i("maker.publishToProductionTip")}),e.jsx(s.Box,{maxHeight:"50vh",overflow:"auto",mt:2,children:e.jsx(J,{state:d,toMode:t,onChange:y=>n=y,defaultPageIds:L})})]}),okText:i("maker.publish"),cancelText:i("common.cancel"),onOk:async()=>{var y,u;if((n==null?void 0:n.length)===0){const x=i("maker.publishSelectPagesMessage");throw A.default.error(x),new Error(x)}for(const x of n??d.pageIds){const I=d.pages[x];if(I){const P=(u=(y=v.checkPage(i,I,d))==null?void 0:y[0])==null?void 0:u.message;if(P)throw A.default.error(P),new Error(P)}}localStorage.setItem(v.getProjectPageVersionKey(p??""),String(new Date().getTime())),h(!0);try{await C.publishPages({mode:t,pages:n}),A.default.success(i("maker.publishSuccessMessage"))}catch(x){throw A.default.error(x.message),x}finally{h(!1)}}})},[t,d,i,p,T]);c.useImperativeHandle(b,()=>({openPublishDialog:f}));const k=c.useCallback(()=>{f()},[f]);return e.jsxs(e.Fragment,{children:[e.jsx(E.LoadingButton,{color:"primary",variant:"contained",size:"small",sx:{mr:2},onClick:k,loading:m,disabled:m,children:i("maker.publishToProduction")}),g]})});function J({state:t,toMode:d,onChange:b,defaultPageIds:i}){const{t:m,locale:h}=q.useLocaleContext(),[g,T]=c.useState(!1),[p,f]=c.useState(()=>i?Object.fromEntries(i.map(r=>[r,!0])):{}),{loading:k,error:L,value:n}=_.useAsync(()=>C.getPages({mode:d}),[d]);if(L)throw L;const y=c.useMemo(()=>JSON.parse(JSON.stringify(t.pageIds)).sort((a,j)=>{const o=t.pages[a],l=t.pages[j];return o!=null&&o.publishedAt&&new Date(o.publishedAt).getTime()<new Date(o.updatedAt).getTime()?-1:l!=null&&l.publishedAt&&new Date(l.publishedAt).getTime()<new Date(l.updatedAt).getTime()?1:new Date((o==null?void 0:o.updatedAt)??"").getTime()-new Date((l==null?void 0:l.updatedAt)??"").getTime()}),[t]),u=c.useMemo(()=>n?D.default(n.pageIds,t.pageIds):[],[t,n]),x=c.useMemo(()=>[...t.pageIds].concat(u),[t,u]),I=c.useCallback(r=>{f(a=>{const j=W.produce(a,o=>{g?(Object.assign(o,Object.fromEntries(x.map(l=>[l,!0]))),delete o[r]):o[r]?(delete o[r],u.includes(r)&&t.pageIds.filter(l=>{var w,B;return((w=t.pages[l])==null?void 0:w.slug)===((B=n==null?void 0:n.pages[r])==null?void 0:B.slug)}).forEach(l=>{delete o[l]})):(o[r]=!0,t.pageIds.includes(r)&&u.filter(l=>{var w,B;return((w=n==null?void 0:n.pages[l])==null?void 0:w.slug)===((B=t.pages[r])==null?void 0:B.slug)}).forEach(l=>{o[l]=!0}))});return T(D.default(x,Object.keys(j)).length===0),j})},[g,x,u,t,n]),P=c.useCallback(()=>{T(r=>(r&&f({}),!r))},[p]);return c.useEffect(()=>{b(g?null:Object.keys(p))},[g,p,b]),k?e.jsx(C.Loading,{sx:{my:4}}):e.jsxs(s.List,{disablePadding:!0,sx:{maxWidth:500},children:[e.jsx(s.ListItem,{sx:{position:"sticky",top:0,bgcolor:"background.paper",zIndex:1},disablePadding:!0,children:e.jsxs(s.ListItemButton,{onClick:P,dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g,tabIndex:-1})}),e.jsx(s.ListItemText,{primary:m("common.all")})]})}),y.map(r=>{var l,w;const a=t.pages[r];if(!a)return null;const j=v.checkPage(m,a,t),o=!a.publishedAt||a.updatedAt&&new Date(a.updatedAt).getTime()>new Date(a.publishedAt).getTime();return e.jsx(s.ListItem,{disablePadding:!0,secondaryAction:e.jsxs(e.Fragment,{children:[o&&e.jsx(s.Tooltip,{title:m("maker.pages.needPublish"),children:e.jsx(S.Sync,{fontSize:"small",sx:{color:"warning.main",fontSize:16,mr:.35}})}),!a.isPublic&&e.jsx(s.Tooltip,{title:m("maker.pages.notPublic"),children:e.jsx(S.VisibilityOff,{fontSize:"small",sx:{color:"warning.main",fontSize:16,mr:.35}})}),j&&e.jsx(v.PageErrorTip,{errors:j,children:e.jsx(S.Warning,{sx:{color:"error.dark",mr:.35}})})]}),children:e.jsxs(s.ListItemButton,{onClick:()=>I(r),dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g||!!p[r],tabIndex:-1})}),e.jsx(s.ListItemText,{primary:a.slug,secondary:(w=(l=a.locales)==null?void 0:l[h])==null?void 0:w.title,primaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"},secondaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"}})]})},r)}),u.map(r=>{var j,o;const a=n==null?void 0:n.pages[r];return a?e.jsx(s.ListItem,{disablePadding:!0,secondaryAction:e.jsx(s.Chip,{color:"warning",label:"deleted",size:"small"}),children:e.jsxs(s.ListItemButton,{onClick:()=>I(r),dense:!0,children:[e.jsx(s.ListItemIcon,{children:e.jsx(s.Checkbox,{edge:"start",checked:g||!!p[r],tabIndex:-1})}),e.jsx(s.ListItemText,{primary:a.slug,secondary:(o=(j=a.locales)==null?void 0:j[h])==null?void 0:o.title,primaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"},secondaryTypographyProps:{noWrap:!0,textOverflow:"ellipsis"}})]})},r):null})]})}exports.default=H;
package/lib/cjs/home.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require("react/jsx-runtime");require("./_chunks/state-BjeG4kYg.js");const e=require("./_chunks/home-BFxAZSGy.js");require("@arcblock/ux/lib/Locale/context");require("@arcblock/ux/lib/Result");require("@blocklet/pages-kit/builtin/page/header");require("@blocklet/ui-react/lib/Header");require("@emotion/css");require("@emotion/react");require("@emotion/styled");require("@mui/material");require("ahooks");require("isomorphic-dompurify");require("lodash");require("lodash/isEmpty");require("react");require("react-helmet");require("react-router-dom");require("react-use");require("ufo");exports.HomeView=e.HomeView;exports.PageRoutes=e.PageRoutes;exports.PageView=e.PageView;exports.PageViewByPath=e.PageViewByPath;exports.TranslucentHeader=e.TranslucentHeader;exports.default=e.Home;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require("react/jsx-runtime");require("./_chunks/state-BjeG4kYg.js");const e=require("./_chunks/home-D0r5jd24.js");require("@arcblock/ux/lib/Locale/context");require("@arcblock/ux/lib/Result");require("@blocklet/pages-kit/builtin/page/header");require("@blocklet/ui-react/lib/Header");require("@emotion/css");require("@emotion/react");require("@emotion/styled");require("@mui/material");require("ahooks");require("isomorphic-dompurify");require("lodash");require("lodash/isEmpty");require("react");require("react-helmet");require("react-router-dom");require("react-use");require("ufo");exports.HomeView=e.HomeView;exports.PageRoutes=e.PageRoutes;exports.PageView=e.PageView;exports.PageViewByPath=e.PageViewByPath;exports.TranslucentHeader=e.TranslucentHeader;exports.default=e.Home;
@@ -2262,7 +2262,7 @@ function at({
2262
2262
  !((bt = a.footer) != null && bt.hidden) && /* @__PURE__ */ n(wo, {})
2263
2263
  ] });
2264
2264
  }
2265
- const To = Dt(() => import("./publish-button-BWD3lOEM.js")), re = Ht(pe)`
2265
+ const To = Dt(() => import("./publish-button-DUkACr5d.js")), re = Ht(pe)`
2266
2266
  &.sticky {
2267
2267
  position: sticky;
2268
2268
  top: 0;
@@ -2283,7 +2283,7 @@ function Eo({ logo: t }) {
2283
2283
  return /* @__PURE__ */ n(b, { sx: { filter: "initial !important" }, dangerouslySetInnerHTML: { __html: Se.sanitize(e) } });
2284
2284
  if (r) {
2285
2285
  const i = new URL(r);
2286
- i.searchParams.set("imageFilter", "convert"), i.searchParams.set("f", "png"), i.searchParams.set("h", "88"), i.searchParams.set("hash", "00c22ff");
2286
+ i.searchParams.set("imageFilter", "convert"), i.searchParams.set("f", "png"), i.searchParams.set("h", "80");
2287
2287
  const s = i.toString();
2288
2288
  return /* @__PURE__ */ n("img", { src: s, alt: "logo" });
2289
2289
  }
@@ -9,7 +9,7 @@ import { produce as oe } from "immer";
9
9
  import N from "lodash/difference";
10
10
  import { useState as D, useMemo as j, useCallback as L, forwardRef as se, useImperativeHandle as le, useEffect as ce } from "react";
11
11
  import { useAsync as ae } from "react-use";
12
- import { p as de, g as ue, L as me } from "./home-BTLUdaL7.js";
12
+ import { p as de, g as ue, L as me } from "./home-BX1L-H5W.js";
13
13
  function ge(r) {
14
14
  const [a, y] = D(!1);
15
15
  return /* @__PURE__ */ e(
package/lib/es/home.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import "react/jsx-runtime";
2
2
  import "./_chunks/state-DqChB5ys.js";
3
- import { a as b, P as h, c as x, b as y, T as B, H as R } from "./_chunks/home-BTLUdaL7.js";
3
+ import { a as b, P as h, c as x, b as y, T as B, H as R } from "./_chunks/home-BX1L-H5W.js";
4
4
  import "@arcblock/ux/lib/Locale/context";
5
5
  import "@arcblock/ux/lib/Result";
6
6
  import "@blocklet/pages-kit/builtin/page/header";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/pages-kit-inner-components",
3
- "version": "0.4.76",
3
+ "version": "0.4.78",
4
4
  "description": "Pages Kit inner components library",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -202,8 +202,8 @@
202
202
  "yaml": "^2.5.0",
203
203
  "yjs": "^13.6.18",
204
204
  "zustand": "^4.5.5",
205
- "@blocklet/pages-kit": "^0.4.76",
206
- "@blocklet/pages-kit-block-studio": "^0.4.76"
205
+ "@blocklet/pages-kit": "^0.4.78",
206
+ "@blocklet/pages-kit-block-studio": "^0.4.78"
207
207
  },
208
208
  "devDependencies": {
209
209
  "@trivago/prettier-plugin-sort-imports": "^5.2.1",