@ozdao/prometheus-framework 0.2.190 โ†’ 0.2.192

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. package/dist/builder.js +1 -1
  2. package/dist/builder.mjs +1 -1
  3. package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
  4. package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +1 -1
  5. package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
  6. package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.js +1 -1
  7. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
  8. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +1 -1
  9. package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.cjs +1 -1
  10. package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.js +1 -1
  11. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  12. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +1 -1
  13. package/dist/prometheus-framework/src/modules/globals/globals.client.cjs +1 -1
  14. package/dist/prometheus-framework/src/modules/globals/globals.client.js +23 -20
  15. package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.cjs +1 -1
  16. package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.js +1 -1
  17. package/dist/prometheus-framework/src/modules/globals/views/components/layouts/App.vue.cjs +1 -1
  18. package/dist/prometheus-framework/src/modules/globals/views/components/layouts/App.vue.js +80 -49
  19. package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.cjs +1 -1
  20. package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.js +94 -125
  21. package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.cjs +1 -0
  22. package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.js +152 -0
  23. package/dist/prometheus-framework/src/modules/globals/views/components/partials/LocationSelection.vue.cjs +1 -0
  24. package/dist/prometheus-framework/src/modules/globals/views/components/partials/LocationSelection.vue.js +96 -0
  25. package/dist/prometheus-framework/src/modules/icons/entities/IconProfile.vue.cjs +1 -0
  26. package/dist/prometheus-framework/src/modules/icons/entities/IconProfile.vue.js +28 -0
  27. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
  28. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +2 -2
  29. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
  30. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +1 -1
  31. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  32. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +2 -2
  33. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
  34. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +2 -2
  35. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
  36. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +2 -2
  37. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
  38. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +1 -1
  39. package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.cjs +1 -1
  40. package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.js +1 -1
  41. package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.cjs +1 -1
  42. package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.js +2 -2
  43. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  44. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +1 -1
  45. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  46. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +2 -2
  47. package/dist/style.css +1 -1
  48. package/package.json +1 -1
  49. package/src/builder/webpack/webpack.config.base.js +1 -1
  50. package/src/components/index.js +0 -1
  51. package/src/main.js +0 -3
  52. package/src/modules/globals/globals.client.js +8 -6
  53. package/src/modules/globals/views/components/layouts/App.vue +44 -6
  54. package/src/modules/globals/views/components/layouts/Client.vue +2 -47
  55. package/src/modules/globals/views/components/partials/Header.vue +10 -8
  56. package/src/modules/globals/views/components/sections/Walkthrough.vue +5 -5
  57. /package/src/{components/LocationSelection โ†’ modules/globals/views/components/partials}/LocationSelection.vue +0 -0
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),c=require("vue-router"),d=require("../../../orders/components/blocks/CardOrderItem.vue.cjs"),u=require("../../../../components/Chips/Chips.vue2.cjs"),m=require("../../../icons/placeholders/PlaceholderOrganizationPic.vue.cjs"),h=require("../../../icons/entities/IconPrice.vue.cjs"),g=require("../../../icons/entities/IconShopcart.vue.cjs"),f=require("../../../icons/entities/IconTime.vue.cjs"),k=require("../elements/ButtonToggleMembership.vue.cjs"),w={class:"flex pos-relative"},b=["src"],z={class:"pos-relative w-100 flex-h-center flex flex-column flex-child-1 flex-child mn-l-thin w-100"},B={class:"h4 t-truncate"},y={key:1,class:"flex-center gap-thin pd-r-thin pd-l-thin flex-nowrap flex mn-t-thin bg-white radius-extra w-max"},p={class:"mn-t-thin mn-b-thin"},V={key:0,class:"mn-b-small mn-t-small w-100 flex-nowrap flex flex-v-center pd-small bg-white radius-medium"},v={class:"mn-r-thin"},E={key:0,class:"t-transp mn-r-thin"},N={key:1,class:"mn-r-thin"},x={class:"mn-r-thin"},S={class:"mn-r-thin"},C={key:1,class:"w-100 o-scroll radius-medium"},M={class:"w-max flex-nowrap flex gap-thin"},q=e.createElementVNode("button",{class:"pd-thin w-15r radius-medium bg-main button"}," View menu ",-1),O={__name:"CardOrganization",props:{user:String,organization:Object,showProducts:{type:Boolean,default:!1},showFollowers:{type:Boolean,default:!0},showRating:{type:Boolean,default:!1},showFeatured:{type:Boolean,default:!0},showTags:{type:Boolean,default:!0}},emits:["updateMembership"],setup(t,{emit:l}){const s=l;return c.useRouter(),(o,i)=>{var a,r;return e.openBlock(),e.createElementBlock("div",{class:"o-hidden pos-relative cursor-pointer bg-light pd-small",onClick:i[1]||(i[1]=n=>o.$router.push({name:"Organization",params:{_id:t.organization._id}}))},[e.createElementVNode("div",w,[t.organization.profile.photo&&t.organization.profile.photo.length>0?(e.openBlock(),e.createElementBlock("img",{key:0,src:(o.FILE_SERVER_URL||"")+t.organization.profile.photo,class:"h-4r w-4r radius-extra bg-white"},null,8,b)):(e.openBlock(),e.createBlock(m.default,{key:1,class:"h-4r w-4r"})),e.createElementVNode("div",z,[e.createElementVNode("p",B,e.toDisplayString(t.organization.profile.name),1),t.showTags&&((a=t.organization.profile.tags)==null?void 0:a.length)>0?(e.openBlock(),e.createBlock(u.default,{key:0,chips:t.organization.profile.tags.slice(0,3),class:"pos-relative p-small"},null,8,["chips"])):e.createCommentVNode("",!0),t.showFollowers?(e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("p",p,e.toDisplayString(t.organization.numberOfSubscribers)+" followers",1),(r=t.user)!=null&&r._id&&t.organization.owner!==t.user._id?(e.openBlock(),e.createBlock(k.default,{key:0,user:t.user._id,type:"organization",role:"subscriber",target:t.organization._id,status:t.organization.isSubscriber,text:{create:"+",remove:"-"},onUpdateMembership:i[0]||(i[0]=n=>s("updateMembership",n,"isSubscriber","numberOfSubscribers")),class:"i-semi"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])]),t.showProducts?(e.openBlock(),e.createElementBlock("div",V,[e.createVNode(f.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",v,e.toDisplayString(t.organization.distance?t.organization.distance>50?"3-5 days":Math.ceil((10+3*t.organization.distance)/5)*5+"-"+Math.ceil((20+3*t.organization.distance)/5)*5+" MIN":"Unavailable"),1),t.organization.distance&&t.organization.distance<50?(e.openBlock(),e.createElementBlock("span",E,"|")):e.createCommentVNode("",!0),t.organization.distance&&t.organization.distance<50?(e.openBlock(),e.createElementBlock("span",N,e.toDisplayString(t.organization.distance?t.organization.distance.toFixed(1)+" KM":""),1)):e.createCommentVNode("",!0),e.createVNode(h.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",x,e.toDisplayString(o.returnCurrency())+"500 ",1),e.createVNode(g.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",S,e.toDisplayString(t.organization.products.length)+" products",1)])):e.createCommentVNode("",!0),t.showProducts&&t.organization.products.length>0?(e.openBlock(),e.createElementBlock("div",C,[e.createElementVNode("div",M,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.organization.products.slice(0,5),n=>(e.openBlock(),e.createBlock(d.default,{onClick:e.withModifiers(P=>o.$router.push({name:"Product Organization",params:{_id:t.organization._id,product:n._id}}),["stop"]),key:n._id,editable:!1,product:n,class:"pd-thin w-15r radius-medium bg-white"},null,8,["onClick","product"]))),128)),q])])):e.createCommentVNode("",!0)])}}};exports.default=O;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),c=require("vue-router"),d=require("../../../orders/components/blocks/CardOrderItem.vue.cjs"),u=require("../../../../components/Chips/Chips.vue.cjs"),m=require("../../../icons/placeholders/PlaceholderOrganizationPic.vue.cjs"),h=require("../../../icons/entities/IconPrice.vue.cjs"),g=require("../../../icons/entities/IconShopcart.vue.cjs"),f=require("../../../icons/entities/IconTime.vue.cjs"),k=require("../elements/ButtonToggleMembership.vue.cjs"),w={class:"flex pos-relative"},b=["src"],z={class:"pos-relative w-100 flex-h-center flex flex-column flex-child-1 flex-child mn-l-thin w-100"},B={class:"h4 t-truncate"},y={key:1,class:"flex-center gap-thin pd-r-thin pd-l-thin flex-nowrap flex mn-t-thin bg-white radius-extra w-max"},p={class:"mn-t-thin mn-b-thin"},V={key:0,class:"mn-b-small mn-t-small w-100 flex-nowrap flex flex-v-center pd-small bg-white radius-medium"},v={class:"mn-r-thin"},E={key:0,class:"t-transp mn-r-thin"},N={key:1,class:"mn-r-thin"},x={class:"mn-r-thin"},S={class:"mn-r-thin"},C={key:1,class:"w-100 o-scroll radius-medium"},M={class:"w-max flex-nowrap flex gap-thin"},q=e.createElementVNode("button",{class:"pd-thin w-15r radius-medium bg-main button"}," View menu ",-1),O={__name:"CardOrganization",props:{user:String,organization:Object,showProducts:{type:Boolean,default:!1},showFollowers:{type:Boolean,default:!0},showRating:{type:Boolean,default:!1},showFeatured:{type:Boolean,default:!0},showTags:{type:Boolean,default:!0}},emits:["updateMembership"],setup(t,{emit:l}){const s=l;return c.useRouter(),(o,i)=>{var a,r;return e.openBlock(),e.createElementBlock("div",{class:"o-hidden pos-relative cursor-pointer bg-light pd-small",onClick:i[1]||(i[1]=n=>o.$router.push({name:"Organization",params:{_id:t.organization._id}}))},[e.createElementVNode("div",w,[t.organization.profile.photo&&t.organization.profile.photo.length>0?(e.openBlock(),e.createElementBlock("img",{key:0,src:(o.FILE_SERVER_URL||"")+t.organization.profile.photo,class:"h-4r w-4r radius-extra bg-white"},null,8,b)):(e.openBlock(),e.createBlock(m.default,{key:1,class:"h-4r w-4r"})),e.createElementVNode("div",z,[e.createElementVNode("p",B,e.toDisplayString(t.organization.profile.name),1),t.showTags&&((a=t.organization.profile.tags)==null?void 0:a.length)>0?(e.openBlock(),e.createBlock(u.default,{key:0,chips:t.organization.profile.tags.slice(0,3),class:"pos-relative p-small"},null,8,["chips"])):e.createCommentVNode("",!0),t.showFollowers?(e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("p",p,e.toDisplayString(t.organization.numberOfSubscribers)+" followers",1),(r=t.user)!=null&&r._id&&t.organization.owner!==t.user._id?(e.openBlock(),e.createBlock(k.default,{key:0,user:t.user._id,type:"organization",role:"subscriber",target:t.organization._id,status:t.organization.isSubscriber,text:{create:"+",remove:"-"},onUpdateMembership:i[0]||(i[0]=n=>s("updateMembership",n,"isSubscriber","numberOfSubscribers")),class:"i-semi"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])]),t.showProducts?(e.openBlock(),e.createElementBlock("div",V,[e.createVNode(f.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",v,e.toDisplayString(t.organization.distance?t.organization.distance>50?"3-5 days":Math.ceil((10+3*t.organization.distance)/5)*5+"-"+Math.ceil((20+3*t.organization.distance)/5)*5+" MIN":"Unavailable"),1),t.organization.distance&&t.organization.distance<50?(e.openBlock(),e.createElementBlock("span",E,"|")):e.createCommentVNode("",!0),t.organization.distance&&t.organization.distance<50?(e.openBlock(),e.createElementBlock("span",N,e.toDisplayString(t.organization.distance?t.organization.distance.toFixed(1)+" KM":""),1)):e.createCommentVNode("",!0),e.createVNode(h.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",x,e.toDisplayString(o.returnCurrency())+"500 ",1),e.createVNode(g.default,{class:"i-medium mn-r-micro"}),e.createElementVNode("span",S,e.toDisplayString(t.organization.products.length)+" products",1)])):e.createCommentVNode("",!0),t.showProducts&&t.organization.products.length>0?(e.openBlock(),e.createElementBlock("div",C,[e.createElementVNode("div",M,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.organization.products.slice(0,5),n=>(e.openBlock(),e.createBlock(d.default,{onClick:e.withModifiers(P=>o.$router.push({name:"Product Organization",params:{_id:t.organization._id,product:n._id}}),["stop"]),key:n._id,editable:!1,product:n,class:"pd-thin w-15r radius-medium bg-white"},null,8,["onClick","product"]))),128)),q])])):e.createCommentVNode("",!0)])}}};exports.default=O;
@@ -1,7 +1,7 @@
1
1
  import { openBlock as i, createElementBlock as n, createElementVNode as t, createBlock as c, toDisplayString as s, createCommentVNode as a, createVNode as d, Fragment as f, renderList as w, withModifiers as z } from "vue";
2
2
  import { useRouter as b } from "vue-router";
3
3
  import y from "../../../orders/components/blocks/CardOrderItem.vue.js";
4
- import x from "../../../../components/Chips/Chips.vue2.js";
4
+ import x from "../../../../components/Chips/Chips.vue.js";
5
5
  import k from "../../../icons/placeholders/PlaceholderOrganizationPic.vue.js";
6
6
  import v from "../../../icons/entities/IconPrice.vue.js";
7
7
  import p from "../../../icons/entities/IconShopcart.vue.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),c=require("vue-router");require("../../../../../../node_modules/js-cookie/dist/js.cookie.cjs");require("vue-i18n");;/* empty css */const P=require("../../../../components/UploadImage/UploadImage.vue.cjs");;/* empty css */const u=require("../../../../components/Field/Field.vue2.cjs");;/* empty css */const r=require("../../../../components/Checkbox/Checkbox.vue.cjs");require("../../../../../../node_modules/@googlemaps/js-api-loader/dist/index.cjs");;/* empty css */;/* empty css */;/* empty css */const f=require("../../../../components/Button/Button.vue2.cjs"),x=require("../../../../components/Popup/Popup.vue.cjs"),h=require("../../../../components/Block/Block.vue.cjs"),B=require("../../../../components/Feed/Feed.vue.cjs"),D=require("../../../icons/navigation/IconDelete.vue.cjs");;/* empty css */;/* empty css */const b=require("../../../users/components/blocks/CardUser.vue.cjs"),g=require("../../../globals/views/store/globals.cjs"),t=require("../../store/departments.cjs"),w=require("../../store/memberships.cjs"),U={class:"for-transition pd-thin w-100"},C={class:"mn-b-thin flex-nowrap flex bg-light pd-medium radius-big"},O={key:0,class:"mn-r-auto"},M={key:1,class:"mn-r-auto"},R={class:"flex-nowrap flex gap-thin pd-thin"},S={class:"cols-2-fit-content"},T={class:"w-100 flex-child-grow-1 flex-child"},z={class:"cols-2 gap-thin"},A={class:"bg-light pd-medium o-hidden radius-big"},F=e.createElementVNode("h3",{class:"mn-b-semi"},"Department Settings",-1),I=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please settings for your department:",-1),L={class:"cols-1 gap-thin"},j={class:"bg-light pd-medium o-hidden radius-big"},G=e.createElementVNode("h3",{class:"mn-b-semi"},"Acessess",-1),H=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please select organization accesses for user in department:",-1),J={class:"cols-1 gap-thin"},K=e.createElementVNode("h4",null,"Gallery",-1),Q=e.createElementVNode("h4",null,"Products",-1),W=e.createElementVNode("h4",null,"Orders",-1),X=e.createElementVNode("h4",null,"Departments",-1),Y={__name:"DepartmentEdit",setup(Z){const N=c.useRouter(),d=c.useRoute();async function V(){e.ref(w.state.memberships),d.params.department&&await t.actions.readOne(d.params.department)}V();const n=e.ref(!1),_=e.ref(null);function y(o){n.value=!0}function i(){n.value=!1,_.value=null}e.ref(!1),e.ref(null);async function k(){d.params.department&&await t.actions.update(d.params._id,t.state.department),d.params.department||await t.actions.create(d.params._id,t.state.department)}function E(){N.push({name:"Organization Members",params:{_id:d.params._id}})}async function v(){confirm("Are you sure you want to delete this department?")&&await t.actions.delete(d.params._id,t.state.department)}function q(o){confirm("Are you sure you want to remove this member?")&&g.actions.delete(t.state.department.members,{_id:o.user._id})}return(o,a)=>(e.openBlock(),e.createElementBlock("div",U,[e.createElementVNode("header",C,[e.unref(d).params.department?(e.openBlock(),e.createElementBlock("h1",O,"Edit Department")):(e.openBlock(),e.createElementBlock("h1",M,"Create Department")),e.createElementVNode("section",R,[e.unref(d).params.department?(e.openBlock(),e.createBlock(f.default,{key:0,submit:v,callback:o.redirectToDash,class:"bg-red"},{default:e.withCtx(()=>[e.createTextVNode("Delete")]),_:1},8,["callback"])):e.createCommentVNode("",!0),e.createVNode(f.default,{submit:k,callback:E,class:"bg-main"},{default:e.withCtx(()=>[e.createTextVNode("Save")]),_:1})])]),t.state.department.profile?(e.openBlock(),e.createBlock(h.default,{key:0,title:"Profile",class:"mn-b-thin"},{default:e.withCtx(()=>[e.createElementVNode("div",S,[e.createVNode(P.default,{photo:t.state.department.profile.photo,"onUpdate:photo":a[0]||(a[0]=s=>t.state.department.profile.photo=s),uploadPath:"organizations/"+t.state.department.name+"/avatars",class:"w-8r aspect-1x1 o-hidden mn-r-small radius-extra"},null,8,["photo","uploadPath"]),e.createElementVNode("div",T,[e.createVNode(u.default,{field:t.state.department.profile.name,"onUpdate:field":a[1]||(a[1]=s=>t.state.department.profile.name=s),label:"Name",placeholder:"Department Name",class:"mn-b-small bg-white radius-small pd-medium",validation:o.organizationName},null,8,["field","validation"]),e.createVNode(u.default,{field:t.state.department.profile.description,"onUpdate:field":a[2]||(a[2]=s=>t.state.department.profile.description=s),label:"Description",placeholder:"Department description (max 120 symbols)",class:"bg-white radius-small pd-medium",validation:o.organizationName},null,8,["field","validation"])])])]),_:1})):e.createCommentVNode("",!0),e.createVNode(h.default,{title:"Team",placeholder:"No members added yet",actions:[{label:"+",function:()=>y()}],class:"cols-1 gap-thin mn-b-thin"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.state.department.members,(s,l)=>(e.openBlock(),e.createBlock(b.default,{class:"h-4r bg-white pd-thin radius-medium w-100",key:l,user:s.user,photo:s.user.profile.photo,name:s.user.profile.name||s.user.phone||s.user.email||s.user._id,position:s.position,action:{label:{is:D.default,props:{class:"i-medium",fill:"rgb(var(--white)"}},method:()=>q(s)}},null,8,["user","photo","name","position","action"]))),128))]),_:1},8,["actions"]),e.createVNode(x.default,{title:"Add member",onClosePopup:i,isPopupOpen:n.value,class:"bg-white w-max-30r radius-big pd-big"},{default:e.withCtx(()=>[e.createVNode(B.default,{search:{placeholder:"Search customer...",class:"bg-light mn-b-thin"},states:{empty:{title:"No Products Found",description:"Currently, there are no such products available."}},store:{read:s=>w.actions.read(s),state:null},options:{target:e.unref(d).params._id},class:"bg-light pd-medium w-min-20r w-max-40r radius-big h-max-20r o-scroll"},{default:e.withCtx(({items:s})=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s,(l,$)=>{var m,p;return e.openBlock(),e.createBlock(b.default,{key:l._id,user:l.user,photo:(m=l.user.profile)==null?void 0:m.photo,name:((p=l.user.profile)==null?void 0:p.name)||l.user.phone||l.user.email,onClick:()=>{g.actions.add(t.state.department.members,{_id:l.user._id,user:l.user,position:"Member"}),i()},class:"h-4r bg-white pd-thin radius-medium w-100 mn-b-thin"},null,8,["user","photo","name","onClick"])}),128))]),_:1},8,["store","options"])]),_:1},8,["isPopupOpen"]),e.createElementVNode("div",z,[e.createElementVNode("div",A,[F,I,e.createElementVNode("div",L,[e.createVNode(r.default,{label:"Hidden department",name:"hidden",class:"w-100 mn-r-small bg-white radius-small pd-small","onUpdate:radio":a[3]||(a[3]=s=>t.state.department.hidden=!t.state.department.hidden),radio:t.state.department.hidden},null,8,["radio"])])]),e.createElementVNode("div",j,[G,H,e.createElementVNode("div",J,[K,e.createVNode(r.default,{label:"Read gallery",name:"readProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.read,"onUpdate:radio":a[4]||(a[4]=s=>t.state.department.accesses.gallery.read=!t.state.department.accesses.gallery.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit gallery",name:"editProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.edit,"onUpdate:radio":a[5]||(a[5]=s=>t.state.department.accesses.gallery.edit=!t.state.department.accesses.gallery.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete gallery",name:"deleteProducts",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.delete,"onUpdate:radio":a[6]||(a[6]=s=>t.state.department.accesses.gallery.delete=!t.state.department.accesses.gallery.delete)},null,8,["radio"]),Q,e.createVNode(r.default,{label:"Read products",name:"readProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.products.read,"onUpdate:radio":a[7]||(a[7]=s=>t.state.department.accesses.products.read=!t.state.department.accesses.products.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit products",name:"editProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.products.edit,"onUpdate:radio":a[8]||(a[8]=s=>t.state.department.accesses.products.edit=!t.state.department.accesses.products.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete products",name:"deleteProducts",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.products.delete,"onUpdate:radio":a[9]||(a[9]=s=>t.state.department.accesses.products.delete=!t.state.department.accesses.products.delete)},null,8,["radio"]),W,e.createVNode(r.default,{label:"Read orders",name:"readOrders",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.orders.read,"onUpdate:radio":a[10]||(a[10]=s=>t.state.department.accesses.orders.read=!t.state.department.accesses.orders.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Confirm orders",name:"confirmOrders",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.orders.confirm,"onUpdate:radio":a[11]||(a[11]=s=>t.state.department.accesses.orders.confirm=!t.state.department.accesses.orders.confirm)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete orders",name:"deleteOrders",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.orders.delete,"onUpdate:radio":a[12]||(a[12]=s=>t.state.department.accesses.orders.delete=!t.state.department.accesses.orders.delete)},null,8,["radio"]),X,e.createVNode(r.default,{label:"Read departments",name:"readDepartments",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.departments.read,"onUpdate:radio":a[13]||(a[13]=s=>t.state.department.accesses.departments.read=!t.state.department.accesses.departments.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit departments",name:"editDepartments",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.departments.edit,"onUpdate:radio":a[14]||(a[14]=s=>t.state.department.accesses.departments.edit=!t.state.department.accesses.departments.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete departments",name:"deleteDepartments",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.departments.delete,"onUpdate:radio":a[15]||(a[15]=s=>t.state.department.accesses.departments.delete=!t.state.department.accesses.departments.delete)},null,8,["radio"])])])])]))}};exports.default=Y;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),c=require("vue-router");require("../../../../../../node_modules/js-cookie/dist/js.cookie.cjs");require("vue-i18n");;/* empty css */const P=require("../../../../components/UploadImage/UploadImage.vue.cjs");;/* empty css */const u=require("../../../../components/Field/Field.vue2.cjs");;/* empty css */const r=require("../../../../components/Checkbox/Checkbox.vue.cjs");require("../../../../../../node_modules/@googlemaps/js-api-loader/dist/index.cjs");;/* empty css */;/* empty css */;/* empty css */const f=require("../../../../components/Button/Button.vue2.cjs"),x=require("../../../../components/Popup/Popup.vue.cjs"),h=require("../../../../components/Block/Block.vue.cjs"),B=require("../../../../components/Feed/Feed.vue.cjs"),D=require("../../../icons/navigation/IconDelete.vue.cjs");;/* empty css */;/* empty css */const b=require("../../../users/components/blocks/CardUser.vue.cjs"),g=require("../../../globals/views/store/globals.cjs"),t=require("../../store/departments.cjs"),w=require("../../store/memberships.cjs"),U={class:"for-transition pd-thin w-100"},C={class:"mn-b-thin flex-nowrap flex bg-light pd-medium radius-big"},O={key:0,class:"mn-r-auto"},M={key:1,class:"mn-r-auto"},R={class:"flex-nowrap flex gap-thin pd-thin"},S={class:"cols-2-fit-content"},T={class:"w-100 flex-child-grow-1 flex-child"},z={class:"cols-2 gap-thin"},A={class:"bg-light pd-medium o-hidden radius-big"},F=e.createElementVNode("h3",{class:"mn-b-semi"},"Department Settings",-1),I=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please settings for your department:",-1),L={class:"cols-1 gap-thin"},j={class:"bg-light pd-medium o-hidden radius-big"},G=e.createElementVNode("h3",{class:"mn-b-semi"},"Acessess",-1),H=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please select organization accesses for user in department:",-1),J={class:"cols-1 gap-thin"},K=e.createElementVNode("h4",null,"Gallery",-1),Q=e.createElementVNode("h4",null,"Products",-1),W=e.createElementVNode("h4",null,"Orders",-1),X=e.createElementVNode("h4",null,"Departments",-1),Y={__name:"DepartmentEdit",setup(Z){const N=c.useRouter(),d=c.useRoute();async function V(){e.ref(w.state.memberships),d.params.department&&await t.actions.readOne(d.params.department)}V();const n=e.ref(!1),_=e.ref(null);function y(o){n.value=!0}function i(){n.value=!1,_.value=null}e.ref(!1),e.ref(null);async function k(){d.params.department&&await t.actions.update(d.params._id,t.state.department),d.params.department||await t.actions.create(d.params._id,t.state.department)}function E(){N.push({name:"Organization Members",params:{_id:d.params._id}})}async function v(){confirm("Are you sure you want to delete this department?")&&await t.actions.delete(d.params._id,t.state.department)}function q(o){confirm("Are you sure you want to remove this member?")&&g.actions.delete(t.state.department.members,{_id:o.user._id})}return(o,a)=>(e.openBlock(),e.createElementBlock("div",U,[e.createElementVNode("header",C,[e.unref(d).params.department?(e.openBlock(),e.createElementBlock("h1",O,"Edit Department")):(e.openBlock(),e.createElementBlock("h1",M,"Create Department")),e.createElementVNode("section",R,[e.unref(d).params.department?(e.openBlock(),e.createBlock(f.default,{key:0,submit:v,callback:o.redirectToDash,class:"bg-red"},{default:e.withCtx(()=>[e.createTextVNode("Delete")]),_:1},8,["callback"])):e.createCommentVNode("",!0),e.createVNode(f.default,{submit:k,callback:E,class:"bg-main"},{default:e.withCtx(()=>[e.createTextVNode("Save")]),_:1})])]),t.state.department.profile?(e.openBlock(),e.createBlock(h.default,{key:0,title:"Profile",class:"mn-b-thin"},{default:e.withCtx(()=>[e.createElementVNode("div",S,[e.createVNode(P.default,{photo:t.state.department.profile.photo,"onUpdate:photo":a[0]||(a[0]=s=>t.state.department.profile.photo=s),uploadPath:"organizations/"+t.state.department.name+"/avatars",class:"w-8r aspect-1x1 o-hidden mn-r-small radius-extra"},null,8,["photo","uploadPath"]),e.createElementVNode("div",T,[e.createVNode(u.default,{field:t.state.department.profile.name,"onUpdate:field":a[1]||(a[1]=s=>t.state.department.profile.name=s),label:"Name",placeholder:"Department Name",class:"mn-b-small bg-white radius-small pd-medium",validation:o.organizationName},null,8,["field","validation"]),e.createVNode(u.default,{field:t.state.department.profile.description,"onUpdate:field":a[2]||(a[2]=s=>t.state.department.profile.description=s),label:"Description",placeholder:"Department description (max 120 symbols)",class:"bg-white radius-small pd-medium",validation:o.organizationName},null,8,["field","validation"])])])]),_:1})):e.createCommentVNode("",!0),e.createVNode(h.default,{title:"Team",placeholder:"No members added yet",actions:[{label:"+",function:()=>y()}],class:"cols-1 gap-thin mn-b-thin"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.state.department.members,(s,l)=>(e.openBlock(),e.createBlock(b.default,{class:"h-4r bg-white pd-thin radius-medium w-100",key:l,user:s.user,photo:s.user.profile.photo,name:s.user.profile.name||s.user.phone||s.user.email||s.user._id,position:s.position,action:{label:{is:D.default,props:{class:"i-medium",fill:"rgb(var(--white)"}},method:()=>q(s)}},null,8,["user","photo","name","position","action"]))),128))]),_:1},8,["actions"]),e.createVNode(x.default,{title:"Add member",onClosePopup:i,isPopupOpen:n.value,class:"bg-white w-max-30r radius-big pd-big"},{default:e.withCtx(()=>[e.createVNode(B.default,{search:{placeholder:"Search customer...",class:"bg-light mn-b-thin"},states:{empty:{title:"No Products Found",description:"Currently, there are no such products available."}},store:{read:s=>w.actions.read(s),state:null},options:{target:e.unref(d).params._id},class:"bg-light pd-medium w-min-20r w-max-40r radius-big h-max-20r o-scroll"},{default:e.withCtx(({items:s})=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s,(l,$)=>{var m,p;return e.openBlock(),e.createBlock(b.default,{key:l._id,user:l.user,photo:(m=l.user.profile)==null?void 0:m.photo,name:((p=l.user.profile)==null?void 0:p.name)||l.user.phone||l.user.email,onClick:()=>{g.actions.add(t.state.department.members,{_id:l.user._id,user:l.user,position:"Member"}),i()},class:"h-4r bg-white pd-thin radius-medium w-100 mn-b-thin"},null,8,["user","photo","name","onClick"])}),128))]),_:1},8,["store","options"])]),_:1},8,["isPopupOpen"]),e.createElementVNode("div",z,[e.createElementVNode("div",A,[F,I,e.createElementVNode("div",L,[e.createVNode(r.default,{label:"Hidden department",name:"hidden",class:"w-100 mn-r-small bg-white radius-small pd-small","onUpdate:radio":a[3]||(a[3]=s=>t.state.department.hidden=!t.state.department.hidden),radio:t.state.department.hidden},null,8,["radio"])])]),e.createElementVNode("div",j,[G,H,e.createElementVNode("div",J,[K,e.createVNode(r.default,{label:"Read gallery",name:"readProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.read,"onUpdate:radio":a[4]||(a[4]=s=>t.state.department.accesses.gallery.read=!t.state.department.accesses.gallery.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit gallery",name:"editProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.edit,"onUpdate:radio":a[5]||(a[5]=s=>t.state.department.accesses.gallery.edit=!t.state.department.accesses.gallery.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete gallery",name:"deleteProducts",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.gallery.delete,"onUpdate:radio":a[6]||(a[6]=s=>t.state.department.accesses.gallery.delete=!t.state.department.accesses.gallery.delete)},null,8,["radio"]),Q,e.createVNode(r.default,{label:"Read products",name:"readProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.products.read,"onUpdate:radio":a[7]||(a[7]=s=>t.state.department.accesses.products.read=!t.state.department.accesses.products.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit products",name:"editProducts",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.products.edit,"onUpdate:radio":a[8]||(a[8]=s=>t.state.department.accesses.products.edit=!t.state.department.accesses.products.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete products",name:"deleteProducts",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.products.delete,"onUpdate:radio":a[9]||(a[9]=s=>t.state.department.accesses.products.delete=!t.state.department.accesses.products.delete)},null,8,["radio"]),W,e.createVNode(r.default,{label:"Read orders",name:"readOrders",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.orders.read,"onUpdate:radio":a[10]||(a[10]=s=>t.state.department.accesses.orders.read=!t.state.department.accesses.orders.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Confirm orders",name:"confirmOrders",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.orders.confirm,"onUpdate:radio":a[11]||(a[11]=s=>t.state.department.accesses.orders.confirm=!t.state.department.accesses.orders.confirm)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete orders",name:"deleteOrders",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.orders.delete,"onUpdate:radio":a[12]||(a[12]=s=>t.state.department.accesses.orders.delete=!t.state.department.accesses.orders.delete)},null,8,["radio"]),X,e.createVNode(r.default,{label:"Read departments",name:"readDepartments",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.departments.read,"onUpdate:radio":a[13]||(a[13]=s=>t.state.department.accesses.departments.read=!t.state.department.accesses.departments.read)},null,8,["radio"]),e.createVNode(r.default,{label:"Edit departments",name:"editDepartments",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:t.state.department.accesses.departments.edit,"onUpdate:radio":a[14]||(a[14]=s=>t.state.department.accesses.departments.edit=!t.state.department.accesses.departments.edit)},null,8,["radio"]),e.createVNode(r.default,{label:"Delete departments",name:"deleteDepartments",class:"w-100 bg-white radius-small pd-small",radio:t.state.department.accesses.departments.delete,"onUpdate:radio":a[15]||(a[15]=s=>t.state.department.accesses.departments.delete=!t.state.department.accesses.departments.delete)},null,8,["radio"])])])])]))}};exports.default=Y;
@@ -9,9 +9,9 @@ import U from "../../../../components/Field/Field.vue2.js";
9
9
  /* empty css */
10
10
  import d from "../../../../components/Checkbox/Checkbox.vue.js";
11
11
  import "../../../../../../node_modules/@googlemaps/js-api-loader/dist/index.js";
12
- /* empty css */
12
+ /* empty css */
13
13
  /* empty css */
14
- /* empty css */
14
+ /* empty css */
15
15
  import k from "../../../../components/Button/Button.vue2.js";
16
16
  import F from "../../../../components/Popup/Popup.vue.js";
17
17
  import x from "../../../../components/Block/Block.vue.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-router"),d=require("../../../../components/Dropdown/Dropdown.vue2.cjs"),m=require("../../../../components/Text/Text.vue.cjs"),g=require("../../../../components/Chips/Chips.vue2.cjs"),b=require("../../../icons/entities/IconFollowing.vue.cjs"),h=require("../../../icons/navigation/IconEdit.vue.cjs"),f=require("../../../icons/navigation/IconEllipsis.vue.cjs"),k=require("../../../icons/placeholders/PlaceholderOrganizationPic.vue.cjs"),c=require("../elements/ButtonToggleMembership.vue.cjs"),z=require("../blocks/Socials.vue.cjs"),w=require("../../../reports/components/sections/FormReport.vue.cjs"),x=require("../../store/organizations.cjs"),B=require("../../store/memberships.cjs"),V={class:"flex-center flex flex-column t-center pd-medium radius-big bg-light"},y={class:"bg-black pd-thin radius-small"},N=e.createElementVNode("button",{class:"w-100 bg-black br-solid br-1px br-white-transp-20 t-white button-small button"}," Report ",-1),E=["src"],q={class:"mn-b-thin"},p={class:"flex-center pd-r-thin pd-l-thin flex-nowrap flex mn-t-thin bg-white radius-extra w-max"},C={class:"mn-t-thin p-medium t-medium uppercase mn-b-thin"},S={class:"w-max-50r mn-t-regular mn-b-medium p-big"},v={key:5,class:"mn-t-small mn-b-thin"},O={__name:"DetailsTab",props:{organization:Object,user:Object},setup(t){const s=u.useRoute(),l=({membership:o,status:i,target:r},n,a)=>{B.mutations.handleMembershipUpdate(x.state.current,o,i,r,n,a)};return(o,i)=>(e.openBlock(),e.createBlock(e.Transition,{name:"slide-fade"},{default:e.withCtx(()=>{var r,n;return[e.createElementVNode("section",V,[t.user._id!==t.organization.owner?(e.openBlock(),e.createBlock(d.default,{key:0,label:{component:f.default,class:"i-regular t-transp"},align:"right",class:"cursor-pointer pos-absolute pos-r-regular pos-t-regular pd-thin radius-extra"},{default:e.withCtx(()=>[e.createElementVNode("section",y,[e.createVNode(w.default,{user:t.user._id,type:"organization",target:t.organization._id,text:"Report",class:"w-100"},{default:e.withCtx(()=>[N]),_:1},8,["user","target"]),t.user._id&&t.user._id!==t.organization.owner?(e.openBlock(),e.createBlock(c.default,{key:0,user:t.user._id,type:"organization",role:"blocked",target:t.organization._id,status:t.organization.isBlocked,text:{create:"Block",remove:"Unblock"},onUpdateMembership:i[0]||(i[0]=a=>l(a,"isBlocked")),class:"t-white w-100 mn-t-thin bg-red"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])]),_:1},8,["label"])):e.createCommentVNode("",!0),t.user._id===t.organization.owner?(e.openBlock(),e.createBlock(h.default,{key:1,onClick:i[1]||(i[1]=a=>o.$router.push({name:"Organization Edit",params:{_id:t.organization._id}})),class:"pos-absolute cursor-pointer pos-t-big pos-r-big i-regular t-transp"})):e.createCommentVNode("",!0),t.organization.profile.photo?(e.openBlock(),e.createElementBlock("img",{key:2,src:(o.FILE_SERVER_URL||"")+t.organization.profile.photo,class:"radius-big bg-light flex-center flex mn-b-small w-8r"},null,8,E)):(e.openBlock(),e.createBlock(k.default,{key:3,class:"radius-medium mn-b-small i-extra"})),e.createElementVNode("h1",q,e.toDisplayString(t.organization.profile.name),1),e.createElementVNode("div",p,[e.createVNode(b.default,{class:"i-medium mn-r-micro t-transp"}),e.createElementVNode("p",C,e.toDisplayString(t.organization.numberOfSubscribers)+" followers",1),t.user._id&&e.unref(s).params._id&&e.unref(s).params._id!==t.user._id&&t.organization.owner!==t.user._id?(e.openBlock(),e.createBlock(c.default,{key:0,user:t.user._id,type:"organization",role:"subscriber",target:t.organization._id,status:t.organization.isSubscriber,text:{create:"+",remove:"-"},onUpdateMembership:i[2]||(i[2]=a=>l(a,"isSubscriber","numberOfSubscribers")),class:"mn-l-thin p-medium t-medium radius-extra i-semi"},null,8,["user","target","status"])):e.createCommentVNode("",!0)]),e.createElementVNode("p",S,[e.createVNode(m.default,{text:t.organization.profile.description||"",showToggleText:!0,maxLen:320},null,8,["text"])]),((n=(r=t.organization.profile)==null?void 0:r.tags)==null?void 0:n.length)>0?(e.openBlock(),e.createBlock(g.default,{key:4,chips:t.organization.profile.tags,class:"p-medium"},null,8,["chips"])):e.createCommentVNode("",!0),Object.values(t.organization.socials).some(a=>a)?(e.openBlock(),e.createElementBlock("h4",v," Find us in socials ")):e.createCommentVNode("",!0),e.createVNode(z.default,{telegram:t.organization.socials.telegram,facebook:t.organization.socials.facebook,instagram:t.organization.socials.instagram,twitter:t.organization.socials.twitter,youtube:t.organization.socials.youtube},null,8,["telegram","facebook","instagram","twitter","youtube"])])]}),_:1}))}};exports.default=O;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-router"),d=require("../../../../components/Dropdown/Dropdown.vue.cjs"),m=require("../../../../components/Text/Text.vue.cjs"),g=require("../../../../components/Chips/Chips.vue.cjs"),b=require("../../../icons/entities/IconFollowing.vue.cjs"),h=require("../../../icons/navigation/IconEdit.vue.cjs"),f=require("../../../icons/navigation/IconEllipsis.vue.cjs"),k=require("../../../icons/placeholders/PlaceholderOrganizationPic.vue.cjs"),c=require("../elements/ButtonToggleMembership.vue.cjs"),z=require("../blocks/Socials.vue.cjs"),w=require("../../../reports/components/sections/FormReport.vue.cjs"),x=require("../../store/organizations.cjs"),B=require("../../store/memberships.cjs"),V={class:"flex-center flex flex-column t-center pd-medium radius-big bg-light"},y={class:"bg-black pd-thin radius-small"},N=e.createElementVNode("button",{class:"w-100 bg-black br-solid br-1px br-white-transp-20 t-white button-small button"}," Report ",-1),E=["src"],q={class:"mn-b-thin"},p={class:"flex-center pd-r-thin pd-l-thin flex-nowrap flex mn-t-thin bg-white radius-extra w-max"},C={class:"mn-t-thin p-medium t-medium uppercase mn-b-thin"},S={class:"w-max-50r mn-t-regular mn-b-medium p-big"},v={key:5,class:"mn-t-small mn-b-thin"},O={__name:"DetailsTab",props:{organization:Object,user:Object},setup(t){const s=u.useRoute(),l=({membership:o,status:i,target:r},n,a)=>{B.mutations.handleMembershipUpdate(x.state.current,o,i,r,n,a)};return(o,i)=>(e.openBlock(),e.createBlock(e.Transition,{name:"slide-fade"},{default:e.withCtx(()=>{var r,n;return[e.createElementVNode("section",V,[t.user._id!==t.organization.owner?(e.openBlock(),e.createBlock(d.default,{key:0,label:{component:f.default,class:"i-regular t-transp"},align:"right",class:"cursor-pointer pos-absolute pos-r-regular pos-t-regular pd-thin radius-extra"},{default:e.withCtx(()=>[e.createElementVNode("section",y,[e.createVNode(w.default,{user:t.user._id,type:"organization",target:t.organization._id,text:"Report",class:"w-100"},{default:e.withCtx(()=>[N]),_:1},8,["user","target"]),t.user._id&&t.user._id!==t.organization.owner?(e.openBlock(),e.createBlock(c.default,{key:0,user:t.user._id,type:"organization",role:"blocked",target:t.organization._id,status:t.organization.isBlocked,text:{create:"Block",remove:"Unblock"},onUpdateMembership:i[0]||(i[0]=a=>l(a,"isBlocked")),class:"t-white w-100 mn-t-thin bg-red"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])]),_:1},8,["label"])):e.createCommentVNode("",!0),t.user._id===t.organization.owner?(e.openBlock(),e.createBlock(h.default,{key:1,onClick:i[1]||(i[1]=a=>o.$router.push({name:"Organization Edit",params:{_id:t.organization._id}})),class:"pos-absolute cursor-pointer pos-t-big pos-r-big i-regular t-transp"})):e.createCommentVNode("",!0),t.organization.profile.photo?(e.openBlock(),e.createElementBlock("img",{key:2,src:(o.FILE_SERVER_URL||"")+t.organization.profile.photo,class:"radius-big bg-light flex-center flex mn-b-small w-8r"},null,8,E)):(e.openBlock(),e.createBlock(k.default,{key:3,class:"radius-medium mn-b-small i-extra"})),e.createElementVNode("h1",q,e.toDisplayString(t.organization.profile.name),1),e.createElementVNode("div",p,[e.createVNode(b.default,{class:"i-medium mn-r-micro t-transp"}),e.createElementVNode("p",C,e.toDisplayString(t.organization.numberOfSubscribers)+" followers",1),t.user._id&&e.unref(s).params._id&&e.unref(s).params._id!==t.user._id&&t.organization.owner!==t.user._id?(e.openBlock(),e.createBlock(c.default,{key:0,user:t.user._id,type:"organization",role:"subscriber",target:t.organization._id,status:t.organization.isSubscriber,text:{create:"+",remove:"-"},onUpdateMembership:i[2]||(i[2]=a=>l(a,"isSubscriber","numberOfSubscribers")),class:"mn-l-thin p-medium t-medium radius-extra i-semi"},null,8,["user","target","status"])):e.createCommentVNode("",!0)]),e.createElementVNode("p",S,[e.createVNode(m.default,{text:t.organization.profile.description||"",showToggleText:!0,maxLen:320},null,8,["text"])]),((n=(r=t.organization.profile)==null?void 0:r.tags)==null?void 0:n.length)>0?(e.openBlock(),e.createBlock(g.default,{key:4,chips:t.organization.profile.tags,class:"p-medium"},null,8,["chips"])):e.createCommentVNode("",!0),Object.values(t.organization.socials).some(a=>a)?(e.openBlock(),e.createElementBlock("h4",v," Find us in socials ")):e.createCommentVNode("",!0),e.createVNode(z.default,{telegram:t.organization.socials.telegram,facebook:t.organization.socials.facebook,instagram:t.organization.socials.instagram,twitter:t.organization.socials.twitter,youtube:t.organization.socials.youtube},null,8,["telegram","facebook","instagram","twitter","youtube"])])]}),_:1}))}};exports.default=O;
@@ -1,8 +1,8 @@
1
1
  import { openBlock as e, createBlock as r, Transition as x, withCtx as c, createElementVNode as n, createVNode as u, createCommentVNode as o, createElementBlock as b, toDisplayString as f, unref as h } from "vue";
2
2
  import { useRoute as k } from "vue-router";
3
- import w from "../../../../components/Dropdown/Dropdown.vue2.js";
3
+ import w from "../../../../components/Dropdown/Dropdown.vue.js";
4
4
  import y from "../../../../components/Text/Text.vue.js";
5
- import p from "../../../../components/Chips/Chips.vue2.js";
5
+ import p from "../../../../components/Chips/Chips.vue.js";
6
6
  import $ from "../../../icons/entities/IconFollowing.vue.js";
7
7
  import O from "../../../icons/navigation/IconEdit.vue.js";
8
8
  import B from "../../../icons/navigation/IconEllipsis.vue.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),s=require("vue-router");require("../../../../../../node_modules/js-cookie/dist/js.cookie.cjs");;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */const q=require("../../../auth/views/store/auth.cjs");require("../../store/memberships.cjs");require("vue-i18n");;/* empty css */require("../../../reports/store/reports.cjs");const y=require("../../store/organizations.cjs"),m=require("../blocks/CardOrganization.vue.cjs"),b=require("../blocks/EmptyState.vue.cjs");;/* empty css */;/* empty css */const g={class:"for-transition bg-white radius-big w-100"},k={class:""},_={key:1,class:"cols-1"},h={__name:"Organizations",props:{owner:{type:String,default:null},user:{type:[String,Number],default:null},onlyuser:{type:[String,Number],default:null}},async setup(c){let t,u;const o=c,a=e.ref(null);a.value=([t,u]=e.withAsyncContext(()=>y.actions.read({owner:o.owner,user:o.user,onlyuser:o.onlyuser})),t=await t,u(),t);const d=s.useRouter(),n=s.useRoute();let p=n.query.tab?n.query.tab:"details";const i=e.ref(p);return n.query.tab=i.value,e.watch(i,r=>{d.replace({query:{...n.query,tab:r}})}),(r,v)=>(e.openBlock(),e.createElementBlock("div",g,[e.createElementVNode("div",k,[a.value<1?(e.openBlock(),e.createBlock(b.default,{key:0,title:"You Haven't Joined Any Organization Yet",description:"Weeder is all about community. Join an organization or maybe you want to create your own?",action:"Create organization",callback:r.a=()=>r.$router.push("/app/organization/create/details")},null,8,["callback"])):(e.openBlock(),e.createElementBlock("div",_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value,l=>(e.openBlock(),e.createBlock(m.default,{key:l._id,organization:l,user:q.state.user,onUpdateMembership:r.handleMembershipUpdate,class:e.normalizeClass(["w-100",{"mn-r-small":r.index!==a.value.length-1}])},null,8,["organization","user","onUpdateMembership","class"]))),128))]))])]))}};exports.default=h;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),s=require("vue-router");require("../../../../../../node_modules/js-cookie/dist/js.cookie.cjs");;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */;/* empty css */const q=require("../../../auth/views/store/auth.cjs");require("../../store/memberships.cjs");require("vue-i18n");;/* empty css */require("../../../reports/store/reports.cjs");const y=require("../../store/organizations.cjs"),m=require("../blocks/CardOrganization.vue.cjs"),b=require("../blocks/EmptyState.vue.cjs");;/* empty css */;/* empty css */const g={class:"for-transition bg-white radius-big w-100"},k={class:""},_={key:1,class:"cols-1"},h={__name:"Organizations",props:{owner:{type:String,default:null},user:{type:[String,Number],default:null},onlyuser:{type:[String,Number],default:null}},async setup(c){let t,u;const o=c,a=e.ref(null);a.value=([t,u]=e.withAsyncContext(()=>y.actions.read({owner:o.owner,user:o.user,onlyuser:o.onlyuser})),t=await t,u(),t);const d=s.useRouter(),n=s.useRoute();let p=n.query.tab?n.query.tab:"details";const i=e.ref(p);return n.query.tab=i.value,e.watch(i,r=>{d.replace({query:{...n.query,tab:r}})}),(r,v)=>(e.openBlock(),e.createElementBlock("div",g,[e.createElementVNode("div",k,[a.value<1?(e.openBlock(),e.createBlock(b.default,{key:0,title:"You Haven't Joined Any Organization Yet",description:"Weeder is all about community. Join an organization or maybe you want to create your own?",action:"Create organization",callback:r.a=()=>r.$router.push("/app/organization/create/details")},null,8,["callback"])):(e.openBlock(),e.createElementBlock("div",_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value,l=>(e.openBlock(),e.createBlock(m.default,{key:l._id,organization:l,user:q.state.user,onUpdateMembership:r.handleMembershipUpdate,class:e.normalizeClass(["w-100",{"mn-r-small":r.index!==a.value.length-1}])},null,8,["organization","user","onUpdateMembership","class"]))),128))]))])]))}};exports.default=h;
@@ -6,8 +6,8 @@ import "../../../../../../node_modules/js-cookie/dist/js.cookie.js";
6
6
  /* empty css */
7
7
  /* empty css */
8
8
  /* empty css */
9
- /* empty css */
10
- /* empty css */
9
+ /* empty css */
10
+ /* empty css */
11
11
  import { state as k } from "../../../auth/views/store/auth.js";
12
12
  import "../../store/memberships.js";
13
13
  import "vue-i18n";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),r=require("../../../icons/navigation/IconEdit.vue.cjs"),a=require("../../../../components/Chips/Chips.vue2.cjs"),d=require("../../../../components/Map/Map.vue.cjs");;/* empty css */const c=require("../../../../../../_virtual/_plugin-vue_export-helper.cjs"),l=t=>(e.pushScopeId("data-v-bc545dfb"),t=t(),e.popScopeId(),t),p={class:"radius-big o-hidden pos-relative cols-2-1_3"},u={class:"pd-medium w-100"},m=["innerHTML"],h={class:"d-block p-big mn-b-semi"},g=l(()=>e.createElementVNode("h4",null,"Delivery:",-1)),b=l(()=>e.createElementVNode("h4",null,"Accepted Payment:",-1)),y={__name:"CardSpot",props:{spot:Object,organization:Object},setup(t){const i=t;return(o,n)=>(e.openBlock(),e.createElementBlock("div",p,[e.createVNode(d.default,{apiKey:o.GOOGLE_MAPS_API_KEY,location:{lat:t.spot.location.coordinates[1],lng:t.spot.location.coordinates[0]},locale:o.$i18n.locale,class:""},null,8,["apiKey","location","locale"]),e.createElementVNode("div",u,[e.createVNode(r.default,{onClick:n[0]||(n[0]=s=>o.$router.push({name:"Spot Edit",params:{_id:i.organization._id,spot:t.spot._id}})),class:"z-index-2 pos-absolute pos-t-regular pos-r-regular i-regular t-transp"}),e.createElementVNode("p",{onClick:n[1]||(n[1]=s=>o.$router.push(`/app/organization/${i.organization._id}/spots/${t.spot._id}`)),class:"pd-thin bg-white radius-small mn-b-thin p-small w-max"},e.toDisplayString(t.spot.address),1),e.createElementVNode("h3",{onClick:n[2]||(n[2]=s=>o.$router.push(`/app/organization/${i.organization._id}/spots/${t.spot._id}`)),class:"mn-b-thin w-100",innerHTML:t.spot.profile.name},null,8,m),e.createElementVNode("p",h,e.toDisplayString(t.spot.profile.description),1),g,o.type!=="short"&&t.spot.delivery.length>0?(e.openBlock(),e.createBlock(a.default,{key:0,chips:t.spot.delivery},null,8,["chips"])):e.createCommentVNode("",!0),b,o.type!=="short"&&t.spot.payment.length>0?(e.openBlock(),e.createBlock(a.default,{key:1,chips:t.spot.payment},null,8,["chips"])):e.createCommentVNode("",!0)])]))}},v=c.default(y,[["__scopeId","data-v-bc545dfb"]]);exports.default=v;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),r=require("../../../icons/navigation/IconEdit.vue.cjs"),a=require("../../../../components/Chips/Chips.vue.cjs"),d=require("../../../../components/Map/Map.vue.cjs");;/* empty css */const c=require("../../../../../../_virtual/_plugin-vue_export-helper.cjs"),l=t=>(e.pushScopeId("data-v-bc545dfb"),t=t(),e.popScopeId(),t),p={class:"radius-big o-hidden pos-relative cols-2-1_3"},u={class:"pd-medium w-100"},m=["innerHTML"],h={class:"d-block p-big mn-b-semi"},g=l(()=>e.createElementVNode("h4",null,"Delivery:",-1)),b=l(()=>e.createElementVNode("h4",null,"Accepted Payment:",-1)),y={__name:"CardSpot",props:{spot:Object,organization:Object},setup(t){const i=t;return(o,n)=>(e.openBlock(),e.createElementBlock("div",p,[e.createVNode(d.default,{apiKey:o.GOOGLE_MAPS_API_KEY,location:{lat:t.spot.location.coordinates[1],lng:t.spot.location.coordinates[0]},locale:o.$i18n.locale,class:""},null,8,["apiKey","location","locale"]),e.createElementVNode("div",u,[e.createVNode(r.default,{onClick:n[0]||(n[0]=s=>o.$router.push({name:"Spot Edit",params:{_id:i.organization._id,spot:t.spot._id}})),class:"z-index-2 pos-absolute pos-t-regular pos-r-regular i-regular t-transp"}),e.createElementVNode("p",{onClick:n[1]||(n[1]=s=>o.$router.push(`/app/organization/${i.organization._id}/spots/${t.spot._id}`)),class:"pd-thin bg-white radius-small mn-b-thin p-small w-max"},e.toDisplayString(t.spot.address),1),e.createElementVNode("h3",{onClick:n[2]||(n[2]=s=>o.$router.push(`/app/organization/${i.organization._id}/spots/${t.spot._id}`)),class:"mn-b-thin w-100",innerHTML:t.spot.profile.name},null,8,m),e.createElementVNode("p",h,e.toDisplayString(t.spot.profile.description),1),g,o.type!=="short"&&t.spot.delivery.length>0?(e.openBlock(),e.createBlock(a.default,{key:0,chips:t.spot.delivery},null,8,["chips"])):e.createCommentVNode("",!0),b,o.type!=="short"&&t.spot.payment.length>0?(e.openBlock(),e.createBlock(a.default,{key:1,chips:t.spot.payment},null,8,["chips"])):e.createCommentVNode("",!0)])]))}},v=c.default(y,[["__scopeId","data-v-bc545dfb"]]);exports.default=v;
@@ -1,6 +1,6 @@
1
1
  import { openBlock as n, createElementBlock as u, createVNode as l, createElementVNode as i, toDisplayString as r, createBlock as p, createCommentVNode as d, pushScopeId as h, popScopeId as g } from "vue";
2
2
  import b from "../../../icons/navigation/IconEdit.vue.js";
3
- import c from "../../../../components/Chips/Chips.vue2.js";
3
+ import c from "../../../../components/Chips/Chips.vue.js";
4
4
  import f from "../../../../components/Map/Map.vue.js";
5
5
  /* empty css */
6
6
  import y from "../../../../../../_virtual/_plugin-vue_export-helper.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),y=require("vue-router"),v=require("vue-i18n");;/* empty css */;/* empty css */;/* empty css */;/* empty css */const m=require("../../../globals/views/store/globals.cjs"),f=require("../../../products/store/categories.cjs"),g=require("../../../marketplace/store/marketplace.cjs"),h={class:"w-100 h-100"},k={class:"h-100 w-100 flex-nowrap flex-column flex gap-thin"},_={class:"pos-absolute z-index-2 w-100"},w={class:"bg-black-transp-25 t-white pd-small w-100 bg-blur-big mn-l-auto mn-r-auto t-center"},b=e.createElementVNode("span",{class:""},"Weed in ",-1),B={key:0},E={key:1},q={key:2},C={__name:"Spots",setup(O){const s=y.useRoute(),n=y.useRouter(),o=e.ref({city:null,state:null,country:null});function u(t){return t.replace(/-/g," ").replace(/\b\w/g,r=>r.toUpperCase())}e.onMounted(async()=>{if(s.params){let t={country:u(s.params.country),state:u(s.params.state),city:u(s.params.city)};o.value=t}if(s.query){const t=s.query,r={categories:t.categories?t.categories.split(","):[],prices:t.prices?t.prices.split(","):[],delivery:t.delivery?t.delivery.split(","):[]};g.state.filter.selected=r}await f.actions.fetchCategories()}),e.watch(()=>g.state.filter.selected,(t,r)=>{const a={...s.query};Object.keys(r).forEach(l=>{a[l]&&delete a[l]});const i=Object.fromEntries(Object.entries(t).filter(([l,c])=>Array.isArray(c)&&c.length>0).map(([l,c])=>[l,c.join(",")]));Object.assign(a,i),n.push({query:a})},{deep:!0});function p(t){return t.toLowerCase().replace(/ /g,"-").replace(/[^a-z0-9-]/g,"")}e.watch(()=>m.state.position,t=>{const r={...n.currentRoute.value};let a={country:p(t.country),state:p(t.state),city:p(t.city)};r.params=a,n.replace(r)},{deep:!0});const d={locale:"en",messages:{en:{meta:{title:"Marketplace โ€“ Shop Our Wide Selection of Quality Weed for Delivery",description:"Browse our marketplace of top-grade weed strains and choose from a variety of delivery options. Order now and have your favorite strains delivered straight to your door. Safe, fast, and reliable."},breadcrumbs:{home:"Home",store:"Marketplace"},categoriesTitle:"Category",categories:[],sort:{price:"By price",newest:"By newest",popularity:"By popularity"},filters:{title:"Filters",price:{title:"Price",from:"From",to:"To"},filters:[],reset:"Reset Filters"}},ru:{meta:{title:"ะœะฐั€ะบะตั‚ะฟะปะตะนั โ€“ ะ’ั‹ะฑะธั€ะฐะนั‚ะต ะธะท ะฝะฐัˆะตะณะพ ะฐััะพั€ั‚ะธะผะตะฝั‚ะฐ ะบะฐั‡ะตัั‚ะฒะตะฝะฝะพะน ั‚ั€ะฐะฒะบะธ ะดะปั ะดะพัั‚ะฐะฒะบะธ",description:"ะœะฐั€ะบะตั‚ะฟะปะตะนั โ€“ ะ˜ะทัƒั‡ะธั‚ะต ะฝะฐัˆะธ ะฟั€ะพะดัƒะบั‚ั‹ ะฒั‹ัะพะบะพะณะพ ะบะฐั‡ะตัั‚ะฒะฐ ะธ ะฒั‹ะฑะธั€ะฐะนั‚ะต ะธะท ั€ะฐะทะปะธั‡ะฝั‹ั… ะฒะฐั€ะธะฐะฝั‚ะพะฒ ะดะพัั‚ะฐะฒะบะธ. ะ—ะฐะบะฐะถะธั‚ะต ัะตะนั‡ะฐั ะธ ะฟะพะปัƒั‡ะธั‚ะต ัะฒะพะธ ะปัŽะฑะธะผั‹ะต ัะพั€ั‚ะฐ ะฝะฐ ะดะพะผ. ะ‘ะตะทะพะฟะฐัะฝะพ, ะฑั‹ัั‚ั€ะพ ะธ ะฝะฐะดะตะถะฝะพ."},breadcrumbs:{home:"ะ“ะปะฐะฒะฝะฐั",store:"ะœะฐั€ะบะตั‚ะฟะปะตะนั"},categoriesTitle:"ะšะฐั‚ะตะณะพั€ะธั",categories:[],sort:{price:"ะŸะพ ั†ะตะฝะต",newest:"ะŸะพ ะฝะพะฒะธะทะฝะต",popularity:"ะŸะพ ะฟะพะฟัƒะปัั€ะฝะพัั‚ะธ"},filters:{title:"ะคะธะปัŒั‚ั€ั‹",price:{title:"ะฆะตะฝะฐ",from:"ะžั‚",to:"ะ”ะพ"},filters:[],reset:"ะกะฑั€ะพัะธั‚ัŒ ั„ะธะปัŒั‚ั€ั‹"}}}};return f.state.all.forEach(t=>{t.localization.forEach(r=>{d.messages[r.locale].categories.push(r.text)})}),v.useI18n(d),(t,r)=>{const a=e.resolveComponent("router-view");return e.openBlock(),e.createElementBlock("div",h,[e.createElementVNode("div",k,[e.createElementVNode("div",_,[e.createElementVNode("h2",w,[b,o.value.city||o.value.state||o.value.country?(e.openBlock(),e.createElementBlock("span",{key:0,onClick:r[0]||(r[0]=i=>{m.state.isOpenLocationPopup=!0}),class:"t-semi t-main"},[o.value.city?(e.openBlock(),e.createElementBlock("span",B,e.toDisplayString(o.value.city)+", ",1)):e.createCommentVNode("",!0),o.value.state?(e.openBlock(),e.createElementBlock("span",E,e.toDisplayString(o.value.state)+", ",1)):e.createCommentVNode("",!0),o.value.country?(e.openBlock(),e.createElementBlock("span",q,e.toDisplayString(o.value.country),1)):e.createCommentVNode("",!0)])):(e.openBlock(),e.createElementBlock("span",{key:1,onClick:r[1]||(r[1]=i=>{m.state.isOpenLocationPopup=!0}),class:"t-semi t-main"}," The World "))])]),e.createVNode(a,null,{default:e.withCtx(({Component:i,route:l})=>[e.createVNode(e.Transition,{name:"scaleIn",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i),{ref:"page",key:l.path,localPosition:o.value,apiKey:t.GOOGLE_MAPS_API_KEY,locale:t.$i18n.locale,class:""},null,8,["localPosition","apiKey","locale"]))]),_:2},1024)]),_:1})])])}}};exports.default=C;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),y=require("vue-router"),v=require("vue-i18n");;/* empty css */;/* empty css */;/* empty css */;/* empty css */const m=require("../../../globals/views/store/globals.cjs"),f=require("../../../products/store/categories.cjs"),g=require("../../../marketplace/store/marketplace.cjs"),h={class:"w-100 h-100"},k={class:"h-100 w-100 flex-nowrap flex-column flex gap-thin"},_={class:"pos-absolute z-index-2 w-100"},w={class:"bg-black-transp-25 t-white pd-small w-100 bg-blur-big mn-l-auto mn-r-auto t-center"},b=e.createElementVNode("span",{class:""},"Weed in ",-1),B={key:0},E={key:1},q={key:2},C={__name:"Spots",setup(O){const s=y.useRoute(),n=y.useRouter(),o=e.ref({city:null,state:null,country:null});function u(t){return t.replace(/-/g," ").replace(/\b\w/g,r=>r.toUpperCase())}e.onMounted(async()=>{if(s.params){let t={country:u(s.params.country),state:u(s.params.state),city:u(s.params.city)};o.value=t}if(s.query){const t=s.query,r={categories:t.categories?t.categories.split(","):[],prices:t.prices?t.prices.split(","):[],delivery:t.delivery?t.delivery.split(","):[]};g.state.filter.selected=r}await f.actions.fetchCategories()}),e.watch(()=>g.state.filter.selected,(t,r)=>{const a={...s.query};Object.keys(r).forEach(l=>{a[l]&&delete a[l]});const i=Object.fromEntries(Object.entries(t).filter(([l,c])=>Array.isArray(c)&&c.length>0).map(([l,c])=>[l,c.join(",")]));Object.assign(a,i),n.push({query:a})},{deep:!0});function p(t){return t.toLowerCase().replace(/ /g,"-").replace(/[^a-z0-9-]/g,"")}e.watch(()=>m.state.position,t=>{const r={...n.currentRoute.value};let a={country:p(t.country),state:p(t.state),city:p(t.city)};r.params=a,n.replace(r)},{deep:!0});const d={locale:"en",messages:{en:{meta:{title:"Marketplace โ€“ Shop Our Wide Selection of Quality Weed for Delivery",description:"Browse our marketplace of top-grade weed strains and choose from a variety of delivery options. Order now and have your favorite strains delivered straight to your door. Safe, fast, and reliable."},breadcrumbs:{home:"Home",store:"Marketplace"},categoriesTitle:"Category",categories:[],sort:{price:"By price",newest:"By newest",popularity:"By popularity"},filters:{title:"Filters",price:{title:"Price",from:"From",to:"To"},filters:[],reset:"Reset Filters"}},ru:{meta:{title:"ะœะฐั€ะบะตั‚ะฟะปะตะนั โ€“ ะ’ั‹ะฑะธั€ะฐะนั‚ะต ะธะท ะฝะฐัˆะตะณะพ ะฐััะพั€ั‚ะธะผะตะฝั‚ะฐ ะบะฐั‡ะตัั‚ะฒะตะฝะฝะพะน ั‚ั€ะฐะฒะบะธ ะดะปั ะดะพัั‚ะฐะฒะบะธ",description:"ะœะฐั€ะบะตั‚ะฟะปะตะนั โ€“ ะ˜ะทัƒั‡ะธั‚ะต ะฝะฐัˆะธ ะฟั€ะพะดัƒะบั‚ั‹ ะฒั‹ัะพะบะพะณะพ ะบะฐั‡ะตัั‚ะฒะฐ ะธ ะฒั‹ะฑะธั€ะฐะนั‚ะต ะธะท ั€ะฐะทะปะธั‡ะฝั‹ั… ะฒะฐั€ะธะฐะฝั‚ะพะฒ ะดะพัั‚ะฐะฒะบะธ. ะ—ะฐะบะฐะถะธั‚ะต ัะตะนั‡ะฐั ะธ ะฟะพะปัƒั‡ะธั‚ะต ัะฒะพะธ ะปัŽะฑะธะผั‹ะต ัะพั€ั‚ะฐ ะฝะฐ ะดะพะผ. ะ‘ะตะทะพะฟะฐัะฝะพ, ะฑั‹ัั‚ั€ะพ ะธ ะฝะฐะดะตะถะฝะพ."},breadcrumbs:{home:"ะ“ะปะฐะฒะฝะฐั",store:"ะœะฐั€ะบะตั‚ะฟะปะตะนั"},categoriesTitle:"ะšะฐั‚ะตะณะพั€ะธั",categories:[],sort:{price:"ะŸะพ ั†ะตะฝะต",newest:"ะŸะพ ะฝะพะฒะธะทะฝะต",popularity:"ะŸะพ ะฟะพะฟัƒะปัั€ะฝะพัั‚ะธ"},filters:{title:"ะคะธะปัŒั‚ั€ั‹",price:{title:"ะฆะตะฝะฐ",from:"ะžั‚",to:"ะ”ะพ"},filters:[],reset:"ะกะฑั€ะพัะธั‚ัŒ ั„ะธะปัŒั‚ั€ั‹"}}}};return f.state.all.forEach(t=>{t.localization.forEach(r=>{d.messages[r.locale].categories.push(r.text)})}),v.useI18n(d),(t,r)=>{const a=e.resolveComponent("router-view");return e.openBlock(),e.createElementBlock("div",h,[e.createElementVNode("div",k,[e.createElementVNode("div",_,[e.createElementVNode("h2",w,[b,o.value.city||o.value.state||o.value.country?(e.openBlock(),e.createElementBlock("span",{key:0,onClick:r[0]||(r[0]=i=>{m.state.isOpenLocationPopup=!0}),class:"t-semi t-main"},[o.value.city?(e.openBlock(),e.createElementBlock("span",B,e.toDisplayString(o.value.city)+", ",1)):e.createCommentVNode("",!0),o.value.state?(e.openBlock(),e.createElementBlock("span",E,e.toDisplayString(o.value.state)+", ",1)):e.createCommentVNode("",!0),o.value.country?(e.openBlock(),e.createElementBlock("span",q,e.toDisplayString(o.value.country),1)):e.createCommentVNode("",!0)])):(e.openBlock(),e.createElementBlock("span",{key:1,onClick:r[1]||(r[1]=i=>{m.state.isOpenLocationPopup=!0}),class:"t-semi t-main"}," The World "))])]),e.createVNode(a,null,{default:e.withCtx(({Component:i,route:l})=>[e.createVNode(e.Transition,{name:"scaleIn",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i),{ref:"page",key:l.path,localPosition:o.value,apiKey:t.GOOGLE_MAPS_API_KEY,locale:t.$i18n.locale,class:""},null,8,["localPosition","apiKey","locale"]))]),_:2},1024)]),_:1})])])}}};exports.default=C;
@@ -4,7 +4,7 @@ import { useI18n as j } from "vue-i18n";
4
4
  /* empty css */
5
5
  /* empty css */
6
6
  /* empty css */
7
- /* empty css */
7
+ /* empty css */
8
8
  import { state as h } from "../../../globals/views/store/globals.js";
9
9
  import { actions as q, state as R } from "../../../products/store/categories.js";
10
10
  import { state as b } from "../../../marketplace/store/marketplace.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-router"),d=require("../../../../components/Block/Block.vue.cjs"),g=require("../../../../components/UploadImage/UploadImage.vue.cjs");;/* empty css */const r=require("../../../../components/Field/Field.vue2.cjs"),N=require("../../../../components/Select/Select.vue.cjs"),n=require("../../../../components/Checkbox/Checkbox.vue.cjs"),w=require("../../../../components/Address/Address.vue.cjs"),V=require("../../../../components/LocationMarker/LocationMarker.vue.cjs"),m=require("../../../../components/Button/Button.vue2.cjs");require("vue-i18n");;/* empty css */const t=require("../../store/spots.cjs"),y={class:"for-transition w-100 cols-1 pd-thin gap-thin"},E={class:"mn-r-auto"},S={class:"cols-2 gap-thin"},q={class:"gap-small mn-b-small cols-2-fit-content"},k={class:"w-100"},U=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please the available delivery options:",-1),_=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please select the available payment methods:",-1),P=e.createElementVNode("p",{class:"mn-b-small p-medium"},"Options:",-1),O={__name:"SpotEdit",setup(x){const p=u.useRouter(),l=u.useRoute();e.ref("details"),e.ref(!1),e.onMounted(async()=>{await c()});async function c(){var s,o;l.params.spot&&await t.actions.readOne(l.params.spot);const i=(s=t.state.spot.location)==null?void 0:s.coordinates[0],a=(o=t.state.spot.location)==null?void 0:o.coordinates[1];t.state.spot.location={lat:a||1,lng:i||1}}async function f(){t.state.spot.location={type:"Point",coordinates:[t.state.spot.location.lng,t.state.spot.location.lat]},l.params.spot&&await t.actions.update(l.params._id,t.state.spot),l.params.spot||await t.actions.create(l.params._id,t.state.spot)}function b(){p.push({name:"Organization",params:{_id:l.params._id}})}async function h(){await t.actions.delete(l.params._id,t.state.spot)}function v(){p.push({name:"Organization",params:{_id:l.params._id}})}return(i,a)=>(e.openBlock(),e.createElementBlock("div",y,[e.createVNode(d.default,{class:"flex-nowrap flex-v-center flex"},{default:e.withCtx(()=>[e.createElementVNode("h1",E,e.toDisplayString(e.unref(l).params.spot?t.state.spot.profile.name:"Create Spot"),1),e.createVNode(m.default,{submit:f,callback:b,class:"bg-main"},{default:e.withCtx(()=>[e.createTextVNode(" Save Spot ")]),_:1})]),_:1}),e.createElementVNode("div",S,[e.createVNode(d.default,{title:"Profile",class:"mn-b-semi"},{default:e.withCtx(()=>[e.createElementVNode("div",q,[e.createVNode(g.default,{photo:t.state.spot.profile.photo,"onUpdate:photo":a[0]||(a[0]=s=>t.state.spot.profile.photo=s),uploadPath:"organizations/"+t.state.spot.name+"/avatars",class:"aspect-1x1 w-8r o-hidden radius-extra"},null,8,["photo","uploadPath"]),e.createElementVNode("div",k,[e.createVNode(r.default,{field:t.state.spot.profile.name,"onUpdate:field":a[1]||(a[1]=s=>t.state.spot.profile.name=s),label:"Name",placeholder:"Spot Name",class:"mn-b-small bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"]),e.createVNode(r.default,{field:t.state.spot.profile.description,"onUpdate:field":a[2]||(a[2]=s=>t.state.spot.profile.description=s),label:"Description",placeholder:"Spot description (max 120 symbols)",class:"bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"])])]),e.createVNode(N.default,{select:t.state.spot.status,"onUpdate:select":a[3]||(a[3]=s=>t.state.spot.status=s),label:"Status",options:["unpublished","published","archivied"],placeholder:"Display product",class:"pos-relative w-100 mn-b-small bg-white radius-small pd-medium"},null,8,["select"]),U,(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(["pickup","courier","post"],s=>e.createVNode(n.default,{label:s,name:"Delivery",value:s,class:"w-100 mn-b-small bg-white radius-small pd-small",radio:t.state.spot.delivery,"onUpdate:radio":a[4]||(a[4]=o=>t.state.spot.delivery=o)},null,8,["label","value","radio"])),64)),_,(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(["cash","bank transfer","crypto"],s=>e.createVNode(n.default,{label:s,name:"Payment",value:s,class:"w-100 mn-b-small bg-white radius-small pd-small",radio:t.state.spot.payment,"onUpdate:radio":a[5]||(a[5]=o=>t.state.spot.payment=o)},null,8,["label","value","radio"])),64))]),_:1}),e.createVNode(d.default,{title:"Location",class:"pos-relative"},{default:e.withCtx(()=>{var s;return[e.createVNode(w.default,{apiKey:i.GOOGLE_MAPS_API_KEY,address:t.state.spot.address,location:t.state.spot.location,locale:i.$i18n.locale,label:"Address",placeholder:"Enter delivery address",class:"bg-white pd-small radius-tl-medium radius-tr-medium","onUpdate:location":a[6]||(a[6]=o=>{t.state.spot.location=o}),"onUpdate:address":a[7]||(a[7]=o=>{t.state.spot.address=o})},null,8,["apiKey","address","location","locale"]),e.createVNode(V.default,{apiKey:i.GOOGLE_MAPS_API_KEY,address:t.state.spot.address,location:t.state.spot.location,locale:i.$i18n.locale,class:"h-20r mn-b-small radius-bl-medium radius-br-medium o-hidden","onUpdate:location":a[8]||(a[8]=o=>{t.state.spot.location=o}),"onUpdate:address":a[9]||(a[9]=o=>{t.state.spot.address=o})},null,8,["apiKey","address","location","locale"]),P,e.createVNode(n.default,{label:"Hide address",name:"address",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:(s=t.state.spot.position)==null?void 0:s.hide,"onUpdate:radio":a[10]||(a[10]=o=>t.state.spot.position.hide=o)},null,8,["radio"]),e.createVNode(r.default,{field:t.state.spot.minorder,"onUpdate:field":a[11]||(a[11]=o=>t.state.spot.minorder=o),label:"Min.order",placeholder:"Enter minimum order value",class:"bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"])]}),_:1})]),e.createVNode(m.default,{submit:h,callback:v,class:"w-100 bg-light"},{default:e.withCtx(()=>[e.createTextVNode("Delete Spot")]),_:1})]))}};exports.default=O;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-router"),d=require("../../../../components/Block/Block.vue.cjs"),g=require("../../../../components/UploadImage/UploadImage.vue.cjs");;/* empty css */const r=require("../../../../components/Field/Field.vue2.cjs"),N=require("../../../../components/Select/Select.vue.cjs"),n=require("../../../../components/Checkbox/Checkbox.vue.cjs"),w=require("../../../../components/Address/Address.vue2.cjs"),V=require("../../../../components/LocationMarker/LocationMarker.vue2.cjs"),m=require("../../../../components/Button/Button.vue2.cjs");require("vue-i18n");;/* empty css */const t=require("../../store/spots.cjs"),y={class:"for-transition w-100 cols-1 pd-thin gap-thin"},E={class:"mn-r-auto"},S={class:"cols-2 gap-thin"},q={class:"gap-small mn-b-small cols-2-fit-content"},k={class:"w-100"},U=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please the available delivery options:",-1),_=e.createElementVNode("p",{class:"p-medium mn-b-small"},"Please select the available payment methods:",-1),P=e.createElementVNode("p",{class:"mn-b-small p-medium"},"Options:",-1),O={__name:"SpotEdit",setup(x){const p=u.useRouter(),l=u.useRoute();e.ref("details"),e.ref(!1),e.onMounted(async()=>{await c()});async function c(){var s,o;l.params.spot&&await t.actions.readOne(l.params.spot);const i=(s=t.state.spot.location)==null?void 0:s.coordinates[0],a=(o=t.state.spot.location)==null?void 0:o.coordinates[1];t.state.spot.location={lat:a||1,lng:i||1}}async function f(){t.state.spot.location={type:"Point",coordinates:[t.state.spot.location.lng,t.state.spot.location.lat]},l.params.spot&&await t.actions.update(l.params._id,t.state.spot),l.params.spot||await t.actions.create(l.params._id,t.state.spot)}function b(){p.push({name:"Organization",params:{_id:l.params._id}})}async function h(){await t.actions.delete(l.params._id,t.state.spot)}function v(){p.push({name:"Organization",params:{_id:l.params._id}})}return(i,a)=>(e.openBlock(),e.createElementBlock("div",y,[e.createVNode(d.default,{class:"flex-nowrap flex-v-center flex"},{default:e.withCtx(()=>[e.createElementVNode("h1",E,e.toDisplayString(e.unref(l).params.spot?t.state.spot.profile.name:"Create Spot"),1),e.createVNode(m.default,{submit:f,callback:b,class:"bg-main"},{default:e.withCtx(()=>[e.createTextVNode(" Save Spot ")]),_:1})]),_:1}),e.createElementVNode("div",S,[e.createVNode(d.default,{title:"Profile",class:"mn-b-semi"},{default:e.withCtx(()=>[e.createElementVNode("div",q,[e.createVNode(g.default,{photo:t.state.spot.profile.photo,"onUpdate:photo":a[0]||(a[0]=s=>t.state.spot.profile.photo=s),uploadPath:"organizations/"+t.state.spot.name+"/avatars",class:"aspect-1x1 w-8r o-hidden radius-extra"},null,8,["photo","uploadPath"]),e.createElementVNode("div",k,[e.createVNode(r.default,{field:t.state.spot.profile.name,"onUpdate:field":a[1]||(a[1]=s=>t.state.spot.profile.name=s),label:"Name",placeholder:"Spot Name",class:"mn-b-small bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"]),e.createVNode(r.default,{field:t.state.spot.profile.description,"onUpdate:field":a[2]||(a[2]=s=>t.state.spot.profile.description=s),label:"Description",placeholder:"Spot description (max 120 symbols)",class:"bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"])])]),e.createVNode(N.default,{select:t.state.spot.status,"onUpdate:select":a[3]||(a[3]=s=>t.state.spot.status=s),label:"Status",options:["unpublished","published","archivied"],placeholder:"Display product",class:"pos-relative w-100 mn-b-small bg-white radius-small pd-medium"},null,8,["select"]),U,(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(["pickup","courier","post"],s=>e.createVNode(n.default,{label:s,name:"Delivery",value:s,class:"w-100 mn-b-small bg-white radius-small pd-small",radio:t.state.spot.delivery,"onUpdate:radio":a[4]||(a[4]=o=>t.state.spot.delivery=o)},null,8,["label","value","radio"])),64)),_,(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(["cash","bank transfer","crypto"],s=>e.createVNode(n.default,{label:s,name:"Payment",value:s,class:"w-100 mn-b-small bg-white radius-small pd-small",radio:t.state.spot.payment,"onUpdate:radio":a[5]||(a[5]=o=>t.state.spot.payment=o)},null,8,["label","value","radio"])),64))]),_:1}),e.createVNode(d.default,{title:"Location",class:"pos-relative"},{default:e.withCtx(()=>{var s;return[e.createVNode(w.default,{apiKey:i.GOOGLE_MAPS_API_KEY,address:t.state.spot.address,location:t.state.spot.location,locale:i.$i18n.locale,label:"Address",placeholder:"Enter delivery address",class:"bg-white pd-small radius-tl-medium radius-tr-medium","onUpdate:location":a[6]||(a[6]=o=>{t.state.spot.location=o}),"onUpdate:address":a[7]||(a[7]=o=>{t.state.spot.address=o})},null,8,["apiKey","address","location","locale"]),e.createVNode(V.default,{apiKey:i.GOOGLE_MAPS_API_KEY,address:t.state.spot.address,location:t.state.spot.location,locale:i.$i18n.locale,class:"h-20r mn-b-small radius-bl-medium radius-br-medium o-hidden","onUpdate:location":a[8]||(a[8]=o=>{t.state.spot.location=o}),"onUpdate:address":a[9]||(a[9]=o=>{t.state.spot.address=o})},null,8,["apiKey","address","location","locale"]),P,e.createVNode(n.default,{label:"Hide address",name:"address",class:"w-100 mn-r-small bg-white radius-small pd-small",radio:(s=t.state.spot.position)==null?void 0:s.hide,"onUpdate:radio":a[10]||(a[10]=o=>t.state.spot.position.hide=o)},null,8,["radio"]),e.createVNode(r.default,{field:t.state.spot.minorder,"onUpdate:field":a[11]||(a[11]=o=>t.state.spot.minorder=o),label:"Min.order",placeholder:"Enter minimum order value",class:"bg-white radius-small pd-medium",validation:i.organizationName},null,8,["field","validation"])]}),_:1})]),e.createVNode(m.default,{submit:h,callback:v,class:"w-100 bg-light"},{default:e.withCtx(()=>[e.createTextVNode("Delete Spot")]),_:1})]))}};exports.default=O;
@@ -6,8 +6,8 @@ import z from "../../../../components/UploadImage/UploadImage.vue.js";
6
6
  import c from "../../../../components/Field/Field.vue2.js";
7
7
  import K from "../../../../components/Select/Select.vue.js";
8
8
  import f from "../../../../components/Checkbox/Checkbox.vue.js";
9
- import A from "../../../../components/Address/Address.vue.js";
10
- import G from "../../../../components/LocationMarker/LocationMarker.vue.js";
9
+ import A from "../../../../components/Address/Address.vue2.js";
10
+ import G from "../../../../components/LocationMarker/LocationMarker.vue2.js";
11
11
  import _ from "../../../../components/Button/Button.vue2.js";
12
12
  import "vue-i18n";
13
13
  /* empty css */
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");;/* empty css */;/* empty css */;/* empty css */const h=require("../../../../components/Dropdown/Dropdown.vue2.cjs"),g=require("../../../../components/Completion/Completion.vue.cjs"),d=require("../../../../components/Menu/Menu.vue.cjs"),l=require("../../../../components/Menu/MenuItem.vue.cjs"),p=require("../../../organizations/components/elements/ButtonToggleMembership.vue.cjs"),N=require("../../../reports/components/sections/FormReport.vue.cjs"),V=require("../../../organizations/components/blocks/Socials.vue.cjs"),B=require("../../../icons/entities/IconEvents.vue.cjs"),f=require("../../../icons/entities/IconGroups.vue.cjs"),w=require("../../../icons/entities/IconCommunity.vue.cjs"),C=require("../../../icons/navigation/IconEdit.vue.cjs"),E=require("../../../icons/placeholders/PlaceholderUserpic.vue.cjs"),_=require("vue-router"),o=require("../../../auth/views/store/auth.cjs"),t=require("../../store/users.cjs"),v=require("../../../organizations/store/memberships.cjs");require("./Profile.vue2.cjs");const x={key:0,class:"for-transition w-100"},y={key:0,class:"flex-center flex pd-medium radius-big bg-light uppercase t-semi w-100 h-100"},q={key:1,_id:"dash",class:"pd-b-extra pd-thin w-100"},S={class:"flex-center pos-relative flex flex-column t-center w-100 mn-b-semi radius-medium pd-medium bg-light"},U={class:"bg-black pd-thin radius-small"},M=e.createElementVNode("button",{class:"w-100 bg-black br-solid br-1px br-white-transp-20 t-white button-small button"}," Report ",-1),P=["src"],R={class:"mn-b-thin"},$={key:4,class:"mn-b-thin t-main t-semi"},D={class:"mn-b-small p-medium"},I={class:"mn-b-medium flex-center flex-nowrap flex"},F={class:"t-semi mn-b-small"},L={key:6,class:"mn-t-small mn-b-thin"},O=e.createElementVNode("span",null,"Events",-1),A=e.createElementVNode("span",null,"Groups",-1),j=e.createElementVNode("span",null,"Posts",-1),W=e.createElementVNode("span",null,"Wallet",-1),z=e.createElementVNode("span",null," Settings ",-1),G=e.createElementVNode("span",null," About ",-1),T=e.createElementVNode("span",{class:"t-red"}," Logout ",-1),H={__name:"Profile",setup(J){const a=_.useRoute(),n=_.useRouter(),u=e.ref(!1);e.onMounted(async()=>{await t.actions.read({_id:a.params._id,user:o.state.user._id}),u.value=!0});const m=({membership:i,status:r,target:s},c,k)=>{v.mutations.handleMembershipUpdate(t.state.current,i,r,s,c,k)};function b(){o.actions.logout(),n.push({name:"Sign In"})}return(i,r)=>u.value?(e.openBlock(),e.createElementBlock("div",x,[t.state.current.status==="removed"?(e.openBlock(),e.createElementBlock("div",y," Sorry, user has been removed. ")):(e.openBlock(),e.createElementBlock("div",q,[e.unref(a).params._id===o.state.user._id&&u.value?(e.openBlock(),e.createBlock(g.default,{key:0,user:o.state.user._id,target:t.state.current,cta:!0,text_cta:"Fill Profile",text:"Profile completed at",class:"mn-b-medium"},null,8,["user","target"])):e.createCommentVNode("",!0),e.createElementVNode("section",S,[e.unref(a).params._id&&e.unref(a).params._id!==o.state.user._id?(e.openBlock(),e.createBlock(h.default,{key:0,label:"...",align:"right",class:"cursor-pointer pos-absolute pos-r-0 pos-t-0 pd-thin radius-extra"},{default:e.withCtx(()=>[e.createElementVNode("section",U,[e.createVNode(N.default,{user:o.state.user._id,type:"user",target:t.state.current._id,text:"Report",class:"w-100"},{default:e.withCtx(()=>[M]),_:1},8,["user","target"]),o.state.user._id?(e.openBlock(),e.createBlock(p.default,{key:0,user:o.state.user._id,type:"user",role:"blocked",target:t.state.current._id,status:t.state.current.isBlocked,text:{create:"Block",remove:"Unblock"},onUpdateMembership:r[0]||(r[0]=s=>m(s,"isBlocked")),class:"t-white mn-t-thin bg-red"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])]),_:1})):e.createCommentVNode("",!0),e.unref(a).params._id===o.state.user._id?(e.openBlock(),e.createBlock(C.default,{key:1,onClick:r[1]||(r[1]=s=>i.$router.push({name:"User Edit Profile",params:{_id:o.state.user._id}})),class:"cursor-pointer pos-absolute pos-t-regular pos-r-regular i-regular t-transp"})):e.createCommentVNode("",!0),t.state.current.profile.photo&&t.state.current.profile.photo.length>0?(e.openBlock(),e.createElementBlock("img",{key:2,src:(i.FILE_SERVER_URL||"")+t.state.current.profile.photo,class:"radius-extra bg-white mn-b-small object-fit-cover i-extra"},null,8,P)):(e.openBlock(),e.createBlock(E.default,{key:3,class:"radius-medium mn-b-small i-extra"})),e.createElementVNode("h3",R,e.toDisplayString(t.state.current.profile.name?t.state.current.profile.name:"Anonymous"),1),t.state.current.username?(e.openBlock(),e.createElementBlock("p",$," @"+e.toDisplayString(t.state.current.username?t.state.current.username:"Not specified"),1)):e.createCommentVNode("",!0),e.createElementVNode("p",D,e.toDisplayString(t.state.current.profile.description?t.state.current.profile.description:"Bio not specified"),1),e.createElementVNode("div",I,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.state.current.roles,(s,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["pd-thin radius-small t-semi bg-white",{"mn-r-thin":c!==t.state.current.roles.length-1}])},e.toDisplayString(s.icon)+" "+e.toDisplayString(s.name),3))),256))]),e.createElementVNode("p",F," ๐Ÿ‘จโ€๐Ÿ‘จโ€๐Ÿ‘งโ€๐Ÿ‘ง "+e.toDisplayString(t.state.current.numberOfSubscribers)+" followers ",1),o.state.user._id&&e.unref(a).params._id&&e.unref(a).params._id!==o.state.user._id?(e.openBlock(),e.createBlock(p.default,{key:5,user:o.state.user._id,type:"user",role:"subscriber",target:t.state.current._id,status:t.state.current.isSubscriber,text:{create:"Follow",remove:"Unfollow"},onUpdateMembership:r[2]||(r[2]=s=>m(s,"isSubscriber","numberOfSubscribers")),class:"w-min mn-b-medium mn-r-auto mn-l-auto"},null,8,["user","target","status"])):e.createCommentVNode("",!0),Object.values(t.state.current.socials).some(s=>s)?(e.openBlock(),e.createElementBlock("h4",L," Find Me in Socials ")):e.createCommentVNode("",!0),e.createVNode(V.default,{telegram:t.state.current.socials.telegram,facebook:t.state.current.socials.facebook,instagram:t.state.current.socials.instagram,twitter:t.state.current.socials.twitter,class:"mn-r-auto mn-l-auto"},null,8,["telegram","facebook","instagram","twitter"])]),e.createVNode(d.default,{class:"mn-b-regular bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[3]||(r[3]=s=>e.unref(n).push({name:"User Events",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(B.default,{class:"i-semi",icon:!0,fill:"rgb(var(--white))"}),O]),_:1}),e.createVNode(l.default,{onClick:r[4]||(r[4]=s=>e.unref(n).push({name:"User Organizations",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(f.default,{class:"i-semi",icon:!0}),A]),_:1}),e.createVNode(l.default,{onClick:r[5]||(r[5]=s=>e.unref(n).push({name:"User Blogposts",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(w.default,{class:"i-semi",icon:!0}),j]),_:1})]),_:1}),i.APP_NAME==="Weeder"?(e.openBlock(),e.createBlock(d.default,{key:1,class:"mn-b-regular bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[6]||(r[6]=s=>e.unref(n).push({name:"User Wallet",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(f.default,{class:"i-semi",icon:!0}),W]),_:1})]),_:1})):e.createCommentVNode("",!0),o.state.user._id===e.unref(a).params._id?(e.openBlock(),e.createBlock(d.default,{key:2,class:"bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[7]||(r[7]=s=>e.unref(n).push({name:"User Edit Profile",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[z]),_:1}),e.createVNode(l.default,{onClick:r[8]||(r[8]=s=>e.unref(n).push({name:"Legal",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[G]),_:1}),e.createVNode(l.default,{class:"cursor-pointer",onClick:r[9]||(r[9]=s=>b())},{default:e.withCtx(()=>[T]),_:1})]),_:1})):e.createCommentVNode("",!0)]))])):e.createCommentVNode("",!0)}};exports.default=H;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");;/* empty css */;/* empty css */;/* empty css */const h=require("../../../../components/Dropdown/Dropdown.vue.cjs"),g=require("../../../../components/Completion/Completion.vue.cjs"),d=require("../../../../components/Menu/Menu.vue.cjs"),l=require("../../../../components/Menu/MenuItem.vue.cjs"),p=require("../../../organizations/components/elements/ButtonToggleMembership.vue.cjs"),N=require("../../../reports/components/sections/FormReport.vue.cjs"),V=require("../../../organizations/components/blocks/Socials.vue.cjs"),B=require("../../../icons/entities/IconEvents.vue.cjs"),f=require("../../../icons/entities/IconGroups.vue.cjs"),w=require("../../../icons/entities/IconCommunity.vue.cjs"),C=require("../../../icons/navigation/IconEdit.vue.cjs"),E=require("../../../icons/placeholders/PlaceholderUserpic.vue.cjs"),_=require("vue-router"),o=require("../../../auth/views/store/auth.cjs"),t=require("../../store/users.cjs"),v=require("../../../organizations/store/memberships.cjs");require("./Profile.vue2.cjs");const x={key:0,class:"for-transition w-100"},y={key:0,class:"flex-center flex pd-medium radius-big bg-light uppercase t-semi w-100 h-100"},q={key:1,_id:"dash",class:"pd-b-extra pd-thin w-100"},S={class:"flex-center pos-relative flex flex-column t-center w-100 mn-b-semi radius-medium pd-medium bg-light"},U={class:"bg-black pd-thin radius-small"},M=e.createElementVNode("button",{class:"w-100 bg-black br-solid br-1px br-white-transp-20 t-white button-small button"}," Report ",-1),P=["src"],R={class:"mn-b-thin"},$={key:4,class:"mn-b-thin t-main t-semi"},D={class:"mn-b-small p-medium"},I={class:"mn-b-medium flex-center flex-nowrap flex"},F={class:"t-semi mn-b-small"},L={key:6,class:"mn-t-small mn-b-thin"},O=e.createElementVNode("span",null,"Events",-1),A=e.createElementVNode("span",null,"Groups",-1),j=e.createElementVNode("span",null,"Posts",-1),W=e.createElementVNode("span",null,"Wallet",-1),z=e.createElementVNode("span",null," Settings ",-1),G=e.createElementVNode("span",null," About ",-1),T=e.createElementVNode("span",{class:"t-red"}," Logout ",-1),H={__name:"Profile",setup(J){const a=_.useRoute(),n=_.useRouter(),u=e.ref(!1);e.onMounted(async()=>{await t.actions.read({_id:a.params._id,user:o.state.user._id}),u.value=!0});const m=({membership:i,status:r,target:s},c,k)=>{v.mutations.handleMembershipUpdate(t.state.current,i,r,s,c,k)};function b(){o.actions.logout(),n.push({name:"Sign In"})}return(i,r)=>u.value?(e.openBlock(),e.createElementBlock("div",x,[t.state.current.status==="removed"?(e.openBlock(),e.createElementBlock("div",y," Sorry, user has been removed. ")):(e.openBlock(),e.createElementBlock("div",q,[e.unref(a).params._id===o.state.user._id&&u.value?(e.openBlock(),e.createBlock(g.default,{key:0,user:o.state.user._id,target:t.state.current,cta:!0,text_cta:"Fill Profile",text:"Profile completed at",class:"mn-b-medium"},null,8,["user","target"])):e.createCommentVNode("",!0),e.createElementVNode("section",S,[e.unref(a).params._id&&e.unref(a).params._id!==o.state.user._id?(e.openBlock(),e.createBlock(h.default,{key:0,label:"...",align:"right",class:"cursor-pointer pos-absolute pos-r-0 pos-t-0 pd-thin radius-extra"},{default:e.withCtx(()=>[e.createElementVNode("section",U,[e.createVNode(N.default,{user:o.state.user._id,type:"user",target:t.state.current._id,text:"Report",class:"w-100"},{default:e.withCtx(()=>[M]),_:1},8,["user","target"]),o.state.user._id?(e.openBlock(),e.createBlock(p.default,{key:0,user:o.state.user._id,type:"user",role:"blocked",target:t.state.current._id,status:t.state.current.isBlocked,text:{create:"Block",remove:"Unblock"},onUpdateMembership:r[0]||(r[0]=s=>m(s,"isBlocked")),class:"t-white mn-t-thin bg-red"},null,8,["user","target","status"])):e.createCommentVNode("",!0)])]),_:1})):e.createCommentVNode("",!0),e.unref(a).params._id===o.state.user._id?(e.openBlock(),e.createBlock(C.default,{key:1,onClick:r[1]||(r[1]=s=>i.$router.push({name:"User Edit Profile",params:{_id:o.state.user._id}})),class:"cursor-pointer pos-absolute pos-t-regular pos-r-regular i-regular t-transp"})):e.createCommentVNode("",!0),t.state.current.profile.photo&&t.state.current.profile.photo.length>0?(e.openBlock(),e.createElementBlock("img",{key:2,src:(i.FILE_SERVER_URL||"")+t.state.current.profile.photo,class:"radius-extra bg-white mn-b-small object-fit-cover i-extra"},null,8,P)):(e.openBlock(),e.createBlock(E.default,{key:3,class:"radius-medium mn-b-small i-extra"})),e.createElementVNode("h3",R,e.toDisplayString(t.state.current.profile.name?t.state.current.profile.name:"Anonymous"),1),t.state.current.username?(e.openBlock(),e.createElementBlock("p",$," @"+e.toDisplayString(t.state.current.username?t.state.current.username:"Not specified"),1)):e.createCommentVNode("",!0),e.createElementVNode("p",D,e.toDisplayString(t.state.current.profile.description?t.state.current.profile.description:"Bio not specified"),1),e.createElementVNode("div",I,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.state.current.roles,(s,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["pd-thin radius-small t-semi bg-white",{"mn-r-thin":c!==t.state.current.roles.length-1}])},e.toDisplayString(s.icon)+" "+e.toDisplayString(s.name),3))),256))]),e.createElementVNode("p",F," ๐Ÿ‘จโ€๐Ÿ‘จโ€๐Ÿ‘งโ€๐Ÿ‘ง "+e.toDisplayString(t.state.current.numberOfSubscribers)+" followers ",1),o.state.user._id&&e.unref(a).params._id&&e.unref(a).params._id!==o.state.user._id?(e.openBlock(),e.createBlock(p.default,{key:5,user:o.state.user._id,type:"user",role:"subscriber",target:t.state.current._id,status:t.state.current.isSubscriber,text:{create:"Follow",remove:"Unfollow"},onUpdateMembership:r[2]||(r[2]=s=>m(s,"isSubscriber","numberOfSubscribers")),class:"w-min mn-b-medium mn-r-auto mn-l-auto"},null,8,["user","target","status"])):e.createCommentVNode("",!0),Object.values(t.state.current.socials).some(s=>s)?(e.openBlock(),e.createElementBlock("h4",L," Find Me in Socials ")):e.createCommentVNode("",!0),e.createVNode(V.default,{telegram:t.state.current.socials.telegram,facebook:t.state.current.socials.facebook,instagram:t.state.current.socials.instagram,twitter:t.state.current.socials.twitter,class:"mn-r-auto mn-l-auto"},null,8,["telegram","facebook","instagram","twitter"])]),e.createVNode(d.default,{class:"mn-b-regular bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[3]||(r[3]=s=>e.unref(n).push({name:"User Events",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(B.default,{class:"i-semi",icon:!0,fill:"rgb(var(--white))"}),O]),_:1}),e.createVNode(l.default,{onClick:r[4]||(r[4]=s=>e.unref(n).push({name:"User Organizations",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(f.default,{class:"i-semi",icon:!0}),A]),_:1}),e.createVNode(l.default,{onClick:r[5]||(r[5]=s=>e.unref(n).push({name:"User Blogposts",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(w.default,{class:"i-semi",icon:!0}),j]),_:1})]),_:1}),i.APP_NAME==="Weeder"?(e.openBlock(),e.createBlock(d.default,{key:1,class:"mn-b-regular bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[6]||(r[6]=s=>e.unref(n).push({name:"User Wallet",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[e.createVNode(f.default,{class:"i-semi",icon:!0}),W]),_:1})]),_:1})):e.createCommentVNode("",!0),o.state.user._id===e.unref(a).params._id?(e.openBlock(),e.createBlock(d.default,{key:2,class:"bg-light"},{default:e.withCtx(()=>[e.createVNode(l.default,{onClick:r[7]||(r[7]=s=>e.unref(n).push({name:"User Edit Profile",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[z]),_:1}),e.createVNode(l.default,{onClick:r[8]||(r[8]=s=>e.unref(n).push({name:"Legal",params:{_id:e.unref(a).params._id}})),class:"cursor-pointer"},{default:e.withCtx(()=>[G]),_:1}),e.createVNode(l.default,{class:"cursor-pointer",onClick:r[9]||(r[9]=s=>b())},{default:e.withCtx(()=>[T]),_:1})]),_:1})):e.createCommentVNode("",!0)]))])):e.createCommentVNode("",!0)}};exports.default=H;
@@ -2,7 +2,7 @@ import { ref as U, onMounted as C, openBlock as i, createElementBlock as c, unre
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  /* empty css */
5
- import B from "../../../../components/Dropdown/Dropdown.vue2.js";
5
+ import B from "../../../../components/Dropdown/Dropdown.vue.js";
6
6
  import M from "../../../../components/Completion/Completion.vue.js";
7
7
  import k from "../../../../components/Menu/Menu.vue.js";
8
8
  import _ from "../../../../components/Menu/MenuItem.vue.js";
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-i18n"),m=require("web3"),t=require("../../store/wallet.store.cjs"),p=require("../../localization/wallet.json.cjs"),b=require("../../../../../components/Popup/Popup.vue.cjs"),k=require("../../../../../components/Button/Button.vue2.cjs");require("vue-router");;/* empty css */require("../../../../reports/store/reports.cjs");;/* empty css */;/* empty css */require("../../../../auth/views/store/auth.cjs");require("../../../../organizations/store/memberships.cjs");require("../../../../community/store/reactions.cjs");;/* empty css */const h=require("../elements/ConnectMetamask.vue.cjs"),f=require("../blocks/CashDeposit.vue.cjs"),_=require("../blocks/CardDeposit.vue.cjs"),g=require("../blocks/CryptoDeposit.vue.cjs"),w=require("../blocks/CardBalanceReplenished.vue.cjs"),N=require("../blocks/CryptoDepositProcessing.vue.cjs"),V={class:"pd-thin"},E={class:"bg-black t-white mn-b-thin radius-big pd-big"},B={class:"mn-b-medium"},v={class:"mn-b-semi t-transp p-big"},y={key:0,class:"gap-thin mn-b-thin flex-nowrap bg-black radius-extra t-white br-solid br-white-transp-10 br-1px flex-v-center flex pd-medium"},C={class:"flex-v-center flex-nowrap flex mn-r-auto"},x={key:1,class:"w-100 mn-b-semi flex-column flex pd-big radius-big bg-main t-black"},S=e.createElementVNode("p",{class:"t-transp t-medium mn-b-thin"},"You own:",-1),q={class:"h1 mn-b-small"},D=e.createElementVNode("p",{class:"t-white p-big t-medium mn-b-semi"},"of all shares",-1),M={class:"flex-v-center mn-b-small flex-nowrap flex pd-small bg-black-transp-5 radius-extra"},W={key:0,class:"t-transp t-medium"},P=e.createElementVNode("span",{class:"uppercase p-small t-medium t-transp"},"Connected Metamask",-1),R=e.createElementVNode("br",null,null,-1),T={key:0,class:"mn-b-semi cols-2 gap-thin"},$=e.createElementVNode("div",{class:"w-100 pd-medium radius-medium t-center bg-light"},[e.createElementVNode("h3",{class:"mn-b-small"},"Make first order and start earning Weeder Token"),e.createElementVNode("button",{class:"mn-l-auto mn-r-auto bg-main button"},"Explore marketplace")],-1),G={class:"w-100 pd-medium flex-center flex flex-column radius-medium t-center bg-light"},O={key:0,class:"mn-b-small"},A={key:1,class:"mn-b-small"},L={class:"cols-3 gap-thin"},F={class:"radius-medium bg-light"},I={class:"flex-nowrap br-b br-black-transp-10 br-solid flex pd-medium"},Y={class:"t-semi mn-r-auto"},j={class:"pd-t-nano pd-b-nano pd-l-thin pd-r-thin bg-main flex flex-center radius-extra t-semi p-small"},H={class:"pd-medium"},z={class:"t-regular mn-b-thin"},J={key:2,class:"mn-b-small"},K={class:"cols-3 gap-thin"},Q={class:"radius-medium bg-grey"},U={class:"flex-nowrap br-b br-black-transp-10 br-solid flex pd-medium"},X={class:"t-semi mn-r-auto"},Z={class:"pd-t-nano pd-b-nano pd-l-thin pd-r-thin bg-main flex flex-center radius-extra t-semi p-small"},ee={class:"pd-medium"},te={class:"t-regular mn-b-thin"},ne={key:0},oe=e.createElementVNode("h2",{class:"mn-b-small t-center t-bold"},"Choose the way of deposit",-1),se={__name:"Wallet",setup(le){const{t:r}=u.useI18n({useScope:"global",...p.default});window.ethereum.on("accountsChanged",a=>{a.length<1&&(t.state.account=null)}),t.state.web3=new m(window.ethereum||"http://localhost:8080"),e.onMounted(()=>{t.actions.listRewards(),t.actions.tryReconnectWallet()});const c=e.ref(!1),l=e.ref(0);function s(a){l.value=a}function d(){c.value=!0}function i(){c.value=!1,l.value=0,t.actions.stopTimer(),t.actions.disconnectWebSocket()}return(a,o)=>(e.openBlock(),e.createElementBlock("div",V,[e.createElementVNode("section",E,[e.createElementVNode("h1",B,e.toDisplayString(e.unref(r)("wallet.title")),1),e.createElementVNode("p",v,e.toDisplayString(e.unref(r)("wallet.subtitle")),1),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("div",C,[e.createElementVNode("h2",null,e.toDisplayString(e.unref(t.state).tokenBalance)+" "+e.toDisplayString(e.unref(r)("wallet.token")),1)]),e.createElementVNode("button",{onClick:d,class:"t-nowrap w-max bg-main t-medium button"},"Get More"),e.createVNode(k.default,{submit:e.unref(t.actions).collectRewards,class:"w-max bg-white t-black t-medium button"},{default:e.withCtx(()=>[e.createTextVNode(" Withdraw ")]),_:1},8,["submit"])])):e.createCommentVNode("",!0),e.createVNode(h.default,{class:"mn-b-thin radius-extra br-solid br-white-transp-10 br-1px w-100"}),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("div",x,[S,e.createElementVNode("p",q,e.toDisplayString(e.unref(t.state).share)+"%",1),D,e.createElementVNode("div",M,[e.unref(t.state).account?(e.openBlock(),e.createElementBlock("p",W,[P,R,e.createElementVNode("span",null,e.toDisplayString(e.unref(t.state).account),1)])):e.createCommentVNode("",!0),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("button",{key:1,onClick:o[0]||(o[0]=(...n)=>e.unref(t.actions).disconnectWallet&&e.unref(t.actions).disconnectWallet(...n)),class:"mn-l-auto bg-red button"}," Disconnect Wallet ")):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0)]),e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",T,[$,e.createElementVNode("div",G,[e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("h3",O," Connect Metamask to withdrawal your earnings. ")),e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:1,onClick:o[1]||(o[1]=(...n)=>e.unref(t.actions).connectWallet&&e.unref(t.actions).connectWallet(...n)),class:"br-solid br-2px br-black-transp-10 t-black button"}," Connect Wallet "))])])),e.unref(t.state).rewards.length>0?(e.openBlock(),e.createElementBlock("h2",A,"Latest Rewards ")):e.createCommentVNode("",!0),e.createElementVNode("section",L,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(t.state).rewards,n=>(e.openBlock(),e.createElementBlock("div",F,[e.createElementVNode("div",I,[e.createElementVNode("p",Y,e.toDisplayString(n.amount)+" WDT",1),e.createElementVNode("span",j,e.toDisplayString(n.type==="blogpost"?"Community Reward":n.type),1)]),e.createElementVNode("div",H,[e.createElementVNode("h4",z,e.toDisplayString(n.name),1)])]))),256))]),e.unref(t.state).rewards.length>0?(e.openBlock(),e.createElementBlock("h2",J,"Activity")):e.createCommentVNode("",!0),e.createElementVNode("section",K,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(t.state).rewards,n=>(e.openBlock(),e.createElementBlock("div",Q,[e.createElementVNode("div",U,[e.createElementVNode("p",X,e.toDisplayString(n.amount)+" WDT",1),e.createElementVNode("span",Z,e.toDisplayString(n.type==="blogpost"?"Community Reward":n.type),1)]),e.createElementVNode("div",ee,[e.createElementVNode("h4",te,e.toDisplayString(n.name),1)])]))),256))]),e.createVNode(b.default,{onClosePopup:i,isPopupOpen:c.value,class:"w-m-50r t-left pd-big bg-white radius-big"},{default:e.withCtx(()=>[l.value===0?(e.openBlock(),e.createElementBlock("div",ne,[oe,e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[2]||(o[2]=n=>s(1))}," CASH "),e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[3]||(o[3]=n=>s(2))}," CARD "),e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[4]||(o[4]=n=>s(4))}," CRYPTO ")])):e.createCommentVNode("",!0),l.value===1?(e.openBlock(),e.createBlock(f.default,{key:1,onBackSelection:o[5]||(o[5]=n=>s(0))})):e.createCommentVNode("",!0),l.value===2?(e.openBlock(),e.createBlock(_.default,{key:2,onBackSelection:o[6]||(o[6]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0),l.value===3?(e.openBlock(),e.createBlock(w.default,{key:3,onClose:i})):e.createCommentVNode("",!0),l.value===4?(e.openBlock(),e.createBlock(g.default,{key:4,onBackSelection:o[7]||(o[7]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0),l.value===5?(e.openBlock(),e.createBlock(N.default,{key:5,onBackSelection:o[8]||(o[8]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0)]),_:1},8,["isPopupOpen"])]))}};exports.default=se;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("vue-i18n"),m=require("web3"),t=require("../../store/wallet.store.cjs"),p=require("../../localization/wallet.json.cjs"),b=require("../../../../../components/Popup/Popup.vue.cjs"),k=require("../../../../../components/Button/Button.vue2.cjs");require("vue-router");;/* empty css */require("../../../../reports/store/reports.cjs");;/* empty css */;/* empty css */require("../../../../auth/views/store/auth.cjs");require("../../../../organizations/store/memberships.cjs");require("../../../../community/store/reactions.cjs");;/* empty css */const h=require("../elements/ConnectMetamask.vue.cjs"),f=require("../blocks/CashDeposit.vue.cjs"),_=require("../blocks/CardDeposit.vue.cjs"),g=require("../blocks/CryptoDeposit.vue.cjs"),w=require("../blocks/CardBalanceReplenished.vue.cjs"),N=require("../blocks/CryptoDepositProcessing.vue.cjs"),V={class:"pd-thin"},E={class:"bg-black t-white mn-b-thin radius-big pd-big"},B={class:"mn-b-medium"},v={class:"mn-b-semi t-transp p-big"},y={key:0,class:"gap-thin mn-b-thin flex-nowrap bg-black radius-extra t-white br-solid br-white-transp-10 br-1px flex-v-center flex pd-medium"},C={class:"flex-v-center flex-nowrap flex mn-r-auto"},x={key:1,class:"w-100 mn-b-semi flex-column flex pd-big radius-big bg-main t-black"},S=e.createElementVNode("p",{class:"t-transp t-medium mn-b-thin"},"You own:",-1),q={class:"h1 mn-b-small"},D=e.createElementVNode("p",{class:"t-white p-big t-medium mn-b-semi"},"of all shares",-1),M={class:"flex-v-center mn-b-small flex-nowrap flex pd-small bg-black-transp-5 radius-extra"},W={key:0,class:"t-transp t-medium"},P=e.createElementVNode("span",{class:"uppercase p-small t-medium t-transp"},"Connected Metamask",-1),R=e.createElementVNode("br",null,null,-1),T={key:0,class:"mn-b-semi cols-2 gap-thin"},$=e.createElementVNode("div",{class:"w-100 pd-medium radius-medium t-center bg-light"},[e.createElementVNode("h3",{class:"mn-b-small"},"Make first order and start earning Weeder Token"),e.createElementVNode("button",{class:"mn-l-auto mn-r-auto bg-main button"},"Explore marketplace")],-1),G={class:"w-100 pd-medium flex-center flex flex-column radius-medium t-center bg-light"},O={key:0,class:"mn-b-small"},A={key:1,class:"mn-b-small"},L={class:"cols-3 gap-thin"},F={class:"radius-medium bg-light"},I={class:"flex-nowrap br-b br-black-transp-10 br-solid flex pd-medium"},Y={class:"t-semi mn-r-auto"},j={class:"pd-t-nano pd-b-nano pd-l-thin pd-r-thin bg-main flex flex-center radius-extra t-semi p-small"},H={class:"pd-medium"},z={class:"t-regular mn-b-thin"},J={key:2,class:"mn-b-small"},K={class:"cols-3 gap-thin"},Q={class:"radius-medium bg-grey"},U={class:"flex-nowrap br-b br-black-transp-10 br-solid flex pd-medium"},X={class:"t-semi mn-r-auto"},Z={class:"pd-t-nano pd-b-nano pd-l-thin pd-r-thin bg-main flex flex-center radius-extra t-semi p-small"},ee={class:"pd-medium"},te={class:"t-regular mn-b-thin"},ne={key:0},oe=e.createElementVNode("h2",{class:"mn-b-small t-center t-bold"},"Choose the way of deposit",-1),se={__name:"Wallet",setup(le){const{t:r}=u.useI18n({useScope:"global",...p.default});window.ethereum.on("accountsChanged",a=>{a.length<1&&(t.state.account=null)}),t.state.web3=new m(window.ethereum||"http://localhost:8080"),e.onMounted(()=>{t.actions.listRewards(),t.actions.tryReconnectWallet()});const c=e.ref(!1),l=e.ref(0);function s(a){l.value=a}function d(){c.value=!0}function i(){c.value=!1,l.value=0,t.actions.stopTimer(),t.actions.disconnectWebSocket()}return(a,o)=>(e.openBlock(),e.createElementBlock("div",V,[e.createElementVNode("section",E,[e.createElementVNode("h1",B,e.toDisplayString(e.unref(r)("wallet.title")),1),e.createElementVNode("p",v,e.toDisplayString(e.unref(r)("wallet.subtitle")),1),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("div",C,[e.createElementVNode("h2",null,e.toDisplayString(e.unref(t.state).tokenBalance)+" "+e.toDisplayString(e.unref(r)("wallet.token")),1)]),e.createElementVNode("button",{onClick:d,class:"t-nowrap w-max bg-main t-medium button"},"Get More"),e.createVNode(k.default,{submit:e.unref(t.actions).collectRewards,class:"w-max bg-white t-black t-medium button"},{default:e.withCtx(()=>[e.createTextVNode(" Withdraw ")]),_:1},8,["submit"])])):e.createCommentVNode("",!0),e.createVNode(h.default,{class:"mn-b-thin radius-extra br-solid br-white-transp-10 br-1px w-100"}),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("div",x,[S,e.createElementVNode("p",q,e.toDisplayString(e.unref(t.state).share)+"%",1),D,e.createElementVNode("div",M,[e.unref(t.state).account?(e.openBlock(),e.createElementBlock("p",W,[P,R,e.createElementVNode("span",null,e.toDisplayString(e.unref(t.state).account),1)])):e.createCommentVNode("",!0),e.unref(t.state).account?(e.openBlock(),e.createElementBlock("button",{key:1,onClick:o[0]||(o[0]=(...n)=>e.unref(t.actions).disconnectWallet&&e.unref(t.actions).disconnectWallet(...n)),class:"mn-l-auto bg-red button"}," Disconnect Wallet ")):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0)]),e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",T,[$,e.createElementVNode("div",G,[e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("h3",O," Connect Metamask to withdrawal your earnings. ")),e.unref(t.state).account?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:1,onClick:o[1]||(o[1]=(...n)=>e.unref(t.actions).connectWallet&&e.unref(t.actions).connectWallet(...n)),class:"br-solid br-2px br-black-transp-10 t-black button"}," Connect Wallet "))])])),e.unref(t.state).rewards.length>0?(e.openBlock(),e.createElementBlock("h2",A,"Latest Rewards ")):e.createCommentVNode("",!0),e.createElementVNode("section",L,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(t.state).rewards,n=>(e.openBlock(),e.createElementBlock("div",F,[e.createElementVNode("div",I,[e.createElementVNode("p",Y,e.toDisplayString(n.amount)+" WDT",1),e.createElementVNode("span",j,e.toDisplayString(n.type==="blogpost"?"Community Reward":n.type),1)]),e.createElementVNode("div",H,[e.createElementVNode("h4",z,e.toDisplayString(n.name),1)])]))),256))]),e.unref(t.state).rewards.length>0?(e.openBlock(),e.createElementBlock("h2",J,"Activity")):e.createCommentVNode("",!0),e.createElementVNode("section",K,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(t.state).rewards,n=>(e.openBlock(),e.createElementBlock("div",Q,[e.createElementVNode("div",U,[e.createElementVNode("p",X,e.toDisplayString(n.amount)+" WDT",1),e.createElementVNode("span",Z,e.toDisplayString(n.type==="blogpost"?"Community Reward":n.type),1)]),e.createElementVNode("div",ee,[e.createElementVNode("h4",te,e.toDisplayString(n.name),1)])]))),256))]),e.createVNode(b.default,{onClosePopup:i,isPopupOpen:c.value,class:"w-m-50r t-left pd-big bg-white radius-big"},{default:e.withCtx(()=>[l.value===0?(e.openBlock(),e.createElementBlock("div",ne,[oe,e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[2]||(o[2]=n=>s(1))}," CASH "),e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[3]||(o[3]=n=>s(2))}," CARD "),e.createElementVNode("button",{class:"w-100 bg-white t-black pd-thin radius-medium h3 t-center br-solid br-2px br-black-transp-10 mn-t-small",onClick:o[4]||(o[4]=n=>s(4))}," CRYPTO ")])):e.createCommentVNode("",!0),l.value===1?(e.openBlock(),e.createBlock(f.default,{key:1,onBackSelection:o[5]||(o[5]=n=>s(0))})):e.createCommentVNode("",!0),l.value===2?(e.openBlock(),e.createBlock(_.default,{key:2,onBackSelection:o[6]||(o[6]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0),l.value===3?(e.openBlock(),e.createBlock(w.default,{key:3,onClose:i})):e.createCommentVNode("",!0),l.value===4?(e.openBlock(),e.createBlock(g.default,{key:4,onBackSelection:o[7]||(o[7]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0),l.value===5?(e.openBlock(),e.createBlock(N.default,{key:5,onBackSelection:o[8]||(o[8]=n=>s(0)),onSwitchMenu:s})):e.createCommentVNode("",!0)]),_:1},8,["isPopupOpen"])]))}};exports.default=se;
@@ -9,11 +9,11 @@ import "vue-router";
9
9
  /* empty css */
10
10
  import "../../../../reports/store/reports.js";
11
11
  /* empty css */
12
- /* empty css */
12
+ /* empty css */
13
13
  import "../../../../auth/views/store/auth.js";
14
14
  import "../../../../organizations/store/memberships.js";
15
15
  import "../../../../community/store/reactions.js";
16
- /* empty css */
16
+ /* empty css */
17
17
  import B from "../elements/ConnectMetamask.vue.js";
18
18
  import R from "../blocks/CashDeposit.vue.js";
19
19
  import D from "../blocks/CardDeposit.vue.js";