umwd-components 0.1.294 → 0.1.296
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/components/FluidBackground.js +1 -1
- package/dist/src/components/auth/AuthWidget.js +1 -1
- package/dist/src/components/auth/DenseSigninForm.js +1 -1
- package/dist/src/components/common/Address.js +1 -1
- package/dist/src/components/common/Pagination.js +1 -1
- package/dist/src/components/e-commerce/cart/AddToCartButton.client.js +1 -1
- package/dist/src/components/e-commerce/cart/CartDisplay.js +1 -1
- package/dist/src/components/e-commerce/cart/CartSummary.js +1 -1
- package/dist/src/components/e-commerce/cart/CartSummaryRow.js +1 -1
- package/dist/src/components/e-commerce/cart/CartWidget.js +1 -1
- package/dist/src/components/e-commerce/checkout/Step1.js +1 -1
- package/dist/src/components/e-commerce/checkout/Step2.js +1 -1
- package/dist/src/components/e-commerce/checkout/Step3.js +1 -1
- package/dist/src/components/e-commerce/checkout/Step4.js +1 -1
- package/dist/src/components/e-commerce/checkout/Step5.js +1 -1
- package/dist/src/components/e-commerce/customer/BusinessCredentials.js +1 -1
- package/dist/src/components/e-commerce/customer/CustomerProfileDisplay.js +1 -1
- package/dist/src/components/e-commerce/customer/CustomerProfileEditForm.js +1 -1
- package/dist/src/components/e-commerce/customer/DenseCustomerProfileDisplay.js +1 -1
- package/dist/src/components/e-commerce/opo/OpoDisplay.js +1 -1
- package/dist/src/components/e-commerce/opo/OpoSummary.js +1 -1
- package/dist/src/components/e-commerce/opo/OpoSummaryRow.js +1 -1
- package/dist/src/components/e-commerce/opo/PaymentStatusIndicator.js +1 -1
- package/dist/src/components/e-commerce/products/Price.js +1 -1
- package/dist/src/components/e-commerce/products/ProductCard.js +1 -1
- package/dist/src/components/e-commerce/products/ProductCategoryCard.js +1 -1
- package/dist/src/components/e-commerce/products/SingleProduct.js +1 -1
- package/dist/src/components/page-builder/PBFeaturesSection.js +1 -1
- package/dist/src/components/page-builder/PBHeroSection.js +1 -1
- package/dist/src/components/page-builder/PBPersonaliaSection.js +1 -1
- package/dist/src/components/page-builder/PBTextImageSection.js +1 -1
- package/dist/src/components/page-builder/PictureBarSection.js +1 -1
- package/dist/src/components/page-elements/HeroSection.js +1 -1
- package/dist/src/components/page-elements/LogoBarSection.js +1 -1
- package/dist/src/components/page-elements/PictureBarSection.js +1 -1
- package/dist/src/components/page-elements/TextImageSection.js +1 -1
- package/dist/src/data/services/get-user-me-loader.js +1 -1
- package/dist/src/index.js +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/types/components/e-commerce/customer/BusinessCredentials.d.ts +3 -3
- package/dist/types/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/FluidBackground.tsx +1 -1
- package/src/components/auth/AuthWidget.tsx +4 -6
- package/src/components/auth/DenseSigninForm.tsx +2 -1
- package/src/components/common/Address.tsx +3 -1
- package/src/components/common/Pagination.tsx +3 -1
- package/src/components/e-commerce/cart/AddToCartButton.client.tsx +1 -1
- package/src/components/e-commerce/cart/CartDisplay.tsx +8 -13
- package/src/components/e-commerce/cart/CartSummary.tsx +10 -11
- package/src/components/e-commerce/cart/CartSummaryRow.tsx +4 -1
- package/src/components/e-commerce/cart/CartWidget.tsx +11 -11
- package/src/components/e-commerce/checkout/CheckoutForm.tsx +14 -15
- package/src/components/e-commerce/checkout/Step1.tsx +6 -8
- package/src/components/e-commerce/checkout/Step2.tsx +5 -1
- package/src/components/e-commerce/checkout/Step3.tsx +4 -1
- package/src/components/e-commerce/checkout/Step4.tsx +4 -1
- package/src/components/e-commerce/checkout/Step5.tsx +5 -1
- package/src/components/e-commerce/customer/BusinessCredentials.tsx +6 -1
- package/src/components/e-commerce/customer/CustomerProfileDisplay.tsx +8 -10
- package/src/components/e-commerce/customer/CustomerProfileEditForm.tsx +8 -9
- package/src/components/e-commerce/customer/DenseCustomerProfileDisplay.tsx +6 -12
- package/src/components/e-commerce/opo/OpoDisplay.tsx +8 -8
- package/src/components/e-commerce/opo/OpoSummary.tsx +10 -10
- package/src/components/e-commerce/opo/OpoSummaryRow.tsx +3 -1
- package/src/components/e-commerce/opo/PaymentStatusIndicator.tsx +3 -1
- package/src/components/e-commerce/products/Price.tsx +6 -1
- package/src/components/e-commerce/products/ProductCard.tsx +10 -10
- package/src/components/e-commerce/products/ProductCategoryCard.tsx +6 -1
- package/src/components/e-commerce/products/SingleProduct.tsx +8 -1
- package/src/components/page-builder/PBFeaturesSection.tsx +10 -13
- package/src/components/page-builder/PBHeroSection.tsx +8 -12
- package/src/components/page-builder/PBPersonaliaSection.tsx +11 -13
- package/src/components/page-builder/PBTextImageSection.tsx +10 -10
- package/src/components/page-builder/PictureBarSection.tsx +8 -2
- package/src/components/page-elements/HeroSection.tsx +9 -10
- package/src/components/page-elements/LogoBarSection.tsx +7 -2
- package/src/components/page-elements/PictureBarSection.tsx +8 -3
- package/src/components/page-elements/TextImageSection.tsx +8 -9
- package/src/index.ts +1 -0
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as e}from"../../node_modules/tslib/tslib.es6.js";import t,{useState as n,useEffect as E}from"react";import{useTheme as a}from"@mui/material";function i(){var i=e(n(0),2),r=i[0],o=i[1],l=e(n(0),2),
|
|
7
|
+
import{__read as e}from"../../node_modules/tslib/tslib.es6.js";import t,{useState as n,useEffect as E}from"react";import{useTheme as a}from"@mui/material/styles";function i(){var i=e(n(0),2),r=i[0],o=i[1],l=e(n(0),2),s=l[0],c=l[1],m=e(n(300),2),d=m[0],p=m[1],T=a();return E((function(){o(window.innerWidth/2),c(window.innerHeight/2),p(Math.sqrt(Math.pow(window.innerWidth,2)+Math.pow(window.innerHeight,2))/1.3)}),[]),E((function(){var e=function(e){!function(e,t){o(e),c(t)}(e instanceof TouchEvent?e.touches[0].clientX:e.clientX,e instanceof TouchEvent?e.touches[0].clientY:e.clientY)};return window.addEventListener("touchmove",e),window.addEventListener("mousemove",e),function(){window.removeEventListener("touchmove",e),window.removeEventListener("mousemove",e)}}),[]),t.createElement("div",{style:{position:"fixed",top:0,left:0,width:"100vw",height:"100vh",zIndex:-1,pointerEvents:"none",isolation:"isolate"}},t.createElement("div",{id:"background",style:{position:"absolute",top:0,left:0,display:"Block",width:"100%",height:"100%",background:T.palette.background.paper,zIndex:-1}}),t.createElement("svg",{id:"object",width:"".concat(d,"px"),height:"".concat(d,"px"),style:{position:"absolute",top:"".concat(s,"px"),left:"".concat(r,"px"),transform:"translate(-50%, -50%)"}},t.createElement("defs",null,t.createElement("mask",{id:"radial-gradient-mask"},t.createElement("radialGradient",{id:"gradient",cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%"},t.createElement("stop",{offset:"0%",stopColor:"white"}),t.createElement("stop",{offset:"100%",stopColor:"black"})),t.createElement("rect",{width:"100%",height:"100%",fill:"url(#gradient)"}))),t.createElement("rect",{width:"100%",height:"100%",fill:T.palette.primary.main,mask:"url(#radial-gradient-mask)",style:{filter:"opacity(.5)"}})),t.createElement("svg",{id:"foreground",style:{position:"absolute"},preserveAspectRatio:"xMidYMid slice",width:"100%",height:"100%",viewBox:"0 0 7680 4320 "},t.createElement("defs",null,t.createElement("mask",{id:"mask"},t.createElement("rect",{width:"100%",height:"100%",fill:"white"}),t.createElement("text",{transform:"translate(-1000 200) rotate(-15)",style:{fill:"#000",fontFamily:"Merriweather-Bold, Merriweather",fontSize:"360px",fontWeight:700,letterSpacing:".055em"}},t.createElement("tspan",{x:"0",y:"0"},"JELLE PAULUS IS A TALENTED WEB DEVELOPER AND"," "),t.createElement("tspan",{x:"0",y:"432"},"DESIGNER WITH A PASSION FOR CREATING VISUALLY"," "),t.createElement("tspan",{x:"0",y:"864"},"STUNNING AND USER-FRIENDLY WEBSITES. WITH A"," "),t.createElement("tspan",{x:"0",y:"1296"},"KEEN EYE FOR DETAIL AND A FOCUS ON CREATING"," "),t.createElement("tspan",{x:"0",y:"1728"},"CLEAN, FUNCTIONAL DESIGNS, JELLE HAS A"," "),t.createElement("tspan",{x:"0",y:"2160"},"REPUTATION FOR DELIVERING HIGH-QUALITY WORK"," "),t.createElement("tspan",{x:"0",y:"2592"},"THAT EXCEEDS HIS CLIENTS' EXPECTATIONS. HE HAS A"," "),t.createElement("tspan",{x:"0",y:"3024"},"DEEP UNDERSTANDING OF THE LATEST WEB"," "),t.createElement("tspan",{x:"0",y:"3456"},"DEVELOPMENT TECHNOLOGIES, AND IS ABLE TO"," "),t.createElement("tspan",{x:"0",y:"3888"},"SEAMLESSLY INTEGRATE FUNCTIONALITY AND"," "),t.createElement("tspan",{x:"0",y:"4320"},"AESTHETICS TO CREATE WEBSITES THAT ARE BOTH"," "),t.createElement("tspan",{x:"0",y:"4752"},"FUNCTIONAL AND VISUALLY APPEALING. WHETHER"," "),t.createElement("tspan",{x:"0",y:"5184"},"YOU'RE LOOKING TO ESTABLISH AN ONLINE PRESENCE"," "),t.createElement("tspan",{x:"0",y:"5616"},"OR REVAMP AN EXISTING WEBSITE, JELLE HAS THE"," "),t.createElement("tspan",{x:"0",y:"6048"},"SKILLS AND EXPERTISE TO BRING YOUR VISION TO LIFE.")))),t.createElement("rect",{width:"100%",height:"100%",fill:T.palette.background.default,mask:"url(#mask)"})))}export{i as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import e from"react";import
|
|
7
|
+
import e from"react";import t from"@mui/material/SpeedDial";import o from"@mui/material/SpeedDialAction";import i from"@mui/material/Box";import r from"@mui/material/CircularProgress";import n from"@mui/icons-material/AccountCircle";import m from"@mui/icons-material/Person";import l from"@mui/icons-material/Folder";import a from"@mui/icons-material/ListAlt";import u from"@mui/icons-material/Login";import c from"@mui/icons-material/Logout";import s from"@mui/icons-material/HowToReg";import{useRouter as p}from"next/navigation";import{useSession as f}from"../../context/auth/SessionContext.js";var d={loggedIn:[{icon:e.createElement(m,null),name:"Profile",route:"/user/profile"},{icon:e.createElement(a,null),name:"Orders",route:"/user/orders"},{icon:e.createElement(l,null),name:"Documents",route:"/user/documents"}],loggedOut:[{icon:e.createElement(u,null),name:"Sign-In",route:"/auth/signin"},{icon:e.createElement(s,null),name:"Register",route:"/auth/register"}]};function g(m){var l=m.actions,a=void 0===l?d:l,u=p(),s=f(),g=s.user,x=s.loading,h=s.error,E=s.logout;return x?e.createElement(i,{sx:{display:{xs:"none",md:"flex"},flexGrow:0,position:"relative",width:"40px",height:"40px"}},e.createElement(r,null)):h?e.createElement("p",null,"Error: ",h):e.createElement(i,{sx:{display:{xs:"none",md:"flex"},flexGrow:0,position:"relative",width:"40px",height:"40px"}},e.createElement(t,{ariaLabel:"SpeedDial basic example",icon:e.createElement(n,null),direction:"down",sx:{position:"absolute",top:0,right:0,width:40,"& .MuiFab-root":{width:40,height:40}}},(g?a.loggedIn:a.loggedOut).map((function(t){return e.createElement(o,{key:t.name,icon:t.icon,tooltipTitle:t.name,onClick:function(){return u.push(t.route)}})})),g&&e.createElement(o,{icon:e.createElement(c,null),tooltipTitle:"Log-Out",onClick:function(){return E()}})))}export{g as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as r}from"../../../node_modules/tslib/tslib.es6.js";import e from"react";import{useFormState as
|
|
7
|
+
import{__read as r}from"../../../node_modules/tslib/tslib.es6.js";import e from"react";import{useFormState as i}from"react-dom";import{loginUserAction as t}from"../../data/actions/auth-actions.js";import o from"@mui/material/Stack";import l from"@mui/material/TextField";import{SubmitButton as a}from"../SubmitButton.js";import{StrapiErrors as n}from"../StrapiErrors.js";import{useTheme as d}from"@mui/material/styles";var m={zodErrors:null,strapiErrors:null,data:null,message:null};function s(s){var u,p,v,c,f=s.data.redirect_url,E=void 0===f?"/":f,w=r(i(t,m),2),x=w[0],b=w[1];return d(),e.createElement("form",{action:b},e.createElement("input",{type:"hidden",name:"redirect",value:E}),e.createElement(o,{spacing:2},e.createElement(l,{id:"identifier",name:"identifier",label:"identifier",variant:"outlined",error:null!=(null===(u=null==x?void 0:x.zodErrors)||void 0===u?void 0:u.identifier),helperText:null===(p=null==x?void 0:x.zodErrors)||void 0===p?void 0:p.identifier}),e.createElement(l,{id:"password",name:"password",label:"password",type:"password",variant:"outlined",error:null!=(null===(v=null==x?void 0:x.zodErrors)||void 0===v?void 0:v.password),helperText:null===(c=null==x?void 0:x.zodErrors)||void 0===c?void 0:c.password}),e.createElement(a,{text:"Sign In",loadingText:"Loading"}),e.createElement(n,{error:null==x?void 0:x.strapiErrors})))}export{s as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import
|
|
6
|
+
import e from"@mui/material/Stack";import t from"@mui/material/TextField";import a from"@mui/material/Typography";import n from"@mui/icons-material/Home";import r from"react";function l(t){var l=t.data,m=l.title;l.id;var i=l.street,c=l.street_number,o=l.street_number_addition,d=l.postal_code,u=l.city;return r.createElement(e,null,r.createElement(e,{spacing:2,direction:"row"},r.createElement(n,null),r.createElement(e,null,r.createElement(a,{variant:"h6"},m),r.createElement(a,{variant:"body1",component:"p"},i," ",c," ",o),r.createElement(a,{variant:"body1",component:"p"},d," ",u))))}function m(a){var l=a.data,m=a.componentName,i=a.componentReference,c=l||{},o=c.id,d=c.street,u=c.street_number,p=c.street_number_addition,s=c.postal_code,_=c.city;return r.createElement(e,{spacing:2,direction:"row"},r.createElement(n,null),r.createElement(e,{spacing:1,sx:{flex:1}},r.createElement("input",{id:"",type:"hidden",name:"".concat(m,".__component"),value:i}),o&&r.createElement("input",{id:"",type:"hidden",name:"".concat(m,".id"),value:o}),r.createElement(t,{id:"street",name:"".concat(m,".street"),label:"Street",defaultValue:d||""}),r.createElement(t,{id:"street_number",name:"".concat(m,".street_number"),label:"Street Number",defaultValue:u||""}),r.createElement(t,{id:"street_number_addition",name:"".concat(m,".street_number_addition"),label:"Street Number Addition",defaultValue:p||""}),r.createElement(t,{id:"postal_code",name:"".concat(m,".postal_code"),label:"Postal Code",defaultValue:s||""}),r.createElement(t,{id:"city",name:"".concat(m,".city"),label:"City",defaultValue:_||""})))}export{m as AddressFields,l as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import t from"react";import{useRouter as e,usePathname as a,useSearchParams as
|
|
7
|
+
import t from"react";import{useRouter as e,usePathname as a,useSearchParams as r}from"next/navigation";import n from"@mui/material/Pagination";import i from"@mui/material/Box";import{useTheme as o}from"@mui/material/styles";function m(m){var l=m.pageCount,u=e(),p=o(),c=a(),g=r(),s=null!==g?Number(g.get("page")):1;return t.createElement(i,{sx:[{background:p.palette.primary.main,p:2,textAlign:"center",borderRadius:2,mt:2},Boolean(1==l)&&{visibility:"hidden"}]},t.createElement(n,{count:l,page:s,onChange:function(t,e){var a,r,n=(a=e,(r=new URLSearchParams(null!=g?g:"")).set("page",a.toString()),"".concat(c,"?").concat(r.toString()));u.push(n)},disabled:Boolean(1===l)}))}export{m as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import t from"react";import
|
|
7
|
+
import t from"react";import r from"@mui/material/Button";import{useCart as a}from"../../../context/e-commerce/cart/CartContext.js";var o=function(o){var e=o.product,n=a().dispatch;return t.createElement(r,{size:"small",variant:"contained",onClick:function(){n({type:"ADD_ITEM",payload:e})}},"Add to Card")};export{o as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import e from"react";import
|
|
7
|
+
import e from"react";import t from"@mui/material/Grid";import r from"@mui/material/Paper";import a from"@mui/material/Stack";import i from"@mui/material/Button";import o from"@mui/material/Typography";import n from"@mui/material/CircularProgress";import m from"next/link";import{useClientSideCart as l}from"./hooks.js";import c from"./CartSummary.js";function h(h){var s=h.data,p=s.shopUrl,E=void 0===p?"/shop":p,d=s.checkoutUrl,g=void 0===d?"/shop/check-out":d,u=l(),x=u.state;return u.isClient?e.createElement(t,{container:!0,spacing:2,sx:{py:3,minHeight:"60vh"}},e.createElement(t,{item:!0,xs:12},e.createElement(o,{variant:"h4",align:"center",component:"h1"},"My cart")),e.createElement(t,{item:!0,xs:12},e.createElement(r,{sx:{width:"100%",p:2}},e.createElement(a,{spacing:2},e.createElement(c,null),x.items.length>0&&e.createElement(a,{spacing:2},e.createElement(a,{direction:"row"},e.createElement(o,{sx:{width:"10%"}}),e.createElement(o,{sx:{width:"60%",color:"#555"}},"Total excl. VAT"),e.createElement(o,{sx:{width:"30%",color:"#555"},align:"right"},"€ ",x.totalExVAT.toFixed(2))),e.createElement(a,{direction:"row"},e.createElement(o,{sx:{width:"10%"}}),e.createElement(o,{sx:{width:"60%",color:"#555"}},"Total VAT"),e.createElement(o,{sx:{width:"30%",color:"#555"},align:"right"},"€ ",x.totalVAT.toFixed(2))),e.createElement(a,{direction:"row"},e.createElement(o,{sx:{width:"10%"}}),e.createElement(o,{sx:{width:"60%",color:"#555",fontWeight:600}},"Total"),e.createElement(o,{sx:{width:"30%",color:"#555",fontWeight:600},align:"right"},"€ ",x.totalInclVAT.toFixed(2)))),e.createElement(a,{spacing:2,justifyContent:"space-between"},e.createElement(m,{href:E,legacyBehavior:!0},e.createElement(i,{variant:"outlined"},"Continue shopping")),x.items.length>0&&e.createElement(m,{href:g,legacyBehavior:!0},e.createElement(i,{variant:"contained"},"Check Out"))))))):e.createElement(n,null)}export{h as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import e from"@mui/material/Box";import t from"@mui/material/Table";import r from"@mui/material/TableBody";import l from"@mui/material/TableRow";import a from"@mui/material/TableCell";import m from"@mui/material/TableFooter";import o from"@mui/material/Typography";import i from"@mui/material/useMediaQuery";import n from"@mui/material/CircularProgress";import{useTheme as c}from"@mui/material/styles";import s from"./CartSummaryRow.js";import{useClientSideCart as u}from"./hooks.js";import p from"react";var x=function(){var x=u(),f=x.state,E=x.isClient,T=c(),d=i(T.breakpoints.down("sm"));return E?p.createElement(e,{sx:{p:{xs:1,md:2}}},f.items.length>0?p.createElement(t,null,p.createElement(r,null,f.items.map((function(e){return p.createElement(s,{key:e.id,data:e})}))),p.createElement(m,null,p.createElement(l,null,!d&&p.createElement(a,{sx:{p:{xs:1,sm:2}}}),p.createElement(a,{sx:{p:{xs:1,sm:2}},colSpan:d?2:1}),d?p.createElement(p.Fragment,null,p.createElement(a,{colSpan:2,align:"right",sx:{color:"#555",padding:1}},p.createElement(o,{sx:{fontSize:14}},"Total "),p.createElement(o,{sx:{fontSize:14}},"excl VAT: € ",f.totalExVAT.toFixed(2)),p.createElement(o,{sx:{fontSize:14}},"incl VAT: € ",f.totalInclVAT.toFixed(2)))):p.createElement(p.Fragment,null,p.createElement(a,{colSpan:1,align:"right",sx:{color:"#555"}},"Total excl VAT: € ",f.totalExVAT.toFixed(2)),p.createElement(a,{colSpan:2,align:"right",sx:{color:"#555",fontSize:16,fontWeight:600}},"Total: € ",f.totalInclVAT.toFixed(2)))))):p.createElement(o,null,"No products in cart")):p.createElement(n,null)};export{x as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import e from"react";import
|
|
7
|
+
import e from"react";import t from"@mui/material/TableRow";import r from"@mui/material/TableCell";import a from"@mui/material/IconButton";import m from"@mui/material/useMediaQuery";import{useTheme as i}from"@mui/material/styles";import l from"next/image";import o from"@mui/icons-material/Delete";import c from"../products/Price.js";import{useCart as n}from"../../../context/e-commerce/cart/CartContext.js";function s(s){var p=s.data,u=p.id,x=p.thumb,f=p.title,E=p.vat_rate,d=p.price_excl_vat,v=p.price_incl_vat,_=p.quantity,y=i(),b=m(y.breakpoints.down("sm")),h=n().dispatch;return e.createElement(t,{key:u},e.createElement(r,{sx:{p:{xs:1,sm:2}}},_," * "),e.createElement(r,{sx:{p:{xs:1,sm:2}}},e.createElement(c,{price:d,vat_rate:E,vat:d*E,price_incl_vat:v})),e.createElement(r,{sx:{p:{xs:1,sm:2}}},f),!b&&e.createElement(r,{sx:{p:{xs:1,sm:2}}},e.createElement("div",{style:{position:"relative",width:"40px",height:"40px"}},null!==x&&e.createElement(l,{src:x,alt:"Thumbnail of product",fill:!0,sizes:"5vw",style:{objectFit:"cover"}}))),e.createElement(r,{sx:{p:0}},e.createElement(a,{"aria-label":"delete",onClick:function(){h({type:"REMOVE_ITEM",payload:{id:u}})},sx:{p:0}},e.createElement(o,null))))}export{s as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as
|
|
7
|
+
import{__read as r}from"../../../../node_modules/tslib/tslib.es6.js";import e,{useState as t}from"react";import o from"@mui/material/Box";import a from"@mui/material/Popover";import i from"@mui/material/Stack";import m from"@mui/material/Button";import l from"@mui/material/Badge";import n from"@mui/material/IconButton";import c from"@mui/material/CircularProgress";import p from"@mui/material/useMediaQuery";import{useTheme as s}from"@mui/material/styles";import u from"next/link";import x from"@mui/icons-material/ShoppingCart";import f from"./CartSummary.js";import{useClientSideCart as h}from"./hooks.js";function d(d){var g=d.data,v=g.cartUrl,E=void 0===v?"/shop/cart":v,b=g.checkoutUrl,k=void 0===b?"/shop/check-out":b,C=h(),y=C.state,B=C.isClient,w=r(t(null),2),z=w[0],S=w[1],j=function(){S(null)},O=Boolean(z),T=O?"cart-widget-popover":void 0,P=s(),U=p(P.breakpoints.down("sm"));return B?e.createElement(o,{sx:{flexGrow:0,position:"relative",width:"40px",height:"40px",mr:"10px"}},e.createElement(l,{badgeContent:y.totalAmount,color:"primary"},e.createElement(n,{"aria-describedby":T,onClick:function(r){S(r.currentTarget)},sx:{color:"primary.contrastText",boxShadow:"0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)","&:hover":{backgroundColor:"primary.dark"}}},e.createElement(x,{sx:{color:"primary.contrastText"}}))),e.createElement(a,{id:T,open:O,anchorEl:z,onClose:j,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},sx:{top:"25px"}},e.createElement(f,null),e.createElement(i,{spacing:{xs:1,sm:2},sx:{p:{xs:1,sm:2}}},e.createElement(u,{href:E,legacyBehavior:!0},e.createElement(m,{size:U?"small":"large",variant:"outlined",onClick:function(){j()}},e.createElement(x,null))),e.createElement(u,{href:k,legacyBehavior:!0},e.createElement(m,{size:U?"small":"large",variant:"contained",onClick:function(){j()}},"Check Out"))))):e.createElement(c,null)}export{d as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import t from"react";import
|
|
7
|
+
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import t from"react";import r from"@mui/material/Box";import n from"@mui/material/CircularProgress";import a from"@mui/material/Paper";import i from"@mui/material/Typography";import o from"@mui/material/Button";import m from"@mui/material/Stack";import{useSession as l}from"../../../context/auth/SessionContext.js";import c from"../../auth/DenseSigninForm.js";import u from"../../auth/DenseRegisterForm.js";function s(){var s=l(),p=s.user,E=s.loading,d=s.error,f=s.logout;if(E)return t.createElement(r,{sx:{display:{xs:"none",md:"flex"},flexGrow:0,position:"relative",width:"40px",height:"40px"}},t.createElement(n,null));if(d)return t.createElement("p",null,"Error: ",d);var g=(null==p?void 0:p.customer_profile)?p.customer_profile:null,h=e(t.useState(!1),2),v=h[0],y=h[1];return t.createElement(a,{sx:{p:2}},p?t.createElement(t.Fragment,null,g?t.createElement(t.Fragment,null,t.createElement(i,{variant:"h6"},"Dear ",g.first_name," ",g.last_name,", are you ready to checkout?"),t.createElement(m,{spacing:2,direction:"row",alignItems:"center"},t.createElement(i,{variant:"body1"},"Not ",g.first_name," ",g.last_name,"?"),t.createElement(o,{variant:"outlined",onClick:function(){return f()}},"sign in as somebody else"))):t.createElement(t.Fragment,null,t.createElement(i,{variant:"h6"},"Dear ",p.username,", ",p.email,", are you ready to checkout?"),t.createElement(m,{spacing:2,direction:"row",alignItems:"center"},t.createElement(i,{variant:"body1"},"Not"," ",p.username&&p.email?"".concat(p.username," ").concat(p.email):"".concat(p.username),"?"),t.createElement(o,{variant:"outlined",onClick:function(){return f()}},"sign in as somebody else")))):t.createElement(t.Fragment,null,v?t.createElement(m,{spacing:2},t.createElement(i,{variant:"h6"},"Register to continue"),t.createElement(i,{variant:"body1"},"Enter your details to register an account"),t.createElement(u,{data:{redirect_url:"/shop/check-out"}}),t.createElement(o,{variant:"outlined",onClick:function(){return y(!1)}},"Sign in")):t.createElement(m,{spacing:2},t.createElement(i,{variant:"h6"},"Sign in to continue"),t.createElement(i,{variant:"body1"},"Enter your details to sign in to your account"),t.createElement(c,{data:{redirect_url:"/shop/check-out"}}),t.createElement(o,{variant:"outlined",onClick:function(){return y(!0)}},"Register"))))}export{s as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import
|
|
7
|
+
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import r,{useState as t,useEffect as o}from"react";import i from"@mui/material/Button";import m from"@mui/material/Paper";import a from"@mui/material/Stack";import n from"@mui/material/Box";import l from"@mui/material/CircularProgress";import{useSession as s}from"../../../context/auth/SessionContext.js";import{isCustomerProfileComplete as c}from"../../../lib/isCustomerProfileComplete.js";import u from"../customer/DenseCustomerProfileDisplay.js";import f from"../customer/CustomerProfileEditForm.js";function p(){var p=s(),d=p.user,E=p.loading,x=p.error;if(E)return r.createElement(n,{sx:{display:{xs:"none",md:"flex"},flexGrow:0,position:"relative",width:"40px",height:"40px"}},r.createElement(l,null));if(x)return r.createElement("p",null,"Error: ",x);var C=(null==d?void 0:d.customer_profile)?d.customer_profile:null,g=e(t(!1),2),v=g[0],h=g[1];return o((function(){c(C)?h(!1):h(!0)}),[C]),r.createElement(m,{sx:{p:2}},v?r.createElement(a,{spacing:2},r.createElement(f,{data:C}),r.createElement(i,{variant:"contained",onClick:function(){h(!1)},disabled:!c(C)},"cancel")):r.createElement(a,{spacing:2},r.createElement(u,{data:C}),r.createElement(i,{variant:"contained",onClick:function(){h(!0)}},"Change address")))}export{p as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import e from"react";import
|
|
6
|
+
import e from"react";import r from"@mui/material/Paper";import t from"@mui/material/Stack";import m from"@mui/material/Typography";function a(){return e.createElement(r,{sx:{p:2}},e.createElement(t,{spacing:2},e.createElement("form",null,e.createElement(m,null,"Options for delivery"),e.createElement(m,null,"Preffered payment method"))))}export{a as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import t,{Fragment as e}from"react";import a from"@mui/material/Paper";import r from"@mui/material/Stack";import{useClientSideCart as m}from"../cart/hooks.js";import n from"../cart/CartSummary.js";function i(){var i=m().state;return t.createElement(a,{sx:{p:2}},t.createElement(r,{spacing:2},t.createElement(n,null),i.items&&i.items.map((function(a,r){return t.createElement(e,{key:r},t.createElement("input",{type:"hidden",name:"opo_items[".concat(r,"].product"),value:a.id}),t.createElement("input",{type:"hidden",name:"opo_items[".concat(r,"].quantity"),value:a.quantity}))}))))}export{i as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import t,{useState as r,useEffect as o}from"react";import{getSingleOrder as
|
|
6
|
+
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import t,{useState as r,useEffect as o}from"react";import{getSingleOrder as i}from"../../../data/loaders/e-commerce-loaders.js";import{useSearchParams as l}from"next/navigation";import n from"../opo/OpoDisplay.js";import m from"@mui/material/Paper";import a from"@mui/material/Stack";import c from"@mui/material/Typography";import s from"@mui/material/useMediaQuery";import u from"@mui/icons-material/MoreVert";import p from"@mui/icons-material/ListAlt";import d from"@mui/icons-material/AccountCircle";import{useTheme as f}from"@mui/material/styles";function h(){var h=l(),E=e(r(null),2),g=E[0],v=E[1],y=null!==h?h.get("order"):null,x=f(),k=s(x.breakpoints.down("md"));return o((function(){y&&i(y).then((function(e){e.error?v(null):v(e)}))}),[y]),y&&null!==g?g?t.createElement(m,{sx:{p:2}},t.createElement(a,{spacing:2},g&&t.createElement(n,{opo:g}),t.createElement(c,{variant:"h6"},"Thank you for shopping with us!"),t.createElement(c,null,"You are always able to access your information and documents in your personal details."),k?t.createElement(c,null,"Click on the ",t.createElement(u,{sx:{verticalAlign:"middle"}})," icon in the top-right bottom of the screen, then click on"," ",t.createElement(p,{sx:{verticalAlign:"middle"}})," Orders"):t.createElement(c,null,"Hover over the"," ",t.createElement(d,{sx:{verticalAlign:"middle"}})," icon in the top-right corner of the screen, then click on"," ",t.createElement(p,{sx:{verticalAlign:"middle"}})," Orders"))):t.createElement("div",null,"Loading..."):t.createElement("div",null,"No order to display...")}export{h as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import
|
|
6
|
+
import e from"@mui/material/Typography";import n from"@mui/material/Stack";import t from"@mui/material/Box";import a from"@mui/material/TextField";import m from"@mui/icons-material/BusinessCenter";import r from"react";function c(a){var c=a.data,o=c.company_name,i=c.business_entity_name,l=c.coc_number,u=c.vat_number;return r.createElement(n,{spacing:2,direction:"row"},r.createElement(m,null),r.createElement(t,null,r.createElement(e,{variant:"h6",component:"p"},o),r.createElement(e,{variant:"body2",component:"p"},i),r.createElement(e,{variant:"body2",component:"p"},l),r.createElement(e,{variant:"body2",component:"p"},u)))}function o(e){var t=e.data,c=e.componentName,o=e.componentReference,i=t||{},l=i.id,u=i.company_name,p=i.business_entity_name,d=i.coc_number,s=i.vat_number;return r.createElement(n,{spacing:2,direction:"row"},r.createElement(m,null),r.createElement(n,{spacing:1,sx:{flex:1}},r.createElement("input",{id:"component_name",type:"hidden",name:"".concat(c,".__component"),value:o}),l&&r.createElement("input",{id:"component_id",type:"hidden",name:"".concat(c,".id"),value:l}),r.createElement(a,{id:"company_name",name:"".concat(c,".company_name"),label:"Company Name",defaultValue:u}),r.createElement(a,{id:"business_entity_name",name:"".concat(c,".business_entity_name"),label:"Business Entity Name",defaultValue:p}),r.createElement(a,{id:"coc_number",name:"".concat(c,".coc_number"),label:"CoC Number",defaultValue:d}),r.createElement(a,{id:"vat_number",name:"".concat(c,".vat_number"),label:"VAT Number",defaultValue:s})))}export{o as BusinessCredentialsFields,c as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__assign as e}from"../../../../node_modules/tslib/tslib.es6.js";import
|
|
6
|
+
import{__assign as e}from"../../../../node_modules/tslib/tslib.es6.js";import t from"@mui/material/Paper";import r from"@mui/material/Stack";import a from"@mui/material/Box";import l from"@mui/material/Typography";import m from"@mui/material/Button";import n from"@mui/material/Divider";import i from"@mui/material/Grid";import o from"@mui/icons-material/Person";import s from"@mui/icons-material/Email";import c from"@mui/icons-material/Phone";import d from"../../common/Address.js";import p from"./BusinessCredentials.js";import{StyledLink as E}from"../../StyledLink.js";import u from"react";function f(f){var v=f.data;console.log(v);var b=v.first_name,y=v.last_name,g=v.email,x=v.phone,_=v.company_address,B=v.billing_address,j=v.delivery_address,w=v.business_credentials,P=v.editProfileUrl,h=void 0===P?"/user/profile/edit":P;return u.createElement(t,{sx:{p:2}},u.createElement(r,{spacing:2},u.createElement(r,{direction:"row",alignItems:"center",justifyContent:"space-between",sx:{p:2,border:"2px solid red"}},u.createElement(l,{sx:{color:"red"}},"Profile not complete"),u.createElement(E,{href:h,target:"_self"},u.createElement(m,{variant:"contained"},"complete profile"))),w?u.createElement(p,{data:w}):u.createElement(l,null,"Business credentials not available"),u.createElement(n,null),u.createElement(r,{spacing:2,direction:"row"},u.createElement(o,null),u.createElement(a,null,u.createElement(l,{variant:"body1",component:"p"},b," ",y))),u.createElement(r,{spacing:2,direction:"row"},u.createElement(s,null),u.createElement(a,null,u.createElement(l,{variant:"body1",component:"p"},g))),u.createElement(r,{spacing:2,direction:"row"},u.createElement(c,null),u.createElement(a,null,u.createElement(l,{variant:"body1",component:"p"},x))),u.createElement(n,null),u.createElement(i,{container:!0},_?u.createElement(i,{item:!0,xs:12,md:4},u.createElement(d,{data:e(e({},_),{title:"Company Address"})})):u.createElement(l,null,"Company address not available"),j?u.createElement(i,{item:!0,xs:12,md:4},u.createElement(d,{data:e(e({},j),{title:"Delivery Address"})})):u.createElement(i,{item:!0,xs:12,md:4},u.createElement(l,null,"Delivery address not available")),B?u.createElement(i,{item:!0,xs:12,md:4},u.createElement(d,{data:e(e({},B),{title:"Billing Address"})})):u.createElement(i,{item:!0,xs:12,md:4},u.createElement(l,null,"Billing address not available")))))}export{f as default};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import
|
|
7
|
+
import{__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import r from"@mui/material/Divider";import a from"@mui/material/Paper";import t from"@mui/material/Box";import m from"@mui/material/Stack";import n from"@mui/material/Alert";import o from"@mui/material/TextField";import l from"@mui/material/Typography";import{AddressFields as s}from"../../common/Address.js";import{SubmitButton as i}from"../../SubmitButton.js";import{useFormState as d}from"react-dom";import{updateCustomerProfileAction as c}from"../../../data/actions/profile-actions.js";import{StrapiErrors as p}from"../../StrapiErrors.js";import{BusinessCredentialsFields as u}from"./BusinessCredentials.js";import{useSession as f}from"../../../context/auth/SessionContext.js";import E,{useEffect as v}from"react";var _={zodErrors:null,strapiErrors:null,data:null,message:null};function g(g){var b=g.data,y=b.id;b.uuid,b.customer_number;var h=b.first_name,x=b.last_name,j=b.email,N=b.phone,A=b.company_address,S=b.delivery_address,B=b.billing_address,C=b.business_credentials,R=e(d(c,_),2),T=R[0],V=R[1],k=f().refreshSession;return v((function(){!T.strapiErrors&&T.message&&k()}),[T]),E.createElement(t,{component:a,sx:{p:2}},E.createElement("form",{action:V},E.createElement(m,{spacing:2},E.createElement(m,{direction:"row-reverse",spacing:2,alignItems:"center",sx:{backgroundColor:"secondary.dark",px:2,py:1}},E.createElement(i,{text:"save changes",loadingText:"loading",sx:{color:"secondary.contrastText"}}),E.createElement(p,{error:null==T?void 0:T.strapiErrors}),(null==T?void 0:T.message)&&E.createElement(n,{severity:"error"},null==T?void 0:T.message)),E.createElement("input",{type:"hidden",name:"id",value:y}),E.createElement(o,{id:"first_name",name:"first_name",label:"First Name",defaultValue:h}),E.createElement(o,{id:"last_name",name:"last_name",label:"Last Name",defaultValue:x}),E.createElement(o,{id:"email",name:"email",label:"Email",defaultValue:j}),E.createElement(o,{id:"phone",name:"phone",label:"Phone",defaultValue:N}),E.createElement(l,{variant:"h6"},"Company Address"),E.createElement(r,null),E.createElement(s,{componentName:"company_address",componentReference:"common.address",data:A}),E.createElement(l,{variant:"h6"},"Delivery Address"),E.createElement(r,null),E.createElement(s,{componentName:"delivery_address",componentReference:"common.address",data:S}),E.createElement(l,{variant:"h6"},"Billing Address"),E.createElement(r,null),E.createElement(s,{componentName:"billing_address",componentReference:"common.address",data:B}),E.createElement(r,null),E.createElement(u,{componentName:"business_credentials",componentReference:"business.credentials",data:C}))))}export{g as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__assign as e}from"../../../../node_modules/tslib/tslib.es6.js";import
|
|
6
|
+
import{__assign as e}from"../../../../node_modules/tslib/tslib.es6.js";import t from"@mui/material/Stack";import a from"@mui/material/Box";import r from"@mui/material/Typography";import m from"@mui/material/Divider";import l from"@mui/material/Grid";import n from"@mui/icons-material/Person";import i from"@mui/icons-material/Email";import o from"@mui/icons-material/Phone";import s from"../../common/Address.js";import c from"./BusinessCredentials.js";import d from"react";function E(E){var p=E.data,u=p.first_name,f=void 0===u?"":u,v=p.last_name,b=p.email,y=p.phone,g=p.company_address,x=p.billing_address,_=p.delivery_address,B=p.business_credentials;return d.createElement(t,{spacing:2},B?d.createElement(c,{data:B}):d.createElement(r,null,"Business credentials not available"),d.createElement(m,null),d.createElement(t,{spacing:2,direction:"row"},d.createElement(n,null),d.createElement(a,null,d.createElement(r,{variant:"body1",component:"p"},f," ",v))),d.createElement(t,{spacing:2,direction:"row"},d.createElement(i,null),d.createElement(a,null,d.createElement(r,{variant:"body1",component:"p"},b))),d.createElement(t,{spacing:2,direction:"row"},d.createElement(o,null),d.createElement(a,null,d.createElement(r,{variant:"body1",component:"p"},y))),d.createElement(m,null),d.createElement(l,{container:!0},g?d.createElement(l,{item:!0,xs:12,md:4},d.createElement(s,{data:e(e({},g),{title:"Company Address"})})):d.createElement(r,null,"Company address not available"),_?d.createElement(l,{item:!0,xs:12,md:4},d.createElement(s,{data:e(e({},_),{title:"Delivery Address"})})):d.createElement(l,{item:!0,xs:12,md:4},d.createElement(r,null,"Delivery address not available")),x?d.createElement(l,{item:!0,xs:12,md:4},d.createElement(s,{data:e(e({},x),{title:"Billing Address"})})):d.createElement(l,{item:!0,xs:12,md:4},d.createElement(r,null,"Billing address not available"))))}export{E as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import e from"react";import
|
|
6
|
+
import e from"react";import t from"@mui/material/Typography";import l from"@mui/material/Table";import r from"@mui/material/TableHead";import a from"@mui/material/TableRow";import m from"@mui/material/TableCell";import n from"@mui/material/TableBody";import{OpoSummary as o}from"./OpoSummary.js";import{PaymentStatusIndicator as i}from"./PaymentStatusIndicator.js";function u(u){var d,p,c,E,v=u.opo;return e.createElement(e.Fragment,null,e.createElement(t,{variant:"h5"},"Order Details"),e.createElement(l,null,e.createElement(r,null,e.createElement(a,null,e.createElement(m,null,"Order number"),e.createElement(m,null,"Order Date"),e.createElement(m,null,"Payment status"))),e.createElement(n,null,e.createElement(a,null,e.createElement(m,null,v.opo_number),e.createElement(m,null,v.order_date),e.createElement(m,null,e.createElement(i,{payment_status:null===(p=null===(d=null==v?void 0:v.payments)||void 0===d?void 0:d[0])||void 0===p?void 0:p.payment_status,provider_id:null===(E=null===(c=null==v?void 0:v.payments)||void 0===c?void 0:c[0])||void 0===E?void 0:E.provider_id}))))),e.createElement(t,{variant:"body1"},"Contents of the order:"),e.createElement(o,{opo:v}))}export{u as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import e from"react";import
|
|
6
|
+
import e from"react";import l from"@mui/material/Box";import t from"@mui/material/Table";import a from"@mui/material/TableBody";import r from"@mui/material/TableCell";import m from"@mui/material/TableHead";import n from"@mui/material/TableFooter";import o from"@mui/material/TableRow";import i from"@mui/material/Typography";import{OpoSummaryRow as c}from"./OpoSummaryRow.js";function u(u){var p=u.opo,E=p.opo_items;return e.createElement(l,{sx:{p:{xs:1,md:2}}},null!=E?e.createElement(t,null,e.createElement(m,null,e.createElement(o,null,e.createElement(r,null,"Amount"),e.createElement(r,null,"Product Title"),e.createElement(r,null,"Price Excl. VAT"),e.createElement(r,null,"Price Incl. VAT"))),e.createElement(a,null,E.map((function(l){return e.createElement(c,{key:l.id,data:l})}))),e.createElement(n,null,e.createElement(o,null,e.createElement(r,{colSpan:3,align:"right"},"Total excl VAT"),e.createElement(r,{colSpan:1,align:"left"},"€ ",p.total_excl_vat)),e.createElement(o,null,e.createElement(r,{colSpan:3,align:"right"},"Total incl VAT"),e.createElement(r,{colSpan:1,align:"left"},"€ ",p.total_incl_vat)))):e.createElement(i,null,"No products in cart"))}export{u as OpoSummary};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import e from"react";import
|
|
6
|
+
import e from"react";import l from"@mui/material/TableRow";import t from"@mui/material/TableCell";function r(r){var i,n,a=r.data;a.id;var o=a.quantity,u=a.product;return e.createElement(l,null,e.createElement(t,null,o),e.createElement(t,null,null==u?void 0:u.title),e.createElement(t,null,"€ ",null===(i=null==u?void 0:u.price)||void 0===i?void 0:i.price),e.createElement(t,null,"€ ",null===(n=null==u?void 0:u.price)||void 0===n?void 0:n.price_incl_vat))}export{r as OpoSummaryRow};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import r from"react";import
|
|
7
|
+
import r from"react";import t from"@mui/material/Chip";var e=function(e){var a=e.payment_status;return e.provider_id,r.createElement(t,{label:a})};export{e as PaymentStatusIndicator};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import t from"react";import
|
|
6
|
+
import t from"react";import a from"@mui/material/Chip";import e from"@mui/material/Tooltip";import r from"@mui/material/Typography";import i from"@mui/material/Stack";function m(m){var o=m.vat_rate,n=m.vat,c=m.price_incl_vat,l=m.price;return t.createElement(e,{title:t.createElement(i,{direction:"column"},t.createElement(r,{variant:"body2"},"vat rate: ",Math.round(100*o*100)/100," %"),t.createElement(r,{variant:"body2"},"vat: € ",Math.round(100*n)/100),t.createElement(r,{variant:"body2"},"price incl. vat: € ",Math.round(100*c)/100))},t.createElement(a,{label:"€ ".concat(Math.round(100*l)/100)}))}export{m as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__spreadArray as
|
|
6
|
+
import{__spreadArray as t,__read as e}from"../../../../node_modules/tslib/tslib.es6.js";import r from"react";import i from"@mui/material/Box";import a from"@mui/material/Card";import m from"@mui/material/CardActions";import o from"@mui/material/CardContent";import l from"@mui/material/CardMedia";import n from"@mui/material/Button";import c from"@mui/material/Typography";import p from"@mui/material/Stack";import u from"./Price.js";import{getStrapiMedia as s}from"../../../lib/utils.js";import{StyledLink as d}from"../../StyledLink.js";import f from"../cart/AddToCartButton.client.js";function _(_){var v=_.product,x=_.sx,h=void 0===x?[]:x,E=v.id,b=v.uuid,y=v.productNumber,g=v.title,C=v.description,j=v.slug,w=v.price,A=v.image,B=s(A.url),T=s(A.formats.thumbnail.url);return r.createElement(a,{sx:t([{width:"100%",height:"100%"},{display:"flex",flexDirection:"column"}],e(Array.isArray(h)?h:[h]),!1)},r.createElement(l,{component:"img",height:"140",src:"".concat(B),alt:A.alternativeText}),r.createElement(o,null,r.createElement(p,{direction:"row",justifyContent:"space-between",sx:{pb:2}},r.createElement(d,{href:"/shop/".concat(j),target:"_self"},r.createElement(c,{variant:"h5"},g)),r.createElement(u,{price:w.price,vat:w.vat,vat_rate:w.vat_rate,price_incl_vat:w.price_incl_vat})),r.createElement(c,{variant:"body2"},C&&C.substring(0,150)+"...")),r.createElement(i,{sx:{flexGrow:1}}),r.createElement(m,{sx:{display:"flex",justifyContent:"flex-end"}},r.createElement(n,{size:"small",href:"/shop/".concat(j)},"Learn More"),r.createElement(f,{product:{id:E,uuid:b,slug:j,thumb:T,title:g,vat_rate:w.vat_rate,price_excl_vat:w.price,price_incl_vat:w.price_incl_vat,quantity:1,product_number:y}})))}export{_ as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__spreadArray as e,__read as t}from"../../../../node_modules/tslib/tslib.es6.js";import r from"react";import
|
|
6
|
+
import{__spreadArray as e,__read as t}from"../../../../node_modules/tslib/tslib.es6.js";import r from"react";import a from"@mui/material/Grid";import i from"@mui/material/Card";import m from"@mui/material/Button";import n from"@mui/material/Typography";import o from"./ProductCard.js";function l(l){var c=l.category,s=l.sx,p=void 0===s?[]:s,d=c.title,u=c.description,f=c.slug,g=c.products;return r.createElement(i,{sx:e([{width:"100%",height:"100%",pt:2,pl:2,pb:2,mb:2}],t(Array.isArray(p)?p:[p]),!1)},r.createElement(a,{container:!0,xs:12,spacing:2},r.createElement(a,{item:!0,xs:12,sm:6,md:3,sx:{display:"flex",justifyContent:"start",alignItems:"center",gap:2,flexDirection:"column"}},r.createElement(n,{variant:"h4",component:"h1",align:"center"},d),r.createElement(n,{variant:"body2",align:"center"},u),r.createElement(m,{variant:"contained",color:"primary",href:"/shop/categories/".concat(f)},"See all ",c.title),g.data.length-3>0&&r.createElement(n,{variant:"body2"},g.data.length-3," more...")),g.data.slice(0,3).map((function(e){return r.createElement(a,{item:!0,xs:12,sm:6,md:3},r.createElement(o,{key:e.id,product:e}))}))))}export{l as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import e from"react";import
|
|
6
|
+
import e from"react";import t from"@mui/material/Box";import i from"@mui/material/Button";import r from"@mui/material/Typography";import l from"@mui/material/Stack";import a from"@mui/material/Grid";import n from"@mui/material/Paper";import{getStrapiMedia as m}from"../../../lib/utils.js";import o from"next/link";import{StrapiImage as c}from"../../StrapiImage.js";import u from"../cart/AddToCartButton.client.js";function d(d){var s,p,v,g,x=d.product;d.sx;var E=x.id,h=x.uuid,f=x.productNumber,y=x.title,_=x.description,b=x.slug,T=x.price,j=x.image;x.galery;var k=x.categories,w=x.stock,B=(null==j?void 0:j.url)?m(j.url):null,F=(null===(p=null===(s=null==j?void 0:j.formats)||void 0===s?void 0:s.thumbnail)||void 0===p?void 0:p.url)?m(j.formats.thumbnail.url):null;return e.createElement(e.Fragment,null,e.createElement(a,{container:!0,spacing:2,sx:{py:3,minHeight:"60vh"}},e.createElement(a,{item:!0,xs:12,sm:12,md:12,lg:12,xl:12},e.createElement(r,{variant:"h4",align:"left",component:"h1"},y)),e.createElement(a,{item:!0,xs:12,sm:8,md:9,lg:4,xl:4},e.createElement(r,{variant:"body1"},_)),e.createElement(a,{item:!0,xs:12,sm:4,md:3,lg:3,xl:3},(null==T?void 0:T.price)&&e.createElement(n,{sx:{p:1}},e.createElement(l,{spacing:1},e.createElement(r,{variant:"body2"},"Price excl. VAT € ",T.price.toFixed(2)),T.price_incl_vat&&e.createElement(r,{variant:"body2",sx:{fontWeight:600}},"Price incl. VAT € ",T.price_incl_vat.toFixed(2)),e.createElement(r,{variant:"body2",sx:{fontWeight:600,color:0===w?"red":"white"},align:"right"},w," items in stock"),e.createElement(u,{product:{id:E,uuid:h,slug:b,thumb:F,title:y,vat_rate:T.vat_rate,quantity:1,price_excl_vat:T.price,price_incl_vat:T.price_incl_vat,product_number:f}})))),e.createElement(a,{item:!0,xs:12,sm:12,md:6,lg:5,xl:5},null!==B&&e.createElement(t,{sx:{height:"400px",width:"100%",position:"relative"}},e.createElement(c,{id:j.id,url:B,alternativeText:j.alternativeText,fill:!0,style:{objectFit:"contain"}}))),e.createElement(a,{item:!0,xs:12,sm:12,md:6,lg:7,xl:7},e.createElement(a,{container:!0,spacing:2},e.createElement(a,{item:!0,xs:12},e.createElement(r,{variant:"h6"},"Image galery")),e.createElement(a,{item:!0,xs:12},e.createElement(l,{spacing:1,direction:"row"},(null===(v=null==x?void 0:x.galery)||void 0===v?void 0:v.data)&&x.galery.data.map((function(i){var r=(null==i?void 0:i.url)?m(i.url):null;return e.createElement(t,{key:i.id,sx:{width:" 150px",height:"150px",position:"relative"}},null!==r&&e.createElement(c,{id:i.id,url:r,alternativeText:i.alternativeText,fill:!0,style:{objectFit:"contain"}}))})))),e.createElement(a,{item:!0,xs:12,md:6},(null==k?void 0:k.data)&&e.createElement(l,{justifyContent:"center",alignItems:"center",direction:1===k.data.length?"row":"column"},1===k.data.length?e.createElement(r,null,"Category:"):e.createElement(r,null,"Categories:"),null===(g=k.data)||void 0===g?void 0:g.map((function(t){return e.createElement(o,{href:"/shop/categories/".concat(t.slug),key:t.id,legacyBehavior:!0},e.createElement(i,{variant:"text"},t.slug))})))),e.createElement(a,{item:!0,xs:12,md:6},e.createElement(l,null,e.createElement(o,{href:"/shop",legacyBehavior:!0},e.createElement(i,{variant:"outlined"},"continue shopping"))))))))}export{d as default};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.js";import t from"react";import
|
|
6
|
+
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.js";import t from"react";import a from"@mui/material/Stack";import i from"@mui/material/Card";import n from"@mui/material/CardContent";import o from"@mui/material/Box";import r from"@mui/material/Container";import l from"@mui/material/TextField";import c from"../../lib/getIcon.js";import{useTheme as m}from"@mui/material/styles";import{ExplanatoryFoldOut as s}from"../ExplanatoryFoldOut.js";function u(u){var d,p=u.data,f=u.index,h=p.feature,x=p.maxWidth,y=p.sx,g=void 0===y?{}:y,b=p.anchor,k=void 0===b?"":b,E=m();return t.createElement(r,{maxWidth:x||"lg",sx:e({my:1},g),id:k},t.createElement(o,{sx:{p:1,border:"1px dashed ".concat(E.palette.primary.main)}},t.createElement(s,{title:"Features section",description:"Direct the visitor to your most valuable services"}),t.createElement("input",{type:"hidden",name:"blocks[".concat(f,"].id"),value:p.id}),t.createElement("input",{type:"hidden",name:"blocks[".concat(f,"].__component"),value:"layout.features-section"}),t.createElement(a,{spacing:2,direction:"row",justifyContent:"stretch",flexWrap:"wrap",sx:(d={width:"100%"},d[E.breakpoints.up("xs")]={flexDirection:"column"},d[E.breakpoints.up("sm")]={flexDirection:"row"},d),useFlexGap:!0},h.map((function(e,a){var r=c(e.icon);return t.createElement(i,{id:e.anchor||"",key:e.id,sx:{display:"flex",flexDirection:"column",justifyContent:"space-between",flex:1,minWidth:275}},t.createElement(n,{sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:2}},t.createElement(o,{sx:{height:100,display:"grid",alignItems:"center",justifyContent:"center"}},null!==r&&t.createElement(r,{sx:{mr:2,mt:.2,width:"75px",height:"75px",fill:"none",stroke:"currentColor",strokeWidth:.5}})),t.createElement(l,{id:"blocks[".concat(f,"].feature[").concat(a,"].heading"),name:"blocks[".concat(f,"].feature[").concat(a,"].heading"),label:"heading",defaultValue:e.heading,variant:"outlined",sx:{input:{textAlign:"center",width:"100%",fontFamily:E.typography.h2.fontFamily,fontWeight:E.typography.h2.fontWeight,fontSize:E.typography.h2.fontSize}}}),t.createElement(l,{id:"blocks[".concat(f,"].feature[").concat(a,"].subHeading"),name:"blocks[".concat(f,"].feature[").concat(a,"].subHeading"),label:"subHeading",defaultValue:e.subHeading,multiline:!0,minRows:2,maxRows:7,sx:{width:"100%",textarea:{textAlign:"center",width:"100%",fontFamily:E.typography.h6.fontFamily,fontWeight:E.typography.h6.fontWeight,fontSize:E.typography.h6.fontSize}}}),e.text&&t.createElement(l,{id:"blocks[".concat(f,"].feature[").concat(a,"].text"),name:"blocks[".concat(f,"].feature[").concat(a,"].text"),label:"text",defaultValue:e.text,multiline:!0,sx:{width:"100%"}})))})))))}export{u as PBFeatureSection};
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* @copyright Jelle Paulus
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
import{__assign as t}from"../../../node_modules/tslib/tslib.es6.js";import e from"react";import
|
|
6
|
+
import{__assign as t}from"../../../node_modules/tslib/tslib.es6.js";import e from"react";import i from"@mui/material/Box";import n from"@mui/material/Stack";import o from"@mui/material/Container";import a from"@mui/material/Paper";import r from"@mui/material/TextField";import{StrapiImage as l}from"../StrapiImage.js";import{setOpacity as c}from"../../lib/utils.js";import{useTheme as m}from"@mui/material/styles";import{ExplanatoryFoldOut as p}from"../ExplanatoryFoldOut.js";function d(d){var s,u,g=d.data,h=d.index,y=g.heading,f=g.subHeading,x=g.bgImage,b=g.logoImage,k=g.link,v=g.maxWidth,E=g.sx,w=void 0===E?{}:E,F=g.glass,S=void 0!==F&&F,j=m();return e.createElement("div",{style:{position:"relative",padding:0,margin:0}},e.createElement("input",{type:"hidden",name:"blocks[".concat(h,"].id"),value:g.id}),e.createElement("input",{type:"hidden",name:"blocks[".concat(h,"].__component"),value:"layout.hero-section"}),e.createElement(i,{sx:t({display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"100%",overflow:"hidden",minHeight:"600px"},w)},x&&x.url&&e.createElement(l,{id:null===(s=x.id)||void 0===s?void 0:s.toString(),alternativeText:"Background",style:{position:"absolute",inset:0,objectFit:"cover",width:"100%",height:"100%"},height:x.height||1080,url:x.url,width:x.width||1920}),e.createElement(o,{maxWidth:v||"lg",sx:{my:1,zIndex:1}},e.createElement(i,{sx:{p:1,border:"1px dashed ".concat(j.palette.primary.main)}},e.createElement(p,{title:"Hero Section",description:"Use this to introduce yourself and create a link to you most important page. i.e. shop or contact"}),e.createElement(a,{sx:{px:2,py:7,backdropFilter:"blur(3px)",backgroundColor:c(j.palette.background.paper,S?.1:1),border:S?"1px solid rgba(255, 255, 255, 0.15)":"none"}},e.createElement(n,{spacing:5,alignItems:"center",justifyContent:"center"},b&&null!==b.url&&e.createElement(i,{className:"manipulator",sx:{position:"relative",mt:"-100px",width:"100%",zIndex:-1,display:"flex",justifyContent:"center",alignItems:"center",img:{objectFit:"contain",width:"100%",height:"100%"}}},e.createElement(l,{id:null===(u=b.id)||void 0===u?void 0:u.toString(),alternativeText:b.alternativeText||"logo image",height:b.height||100,url:b.url,width:b.width||100,style:{objectFit:"contain"}})),e.createElement(r,{id:"blocks[".concat(h,"].heading"),name:"blocks[".concat(h,"].heading"),label:"heading",defaultValue:y,variant:"outlined",sx:{input:{textAlign:"center",fontFamily:j.typography.h2.fontFamily,fontWeight:j.typography.h2.fontWeight,fontSize:j.typography.h2.fontSize}}}),e.createElement(i,{className:"spacer",sx:{display:"none"}}),e.createElement(r,{id:"blocks[".concat(h,"].subHeading"),name:"blocks[".concat(h,"].subHeading"),label:"subHeading",defaultValue:f,variant:"outlined",multiline:!0,rows:8,sx:{width:"100%","textarea#subHeading":{textAlign:"center",fontFamily:j.typography.h4.fontFamily,fontWeight:j.typography.h4.fontWeight,fontSize:j.typography.h4.fontSize,lineHeight:j.typography.h4.lineHeight}}}),e.createElement(n,{direction:"column",spacing:2,sx:{p:1,border:"1px dashed white",borderRadius:"4px"}},e.createElement(p,{title:"Link",description:"Link to the page on your website were you would like your client/customer to have an interaction"}),e.createElement(r,{id:"blocks[".concat(h,"].link.text"),name:"blocks[".concat(h,"].link.text"),label:"link.text",defaultValue:null==k?void 0:k.text,sx:{backgroundColor:j.palette.primary.main,borderRadius:"4px",input:{color:j.palette.primary.contrastText,textAlign:"center",fontFamily:j.typography.button.fontFamily,fontWeight:j.typography.button.fontWeight,fontSize:"1.5rem",letterSpacing:j.typography.button.letterSpacing,textTransform:j.typography.button.textTransform}}}),e.createElement(r,{id:"blocks[".concat(h,"].link.url"),name:"blocks[".concat(h,"].link.url"),label:"url",defaultValue:null==k?void 0:k.url,sx:{input:{textAlign:"center",fontFamily:j.typography.button.fontFamily,fontWeight:j.typography.button.fontWeight,fontSize:j.typography.button.fontSize}}}))))))))}export{d as PBHeroSection};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.js";import t from"react";import
|
|
7
|
+
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.js";import t from"react";import a from"@mui/material/Paper";import i from"@mui/material/Container";import r from"@mui/material/Grid";import o from"@mui/material/Button";import n from"@mui/material/Stack";import m from"@mui/material/Tooltip";import l from"@mui/material/TextField";import p from"@mui/material/Box";import{StrapiImage as c}from"../StrapiImage.js";import{LinkedIn as d,Email as s}from"@mui/icons-material";import{BlockRendererClient as u}from"../BlockRendererClient.js";import{StyledLink as f}from"../StyledLink.js";import{useTheme as h}from"@mui/material/styles";function y(i,p){var y,x,g=h();return t.createElement(r,{item:!0,xs:12,md:6,key:i.id},t.createElement(a,{sx:{p:2,height:"100%"}},t.createElement(r,{container:!0,spacing:3},t.createElement(r,{item:!0,xs:12,sm:7},t.createElement(n,{spacing:2},t.createElement(l,{id:"name",label:"Name",defaultValue:i.name,sx:{input:{fontFamily:g.typography.h5.fontFamily,fontWeight:g.typography.h5.fontWeight,fontSize:g.typography.h5.fontSize}}}),t.createElement(l,{id:"function",label:"Function",defaultValue:i.function,sx:{input:{fontFamily:g.typography.body2.fontFamily,fontWeight:g.typography.body2.fontWeight,fontSize:g.typography.body2.fontSize}}}),i.text&&t.createElement(u,{content:i.text}))),t.createElement(r,{item:!0,xs:12,sm:5},t.createElement(n,{spacing:2,sx:{overflow:"clip"},justifyContent:"center",alignItems:"stretch"},(null===(y=i.photo)||void 0===y?void 0:y.url)&&t.createElement(c,{id:i.photo.id,url:i.photo.url,alternativeText:i.photo.alternativeText,width:i.photo.width||200,height:i.photo.height||200,style:e({maxWidth:"100%",height:"auto",margin:"auto"},i.photo.style)}),(null===(x=i.links)||void 0===x?void 0:x.length)>0&&i.links.map((function(e){return t.createElement(f,{href:e.url,key:e.id,sx:{color:"dark"===g.palette.mode?g.palette.text.secondary:g.palette.secondary.main}},e.text)})),i.linkedIn&&t.createElement(o,{variant:"outlined",startIcon:t.createElement(d,null),href:i.linkedIn,target:"_blank",sx:{color:"dark"===g.palette.mode?g.palette.text.secondary:g.palette.secondary.main}},"LinkedIn"),i.email&&t.createElement(m,{title:"".concat(i.email)},t.createElement(o,{variant:"outlined",startIcon:t.createElement(s,null),href:"mailto:".concat(i.email),sx:{color:"dark"===g.palette.mode?g.palette.text.secondary:g.palette.secondary.main}},"Email")))))))}function x(a){var o=a.data;a.index;var n=o.partner,m=o.maxWidth,l=o.sx,c=void 0===l?{}:l,d=h();return t.createElement(i,{maxWidth:m||"lg",sx:e({my:1},c)},t.createElement(p,{sx:{p:1,border:"1px dashed ".concat(d.palette.primary.main)}},t.createElement(r,{container:!0,spacing:2},n&&n.map(y))))}export{x as PBPersonaliaSection};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__assign as e,__read as t}from"../../../node_modules/tslib/tslib.es6.js";import r,{useState as i,useEffect as
|
|
7
|
+
import{__assign as e,__read as t}from"../../../node_modules/tslib/tslib.es6.js";import r,{useState as i,useEffect as o}from"react";import n from"@mui/material/Box";import a from"@mui/material/Container";import l from"@mui/material/Paper";import m from"@mui/material/Typography";import d from"@mui/material/Grid";import c from"@mui/material/TextField";import{StrapiImage as u}from"../StrapiImage.js";import{useTheme as s}from"@mui/material/styles";import{setOpacity as g}from"../../lib/utils.js";function h(e){var a=e.image,l=s();if(void 0===a.url)return null;var m=t(i(0),2),d=m[0],c=m[1],g=function(){var e="image-container".concat(a.url),t=document.getElementById(e),r="image".concat(a.url),i=document.getElementById(r);if(null!==t&&null!==i){var o=t.getBoundingClientRect(),n=i.getBoundingClientRect();if(!(n.height>=o.height)){var l=o.height-n.height;o.y<=160&&-o.y<=o.height-n.height-160?c(160-o.y):o.y>0?c(0):c(l)}}};return o((function(){return window.addEventListener("scroll",g),function(){return window.removeEventListener("scroll",g)}}),[]),r.createElement(n,{id:"image-container".concat(a.url),sx:{height:"100%",position:"relative"}},r.createElement(u,{id:"image".concat(a.url),alternativeText:a.alternativeText,height:a.height,width:a.width,url:a.url,style:{width:"100%",height:"auto",display:"block",position:"relative",top:d,borderRadius:4,border:"1px solid ".concat(l.palette.secondary.main)}}))}function p(t){var i=t.data,o=i.title,u=i.text,p=i.image,v=i.reverse,f=void 0!==v&&v,x=i.maxWidth,E=i.sx,y=void 0===E?{}:E,b=i.glass,w=void 0!==b&&b,C=i.anchor,B=void 0===C?"":C,j=s();return r.createElement(a,{maxWidth:x||"lg",sx:e({my:1},y),id:B},r.createElement(n,{sx:{p:1,border:"1px dashed #fff"}},o&&r.createElement(m,{variant:"h1",textAlign:"center",sx:{pb:2}},o),r.createElement(d,{container:!0,spacing:2,direction:f?"row-reverse":"row"},r.createElement(d,{item:!0,xs:12,md:void 0!==(null==p?void 0:p.url)?8:12},r.createElement(l,{sx:{p:2,backdropFilter:"blur(3px)",backgroundColor:g(j.palette.background.paper,w?.1:1),border:w?"1px solid rgba(255, 255, 255, 0.15)":"none"}},null!=u&&r.createElement(n,{sx:{height:"100%",overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"flex-start"}},r.createElement(c,{multiline:!0,placeholder:u,value:u,onChange:function(e){return console.log(e.target.value)},sx:{width:"100%"}})))),void 0!==(null==p?void 0:p.url)&&r.createElement(d,{item:!0,xs:12,md:4},r.createElement(h,{image:p})))))}export{p as PBTextImageSection};
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* @copyright Jelle Paulus
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
|
-
import{__assign as
|
|
7
|
+
import{__assign as t}from"../../../node_modules/tslib/tslib.es6.js";import e from"react";import r from"@mui/material/Paper";import i from"@mui/material/Container";import a from"@mui/material/Grid";import m from"@mui/material/Box";import o from"@mui/material/Stack";import{StrapiImage as l}from"../StrapiImage.js";import{useTheme as n}from"@mui/material/styles";import{setOpacity as s}from"../../lib/utils.js";function p(p){var d=p.data,u=d.pictures,c=d.maxWidth,x=void 0===c?"lg":c,f=d.sx,g=void 0===f?{}:f,h=d.glass,b=void 0!==h&&h,E=n();return e.createElement(i,{maxWidth:x,sx:t({my:1},g)},e.createElement(a,{container:!0,spacing:2},e.createElement(a,{item:!0,xs:12},e.createElement(r,{sx:{p:2,backdropFilter:"blur(3px)",backgroundColor:s(E.palette.background.paper,b?.1:1),border:b?"1px solid rgba(255, 255, 255, 0.15)":"none"}},e.createElement(o,{direction:{xs:"column",sm:"row"},spacing:2,justifyContent:"space-around"},u.data&&u.data.map((function(r){return e.createElement(m,{key:r.id,sx:{flex:"1 1 0"}},e.createElement(l,{id:r.id.toString(),url:r.url,alternativeText:r.alternativeText,width:r.width,height:r.height,style:t(t({},r.style),{width:"100%",height:"auto"})}))})))))))}export{p as PictureBarSection};
|