1import{u as e,S as n,w as t,X as r,x as o}from"./2c1ab0fe.Bf8FS-kA.js";import{bm as s,k as c,o as i,p as a,U as l,q as u,u as d,bn as h,f as p,S as f,H as m,b as y,bo as g,i as b,bp as w,bq as k,ah as R}from"./164ad2e3.D0nOfU9-.js";import{c as v,ag as E}from"./4b4bc88f.DcJe9bVW.js";import"./d0bb51ec.CL_3Kdjr.js";import"./app.C_ntWzAC.js";import"./f67abd2c.CMIDVCe_.js";import"./60a453ce.0K3_0kXS.js";import"./e12db40c.B4InVJ1F.js";import"./9dba8418.CZTcH8_l.js";class j extends Error{constructor(){super(...arguments),this.name="UnknownNodeTypeError"}}function M({nodes:t,registry:r}){return e(n,{children:t.map(n=>e(S,{node:n,registry:r},n.key))})}function S({node:n,registry:t}){const r=function(e,n){const t=e.get(n);if(!t)throw new j(`Unknown node type: ${function(e){const n=e.replace(/[^\w:.-]/g,"");return n.length>64?`${n.slice(0,64)}â¦`:n}(n)}. The registry has no component for it.`);return t}(t,n.type),{children:o,slots:s}=function(n,t){if(!n||0===n.length)return{};const r=[];let o;for(const s of n){const n=e(S,{node:s,registry:t},s.key);if(void 0===s.slot){r.push(n);continue}o??=new Map;const c=o.get(s.slot);c?c.push(n):o.set(s.slot,[n])}return{children:r.length>0?r:void 0,slots:o?Object.fromEntries(o):void 0}}(n.children,t);return e(r,{node:n,slots:s,children:o})}class U extends Error{constructor(){super(...arguments),this.name="UnplaceableSlotError"}}class _ extends Error{constructor(){super(...arguments),this.name="UnknownExtensionPlacementError"}}function x(e){const n=String(e).replace(/[^\w:.-]/g,"");return n.length>64?`${n.slice(0,64)}â¦`:n}function C(e,{children:n,slots:t,accepts:r,acceptsChildren:o}){const s=x(e.type);if(!o&&void 0!==n)throw new U(`"${s}" cannot place unslotted children`);const c=Object.keys(t??{}).filter(e=>!r.includes(e));if(c.length>0)throw new U(`"${s}" cannot place occupants of: ${function(e){const n=e.slice(0,8).map(x);return e.length>8&&n.push("â¦"),n.join(", ")}(c)}`)}const D=[];function O({node:n,children:t,slots:r}){C(n,{children:t,slots:r,accepts:D,acceptsChildren:!0});const o=function(e){return"order-summary"===e.type&&"disclosure"===e.slot?"disclosure":"in-place"}(n);return void 0===n.children?e(s,{monorailSection:A(o)}):e($.Provider,{value:o,children:e(Y,{children:t})})}const $=r("in-place");function A(e){return"disclosure"===e?"top_order_summary":"order_summary"}function Y({children:n}){const{ready:r}=u("chat"),{i18n:o,checkout:s,checkout:{configuration:{allowEmptyCart:c,layout:i}}}=v(),a=i.isOnePage.value,l=d(),w=s.proposal.facts.merchandiseLines??[];if(a&&!c){const n=[];for(const e of l.value.values())n.push(...e);if(n.push(...w),h(n))return e(p,{textAlign:"center",children:o.translate("stock.empty_cart_label")})}return e(b,{containerName:"s-shell-section",children:[e(f,{gap:"large-200",children:[e(m,{visibility:"hidden",children:o.translate("order_summary.title")}),n]}),e(t,{when:r,children:e(y,{minBlockSize:`@media (inline-size >= medium) ${g}px, 0`})})]})}const z=n=>e(b,{children:n}),P=["before","after"];function T(t){return function({node:r,children:o,slots:s}){return C(r,{children:o,slots:s,accepts:P,acceptsChildren:!1}),e(n,{children:[s?.before,e(t,{node:r}),s?.after]})}}const q=new Map([["aside",O],["order-summary",O],["line-items",T(function(n){return e(k,{})})],["money-lines",T(function(n){return e(R,{})})],["reductions",T(function(n){const{checkout:{configuration:{visibility:t}}}=v(),r=o($);return t.showReductions?e(w,{monorailSection:A(r)}):null})],["ui-extension-point",function({node:n,children:t,slots:r}){C(n,{children:t,slots:r,accepts:D,acceptsChildren:!1});const o=function(e){const n=e.attrs?.placement;if("ORDER_SUMMARY3"===n||"ORDER_SUMMARY4"===n)return n;throw new _(`Unknown extension point placement: ${x(n)}`)}(n),{checkout:{configuration:{layout:s}}}=v(),u=s.isOnePage.value,{currentDetour:d}=c().value,h="thankYou"===d?.type,p=i(h?"Checkout::ThankYou::Dynamic::Render":"Checkout::Dynamic::Render","ORDER_SUMMARY3"),f=i("Checkout::Dynamic::Render","ORDER_SUMMARY4"),m=a({base:!0,medium:!1}),y=E(),g=u&&(!y.value||m);return"ORDER_SUMMARY3"===o?h?null:e(l,{customizations:p,gap:"large-200",render:z}):g&&!h?null:e(l,{customizations:h?p:f,gap:"large-200",render:z})}]]);function B({root:n}){return e(M,{nodes:[n],registry:q})}export{B as default};
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.