refactor(ui): replace modal dialogs with toast/sheet components

Remove DialogVant/NotifyVant and add Toast and Sheet components with
useToast, useReveal, and usePageTransition composables. Rework
Navigation, RegisterView, and styles across both apps; rebuild dist assets.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
s.esmaeili
2026-10-04 13:57:25 +03:30
co-authored by Claude Sonnet 5
parent 148b99c4a6
commit c05352d6fd
205 changed files with 3362 additions and 1701 deletions
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
.ci[data-v-52807f97]{display:flex;gap:14px;padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.ci__art[data-v-52807f97]{flex:0 0 84px;width:84px;height:84px;display:flex;align-items:center;justify-content:center;border-radius:13px;overflow:hidden;background:#f4f5f6}.ci__art img[data-v-52807f97]{width:90px;height:90px;-o-object-fit:contain;object-fit:contain;-o-object-position:center;object-position:center;display:block}.ci__artEmpty[data-v-52807f97]{width:100%;height:100%;display:grid;place-items:center;color:#8a909c}.ci__main[data-v-52807f97]{flex:1;min-width:0}.ci__title[data-v-52807f97]{margin:0;font-size:13px;font-weight:700;color:#14161a;line-height:1.6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ci__meta[data-v-52807f97]{display:flex;align-items:center;gap:7px;padding-top:5px}.ci__weight[data-v-52807f97]{font-size:11.5px;font-weight:700;color:#22262e}.ci__wage[data-v-52807f97]{font-size:10.5px;color:#8a909c;padding-inline-start:7px;border-inline-start:1px solid #ECEDEF}.ci__row[data-v-52807f97]{display:flex;align-items:center;justify-content:space-between;gap:10px;padding-top:10px}.ci__qty[data-v-52807f97]{display:inline-flex;align-items:center;gap:4px;padding:3px;border-radius:999px;background:#f4f5f6;border:1px solid #ECEDEF}.ci__qtyBtn[data-v-52807f97]{width:27px;height:27px;border:0;cursor:pointer;border-radius:50%;display:grid;place-items:center;color:#22262e;background:#fff;transition:transform .15s ease,color .15s ease}.ci__qtyBtn--danger[data-v-52807f97]{color:#7a1b33}.ci__qtyBtn[data-v-52807f97]:active{transform:scale(.9)}.ci__qtyValue[data-v-52807f97]{min-width:22px;text-align:center;font-size:12.5px;font-weight:700;color:#14161a}.ci__note[data-v-52807f97]{display:inline-flex;align-items:center;gap:5px;border:0;background:none;cursor:pointer;padding:0;font-family:inherit;font-size:11.5px;font-weight:700;color:#7a1b33;white-space:nowrap}.ci__noteText[data-v-52807f97]{margin:8px 0 0;padding:8px 10px;border-radius:11px;background:#f4f5f6;font-size:11.5px;line-height:1.7;color:#5b616e}.cart[data-v-1b1ebdf9]{background:#fff;min-height:100vh}.cart__body[data-v-1b1ebdf9]{padding-top:76px;padding-bottom:150px}.cart__items[data-v-1b1ebdf9]{display:flex;flex-direction:column;gap:11px;padding-top:16px}.cart__empty[data-v-1b1ebdf9]{margin-top:8px;padding:38px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.cart__empty p[data-v-1b1ebdf9]{margin:0;font-size:12.5px}.cart__emptyCta[data-v-1b1ebdf9]{margin-top:4px;padding:9px 18px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#14161a}.cart__done[data-v-1b1ebdf9]{margin-top:20px;padding:34px 22px;border:1px solid #ECEDEF;border-radius:20px;display:flex;flex-direction:column;align-items:center;text-align:center}.cart__doneIcon[data-v-1b1ebdf9]{width:56px;height:56px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.cart__doneTitle[data-v-1b1ebdf9]{margin:14px 0 0;font-size:15px;font-weight:800;color:#14161a}.cart__doneSub[data-v-1b1ebdf9]{margin:8px 0 0;font-size:12.5px;color:#5b616e}.cart__doneSub b[data-v-1b1ebdf9]{color:#14161a}.cart__doneHint[data-v-1b1ebdf9]{margin:5px 0 0;font-size:11.5px;color:#8a909c}.cart__doneCta[data-v-1b1ebdf9]{margin-top:18px;padding:11px 22px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#14161a}.cart__bar[data-v-1b1ebdf9]{position:fixed;bottom:0;left:0;right:0;z-index:5;background:#ffffffeb;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-top:1px solid #ECEDEF;padding-bottom:66px}.cart__barInner[data-v-1b1ebdf9]{max-width:768px;margin:0 auto;padding:12px 16px;display:flex;align-items:center;justify-content:space-between;gap:14px}.cart__total[data-v-1b1ebdf9]{display:flex;flex-direction:column;gap:3px}.cart__totalLabel[data-v-1b1ebdf9]{font-size:11px;color:#8a909c}.cart__totalValue[data-v-1b1ebdf9]{font-size:16px;font-weight:800;color:#14161a}.cart__totalValue i[data-v-1b1ebdf9]{font-style:normal;font-size:11px;font-weight:600;color:#8a909c;padding-inline-start:3px}.cart__submit[data-v-1b1ebdf9]{flex:1;max-width:200px;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#14161a;transition:transform .15s ease}.cart__submit[data-v-1b1ebdf9]:active{transform:scale(.98)}.sheet[data-v-1b1ebdf9]{padding:18px 16px 22px}.sheet__title[data-v-1b1ebdf9]{margin:0 0 14px;font-size:13.5px;font-weight:800;color:#14161a}.sheet__cta[data-v-1b1ebdf9]{width:100%;padding:12px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#14161a}
.ci[data-v-52807f97]{display:flex;gap:14px;padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.ci__art[data-v-52807f97]{flex:0 0 84px;width:84px;height:84px;display:flex;align-items:center;justify-content:center;border-radius:13px;overflow:hidden;background:#f4f5f6}.ci__art img[data-v-52807f97]{width:90px;height:90px;-o-object-fit:contain;object-fit:contain;-o-object-position:center;object-position:center;display:block}.ci__artEmpty[data-v-52807f97]{width:100%;height:100%;display:grid;place-items:center;color:#8a909c}.ci__main[data-v-52807f97]{flex:1;min-width:0}.ci__title[data-v-52807f97]{margin:0;font-size:13px;font-weight:700;color:#14161a;line-height:1.6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ci__meta[data-v-52807f97]{display:flex;align-items:center;gap:7px;padding-top:5px}.ci__weight[data-v-52807f97]{font-size:11.5px;font-weight:700;color:#22262e}.ci__wage[data-v-52807f97]{font-size:10.5px;color:#8a909c;padding-inline-start:7px;border-inline-start:1px solid #ECEDEF}.ci__row[data-v-52807f97]{display:flex;align-items:center;justify-content:space-between;gap:10px;padding-top:10px}.ci__qty[data-v-52807f97]{display:inline-flex;align-items:center;gap:4px;padding:3px;border-radius:999px;background:#f4f5f6;border:1px solid #ECEDEF}.ci__qtyBtn[data-v-52807f97]{width:27px;height:27px;border:0;cursor:pointer;border-radius:50%;display:grid;place-items:center;color:#22262e;background:#fff;transition:transform .15s ease,color .15s ease}.ci__qtyBtn--danger[data-v-52807f97]{color:#7a1b33}.ci__qtyBtn[data-v-52807f97]:active{transform:scale(.9)}.ci__qtyValue[data-v-52807f97]{min-width:22px;text-align:center;font-size:12.5px;font-weight:700;color:#14161a}.ci__note[data-v-52807f97]{display:inline-flex;align-items:center;gap:5px;border:0;background:none;cursor:pointer;padding:0;font-family:inherit;font-size:11.5px;font-weight:700;color:#7a1b33;white-space:nowrap}.ci__noteText[data-v-52807f97]{margin:8px 0 0;padding:8px 10px;border-radius:11px;background:#f4f5f6;font-size:11.5px;line-height:1.7;color:#5b616e}.cart[data-v-cb7a6c16]{background:#fff;min-height:100vh}.cart__body[data-v-cb7a6c16]{padding-top:76px;padding-bottom:150px}.cart__items[data-v-cb7a6c16]{display:flex;flex-direction:column;gap:11px;padding-top:16px}.cart__empty[data-v-cb7a6c16]{margin-top:8px;padding:38px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.cart__empty p[data-v-cb7a6c16]{margin:0;font-size:12.5px}.cart__emptyCta[data-v-cb7a6c16]{margin-top:4px;padding:9px 18px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#23493c}.cart__done[data-v-cb7a6c16]{margin-top:20px;padding:34px 22px;border:1px solid #ECEDEF;border-radius:20px;display:flex;flex-direction:column;align-items:center;text-align:center}.cart__doneIcon[data-v-cb7a6c16]{width:56px;height:56px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.cart__doneTitle[data-v-cb7a6c16]{margin:14px 0 0;font-size:15px;font-weight:800;color:#14161a}.cart__doneSub[data-v-cb7a6c16]{margin:8px 0 0;font-size:12.5px;color:#5b616e}.cart__doneSub b[data-v-cb7a6c16]{color:#14161a}.cart__doneHint[data-v-cb7a6c16]{margin:5px 0 0;font-size:11.5px;color:#8a909c}.cart__doneCta[data-v-cb7a6c16]{margin-top:18px;padding:11px 22px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#23493c}.cart__bar[data-v-cb7a6c16]{position:fixed;bottom:0;left:0;right:0;z-index:5;background:#ffffffeb;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-top:1px solid #ECEDEF;padding-bottom:66px}.cart__barInner[data-v-cb7a6c16]{max-width:768px;margin:0 auto;padding:12px 16px;display:flex;align-items:center;justify-content:space-between;gap:14px}.cart__total[data-v-cb7a6c16]{display:flex;flex-direction:column;gap:3px}.cart__totalLabel[data-v-cb7a6c16]{font-size:11px;color:#8a909c}.cart__totalValue[data-v-cb7a6c16]{font-size:16px;font-weight:800;color:#14161a}.cart__totalValue i[data-v-cb7a6c16]{font-style:normal;font-size:11px;font-weight:600;color:#8a909c;padding-inline-start:3px}.cart__submit[data-v-cb7a6c16]{flex:1;max-width:200px;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#23493c;transition:transform .15s ease}.cart__submit[data-v-cb7a6c16]:active{transform:scale(.98)}.sheet[data-v-cb7a6c16]{padding:18px 16px 22px}.sheet__title[data-v-cb7a6c16]{margin:0 0 14px;font-size:13.5px;font-weight:800;color:#14161a}.sheet__cta[data-v-cb7a6c16]{width:100%;padding:12px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#23493c}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
.cho__barExtra[data-v-a0cb9c46]{padding:0 16px 12px}.cho__body[data-v-a0cb9c46]{padding-top:132px;padding-bottom:90px}.cho__list[data-v-a0cb9c46]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.cho__card[data-v-a0cb9c46]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px;cursor:pointer;transition:transform .2s ease}.cho__card[data-v-a0cb9c46]:active{transform:scale(.99)}.cho__top[data-v-a0cb9c46]{display:flex;justify-content:space-between;gap:12px}.cho__right[data-v-a0cb9c46]{display:flex;flex-direction:column;align-items:flex-end;gap:8px}.cho__num[data-v-a0cb9c46]{font-size:15px;font-weight:700;margin-bottom:10px}.cho__muted[data-v-a0cb9c46]{color:#5b616e;font-weight:500;margin-left:4px}.cho__meta[data-v-a0cb9c46]{display:flex;align-items:baseline;gap:4px}.cho__strong[data-v-a0cb9c46]{font-size:15px;font-weight:700}.cho__unit[data-v-a0cb9c46]{font-size:12px;color:#5b616e}.cho__status[data-v-a0cb9c46]{padding:5px 14px;border-radius:8px;font-size:12px;font-weight:600;color:#06b6d4;background:#ecfeff;white-space:nowrap}.cho__divider[data-v-a0cb9c46]{height:1px;background:#ecedef;margin:12px 0}.cho__bottom[data-v-a0cb9c46]{display:flex;justify-content:space-between;align-items:center}.cho__customer[data-v-a0cb9c46]{font-size:14px;font-weight:600;color:#5b616e}.cho__more[data-v-a0cb9c46],.cho__sentinel[data-v-a0cb9c46]{padding:12px 0;text-align:center;font-size:12px;color:#5b616e}.cho__empty[data-v-a0cb9c46]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.cho__retry[data-v-a0cb9c46]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.cho__detail[data-v-a0cb9c46]{padding:20px 16px 24px}.cho__detailTitle[data-v-a0cb9c46]{margin:0 0 16px;font-size:17px;font-weight:700}.cho__rows[data-v-a0cb9c46]{margin:0;display:flex;flex-direction:column;gap:2px}.cho__row[data-v-a0cb9c46]{display:flex;justify-content:space-between;align-items:center;padding:11px 14px;background:#fafafa;border-radius:10px}.cho__row dt[data-v-a0cb9c46]{font-size:13px;color:#5b616e}.cho__row dd[data-v-a0cb9c46]{margin:0;font-size:14px;font-weight:600}.cho__close[data-v-a0cb9c46]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#23493c;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
@@ -1 +0,0 @@
.cho__barExtra[data-v-43de2787]{padding:0 16px 12px}.cho__body[data-v-43de2787]{padding-top:132px;padding-bottom:90px}.cho__list[data-v-43de2787]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.cho__card[data-v-43de2787]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px;cursor:pointer;transition:transform .2s ease}.cho__card[data-v-43de2787]:active{transform:scale(.99)}.cho__top[data-v-43de2787]{display:flex;justify-content:space-between;gap:12px}.cho__right[data-v-43de2787]{display:flex;flex-direction:column;align-items:flex-end;gap:8px}.cho__num[data-v-43de2787]{font-size:15px;font-weight:700;margin-bottom:10px}.cho__muted[data-v-43de2787]{color:#5b616e;font-weight:500;margin-left:4px}.cho__meta[data-v-43de2787]{display:flex;align-items:baseline;gap:4px}.cho__strong[data-v-43de2787]{font-size:15px;font-weight:700}.cho__unit[data-v-43de2787]{font-size:12px;color:#5b616e}.cho__status[data-v-43de2787]{padding:5px 14px;border-radius:8px;font-size:12px;font-weight:600;color:#06b6d4;background:#ecfeff;white-space:nowrap}.cho__divider[data-v-43de2787]{height:1px;background:#ecedef;margin:12px 0}.cho__bottom[data-v-43de2787]{display:flex;justify-content:space-between;align-items:center}.cho__customer[data-v-43de2787]{font-size:14px;font-weight:600;color:#5b616e}.cho__more[data-v-43de2787],.cho__sentinel[data-v-43de2787]{padding:12px 0;text-align:center;font-size:12px;color:#5b616e}.cho__empty[data-v-43de2787]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.cho__retry[data-v-43de2787]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.cho__detail[data-v-43de2787]{padding:20px 16px 24px}.cho__detailTitle[data-v-43de2787]{margin:0 0 16px;font-size:17px;font-weight:700}.cho__rows[data-v-43de2787]{margin:0;display:flex;flex-direction:column;gap:2px}.cho__row[data-v-43de2787]{display:flex;justify-content:space-between;align-items:center;padding:11px 14px;background:#fafafa;border-radius:10px}.cho__row dt[data-v-43de2787]{font-size:13px;color:#5b616e}.cho__row dd[data-v-43de2787]{margin:0;font-size:14px;font-weight:600}.cho__close[data-v-43de2787]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#14161a;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
+1
View File
@@ -0,0 +1 @@
import{d as f,o as v,q as g,c as s,k as e,s as u,g as d,h as p,i as t,F as y,r as k,I as P,b as x,f as C,v as b,K as h,x as B,_ as V}from"./index-CRQPRp-C.js";import{P as w}from"./PageBar-DcURmszD.js";import{a as I}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import{S as N}from"./SectionHead-BjbRzluB.js";import{P as q}from"./ProductCard-wJY0AmTh.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./SingleProduct-DKqhvwd1.js";import"./DialogVant.vue_vue_type_style_index_0_lang-DFKmWR5Z.js";import"./cartStore-CIlq1T4-.js";import"./dialogEmpty1-E3h_JfwQ.js";import"./index-BVow2xBt.js";import"./classCallCheck-CJTmwORh.js";const F={class:"coll"},S={key:0,class:"coll__grid"},z={key:1,class:"coll__empty"},E=f({__name:"CollectionView",setup(H){const l=h(),o=d(!1),n=d([]),m=p(()=>l.query.page||"مجموعه"),c=p(()=>n.value.filter(i=>i.collections.some(a=>a.collectionId===l.params.id)));return v(async()=>{o.value=!0;try{n.value=await g.listProducts()}finally{o.value=!1}}),(i,a)=>{const _=b("container");return t(),s("div",F,[e(w,{title:m.value,"back-to":"search"},null,8,["title"]),e(I,{spinning:o.value,tip:"درحال دریافت اطلاعات"},{default:u(()=>[e(_,{class:"coll__body"},{default:u(()=>[e(N,{title:"محصولات این مجموعه",subtitle:"برای دیدن جزئیات، روی محصول ضربه بزنید"}),c.value.length?(t(),s("div",S,[(t(!0),s(y,null,k(c.value,r=>(t(),B(q,{key:r.id,value:r},null,8,["value"]))),128))])):o.value?C("",!0):(t(),s("section",z,[e(P,{icon:"vuesax-linear:box",size:"26"}),a[0]||(a[0]=x("p",null,"در این مجموعه محصولی ثبت نشده است.",-1))]))]),_:1})]),_:1},8,["spinning"])])}}}),Q=V(E,[["__scopeId","data-v-4e05d52b"]]);export{Q as default};
-1
View File
@@ -1 +0,0 @@
import{d as f,o as v,q as g,c as s,k as e,s as u,g as p,h as m,i as t,F as y,r as k,I as P,b as x,f as C,v as b,K as h,x as B,_ as V}from"./index-BLEa2dU-.js";import{P as w}from"./PageBar-IlBZ6uld.js";import{a as I}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";import{S as N}from"./SectionHead-BA4SOlK7.js";import{P as q}from"./ProductCard-D-GU5P_U.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./SingleProduct-8QiMtS5l.js";import"./NotifyVant.vue_vue_type_script_setup_true_lang-1ZprOz0l.js";import"./index-BZfaFJkz.js";import"./DialogVant.vue_vue_type_style_index_0_lang-CV2_T34Y.js";import"./cartStore-DfRVSG0q.js";import"./dialogEmpty1-E3h_JfwQ.js";import"./index-DBmNdnBg.js";import"./classCallCheck-BHfqvuTP.js";const F={class:"coll"},S={key:0,class:"coll__grid"},z={key:1,class:"coll__empty"},E=f({__name:"CollectionView",setup(H){const l=h(),o=p(!1),n=p([]),d=m(()=>l.query.page||"مجموعه"),i=m(()=>n.value.filter(r=>r.collections.some(a=>a.collectionId===l.params.id)));return v(async()=>{o.value=!0;try{n.value=await g.listProducts()}finally{o.value=!1}}),(r,a)=>{const _=b("container");return t(),s("div",F,[e(w,{title:d.value,"back-to":"search"},null,8,["title"]),e(I,{spinning:o.value,tip:"درحال دریافت اطلاعات"},{default:u(()=>[e(_,{class:"coll__body"},{default:u(()=>[e(N,{title:"محصولات این مجموعه",subtitle:"برای دیدن جزئیات، روی محصول ضربه بزنید"}),i.value.length?(t(),s("div",S,[(t(!0),s(y,null,k(i.value,c=>(t(),B(q,{key:c.id,value:c},null,8,["value"]))),128))])):o.value?C("",!0):(t(),s("section",z,[e(P,{icon:"vuesax-linear:box",size:"26"}),a[0]||(a[0]=x("p",null,"در این مجموعه محصولی ثبت نشده است.",-1))]))]),_:1})]),_:1},8,["spinning"])])}}}),W=V(E,[["__scopeId","data-v-4e05d52b"]]);export{W as default};
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
.siu__input[data-v-6ccc0338]{display:none}.siu__box[data-v-6ccc0338]{position:relative;width:100%;min-height:132px;padding:20px 16px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;border:1px dashed #ECEDEF;border-radius:18px;background:#fafafa;font-family:inherit;cursor:pointer;overflow:hidden;transition:border-color .2s ease}.siu__box[data-v-6ccc0338]:disabled{cursor:progress}.is-done .siu__box[data-v-6ccc0338]{border-style:solid;border-color:#16a34a}.is-error .siu__box[data-v-6ccc0338]{border-color:#dc2626}.siu__preview[data-v-6ccc0338]{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;-o-object-fit:cover;object-fit:cover;opacity:.32}.siu__icon[data-v-6ccc0338],.siu__text[data-v-6ccc0338]{position:relative;z-index:1}.siu__text[data-v-6ccc0338]{font-size:13px;font-weight:600;color:#5b616e}.siu__badge[data-v-6ccc0338]{position:absolute;top:10px;left:10px;z-index:1;display:flex;color:#16a34a}.siu__error[data-v-6ccc0338]{margin:7px 2px 0;font-size:12px;color:#dc2626}.cpf__body[data-v-3d5482f8]{padding-top:90px;padding-bottom:40px}.cpf__lead[data-v-3d5482f8]{margin:4px 0 18px;font-size:13px;color:#5b616e}.cpf__form[data-v-3d5482f8]{display:flex;flex-direction:column;gap:14px}.cpf__error[data-v-3d5482f8]{margin:2px;font-size:12.5px;color:#dc2626}.cpf__submit[data-v-3d5482f8]{margin-top:6px;width:100%;padding:14px;border:none;border-radius:14px;background:#14161a;color:#fff;font-family:inherit;font-size:15px;font-weight:700;cursor:pointer}.cpf__submit[data-v-3d5482f8]:disabled{opacity:.6;cursor:progress}.cpf__dialogText[data-v-3d5482f8]{padding:20px;line-height:1.9;text-align:justify;font-size:14px}.cpf__dialogBtn[data-v-3d5482f8]{text-align:center;cursor:pointer}
.siu__input[data-v-6ccc0338]{display:none}.siu__box[data-v-6ccc0338]{position:relative;width:100%;min-height:132px;padding:20px 16px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;border:1px dashed #ECEDEF;border-radius:18px;background:#fafafa;font-family:inherit;cursor:pointer;overflow:hidden;transition:border-color .2s ease}.siu__box[data-v-6ccc0338]:disabled{cursor:progress}.is-done .siu__box[data-v-6ccc0338]{border-style:solid;border-color:#16a34a}.is-error .siu__box[data-v-6ccc0338]{border-color:#dc2626}.siu__preview[data-v-6ccc0338]{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;-o-object-fit:cover;object-fit:cover;opacity:.32}.siu__icon[data-v-6ccc0338],.siu__text[data-v-6ccc0338]{position:relative;z-index:1}.siu__text[data-v-6ccc0338]{font-size:13px;font-weight:600;color:#5b616e}.siu__badge[data-v-6ccc0338]{position:absolute;top:10px;left:10px;z-index:1;display:flex;color:#16a34a}.siu__error[data-v-6ccc0338]{margin:7px 2px 0;font-size:12px;color:#dc2626}.cpf__body[data-v-95ead48e]{padding-top:90px;padding-bottom:40px}.cpf__lead[data-v-95ead48e]{margin:4px 0 18px;font-size:13px;color:#5b616e}.cpf__form[data-v-95ead48e]{display:flex;flex-direction:column;gap:14px}.cpf__error[data-v-95ead48e]{margin:2px;font-size:12.5px;color:#dc2626}.cpf__submit[data-v-95ead48e]{margin-top:6px;width:100%;padding:14px;border:none;border-radius:14px;background:#23493c;color:#fff;font-family:inherit;font-size:15px;font-weight:700;cursor:pointer}.cpf__submit[data-v-95ead48e]:disabled{opacity:.6;cursor:progress}.cpf__dialogText[data-v-95ead48e]{padding:20px;line-height:1.9;text-align:justify;font-size:14px}.cpf__dialogBtn[data-v-95ead48e]{text-align:center;cursor:pointer}
@@ -0,0 +1 @@
import{d as B,i as r,c as _,e as $,b as o,k as t,I as C,t as k,f as x,g as l,q as I,_ as P,s as g,a0 as S,j as D,C as U,v as V,y as z,O as R}from"./index-CRQPRp-C.js";import{P as T}from"./PageBar-DcURmszD.js";import{a as j}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import"./_commonjsHelpers-Cpj98o6Y.js";const N=["disabled"],E=["src"],L={key:1,class:"siu__icon"},M={class:"siu__text"},O={key:2,class:"siu__badge"},q={key:0,class:"siu__error"},A=8*1024*1024,W=B({__name:"SingleImageUploader",props:{uploadText:{},purpose:{}},emits:["done"],setup(b,{emit:y}){const a=b,p=y,u=l(null),i=l(!1),n=l(null),c=l(null),m=l(null);async function e(v){var f;const s=v.target,d=(f=s.files)==null?void 0:f[0];if(s.value="",!!d){if(n.value=null,d.size>A){n.value="حجم فایل بیش از حد مجاز است (۸ مگابایت)";return}i.value=!0;try{const w=await I.uploadDocument(d,a.purpose);c.value=w.id,m.value=d.type.startsWith("image/")?URL.createObjectURL(d):null,p("done",w.id)}catch{n.value="بارگذاری انجام نشد. دوباره تلاش کنید.",c.value=null,m.value=null}finally{i.value=!1}}}return(v,s)=>(r(),_("div",{class:$(["siu",{"is-done":!!c.value,"is-error":!!n.value}])},[o("input",{ref_key:"input",ref:u,type:"file",accept:"image/jpeg,image/png,image/webp,application/pdf",class:"siu__input",onChange:e},null,544),o("button",{type:"button",class:"siu__box",disabled:i.value,onClick:s[0]||(s[0]=d=>{var f;return(f=u.value)==null?void 0:f.click()})},[m.value?(r(),_("img",{key:0,src:m.value,class:"siu__preview",alt:""},null,8,E)):(r(),_("span",L,[t(C,{icon:i.value?"vuesax-linear:refresh":"vuesax-linear:gallery-add",size:"26"},null,8,["icon"])])),o("span",M,k(i.value?"در حال بارگذاری…":c.value?"تغییر تصویر":b.uploadText),1),c.value&&!i.value?(r(),_("span",O,[t(C,{icon:"vuesax-linear:tick-circle",size:"16"})])):x("",!0)],8,N),n.value?(r(),_("p",q,k(n.value),1)):x("",!0)],2))}}),h=P(W,[["__scopeId","data-v-6ccc0338"]]),X={class:"cpf"},Y={key:0,class:"cpf__error"},F=["disabled"],G=B({__name:"CompleteProfileView",setup(b){const y=z(),a=U({business_license_image_id:null,shop_image_id:null,ncode_image_id:null}),p=l(!1),u=l(!1),i=l(null);async function n(){if(i.value=null,!a.business_license_image_id||!a.shop_image_id||!a.ncode_image_id){R.warning("لطفا تمامی عکس های خواسته شده را آپلود کنید");return}p.value=!0;try{await I.completeProfile({business_license_image_id:a.business_license_image_id,shop_image_id:a.shop_image_id,ncode_image_id:a.ncode_image_id}),u.value=!0}catch{i.value="ثبت اطلاعات انجام نشد. دوباره تلاش کنید."}finally{p.value=!1}}function c(){u.value=!1,y.push({name:"home"})}return(m,e)=>{const v=V("container");return r(),_("div",X,[t(T,{title:"تکمیل پروفایل","back-to":"userPage::hasSubRoute"}),t(j,{spinning:p.value,tip:"در حال ثبت اطلاعات"},{default:g(()=>[t(v,{class:"cpf__body"},{default:g(()=>[e[4]||(e[4]=o("p",{class:"cpf__lead"}," برای تکمیل پروفایل، سه مدرک زیر را بارگذاری کنید. ",-1)),o("form",{class:"cpf__form",onSubmit:D(n,["prevent"])},[t(h,{"upload-text":"بارگذاری عکس جواز کسب",purpose:"business-license",onDone:e[0]||(e[0]=s=>a.business_license_image_id=s)}),t(h,{"upload-text":"بارگذاری عکس سردر مغازه",purpose:"shop-image",onDone:e[1]||(e[1]=s=>a.shop_image_id=s)}),t(h,{"upload-text":"بارگذاری عکس کارت ملی",purpose:"national-card",onDone:e[2]||(e[2]=s=>a.ncode_image_id=s)}),i.value?(r(),_("p",Y,k(i.value),1)):x("",!0),o("button",{type:"submit",class:"cpf__submit",disabled:p.value}," بارگذاری اطلاعات ",8,F)],32)]),_:1})]),_:1},8,["spinning"]),t(S,{show:u.value,"onUpdate:show":e[3]||(e[3]=s=>u.value=s),"time-out":-1,"close-on-click-overlay":!1},{title:g(()=>[...e[5]||(e[5]=[o("div",{class:"cpf__dialogText"}," تکمیل اطلاعات شما با موفقیت انجام شد. ",-1)])]),button:g(()=>[o("div",{class:"cpf__dialogBtn",onClick:c},"متوجه شدم")]),_:1},8,["show"])])}}}),Z=P(G,[["__scopeId","data-v-95ead48e"]]);export{Z as default};
@@ -1 +1 @@
import{d as z,o as S,c,k as a,s as d,u as w,g as r,q as N,i,b as s,F as P,r as B,I as u,t as o,f as m,v as D,e as F,_ as I}from"./index-BLEa2dU-.js";import{P as E}from"./PageBar-IlBZ6uld.js";import{a as R}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";import{S as $}from"./SearchInput-i5kperOC.js";import{D as U}from"./index-DBmNdnBg.js";import{P as q}from"./index-BUGuFVDv.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./classCallCheck-BHfqvuTP.js";const L={class:"cch"},M={class:"cch__barExtra"},O={key:0,class:"cch__list"},T=["onClick"],j={class:"cch__head"},A={class:"cch__name"},G={class:"cch__facts"},H={class:"cch__fact"},J={dir:"ltr"},K={class:"cch__fact"},Q={dir:"ltr"},W={key:0,class:"cch__fact"},X={key:1,class:"cch__empty"},Y={key:2,class:"cch__empty"},Z={key:0,class:"cch__detail"},ss={class:"cch__detailTitle"},es={class:"cch__rows"},ts={class:"cch__row"},os={dir:"ltr"},as={class:"cch__row"},ls={dir:"ltr"},ns={class:"cch__row"},cs={class:"cch__row"},is={class:"cch__row"},rs={dir:"ltr"},_s={class:"cch__row"},ds={dir:"ltr"},us={class:"cch__row"},vs=z({__name:"CustomerChoiceView",setup(hs){const _=r([]),v=r(!1),y=r(!1),h=r(!1),b=r(null),p=r(!1),l=r(null);function g(n){const e=Number(n??0);return Number.isFinite(e)?e.toFixed(3):"0.000"}async function f(){v.value=!0,h.value=!1;try{_.value=await N.getExpertCustomers(b.value)}catch{h.value=!0,_.value=[]}finally{v.value=!1}}async function k(n){b.value=n!=null&&n.trim()?n.trim():null,await f()}async function C(){await f(),y.value=!1}function x(n){l.value=n,p.value=!0}return S(f),(n,e)=>{const V=D("container");return i(),c("div",L,[a(E,{title:"لیست مشتریان","back-to":"userPage::hasSubRoute"},{below:d(()=>[s("div",M,[a($,{onSearch:k,"place-holder":"جستجو"})])]),_:1}),a(R,{spinning:v.value&&!_.value.length,tip:"درحال دریافت اطلاعات"},{default:d(()=>[a(w(q),{modelValue:y.value,"onUpdate:modelValue":e[0]||(e[0]=t=>y.value=t),onRefresh:C},{default:d(()=>[a(V,{class:"cch__body"},{default:d(()=>[_.value.length?(i(),c("div",O,[(i(!0),c(P,null,B(_.value,t=>(i(),c("article",{key:t.id,class:"cch__card",onClick:ps=>x(t)},[s("div",j,[s("h3",A,o(t.name),1),s("span",{class:F(["cch__state",t.active===1?"is-on":"is-off"])},o(t.active===1?"فعال":"غیرفعال"),3)]),s("div",G,[s("div",H,[a(u,{icon:"vuesax-linear:mobile",size:"15"}),s("span",J,o(t.mobile||"—"),1)]),s("div",K,[a(u,{icon:"vuesax-linear:call",size:"15"}),s("span",Q,o(t.phone||"—"),1)]),t.store_name?(i(),c("div",W,[a(u,{icon:"vuesax-linear:shop",size:"15"}),s("span",null,o(t.store_name),1)])):m("",!0)])],8,T))),128))])):!v.value&&!h.value?(i(),c("section",X,[a(u,{icon:"vuesax-linear:profile-2user",size:"26"}),s("p",null,o(b.value?"مشتری با این مشخصات پیدا نشد.":"هنوز مشتری‌ای به شما معرفی نشده است."),1)])):m("",!0),h.value?(i(),c("section",Y,[a(u,{icon:"vuesax-linear:danger",size:"26"}),e[3]||(e[3]=s("p",null,"دریافت اطلاعات با خطا روبه‌رو شد.",-1)),s("button",{type:"button",class:"cch__retry",onClick:f},"تلاش دوباره")])):m("",!0)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["spinning"]),a(w(U),{open:p.value,"onUpdate:open":e[2]||(e[2]=t=>p.value=t),placement:"bottom",height:"auto",closable:!1,"body-style":{padding:"0"}},{default:d(()=>[l.value?(i(),c("div",Z,[s("h2",ss,o(l.value.name),1),s("dl",es,[s("div",ts,[e[4]||(e[4]=s("dt",null,"موبایل",-1)),s("dd",os,o(l.value.mobile||"—"),1)]),s("div",as,[e[5]||(e[5]=s("dt",null,"تلفن",-1)),s("dd",ls,o(l.value.phone||"—"),1)]),s("div",ns,[e[6]||(e[6]=s("dt",null,"نام مغازه",-1)),s("dd",null,o(l.value.store_name||"—"),1)]),s("div",cs,[e[7]||(e[7]=s("dt",null,"نام پاساژ",-1)),s("dd",null,o(l.value.pasazh_name||"—"),1)]),s("div",is,[e[8]||(e[8]=s("dt",null,"سقف اعتبار",-1)),s("dd",rs,o(g(l.value.gram_level))+" گرم",1)]),s("div",_s,[e[9]||(e[9]=s("dt",null,"بدهی گرمی",-1)),s("dd",ds,o(g(l.value.remain))+" گرم",1)]),s("div",us,[e[10]||(e[10]=s("dt",null,"وضعیت",-1)),s("dd",null,o(l.value.active===1?"فعال":"غیرفعال"),1)])]),s("button",{type:"button",class:"cch__close",onClick:e[1]||(e[1]=t=>p.value=!1)},"بستن")])):m("",!0)]),_:1},8,["open"])])}}}),xs=I(vs,[["__scopeId","data-v-5eb7847e"]]);export{xs as default};
import{d as z,o as S,c,k as a,s as d,u as w,g as r,q as N,i,b as s,F as P,r as B,I as u,t as o,f as m,v as D,e as F,_ as I}from"./index-CRQPRp-C.js";import{P as E}from"./PageBar-DcURmszD.js";import{a as R}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import{S as $}from"./SearchInput-CtTYi3ft.js";import{D as U}from"./index-BVow2xBt.js";import{P as q}from"./index-Btu2EoFw.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./classCallCheck-CJTmwORh.js";const L={class:"cch"},M={class:"cch__barExtra"},O={key:0,class:"cch__list"},T=["onClick"],j={class:"cch__head"},A={class:"cch__name"},G={class:"cch__facts"},H={class:"cch__fact"},J={dir:"ltr"},K={class:"cch__fact"},Q={dir:"ltr"},W={key:0,class:"cch__fact"},X={key:1,class:"cch__empty"},Y={key:2,class:"cch__empty"},Z={key:0,class:"cch__detail"},ss={class:"cch__detailTitle"},es={class:"cch__rows"},ts={class:"cch__row"},os={dir:"ltr"},as={class:"cch__row"},ls={dir:"ltr"},ns={class:"cch__row"},cs={class:"cch__row"},is={class:"cch__row"},rs={dir:"ltr"},_s={class:"cch__row"},ds={dir:"ltr"},us={class:"cch__row"},vs=z({__name:"CustomerChoiceView",setup(hs){const _=r([]),v=r(!1),b=r(!1),h=r(!1),y=r(null),p=r(!1),l=r(null);function g(n){const e=Number(n??0);return Number.isFinite(e)?e.toFixed(3):"0.000"}async function f(){v.value=!0,h.value=!1;try{_.value=await N.getExpertCustomers(y.value)}catch{h.value=!0,_.value=[]}finally{v.value=!1}}async function k(n){y.value=n!=null&&n.trim()?n.trim():null,await f()}async function C(){await f(),b.value=!1}function x(n){l.value=n,p.value=!0}return S(f),(n,e)=>{const V=D("container");return i(),c("div",L,[a(E,{title:"لیست مشتریان","back-to":"userPage::hasSubRoute"},{below:d(()=>[s("div",M,[a($,{onSearch:k,"place-holder":"جستجو"})])]),_:1}),a(R,{spinning:v.value&&!_.value.length,tip:"درحال دریافت اطلاعات"},{default:d(()=>[a(w(q),{modelValue:b.value,"onUpdate:modelValue":e[0]||(e[0]=t=>b.value=t),onRefresh:C},{default:d(()=>[a(V,{class:"cch__body"},{default:d(()=>[_.value.length?(i(),c("div",O,[(i(!0),c(P,null,B(_.value,t=>(i(),c("article",{key:t.id,class:"cch__card",onClick:ps=>x(t)},[s("div",j,[s("h3",A,o(t.name),1),s("span",{class:F(["cch__state",t.active===1?"is-on":"is-off"])},o(t.active===1?"فعال":"غیرفعال"),3)]),s("div",G,[s("div",H,[a(u,{icon:"vuesax-linear:mobile",size:"15"}),s("span",J,o(t.mobile||"—"),1)]),s("div",K,[a(u,{icon:"vuesax-linear:call",size:"15"}),s("span",Q,o(t.phone||"—"),1)]),t.store_name?(i(),c("div",W,[a(u,{icon:"vuesax-linear:shop",size:"15"}),s("span",null,o(t.store_name),1)])):m("",!0)])],8,T))),128))])):!v.value&&!h.value?(i(),c("section",X,[a(u,{icon:"vuesax-linear:profile-2user",size:"26"}),s("p",null,o(y.value?"مشتری با این مشخصات پیدا نشد.":"هنوز مشتری‌ای به شما معرفی نشده است."),1)])):m("",!0),h.value?(i(),c("section",Y,[a(u,{icon:"vuesax-linear:danger",size:"26"}),e[3]||(e[3]=s("p",null,"دریافت اطلاعات با خطا روبه‌رو شد.",-1)),s("button",{type:"button",class:"cch__retry",onClick:f},"تلاش دوباره")])):m("",!0)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["spinning"]),a(w(U),{open:p.value,"onUpdate:open":e[2]||(e[2]=t=>p.value=t),placement:"bottom",height:"auto",closable:!1,"body-style":{padding:"0"}},{default:d(()=>[l.value?(i(),c("div",Z,[s("h2",ss,o(l.value.name),1),s("dl",es,[s("div",ts,[e[4]||(e[4]=s("dt",null,"موبایل",-1)),s("dd",os,o(l.value.mobile||"—"),1)]),s("div",as,[e[5]||(e[5]=s("dt",null,"تلفن",-1)),s("dd",ls,o(l.value.phone||"—"),1)]),s("div",ns,[e[6]||(e[6]=s("dt",null,"نام مغازه",-1)),s("dd",null,o(l.value.store_name||"—"),1)]),s("div",cs,[e[7]||(e[7]=s("dt",null,"نام پاساژ",-1)),s("dd",null,o(l.value.pasazh_name||"—"),1)]),s("div",is,[e[8]||(e[8]=s("dt",null,"سقف اعتبار",-1)),s("dd",rs,o(g(l.value.gram_level))+" گرم",1)]),s("div",_s,[e[9]||(e[9]=s("dt",null,"بدهی گرمی",-1)),s("dd",ds,o(g(l.value.remain))+" گرم",1)]),s("div",us,[e[10]||(e[10]=s("dt",null,"وضعیت",-1)),s("dd",null,o(l.value.active===1?"فعال":"غیرفعال"),1)])]),s("button",{type:"button",class:"cch__close",onClick:e[1]||(e[1]=t=>p.value=!1)},"بستن")])):m("",!0)]),_:1},8,["open"])])}}}),xs=I(vs,[["__scopeId","data-v-5a9bdd6b"]]);export{xs as default};
@@ -0,0 +1 @@
.cch__barExtra[data-v-5a9bdd6b]{padding:0 16px 12px}.cch__body[data-v-5a9bdd6b]{padding-top:132px;padding-bottom:90px}.cch__list[data-v-5a9bdd6b]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.cch__card[data-v-5a9bdd6b]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px;cursor:pointer;transition:transform .2s ease}.cch__card[data-v-5a9bdd6b]:active{transform:scale(.99)}.cch__head[data-v-5a9bdd6b]{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.cch__name[data-v-5a9bdd6b]{margin:0;font-size:15.5px;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cch__state[data-v-5a9bdd6b]{flex:0 0 auto;padding:4px 12px;border-radius:999px;font-size:11.5px;font-weight:600}.cch__state.is-on[data-v-5a9bdd6b]{color:#16a34a;background:#dcfce7}.cch__state.is-off[data-v-5a9bdd6b]{color:#dc2626;background:#fee2e2}.cch__facts[data-v-5a9bdd6b]{display:flex;flex-direction:column;gap:7px}.cch__fact[data-v-5a9bdd6b]{display:flex;align-items:center;gap:7px;font-size:13px;font-weight:600;color:#5b616e}.cch__empty[data-v-5a9bdd6b]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.cch__retry[data-v-5a9bdd6b]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.cch__detail[data-v-5a9bdd6b]{padding:20px 16px 24px}.cch__detailTitle[data-v-5a9bdd6b]{margin:0 0 16px;font-size:17px;font-weight:700}.cch__rows[data-v-5a9bdd6b]{margin:0;display:flex;flex-direction:column;gap:2px}.cch__row[data-v-5a9bdd6b]{display:flex;justify-content:space-between;align-items:center;padding:11px 14px;background:#fafafa;border-radius:10px}.cch__row dt[data-v-5a9bdd6b]{font-size:13px;color:#5b616e}.cch__row dd[data-v-5a9bdd6b]{margin:0;font-size:14px;font-weight:600}.cch__close[data-v-5a9bdd6b]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#23493c;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
@@ -1 +0,0 @@
.cch__barExtra[data-v-5eb7847e]{padding:0 16px 12px}.cch__body[data-v-5eb7847e]{padding-top:132px;padding-bottom:90px}.cch__list[data-v-5eb7847e]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.cch__card[data-v-5eb7847e]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px;cursor:pointer;transition:transform .2s ease}.cch__card[data-v-5eb7847e]:active{transform:scale(.99)}.cch__head[data-v-5eb7847e]{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.cch__name[data-v-5eb7847e]{margin:0;font-size:15.5px;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cch__state[data-v-5eb7847e]{flex:0 0 auto;padding:4px 12px;border-radius:999px;font-size:11.5px;font-weight:600}.cch__state.is-on[data-v-5eb7847e]{color:#16a34a;background:#dcfce7}.cch__state.is-off[data-v-5eb7847e]{color:#dc2626;background:#fee2e2}.cch__facts[data-v-5eb7847e]{display:flex;flex-direction:column;gap:7px}.cch__fact[data-v-5eb7847e]{display:flex;align-items:center;gap:7px;font-size:13px;font-weight:600;color:#5b616e}.cch__empty[data-v-5eb7847e]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.cch__retry[data-v-5eb7847e]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.cch__detail[data-v-5eb7847e]{padding:20px 16px 24px}.cch__detailTitle[data-v-5eb7847e]{margin:0 0 16px;font-size:17px;font-weight:700}.cch__rows[data-v-5eb7847e]{margin:0;display:flex;flex-direction:column;gap:2px}.cch__row[data-v-5eb7847e]{display:flex;justify-content:space-between;align-items:center;padding:11px 14px;background:#fafafa;border-radius:10px}.cch__row dt[data-v-5eb7847e]{font-size:13px;color:#5b616e}.cch__row dd[data-v-5eb7847e]{margin:0;font-size:14px;font-weight:600}.cch__close[data-v-5eb7847e]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#14161a;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
-1
View File
@@ -1 +0,0 @@
.dash[data-v-94bfcf92]{background:#fff;min-height:100vh}.dash__bar[data-v-94bfcf92]{position:fixed;top:0;left:0;right:0;z-index:20;background:#ffffffe0;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-bottom:1px solid #ECEDEF}.dash__barInner[data-v-94bfcf92]{max-width:768px;margin:0 auto;padding:11px 16px;display:flex;align-items:center;justify-content:space-between;gap:12px}.dash__barTitle[data-v-94bfcf92]{margin:0;font-size:14.5px;font-weight:800;color:#14161a}.dash__barBtn[data-v-94bfcf92]{flex:0 0 auto;width:38px;height:38px;border:0;cursor:pointer;border-radius:12px;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.dash__barBtn[data-v-94bfcf92]:active{transform:scale(.94)}.dash__barSpacer[data-v-94bfcf92]{display:block;width:38px;height:38px}.dash__body[data-v-94bfcf92]{padding-top:76px;padding-bottom:90px}.dash__balance[data-v-94bfcf92]{padding:16px;border-radius:20px;background:#14161a;color:#fff;box-shadow:0 14px 30px -22px #14161af2}.dash__balanceHead[data-v-94bfcf92]{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.dash__eyebrow[data-v-94bfcf92]{font-size:11.5px;color:#ffffff9e}.dash__figure[data-v-94bfcf92]{padding-top:5px;font-size:25px;font-weight:800;letter-spacing:-.3px}.dash__unit[data-v-94bfcf92]{font-size:11.5px;font-weight:600;color:#ffffff9e;padding-inline-start:4px}.dash__seal[data-v-94bfcf92]{flex:0 0 auto;padding:5px 12px;border-radius:999px;font-size:10.5px;font-weight:700}.dash__seal.is-debtor[data-v-94bfcf92]{color:#fff;background:#a33c55}.dash__seal.is-creditor[data-v-94bfcf92]{color:#14161a;background:#ffffffe6}.dash__balanceRow[data-v-94bfcf92]{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:16px;padding-top:13px;border-top:1px solid rgba(255,255,255,.13)}.dash__rowLabel[data-v-94bfcf92]{font-size:11.5px;color:#ffffff9e}.dash__rowValue[data-v-94bfcf92]{font-size:13.5px;font-weight:700}.dash__rowValue i[data-v-94bfcf92]{font-style:normal;font-size:10.5px;font-weight:600;color:#ffffff9e;padding-inline-start:3px}.dash__identity[data-v-94bfcf92]{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:13px;padding-top:13px;border-top:1px solid rgba(255,255,255,.13)}.dash__name[data-v-94bfcf92]{font-size:12.5px;font-weight:700}.dash__mobile[data-v-94bfcf92]{font-size:11.5px;color:#ffffff9e;direction:ltr}.dash__invite[data-v-94bfcf92]{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.dash__inviteIcon[data-v-94bfcf92]{flex:0 0 42px;width:42px;height:42px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.dash__inviteCopy[data-v-94bfcf92]{flex:1;min-width:0}.dash__inviteCopy h3[data-v-94bfcf92]{margin:0;font-size:13px;font-weight:800;color:#14161a}.dash__inviteCopy p[data-v-94bfcf92]{margin:4px 0 0;font-size:11.5px;color:#8a909c}.dash__inviteCta[data-v-94bfcf92]{flex:0 0 auto;padding:9px 14px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:11.5px;font-weight:700;color:#fff;background:#14161a}.dash__section[data-v-94bfcf92]{margin-top:26px}.dash__grid[data-v-94bfcf92]{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}.dash__tile[data-v-94bfcf92]{display:flex;flex-direction:column;align-items:center;gap:8px;padding:14px 6px;border:1px solid #ECEDEF;border-radius:16px;cursor:pointer;background:#fff;font-family:inherit;transition:transform .18s ease}.dash__tile[data-v-94bfcf92]:active{transform:scale(.97)}.dash__tile.is-disabled[data-v-94bfcf92]{opacity:.4}.dash__tileIcon[data-v-94bfcf92]{width:38px;height:38px;border-radius:12px;display:grid;place-items:center;color:#22262e;background:#f4f5f6}.dash__tileTitle[data-v-94bfcf92]{font-size:11px;font-weight:700;color:#22262e}
+1
View File
@@ -0,0 +1 @@
.dash[data-v-0d767c80]{background:#fff;min-height:100vh}.dash__bar[data-v-0d767c80]{position:fixed;top:0;left:0;right:0;z-index:20;background:#ffffffe0;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-bottom:1px solid #ECEDEF}.dash__barInner[data-v-0d767c80]{max-width:768px;margin:0 auto;padding:11px 16px;display:flex;align-items:center;justify-content:space-between;gap:12px}.dash__barTitle[data-v-0d767c80]{margin:0;font-size:14.5px;font-weight:800;color:#14161a}.dash__barBtn[data-v-0d767c80]{flex:0 0 auto;width:38px;height:38px;border:0;cursor:pointer;border-radius:12px;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.dash__barBtn[data-v-0d767c80]:active{transform:scale(.94)}.dash__barSpacer[data-v-0d767c80]{display:block;width:38px;height:38px}.dash__body[data-v-0d767c80]{padding-top:76px;padding-bottom:90px}.dash__balance[data-v-0d767c80]{padding:16px;border-radius:20px;background:#23493c;color:#fff;box-shadow:0 14px 30px -22px #14161af2}.dash__balanceHead[data-v-0d767c80]{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.dash__eyebrow[data-v-0d767c80]{font-size:11.5px;color:#ffffff9e}.dash__figure[data-v-0d767c80]{padding-top:5px;font-size:25px;font-weight:800;letter-spacing:-.3px}.dash__unit[data-v-0d767c80]{font-size:11.5px;font-weight:600;color:#ffffff9e;padding-inline-start:4px}.dash__seal[data-v-0d767c80]{flex:0 0 auto;padding:5px 12px;border-radius:999px;font-size:10.5px;font-weight:700}.dash__seal.is-debtor[data-v-0d767c80]{color:#fff;background:#a33c55}.dash__seal.is-creditor[data-v-0d767c80]{color:#14161a;background:#ffffffe6}.dash__balanceRow[data-v-0d767c80]{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:16px;padding-top:13px;border-top:1px solid rgba(255,255,255,.13)}.dash__rowLabel[data-v-0d767c80]{font-size:11.5px;color:#ffffff9e}.dash__rowValue[data-v-0d767c80]{font-size:13.5px;font-weight:700}.dash__rowValue i[data-v-0d767c80]{font-style:normal;font-size:10.5px;font-weight:600;color:#ffffff9e;padding-inline-start:3px}.dash__identity[data-v-0d767c80]{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:13px;padding-top:13px;border-top:1px solid rgba(255,255,255,.13)}.dash__name[data-v-0d767c80]{font-size:12.5px;font-weight:700}.dash__mobile[data-v-0d767c80]{font-size:11.5px;color:#ffffff9e;direction:ltr}.dash__invite[data-v-0d767c80]{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.dash__inviteIcon[data-v-0d767c80]{flex:0 0 42px;width:42px;height:42px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.dash__inviteCopy[data-v-0d767c80]{flex:1;min-width:0}.dash__inviteCopy h3[data-v-0d767c80]{margin:0;font-size:13px;font-weight:800;color:#14161a}.dash__inviteCopy p[data-v-0d767c80]{margin:4px 0 0;font-size:11.5px;color:#8a909c}.dash__inviteCta[data-v-0d767c80]{flex:0 0 auto;padding:9px 14px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:11.5px;font-weight:700;color:#fff;background:#23493c}.dash__section[data-v-0d767c80]{margin-top:26px}.dash__grid[data-v-0d767c80]{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}.dash__tile[data-v-0d767c80]{display:flex;flex-direction:column;align-items:center;gap:8px;padding:14px 6px;border:1px solid #ECEDEF;border-radius:16px;cursor:pointer;background:#fff;font-family:inherit;transition:transform .18s ease}.dash__tile[data-v-0d767c80]:active{transform:scale(.97)}.dash__tile.is-disabled[data-v-0d767c80]{opacity:.4}.dash__tileIcon[data-v-0d767c80]{width:38px;height:38px;border-radius:12px;display:grid;place-items:center;color:#22262e;background:#f4f5f6}.dash__tileTitle[data-v-0d767c80]{font-size:11px;font-weight:700;color:#22262e}
@@ -1 +1 @@
.van-dialog__confirm,.van-dialog__cancel{display:none!important}.van-dialog__confirm .van-button__text{color:#1c2d56;font-weight:600;font-size:15px}.van-dialog__cancel .van-button__text{color:#6b7280;font-weight:600;font-size:15px}
.van-dialog__confirm,.van-dialog__cancel{display:none!important}.van-dialog__confirm .van-button__text{color:#23493c;font-weight:600;font-size:15px}.van-dialog__cancel .van-button__text{color:#6b7280;font-weight:600;font-size:15px}
@@ -1 +1 @@
import{d as l,x as n,s as r,u as d,ap as c,i as x,b as t,B as o,E as a,t as i}from"./index-BLEa2dU-.js";const f={class:"my-4"},u={class:"w-full flex justify-center"},m={class:"w-full flex justify-center text-[18px] font-semibold"},_={class:"grid grid-cols-2 border-t border-solid border-[#E5E7EB] pt-4 mx-2 mt-6 font-semibold text-[15px]"},g=l({__name:"DialogVant",props:{timeOut:{},text1:{},text2:{},text3:{}},setup(e){return(s,p)=>(x(),n(d(c),null,{default:r(()=>[t("div",f,[t("div",u,[o(s.$slots,"img",{},()=>[a(i(e.text2),1)])]),t("div",m,[o(s.$slots,"title",{},()=>[a(i(e.text1),1)])]),t("div",_,[o(s.$slots,"button",{},()=>[a(i(e.text3),1)])])])]),_:3}))}});export{g as _};
import{d as l,x as n,s as r,u as d,ak as c,i as x,b as t,B as o,E as a,t as i}from"./index-CRQPRp-C.js";const f={class:"my-4"},u={class:"w-full flex justify-center"},m={class:"w-full flex justify-center text-[18px] font-semibold"},_={class:"grid grid-cols-2 border-t border-solid border-[#E5E7EB] pt-4 mx-2 mt-6 font-semibold text-[15px]"},g=l({__name:"DialogVant",props:{timeOut:{},text1:{},text2:{},text3:{}},setup(e){return(s,b)=>(x(),n(d(c),null,{default:r(()=>[t("div",f,[t("div",u,[o(s.$slots,"img",{},()=>[a(i(e.text2),1)])]),t("div",m,[o(s.$slots,"title",{},()=>[a(i(e.text1),1)])]),t("div",_,[o(s.$slots,"button",{},()=>[a(i(e.text3),1)])])])]),_:3}))}});export{g as _};
+1
View File
@@ -0,0 +1 @@
.favs[data-v-d8a6de82]{background:#fff;min-height:100vh}.favs__body[data-v-d8a6de82]{padding-top:76px;padding-bottom:90px}.favs__grid[data-v-d8a6de82]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}.favs__empty[data-v-d8a6de82]{margin-top:8px;padding:38px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.favs__empty p[data-v-d8a6de82]{margin:0;font-size:12.5px}.favs__emptyCta[data-v-d8a6de82]{margin-top:4px;padding:9px 18px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#23493c}
-1
View File
@@ -1 +0,0 @@
.favs[data-v-93bb7c6a]{background:#fff;min-height:100vh}.favs__body[data-v-93bb7c6a]{padding-top:76px;padding-bottom:90px}.favs__grid[data-v-93bb7c6a]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}.favs__empty[data-v-93bb7c6a]{margin-top:8px;padding:38px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.favs__empty p[data-v-93bb7c6a]{margin:0;font-size:12.5px}.favs__emptyCta[data-v-93bb7c6a]{margin-top:4px;padding:9px 18px;border:0;cursor:pointer;border-radius:999px;font-family:inherit;font-size:12.5px;font-weight:700;color:#fff;background:#14161a}
+1
View File
@@ -0,0 +1 @@
import{d as f,o as y,q as g,c as o,k as e,s as c,g as m,i as t,F as p,b as i,r as k,I as b,u as h,f as P,y as C,h as x,v as F,x as B,_ as V}from"./index-CRQPRp-C.js";import{P as w}from"./PageBar-DcURmszD.js";import{a as S}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import{S as I}from"./SectionHead-BjbRzluB.js";import{P as N}from"./ProductCard-wJY0AmTh.js";import{u as $}from"./SingleProduct-DKqhvwd1.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./cartStore-CIlq1T4-.js";import"./index-BVow2xBt.js";import"./classCallCheck-CJTmwORh.js";import"./DialogVant.vue_vue_type_style_index_0_lang-DFKmWR5Z.js";import"./dialogEmpty1-E3h_JfwQ.js";const R={class:"favs"},q={class:"favs__grid"},z={key:1,class:"favs__empty"},E=f({__name:"FavoritesView",setup(H){const d=C(),v=$(),a=m(!1),l=m([]),r=x(()=>l.value.filter(u=>v.isFavorite(u.id)));return y(async()=>{a.value=!0;try{l.value=await g.listProducts()}finally{a.value=!1}}),(u,s)=>{const _=F("container");return t(),o("div",R,[e(w,{title:"علاقه‌مندی","back-to":"userPage::hasSubRoute"}),e(S,{spinning:a.value,tip:"در حال دریافت اطلاعات"},{default:c(()=>[e(_,{class:"favs__body"},{default:c(()=>[r.value.length?(t(),o(p,{key:0},[e(I,{title:"ذخیره‌شده‌ها",subtitle:`${r.value.length} محصول`},null,8,["subtitle"]),i("div",q,[(t(!0),o(p,null,k(r.value,n=>(t(),B(N,{key:n.id,value:n},null,8,["value"]))),128))])],64)):a.value?P("",!0):(t(),o("section",z,[e(b,{icon:"vuesax-linear:heart",size:"26"}),s[1]||(s[1]=i("p",null,"هنوز محصولی را به علاقه‌مندی‌ها اضافه نکرده‌اید.",-1)),i("button",{type:"button",class:"favs__emptyCta",onClick:s[0]||(s[0]=n=>h(d).push({name:"home"}))}," دیدن محصولات ")]))]),_:1})]),_:1},8,["spinning"])])}}}),W=V(E,[["__scopeId","data-v-d8a6de82"]]);export{W as default};
-1
View File
@@ -1 +0,0 @@
import{d as f,o as y,q as b,c as o,k as e,s as c,g as m,i as t,F as p,b as i,r as g,I as k,u as h,f as P,y as C,h as x,v as F,x as B,_ as V}from"./index-BLEa2dU-.js";import{P as w}from"./PageBar-IlBZ6uld.js";import{a as S}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";import{S as I}from"./SectionHead-BA4SOlK7.js";import{P as N}from"./ProductCard-D-GU5P_U.js";import{u as $}from"./SingleProduct-8QiMtS5l.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./cartStore-DfRVSG0q.js";import"./index-DBmNdnBg.js";import"./classCallCheck-BHfqvuTP.js";import"./NotifyVant.vue_vue_type_script_setup_true_lang-1ZprOz0l.js";import"./index-BZfaFJkz.js";import"./DialogVant.vue_vue_type_style_index_0_lang-CV2_T34Y.js";import"./dialogEmpty1-E3h_JfwQ.js";const R={class:"favs"},q={class:"favs__grid"},z={key:1,class:"favs__empty"},E=f({__name:"FavoritesView",setup(H){const d=C(),v=$(),a=m(!1),l=m([]),r=x(()=>l.value.filter(u=>v.isFavorite(u.id)));return y(async()=>{a.value=!0;try{l.value=await b.listProducts()}finally{a.value=!1}}),(u,s)=>{const _=F("container");return t(),o("div",R,[e(w,{title:"علاقه‌مندی","back-to":"userPage::hasSubRoute"}),e(S,{spinning:a.value,tip:"در حال دریافت اطلاعات"},{default:c(()=>[e(_,{class:"favs__body"},{default:c(()=>[r.value.length?(t(),o(p,{key:0},[e(I,{title:"ذخیره‌شده‌ها",subtitle:`${r.value.length} محصول`},null,8,["subtitle"]),i("div",q,[(t(!0),o(p,null,g(r.value,n=>(t(),B(N,{key:n.id,value:n},null,8,["value"]))),128))])],64)):a.value?P("",!0):(t(),o("section",z,[e(k,{icon:"vuesax-linear:heart",size:"26"}),s[1]||(s[1]=i("p",null,"هنوز محصولی را به علاقه‌مندی‌ها اضافه نکرده‌اید.",-1)),i("button",{type:"button",class:"favs__emptyCta",onClick:s[0]||(s[0]=n=>h(d).push({name:"home"}))}," دیدن محصولات ")]))]),_:1})]),_:1},8,["spinning"])])}}}),Y=V(E,[["__scopeId","data-v-93bb7c6a"]]);export{Y as default};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
.otp-single-input{display:flex;align-items:center}.auth[data-v-4db8f481]{background:#fff;min-height:100vh}.auth__body[data-v-4db8f481]{padding-top:86px;padding-bottom:90px}.auth__intro[data-v-4db8f481]{display:flex;flex-direction:column;align-items:center;text-align:center;padding-bottom:24px}.auth__mark[data-v-4db8f481]{width:64px;height:64px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.auth__title[data-v-4db8f481]{margin:14px 0 0;font-size:16px;font-weight:800;color:#14161a}.auth__sub[data-v-4db8f481]{margin:6px 0 0;font-size:12.5px;color:#8a909c}.auth__card[data-v-4db8f481]{padding:18px 16px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.auth__otp[data-v-4db8f481]{display:flex;justify-content:center;gap:10px;direction:ltr;padding-bottom:6px}.auth__timer[data-v-4db8f481]{margin:12px 0 16px;text-align:center;font-size:11.5px;color:#5b616e}.auth__form[data-v-4db8f481] .ant-form-item-label>label{font-size:12px;color:#5b616e}.auth__cta[data-v-4db8f481]{width:100%;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#14161a;transition:transform .15s ease,opacity .15s ease}.auth__cta[data-v-4db8f481]:active{transform:scale(.99)}.auth__cta[data-v-4db8f481]:disabled{opacity:.45;cursor:default}.auth__switch[data-v-4db8f481]{margin:20px 0 0;text-align:center;font-size:12px;color:#5b616e}.auth__switch button[data-v-4db8f481]{border:0;background:none;cursor:pointer;padding:0 3px;font-family:inherit;font-size:12px;font-weight:700;color:#7a1b33}.otp-input{width:48px;height:52px;padding:5px;margin:0;font-size:19px;font-weight:700;color:#14161a;background:#fff;border:1px solid #ECEDEF;border-radius:13px;text-align:center;transition:border-color .18s ease}.otp-input:focus{outline:none;border-color:#14161a}.otp-input.error{border-color:#e31a1a!important}.otp-input::-webkit-inner-spin-button,.otp-input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.auth[data-v-23baea3e]{background:#fff;min-height:100vh}.auth__body[data-v-23baea3e]{padding-top:86px;padding-bottom:90px}.auth__intro[data-v-23baea3e]{display:flex;flex-direction:column;align-items:center;text-align:center;padding-bottom:24px}.auth__mark[data-v-23baea3e]{width:64px;height:64px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.auth__title[data-v-23baea3e]{margin:14px 0 0;font-size:16px;font-weight:800;color:#14161a}.auth__sub[data-v-23baea3e]{margin:6px 0 0;font-size:12.5px;color:#8a909c}.auth__card[data-v-23baea3e]{padding:18px 16px 20px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.auth__form[data-v-23baea3e] .ant-form-item-label>label{font-size:12px;color:#5b616e}.auth__cta[data-v-23baea3e]{width:100%;margin-top:4px;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#14161a;transition:transform .15s ease}.auth__cta[data-v-23baea3e]:active{transform:scale(.99)}.auth__switch[data-v-23baea3e]{margin:20px 0 0;text-align:center;font-size:12px;color:#5b616e}.auth__switch button[data-v-23baea3e]{border:0;background:none;cursor:pointer;padding:0 3px;font-family:inherit;font-size:12px;font-weight:700;color:#7a1b33}
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
.otp-single-input{display:flex;align-items:center}.auth[data-v-5b8d4410]{background:#fff;min-height:100vh}.auth__body[data-v-5b8d4410]{padding-top:86px;padding-bottom:90px}.auth__intro[data-v-5b8d4410]{display:flex;flex-direction:column;align-items:center;text-align:center;padding-bottom:24px}.auth__mark[data-v-5b8d4410]{width:64px;height:64px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.auth__title[data-v-5b8d4410]{margin:14px 0 0;font-size:16px;font-weight:800;color:#14161a}.auth__sub[data-v-5b8d4410]{margin:6px 0 0;font-size:12.5px;color:#8a909c}.auth__card[data-v-5b8d4410]{padding:18px 16px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.auth__otp[data-v-5b8d4410]{display:flex;justify-content:center;gap:10px;direction:ltr;padding-bottom:6px}.auth__timer[data-v-5b8d4410]{margin:12px 0 16px;text-align:center;font-size:11.5px;color:#5b616e}.auth__form[data-v-5b8d4410] .ant-form-item-label>label{font-size:12px;color:#5b616e}.auth__cta[data-v-5b8d4410]{width:100%;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#23493c;transition:transform .15s ease,opacity .15s ease}.auth__cta[data-v-5b8d4410]:active{transform:scale(.99)}.auth__cta[data-v-5b8d4410]:disabled{opacity:.45;cursor:default}.auth__switch[data-v-5b8d4410]{margin:20px 0 0;text-align:center;font-size:12px;color:#5b616e}.auth__switch button[data-v-5b8d4410]{border:0;background:none;cursor:pointer;padding:0 3px;font-family:inherit;font-size:12px;font-weight:700;color:#7a1b33}.otp-input{width:48px;height:52px;padding:5px;margin:0;font-size:19px;font-weight:700;color:#14161a;background:#fff;border:1px solid #ECEDEF;border-radius:13px;text-align:center;transition:border-color .18s ease}.otp-input:focus{outline:none;border-color:#23493c}.otp-input.error{border-color:#e31a1a!important}.otp-input::-webkit-inner-spin-button,.otp-input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.auth[data-v-ea664c0f]{background:#fff;min-height:100vh}.auth__body[data-v-ea664c0f]{padding-top:86px;padding-bottom:90px}.auth__intro[data-v-ea664c0f]{display:flex;flex-direction:column;align-items:center;text-align:center;padding-bottom:24px}.auth__mark[data-v-ea664c0f]{width:64px;height:64px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.auth__title[data-v-ea664c0f]{margin:14px 0 0;font-size:16px;font-weight:800;color:#14161a}.auth__sub[data-v-ea664c0f]{margin:6px 0 0;font-size:12.5px;color:#8a909c}.auth__card[data-v-ea664c0f]{padding:18px 16px 20px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.auth__form[data-v-ea664c0f] .ant-form-item-label>label{font-size:12px;color:#5b616e}.auth__cta[data-v-ea664c0f]{width:100%;margin-top:4px;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;color:#fff;background:#23493c;transition:transform .15s ease}.auth__cta[data-v-ea664c0f]:active{transform:scale(.99)}.auth__switch[data-v-ea664c0f]{margin:20px 0 0;text-align:center;font-size:12px;color:#5b616e}.auth__switch button[data-v-ea664c0f]{border:0;background:none;cursor:pointer;padding:0 3px;font-family:inherit;font-size:12px;font-weight:700;color:#7a1b33}
+1
View File
@@ -0,0 +1 @@
import{P as x}from"./PageBar-DcURmszD.js";import{E as P,a as _}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import{S as k}from"./SectionHead-BjbRzluB.js";import{P as S}from"./ProductCard-wJY0AmTh.js";import{d,i as n,c,k as o,u as l,z as b,A as B,n as E,B as C,x as v,f as y,g as u,q as L,C as A,D as $,s as p,F,r as N,h as V,v as D,_ as I}from"./index-CRQPRp-C.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./SingleProduct-DKqhvwd1.js";import"./DialogVant.vue_vue_type_style_index_0_lang-DFKmWR5Z.js";import"./cartStore-CIlq1T4-.js";import"./dialogEmpty1-E3h_JfwQ.js";import"./index-BVow2xBt.js";import"./classCallCheck-CJTmwORh.js";const z={class:"flex justify-center items-center empty"},H=d({__name:"EmptyState",props:{description:{},image:{}},setup(t){return(e,a)=>(n(),c("div",z,[o(l(P),{description:"موردی یافت نشد",image:t.image,class:"h-[200px] w-[200px] opacity-70"},null,8,["image"])]))}}),T="/assets/favoritEmpty-kbtPAdi5.svg",j=d({__name:"ScrollFetchSearch",props:{loading:{type:Boolean},flag:{type:Boolean},padding:{}},emits:["fetch"],setup(t,{emit:e}){const a=e,r=b(),s=u(null);return B(s,()=>{a("fetch")},{distance:50}),(i,m)=>(n(),c("main",{class:"flex flex-col flex-1 overflow-auto no-scrollbar w-[100vw] max-w-screen-md m-auto",style:E({paddingTop:t.padding||l(r).headerHeight+"px"}),ref_key:"scrollArea",ref:s},[C(i.$slots,"default"),o(_,{cls:"my-[10px]",spinning:t.loading,indicator:!0,tip:"درحال دریافت اطلاعات"},null,8,["spinning"]),t.flag?(n(),v(H,{key:0,image:l(T)},null,8,["image"])):y("",!0)],4))}});function q(){const t=A({totalPages:0,productList:[],flag:!1});return{productsData:t,getProducts:async(a,r=!1)=>{if(!r){a.value=!0;try{t.productList=await L.listProducts(),t.flag=t.productList.length<1}catch(s){console.log(s)}finally{a.value=!1}}}}}const G={class:"newest"},M={key:0,class:"newest__grid"},g=20,Z=d({__name:"NewestView",setup(t){const{productsData:e,getProducts:a}=q(),r=u(!1),s=u(!1),i=u(g),m=V(()=>e.productList.slice(0,i.value));$(async()=>{await a(r,!1)});const h=async()=>{if(i.value<e.productList.length){i.value+=g;return}await a(s,!0)};return(J,K)=>{const w=D("container");return n(),c("div",G,[o(x,{title:"جدیدترین محصولات","back-to":"home"}),o(_,{spinning:r.value,tip:"درحال دریافت اطلاعات"},{default:p(()=>[o(j,{class:"newest__scroll",loading:s.value,flag:l(e).flag,padding:"0px",onFetch:h},{default:p(()=>[o(w,{class:"newest__body"},{default:p(()=>[o(k,{title:"تازه‌ها",subtitle:"آخرین افزوده‌های مجموعه"}),l(e).productList.length?(n(),c("div",M,[(n(!0),c(F,null,N(m.value,f=>(n(),v(S,{key:f.id,value:f},null,8,["value"]))),128))])):y("",!0)]),_:1})]),_:1},8,["loading","flag"])]),_:1},8,["spinning"])])}}}),nt=I(Z,[["__scopeId","data-v-62cb523e"]]);export{nt as default};
-1
View File
@@ -1 +0,0 @@
import{P as x}from"./PageBar-IlBZ6uld.js";import{E as P,a as _}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";import{S as k}from"./SectionHead-BA4SOlK7.js";import{P as S}from"./ProductCard-D-GU5P_U.js";import{d,i as n,c,k as o,u as l,z as b,A as B,n as E,B as C,x as v,f as y,g as u,q as L,C as A,D as $,s as p,F,r as N,h as V,v as D,_ as I}from"./index-BLEa2dU-.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./SingleProduct-8QiMtS5l.js";import"./NotifyVant.vue_vue_type_script_setup_true_lang-1ZprOz0l.js";import"./index-BZfaFJkz.js";import"./DialogVant.vue_vue_type_style_index_0_lang-CV2_T34Y.js";import"./cartStore-DfRVSG0q.js";import"./dialogEmpty1-E3h_JfwQ.js";import"./index-DBmNdnBg.js";import"./classCallCheck-BHfqvuTP.js";const z={class:"flex justify-center items-center empty"},H=d({__name:"EmptyState",props:{description:{},image:{}},setup(t){return(e,a)=>(n(),c("div",z,[o(l(P),{description:"موردی یافت نشد",image:t.image,class:"h-[200px] w-[200px] opacity-70"},null,8,["image"])]))}}),T="/assets/favoritEmpty-kbtPAdi5.svg",j=d({__name:"ScrollFetchSearch",props:{loading:{type:Boolean},flag:{type:Boolean},padding:{}},emits:["fetch"],setup(t,{emit:e}){const a=e,r=b(),s=u(null);return B(s,()=>{a("fetch")},{distance:50}),(i,m)=>(n(),c("main",{class:"flex flex-col flex-1 overflow-auto no-scrollbar w-[100vw] max-w-screen-md m-auto",style:E({paddingTop:t.padding||l(r).headerHeight+"px"}),ref_key:"scrollArea",ref:s},[C(i.$slots,"default"),o(_,{cls:"my-[10px]",spinning:t.loading,indicator:!0,tip:"درحال دریافت اطلاعات"},null,8,["spinning"]),t.flag?(n(),v(H,{key:0,image:l(T)},null,8,["image"])):y("",!0)],4))}});function q(){const t=A({totalPages:0,productList:[],flag:!1});return{productsData:t,getProducts:async(a,r=!1)=>{if(!r){a.value=!0;try{t.productList=await L.listProducts(),t.flag=t.productList.length<1}catch(s){console.log(s)}finally{a.value=!1}}}}}const G={class:"newest"},M={key:0,class:"newest__grid"},g=20,Z=d({__name:"NewestView",setup(t){const{productsData:e,getProducts:a}=q(),r=u(!1),s=u(!1),i=u(g),m=V(()=>e.productList.slice(0,i.value));$(async()=>{await a(r,!1)});const h=async()=>{if(i.value<e.productList.length){i.value+=g;return}await a(s,!0)};return(J,K)=>{const w=D("container");return n(),c("div",G,[o(x,{title:"جدیدترین محصولات","back-to":"home"}),o(_,{spinning:r.value,tip:"درحال دریافت اطلاعات"},{default:p(()=>[o(j,{class:"newest__scroll",loading:s.value,flag:l(e).flag,padding:"0px",onFetch:h},{default:p(()=>[o(w,{class:"newest__body"},{default:p(()=>[o(k,{title:"تازه‌ها",subtitle:"آخرین افزوده‌های مجموعه"}),l(e).productList.length?(n(),c("div",M,[(n(!0),c(F,null,N(m.value,f=>(n(),v(S,{key:f.id,value:f},null,8,["value"]))),128))])):y("",!0)]),_:1})]),_:1},8,["loading","flag"])]),_:1},8,["spinning"])])}}}),it=I(Z,[["__scopeId","data-v-62cb523e"]]);export{it as default};
@@ -1 +1 @@
import{d as a,c as n,k as o,s as i,v as c,i as _,b as e,I as r,_ as p}from"./index-BLEa2dU-.js";import{P as d}from"./PageBar-IlBZ6uld.js";const f={class:"notif"},l={class:"notif__empty"},m=a({__name:"NotificationsView",setup(u){return(v,t)=>{const s=c("container");return _(),n("div",f,[o(d,{title:"اعلان‌ها","back-to":"home"}),o(s,{class:"notif__body"},{default:i(()=>[e("section",l,[o(r,{icon:"vuesax-linear:notification",size:"26"}),t[0]||(t[0]=e("p",null,"اعلانی برای نمایش وجود ندارد.",-1))])]),_:1})])}}}),B=p(m,[["__scopeId","data-v-44d0c9a5"]]);export{B as default};
import{d as a,c as n,k as o,s as i,v as c,i as _,b as e,I as r,_ as p}from"./index-CRQPRp-C.js";import{P as d}from"./PageBar-DcURmszD.js";const f={class:"notif"},l={class:"notif__empty"},m=a({__name:"NotificationsView",setup(u){return(v,t)=>{const s=c("container");return _(),n("div",f,[o(d,{title:"اعلان‌ها","back-to":"home"}),o(s,{class:"notif__body"},{default:i(()=>[e("section",l,[o(r,{icon:"vuesax-linear:notification",size:"26"}),t[0]||(t[0]=e("p",null,"اعلانی برای نمایش وجود ندارد.",-1))])]),_:1})])}}}),B=p(m,[["__scopeId","data-v-44d0c9a5"]]);export{B as default};
@@ -1 +0,0 @@
import{d as m,H as r,i as f,c as h,k as l,u as w,n as x,s as p,b as o,I as y,B as V,E as N,t as v,f as B,g as _}from"./index-BLEa2dU-.js";import{N as k}from"./index-BZfaFJkz.js";const C={key:0,class:"flex"},O={class:"w-full text-white my-2"},S={class:"w-full flex content-end"},E=m({__name:"NotifyVant",props:{modelValue:{type:Boolean},timeOut:{},text:{},color:{}},emits:["update:modelValue"],setup(e,{emit:i}){const s=_(!0),t=e,n=i;r(()=>t.modelValue,()=>{t.timeOut!==-1&&c()});const c=()=>{setTimeout(()=>{n("update:modelValue",!1)},t.timeOut)};return(u,a)=>e.modelValue?(f(),h("div",C,[l(w(k),{show:s.value,"onUpdate:show":a[0]||(a[0]=d=>s.value=d),style:x(e.color)},{default:p(()=>[o("div",O,[o("div",S,[l(y,{icon:"vuesax-linear:info-circle",class:"ml-[20px] text-white",size:"25"}),o("div",null,[V(u.$slots,"default",{},()=>[N(v(e.text),1)])])])])]),_:3},8,["show","style"])])):B("",!0)}});export{E as _};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
import{d as _,c as s,b as a,k as d,I as b,t as u,B as i,i as t,y as p,_ as k}from"./index-BLEa2dU-.js";const h={class:"bar"},f={class:"bar__inner"},B={key:1,class:"bar__spacer","aria-hidden":"true"},m={class:"bar__title"},g={class:"bar__trailing"},y=_({__name:"PageBar",props:{title:{},back:{type:Boolean,default:!0},backTo:{}},setup(e){const o=e,r=p();function l(){o.backTo?r.push({name:o.backTo}):r.back()}return(n,c)=>(t(),s("header",h,[a("div",f,[e.back?(t(),s("button",{key:0,type:"button",class:"bar__btn","aria-label":"بازگشت",onClick:l},[d(b,{icon:"vuesax-linear:arrow-right-1",size:"20"})])):(t(),s("span",B)),a("h1",m,u(e.title),1),a("div",g,[i(n.$slots,"trailing",{},()=>[c[0]||(c[0]=a("span",{class:"bar__spacer","aria-hidden":"true"},null,-1))],!0)])]),i(n.$slots,"below",{},void 0,!0)]))}}),I=k(y,[["__scopeId","data-v-d2d3dfeb"]]);export{I as P};
import{d as _,c as s,b as a,k as d,I as b,t as u,B as i,i as t,y as p,_ as k}from"./index-CRQPRp-C.js";const h={class:"bar"},f={class:"bar__inner"},B={key:1,class:"bar__spacer","aria-hidden":"true"},m={class:"bar__title"},g={class:"bar__trailing"},y=_({__name:"PageBar",props:{title:{},back:{type:Boolean,default:!0},backTo:{}},setup(e){const o=e,r=p();function l(){o.backTo?r.push({name:o.backTo}):r.back()}return(n,c)=>(t(),s("header",h,[a("div",f,[e.back?(t(),s("button",{key:0,type:"button",class:"bar__btn","aria-label":"بازگشت",onClick:l},[d(b,{icon:"vuesax-linear:arrow-right-1",size:"20"})])):(t(),s("span",B)),a("h1",m,u(e.title),1),a("div",g,[i(n.$slots,"trailing",{},()=>[c[0]||(c[0]=a("span",{class:"bar__spacer","aria-hidden":"true"},null,-1))],!0)])]),i(n.$slots,"below",{},void 0,!0)]))}}),I=k(y,[["__scopeId","data-v-d2d3dfeb"]]);export{I as P};
+1
View File
@@ -0,0 +1 @@
.pc[data-v-9d171e3b]{cursor:pointer;background:#fff;border:1px solid #ECEDEF;border-radius:18px;overflow:hidden;transition:transform .2s ease,border-color .2s ease}.pc[data-v-9d171e3b]:active{transform:scale(.985)}.pc__art[data-v-9d171e3b]{position:relative;aspect-ratio:1 / 1;display:flex;align-items:center;justify-content:center;background:#f4f5f6}.pc__art img[data-v-9d171e3b]{width:100%;max-width:150px;height:100%;max-height:150px;-o-object-fit:contain;object-fit:contain;-o-object-position:center;object-position:center;display:block}.pc__artEmpty[data-v-9d171e3b]{width:100%;height:100%;display:grid;place-items:center;color:#8a909c}.pc__fav[data-v-9d171e3b]{position:absolute;top:9px;left:9px;width:30px;height:30px;display:grid;place-items:center;border:0;cursor:pointer;border-radius:50%;color:#5b616e;background:#ffffffe6;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);transition:color .18s ease,transform .18s ease}.pc__fav.is-on[data-v-9d171e3b]{color:#7a1b33}.pc__fav[data-v-9d171e3b]:active{transform:scale(.9)}.pc__flag[data-v-9d171e3b]{position:absolute;top:9px;right:9px;padding:4px 9px;border-radius:999px;font-size:10px;font-weight:700;color:#fff;background:#23493c}.pc__flag--soft[data-v-9d171e3b]{background:#a33c55}.pc__body[data-v-9d171e3b]{padding:11px 12px 13px}.pc__title[data-v-9d171e3b]{margin:0;font-size:13px;font-weight:700;color:#14161a;line-height:1.6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pc__meta[data-v-9d171e3b]{display:flex;align-items:center;gap:7px;padding-top:7px}.pc__weight[data-v-9d171e3b]{font-size:11.5px;font-weight:700;color:#22262e}.pc__wage[data-v-9d171e3b]{font-size:10.5px;color:#8a909c;padding-inline-start:7px;border-inline-start:1px solid #ECEDEF}
-1
View File
@@ -1 +0,0 @@
.pc[data-v-5658bc04]{cursor:pointer;background:#fff;border:1px solid #ECEDEF;border-radius:18px;overflow:hidden;transition:transform .2s ease,border-color .2s ease}.pc[data-v-5658bc04]:active{transform:scale(.985)}.pc__art[data-v-5658bc04]{position:relative;aspect-ratio:1 / 1;display:flex;align-items:center;justify-content:center;background:#f4f5f6}.pc__art img[data-v-5658bc04]{width:100%;max-width:150px;height:100%;max-height:150px;-o-object-fit:contain;object-fit:contain;-o-object-position:center;object-position:center;display:block}.pc__artEmpty[data-v-5658bc04]{width:100%;height:100%;display:grid;place-items:center;color:#8a909c}.pc__fav[data-v-5658bc04]{position:absolute;top:9px;left:9px;width:30px;height:30px;display:grid;place-items:center;border:0;cursor:pointer;border-radius:50%;color:#5b616e;background:#ffffffe6;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);transition:color .18s ease,transform .18s ease}.pc__fav.is-on[data-v-5658bc04]{color:#7a1b33}.pc__fav[data-v-5658bc04]:active{transform:scale(.9)}.pc__flag[data-v-5658bc04]{position:absolute;top:9px;right:9px;padding:4px 9px;border-radius:999px;font-size:10px;font-weight:700;color:#fff;background:#14161a}.pc__flag--soft[data-v-5658bc04]{background:#a33c55}.pc__body[data-v-5658bc04]{padding:11px 12px 13px}.pc__title[data-v-5658bc04]{margin:0;font-size:13px;font-weight:700;color:#14161a;line-height:1.6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pc__meta[data-v-5658bc04]{display:flex;align-items:center;gap:7px;padding-top:7px}.pc__weight[data-v-5658bc04]{font-size:11.5px;font-weight:700;color:#22262e}.pc__wage[data-v-5658bc04]{font-size:10.5px;color:#8a909c;padding-inline-start:7px;border-inline-start:1px solid #ECEDEF}
@@ -1 +1 @@
import{d as D,l as P,i as s,c as i,F as S,b as t,u as e,w as z,k as _,I as f,j as B,e as I,f as d,t as u,s as N,x as V,g as E,h as $,_ as j}from"./index-BLEa2dU-.js";import{u as q,S as L}from"./SingleProduct-8QiMtS5l.js";import{u as M}from"./cartStore-DfRVSG0q.js";import{D as O}from"./index-DBmNdnBg.js";const U={class:"pc__art"},A=["alt"],G={key:1,class:"pc__artEmpty","aria-hidden":"true"},H=["aria-label"],J={key:2,class:"pc__flag"},K={key:3,class:"pc__flag pc__flag--soft"},Q={class:"pc__body"},R={class:"pc__title"},T={class:"pc__meta"},W={class:"pc__weight"},X={key:0,class:"pc__wage"},Y=D({__name:"ProductCard",props:{value:{}},setup(g){const h=g,n=q(),{image:p,id:a,title:v,min_gram:y,wage:m,is_exist:b,qty:k,isPreOrder:w}=M(h.value),l=E(!1);function x(){l.value=!0}const C=$(()=>{const r=m.value;return r==null?"":r%1===0?String(r):r.toFixed(2)});return(r,o)=>{const F=P("lazy");return s(),i(S,null,[t("article",{class:"pc",onClick:x},[t("div",U,[e(p)?z((s(),i("img",{key:0,alt:e(v)},null,8,A)),[[F,e(p)]]):(s(),i("div",G,[_(f,{icon:"vuesax-linear:diamonds",size:"26"})])),t("button",{type:"button",class:I(["pc__fav",{"is-on":e(n).isFavorite(e(a))}]),"aria-label":e(n).isFavorite(e(a))?"حذف از علاقه‌مندی":"افزودن به علاقه‌مندی",onClick:o[0]||(o[0]=B(c=>e(n).toggle(e(a)),["stop"]))},[_(f,{icon:e(n).isFavorite(e(a))?"vuesax-linear:heart-fill":"vuesax-linear:heart",size:"16"},null,8,["icon"])],10,H),e(b)?e(w)&&e(k)===0?(s(),i("span",K,"پیش‌سفارش")):d("",!0):(s(),i("span",J,"ناموجود"))]),t("div",Q,[t("h3",R,u(e(v)),1),t("div",T,[t("span",W,u(e(y))+" گرم",1),e(m)!=null?(s(),i("span",X,"اجرت "+u(C.value)+"٪",1)):d("",!0)])])]),_(e(O),{visible:l.value,"onUpdate:visible":o[2]||(o[2]=c=>l.value=c),placement:"bottom",closable:!1,class:"rtl",height:"100vh",bodyStyle:{padding:0,position:"relative"}},{default:N(()=>[l.value?(s(),V(L,{id:e(a),key:e(a),onCloseDrawer:o[1]||(o[1]=c=>l.value=!1)},null,8,["id"])):d("",!0)]),_:1},8,["visible"])],64)}}}),ae=j(Y,[["__scopeId","data-v-5658bc04"]]);export{ae as P};
import{d as D,l as P,i as s,c as i,F as S,b as t,u as e,w as z,k as _,I as f,j as B,e as I,f as d,t as u,s as N,x as V,g as E,h as $,_ as j}from"./index-CRQPRp-C.js";import{u as q,S as L}from"./SingleProduct-DKqhvwd1.js";import{u as M}from"./cartStore-CIlq1T4-.js";import{D as O}from"./index-BVow2xBt.js";const U={class:"pc__art"},A=["alt"],G={key:1,class:"pc__artEmpty","aria-hidden":"true"},H=["aria-label"],J={key:2,class:"pc__flag"},K={key:3,class:"pc__flag pc__flag--soft"},Q={class:"pc__body"},R={class:"pc__title"},T={class:"pc__meta"},W={class:"pc__weight"},X={key:0,class:"pc__wage"},Y=D({__name:"ProductCard",props:{value:{}},setup(g){const h=g,n=q(),{image:p,id:a,title:v,min_gram:y,wage:m,is_exist:b,qty:k,isPreOrder:w}=M(h.value),l=E(!1);function x(){l.value=!0}const C=$(()=>{const r=m.value;return r==null?"":r%1===0?String(r):r.toFixed(2)});return(r,o)=>{const F=P("lazy");return s(),i(S,null,[t("article",{class:"pc",onClick:x},[t("div",U,[e(p)?z((s(),i("img",{key:0,alt:e(v)},null,8,A)),[[F,e(p)]]):(s(),i("div",G,[_(f,{icon:"vuesax-linear:diamonds",size:"26"})])),t("button",{type:"button",class:I(["pc__fav",{"is-on":e(n).isFavorite(e(a))}]),"aria-label":e(n).isFavorite(e(a))?"حذف از علاقه‌مندی":"افزودن به علاقه‌مندی",onClick:o[0]||(o[0]=B(c=>e(n).toggle(e(a)),["stop"]))},[_(f,{icon:e(n).isFavorite(e(a))?"vuesax-linear:heart-fill":"vuesax-linear:heart",size:"16"},null,8,["icon"])],10,H),e(b)?e(w)&&e(k)===0?(s(),i("span",K,"پیش‌سفارش")):d("",!0):(s(),i("span",J,"ناموجود"))]),t("div",Q,[t("h3",R,u(e(v)),1),t("div",T,[t("span",W,u(e(y))+" گرم",1),e(m)!=null?(s(),i("span",X,"اجرت "+u(C.value)+"٪",1)):d("",!0)])])]),_(e(O),{visible:l.value,"onUpdate:visible":o[2]||(o[2]=c=>l.value=c),placement:"bottom",closable:!1,class:"rtl",height:"100vh",bodyStyle:{padding:0,position:"relative"}},{default:N(()=>[l.value?(s(),V(L,{id:e(a),key:e(a),onCloseDrawer:o[1]||(o[1]=c=>l.value=!1)},null,8,["id"])):d("",!0)]),_:1},8,["visible"])],64)}}}),ae=j(Y,[["__scopeId","data-v-9d171e3b"]]);export{ae as P};
+1
View File
@@ -0,0 +1 @@
.prof[data-v-59a26b98]{background:#fff;min-height:100vh}.prof__body[data-v-59a26b98]{padding-top:80px;padding-bottom:90px}.prof__identity[data-v-59a26b98]{display:flex;flex-direction:column;align-items:center;text-align:center;padding:26px 20px 28px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.prof__avatar[data-v-59a26b98]{width:72px;height:72px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.prof__name[data-v-59a26b98]{margin:14px 0 0;font-size:15.5px;font-weight:800;color:#14161a}.prof__mobile[data-v-59a26b98]{margin:6px 0 0;font-size:12.5px;color:#5b616e;direction:ltr}.prof__seal[data-v-59a26b98]{margin-top:12px;padding:5px 12px;border-radius:999px;font-size:11px;font-weight:700}.prof__seal.is-ok[data-v-59a26b98]{color:#16a34a;background:#f0fdf4}.prof__seal.is-pending[data-v-59a26b98]{color:#7a1b33;background:#fbf2f4}.prof__block[data-v-59a26b98]{margin-top:26px}.prof__specs[data-v-59a26b98]{margin:0;border:1px solid #ECEDEF;border-radius:18px;overflow:hidden}.prof__spec[data-v-59a26b98]{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:13px 14px;border-bottom:1px solid #F4F5F6}.prof__spec[data-v-59a26b98]:last-child{border-bottom:0}.prof__spec dt[data-v-59a26b98]{margin:0;font-size:12px;color:#8a909c}.prof__spec dd[data-v-59a26b98]{margin:0;font-size:12.5px;font-weight:700;color:#14161a;text-align:left}.prof__empty[data-v-59a26b98]{margin-top:26px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.prof__empty p[data-v-59a26b98]{margin:0;font-size:12.5px}.prof__complete[data-v-59a26b98]{margin-top:20px;width:100%;padding:14px;border:none;border-radius:14px;background:#23493c;color:#fff;font-family:inherit;font-size:15px;font-weight:700;cursor:pointer}
@@ -1 +1 @@
import{d as y,G as k,o as T,q as b,c as l,k as i,s as V,g as d,v as P,i as n,b as e,I as p,t as a,f as r,e as g,u as B,h as f,y as C,_ as D}from"./index-BLEa2dU-.js";import{P as N}from"./PageBar-IlBZ6uld.js";import{S as h}from"./SectionHead-BA4SOlK7.js";const R={class:"prof"},x={class:"prof__identity"},F={class:"prof__avatar","aria-hidden":"true"},M={class:"prof__name"},w={key:0,class:"prof__mobile"},O={key:0,class:"prof__block"},U={class:"prof__specs"},z={class:"prof__spec"},L={class:"prof__spec"},A={class:"prof__spec"},W={class:"prof__spec"},q={key:1,class:"prof__empty"},G=y({__name:"ProfileView",setup(H){const _={UNVERIFIED:"احراز نشده",STEP_ONE_SUBMITTED:"مرحله اول ثبت شده",STEP_TWO_SUBMITTED:"مرحله دوم ثبت شده",VERIFIED:"تایید شده"},v=k(),s=d(null),u=d(!1),m=f(()=>{var t;return((t=s.value)==null?void 0:t.verificationStep)==="VERIFIED"}),S=f(()=>{var o;const t=(o=s.value)==null?void 0:o.verificationStep;return!!t&&t!=="VERIFIED"&&t!=="STEP_TWO_SUBMITTED"}),E=C();return T(async()=>{if(v.isLoggedIn){u.value=!0;try{s.value=await b.getMe()}finally{u.value=!1}}}),(t,o)=>{const I=P("container");return n(),l("div",R,[i(N,{title:"اطلاعات کاربری","back-to":"userPage::hasSubRoute"}),i(I,{class:"prof__body"},{default:V(()=>{var c;return[e("section",x,[e("div",F,[i(p,{icon:"vuesax-linear:user",size:"30"})]),e("h2",M,a(((c=s.value)==null?void 0:c.fullName)??"—"),1),s.value?(n(),l("p",w,a(s.value.mobile),1)):r("",!0),s.value?(n(),l("span",{key:1,class:g(["prof__seal",m.value?"is-ok":"is-pending"])},a(_[s.value.verificationStep]??s.value.verificationStep),3)):r("",!0)]),s.value?(n(),l("section",O,[i(h,{title:"مشخصات",subtitle:"اطلاعات ثبت‌شده حساب شما"}),e("dl",U,[e("div",z,[o[1]||(o[1]=e("dt",null,"نام و نام خانوادگی",-1)),e("dd",null,a(s.value.fullName),1)]),e("div",L,[o[2]||(o[2]=e("dt",null,"تلفن همراه",-1)),e("dd",null,a(s.value.mobile),1)]),e("div",A,[o[3]||(o[3]=e("dt",null,"کد ملی",-1)),e("dd",null,a(s.value.nationalCode),1)]),e("div",W,[o[4]||(o[4]=e("dt",null,"وضعیت احراز هویت",-1)),e("dd",null,a(_[s.value.verificationStep]??s.value.verificationStep),1)])])])):u.value?r("",!0):(n(),l("section",q,[i(p,{icon:"vuesax-linear:user",size:"26"}),o[5]||(o[5]=e("p",null,"اطلاعات حساب در دسترس نیست.",-1))])),S.value?(n(),l("button",{key:2,type:"button",class:"prof__complete",onClick:o[0]||(o[0]=$=>B(E).push({name:"completeProfile"}))}," تکمیل پروفایل ")):r("",!0)]}),_:1})])}}}),Q=D(G,[["__scopeId","data-v-0d7f9f64"]]);export{Q as default};
import{d as y,G as b,o as k,q as T,c as l,k as i,s as V,g as p,v as P,i as n,b as e,I as d,t as a,f as r,e as g,u as B,h as f,y as C,_ as D}from"./index-CRQPRp-C.js";import{P as N}from"./PageBar-DcURmszD.js";import{S as h}from"./SectionHead-BjbRzluB.js";const R={class:"prof"},x={class:"prof__identity"},F={class:"prof__avatar","aria-hidden":"true"},M={class:"prof__name"},w={key:0,class:"prof__mobile"},O={key:0,class:"prof__block"},U={class:"prof__specs"},z={class:"prof__spec"},L={class:"prof__spec"},A={class:"prof__spec"},W={class:"prof__spec"},q={key:1,class:"prof__empty"},G=y({__name:"ProfileView",setup(H){const _={UNVERIFIED:"احراز نشده",STEP_ONE_SUBMITTED:"مرحله اول ثبت شده",STEP_TWO_SUBMITTED:"مرحله دوم ثبت شده",VERIFIED:"تایید شده"},v=b(),s=p(null),u=p(!1),m=f(()=>{var t;return((t=s.value)==null?void 0:t.verificationStep)==="VERIFIED"}),S=f(()=>{var o;const t=(o=s.value)==null?void 0:o.verificationStep;return!!t&&t!=="VERIFIED"&&t!=="STEP_TWO_SUBMITTED"}),E=C();return k(async()=>{if(v.isLoggedIn){u.value=!0;try{s.value=await T.getMe()}finally{u.value=!1}}}),(t,o)=>{const I=P("container");return n(),l("div",R,[i(N,{title:"اطلاعات کاربری","back-to":"userPage::hasSubRoute"}),i(I,{class:"prof__body"},{default:V(()=>{var c;return[e("section",x,[e("div",F,[i(d,{icon:"vuesax-linear:user",size:"30"})]),e("h2",M,a(((c=s.value)==null?void 0:c.fullName)??"—"),1),s.value?(n(),l("p",w,a(s.value.mobile),1)):r("",!0),s.value?(n(),l("span",{key:1,class:g(["prof__seal",m.value?"is-ok":"is-pending"])},a(_[s.value.verificationStep]??s.value.verificationStep),3)):r("",!0)]),s.value?(n(),l("section",O,[i(h,{title:"مشخصات",subtitle:"اطلاعات ثبت‌شده حساب شما"}),e("dl",U,[e("div",z,[o[1]||(o[1]=e("dt",null,"نام و نام خانوادگی",-1)),e("dd",null,a(s.value.fullName),1)]),e("div",L,[o[2]||(o[2]=e("dt",null,"تلفن همراه",-1)),e("dd",null,a(s.value.mobile),1)]),e("div",A,[o[3]||(o[3]=e("dt",null,"کد ملی",-1)),e("dd",null,a(s.value.nationalCode),1)]),e("div",W,[o[4]||(o[4]=e("dt",null,"وضعیت احراز هویت",-1)),e("dd",null,a(_[s.value.verificationStep]??s.value.verificationStep),1)])])])):u.value?r("",!0):(n(),l("section",q,[i(d,{icon:"vuesax-linear:user",size:"26"}),o[5]||(o[5]=e("p",null,"اطلاعات حساب در دسترس نیست.",-1))])),S.value?(n(),l("button",{key:2,type:"button",class:"prof__complete",onClick:o[0]||(o[0]=$=>B(E).push({name:"completeProfile"}))}," تکمیل پروفایل ")):r("",!0)]}),_:1})])}}}),Q=D(G,[["__scopeId","data-v-59a26b98"]]);export{Q as default};
-1
View File
@@ -1 +0,0 @@
.prof[data-v-0d7f9f64]{background:#fff;min-height:100vh}.prof__body[data-v-0d7f9f64]{padding-top:80px;padding-bottom:90px}.prof__identity[data-v-0d7f9f64]{display:flex;flex-direction:column;align-items:center;text-align:center;padding:26px 20px 28px;border:1px solid #ECEDEF;border-radius:20px;background:#fafafa}.prof__avatar[data-v-0d7f9f64]{width:72px;height:72px;border-radius:50%;display:grid;place-items:center;color:#7a1b33;background:#fbf2f4}.prof__name[data-v-0d7f9f64]{margin:14px 0 0;font-size:15.5px;font-weight:800;color:#14161a}.prof__mobile[data-v-0d7f9f64]{margin:6px 0 0;font-size:12.5px;color:#5b616e;direction:ltr}.prof__seal[data-v-0d7f9f64]{margin-top:12px;padding:5px 12px;border-radius:999px;font-size:11px;font-weight:700}.prof__seal.is-ok[data-v-0d7f9f64]{color:#16a34a;background:#f0fdf4}.prof__seal.is-pending[data-v-0d7f9f64]{color:#7a1b33;background:#fbf2f4}.prof__block[data-v-0d7f9f64]{margin-top:26px}.prof__specs[data-v-0d7f9f64]{margin:0;border:1px solid #ECEDEF;border-radius:18px;overflow:hidden}.prof__spec[data-v-0d7f9f64]{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:13px 14px;border-bottom:1px solid #F4F5F6}.prof__spec[data-v-0d7f9f64]:last-child{border-bottom:0}.prof__spec dt[data-v-0d7f9f64]{margin:0;font-size:12px;color:#8a909c}.prof__spec dd[data-v-0d7f9f64]{margin:0;font-size:12.5px;font-weight:700;color:#14161a;text-align:left}.prof__empty[data-v-0d7f9f64]{margin-top:26px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.prof__empty p[data-v-0d7f9f64]{margin:0;font-size:12.5px}.prof__complete[data-v-0d7f9f64]{margin-top:20px;width:100%;padding:14px;border:none;border-radius:14px;background:#14161a;color:#fff;font-family:inherit;font-size:15px;font-weight:700;cursor:pointer}
@@ -1 +1 @@
import{p as c,j as d}from"./filters-CLL9nGZ2.js";import{d as u,c as s,e as _,b as a,E as l,t as i,u as n,f as m,h as v,i as r,_ as q}from"./index-BLEa2dU-.js";const f={key:0,class:"rate-strip__value"},k={class:"rate-strip__num"},y={key:1,class:"rate-strip__value rate-strip__value--muted"},x={key:2,class:"rate-strip__time"},R=u({__name:"RateStrip",props:{quote:{}},setup(t){const o=t,p=v(()=>o.quote?o.quote.pricePerGramRial.split(".")[0]:"");return(b,e)=>(r(),s("div",{class:_(["rate-strip",{"is-empty":!t.quote}])},[e[1]||(e[1]=a("div",{class:"rate-strip__label"},[a("span",{class:"rate-strip__dot","aria-hidden":"true"}),l(" نرخ طلای ۱۸ عیار ")],-1)),t.quote?(r(),s("div",f,[a("span",k,i(n(c)(p.value)),1),e[0]||(e[0]=a("span",{class:"rate-strip__unit"},"ریال / گرم",-1))])):(r(),s("div",y,"در انتظار اعلام نرخ")),t.quote?(r(),s("div",x,i(n(d)(t.quote.quotedAt)),1)):m("",!0)],2))}}),C=q(R,[["__scopeId","data-v-16b4c8d5"]]);export{C as R};
import{p as c,j as d}from"./filters-CLL9nGZ2.js";import{d as u,c as s,e as _,b as a,E as l,t as i,u as n,f as m,h as v,i as r,_ as f}from"./index-CRQPRp-C.js";const q={key:0,class:"rate-strip__value"},k={class:"rate-strip__num"},y={key:1,class:"rate-strip__value rate-strip__value--muted"},x={key:2,class:"rate-strip__time"},R=u({__name:"RateStrip",props:{quote:{}},setup(t){const o=t,p=v(()=>o.quote?o.quote.pricePerGramRial.split(".")[0]:"");return(b,e)=>(r(),s("div",{class:_(["rate-strip",{"is-empty":!t.quote}])},[e[1]||(e[1]=a("div",{class:"rate-strip__label"},[a("span",{class:"rate-strip__dot","aria-hidden":"true"}),l(" نرخ طلای ۱۸ عیار ")],-1)),t.quote?(r(),s("div",q,[a("span",k,i(n(c)(p.value)),1),e[0]||(e[0]=a("span",{class:"rate-strip__unit"},"ریال / گرم",-1))])):(r(),s("div",y,"در انتظار اعلام نرخ")),t.quote?(r(),s("div",x,i(n(d)(t.quote.quotedAt)),1)):m("",!0)],2))}}),C=f(R,[["__scopeId","data-v-f23116bf"]]);export{C as R};
-1
View File
@@ -1 +0,0 @@
.rate-strip[data-v-16b4c8d5]{display:flex;align-items:center;gap:10px;padding:10px 14px;border-radius:14px;background:#14161a;color:#fff;box-shadow:0 10px 24px -18px #14161ae6}.rate-strip__label[data-v-16b4c8d5]{display:flex;align-items:center;gap:7px;font-size:12px;color:#ffffffad;white-space:nowrap}.rate-strip__dot[data-v-16b4c8d5]{width:6px;height:6px;border-radius:50%;background:#a33c55;box-shadow:0 0 #a33c55a6;animation:ratePulse-16b4c8d5 2.4s ease-out infinite}.rate-strip__value[data-v-16b4c8d5]{margin-inline-start:auto;display:flex;align-items:baseline;gap:5px}.rate-strip__value--muted[data-v-16b4c8d5]{font-size:12px;color:#ffffff8c}.rate-strip__num[data-v-16b4c8d5]{font-size:16px;font-weight:700;letter-spacing:.2px}.rate-strip__unit[data-v-16b4c8d5]{font-size:10.5px;color:#ffffff8c}.rate-strip__time[data-v-16b4c8d5]{font-size:10.5px;color:#ffffff6b;padding-inline-start:10px;border-inline-start:1px solid rgba(255,255,255,.14);white-space:nowrap}@keyframes ratePulse-16b4c8d5{0%{box-shadow:0 0 #a33c5599}70%{box-shadow:0 0 0 7px #a33c5500}to{box-shadow:0 0 #a33c5500}}
+1
View File
@@ -0,0 +1 @@
.rate-strip[data-v-f23116bf]{display:flex;align-items:center;gap:10px;padding:10px 14px;border-radius:14px;background:#23493c;color:#fff;box-shadow:0 10px 24px -18px #14161ae6}.rate-strip__label[data-v-f23116bf]{display:flex;align-items:center;gap:7px;font-size:12px;color:#ffffffad;white-space:nowrap}.rate-strip__dot[data-v-f23116bf]{width:6px;height:6px;border-radius:50%;background:#a33c55;box-shadow:0 0 #a33c55a6;animation:ratePulse-f23116bf 2.4s ease-out infinite}.rate-strip__value[data-v-f23116bf]{margin-inline-start:auto;display:flex;align-items:baseline;gap:5px}.rate-strip__value--muted[data-v-f23116bf]{font-size:12px;color:#ffffff8c}.rate-strip__num[data-v-f23116bf]{font-size:16px;font-weight:700;letter-spacing:.2px}.rate-strip__unit[data-v-f23116bf]{font-size:10.5px;color:#ffffff8c}.rate-strip__time[data-v-f23116bf]{font-size:10.5px;color:#ffffff6b;padding-inline-start:10px;border-inline-start:1px solid rgba(255,255,255,.14);white-space:nowrap}@keyframes ratePulse-f23116bf{0%{box-shadow:0 0 #a33c5599}70%{box-shadow:0 0 0 7px #a33c5500}to{box-shadow:0 0 #a33c5500}}
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
.doc[data-v-6b6d3f11]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.doc__head[data-v-6b6d3f11]{display:flex;justify-content:space-between;gap:10px;margin-bottom:12px;font-size:13px;font-weight:600}.doc__muted[data-v-6b6d3f11]{color:#5b616e;font-weight:500;margin-left:4px}.doc__rows[data-v-6b6d3f11]{margin:0;display:flex;flex-direction:column;gap:2px}.doc__row[data-v-6b6d3f11]{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;background:#fafafa;border-radius:10px}.doc__row dt[data-v-6b6d3f11]{font-size:12.5px;color:#5b616e;white-space:nowrap}.doc__row dd[data-v-6b6d3f11]{margin:0;font-size:13.5px;font-weight:600;text-align:left}.doc__gold[data-v-6b6d3f11]{display:flex;justify-content:space-between;align-items:center;margin-top:8px;padding:10px 12px;background:#f4f5f6;border-radius:10px;font-size:13px;font-weight:700}.doc__stack[data-v-6b6d3f11]{display:flex;flex-direction:column;align-items:flex-end;gap:2px}.is-in[data-v-6b6d3f11]{color:#16a34a}.is-out[data-v-6b6d3f11]{color:#dc2626}.rep__tabs[data-v-69dba3f6]{display:flex;gap:8px;padding:0 16px 12px}.rep__tab[data-v-69dba3f6]{flex:1;padding:10px;border:1px solid #ECEDEF;border-radius:999px;background:#fff;font-family:inherit;font-size:13px;font-weight:600;color:#5b616e;cursor:pointer}.rep__tab.is-on[data-v-69dba3f6]{background:#14161a;border-color:#14161a;color:#fff}.rep__body[data-v-69dba3f6]{padding-top:132px;padding-bottom:90px}.rep__list[data-v-69dba3f6]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.rep__card[data-v-69dba3f6]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.rep__head[data-v-69dba3f6]{display:flex;justify-content:space-between;gap:10px;margin-bottom:12px;font-size:13px;font-weight:600}.rep__muted[data-v-69dba3f6]{color:#5b616e;font-weight:500;margin-left:4px}.rep__pair[data-v-69dba3f6]{display:flex;justify-content:space-between;align-items:center;padding:9px 12px;margin-bottom:6px;background:#fafafa;border-radius:10px;font-size:13px}.rep__pair.is-balance[data-v-69dba3f6]{background:#f4f5f6;font-weight:700}.rep__stack[data-v-69dba3f6]{display:flex;flex-direction:column;align-items:flex-end;gap:2px;font-weight:600}.is-in[data-v-69dba3f6]{color:#16a34a}.is-out[data-v-69dba3f6]{color:#dc2626}.rep__more[data-v-69dba3f6],.rep__sentinel[data-v-69dba3f6]{padding:12px 0;text-align:center;font-size:12px;color:#5b616e}.rep__more[data-v-69dba3f6]{width:100%;margin-top:4px;border:none;background:transparent;font-family:inherit;font-weight:700;color:#7a1b33;cursor:pointer}.rep__empty[data-v-69dba3f6]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.rep__retry[data-v-69dba3f6]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.rep__modal[data-v-69dba3f6]{padding:20px 16px 24px}.rep__modalEmpty[data-v-69dba3f6]{padding:24px 0;text-align:center;font-size:13px;color:#5b616e}.rep__close[data-v-69dba3f6]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#14161a;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
.doc[data-v-6b6d3f11]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.doc__head[data-v-6b6d3f11]{display:flex;justify-content:space-between;gap:10px;margin-bottom:12px;font-size:13px;font-weight:600}.doc__muted[data-v-6b6d3f11]{color:#5b616e;font-weight:500;margin-left:4px}.doc__rows[data-v-6b6d3f11]{margin:0;display:flex;flex-direction:column;gap:2px}.doc__row[data-v-6b6d3f11]{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;background:#fafafa;border-radius:10px}.doc__row dt[data-v-6b6d3f11]{font-size:12.5px;color:#5b616e;white-space:nowrap}.doc__row dd[data-v-6b6d3f11]{margin:0;font-size:13.5px;font-weight:600;text-align:left}.doc__gold[data-v-6b6d3f11]{display:flex;justify-content:space-between;align-items:center;margin-top:8px;padding:10px 12px;background:#f4f5f6;border-radius:10px;font-size:13px;font-weight:700}.doc__stack[data-v-6b6d3f11]{display:flex;flex-direction:column;align-items:flex-end;gap:2px}.is-in[data-v-6b6d3f11]{color:#16a34a}.is-out[data-v-6b6d3f11]{color:#dc2626}.rep__tabs[data-v-c08e549f]{display:flex;gap:8px;padding:0 16px 12px}.rep__tab[data-v-c08e549f]{flex:1;padding:10px;border:1px solid #ECEDEF;border-radius:999px;background:#fff;font-family:inherit;font-size:13px;font-weight:600;color:#5b616e;cursor:pointer}.rep__tab.is-on[data-v-c08e549f]{background:#23493c;border-color:#23493c;color:#fff}.rep__body[data-v-c08e549f]{padding-top:132px;padding-bottom:90px}.rep__list[data-v-c08e549f]{display:flex;flex-direction:column;padding-top:16px;gap:11px}.rep__card[data-v-c08e549f]{padding:16px;background:#fff;border:1px solid #ECEDEF;border-radius:18px}.rep__head[data-v-c08e549f]{display:flex;justify-content:space-between;gap:10px;margin-bottom:12px;font-size:13px;font-weight:600}.rep__muted[data-v-c08e549f]{color:#5b616e;font-weight:500;margin-left:4px}.rep__pair[data-v-c08e549f]{display:flex;justify-content:space-between;align-items:center;padding:9px 12px;margin-bottom:6px;background:#fafafa;border-radius:10px;font-size:13px}.rep__pair.is-balance[data-v-c08e549f]{background:#f4f5f6;font-weight:700}.rep__stack[data-v-c08e549f]{display:flex;flex-direction:column;align-items:flex-end;gap:2px;font-weight:600}.is-in[data-v-c08e549f]{color:#16a34a}.is-out[data-v-c08e549f]{color:#dc2626}.rep__more[data-v-c08e549f],.rep__sentinel[data-v-c08e549f]{padding:12px 0;text-align:center;font-size:12px;color:#5b616e}.rep__more[data-v-c08e549f]{width:100%;margin-top:4px;border:none;background:transparent;font-family:inherit;font-weight:700;color:#7a1b33;cursor:pointer}.rep__empty[data-v-c08e549f]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#5b616e;font-size:13px}.rep__retry[data-v-c08e549f]{padding:8px 18px;border-radius:999px;border:1px solid #ECEDEF;background:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}.rep__modal[data-v-c08e549f]{padding:20px 16px 24px}.rep__modalEmpty[data-v-c08e549f]{padding:24px 0;text-align:center;font-size:13px;color:#5b616e}.rep__close[data-v-c08e549f]{margin-top:18px;width:100%;padding:13px;border:none;border-radius:14px;background:#23493c;color:#fff;font-family:inherit;font-size:14px;font-weight:700;cursor:pointer}
@@ -1 +1 @@
import{d as v,aa as h,H as m,i as t,c as l,k as n,I as r,w as f,ab as b,b as k,ac as x,f as C,C as I,g as w,_ as y}from"./index-BLEa2dU-.js";const S={class:"si"},V=["placeholder"],B=v({__name:"SearchInput",props:{placeHolder:{}},emits:["search"],setup(i,{emit:d}){const c=d,a=I({clear:!1}),e=w(void 0),s=()=>{c("search",e.value)},u=()=>{e.value=void 0,a.clear=!1,c("search",void 0)},p=h(e,700);return m(p,()=>{e?a.clear=!0:a.clear=!1,s()}),(H,o)=>(t(),l("div",S,[n(r,{icon:"vuesax-linear:search-normal-1",class:"si__icon",size:"18",onClick:s}),f(k("input",{"onUpdate:modelValue":o[0]||(o[0]=_=>e.value=_),class:"si__input",placeholder:i.placeHolder,onKeyup:x(s,["enter"])},null,40,V),[[b,e.value]]),a.clear?(t(),l("button",{key:0,type:"button",class:"si__clear","aria-label":"پاک کردن",onClick:u},[n(r,{icon:"vuesax-linear:add",size:"16"})])):C("",!0)]))}}),z=y(B,[["__scopeId","data-v-4c50067a"]]);export{z as S};
import{d as v,a5 as h,H as m,i as t,c as l,k as n,I as r,w as f,a6 as b,b as k,a7 as x,f as C,C as I,g as w,_ as y}from"./index-CRQPRp-C.js";const S={class:"si"},V=["placeholder"],B=v({__name:"SearchInput",props:{placeHolder:{}},emits:["search"],setup(i,{emit:d}){const c=d,a=I({clear:!1}),e=w(void 0),s=()=>{c("search",e.value)},u=()=>{e.value=void 0,a.clear=!1,c("search",void 0)},p=h(e,700);return m(p,()=>{e?a.clear=!0:a.clear=!1,s()}),(H,o)=>(t(),l("div",S,[n(r,{icon:"vuesax-linear:search-normal-1",class:"si__icon",size:"18",onClick:s}),f(k("input",{"onUpdate:modelValue":o[0]||(o[0]=_=>e.value=_),class:"si__input",placeholder:i.placeHolder,onKeyup:x(s,["enter"])},null,40,V),[[b,e.value]]),a.clear?(t(),l("button",{key:0,type:"button",class:"si__clear","aria-label":"پاک کردن",onClick:u},[n(r,{icon:"vuesax-linear:add",size:"16"})])):C("",!0)]))}}),z=y(B,[["__scopeId","data-v-4c50067a"]]);export{z as S};
File diff suppressed because one or more lines are too long
-1
View File
@@ -1 +0,0 @@
.dd[data-v-9e57de56]{padding:15px;border:1px solid #ECEDEF;border-radius:16px;background:#fff}.dd.is-open[data-v-9e57de56]{border-color:#a33c55}.dd__head[data-v-9e57de56]{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;border:0;padding:0;cursor:pointer;background:none;font-family:inherit;text-align:start}.dd__title[data-v-9e57de56]{margin:0;font-size:13px;font-weight:700;color:#14161a}.dd__chevron[data-v-9e57de56]{flex:0 0 auto;color:#8a909c;transition:transform .2s ease}.dd.is-open .dd__chevron[data-v-9e57de56]{transform:rotate(180deg);color:#7a1b33}.dd__body[data-v-9e57de56]{overflow:hidden;padding-top:15px}.drop-enter-active{animation:drop .2s cubic-bezier(.33,1,.68,1)}.drop-leave-to{animation:drop .2s cubic-bezier(.33,1,.68,1) reverse}@keyframes drop{0%{max-height:0}to{max-height:240px}}.filt[data-v-9651e9da]{background:#fff;min-height:100vh}.filt__body[data-v-9651e9da]{max-width:768px;margin:0 auto;padding:120px 16px 110px;display:flex;flex-direction:column;gap:12px}.filt__chips[data-v-9651e9da]{display:flex;flex-wrap:wrap;gap:8px}.filt__chip[data-v-9651e9da]{padding:8px 14px;border-radius:999px;cursor:pointer;font-family:inherit;font-size:12px;font-weight:600;color:#22262e;background:#fff;border:1px solid #ECEDEF;transition:all .2s ease}.filt__chip.is-on[data-v-9651e9da]{color:#fff;background:#14161a;border-color:#14161a}.filt__chip[data-v-9651e9da]:active{transform:scale(.97)}.filt__empty[data-v-9651e9da]{margin:0;font-size:12px;color:#8a909c}.filt__gram[data-v-9651e9da]{padding:4px 6px 0}.filt__gram[data-v-9651e9da] .ant-slider-track{background-color:#7a1b33}.filt__gram[data-v-9651e9da] .ant-slider-handle{border-color:#7a1b33}.filt__gram[data-v-9651e9da] .ant-slider-rail{background-color:#ecedef}.filt__gramFigures[data-v-9651e9da]{display:flex;align-items:center;justify-content:space-between;gap:10px;padding-top:18px}.filt__gramFigure[data-v-9651e9da]{font-size:12px;font-weight:700;color:#14161a}.filt__gramFigure i[data-v-9651e9da]{font-style:normal;font-size:11px;font-weight:600;color:#8a909c;padding-inline-end:4px}.filt__bar[data-v-9651e9da]{position:fixed;bottom:0;left:0;right:0;z-index:5;background:#ffffffeb;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-top:1px solid #ECEDEF;padding-bottom:16px}.filt__barInner[data-v-9651e9da]{max-width:768px;margin:0 auto;padding:12px 16px;display:flex;align-items:center;gap:10px}.filt__clear[data-v-9651e9da],.filt__apply[data-v-9651e9da]{flex:1;padding:13px 18px;border:0;cursor:pointer;border-radius:14px;font-family:inherit;font-size:13px;font-weight:700;transition:transform .15s ease}.filt__clear[data-v-9651e9da]{color:#22262e;background:#f4f5f6;border:1px solid #ECEDEF}.filt__apply[data-v-9651e9da]{color:#fff;background:#14161a}.filt__clear[data-v-9651e9da]:active,.filt__apply[data-v-9651e9da]:active{transform:scale(.98)}.search[data-v-0d6eddd7]{background:#fff;min-height:100vh}.search__barExtra[data-v-0d6eddd7]{max-width:768px;margin:0 auto;padding:0 16px}.search__chips[data-v-0d6eddd7]{display:flex;gap:4px;overflow-x:auto;margin:8px 0 8px -16px;scroll-snap-type:x proximity}.search__chips[data-v-0d6eddd7]:before,.search__chips[data-v-0d6eddd7]:after{content:"";flex:0 0 16px}.search__chip[data-v-0d6eddd7]{scroll-snap-align:start;flex:0 0 auto;display:inline-flex;align-items:center;gap:6px;padding:7px 14px;border-radius:999px;cursor:pointer;font-family:inherit;font-size:12.5px;font-weight:600;white-space:nowrap;color:#22262e;background:#fff;border:1px solid #ECEDEF;transition:all .2s ease}.search__chip.is-on[data-v-0d6eddd7]{color:#fff;background:#14161a;border-color:#14161a}.search__chip--filter.is-on[data-v-0d6eddd7]{background:#7a1b33;border-color:#7a1b33}.search__chip[data-v-0d6eddd7]:active{transform:scale(.97)}.search__body[data-v-0d6eddd7]{padding-top:160px;padding-bottom:90px}.search__body[data-v-0d6eddd7]>*:first-child{margin-top:16px}.search__collections[data-v-0d6eddd7]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin-bottom:22px}.search__collection[data-v-0d6eddd7]{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:13px 10px;border-radius:14px;cursor:pointer;font-family:inherit;font-size:12.5px;font-weight:700;color:#22262e;background:#f4f5f6;border:1px solid #ECEDEF;transition:all .2s ease}.search__collection[data-v-0d6eddd7]:active{transform:scale(.98)}.search__grid[data-v-0d6eddd7]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}.search__more[data-v-0d6eddd7]{display:flex;justify-content:center;padding:18px 0 4px}.search__empty[data-v-0d6eddd7]{margin-top:8px;padding:34px 20px;border:1px dashed #ECEDEF;border-radius:18px;display:flex;flex-direction:column;align-items:center;gap:10px;color:#8a909c}.search__empty p[data-v-0d6eddd7]{margin:0;font-size:12.5px}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
import{d as r,c as t,b as o,t as s,f as n,E as _,k as d,I as u,i as a,_ as b}from"./index-BLEa2dU-.js";const m={class:"sec"},f={class:"sec__text"},k={class:"sec__title"},x={key:0,class:"sec__sub"},h=r({__name:"SectionHead",props:{title:{},subtitle:{},actionLabel:{}},emits:["action"],setup(e,{emit:i}){const l=i;return(p,c)=>(a(),t("header",m,[o("div",f,[o("h2",k,s(e.title),1),e.subtitle?(a(),t("p",x,s(e.subtitle),1)):n("",!0)]),e.actionLabel?(a(),t("button",{key:0,type:"button",class:"sec__action",onClick:c[0]||(c[0]=v=>l("action"))},[_(s(e.actionLabel)+" ",1),d(u,{icon:"vuesax-linear:arrow-left-2",size:"15"})])):n("",!0)]))}}),N=b(h,[["__scopeId","data-v-e5c65b7c"]]);export{N as S};
import{d as r,c as t,b as o,t as s,f as n,E as _,k as d,I as u,i as a,_ as b}from"./index-CRQPRp-C.js";const m={class:"sec"},f={class:"sec__text"},k={class:"sec__title"},x={key:0,class:"sec__sub"},h=r({__name:"SectionHead",props:{title:{},subtitle:{},actionLabel:{}},emits:["action"],setup(e,{emit:i}){const l=i;return(p,c)=>(a(),t("header",m,[o("div",f,[o("h2",k,s(e.title),1),e.subtitle?(a(),t("p",x,s(e.subtitle),1)):n("",!0)]),e.actionLabel?(a(),t("button",{key:0,type:"button",class:"sec__action",onClick:c[0]||(c[0]=v=>l("action"))},[_(s(e.actionLabel)+" ",1),d(u,{icon:"vuesax-linear:arrow-left-2",size:"15"})])):n("",!0)]))}}),N=b(h,[["__scopeId","data-v-e5c65b7c"]]);export{N as S};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
.loading *{box-sizing:border-box}.loading{position:relative;width:50px;height:50px;border-radius:50%;box-sizing:border-box;border:3px solid transparent}.loading .effect-1,.loading .effect-2{position:absolute;width:50px;height:50px;border:3px solid transparent;border-left:3px solid #8D6A46;border-radius:50%;box-sizing:border-box}.loading .effect-1{animation:rotate 1s ease infinite}.loading .effect-2{animation:rotateOpacity 1s ease infinite .1s}.loading .effect-3{position:absolute;width:50px;height:50px;border:3px solid transparent;border-left:3px solid #8D6A46;animation:rotateOpacity 1s ease infinite .2s;border-radius:50%;box-sizing:border-box}.loading .effects{transition:all .3s ease}@keyframes rotate{0%{transform:rotate(0)}to{transform:rotate(1turn)}}@keyframes rotateOpacity{0%{transform:rotate(0);opacity:.1}to{transform:rotate(1turn);opacity:1}}.spinner-brand{display:block;width:48px;height:48px;-o-object-fit:contain;object-fit:contain;border-radius:8px}.ant-spin-text{color:#1c2d56}.loading+.ant-spin-text{margin-top:24px}
.loading *{box-sizing:border-box}.loading{position:relative;width:50px;height:50px;border-radius:50%;box-sizing:border-box;border:3px solid transparent}.loading .effect-1,.loading .effect-2{position:absolute;width:50px;height:50px;border:3px solid transparent;border-left:3px solid #8D6A46;border-radius:50%;box-sizing:border-box}.loading .effect-1{animation:rotate 1s ease infinite}.loading .effect-2{animation:rotateOpacity 1s ease infinite .1s}.loading .effect-3{position:absolute;width:50px;height:50px;border:3px solid transparent;border-left:3px solid #8D6A46;animation:rotateOpacity 1s ease infinite .2s;border-radius:50%;box-sizing:border-box}.loading .effects{transition:all .3s ease}@keyframes rotate{0%{transform:rotate(0)}to{transform:rotate(1turn)}}@keyframes rotateOpacity{0%{transform:rotate(0);opacity:.1}to{transform:rotate(1turn);opacity:1}}.spinner-brand{display:block;width:48px;height:48px;-o-object-fit:contain;object-fit:contain;border-radius:8px}.ant-spin-text{color:#23493c}.loading+.ant-spin-text{margin-top:24px}
@@ -1 +1 @@
import{d as A,G as C,o as b,q as D,c as i,k as r,s as f,x as w,u as E,f as m,g as u,i as l,F as y,b as s,r as L,I as g,t as o,e as p,v as N,_ as M}from"./index-BLEa2dU-.js";import{P}from"./PageBar-IlBZ6uld.js";import{a as O}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";import{S as B}from"./SectionHead-BA4SOlK7.js";import{j as R,p as U}from"./filters-CLL9nGZ2.js";import{D as I}from"./index-DBmNdnBg.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./classCallCheck-BHfqvuTP.js";const V={class:"tx"},$={class:"tx__list"},G=["onClick"],Y={class:"tx__main"},z={class:"tx__head"},F={class:"tx__kind"},H={key:0,class:"tx__note"},j={class:"tx__foot"},q={class:"tx__date"},J={key:1,class:"tx__empty"},K={class:"sheet"},Q={class:"sheet__specs"},W={class:"sheet__spec"},X={class:"sheet__spec"},Z={class:"sheet__spec"},ss={class:"sheet__spec"},es={class:"sheet__spec"},ts=A({__name:"TransactionsView",setup(os){const x={ORDER_STOCK:"سفارش",ORDER_PRE_ORDER:"سفارش ساخت",REPAYMENT_MELTED_GOLD:"طلای آب‌شده",REPAYMENT_TRANSFER:"حواله",REPAYMENT_CHEQUE:"چک",REPAYMENT_CASH:"پولی",WALLET_BONUS:"پاداش",ADJUSTMENT:"اصلاحیه"},T=C(),_=u(!1),d=u([]),v=u(!1),n=u(null),c=a=>a.direction==="CREDIT",h=a=>a.currency==="GOLD_GRAM"?`${a.amount} گرم`:`${U(a.amount)} ریال`,k=a=>{n.value=a,v.value=!0};return b(async()=>{if(T.isLoggedIn){_.value=!0;try{d.value=await D.getMyLedgerEntries()}finally{_.value=!1}}}),(a,e)=>{const S=N("container");return l(),i("div",V,[r(P,{title:"اسناد","back-to":"userPage::hasSubRoute"}),r(O,{spinning:_.value,tip:"درحال دریافت اطلاعات"},{default:f(()=>[r(S,{class:"tx__body"},{default:f(()=>[d.value.length?(l(),i(y,{key:0},[r(B,{title:"گردش حساب",subtitle:`${d.value.length} سند`},null,8,["subtitle"]),s("div",$,[(l(!0),i(y,null,L(d.value,t=>(l(),i("article",{key:t.id,class:"tx__row",onClick:ns=>k(t)},[s("span",{class:p(["tx__mark",c(t)?"is-in":"is-out"]),"aria-hidden":"true"},[r(g,{icon:c(t)?"vuesax-linear:arrow-down":"vuesax-linear:arrow-up",size:"16"},null,8,["icon"])],2),s("div",Y,[s("div",z,[s("h3",F,o(x[t.sourceType]??t.sourceType),1),s("span",{class:p(["tx__amount",c(t)?"is-in":"is-out"])},o(h(t)),3)]),t.note?(l(),i("p",H,o(t.note),1)):m("",!0),s("div",j,[s("span",q,o(E(R)(t.createdAt)),1),s("span",{class:p(["tx__state",{"is-pending":!t.confirmed}])},o(t.confirmed?"تایید شده":"در انتظار تایید"),3)])])],8,G))),128))])],64)):_.value?m("",!0):(l(),i("section",J,[r(g,{icon:"vuesax-linear:receipt-text",size:"26"}),e[1]||(e[1]=s("p",null,"سندی برای حساب شما ثبت نشده است.",-1))]))]),_:1})]),_:1},8,["spinning"]),n.value?(l(),w(E(I),{key:0,visible:v.value,"onUpdate:visible":e[0]||(e[0]=t=>v.value=t),placement:"bottom",closable:!1,height:"420px",class:"rtl",bodyStyle:{padding:0}},{default:f(()=>[s("div",K,[e[7]||(e[7]=s("h3",{class:"sheet__title"},"جزئیات سند",-1)),s("dl",Q,[s("div",W,[e[2]||(e[2]=s("dt",null,"نوع سند",-1)),s("dd",null,o(x[n.value.sourceType]??n.value.sourceType),1)]),s("div",X,[e[3]||(e[3]=s("dt",null,"مبلغ",-1)),s("dd",{class:p(c(n.value)?"is-in":"is-out")},o(h(n.value)),3)]),s("div",Z,[e[4]||(e[4]=s("dt",null,"وضعیت",-1)),s("dd",null,o(n.value.confirmed?"تایید شده":"در انتظار تایید"),1)]),s("div",ss,[e[5]||(e[5]=s("dt",null,"تاریخ",-1)),s("dd",null,o(E(R)(n.value.createdAt)),1)]),s("div",es,[e[6]||(e[6]=s("dt",null,"توضیحات",-1)),s("dd",null,o(n.value.note||"—"),1)])])])]),_:1},8,["visible"])):m("",!0)])}}}),ps=M(ts,[["__scopeId","data-v-ea71d707"]]);export{ps as default};
import{d as A,G as C,o as b,q as D,c as i,k as r,s as f,x as w,u as E,f as m,g as u,i as l,F as y,b as s,r as L,I as g,t as o,e as p,v as N,_ as M}from"./index-CRQPRp-C.js";import{P}from"./PageBar-DcURmszD.js";import{a as O}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";import{S as B}from"./SectionHead-BjbRzluB.js";import{j as R,p as U}from"./filters-CLL9nGZ2.js";import{D as I}from"./index-BVow2xBt.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./classCallCheck-CJTmwORh.js";const V={class:"tx"},$={class:"tx__list"},G=["onClick"],Y={class:"tx__main"},z={class:"tx__head"},F={class:"tx__kind"},H={key:0,class:"tx__note"},j={class:"tx__foot"},q={class:"tx__date"},J={key:1,class:"tx__empty"},K={class:"sheet"},Q={class:"sheet__specs"},W={class:"sheet__spec"},X={class:"sheet__spec"},Z={class:"sheet__spec"},ss={class:"sheet__spec"},es={class:"sheet__spec"},ts=A({__name:"TransactionsView",setup(os){const x={ORDER_STOCK:"سفارش",ORDER_PRE_ORDER:"سفارش ساخت",REPAYMENT_MELTED_GOLD:"طلای آب‌شده",REPAYMENT_TRANSFER:"حواله",REPAYMENT_CHEQUE:"چک",REPAYMENT_CASH:"پولی",WALLET_BONUS:"پاداش",ADJUSTMENT:"اصلاحیه"},T=C(),_=u(!1),d=u([]),v=u(!1),n=u(null),c=a=>a.direction==="CREDIT",h=a=>a.currency==="GOLD_GRAM"?`${a.amount} گرم`:`${U(a.amount)} ریال`,k=a=>{n.value=a,v.value=!0};return b(async()=>{if(T.isLoggedIn){_.value=!0;try{d.value=await D.getMyLedgerEntries()}finally{_.value=!1}}}),(a,e)=>{const S=N("container");return l(),i("div",V,[r(P,{title:"اسناد","back-to":"userPage::hasSubRoute"}),r(O,{spinning:_.value,tip:"درحال دریافت اطلاعات"},{default:f(()=>[r(S,{class:"tx__body"},{default:f(()=>[d.value.length?(l(),i(y,{key:0},[r(B,{title:"گردش حساب",subtitle:`${d.value.length} سند`},null,8,["subtitle"]),s("div",$,[(l(!0),i(y,null,L(d.value,t=>(l(),i("article",{key:t.id,class:"tx__row",onClick:ns=>k(t)},[s("span",{class:p(["tx__mark",c(t)?"is-in":"is-out"]),"aria-hidden":"true"},[r(g,{icon:c(t)?"vuesax-linear:arrow-down":"vuesax-linear:arrow-up",size:"16"},null,8,["icon"])],2),s("div",Y,[s("div",z,[s("h3",F,o(x[t.sourceType]??t.sourceType),1),s("span",{class:p(["tx__amount",c(t)?"is-in":"is-out"])},o(h(t)),3)]),t.note?(l(),i("p",H,o(t.note),1)):m("",!0),s("div",j,[s("span",q,o(E(R)(t.createdAt)),1),s("span",{class:p(["tx__state",{"is-pending":!t.confirmed}])},o(t.confirmed?"تایید شده":"در انتظار تایید"),3)])])],8,G))),128))])],64)):_.value?m("",!0):(l(),i("section",J,[r(g,{icon:"vuesax-linear:receipt-text",size:"26"}),e[1]||(e[1]=s("p",null,"سندی برای حساب شما ثبت نشده است.",-1))]))]),_:1})]),_:1},8,["spinning"]),n.value?(l(),w(E(I),{key:0,visible:v.value,"onUpdate:visible":e[0]||(e[0]=t=>v.value=t),placement:"bottom",closable:!1,height:"420px",class:"rtl",bodyStyle:{padding:0}},{default:f(()=>[s("div",K,[e[7]||(e[7]=s("h3",{class:"sheet__title"},"جزئیات سند",-1)),s("dl",Q,[s("div",W,[e[2]||(e[2]=s("dt",null,"نوع سند",-1)),s("dd",null,o(x[n.value.sourceType]??n.value.sourceType),1)]),s("div",X,[e[3]||(e[3]=s("dt",null,"مبلغ",-1)),s("dd",{class:p(c(n.value)?"is-in":"is-out")},o(h(n.value)),3)]),s("div",Z,[e[4]||(e[4]=s("dt",null,"وضعیت",-1)),s("dd",null,o(n.value.confirmed?"تایید شده":"در انتظار تایید"),1)]),s("div",ss,[e[5]||(e[5]=s("dt",null,"تاریخ",-1)),s("dd",null,o(E(R)(n.value.createdAt)),1)]),s("div",es,[e[6]||(e[6]=s("dt",null,"توضیحات",-1)),s("dd",null,o(n.value.note||"—"),1)])])])]),_:1},8,["visible"])):m("",!0)])}}}),ps=M(ts,[["__scopeId","data-v-ea71d707"]]);export{ps as default};
@@ -1 +1 @@
import{g as d,u as C,h as a,m as F,q as S}from"./index-BLEa2dU-.js";function W(t){return(t.qty??0)>0||!!t.isPreOrder}function Q(t){if(!t||t.length===0)return null;const e=t.filter(W);return(e.length?e:t).reduce((s,r)=>parseFloat(r.defaultWagePercent)<parseFloat(s.defaultWagePercent)?r:s)}function M(t,e){const i=d(t),s=a(()=>i.value.id),r=a(()=>i.value.title),n=a(()=>i.value.variants),o=d(e??Q(C(n))),y=a(()=>{var u,f,m,p;return((f=(u=o.value)==null?void 0:u.image)==null?void 0:f.url)??((p=(m=i.value.images)==null?void 0:m[0])==null?void 0:p.url)}),g=a(()=>o.value?parseFloat(o.value.rashWeightGrams):0),x=a(()=>o.value?parseFloat(o.value.defaultWagePercent):null),q=d(null),l=a(()=>{var u;return((u=o.value)==null?void 0:u.qty)??0}),h=a(()=>{var u;return((u=o.value)==null?void 0:u.isPreOrder)??!1}),P=a(()=>l.value>0||h.value),O=a(()=>i.value.productCode??null),_=d(!1);return{product:i,image:y,id:s,title:r,productCode:O,variants:n,selectedVariant:o,min_gram:g,wage:x,hasDiscountWage:q,qty:l,isPreOrder:h,is_exist:P,has_warranty:_}}const v="appCart";function w(){try{const t=localStorage.getItem(v);return t?JSON.parse(t):[]}catch{return[]}}function c(t){localStorage.setItem(v,JSON.stringify(t))}const N=F("cart",{state:()=>({items:w()}),actions:{async init(){try{const t=await S.listProducts(),e=[];for(const i of this.items){const s=t.find(n=>n.id===i.pid),r=s==null?void 0:s.variants.find(n=>n.id===i.vid);s&&r&&e.push({...i,product:s})}this.items=e,c(this.items)}catch(t){console.log(t)}},addToCart(t){var s,r;const e=(r=(s=t.product)==null?void 0:s.variants)==null?void 0:r.find(n=>n.id===t.vid);if(!e||!((e.qty??0)>0||e.isPreOrder))return!1;const i=this.find_index(t);return i===-1?this.items.push({...t,qty:this.capQty(t.qty,e)}):(this.items[i].product=t.product,this.items[i].qty=this.capQty(t.qty,e)),c(this.items),!0},capQty(t,e){const i=Math.max(1,Math.floor(t)||1);if(e.isPreOrder)return i;const s=e.qty??0;return s>0?Math.min(i,s):i},maxQty(t){const e=this.find_index(t);if(e===-1)return null;const i=this.variant(this.items[e]);return!i||i.isPreOrder?null:(i.qty??0)>0?i.qty:null},remove(t){const e=this.find_index(t);e>-1&&this.items.splice(e,1),c(this.items)},updateFeild(t,e,i,s){if(!this.isInCart(i))return!1;const r=e??this.find_index(i);if(s==="qty"){const n=this.variant(this.items[r]);t=n?this.capQty(Number(t),n):Math.max(1,Number(t)||1)}return this.items[r][s]=t,c(this.items),!0},find_index(t){return this.items.findIndex(e=>e.pid===t.pid&&e.vid===t.vid)},isInCart(t){return this.find_index(t)>-1},variant(t){return t.product.variants.find(e=>e.id===t.vid)},total(){return this.items.reduce((t,e)=>{const i=this.variant(e);return t+(i?parseFloat(i.rashWeightGrams)*e.qty:0)},0).toFixed(2)},clear(){this.items=[],c(this.items)}}});export{N as a,W as i,M as u};
import{g as d,u as C,h as a,m as F,q as S}from"./index-CRQPRp-C.js";function W(t){return(t.qty??0)>0||!!t.isPreOrder}function Q(t){if(!t||t.length===0)return null;const e=t.filter(W);return(e.length?e:t).reduce((s,r)=>parseFloat(r.defaultWagePercent)<parseFloat(s.defaultWagePercent)?r:s)}function M(t,e){const i=d(t),s=a(()=>i.value.id),r=a(()=>i.value.title),n=a(()=>i.value.variants),o=d(e??Q(C(n))),y=a(()=>{var u,f,m,p;return((f=(u=o.value)==null?void 0:u.image)==null?void 0:f.url)??((p=(m=i.value.images)==null?void 0:m[0])==null?void 0:p.url)}),g=a(()=>o.value?parseFloat(o.value.rashWeightGrams):0),x=a(()=>o.value?parseFloat(o.value.defaultWagePercent):null),q=d(null),l=a(()=>{var u;return((u=o.value)==null?void 0:u.qty)??0}),h=a(()=>{var u;return((u=o.value)==null?void 0:u.isPreOrder)??!1}),P=a(()=>l.value>0||h.value),O=a(()=>i.value.productCode??null),_=d(!1);return{product:i,image:y,id:s,title:r,productCode:O,variants:n,selectedVariant:o,min_gram:g,wage:x,hasDiscountWage:q,qty:l,isPreOrder:h,is_exist:P,has_warranty:_}}const v="appCart";function w(){try{const t=localStorage.getItem(v);return t?JSON.parse(t):[]}catch{return[]}}function c(t){localStorage.setItem(v,JSON.stringify(t))}const N=F("cart",{state:()=>({items:w()}),actions:{async init(){try{const t=await S.listProducts(),e=[];for(const i of this.items){const s=t.find(n=>n.id===i.pid),r=s==null?void 0:s.variants.find(n=>n.id===i.vid);s&&r&&e.push({...i,product:s})}this.items=e,c(this.items)}catch(t){console.log(t)}},addToCart(t){var s,r;const e=(r=(s=t.product)==null?void 0:s.variants)==null?void 0:r.find(n=>n.id===t.vid);if(!e||!((e.qty??0)>0||e.isPreOrder))return!1;const i=this.find_index(t);return i===-1?this.items.push({...t,qty:this.capQty(t.qty,e)}):(this.items[i].product=t.product,this.items[i].qty=this.capQty(t.qty,e)),c(this.items),!0},capQty(t,e){const i=Math.max(1,Math.floor(t)||1);if(e.isPreOrder)return i;const s=e.qty??0;return s>0?Math.min(i,s):i},maxQty(t){const e=this.find_index(t);if(e===-1)return null;const i=this.variant(this.items[e]);return!i||i.isPreOrder?null:(i.qty??0)>0?i.qty:null},remove(t){const e=this.find_index(t);e>-1&&this.items.splice(e,1),c(this.items)},updateFeild(t,e,i,s){if(!this.isInCart(i))return!1;const r=e??this.find_index(i);if(s==="qty"){const n=this.variant(this.items[r]);t=n?this.capQty(Number(t),n):Math.max(1,Number(t)||1)}return this.items[r][s]=t,c(this.items),!0},find_index(t){return this.items.findIndex(e=>e.pid===t.pid&&e.vid===t.vid)},isInCart(t){return this.find_index(t)>-1},variant(t){return t.product.variants.find(e=>e.id===t.vid)},total(){return this.items.reduce((t,e)=>{const i=this.variant(e);return t+(i?parseFloat(i.rashWeightGrams)*e.qty:0)},0).toFixed(2)},clear(){this.items=[],c(this.items)}}});export{N as a,W as i,M as u};
@@ -1 +1 @@
import{c as l}from"./Spinner.vue_vue_type_style_index_0_lang-qGBuw_hS.js";var f=function(n){return setTimeout(n,16)},c=function(n){return clearTimeout(n)};typeof window<"u"&&"requestAnimationFrame"in window&&(f=function(n){return window.requestAnimationFrame(n)},c=function(n){return window.cancelAnimationFrame(n)});var i=0,o=new Map;function u(e){o.delete(e)}function w(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;i+=1;var r=i;function a(t){if(t===0)u(r),e();else{var s=f(function(){a(t-1)});o.set(r,s)}}return a(n),r}w.cancel=function(e){var n=o.get(e);return u(n),c(n)};function m(e,n){for(var r=l({},e),a=0;a<n.length;a+=1){var t=n[a];delete r[t]}return r}function p(e,n,r){return Object.defineProperty(e,"prototype",{writable:!1}),e}function v(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}export{p as _,v as a,m as o,w};
import{c as l}from"./Spinner.vue_vue_type_style_index_0_lang-uVHC4xq0.js";var f=function(n){return setTimeout(n,16)},c=function(n){return clearTimeout(n)};typeof window<"u"&&"requestAnimationFrame"in window&&(f=function(n){return window.requestAnimationFrame(n)},c=function(n){return window.cancelAnimationFrame(n)});var i=0,o=new Map;function u(e){o.delete(e)}function w(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;i+=1;var r=i;function a(t){if(t===0)u(r),e();else{var s=f(function(){a(t-1)});o.set(r,s)}}return a(n),r}w.cancel=function(e){var n=o.get(e);return u(n),c(n)};function m(e,n){for(var r=l({},e),a=0;a<n.length;a+=1){var t=n[a];delete r[t]}return r}function p(e,n,r){return Object.defineProperty(e,"prototype",{writable:!1}),e}function v(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}export{p as _,v as a,m as o,w};
@@ -1 +1 @@
import{m as e}from"./index-BLEa2dU-.js";const t={colors:[],brands:[],ciny_id:[],limit_percent:[],limit_gram:[],has_discount:!1,text:void 0,cats:void 0,page:0},i=e("filters",{state:()=>({query:{...t}}),actions:{reset(){this.query={...t}}}});export{i as u};
import{m as e}from"./index-CRQPRp-C.js";const t={colors:[],brands:[],ciny_id:[],limit_percent:[],limit_gram:[],has_discount:!1,text:void 0,cats:void 0,page:0},i=e("filters",{state:()=>({query:{...t}}),actions:{reset(){this.query={...t}}}});export{i as u};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
-1
View File
@@ -1 +0,0 @@
import{d as r,k as c,a4 as l,aq as p,ar as d,a1 as i,as as u,at as m,ae as f,au as o,ad as g,al as k}from"./index-BLEa2dU-.js";const[h,P]=g("notify"),w=["lockScroll","position","show","teleport","zIndex"],y=i({},u,{type:o("danger"),color:String,message:f,position:o("top"),className:m,background:String,lockScroll:Boolean});var S=r({name:h,props:y,emits:["update:show"],setup(a,{emit:s,slots:e}){const t=n=>s("update:show",n);return()=>c(d,l({class:[P([a.type]),a.className],style:{color:a.color,background:a.background},overlay:!1,duration:.2,"onUpdate:show":t},p(a,w)),{default:()=>[e.default?e.default():a.message]})}});const b=k(S);export{b as N,S as s};
@@ -1 +1 @@
import{ad as y,d as L,ae as N,af as $,H as w,ag as A,k as c,g as D,C as p,L as B,ah as C,N as I,ai as f,aj as M,ak as R,al as U}from"./index-BLEa2dU-.js";const[Y,r,j]=y("pull-refresh"),x=50,F=["pulling","loosing","success"],G={disabled:Boolean,modelValue:Boolean,headHeight:f(x),successText:String,pullingText:String,loosingText:String,loadingText:String,pullDistance:N,successDuration:f(500),animationDuration:f(300)};var X=L({name:Y,props:G,emits:["change","refresh","update:modelValue"],setup(s,{emit:d,slots:o}){let u;const g=D(),T=D(),H=$(g),e=p({status:"normal",distance:0,duration:0}),i=R(),P=()=>{if(s.headHeight!==x)return{height:`${s.headHeight}px`}},h=()=>e.status!=="loading"&&e.status!=="success"&&!s.disabled,k=t=>{const a=+(s.pullDistance||s.headHeight);return t>a&&(t<a*2?t=a+(t-a)/2:t=a*1.5+(t-a*2)/4),Math.round(t)},n=(t,a)=>{const l=+(s.pullDistance||s.headHeight);e.distance=t,a?e.status="loading":t===0?e.status="normal":t<l?e.status="pulling":e.status="loosing",d("change",{status:e.status,distance:t})},m=()=>{const{status:t}=e;return t==="normal"?"":s[`${t}Text`]||j(t)},E=()=>{const{status:t,distance:a}=e;if(o[t])return o[t]({distance:a});const l=[];return F.includes(t)&&l.push(c("div",{class:r("text")},[m()])),t==="loading"&&l.push(c(B,{class:r("loading")},{default:m})),l},V=()=>{e.status="success",setTimeout(()=>{n(0)},+s.successDuration)},v=t=>{u=M(H.value)===0,u&&(e.duration=0,i.start(t))},_=t=>{h()&&v(t)},b=t=>{if(h()){u||v(t);const{deltaY:a}=i;i.move(t),u&&a.value>=0&&i.isVertical()&&(C(t),n(k(a.value)))}},S=()=>{u&&i.deltaY.value&&h()&&(e.duration=+s.animationDuration,e.status==="loosing"?(n(+s.headHeight,!0),d("update:modelValue",!0),I(()=>d("refresh"))):n(0))};return w(()=>s.modelValue,t=>{e.duration=+s.animationDuration,t?n(+s.headHeight,!0):o.success||s.successText?V():n(0,!1)}),A("touchmove",b,{target:T}),()=>{var t;const a={transitionDuration:`${e.duration}ms`,transform:e.distance?`translate3d(0,${e.distance}px, 0)`:""};return c("div",{ref:g,class:r()},[c("div",{ref:T,class:r("track"),style:a,onTouchstartPassive:_,onTouchend:S,onTouchcancel:S},[c("div",{class:r("head"),style:P()},[E()]),(t=o.default)==null?void 0:t.call(o)])])}}});const z=U(X);export{z as P};
import{a8 as y,d as L,a9 as N,aa as $,H as w,ab as A,k as l,g as D,C as p,L as B,ac as C,N as I,ad as f,ae as M,af as R,ag as U}from"./index-CRQPRp-C.js";const[Y,r,F]=y("pull-refresh"),x=50,G=["pulling","loosing","success"],X={disabled:Boolean,modelValue:Boolean,headHeight:f(x),successText:String,pullingText:String,loosingText:String,loadingText:String,pullDistance:N,successDuration:f(500),animationDuration:f(300)};var j=L({name:Y,props:X,emits:["change","refresh","update:modelValue"],setup(s,{emit:d,slots:o}){let u;const g=D(),T=D(),H=$(g),e=p({status:"normal",distance:0,duration:0}),i=R(),P=()=>{if(s.headHeight!==x)return{height:`${s.headHeight}px`}},h=()=>e.status!=="loading"&&e.status!=="success"&&!s.disabled,k=t=>{const a=+(s.pullDistance||s.headHeight);return t>a&&(t<a*2?t=a+(t-a)/2:t=a*1.5+(t-a*2)/4),Math.round(t)},n=(t,a)=>{const c=+(s.pullDistance||s.headHeight);e.distance=t,a?e.status="loading":t===0?e.status="normal":t<c?e.status="pulling":e.status="loosing",d("change",{status:e.status,distance:t})},m=()=>{const{status:t}=e;return t==="normal"?"":s[`${t}Text`]||F(t)},E=()=>{const{status:t,distance:a}=e;if(o[t])return o[t]({distance:a});const c=[];return G.includes(t)&&c.push(l("div",{class:r("text")},[m()])),t==="loading"&&c.push(l(B,{class:r("loading")},{default:m})),c},V=()=>{e.status="success",setTimeout(()=>{n(0)},+s.successDuration)},v=t=>{u=M(H.value)===0,u&&(e.duration=0,i.start(t))},b=t=>{h()&&v(t)},_=t=>{if(h()){u||v(t);const{deltaY:a}=i;i.move(t),u&&a.value>=0&&i.isVertical()&&(C(t),n(k(a.value)))}},S=()=>{u&&i.deltaY.value&&h()&&(e.duration=+s.animationDuration,e.status==="loosing"?(n(+s.headHeight,!0),d("update:modelValue",!0),I(()=>d("refresh"))):n(0))};return w(()=>s.modelValue,t=>{e.duration=+s.animationDuration,t?n(+s.headHeight,!0):o.success||s.successText?V():n(0,!1)}),A("touchmove",_,{target:T}),()=>{var t;const a={transitionDuration:`${e.duration}ms`,transform:e.distance?`translate3d(0,${e.distance}px, 0)`:""};return l("div",{ref:g,class:r()},[l("div",{ref:T,class:r("track"),style:a,onTouchstartPassive:b,onTouchend:S,onTouchcancel:S},[l("div",{class:r("head"),style:P()},[E()]),(t=o.default)==null?void 0:t.call(o)])])}}});const z=U(j);export{z as P};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
import{g as s,N as l}from"./index-CRQPRp-C.js";const r=new Set;function c(a,n=70){const e=s(r.has(a));function t(i){return{"--reveal-delay":`${i*n}ms`}}async function u(){e.value||(await l(),requestAnimationFrame(()=>requestAnimationFrame(()=>{e.value=!0,r.add(a)})))}return{revealed:e,revealDelay:t,reveal:u}}export{c as u};
+19 -19
View File
@@ -1,19 +1,19 @@
<!doctype html>
<html lang="en">
<head>
<link rel="icon" href="/favicon.ico" />
<meta charset="UTF-8" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<meta name="theme-color" content="#1C2D56" />
<meta name="background-color" content="#1C2D56" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />
<title>طلای منتزر</title>
<script type="module" crossorigin src="/assets/index-BLEa2dU-.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-DmO-cYMw.css">
<link rel="manifest" href="/manifest.webmanifest"></head>
<body style="background-color: #fff">
<div class="bg-white w-screen h-screen fixed"></div>
<div id="app"></div>␍
</body>
</html>
<!doctype html>
<html lang="en">
<head>
<link rel="icon" href="/favicon.ico" />
<meta charset="UTF-8" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<meta name="theme-color" content="#23493c" />
<meta name="background-color" content="#23493c" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />
<title>طلای منتزر</title>
<script type="module" crossorigin src="/assets/index-CRQPRp-C.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-CbjNawkY.css">
<link rel="manifest" href="/manifest.webmanifest"></head>
<body style="background-color: #fff">
<div class="bg-white w-screen h-screen fixed"></div>
<div id="app"></div>
</body>
</html>
+1 -1
View File
@@ -1 +1 @@
{"name":"Montzar","short_name":"Montzar","start_url":"/","display":"standalone","background_color":"#1C2D56","lang":"en","scope":"/","description":"Montzar","theme_color":"#1C2D56","icons":[{"src":"icon-192.png","sizes":"192x192","type":"image/png"},{"src":"/icon-512.png","sizes":"512x512","type":"image/png"},{"src":"icon-512.png","sizes":"512x512","type":"image/png","purpose":"any maskable"}]}
{"name":"Montzar","short_name":"Montzar","start_url":"/","display":"standalone","background_color":"#23493c","lang":"en","scope":"/","description":"Montzar","theme_color":"#23493c","icons":[{"src":"icon-192.png","sizes":"192x192","type":"image/png"},{"src":"/icon-512.png","sizes":"512x512","type":"image/png"},{"src":"icon-512.png","sizes":"512x512","type":"image/png","purpose":"any maskable"}]}
+1 -1
View File
File diff suppressed because one or more lines are too long
+2 -2
View File
@@ -5,8 +5,8 @@
<meta charset="UTF-8" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<meta name="theme-color" content="#1C2D56" />
<meta name="background-color" content="#1C2D56" />
<meta name="theme-color" content="#23493c" />
<meta name="background-color" content="#23493c" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />
<title>طلای منتزر</title>
</head>
+4 -1
View File
@@ -34,9 +34,11 @@
</template>
<template v-slot:button>
<div class="text-center text-[#1C2D56]" @click="update()">به روز رسانی</div>
<div class="text-center text-[#23493c]" @click="update()">به روز رسانی</div>
</template>
</DialogVantOneButton>
<ToastHost />
</div>
</template>
@@ -48,6 +50,7 @@ import { useRegisterSW } from 'virtual:pwa-register/vue'
import MasterLayout from './layout/MasterLayout.vue'
import FullPageLayout from './layout/FullPageLayout.vue'
import DialogVantOneButton from './components/DialogVantOneButton.vue'
import ToastHost from './components/ui/ToastHost.vue'
import { useRefresh } from './composables/useRefresh'
import pkg from '../package.json'
@@ -607,3 +607,84 @@ input:focus-visible {
width: 100%;
height: 40vh
}
// v-lazy images (vue3-lazyload sets lazy="loading" | "loaded" | "error").
// Hidden until the real file has loaded, then faded in, so a card never shows
// a placeholder that is then swapped out, or a photo painting in top-down.
img[lazy='loading'] {
opacity: 0;
}
img[lazy='loaded'],
img[lazy='error'] {
opacity: 1;
transition: opacity 0.35s ease;
}
// Shimmering placeholder block for content that is still loading.
.skeleton {
position: relative;
overflow: hidden;
background: @hairlineSoft;
&::after {
content: '';
position: absolute;
inset: 0;
transform: translateX(100%);
background: linear-gradient(90deg, transparent, fade(#fff, 65%), transparent);
animation: skeleton-sweep 1.3s ease-in-out infinite;
}
}
// RTL page, so the sweep runs right to left.
@keyframes skeleton-sweep {
to {
transform: translateX(-100%);
}
}
@media (prefers-reduced-motion: reduce) {
.skeleton::after {
animation: none;
}
}
// First-paint entrance (driven by composables/useReveal.ts): put `reveal` on
// each section and `is-revealed` on their container once the data is in. Each
// section rises a little, scales up from just under full size and fades in,
// one beat (--reveal-delay) after the one above it.
//
// The curve is a long decelerate with no overshoot — it starts fast, settles
// slowly and never bounces back. The travel is deliberately small (14px, 2% of
// scale): the content should look like it was always there and simply came
// into focus, not like it flew in.
//
// The settled state is `transform: none`, not an identity transform: any
// transform left on a section would make it the containing block for fixed
// elements inside it and give it a permanent stacking context.
.reveal {
opacity: 0;
transform: translate3d(0, 14px, 0) scale(0.98);
will-change: transform, opacity;
}
.is-revealed .reveal {
opacity: 1;
transform: none;
will-change: auto;
transition:
opacity 0.62s cubic-bezier(0.32, 0.72, 0, 1) var(--reveal-delay, 0ms),
transform 0.62s cubic-bezier(0.32, 0.72, 0, 1) var(--reveal-delay, 0ms);
}
// Respect a reduced-motion preference: show the content, skip the choreography.
@media (prefers-reduced-motion: reduce) {
.reveal {
opacity: 1;
transform: none;
}
.is-revealed .reveal {
transition: none;
}
}
+1 -1
View File
@@ -44,7 +44,7 @@ withDefaults(
display: none !important;
}
.van-dialog__confirm .van-button__text {
color: #1c2d56;
color: #23493c;
font-weight: 600;
font-size: 15px;
}
@@ -44,7 +44,7 @@ withDefaults(
display: none !important;
}
.van-dialog__confirm .van-button__text {
color: #1c2d56;
color: #23493c;
font-weight: 600;
font-size: 15px;
}
@@ -1,50 +0,0 @@
<!-- Ported from legacy henza_pwa/src/components/NotifyVant.vue -->
<template>
<div v-if="modelValue" class="flex">
<van-notify v-model:show="show" :style="color">
<div class="w-full text-white my-2">
<div class="w-full flex content-end">
<Icon icon="vuesax-linear:info-circle" class="ml-[20px] text-white" size="25" />
<div>
<slot>{{ text }}</slot>
</div>
</div>
</div>
</van-notify>
</div>
</template>
<script setup lang="ts">
import { ref, watch } from 'vue'
import { Notify as VanNotify } from 'vant'
import Icon from './icon/Icon.vue'
const show = ref(true)
const props = withDefaults(
defineProps<{
modelValue: boolean
timeOut: number
text?: string
color?: string
}>(),
{},
)
const emit = defineEmits<{ (e: 'update:modelValue', value: boolean): void }>()
watch(
() => props.modelValue,
() => {
if (props.timeOut !== -1) showNotify()
},
)
const showNotify = () => {
setTimeout(() => {
emit('update:modelValue', false)
}, props.timeOut)
}
</script>
<!--
Legacy also had a `.notify-enter-active`/`.notify-leave-active` style block
referencing an undefined `notify-in` @keyframes and unused by any
<transition name="notify"> in this component — genuinely dead, dropped.
-->
@@ -78,7 +78,7 @@ const fiat = computed(() => (props.customer ? props.customer.fiatDebtRial.split(
.acct {
border-radius: 20px;
padding: 18px;
background: @ink;
background: @primary;
color: #fff;
box-shadow: 0 22px 44px -32px rgba(20, 22, 26, 0.9);
}
@@ -61,8 +61,8 @@ const emit = defineEmits<{ (e: 'select', cat: HomeCategory): void }>()
}
.rail__chip.is-active {
background: @ink;
border-color: @ink;
background: @primary;
border-color: @primary;
color: #fff;
}
@@ -39,7 +39,7 @@ const perGram = computed(() => (props.quote ? props.quote.pricePerGramRial.split
gap: 10px;
padding: 10px 14px;
border-radius: 14px;
background: @ink;
background: @primary;
color: #fff;
box-shadow: 0 10px 24px -18px rgba(20, 22, 26, 0.9);
}
+3 -3
View File
@@ -1017,11 +1017,11 @@
"vuesax-linear:youtube": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M17 20H7C4 20 2 18 2 15V9C2 6 4 4 7 4H17C20 4 22 6 22 9V15C22 18 20 20 17 20Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M11.4001 9.5L13.9001 11C14.8001 11.6 14.8001 12.5 13.9001 13.1L11.4001 14.6C10.4001 15.2 9.6001 14.7 9.6001 13.6V10.6C9.6001 9.3 10.4001 8.9 11.4001 9.5Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>\n",
"vuesax-linear:zel-(zel)": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10.5 11.5V14.3L8 15.8L5.5 14.3V11.5L8 10L9.2 10.7L10.5 11.5Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linejoin=\"round\"/>\n<path d=\"M18.5 11.5V14.3L16 15.8L13.5 14.3V11.5L14.8 10.7L16 10L18.5 11.5Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linejoin=\"round\"/>\n<path d=\"M14.8 9.29999V10.7L13.5 11.5V13.2L12 14.1L10.5 13.2V11.5L9.19995 10.7V9.29999L12 7.79999L14.8 9.29999Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linejoin=\"round\"/>\n<path d=\"M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linejoin=\"round\"/>\n</svg>\n",
"vuesax-linear:zoom": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M6 9.69999V12.5C6 14 7.3 15.3 8.8 15.3H12.5C13 15.3 13.4 14.9 13.4 14.4V11.6C13.4 10.1 12.2 8.79999 10.6 8.79999H6.9C6.4 8.79999 6 9.19999 6 9.69999Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\"/>\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M18 9.20001V14.8L15.2 12.9V11.1L18 9.20001Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\"/>\n</svg>\n",
"vuesax-linear:number-18": "<svg width=\"17\" height=\"14\" viewBox=\"0 0 17 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M1.05502 13.4129C1.05502 13.3105 1.05502 13.1901 1.05502 13.0516C1.05502 12.9131 1.05502 12.7686 1.05502 12.6181C1.05502 12.4675 1.05502 12.32 1.05502 12.1755C1.06084 12.031 1.06665 11.8985 1.07246 11.7781V11.7871C1.07827 11.4981 1.08118 11.2 1.08118 10.8929C1.08699 10.5798 1.0899 10.2516 1.0899 9.90839C1.0899 9.24602 1.08118 8.55957 1.06374 7.84903C1.05212 7.1385 1.01143 6.40086 0.941674 5.63613C0.87192 4.86538 0.764383 4.07054 0.619063 3.25161C0.473743 2.42667 0.267389 1.57161 0 0.686452L2.03157 0C2.32803 0.981505 2.55763 1.92387 2.72039 2.8271C2.88896 3.7243 3.01103 4.58538 3.0866 5.41032C3.16798 6.22925 3.21738 7.01505 3.23482 7.76774C3.25226 8.52043 3.26098 9.24301 3.26098 9.93548C3.26098 10.2787 3.25807 10.6099 3.25226 10.929C3.25226 11.2422 3.24935 11.5432 3.24354 11.8323C3.23773 11.9527 3.23192 12.0852 3.2261 12.2297C3.2261 12.3682 3.2261 12.5097 3.2261 12.6542C3.2261 12.7987 3.2261 12.9372 3.2261 13.0697C3.2261 13.2022 3.2261 13.3166 3.2261 13.4129H1.05502Z\" fill=\"#1C2D56\"/>\n<path d=\"M13.6693 6.05161C14.1052 7.3643 14.608 8.57763 15.1777 9.69161C15.7532 10.7996 16.3606 11.754 17 12.5548L15.3172 14C14.9684 13.5604 14.6226 13.0486 14.2796 12.4645C13.9425 11.8804 13.6082 11.2331 13.2769 10.5226C12.9456 9.80602 12.6201 9.03226 12.3004 8.20129C11.9806 7.37032 11.6639 6.48817 11.35 5.55484C11.1058 6.30753 10.8355 7.08129 10.5391 7.87613C10.2426 8.67097 9.92292 9.44473 9.57996 10.1974C9.24282 10.9441 8.89115 11.6456 8.52494 12.3019C8.15873 12.9523 7.78381 13.5123 7.40016 13.9819L5.69992 12.5548C6.008 12.1815 6.31317 11.748 6.61544 11.2542C6.9177 10.7604 7.21125 10.2335 7.49608 9.67355C7.7809 9.10753 8.0512 8.51742 8.30696 7.90323C8.56854 7.28903 8.80977 6.67183 9.03065 6.05161C9.19341 5.52774 9.35036 5.00086 9.50149 4.47097C9.65262 3.94108 9.78341 3.42925 9.89386 2.93548C10.0043 2.44172 10.0915 1.97806 10.1554 1.54452C10.2252 1.10495 10.2601 0.713549 10.2601 0.370324H12.4224C12.4224 0.737635 12.4515 1.13505 12.5096 1.56258C12.5736 1.99011 12.6578 2.44473 12.7625 2.92645C12.8729 3.40817 13.0037 3.91097 13.1548 4.43484C13.3118 4.95871 13.4833 5.49763 13.6693 6.05161Z\" fill=\"#1C2D56\"/>\n</svg>\n",
"vuesax-linear:number-24": "<svg width=\"21\" height=\"12\" viewBox=\"0 0 21 12\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M7.59689 0.399477C7.61323 0.446474 7.64862 0.558746 7.70308 0.736292C7.75754 0.913838 7.812 1.12794 7.86646 1.37859C7.92092 1.62402 7.96993 1.89034 8.01349 2.17755C8.05706 2.45953 8.07884 2.73107 8.07884 2.99217C8.07884 3.53003 7.98626 3.99739 7.80111 4.39426C7.61595 4.79112 7.37633 5.1201 7.08226 5.3812C6.78819 5.63708 6.45327 5.82768 6.07751 5.953C5.7072 6.07833 5.33416 6.14099 4.9584 6.14099C4.58809 6.14099 4.24772 6.09922 3.93731 6.01567C3.63235 5.92689 3.34644 5.8094 3.0796 5.66318C3.12861 6.11749 3.16673 6.56919 3.19396 7.01828C3.22119 7.46736 3.24025 7.94256 3.25114 8.44386C3.26203 8.93995 3.26748 9.47781 3.26748 10.0574C3.27293 10.6371 3.27293 11.2846 3.26748 12H1.25798V10.1044C1.25798 9.48825 1.24709 8.83812 1.2253 8.15405C1.20897 7.46475 1.15996 6.74151 1.07827 5.98433C0.996581 5.22715 0.871328 4.43342 0.702508 3.60313C0.533688 2.77285 0.299519 1.906 0 1.00261L1.93598 0.40731L2.2709 1.36292C2.29813 1.44125 2.34169 1.56658 2.4016 1.7389C2.46695 1.906 2.55136 2.09661 2.65483 2.3107C2.7583 2.51958 2.88083 2.73629 3.02242 2.96084C3.16946 3.18016 3.33827 3.38381 3.52888 3.5718C3.71948 3.75457 3.93187 3.906 4.16604 4.02611C4.40565 4.14099 4.66977 4.19843 4.9584 4.19843C5.02375 4.19843 5.11633 4.18799 5.23614 4.1671C5.36139 4.14621 5.48392 4.09661 5.60373 4.01828C5.72898 3.93473 5.8379 3.81201 5.93048 3.65013C6.02305 3.48825 6.06934 3.26893 6.06934 2.99217C6.06934 2.83029 6.05573 2.65535 6.0285 2.46736C6.00127 2.27415 5.96587 2.08877 5.92231 1.91123C5.88419 1.72846 5.84062 1.55875 5.79161 1.40209C5.74804 1.24021 5.7072 1.10444 5.66908 0.994778L7.59689 0.399477Z\" fill=\"#1C2D56\"/>\n<path d=\"M17.9907 4.62924C18.1432 4.62924 18.2929 4.62924 18.44 4.62924C18.587 4.62402 18.734 4.61619 18.8811 4.60574C19.0281 4.5953 19.1806 4.58224 19.3385 4.56658C19.5019 4.54569 19.6762 4.51958 19.8613 4.48825L20.3188 6.25065C20.0356 6.32898 19.7633 6.39687 19.5019 6.45431C19.2405 6.50653 18.9709 6.55091 18.6932 6.58747C18.4155 6.6188 18.1187 6.64491 17.8028 6.6658C17.4924 6.68146 17.1412 6.68929 16.7491 6.68929C16.1827 6.68929 15.6054 6.64752 15.0173 6.56397C14.4346 6.48042 13.8791 6.32898 13.3509 6.10966C13.3836 6.53264 13.4108 6.91906 13.4326 7.26893C13.4598 7.6188 13.4789 7.95039 13.4897 8.26371C13.5006 8.57702 13.5088 8.88251 13.5143 9.18016C13.5197 9.47781 13.5224 9.7859 13.5224 10.1044C13.5224 10.3238 13.5197 10.5483 13.5143 10.7781C13.5143 11.0026 13.5143 11.248 13.5143 11.5144V12H11.4884V11.5065C11.4884 10.7389 11.483 10.0209 11.4721 9.35248C11.4666 8.68407 11.4476 8.05222 11.4149 7.45692C11.3877 6.86162 11.3468 6.29243 11.2924 5.74935C11.2379 5.20627 11.1644 4.67363 11.0718 4.15144C10.9792 3.62924 10.8649 3.10966 10.7287 2.59269C10.5926 2.07572 10.4292 1.54569 10.2386 1.00261L12.1991 0.40731C12.2862 0.678851 12.3652 0.94778 12.436 1.2141C12.5122 1.48042 12.5857 1.75196 12.6565 2.02872C12.7001 2.18016 12.7382 2.33681 12.7709 2.49869C12.809 2.65535 12.8499 2.81201 12.8934 2.96867C12.9915 3.33943 13.1439 3.6423 13.3509 3.87728C13.5633 4.10705 13.792 4.27676 14.037 4.38642C14.0044 4.30809 13.969 4.22454 13.9309 4.13577C13.8927 4.047 13.8573 3.94778 13.8247 3.83812C13.7974 3.72324 13.7729 3.59791 13.7511 3.46214C13.7348 3.32637 13.7266 3.17493 13.7266 3.00783C13.7266 2.53264 13.8219 2.10966 14.0125 1.7389C14.2086 1.36292 14.4618 1.047 14.7722 0.791123C15.0881 0.530026 15.4421 0.334203 15.8342 0.203655C16.2317 0.067885 16.6292 0 17.0268 0C17.3426 0 17.634 0.0365535 17.9008 0.10966C18.1731 0.177546 18.4264 0.266318 18.6605 0.375979C18.8947 0.485639 19.1153 0.608355 19.3222 0.744125C19.5346 0.874673 19.7415 1.00261 19.943 1.12794L18.9791 2.78068C18.7885 2.65013 18.6088 2.53525 18.44 2.43603C18.2712 2.33159 18.1078 2.24543 17.9499 2.17755C17.7919 2.10966 17.6367 2.05744 17.4842 2.02089C17.3372 1.97911 17.1847 1.95561 17.0268 1.95039H16.9778C16.8362 1.95039 16.6837 1.97389 16.5203 2.02089C16.357 2.06788 16.2045 2.14099 16.0629 2.24021C15.9213 2.33942 15.8015 2.46214 15.7035 2.60835C15.6109 2.74935 15.5646 2.91123 15.5646 3.09399C15.5646 3.39164 15.6381 3.63969 15.7851 3.83812C15.9322 4.03655 16.1201 4.19582 16.3488 4.31593C16.583 4.43081 16.8444 4.51175 17.133 4.55875C17.4216 4.60574 17.7075 4.62924 17.9907 4.62924Z\" fill=\"#1C2D56\"/>\n</svg>\n",
"vuesax-linear:number-18": "<svg width=\"17\" height=\"14\" viewBox=\"0 0 17 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M1.05502 13.4129C1.05502 13.3105 1.05502 13.1901 1.05502 13.0516C1.05502 12.9131 1.05502 12.7686 1.05502 12.6181C1.05502 12.4675 1.05502 12.32 1.05502 12.1755C1.06084 12.031 1.06665 11.8985 1.07246 11.7781V11.7871C1.07827 11.4981 1.08118 11.2 1.08118 10.8929C1.08699 10.5798 1.0899 10.2516 1.0899 9.90839C1.0899 9.24602 1.08118 8.55957 1.06374 7.84903C1.05212 7.1385 1.01143 6.40086 0.941674 5.63613C0.87192 4.86538 0.764383 4.07054 0.619063 3.25161C0.473743 2.42667 0.267389 1.57161 0 0.686452L2.03157 0C2.32803 0.981505 2.55763 1.92387 2.72039 2.8271C2.88896 3.7243 3.01103 4.58538 3.0866 5.41032C3.16798 6.22925 3.21738 7.01505 3.23482 7.76774C3.25226 8.52043 3.26098 9.24301 3.26098 9.93548C3.26098 10.2787 3.25807 10.6099 3.25226 10.929C3.25226 11.2422 3.24935 11.5432 3.24354 11.8323C3.23773 11.9527 3.23192 12.0852 3.2261 12.2297C3.2261 12.3682 3.2261 12.5097 3.2261 12.6542C3.2261 12.7987 3.2261 12.9372 3.2261 13.0697C3.2261 13.2022 3.2261 13.3166 3.2261 13.4129H1.05502Z\" fill=\"#23493c\"/>\n<path d=\"M13.6693 6.05161C14.1052 7.3643 14.608 8.57763 15.1777 9.69161C15.7532 10.7996 16.3606 11.754 17 12.5548L15.3172 14C14.9684 13.5604 14.6226 13.0486 14.2796 12.4645C13.9425 11.8804 13.6082 11.2331 13.2769 10.5226C12.9456 9.80602 12.6201 9.03226 12.3004 8.20129C11.9806 7.37032 11.6639 6.48817 11.35 5.55484C11.1058 6.30753 10.8355 7.08129 10.5391 7.87613C10.2426 8.67097 9.92292 9.44473 9.57996 10.1974C9.24282 10.9441 8.89115 11.6456 8.52494 12.3019C8.15873 12.9523 7.78381 13.5123 7.40016 13.9819L5.69992 12.5548C6.008 12.1815 6.31317 11.748 6.61544 11.2542C6.9177 10.7604 7.21125 10.2335 7.49608 9.67355C7.7809 9.10753 8.0512 8.51742 8.30696 7.90323C8.56854 7.28903 8.80977 6.67183 9.03065 6.05161C9.19341 5.52774 9.35036 5.00086 9.50149 4.47097C9.65262 3.94108 9.78341 3.42925 9.89386 2.93548C10.0043 2.44172 10.0915 1.97806 10.1554 1.54452C10.2252 1.10495 10.2601 0.713549 10.2601 0.370324H12.4224C12.4224 0.737635 12.4515 1.13505 12.5096 1.56258C12.5736 1.99011 12.6578 2.44473 12.7625 2.92645C12.8729 3.40817 13.0037 3.91097 13.1548 4.43484C13.3118 4.95871 13.4833 5.49763 13.6693 6.05161Z\" fill=\"#23493c\"/>\n</svg>\n",
"vuesax-linear:number-24": "<svg width=\"21\" height=\"12\" viewBox=\"0 0 21 12\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M7.59689 0.399477C7.61323 0.446474 7.64862 0.558746 7.70308 0.736292C7.75754 0.913838 7.812 1.12794 7.86646 1.37859C7.92092 1.62402 7.96993 1.89034 8.01349 2.17755C8.05706 2.45953 8.07884 2.73107 8.07884 2.99217C8.07884 3.53003 7.98626 3.99739 7.80111 4.39426C7.61595 4.79112 7.37633 5.1201 7.08226 5.3812C6.78819 5.63708 6.45327 5.82768 6.07751 5.953C5.7072 6.07833 5.33416 6.14099 4.9584 6.14099C4.58809 6.14099 4.24772 6.09922 3.93731 6.01567C3.63235 5.92689 3.34644 5.8094 3.0796 5.66318C3.12861 6.11749 3.16673 6.56919 3.19396 7.01828C3.22119 7.46736 3.24025 7.94256 3.25114 8.44386C3.26203 8.93995 3.26748 9.47781 3.26748 10.0574C3.27293 10.6371 3.27293 11.2846 3.26748 12H1.25798V10.1044C1.25798 9.48825 1.24709 8.83812 1.2253 8.15405C1.20897 7.46475 1.15996 6.74151 1.07827 5.98433C0.996581 5.22715 0.871328 4.43342 0.702508 3.60313C0.533688 2.77285 0.299519 1.906 0 1.00261L1.93598 0.40731L2.2709 1.36292C2.29813 1.44125 2.34169 1.56658 2.4016 1.7389C2.46695 1.906 2.55136 2.09661 2.65483 2.3107C2.7583 2.51958 2.88083 2.73629 3.02242 2.96084C3.16946 3.18016 3.33827 3.38381 3.52888 3.5718C3.71948 3.75457 3.93187 3.906 4.16604 4.02611C4.40565 4.14099 4.66977 4.19843 4.9584 4.19843C5.02375 4.19843 5.11633 4.18799 5.23614 4.1671C5.36139 4.14621 5.48392 4.09661 5.60373 4.01828C5.72898 3.93473 5.8379 3.81201 5.93048 3.65013C6.02305 3.48825 6.06934 3.26893 6.06934 2.99217C6.06934 2.83029 6.05573 2.65535 6.0285 2.46736C6.00127 2.27415 5.96587 2.08877 5.92231 1.91123C5.88419 1.72846 5.84062 1.55875 5.79161 1.40209C5.74804 1.24021 5.7072 1.10444 5.66908 0.994778L7.59689 0.399477Z\" fill=\"#23493c\"/>\n<path d=\"M17.9907 4.62924C18.1432 4.62924 18.2929 4.62924 18.44 4.62924C18.587 4.62402 18.734 4.61619 18.8811 4.60574C19.0281 4.5953 19.1806 4.58224 19.3385 4.56658C19.5019 4.54569 19.6762 4.51958 19.8613 4.48825L20.3188 6.25065C20.0356 6.32898 19.7633 6.39687 19.5019 6.45431C19.2405 6.50653 18.9709 6.55091 18.6932 6.58747C18.4155 6.6188 18.1187 6.64491 17.8028 6.6658C17.4924 6.68146 17.1412 6.68929 16.7491 6.68929C16.1827 6.68929 15.6054 6.64752 15.0173 6.56397C14.4346 6.48042 13.8791 6.32898 13.3509 6.10966C13.3836 6.53264 13.4108 6.91906 13.4326 7.26893C13.4598 7.6188 13.4789 7.95039 13.4897 8.26371C13.5006 8.57702 13.5088 8.88251 13.5143 9.18016C13.5197 9.47781 13.5224 9.7859 13.5224 10.1044C13.5224 10.3238 13.5197 10.5483 13.5143 10.7781C13.5143 11.0026 13.5143 11.248 13.5143 11.5144V12H11.4884V11.5065C11.4884 10.7389 11.483 10.0209 11.4721 9.35248C11.4666 8.68407 11.4476 8.05222 11.4149 7.45692C11.3877 6.86162 11.3468 6.29243 11.2924 5.74935C11.2379 5.20627 11.1644 4.67363 11.0718 4.15144C10.9792 3.62924 10.8649 3.10966 10.7287 2.59269C10.5926 2.07572 10.4292 1.54569 10.2386 1.00261L12.1991 0.40731C12.2862 0.678851 12.3652 0.94778 12.436 1.2141C12.5122 1.48042 12.5857 1.75196 12.6565 2.02872C12.7001 2.18016 12.7382 2.33681 12.7709 2.49869C12.809 2.65535 12.8499 2.81201 12.8934 2.96867C12.9915 3.33943 13.1439 3.6423 13.3509 3.87728C13.5633 4.10705 13.792 4.27676 14.037 4.38642C14.0044 4.30809 13.969 4.22454 13.9309 4.13577C13.8927 4.047 13.8573 3.94778 13.8247 3.83812C13.7974 3.72324 13.7729 3.59791 13.7511 3.46214C13.7348 3.32637 13.7266 3.17493 13.7266 3.00783C13.7266 2.53264 13.8219 2.10966 14.0125 1.7389C14.2086 1.36292 14.4618 1.047 14.7722 0.791123C15.0881 0.530026 15.4421 0.334203 15.8342 0.203655C16.2317 0.067885 16.6292 0 17.0268 0C17.3426 0 17.634 0.0365535 17.9008 0.10966C18.1731 0.177546 18.4264 0.266318 18.6605 0.375979C18.8947 0.485639 19.1153 0.608355 19.3222 0.744125C19.5346 0.874673 19.7415 1.00261 19.943 1.12794L18.9791 2.78068C18.7885 2.65013 18.6088 2.53525 18.44 2.43603C18.2712 2.33159 18.1078 2.24543 17.9499 2.17755C17.7919 2.10966 17.6367 2.05744 17.4842 2.02089C17.3372 1.97911 17.1847 1.95561 17.0268 1.95039H16.9778C16.8362 1.95039 16.6837 1.97389 16.5203 2.02089C16.357 2.06788 16.2045 2.14099 16.0629 2.24021C15.9213 2.33942 15.8015 2.46214 15.7035 2.60835C15.6109 2.74935 15.5646 2.91123 15.5646 3.09399C15.5646 3.39164 15.6381 3.63969 15.7851 3.83812C15.9322 4.03655 16.1201 4.19582 16.3488 4.31593C16.583 4.43081 16.8444 4.51175 17.133 4.55875C17.4216 4.60574 17.7075 4.62924 17.9907 4.62924Z\" fill=\"#23493c\"/>\n</svg>\n",
"vuesax-linear:heart-fill": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M16.44 3.09998C14.63 3.09998 13.01 3.97998 12 5.32998C10.99 3.97998 9.37 3.09998 7.56 3.09998C4.49 3.09998 2 5.59998 2 8.68998C2 9.87998 2.19 10.98 2.52 12C4.1 17 8.97 19.99 11.38 20.81C11.72 20.93 12.28 20.93 12.62 20.81C15.03 19.99 19.9 17 21.48 12C21.81 10.98 22 9.87998 22 8.68998C22 5.59998 19.51 3.09998 16.44 3.09998Z\" fill=\"#8D6A46\"/>\n</svg>\n",
"vuesax-linear:usd-coins": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M7.1 16.8999C9.8 19.5999 14.3 19.5999 17 16.8999\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M16.9 7.09995C14.2 4.39995 9.69999 4.39995 6.99999 7.09995\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M2 12C2 17.5228 6.47715 22 12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12Z\" stroke=\"#17191C\" stroke-width=\"1.5\" stroke-miterlimit=\"10\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>\n",
"vuesax-linear:heart-transparent": "<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M12.62 20.81C12.28 20.93 11.72 20.93 11.38 20.81C8.48 19.82 2 15.69 2 8.68998C2 5.59998 4.49 3.09998 7.56 3.09998C9.38 3.09998 10.99 3.97998 12 5.33998C13.01 3.97998 14.63 3.09998 16.44 3.09998C19.51 3.09998 22 5.59998 22 8.68998C22 15.69 15.52 19.82 12.62 20.81Z\" fill=\"white\" fill-opacity=\"0.01\" stroke=\"#8D6A46\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>\n",
"vuesax-linear:shield_dollar": "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\">\n<path d=\"M10.49 2.23L5.49997 4.11C4.34997 4.54 3.40997 5.9 3.40997 7.12V14.55C3.40997 15.73 4.18997 17.28 5.13997 17.99L9.43997 21.2C10.85 22.26 13.17 22.26 14.58 21.2L18.88 17.99C19.83 17.28 20.61 15.73 20.61 14.55V7.12C20.61 5.89 19.67 4.53 18.52 4.1L13.53 2.23C12.68 1.92 11.32 1.92 10.49 2.23Z\" stroke=\"#1C2D56\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M9 13.4905C9 14.4976 9.78333 15.281 10.7905 15.281H12.6929C13.4762 15.281 14.2595 14.6095 14.2595 13.7143C14.2595 12.7071 13.8119 12.3714 13.2524 12.1476L10.119 11.0286C9.33571 10.9167 9 10.581 9 9.68572C9 8.79048 9.67143 8.11905 10.5667 8.11905H12.581C13.5881 8.11905 14.3714 8.90238 14.3714 9.90952\" stroke=\"#1C2D56\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M11.5739 7V16.4\" stroke=\"#1C2D56\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>\n"
"vuesax-linear:shield_dollar": "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\">\n<path d=\"M10.49 2.23L5.49997 4.11C4.34997 4.54 3.40997 5.9 3.40997 7.12V14.55C3.40997 15.73 4.18997 17.28 5.13997 17.99L9.43997 21.2C10.85 22.26 13.17 22.26 14.58 21.2L18.88 17.99C19.83 17.28 20.61 15.73 20.61 14.55V7.12C20.61 5.89 19.67 4.53 18.52 4.1L13.53 2.23C12.68 1.92 11.32 1.92 10.49 2.23Z\" stroke=\"#23493c\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M9 13.4905C9 14.4976 9.78333 15.281 10.7905 15.281H12.6929C13.4762 15.281 14.2595 14.6095 14.2595 13.7143C14.2595 12.7071 13.8119 12.3714 13.2524 12.1476L10.119 11.0286C9.33571 10.9167 9 10.581 9 9.68572C9 8.79048 9.67143 8.11905 10.5667 8.11905H12.581C13.5881 8.11905 14.3714 8.90238 14.3714 9.90952\" stroke=\"#23493c\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n<path d=\"M11.5739 7V16.4\" stroke=\"#23493c\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n</svg>\n"
}
@@ -161,7 +161,7 @@ const wageLabel = computed(() => {
font-size: 10px;
font-weight: 700;
color: #fff;
background: @ink;
background: @primary;
}
.pc__flag--soft {
@@ -273,11 +273,6 @@
</Transition>
</Teleport>
<NotifyVant :timeOut="3000" v-model="notify" :color="'background-color: #14161A'">
<div class="font-bold text-right mb-2">ثبت سفارش</div>
<div>محصول با موفقیت به سبد خرید افزوده شد</div>
</NotifyVant>
<DialogVant :timeOut="-1" v-model:show="loginNotify" :closeOnClickOverlay="true">
<template v-slot:img>
<img :src="loginDialogImage" alt="" class="opacity-80" />
@@ -301,7 +296,7 @@ import { useRouter } from 'vue-router'
import Icon from '../icon/Icon.vue'
import GallerySlider from './GallerySlider.vue'
import Spinner from '../Spinner.vue'
import NotifyVant from '../NotifyVant.vue'
import { toast } from '../../composables/useToast'
import DialogVant from '../DialogVant.vue'
import { useProduct, isVariantOrderable } from '../../composables/useProduct'
import { useProductDetail } from '../../composables/useProductDetail'
@@ -327,7 +322,6 @@ const close = () => {
if (router.currentRoute.value.name === 'singleProduct') router.back()
}
const notify = ref(false)
const loginNotify = ref(false)
const imageIndex = ref(0)
const bodyOpen = ref(false)
@@ -484,7 +478,7 @@ const addToCart = () => {
// Previously the "added to cart" toast fired either way, telling the customer
// something had been added when nothing had. Kept in step with user-app-v2.
if (!cart.addToCart(storeProduct.value)) return
notify.value = true
toast.success('محصول با موفقیت به سبد خرید افزوده شد', { title: 'ثبت سفارش' })
}
const toggleFav = (e: Event) => {
@@ -732,8 +726,8 @@ onBeforeUnmount(() => {
transition: border-color 0.18s ease, background 0.18s ease;
}
.pd__variant.is-on {
background: @ink;
border-color: @ink;
background: @primary;
border-color: @primary;
}
.pd__variantImg {
width: 100%;
@@ -931,7 +925,7 @@ onBeforeUnmount(() => {
font-weight: 800;
text-decoration: none;
color: #fff;
background: @ink;
background: @primary;
transition: transform 0.18s ease, opacity 0.18s ease;
}
.pd__cta:active {
@@ -942,9 +936,9 @@ onBeforeUnmount(() => {
opacity: 0.45;
}
.pd__cta--ghost {
color: @ink;
color: @primary;
background: @canvas;
border: 1px solid @ink;
border: 1px solid @primary;
}
/* ── Full-screen preview ─────────────────────────────────── */
@@ -186,8 +186,8 @@ const closeFilters = (sendQuery: boolean): void => {
.filt__chip.is-on {
color: #fff;
background: @ink;
border-color: @ink;
background: @primary;
border-color: @primary;
}
.filt__chip:active {
@@ -280,7 +280,7 @@ const closeFilters = (sendQuery: boolean): void => {
.filt__apply {
color: #fff;
background: @ink;
background: @primary;
}
.filt__clear:active,
@@ -0,0 +1,325 @@
<!--
One toast: a glass card in the same family as the bottom nav — a square
icon tile on the start side, title + message, and a thin countdown line.
The countdown is a CSS animation; its `animationend` is what closes the
toast, so pausing it (finger held on the card) pauses the timer too, with
no JS clock to keep in sync. Swipe sideways or up to throw it away.
-->
<template>
<div
class="toast"
:class="[`toast--${item.type}`, { 'is-held': held, 'is-dragging': dragging }]"
:style="dragStyle"
role="status"
@pointerdown="onDown"
@pointermove="onMove"
@pointerup="onUp"
@pointercancel="onUp"
>
<span class="toast__tile" aria-hidden="true">
<span class="toast__ripple" />
<Icon :icon="item.icon" size="22" />
</span>
<div class="toast__body">
<div v-if="item.title" class="toast__title">{{ item.title }}</div>
<div class="toast__message">{{ item.message }}</div>
</div>
<span
v-if="item.duration > 0"
class="toast__progress"
:style="{ animationDuration: `${item.duration}ms` }"
@animationend="emit('close')"
/>
</div>
</template>
<script setup lang="ts">
import { computed, ref } from 'vue'
import Icon from '../icon/Icon.vue'
import type { ToastItem } from '../../composables/useToast'
defineProps<{ item: ToastItem }>()
const emit = defineEmits<{ (e: 'close'): void }>()
// A drag past either threshold dismisses; anything shorter springs back.
const SWIPE_X = 80
const SWIPE_UP = 36
const held = ref(false)
const dragging = ref(false)
const dx = ref(0)
const dy = ref(0)
let startX = 0
let startY = 0
const flung = ref(false)
let downAt = 0
const dragStyle = computed(() => {
if (flung.value) {
return {
transform: `translate(${dx.value}px, ${dy.value}px)`,
opacity: '0',
transition: 'transform 0.22s ease-in, opacity 0.22s ease-in',
}
}
if (!dragging.value) return undefined
// Upward drags follow the finger; downward ones are damped so the card
// only stretches a little, like pulling on something anchored at the top.
const y = dy.value < 0 ? dy.value : dy.value * 0.25
const fade = 1 - Math.min(Math.abs(dx.value) / 220, 0.6)
return {
transform: `translate(${dx.value}px, ${y}px) rotate(${dx.value * 0.03}deg)`,
opacity: String(fade),
transition: 'none',
}
})
function onDown(e: PointerEvent) {
held.value = true
startX = e.clientX
startY = e.clientY
downAt = Date.now()
;(e.currentTarget as HTMLElement).setPointerCapture(e.pointerId)
}
function onMove(e: PointerEvent) {
if (!held.value) return
dx.value = e.clientX - startX
dy.value = e.clientY - startY
if (!dragging.value && Math.hypot(dx.value, dy.value) > 6) dragging.value = true
}
function onUp() {
held.value = false
if (!dragging.value) {
// A quick tap closes it; a long hold was only pausing it to read.
if (Date.now() - downAt < 250) emit('close')
return
}
if (Math.abs(dx.value) > SWIPE_X || dy.value < -SWIPE_UP) {
flung.value = true
dx.value = Math.abs(dx.value) > SWIPE_X ? Math.sign(dx.value) * window.innerWidth : dx.value
dy.value = dy.value < -SWIPE_UP ? -160 : dy.value
dragging.value = false
setTimeout(() => emit('close'), 200)
return
}
dragging.value = false
dx.value = 0
dy.value = 0
}
</script>
<style scoped lang="less">
.toast {
--accent: @wine;
position: relative;
display: flex;
align-items: center;
gap: 12px;
width: 100%;
padding: 10px 10px 12px 14px;
border-radius: 20px;
overflow: hidden;
pointer-events: auto;
touch-action: none;
cursor: grab;
transition: transform 0.45s cubic-bezier(0.2, 1.4, 0.4, 1), opacity 0.3s ease;
// Same glass recipe as the bottom nav, so the two read as one system.
background:
radial-gradient(120% 160% at 0% 0%, fade(@canvas, 60%) 0%, fade(@canvas, 0%) 55%),
radial-gradient(80% 140% at 100% 100%, fade(@ink, 4%) 0%, fade(@ink, 0%) 60%),
linear-gradient(160deg, fade(@canvas, 72%) 0%, fade(@canvas, 50%) 100%);
-webkit-backdrop-filter: blur(24px) saturate(200%) brightness(1.05);
backdrop-filter: blur(24px) saturate(200%) brightness(1.05);
box-shadow:
inset 0 1px 1px fade(@canvas, 90%),
inset 0 0 0 0.5px fade(@canvas, 40%),
0 18px 40px -16px rgba(20, 22, 26, 0.35),
0 1px 3px rgba(20, 22, 26, 0.06);
// Edge light, masked to a 1px ring.
&::after {
content: '';
position: absolute;
inset: 0;
padding: 1px;
border-radius: inherit;
background: linear-gradient(
145deg,
fade(@canvas, 100%) 0%,
fade(@canvas, 30%) 40%,
fade(@canvas, 10%) 70%,
fade(@canvas, 70%) 100%
);
-webkit-mask:
linear-gradient(#000 0 0) content-box,
linear-gradient(#000 0 0);
-webkit-mask-composite: xor;
mask-composite: exclude;
pointer-events: none;
}
&.is-held:not(.is-dragging) {
transform: scale(0.98);
}
&.is-dragging {
cursor: grabbing;
}
}
.toast--success {
--accent: @green;
}
.toast--error {
--accent: @red;
}
.toast--warning {
--accent: @secondary;
}
.toast--info {
--accent: @wine;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
.toast {
background: fade(@canvas, 96%);
}
}
// Square rounded tile — the same shape as the nav tiles — tinted by type.
.toast__tile {
position: relative;
flex: 0 0 42px;
display: flex;
align-items: center;
justify-content: center;
width: 42px;
height: 42px;
border-radius: 14px;
color: var(--accent);
background: color-mix(in srgb, var(--accent) 12%, transparent);
box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 16%, transparent);
:deep(svg) {
position: relative;
animation: toast-icon-pop 0.6s 0.12s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}
}
// A ring that pulses out of the tile once as the toast lands.
.toast__ripple {
position: absolute;
inset: 0;
border-radius: inherit;
border: 2px solid var(--accent);
opacity: 0;
animation: toast-ripple 0.9s 0.2s ease-out both;
}
.toast--error .toast__tile :deep(svg) {
animation:
toast-icon-pop 0.6s 0.12s cubic-bezier(0.2, 1.6, 0.4, 1) both,
toast-shake 0.45s 0.55s ease-in-out;
}
.toast__body {
flex: 1;
min-width: 0;
text-align: right;
}
.toast__title {
margin-bottom: 2px;
font-size: 13px;
font-weight: 700;
line-height: 1.5;
color: @ink;
}
.toast__message {
font-size: 12.5px;
font-weight: 500;
line-height: 1.6;
color: @inkSoft;
}
// Countdown line along the bottom, draining toward the start side.
.toast__progress {
position: absolute;
right: 14px;
left: 14px;
bottom: 5px;
height: 2.5px;
border-radius: 2px;
background: var(--accent);
opacity: 0.55;
transform-origin: right center;
animation-name: toast-drain;
animation-timing-function: linear;
animation-fill-mode: forwards;
}
.toast.is-held .toast__progress {
animation-play-state: paused;
}
@keyframes toast-drain {
from {
transform: scaleX(1);
}
to {
transform: scaleX(0);
}
}
@keyframes toast-icon-pop {
0% {
transform: scale(0) rotate(-30deg);
opacity: 0;
}
100% {
transform: scale(1) rotate(0);
opacity: 1;
}
}
@keyframes toast-ripple {
0% {
transform: scale(1);
opacity: 0.5;
}
100% {
transform: scale(1.6);
opacity: 0;
}
}
@keyframes toast-shake {
0%,
100% {
transform: translateX(0);
}
20%,
60% {
transform: translateX(-3px);
}
40%,
80% {
transform: translateX(3px);
}
}
@media (prefers-reduced-motion: reduce) {
.toast__tile :deep(svg),
.toast__ripple {
animation: none !important;
}
}
</style>
@@ -0,0 +1,89 @@
<!--
Renders the shared toast queue (see composables/useToast.ts). Mounted once
in App.vue. Toasts drop in from the top with a spring, the stack slides to
make room, and a closing toast shrinks up and fades out.
-->
<template>
<Teleport to="body">
<div class="toast-host">
<TransitionGroup name="toast">
<ToastCard v-for="item in toasts" :key="item.id" :item="item" @close="dismiss(item.id)" />
</TransitionGroup>
</div>
</Teleport>
</template>
<script setup lang="ts">
import ToastCard from './ToastCard.vue'
import { useToast } from '../../composables/useToast'
const { toasts, dismiss } = useToast()
</script>
<style lang="less">
.toast-host {
position: fixed;
top: 0;
left: 0;
right: 0;
z-index: 3000;
display: flex;
flex-direction: column;
align-items: center;
gap: 8px;
padding: calc(12px + env(safe-area-inset-top, 0px)) 14px 0;
direction: rtl;
pointer-events: none;
> * {
max-width: 420px;
}
}
// Enter: drop from above, slightly small and blurred, then overshoot into place.
.toast-host .toast.toast-enter-active {
transition:
transform 0.6s cubic-bezier(0.2, 1.35, 0.4, 1),
opacity 0.35s ease,
filter 0.4s ease;
}
.toast-host .toast.toast-enter-from {
transform: translateY(-120%) scale(0.88);
opacity: 0;
filter: blur(6px);
}
// Leave: taken out of flow so the stack can glide up behind it.
.toast-host .toast.toast-leave-active {
position: absolute;
left: 14px;
right: 14px;
margin: 0 auto;
transition:
transform 0.32s cubic-bezier(0.5, 0, 0.75, 0),
opacity 0.28s ease,
filter 0.3s ease;
}
.toast-host .toast.toast-leave-to {
transform: translateY(-40%) scale(0.9);
opacity: 0;
filter: blur(4px);
}
.toast-host .toast.toast-move {
transition: transform 0.45s cubic-bezier(0.2, 1.2, 0.4, 1);
}
@media (prefers-reduced-motion: reduce) {
.toast-host .toast.toast-enter-active,
.toast-host .toast.toast-leave-active,
.toast-host .toast.toast-move {
transition: opacity 0.2s ease;
}
.toast-host .toast.toast-enter-from,
.toast-host .toast.toast-leave-to {
transform: none;
filter: none;
}
}
</style>
@@ -0,0 +1,43 @@
/**
* Lets the router hold its scroll until MasterLayout's outgoing page has
* faded out.
*
* vue-router runs scrollBehavior right after the new route renders, which with
* an out-in transition is while the OLD page is still fading — so a scrolled
* page would visibly snap to the top on its way out. MasterLayout reports the
* leave here, and scrollBehavior awaits `afterPageLeave()`, so the scroll lands
* while the new page is still fully transparent.
*
* Routes in FullPageLayout have no transition: no leave is ever reported for
* them and `afterPageLeave()` resolves at once.
*/
// Never hold the scroll longer than this, even if a leave hook goes missing.
const MAX_WAIT_MS = 400
let leaving: Promise<void> | null = null
let finish: (() => void) | null = null
export function pageLeaveStarted() {
finish?.()
leaving = new Promise<void>((resolve) => {
const timer = setTimeout(done, MAX_WAIT_MS)
function done() {
clearTimeout(timer)
if (finish === done) {
finish = null
leaving = null
}
resolve()
}
finish = done
})
}
export function pageLeaveEnded() {
finish?.()
}
export function afterPageLeave(): Promise<void> {
return leaving ?? Promise.resolve()
}
@@ -0,0 +1,43 @@
import { nextTick, ref } from 'vue'
/**
* First-paint entrance shared by the tab screens (Home, Dashboard, Cart):
* once a screen's first data load lands, its sections rise and fade in one
* after another. The styles are the global `.reveal` / `.is-revealed` pair in
* assets/styles/style.less.
*
* MasterLayout renders its routes without keep-alive, so a screen remounts on
* every return to its tab. Which screens have already played is kept here in
* module scope, so the entrance is a first-run flourish that resets only on a
* full reload — replaying it on each tab switch would fight the page
* transition rather than add to it. (A `let` at the top of <script setup>
* would not do this: that code runs once per mount.)
*/
const played = new Set<string>()
export function useReveal(key: string, stepMs = 70) {
const revealed = ref(played.has(key))
// Each item starts a beat after the one before it. Kept small, so the whole
// sequence finishes well under a second and reads as the page arriving.
function revealDelay(i: number) {
return { '--reveal-delay': `${i * stepMs}ms` }
}
// Call once the first load has populated the DOM. Waits for the new nodes
// to be mounted, then for one painted frame in their "before" state — with
// a single frame the browser can resolve both states in the same style pass
// and there is nothing to animate.
async function reveal() {
if (revealed.value) return
await nextTick()
requestAnimationFrame(() =>
requestAnimationFrame(() => {
revealed.value = true
played.add(key)
}),
)
}
return { revealed, revealDelay, reveal }
}
+72
View File
@@ -0,0 +1,72 @@
import { reactive } from 'vue'
/**
* App-wide toasts. One shared queue, rendered by <ToastHost> (mounted once in
* App.vue), so any view or store can call `toast.success(...)` without placing
* a component in its own template.
*/
export type ToastType = 'success' | 'error' | 'info' | 'warning'
export interface ToastOptions {
title?: string
/** ms before it closes by itself; 0 keeps it until the user dismisses it. */
duration?: number
/** Custom icon name; defaults to one per type. */
icon?: string
}
export interface ToastItem {
id: number
type: ToastType
message: string
title?: string
icon: string
duration: number
}
const DEFAULT_DURATION = 3200
// Older toasts beyond this are dropped so the stack never covers the screen.
const MAX_VISIBLE = 3
const ICONS: Record<ToastType, string> = {
success: 'vuesax-linear:tick-circle',
error: 'vuesax-linear:close-circle',
info: 'vuesax-linear:info-circle',
warning: 'vuesax-linear:warning-2',
}
const state = reactive<{ items: ToastItem[] }>({ items: [] })
let nextId = 1
function show(type: ToastType, message: string, options: ToastOptions = {}): number {
const id = nextId++
state.items.push({
id,
type,
message,
title: options.title,
icon: options.icon ?? ICONS[type],
duration: options.duration ?? DEFAULT_DURATION,
})
if (state.items.length > MAX_VISIBLE) state.items.splice(0, state.items.length - MAX_VISIBLE)
return id
}
function dismiss(id: number) {
const i = state.items.findIndex((t) => t.id === id)
if (i !== -1) state.items.splice(i, 1)
}
export const toast = {
show,
dismiss,
success: (message: string, options?: ToastOptions) => show('success', message, options),
error: (message: string, options?: ToastOptions) => show('error', message, options),
info: (message: string, options?: ToastOptions) => show('info', message, options),
warning: (message: string, options?: ToastOptions) => show('warning', message, options),
}
export function useToast() {
return { toasts: state.items, ...toast }
}
+52 -1
View File
@@ -8,7 +8,17 @@
-->
<template>
<section ref="content">
<router-view />
<router-view v-slot="{ Component, route }">
<transition
name="page"
mode="out-in"
@before-leave="pageLeaveStarted"
@after-leave="pageLeaveEnded"
@leave-cancelled="pageLeaveEnded"
>
<component :is="Component" :key="route.name" />
</transition>
</router-view>
<Navigation />
<div class="bg-primary top-[-2rem] fixed h-[2rem] w-full z-10" />
</section>
@@ -19,10 +29,16 @@ import { onBeforeMount, ref } from 'vue'
import { useResizeObserver } from '@vueuse/core'
import Navigation from '../components/ui/Navigation.vue'
import { useWindowDataStore } from '../stores/windowDataStore'
import { pageLeaveStarted, pageLeaveEnded } from '../composables/usePageTransition'
const windowData = useWindowDataStore()
const content = ref<HTMLElement | null>(null)
// Route changes here are tab switches, not a hierarchy, so there is no "back"
// or "forward" direction to honour. The outgoing page fades out quickly and
// the new one fades in; the sense of the page settling into place comes from
// each screen's own section reveal (composables/useReveal.ts).
onBeforeMount(() => {
windowData.setWidth(window.innerWidth)
})
@@ -34,3 +50,38 @@ useResizeObserver(content, (entries) => {
}
})
</script>
<!--
Not scoped: these classes land on the routed page component, which carries
its own scope id, not this layout's.
Opacity only, deliberately. A transform (or filter) on the page root makes it
the containing block for every position: fixed element inside the page — the
top bars, PageBar, the cart's checkout bar — so for the length of the
transition they would ride along with the page, then snap back to the screen
edge when it ends. Opacity has no such effect, so nothing jumps.
-->
<style lang="less">
// Leave is deliberately shorter than enter. With mode="out-in" the two run
// back to back, so a slow exit is dead time the user feels as lag; a quick
// fade out and an unhurried fade in reads as responsive but smooth.
.page-leave-active {
transition: opacity 0.16s cubic-bezier(0.4, 0, 1, 1);
}
.page-enter-active {
transition: opacity 0.42s cubic-bezier(0.32, 0.72, 0, 1);
}
.page-enter-from,
.page-leave-to {
opacity: 0;
}
@media (prefers-reduced-motion: reduce) {
.page-enter-active,
.page-leave-active {
transition: opacity 0.12s linear;
}
}
</style>
+7 -4
View File
@@ -33,11 +33,14 @@ setUnauthorizedHandler(() => {
void router.push({ name: 'login' });
}
});
// Ported from legacy main.ts:32-46 — Vector.svg is both the while-loading and
// the on-error placeholder, so a missing/failed image paints the brand mark
// instead of collapsing the layout.
// Ported from legacy main.ts:32-46, with one change: the brand mark is now only
// the on-error placeholder. As the while-loading placeholder it painted the
// logo into every card first and then swapped it for the real photo a moment
// later — a visible jump on every image. While loading, the library's own
// transparent pixel is used instead, the image is held at opacity 0 and fades
// in once loaded (see `img[lazy]` in style.less); the card's own background
// stands in until then.
app.use(VueLazyLoad, {
loading: Vector,
error: Vector,
});
app.component('container', Container);
+6 -1
View File
@@ -3,6 +3,7 @@ import { useSessionStore } from '../stores/session';
import { useNavStore } from '../stores/navStore';
import { useTransitionStore } from '../stores/transitionStore';
import { api } from '../api/client';
import { afterPageLeave } from '../composables/usePageTransition';
// Legacy lazy-loaded every route component (`component: () => import(...)`) so
// the initial bundle only carries the entry route. Matched here.
@@ -10,7 +11,11 @@ export const router = createRouter({
history: createWebHistory(),
// Ported from legacy router/index.ts:225-237 — restore saved scroll on
// back/forward, otherwise jump to top on every navigation.
scrollBehavior(_to, _from, savedPosition) {
// Waits for MasterLayout's outgoing page to finish fading first, so the
// scroll happens behind the still-transparent incoming page instead of
// jerking the old one to the top mid-fade (see composables/usePageTransition.ts).
async scrollBehavior(_to, _from, savedPosition) {
await afterPageLeave();
if (savedPosition) return savedPosition;
return { top: 0 };
},
+16 -8
View File
@@ -38,11 +38,13 @@
<template #loading><Loading size="18" /></template>
<template #success><span /></template>
<template v-if="cart.items.length">
<div class="cart__items">
<div class="cart__items" :class="{ 'is-revealed': revealed }">
<CartItem
v-for="item in cart.items"
v-for="(item, i) in cart.items"
:key="item.pid + item.vid"
:value="item"
class="reveal"
:style="revealDelay(i)"
@note="
cartData.tempRow = item;
cartData.showPopUp = true;
@@ -119,7 +121,7 @@
</template>
<template v-slot:title>آیا مطمئن به ثبت سفارش هستید ؟</template>
<template v-slot:button>
<div class="text-center text-[#1C2D56]" @click="submitOrder">بله</div>
<div class="text-center text-[#23493c]" @click="submitOrder">بله</div>
<div class="text-center text-[#6b7280]" @click="cartData.notify = false">بی خیال</div>
</template>
</DialogVant>
@@ -132,7 +134,7 @@
<div class="p-8 text-justify">برای ثبت سفارش ابتدا باید وارد حساب کاربری خود شوید.</div>
</template>
<template v-slot:button>
<div class="text-center text-[#1C2D56]" @click="router.push({ name: 'login' })">ورود/ثبت نام</div>
<div class="text-center text-[#23493c]" @click="router.push({ name: 'login' })">ورود/ثبت نام</div>
<div class="text-center text-danger" @click="loginNotify = false">بیخیال</div>
</template>
</DialogVant>
@@ -153,6 +155,7 @@ import DialogVant from '../components/DialogVant.vue'
import CartItem from '../components/product/CartItem.vue'
import { useCartStore, type CartItem as CartItemType } from '../stores/cartStore'
import { useSessionStore } from '../stores/session'
import { useReveal } from '../composables/useReveal'
import { api } from '../api/client'
const router = useRouter()
@@ -162,6 +165,10 @@ const session = useSessionStore()
const loginNotify = ref(false)
const refreshing = ref(false)
// First-paint entrance for the basket rows, the same choreography HomeView
// uses with a slightly shorter beat, since a basket can hold many rows.
const { revealed, revealDelay, reveal } = useReveal('cart', 60)
const cartData = reactive({
loadingPage: false,
showPopUp: false,
@@ -227,6 +234,7 @@ async function onRefresh() {
onMounted(async () => {
await cart.init()
reveal()
})
</script>
@@ -274,7 +282,7 @@ onMounted(async () => {
font-size: 12.5px;
font-weight: 700;
color: #fff;
background: @ink;
background: @primary;
}
.cart__done {
@@ -330,7 +338,7 @@ onMounted(async () => {
font-size: 12.5px;
font-weight: 700;
color: #fff;
background: @ink;
background: @primary;
}
.cart__bar {
@@ -390,7 +398,7 @@ onMounted(async () => {
font-size: 13px;
font-weight: 700;
color: #fff;
background: @ink;
background: @primary;
transition: transform 0.15s ease;
}
@@ -419,6 +427,6 @@ onMounted(async () => {
font-size: 13px;
font-weight: 700;
color: #fff;
background: @ink;
background: @primary;
}
</style>
+22 -8
View File
@@ -40,20 +40,27 @@
<template #loosing><Loading size="18" /></template>
<template #loading><Loading size="18" /></template>
<template #success><span /></template>
<container class="home__body">
<RateStrip :quote="goldPrice" class="home__rate" />
<container class="home__body" :class="{ 'is-revealed': revealed }">
<RateStrip :quote="goldPrice" class="home__rate reveal" :style="revealDelay(0)" />
<ShowcaseSlider v-if="slides.length" :slides="slides" class="home__hero" @select="onSlide" />
<ShowcaseSlider
v-if="slides.length"
:slides="slides"
class="home__hero reveal"
:style="revealDelay(1)"
@select="onSlide"
/>
<CategoryRail
v-if="memory.cats.length"
:categories="memory.cats"
:active-id="null"
class="home__rail"
class="home__rail reveal"
:style="revealDelay(2)"
@select="onCategory"
/>
<section v-if="featured" class="home__section">
<section v-if="featured" class="home__section reveal" :style="revealDelay(3)">
<SectionHead
title="برگزیده منتزر"
subtitle="انتخاب‌شده از میان مجموعه‌های موجود"
@@ -67,7 +74,7 @@
</div>
</section>
<section v-if="newestProducts.length" class="home__section">
<section v-if="newestProducts.length" class="home__section reveal" :style="revealDelay(4)">
<SectionHead
title="تازه‌ها"
subtitle="آخرین افزوده‌های مجموعه"
@@ -85,12 +92,12 @@
</div>
</section>
<section v-if="!loading && !products.length" class="home__empty">
<section v-if="!loading && !products.length" class="home__empty reveal" :style="revealDelay(3)">
<Icon icon="vuesax-linear:box" size="26" />
<p>هنوز محصولی در مجموعه ثبت نشده است.</p>
</section>
<div class="home__trust">
<div class="home__trust reveal" :style="revealDelay(5)">
<div class="home__trustItem">
<Icon icon="vuesax-linear:shield-tick" size="18" />
<span>خرید امن</span>
@@ -137,6 +144,7 @@ import { useConfigStore } from '../stores/configStore'
import type { HomeCategory } from '../stores/configStore'
import { useCartStore } from '../stores/cartStore'
import { useFiltersStore } from '../stores/filtersStore'
import { useReveal } from '../composables/useReveal'
import { api } from '../api/client'
import type { AdminSlide, GoldPriceQuote, ProductSummary } from '../api/client'
@@ -157,6 +165,11 @@ const adminSlides = ref<AdminSlide[] | null>(null)
const productDrawer = ref(false)
const activeProductId = ref<string | null>(null)
// First-paint entrance: played once, after the first data load, so the
// sections settle into place instead of popping in piecemeal. Pull-to-refresh
// and later returns to this tab do not replay it.
const { revealed, revealDelay, reveal } = useReveal('home')
const featured = computed<ProductSummary | null>(() => products.value[0] ?? null)
const gridProducts = computed(() => products.value.slice(1, 5))
const newestProducts = computed(() => products.value.slice(5, 13))
@@ -271,6 +284,7 @@ async function onRefresh() {
onMounted(async () => {
await loadData()
loading.value = false
reveal()
})
</script>

Some files were not shown because too many files have changed in this diff Show More