PageSourceSearch

https://www.toolstation.nl/_nuxt/asset/6.0.10/save-list-code-BFYstWwg.js

js toolstation.nl collected 2026-09-26 04:00:39 UTC 6,973 bytes, 3 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../../carouselThumbnail.DHXAGmwn.css","../../entry.IC0nXJmS.css"])))=>i.map(i=>d[i]);
2var y=(I,P,_)=>new Promise((L,C)=>{var D=c=>{try{v(_.next(c))}catch(f){C(f)}},V=c=>{try{v(_.throw(c))}catch(f){C(f)}},v=c=>c.done?L(c.value):Promise.resolve(c.value).then(D,V);v((_=_.apply(I,P)).next())});import{A as de,g as ue,B as me,q as pe,r as _e,e as fe,C as j,a3 as ve,c as u,U as H,V as he}from"./carouselThumbnail-BVGIAQ2F.js";import{c as ye,b as ge,_ as Te}from"./entry-COcyHNV4.js";import{_ as ke}from"./TsCardOutOfStock-CBZZzBco.js";import{_ as Se}from"./TsVatToggle-BGCRqKR-.js";import{_ as Ce}from"./TsForm-BFZFcGID.js";import{l as be,b as E,m as g,G as xe,O as T,a0 as J,J as o,Q as k,u as a,S as l,P as i,a7 as m,ab as A,R as S,I as Ee,a6 as Ae,y as Pe,_ as Le,X}from"./carousel-BVOjnoof.js";import"./TsCardRoundedV1-9qCSFB4w.js";import"./TsTableColumn-_BitrsCO.js";import"./TsNoSavelistFound-Cf6WStgN.js";import"./TsCarouselTopBrands-CNwKM0SZ.js";import"./TsButtonGroup-DHxkNh7i.js";import"./TsModalSubscriptionConfirmation-B9B3Kq-s.js";const De={class:"max-sm:px-4 flex-none lg:flex"},Ve={key:0,class:"mb-3"},Re={key:1},Ie={key:1},je=be({__name:"save-list-code",setup(I){const P=m(()=>u(()=>import("./TsVatToggle-BGCRqKR-.js").then(e=>e.m),__vite__mapDeps([0,1]),import.meta.url)),_=m(()=>u(()=>import("./TsCardExplore-RyXk8Fg5.js").then(e=>e.T),__vite__mapDeps([0,1]),import.meta.url)),L=m(()=>u(()=>import("./TsChip-CcqmxPgV.js").then(e=>e.d),__vite__mapDeps([0,1]),import.meta.url)),C=m(()=>u(()=>import("./TsModalOutOfStockSubscription-Bzv_Ce3E.js").then(e=>e.T),__vite__mapDeps([0,1]),import.meta.url)),D=m(()=>u(()=>import("./contact.datalayer-DADtvvBU.js").then(e=>e.a),__vite__mapDeps([0,1]),import.meta.url)),V=m(()=>u(()=>import("./TsNoResultFound-DwYSEG14.js").then(e=>e.T),__vite__mapDeps([0,1]),import.meta.url)),v=m(()=>u(()=>import("./TsModalSavelistMultipleItems-3CkGfmND.js"),__vite__mapDeps([0,1]),import.meta.url)),c=m(()=>u(()=>import("./entry-COcyHNV4.js").then(e=>e.ab),__vite__mapDeps([0,1]),import.meta.url)),f=de(),$=ue(),O=E(!0),b=E(!1),w=me(),d=E([]),s=E([]),K=pe();_e({title:"Toolstation | Save List Share",meta:[{name:"Save list share receiver end",content:"shared save list items"}]});function B(e){return parseFloat(e.replace("€","").replace(",",".").trim())}function N(e){let t=0;return e==null||e.forEach(n=>{const h=n.prices.formatted.gross,p=B(h);t+=p*(n.quantity||1)}),Math.round(t*100)/100}function z(e){let t=0;return e==null||e.forEach(n=>{const h=n.prices.formatted.net,p=B(h);t+=p*(n.quantity||1)}),Math.round(t*100)/100}function R(e){return"€ ".concat(e.toFixed(2).replace(".",","))}const M=g(()=>R(N(s.value))),W=g(()=>R(z(s.value))),Z=g(()=>{const e=N(s.value),t=z(s.value);return R(e-t)}),ee=g(()=>s.value.length===d.value.length);function te(e){e.target.checked?s.value=d.value:s.value=[]}function ae(){return y(this,null,function*(){const e=[];for(const t of s.value)try{yield $.addToTrolleyForDelivery(t.code,1),e.push(t.code)}catch(n){H("".concat(n),{autoClose:!0,type:"error"}),he("toast","".concat(n))}H("Product added successfully",{autoClose:!0,type:"success"}),yield j(f("/trolley")),e.length>0&&(d.value=d.value.filter(t=>!e.includes(t.code)),s.value=s.value.filter(t=>!e.includes(t.code)))})}function se(){return y(this,null,function*(){b.value=!0,yield ae(),b.value=!1})}function oe(){return y(this,null,function*(){if(!w.is_authenticated){yield j(f("/login"));return}const e=ve();e.modal_savelist_multiple_items_visible=!0,e.fetching_in_progress||e.getUserSaveLists(),e.selectedSavelist=[],e.populateSavedList()})}const q=g(()=>s.value.length>0);return xe(()=>y(this,null,function*(){const e=K.query.s||"SFQ1R0NVIzExNjY1LDg4OTQyLDk4MDEy",t=yield $.getDecodeTrolleyCodeQueryString(e);t&&(saveListId=t.trolleyCode,d.value=t.response),O.value=!1})),(e,t)=>{const n=ye,h=ke,p=Se,le=Te,x=ge,ne=Ce,re=Le,F=fe;return i(),T("div",null,[J("div",null,[a(O)?(i(),k(a(P),{key:0})):a(d).length?(i(),k(n,{key:2,"container-class":"max-sm:px-0 px-8"},{default:l(()=>[o(p,{"is-multiline":"",class:"items-start"},{default:l(()=>[o(x,{"append-class":"is-12 md:is-8"},{default:l(()=>[o(p,{class:"max-sm:px-4 p-2"},{default:l(()=>[o(h,{"append-class":"mb-0"},{default:l(()=>t[2]||(t[2]=[A("Save List Share ")])),_:1})]),_:1}),J("div",De,[o(x,null,{default:l(()=>[o(le,{variant:"sm",weight:"medium"},{default:l(()=>t[3]||(t[3]=[A(" Quicky Add Saved List Products to Your Trolley. ")])),_:1})]),_:1})]),o(a(_),{"append-class":"bg-[#f7fbfe]"},{default:l(()=>[o(p,{"append-class":"mb-2 -mt-2"},{default:l(()=>[o(x,{class:"text-nowrap"},{default:l(()=>[o(ne,{"append-class":"mt-2"},{default:l(()=>[o(a(L),{"data-testid":"save-list-receiver-select-all-checkbox",label:"Select All",checked:a(ee),onChange:te},null,8,["checked"])]),_:1})]),_:1})]),_:1}),a(d).length?(i(),T("div",Ve,[(i(!0),T(Ee,null,Ae(a(d),(r,ie)=>{var Q,U,G,Y;return i(),k(a(C),{key:r.code,check:a(s),"onUpdate:check":t[0]||(t[0]=ce=>Pe(s)?s.value=ce:null),"data-testid":"shared-save-item-"+ie,image:(Q=r.images)==null?void 0:Q.default,"full-name":r.full_name,"pack-size":r.pack_size,code:r.code,quantity:1,gross:(U=r.prices)==null?void 0:U.formatted.gross,net:(G=r.prices)==null?void 0:G.formatted.net,"per-unit":(Y=r.prices)==null?void 0:Y.formatted.per_unit,value:r},null,8,["check","data-testid","image","full-name","pack-size","code","gross","net","per-unit","value"])}),128))])):S("",!0)]),_:1})]),_:1}),o(x,{"append-class":"is-12 md:is-4 lg:mt-20 lg:pt-4 sticky top-[147px]"},{default:l(()=>[o(a(D),{"data-testid":"save-list-receiver-fixed-order-summary-card","total-products":a(s).length,"order-total":a(M),"sub-total":a(M),"total-vat":a(Z),"total-exc-vat":a(W)},null,8,["total-products","order-total","sub-total","total-vat","total-exc-vat"]),o(F,{"data-testid":"save-list-receiver-add-to-trolley-cta",size:"sm","append-class":"lg:py-2 lg:px-6 mt-2.5","is-loading":a(b),disabled:!a(q),block:"",onClick:se},{default:l(()=>[a(b)?(i(),k(re,{key:0,class:"animate-spin",name:"mingcute:loading-line"})):S("",!0),t[4]||(t[4]=A(" Add all products to trolley ")),a(s).length?(i(),T("span",Re,"("+X(a(s).length)+")",1)):S("",!0)]),_:1},8,["is-loading","disabled"]),o(F,{"data-testid":"save-list-receiver-add-to-save-list-cta",size:"sm","append-class":"lg:py-2 lg:px-6 mt-2.5",outlined:"",disabled:!a(q),block:"",onClick:t[1]||(t[1]=r=>oe())},{default:l(()=>[S("",!0),t[5]||(t[5]=A(" Add to savelist ")),a(s).length?(i(),T("span",Ie,"("+X(a(s).length)+")",1)):S("",!0)]),_:1},8,["disabled"])]),_:1})]),_:1})]),_:1})):(i(),k(n,{key:1,class:"my-16"},{default:l(()=>[o(a(c),{"data-testid":"save-list-receiver-empty","is-authenticated":a(w).is_authenticated},null,8,["is-authenticated"])]),_:1})),o(a(V),{model:"symbol",path:"/symbol/customer-support"})]),o(a(v),{"selected-save-list-items":a(s)},null,8,["selected-save-list-items"])])}}});
2export{je as default};
3//# sourceMappingURL=save-list-code-BFYstWwg.js.map

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.