PageSourceSearch

https://www.custompictureframes.com/_next/static/chunks/9804-924bc…?dpl=dpl_51frsFTtL9qnnTQrcz66bwEdLNbV

js custompictureframes.com collected 2026-10-04 07:59:39 UTC 26,538 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9804],{7291:function(e){function t(e){return Promise.resolve().then(function(){var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t})}t.keys=function(){return[]},t.resolve=t,t.id=7291,e.exports=t},68906:function(){},17987:function(e,t,r){"use strict";r.d(t,{m:function(){return i}});var n=r(7653),a=r(76319);function i(){let[e,t]=(0,n.useState)(null),[r,i]=(0,n.useState)(!0),[l,o]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{let e=!0;return(0,a.dG)().then(r=>{e&&(t(r),i(!1))}).catch(()=>{e&&(o(!0),i(!1))}),()=>{e=!1}},[]),{credit:e,isLoading:r,isError:l}}},52764:function(e,t,r){"use strict";r.d(t,{c:function(){return i},n:function(){return l}});var n=r(7653),a=r(76319);function i(){let{enabled:e=!0}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},[t,r]=(0,n.useState)([]),[i,l]=(0,n.useState)(e),[o,u]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{if(!e){r([]),l(!1),u(!1);return}let t=!0;return l(!0),(0,a.yZ)().then(e=>{t&&(r(e),l(!1))}).catch(()=>{t&&(u(!0),l(!1))}),()=>{t=!1}},[e]),{photos:t,isLoading:i,isError:o,remove:(0,n.useCallback)(async e=>{await (0,a.fR)(e),r(t=>t.filter(t=>t.id!==e))},[])}}function l(){return{record:(0,n.useCallback)(async e=>{await (0,a.m$)(e)},[])}}},68889:function(e,t,r){"use strict";r(7653),r(76367)},7773:function(e,t,r){"use strict";r.d(t,{m:function(){return i}});var n=r(7653),a=r(76319);function i(){let[e,t]=(0,n.useState)(null),[r,i]=(0,n.useState)(!0),[l,o]=(0,n.useState)(!1),[u,c]=(0,n.useState)(!1),[s,d]=(0,n.useState)(0);return(0,n.useEffect)(()=>{let e=!0;return i(!0),o(!1),(0,a.FE)().then(r=>{e&&(t(r),o(!r),i(!1))}).catch(()=>{e&&(o(!0),i(!1))}),()=>{e=!1}},[s]),{data:e,isLoading:r,isError:l,isRedeeming:u,redeem:(0,n.useCallback)(async e=>{c(!0);try{let t=await (0,a.EQ)(e);return t.ok&&d(e=>e+1),t}finally{c(!1)}},[]),refresh:(0,n.useCallback)(()=>d(e=>e+1),[])}}},11524:function(e,t,r){"use strict";r.d(t,{H:function(){return i}});var n=r(7653),a=r(76319);
1function i(e){let[t,r]=(0,n.useState)("idle"),[i,l]=(0,n.useState)("");return{status:t,message:i,submit:(0,n.useCallback)(async t=>{var n,i;t.preventDefault();let o=t.currentTarget,u=new FormData(o),c=String(null!==(n=u.get("email"))&&void 0!==n?n:"").trim(),s=String(null!==(i=u.get("website"))&&void 0!==i?i:"");if(!c){r("error"),l("Enter your email address.");return}r("submitting"),l("");try{await (0,a.xw)({email:c,source:e,website:s||void 0}),r("success"),l("You're subscribed. Look out for framing tips and offers."),o.reset()}catch(e){console.error("[newsletter] signup failed",e),r("error"),l("Something went wrong. Please try again.")}},[e]),isSubmitting:"submitting"===t}}},56789:function(e,t,r){"use strict";r.d(t,{o:function(){return i}});var n=r(7653),a=r(76319);function i(){let[e,t]=(0,n.useState)([]),[r,i]=(0,n.useState)(!0),[l,o]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{let e=!0;return(0,a.SM)().then(r=>{e&&(t(r),i(!1))}).catch(()=>{e&&(o(!0),i(!1))}),()=>{e=!1}},[]),{orders:e,isLoading:r,isError:l}}},43471:function(e,t,r){"use strict";r(7653)},84216:function(e,t,r){"use strict";r.d(t,{R:function(){return i}});var n=r(7653),a=r(76319);
1function i(e){let[t,r]=(0,n.useState)(null),[i,l]=(0,n.useState)(!0),[o,u]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{if(!e){l(!1),u(!0);return}let t=!0;return l(!0),u(!1),(0,a._J)(e).then(e=>{t&&(r(e),u(!e),l(!1))}).catch(()=>{t&&(u(!0),l(!1))}),()=>{t=!1}},[e]),{design:t,isLoading:i,isError:o}}},70117:function(e,t,r){"use strict";r.d(t,{U:function(){return o}});var n=r(55238),a=r(7653),i=r(40807),l=r(39161);function o(e){return(0,a.useMemo)(()=>{var t,r,a,o,u;let{frame:c,layoutId:s,matType:d,glass:f,hardware:h,brassPlaqueEnabled:m}=e,g=i.Hr.find(e=>e.id===s);if(!g||!c)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,printPrice:0,subtotal:0,total:0};let w=g.frameWidth-2*i.Lr,v=g.frameHeight-2*i.Lr,y=0,p=0;try{let e={serviceType:"frame-only",artworkWidth:w,artworkHeight:v,frameStyleId:c.id,matType:"none",matBorderWidth:0,matRevealWidth:0,matColorId:"mat-1",glassTypeId:null!==(t=null==f?void 0:f.id)&&void 0!==t?t:"standard"},n=(0,l.a4)(e);y=n.framePrice,p=null!==(r=n.glassPrice)&&void 0!==r?r:0}catch(e){y=(w+v)*2*(null!==(a=c.pricePerInch)&&void 0!==a?a:1.5)}let b=0,k=g.openingCount;k>1&&(b=(k-1)*12),"double"===d&&(b+=15);let P="security"===h?8.95:0,S=m?null!==(o=n.af.PRICE)&&void 0!==o?o:29:0,I=(null!==(u=e.printCount)&&void 0!==u?u:0)*8,F=Math.max(0,y+b+p+P+S+I);return{framePrice:null!=y?y:0,matPrice:null!=b?b:0,glassPrice:null!=p?p:0,hardwarePrice:null!=P?P:0,nameplatePrice:null!=S?S:0,printPrice:null!=I?I:0,subtotal:Number.isNaN(F)?0:F,total:Number.isNaN(F)?0:F}},[e])}},61024:function(e,t,r){"use strict";r.d(t,{J:function(){return o}});var n=r(7653),a=r(39161),i=r(66835),l=r(81279);function o(e){return(0,n.useMemo)(()=>{let{frame:t,layoutId:r,formatId:n,matType:o,glass:u,hardware:c,brassPlaqueEnabled:s}=e;if(!r)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,slabModifier:0,subtotal:0,total:0};let d=(0,l.Tl)(r);if(!(0,i.E8)(n))return console.warn("Comic format not found: ".concat(n)),{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,slabModifier:0,subtotal:0,total:0};let f=0;if((null==t?void 0:t.id)&&(null==t?void 0:t.sku)){let e=(0,i.Bc)(n),o=l.i0[r];if(o){let r=e?o.gr:o.ng,n={serviceType:"frame-only",artworkWidth:r.width,artworkHeight:r.height,frameStyleId:t.id,matType:"none",matBorderWidth:0,matRevealWidth:0,matColorId:"",glassTypeId:(null==u?void 0:u.id)||"standard"};try{f=(0,a.a4)(n).framePrice}catch(e){console.warn("Pricing calculation failed, using fallback:",e),f=120}}}let h=0;"none"!==o&&d.count>1&&(h=(d.count-1)*15);let m=0;(0,i.Bc)(n)&&(m=25);let g=0;"security"===c&&(g=8.95);let w=0;s&&(w=29);let v=f+h+m+0+g+w;return{framePrice:f,matPrice:h,glassPrice:0,hardwarePrice:g,nameplatePrice:w,slabModifier:m,subtotal:v,total:v}},[e,e.formatId,e.matType,e.glass,e.hardware,e.brassPlaqueEnabled])}},80397:function(e,t,r){"use strict";r.d(t,{Jr:function(){return a},Z_:function(){return u},Zf:function(){return i},mf:function(){return o},nF:function(){return l}});var n=r(7653);function a(e){let{fields:t,enabled:r=!0}=e,a=(0,n.useRef)(t);a.current=t;let i=(0,n.useRef)(!1),l=(0,n.useRef)({}),o=(0,n.useRef)(!1),u=t.map(e=>{try{return e.serialize?e.serialize(e.value):String(e.value)}catch(e){return""}}).join("|");(0,n.useEffect)(()=>{if(!r)return;let e=window.setTimeout(()=>{let e=window.location.search,t=function(e,t){let r=new URLSearchParams(t);for(let t of e){var n;for(let e of(r.delete(t.key),null!==(n=t.legacyKeys)&&void 0!==n?n:[]))r.delete(e)}for(let t of e){if(t.isDefault(t.value))continue;let e=t.serialize?t.serialize(t.value):String(t.value);null!=e&&""!==e&&r.set(t.key,e)}let a=r.toString();return a?"?".concat(a):""}(a.current,e),r=[],n={};for(let e of a.current){let t=e.isDefault(e.value)?null:e.serialize?e.serialize(e.value):String(e.value);n[e.key]=t,l.current[e.key]!==t&&r.push(e)}if(e===t){l.current=n;return}let u="".concat(window.location.pathname).concat(t).concat(window.location.hash);o.current=!0;try{i.current?r.length>0&&r.every(e=>e.replaceOnChange)?window.history.replaceState({},"",u):window.history.pushState({},"",u):(window.history.replaceState({},"",u),i.current=!0),l.current=n}finally{window.setTimeout(()=>{o.current=!1},0)}},300);return()=>window.clearTimeout(e)},[u,r]),(0,n.useEffect)(()=>
1{if(!r)return;let e=()=>{if(o.current)return;let e=new URLSearchParams(window.location.search);for(let t of a.current){let r=function(e,t){var r;for(let n of[e.key,...null!==(r=e.legacyKeys)&&void 0!==r?r:[]]){let r=t.get(n);if(null===r)continue;let a=e.parse?e.parse(r):r;if(void 0!==a)return{present:!0,value:a}}return{present:!1}}(t,e);r.present?t.set(r.value):t.isDefault(t.value)||t.set(t.defaultValue)}};return window.addEventListener("popstate",e),()=>window.removeEventListener("popstate",e)},[r])}function i(e){return{key:e.key,legacyKeys:e.legacyKeys,value:e.value,set:e.set,defaultValue:e.defaultValue,isDefault:t=>t===e.defaultValue,serialize:e=>e,parse:t=>e.allowed.includes(t)?t:void 0}}function l(e){return{key:e.key,legacyKeys:e.legacyKeys,value:e.value,set:e.set,defaultValue:e.defaultValue,isDefault:t=>t===e.defaultValue,serialize:e=>e,parse:t=>e.validate(t)?t:void 0}}function o(e){return{key:e.key,legacyKeys:e.legacyKeys,value:e.value,set:e.set,defaultValue:e.defaultValue,isDefault:t=>t===e.defaultValue,serialize:e=>e,parse:t=>{let r=parseFloat(t);if(Number.isFinite(r)&&(void 0===e.min||!(r<e.min))&&(void 0===e.max||!(r>e.max)))return t},replaceOnChange:e.replaceOnChange}}function u(e){return{key:e.key,legacyKeys:e.legacyKeys,value:e.value,set:e.set,defaultValue:e.defaultValue,isDefault:t=>t===e.defaultValue,serialize:e=>String(e),parse:t=>{let r=parseInt(t,10);if(Number.isFinite(r)&&(void 0===e.min||!(r<e.min))&&(void 0===e.max||!(r>e.max)))return r}}}},50365:function(e,t,r){"use strict";r.d(t,{o:function(){return a}});var n=r(7653);function a(e){let{frameWidth:t,frameHeight:r,plaqueEnabled:a=!1,plaqueExtension:i=1.5,isMobile:l,minHeightMobile:o=320,minHeightDesktop:u=420,maxHeightDesktop:c=900,maxHeightMobile:s=620,containerPadding:d={mobile:32,desktop:64}}
1=e,f=(0,n.useRef)(null),[h,m]=(0,n.useState)(400);return(0,n.useEffect)(()=>{let e;if(!f.current)return;let t=new ResizeObserver(t=>{clearTimeout(e),e=setTimeout(()=>{for(let e of t){let t=Math.round(e.contentRect.width);m(e=>Math.abs(t-e)>2?t:e)}},16)});return t.observe(f.current),()=>{clearTimeout(e),t.disconnect()}},[]),{containerRef:f,previewContainerHeight:(0,n.useMemo)(()=>{let e=(a?r+i:r)/t,n=h>0?h:400,f=l?d.mobile:d.desktop;return Math.min(Math.max((n-f)*e+f,l?o:u),l?s:c)},[t,r,a,i,h,l,o,u,c,s,d]),containerWidth:h}}},28940:function(e,t,r){"use strict";r.d(t,{H:function(){return a}});var n=r(7653);function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{threshold:.4},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],[a,i]=(0,n.useState)(!0);return(0,n.useEffect)(()=>{let r=e.current;if(!r)return;if("undefined"==typeof IntersectionObserver){i(!0);return}let n=new IntersectionObserver(e=>{let t=e[0];t&&i(t.isIntersecting)},t);return n.observe(r),()=>{n.disconnect()}},[t.threshold,t.root,t.rootMargin,...r]),a}},82889:function(e,t,r){"use strict";r.d(t,{h:function(){return u}});var n=r(55238),a=r(7653),i=r(39161),l=r(17855),o=r(21984);function u(e){return(0,a.useMemo)(()=>{var t;let{frame:r,layoutId:a,sizeId:u,matType:c,matBorder:s,glass:d,hardware:f,brassPlaqueEnabled:h,bottomWeighted:m=!1}=e;if(!a)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,subtotal:0,total:0};let g=(0,l.lY)(a);if(!(0,o.w6)(u)||!r)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,subtotal:0,total:0};let w=function(e,t){if(!e)return null;let r=(0,l.lY)(e),n=(0,o.w6)(t);if(!n)return null;let{rows:a,columns:i,spacingFactor:u}=r,c=n.width,s=n.height;return{width:c*i+c*u*(i-1),height:s*a+s*u*(a-1)}}(a,u);if(!w)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,subtotal:0,total:0};let v=0,y=null!==(t=null==d?void 0:d.id)&&void 0!==t?t:"standard",p={serviceType:"frame-only",artworkWidth:w.width,artworkHeight:w.height,frameStyleId:r.id,matType:c,matBorderWidth:"none"===c?.25:s,matRevealWidth:.25,matColorId:"mat-1",glassTypeId:y,bottomWeighted:m};try{let e=(0,i.a4)(p);v=e.framePrice+e.matPrice+e.glassPrice}catch(e){v=120}let b=0;"none"!==c&&g.count>1&&(b=(g.count-1)*15);let k=0;"security"===f&&(k=8.95);let P=0;h&&"none"!==c&&(P=n.af.PRICE);let S=v+b+k+P;return{framePrice:v,matPrice:b,glassPrice:0,hardwarePrice:k,nameplatePrice:P,subtotal:S,total:S}},[e])}},9012:function(e,t,r){"use strict";r.d(t,{F:function(){return a}});var n=r(7653);function a(e){let{isMobile:t,headerHeight:r=56,previewTopGap:a=12,controlsTopGap:i=16}=e,[l,o]=(0,n.useState)("preview"),u=(0,n.useRef)("preview"),[c,s]=(0,n.useState)(!0),d=(0,n.useRef)(0),[f,h]=(0,n.useState)(!1),m=(0,n.useRef)(null),g=(0,n.useRef)(null),w=(0,n.useRef)(null),v=(0,n.useRef)(!1);(0,n.useEffect)(()=>{let e;if(!t)return;let r=()=>{clearTimeout(e),e=setTimeout(()=>{h(!0)},50)};return window.addEventListener("scroll",r,{passive:!0}),()=>{window.removeEventListener("scroll",r),clearTimeout(e)}},[t]);let y=(0,n.useCallback)(e=>{if(!t){o(e);return}null!==w.current&&(cancelAnimationFrame(w.current),w.current=null);let r=u.current;r!==e&&("controls"!==r||"preview"!==e||v.current||(d.current=window.scrollY),o(e))},[t]);return(0,n.useEffect)(()=>{if(t&&u.current!==l)return null!==w.current&&cancelAnimationFrame(w.current),w.current=requestAnimationFrame(()=>{if(v.current=!0,"controls"===l){if(c){if(s(!1),g.current){let e=g.current.getBoundingClientRect().top+window.scrollY;window.scrollTo({top:e-r-i,behavior:"smooth"})}}else window.scrollTo({top:d.current,behavior:"smooth"})}else if(m.current){let e=m.current.getBoundingClientRect().top+window.scrollY;window.scrollTo({top:e-r-a,behavior:"smooth"})}u.current=l,w.current=null,setTimeout(()=>{v.current=!1},350)}),()=>{null!==w.current&&cancelAnimationFrame(w.current)}},[l,t,c,r,a,i]),{mobileView:l,setMobileView:y,showMobileBar:f,previewCardRef:m,controlsHeadingRef:g}}},34192:function(e,t,r){"use strict";r(19307),r(7653),r(14007)},9338:function(e,t,r){"use strict";r.d(t,{t:function(){return l}});var n=r(7653),a=r(39161),i=r(83596);function l(e){return(0,n.useMemo)(()=>{let{frame:t,layoutId:r,matType:n,glass:l,hardware:o,brassPlaqueEnabled:u}=e,c=i.Xy.find(e=>e.id===r);if(!c||!t)return{framePrice:0,matPrice:0,glassPrice:0,hardwarePrice:0,nameplatePrice:0,subtotal:0,total:0};let s=t.mouldingWidth||i.Lr,d=c.frameWidth-2*s,f=c.frameHeight-2*s,h=0,m=0,g=0;try{let e={serviceType:"frame-only",artworkWidth:d,artworkHeight:f,frameStyleId:t.id,matType:n,matBorderWidth:"none"!==n?i.zV:0,matRevealWidth:"double"===n?.25:0,matColorId:"mat-1",matInnerColorId:"double"===n?"mat-2":void 0,glassTypeId:(null==l?void 0:l.id)||"standard",bottomWeighted:!1},r=(0,a.a4)(e);h=r.framePrice,m=r.matPrice,g=r.glassPrice}catch(e){console.warn("Playbill pricing calculation failed, using fallback:",e),h=2*(c.frameWidth+c.frameHeight)*(t.pricePerInch||2)}let w=0;"security"===o&&(w=8.95);let v=0;u&&"none"!==n&&(v=29);let y=h+m+g+w+v;return{framePrice:h,matPrice:m,glassPrice:g,hardwarePrice:w,nameplatePrice:v,subtotal:y,total:y}},[e])}},14007:function(e,t,r){"use strict";r(19307),r(7653)},95579:function(e,t,r){"use strict";r.d(t,{H:function(){return i}});var n=r(7653);function a(){if("undefined"==typeof document)return 96;let e=document.querySelector('[data-sticky-chrome="true"]');if(e)return e.getBoundingClientRect().height;let t=document.querySelector('header[role="banner"]');if(!t)return 0;let r=window.getComputedStyle(t).position;return"sticky"!==r&&"fixed"!==r?0:t.getBoundingClientRect().height}
1function i(){let[e,t]=(0,n.useState)(()=>a());return(0,n.useEffect)(()=>{let e=()=>t(e=>e===a()?e:a());e(),window.addEventListener("resize",e,{passive:!0});let r=null;if("undefined"!=typeof ResizeObserver){var n;r=new ResizeObserver(e);let t=null!==(n=document.querySelector('[data-sticky-chrome="true"]'))&&void 0!==n?n:document.querySelector('header[role="banner"]');t&&r.observe(t)}return()=>{window.removeEventListener("resize",e),null==r||r.disconnect()}},[]),e}},97898:function(e,t,r){"use strict";r.d(t,{B2:function(){return o},lj:function(){return c},wd:function(){return u}});var n=r(74745),a=r(96407),i=r(67950),l=r(23880);function o(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e.map((e,n)=>{var o,u;let c=e.configuration,s=c?(0,l.jE)(c.frameStyleId):void 0,d=function(e){var t,r,n;let a=null!==(n=null!==(r=e.imageUrl)&&void 0!==r?r:null===(t=e.configuration)||void 0===t?void 0:t.imageUrl)&&void 0!==n?n:null;return a&&a.trim()?a.trim():null}(e),f=null!==(u=null===(o=r.reviewIdFor)||void 0===o?void 0:o.call(r,e))&&void 0!==u?u:void 0,{widthIn:h,heightIn:m}=(0,i.Ho)(c),g=(null==c?void 0:c.cardFormatId)&&c.cardLayoutId?(0,a.S_)(c.cardFormatId,c.cardLayoutId):void 0;return{merchandiseId:t,quantity:e.quantity,priceCents:e.price||0,configuration:c,packing:c?{frameDisplayName:null==s?void 0:s.name,frameSku:null==s?void 0:s.sku,frameCategory:null==s?void 0:s.category,matOuterLabel:(0,i.Sx)(c.matColorId,h,m),matInnerLabel:(0,i.Sx)(c.matInnerColorId,h,m),lineIndex:n+1,cardProductionCode:g,cardInteriorWidthIn:c.cardInteriorWidthIn,cardInteriorHeightIn:c.cardInteriorHeightIn,...d?{previewImageUrl:d}:{},...f?{reviewId:f}:{}}:void 0}})}function u(){if("undefined"!=typeof document)for(let t of document.cookie.split(";")){var e;let r=null===(e=t.split("=")[0])||void 0===e?void 0:e.trim();r&&(r.includes("shopify")||r.includes("cart")||r.includes("checkout"))&&(document.cookie="".concat(r,"=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/"))}}async function c(e,t,r){let a=(0,n.dY)(),i=await fetch("".concat(r,"/api/cart/fresh-checkout"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({lines:e,...t?{branding:t}:{},...a?{attribution:a}:{}}),credentials:"include"});return await i.json()}},54428:function(e,t,r){"use strict";r.d(t,{xw:function(){return n.xw}}),r(23880),r(39161),r(34092),r(55238),r(10735),r(34184),r(97898),r(95503),r(74859);var n=r(76319);r(76367)},17182:function(e,t,r){"use strict";r.d(t,{nG:function(){return n.nG},xS:function(){return n.xS}});var n=r(48170)},73657:function(e,t,r){"use strict";r.d(t,{GN:function(){return s},Re:function(){return c},Xl:function(){return n.X}});var n=r(90019),a=r(65436);function i(e){return new Promise((t,r)=>{let n=new Image;n.crossOrigin="anonymous",n.onload=()=>t(n),n.onerror=()=>r(Error("Failed to load: ".concat(e))),n.src=e})}async function l(e,t,r,l){let o=(0,a.O5)(t,r,l);if(!o.backgroundImage||"none"===o.backgroundImage)return null;let u=o.backgroundImage.match(/url\(['"]?([^'"]+)['"]?\)/);if(!u||!u[1])return null;try{let t=u[1],r=await (0,n.X)(t),a=await i(r);return e.createPattern(a,"repeat")}catch(e){return console.warn("Failed to load mat texture:",e),null}}async function o(e,t,r,a,l,o,u,c){try{let s=await (0,n.X)(t),d=await i(s);e.save(),e.beginPath();let f=r[0];if(!f)return;e.moveTo(f[0],f[1]);for(let t=1;t<r.length;t++){let n=r[t];n&&e.lineTo(n[0],n[1])}if(e.closePath(),e.clip(),"x"===c){let t=d.width/d.height*u;for(let r=a;r<a+o;r+=t)e.drawImage(d,r,l,t,u)}else{let t=d.height/d.width*o;for(let r=l;r<l+u;r+=t)e.drawImage(d,a,r,o,t)}e.restore()}catch(e){console.warn("Failed to draw frame piece:",e)}}function u(e,t,r,n,a,i,l){e.save(),e.strokeStyle=l,e.lineWidth=i,e.strokeRect(t+i/2,r+i/2,n-i,a-i),e.restore()}async function c(e){let t,r,c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2e3,{framePhotos:s,frameFacePx:d,outerWidth:f,outerHeight:h,matPx:m,openingWidth:g,openingHeight:w,matType:v,matColor:y,matName:p,matInnerColor:b,matInnerName:k,matRevealWidth:P=.25,scale:S,artworkUrl:I}=e,F=f/h;f>h?r=(t=Math.max(c,f))/F:t=(r=Math.max(c,h))*F;let R=t/f,C=Math.round(12*R),E=t+2*C,T=r+2*C,M=document.createElement("canvas");M.width=E,M.height=T;let W=M.getContext("2d",{alpha:!1});if(!W)throw Error("Failed to get canvas context");W.fillStyle="#FFFFFF",W.fillRect(0,0,E,T),W.save(),W.shadowColor="rgba(0, 0, 0, 0.15)",W.shadowBlur=Math.round(8*R),W.shadowOffsetX=0,W.shadowOffsetY=Math.round(4*R),W.fillStyle="#FFFFFF",W.fillRect(C,C,t,r),W.restore(
1);let B=d*R,x=m*R,L=g*R,O=w*R,H=P*S*R,z=Math.max(1.5,.0625*S)*R,U=C+B,j=C+B,N=t-2*B,D=r-2*B,V=await l(W,p,S*R,y);if(V?W.fillStyle=V:W.fillStyle=y,W.fillRect(U,j,N,D),"double"===v&&b&&k){W.save(),W.shadowColor="rgba(0,0,0,0.3)",W.shadowBlur=20*R,W.shadowOffsetX=0,W.shadowOffsetY=0,W.fillRect(U,j,N,D),W.restore();let e=U+x,t=j+x,r=await l(W,k||"White",S*R,b||"#FFFFFF");r?W.fillStyle=r:W.fillStyle=b||"#FFFFFF",W.fillRect(e,t,L,O),W.strokeStyle="#F5F5F0",W.lineWidth=Math.max(1.5,.06*S)*R,W.strokeRect(e,t,L,O),W.save(),W.shadowColor="rgba(0,0,0,0.06)",W.shadowBlur=2*R,W.shadowOffsetY=1*R,W.fillRect(e,t,L,O),W.restore();let o=e+H,c=t+H,s=L-2*H,d=O-2*H;W.fillStyle="white",W.fillRect(o,c,s,d),u(W,o,c,s,d,z,(0,a.fs)(k||"White"));try{let e=await (0,n.X)(I),t=await i(e),r=o+z,a=c+z,l=s-2*z,u=d-2*z;W.drawImage(t,r,a,l,u)}catch(e){console.warn("Failed to load artwork:",e)}}else if("single"===v){W.save(),W.shadowColor="rgba(0,0,0,0.3)",W.shadowBlur=20*R,W.fillRect(U,j,N,D),W.restore();let e=U+x,t=j+x;W.fillStyle="white",W.fillRect(e,t,L,O),u(W,e,t,L,O,z,(0,a.fs)(p));try{let r=await (0,n.X)(I),a=await i(r),l=e+z,o=t+z,u=L-2*z,c=O-2*z;W.drawImage(a,l,o,u,c)}catch(e){console.warn("Failed to load artwork:",e)}}else try{let e=await (0,n.X)(I),t=await i(e);W.drawImage(t,U,j,N,D)}catch(e){console.warn("Failed to load artwork:",e)}return(null==s?void 0:s.topUrl)&&(null==s?void 0:s.bottomUrl)&&(null==s?void 0:s.leftUrl)&&(null==s?void 0:s.rightUrl)&&(await o(W,s.topUrl,[[C,C],[C+t,C],[C+t-B,C+B],[C+B,C+B]],C,C,t,B,"x"),await o(W,s.bottomUrl,[[C+B,C+r-B],[C+t-B,C+r-B],[C+t,C+r],[C,C+r]],C,C+r-B,t,B,"x"),await o(W,s.leftUrl,[[C,C],[C+B,C+B],[C+B,C+r-B],[C,C+r]],C,C,B,r,"y"),await o(W,s.rightUrl,[[C+t-B,C+B],[C+t,C],[C+t,C+r],[C+t-B,C+r-B]],C+t-B,C,B,r,"y")),M.toDataURL("image/png")}function s(e,t){if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){let t=window.open();
1t&&t.document.write('<img src="'.concat(e,'" style="width:100%;height:auto;" />'))}else{let r=document.createElement("a");r.download=t,r.href=e,r.click()}}},90019:function(e,t,r){"use strict";async function n(e){if(e.startsWith("data:"))return e;if(e.startsWith("blob:")){let t=await fetch(e),r=await t.blob();return await new Promise((e,t)=>{let n=new FileReader;n.onloadend=()=>{let r=n.result;"string"==typeof r?e(r):t(Error("Failed to convert blob to data URL"))},n.onerror=()=>t(Error("Failed to read blob")),n.readAsDataURL(r)})}let t=e.startsWith("http")?e:new URL(e,window.location.origin).href,r=await fetch("/api/proxy-image",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:t})});if(!r.ok)throw Error((await r.json().catch(()=>({error:"Proxy failed"}))).error||"HTTP ".concat(r.status));let n=await r.json();if(!n.dataUrl)throw Error("No dataUrl in response");return n.dataUrl}r.d(t,{X:function(){return n}})},4637:function(e,t,r){"use strict";r.d(t,{W:function(){return i}});var n=r(10275),a=r(74859);async function i(e){var t;let r=null!==(t=e.split("?")[0])&&void 0!==t?t:e;if(function(e){var t;if(!e)return!1;let r=void 0!==a?"https://orders.customframesizes.com":void 0;if(!r)return!1;let n=r.replace(/\/$/,"");return(null!==(t=e.split("?")[0])&&void 0!==t?t:e).startsWith(n)}(r))return r;let i=await (0,n.Nv)("POST","/api/objects/upload-from-url",{sourceUrl:r}),l=await i.json();if(!l.objectPath)throw Error(l.error||"No objectPath from upload-from-url");return l.objectPath}},22246:function(e,t,r){"use strict";r.d(t,{B4:function(){return a},Xm:function(){return i}}),r(39161);let n=new Set(["widthIn","heightIn","depthIn","mouldingId","matLayers","background","glazing","hangingHardware","jerseyMount","accessories"]);function a(e){var t,r,a,i,l,o;let u=0===e.matLayers.length?"none":1===e.matLayers.length?"single":"double",c=(null===(r=e.matLayers[0])||void 0===r?void 0:null===(t=r.thicknessIn)||void 0===t?void 0:t.toString())||"2.5",s=(null===(i=e.matLayers[1])||void 0===i?void 0:null===(a=i.thicknessIn)||void 0===a?void 0:a.toString())||"0.25",d=null===(l=e.matLayers[0])||void 0===l?void 0:l.color,f=null===(o=e.matLayers[1])||void 0===o?void 0:o.color,h="acrylic-AR"===e.glazing?"acrylic-ar":"glass-AR"===e.glazing?"uv-glass":"acrylic"===e.glazing?"acrylic":"glass"===e.glazing?"standard":"none"===e.glazing?"none":"acrylic-ar",m="plywood"===e.background.material?"plywood":"suede"===e.background.material?"suede":"linen"===e.background.material?"linen":"mat-color"===e.background.material?e.background.color:"none",g=e.background.color,w={};for(let t in e)n.has(t)||(w[t]=e[t]);return{artworkWidth:e.widthIn.toString(),artworkHeight:e.heightIn.toString(),matType:u,matBorderWidth:c,matRevealWidth:s,frameId:e.mouldingId||"oak-classic",glassId:h,backing:m,backingColor:g,matColorId:d,matInnerColorId:f,rawMatColor:d,rawMatInnerColor:f,depth:e.depthIn,hangingHardware:e.hangingHardware,jerseyMount:e.jerseyMount,accessories:e.accessories,unknownFields:Object.keys(w).length>0?w:void 0}}function i(e){let t;let r=[];"single"===e.matType?r.push({color:e.rawMatColor||e.selectedMat.color,thicknessIn:parseFloat(e.matBorderWidth)||2.5}):"double"===e.matType&&(r.push({color:e.rawMatColor||e.selectedMat.color,thicknessIn:parseFloat(e.matBorderWidth)||2.5}),r.push({color:e.rawMatInnerColor||e.selectedMatInner.color,thicknessIn:parseFloat(e.matRevealWidth)||.25}));let n="plywood"===e.selectedBacking?"plywood":"suede"===e.selectedBacking?"suede":"linen"===e.selectedBacking?"linen":"none"===e.selectedBacking?"paper":"mat-color";if(e.selectedBackingColor)t=e.selectedBackingColor;else if("plywood"===e.selectedBacking)t="#D4A574";else if("suede"===e.selectedBacking)t="#8B7355";else if("linen"===e.selectedBacking)t="#E8E4D9";else if("none"===e.selectedBacking)t="#F5F5F0";else if(e.matPalette){let r=e.matPalette.find(t=>t.id===e.selectedBacking);t=(null==r?void 0:r.color)||"#F5F5F0"}else t="#F5F5F0";let a="acrylic-ar"===e.selectedGlass.id?"acrylic-AR":"uv-glass"===e.selectedGlass.id?"glass-AR":"acrylic"===e.selectedGlass.id?"acrylic":"standard"===e.selectedGlass.id?"glass":"none"===e.selectedGlass.id?"none":"backing-only"===e.selectedGlass.id?"backing-only":"acrylic-AR",i={widthIn:parseFloat(e.artworkWidth)||16,heightIn:parseFloat(e.artworkHeight)||20,depthIn:e.depth||1.25,mouldingId:e.selectedFrame.id,matLayers:r,background:{material:n,color:t},glazing:a};if(e.hangingHardware&&(i.hangingHardware=e.hangingHardware),e.jerseyMount&&(i.jerseyMount=e.jerseyMount),e.accessories&&(i.accessories=e.accessories),e.unknownFields)for(let t in e.unknownFields)i[t]=e.unknownFields[t];return i}},63368:function(e,t,r){"use strict";r.d(t,{S_:function(){return n.S_}}),r(54428),r(39161),r(23880),r(22246),r(76367),r(13172),r(10275);var n=r(31446);r(73657),r(72810),r(4637),r(76755),r(67950),r(750),r(12688),r(9012),r(28940),r(39605),r(67930),r(50365),r(14007),r(34192),r(61024),r(82889),r(9338),r(70117),r(7653),r(86902),r(43471),r(68889),r(23084),r(56789),r(26484),r(84216),r(52764),r(17987),r(7773),r(67393),r(40013),r(70979),r(43665),r(95579),r(81202),r(31266),r(80397),r(11524),r(17182),r(16328),r(27573),r(20661),r(71752),r(95971),r(40343),r(74859)}}]);

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