Files
kaiser-natron/dist/assets/checkout-stUpOmaV.js
Dorian c600fadadb stepped checkout, auth pages, sticky stepper bar, action footer
- 4-step checkout (cart, account, shipping, payment) with Pinia store and route children
- minimal cream sticky top bar (logo + stepper + back-to-shopping) replacing nav/footer in checkout
- fixed cream action footer at viewport bottom for back/continue on every step
- guest / sign-in / register tabs on account step + standalone /login and /register
- src/api/auth.js stub matching expected backend contract
- legal pages (/impressum, /datenschutz) and category landings (/pflege, /haushalt)
- success page stacked CTAs (back-to-home primary, keep-shopping secondary)
- footer logo size aligned with navbar; cream variant footer

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-03 16:06:26 +01:00

1 line
1.5 KiB
JavaScript

import{n as e}from"./pinia-D94NEbtV.js";var t=`kn-checkout-v1`,n=[`guest`,`signin`,`register`];function r(){return{name:``,company:``,street:``,postalCode:``,city:``,country:`AT`,phone:``}}function i(){return{accountMode:`guest`,email:``,acceptsMarketing:!1,password:``,passwordConfirm:``,firstName:``,lastName:``,billingSame:!0,shippingAddress:r(),billingAddress:r()}}function a(){if(typeof sessionStorage>`u`)return i();try{let e=sessionStorage.getItem(t);if(!e)return i();let n=JSON.parse(e);return{...i(),...n}}catch{return i()}}function o(e){if(!(typeof sessionStorage>`u`))try{let{password:n,passwordConfirm:r,...i}=e;sessionStorage.setItem(t,JSON.stringify(i))}catch{}}function s(e){return e?[`name`,`street`,`postalCode`,`city`,`country`].every(t=>String(e[t]||``).trim().length>0):!1}var c=e(`checkout`,{state:()=>a(),getters:{accountComplete(e){return!e.email||!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e.email.trim())?!1:e.accountMode===`signin`?e.password.length>=8:e.accountMode===`register`?e.password.length>=8&&e.password===e.passwordConfirm:!0},shippingComplete(e){return s(e.shippingAddress)?e.billingSame?!0:s(e.billingAddress):!1}},actions:{setAccountMode(e){n.includes(e)&&(this.accountMode=e,this.persist())},update(e){Object.assign(this,e),this.persist()},updateShipping(e){this.shippingAddress={...this.shippingAddress,...e},this.persist()},updateBilling(e){this.billingAddress={...this.billingAddress,...e},this.persist()},persist(){o(this.$state)},reset(){Object.assign(this,i()),typeof sessionStorage<`u`&&sessionStorage.removeItem(t)}}});export{c as t};