@ozdao/martyrs 0.2.424 → 0.2.426
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/builder.js +2 -12
- package/dist/builder.mjs +2 -12
- package/dist/martyrs/src/components/Block/Block.vue.cjs +1 -1
- package/dist/martyrs/src/components/Block/Block.vue.js +1 -1
- package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.cjs +87 -5
- package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.cjs.map +1 -1
- package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.js +88 -6
- package/dist/martyrs/src/components/PhotoViewer/PhotoViewer.vue.js.map +1 -1
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue.cjs → Tooltip.vue2.cjs} +2 -2
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue2.cjs.map +1 -0
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue.js → Tooltip.vue2.js} +2 -2
- package/dist/martyrs/src/components/Tooltip/{Tooltip.vue.cjs.map → Tooltip.vue2.js.map} +1 -1
- package/dist/martyrs/src/modules/globals/views/components/blocks/CardHeader.vue.cjs +1 -1
- package/dist/martyrs/src/modules/globals/views/components/blocks/CardHeader.vue.js +1 -1
- package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.cjs +1 -1
- package/dist/martyrs/src/modules/orders/components/blocks/CardOrderUser.vue.js +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
- package/dist/martyrs/src/modules/organizations/components/pages/Members.vue.js +1 -1
- package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.cjs +1 -1
- package/dist/martyrs/src/modules/pages/views/components/pages/PageEdit.vue.js +1 -1
- package/dist/martyrs/src/modules/products/components/blocks/ImagesThumbnails.vue.cjs +52 -14
- package/dist/martyrs/src/modules/products/components/blocks/ImagesThumbnails.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/products/components/blocks/ImagesThumbnails.vue.js +53 -15
- package/dist/martyrs/src/modules/products/components/blocks/ImagesThumbnails.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.cjs +37 -65
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js +38 -66
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js.map +1 -1
- package/dist/style.css +39 -61
- package/package.json +1 -1
- package/src/builder/modes/spa.dev.js +3 -1
- package/src/builder/modes/spa.prod.js +1 -1
- package/src/builder/modes/ssr.dev.js +10 -10
- package/src/components/PhotoViewer/PhotoViewer.vue +140 -12
- package/src/modules/products/components/blocks/ImagesThumbnails.vue +46 -37
- package/src/modules/products/components/pages/Product.vue +5 -28
- package/dist/martyrs/src/components/Tooltip/Tooltip.vue.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { computed, ref, onMounted, createElementBlock, createCommentVNode, openBlock, createElementVNode,
|
|
1
|
+
import { computed, ref, onMounted, createElementBlock, createCommentVNode, openBlock, createElementVNode, createVNode, createBlock, unref, toDisplayString, Transition, withCtx, Fragment, renderList } from "vue";
|
|
2
2
|
import { useRoute, useRouter } from "vue-router";
|
|
3
3
|
import { useI18n } from "vue-i18n";
|
|
4
4
|
import "../../../auth/views/store/auth.js";
|
|
@@ -12,8 +12,6 @@ import _sfc_main$3 from "../../../../components/Tab/Tab.vue2.js";
|
|
|
12
12
|
import _sfc_main$5 from "../../../globals/views/components/blocks/PopupDateSelector.vue.js";
|
|
13
13
|
import _sfc_main$1 from "../../../icons/navigation/IconEdit.vue.js";
|
|
14
14
|
import _sfc_main$4 from "../../../icons/actions/IconShopcartAdd.vue.js";
|
|
15
|
-
import PlaceholderImage from "../../../icons/placeholders/PlaceholderImage.vue.js";
|
|
16
|
-
import Images360 from "../blocks/Images360.vue.js";
|
|
17
15
|
import ImagesThumbnails from "../blocks/ImagesThumbnails.vue.js";
|
|
18
16
|
import _sfc_main$2 from "../elements/Price.vue.js";
|
|
19
17
|
import _sfc_main$7 from "../sections/PopularProducts.vue.js";
|
|
@@ -22,44 +20,41 @@ const _hoisted_1 = {
|
|
|
22
20
|
class: "h-100 w-100 mobile:pd-thin pd-big bg-white"
|
|
23
21
|
};
|
|
24
22
|
const _hoisted_2 = { class: "cols-2-1_2 w-100 gap-medium" };
|
|
25
|
-
const _hoisted_3 = { class: "w-100
|
|
26
|
-
const _hoisted_4 = { class: "
|
|
27
|
-
const _hoisted_5 =
|
|
28
|
-
const _hoisted_6 = { class: "pos-relative w-100 h-100 flex-column flex-h-center flex" };
|
|
29
|
-
const _hoisted_7 = { class: "w-100 h1-product mn-b-small" };
|
|
30
|
-
const _hoisted_8 = {
|
|
23
|
+
const _hoisted_3 = { class: "pos-relative w-100 h-100 flex-column flex-h-center flex" };
|
|
24
|
+
const _hoisted_4 = { class: "w-100 h1-product mn-b-small" };
|
|
25
|
+
const _hoisted_5 = {
|
|
31
26
|
key: 1,
|
|
32
27
|
class: "h-min-5r o-hidden radius-small bg-light mn-b-medium pos-relative"
|
|
33
28
|
};
|
|
34
|
-
const
|
|
29
|
+
const _hoisted_6 = {
|
|
35
30
|
key: 0,
|
|
36
31
|
class: "pd-medium"
|
|
37
32
|
};
|
|
38
|
-
const
|
|
33
|
+
const _hoisted_7 = {
|
|
39
34
|
key: 0,
|
|
40
35
|
class: "w-100 t-transp"
|
|
41
36
|
};
|
|
42
|
-
const
|
|
37
|
+
const _hoisted_8 = {
|
|
43
38
|
key: 1,
|
|
44
39
|
class: "w-100 t-transp"
|
|
45
40
|
};
|
|
46
|
-
const
|
|
41
|
+
const _hoisted_9 = {
|
|
47
42
|
key: 1,
|
|
48
43
|
class: "cols-2 pd-medium w-100 gap-small"
|
|
49
44
|
};
|
|
50
|
-
const
|
|
51
|
-
const
|
|
52
|
-
const
|
|
53
|
-
const
|
|
54
|
-
const
|
|
55
|
-
const
|
|
56
|
-
const
|
|
57
|
-
const
|
|
58
|
-
const
|
|
45
|
+
const _hoisted_10 = { class: "w-100 pd-small radius-small bg-white product-information" };
|
|
46
|
+
const _hoisted_11 = { class: "t-demi" };
|
|
47
|
+
const _hoisted_12 = { class: "w-max-33r" };
|
|
48
|
+
const _hoisted_13 = { class: "w-max-33r" };
|
|
49
|
+
const _hoisted_14 = { key: 0 };
|
|
50
|
+
const _hoisted_15 = { class: "gap-thin flex flex-center flex-nowrap" };
|
|
51
|
+
const _hoisted_16 = { key: 1 };
|
|
52
|
+
const _hoisted_17 = { class: "gap-thin flex flex-center flex-nowrap" };
|
|
53
|
+
const _hoisted_18 = {
|
|
59
54
|
key: 1,
|
|
60
55
|
class: "flex-center flex uppercase radius-big t-black w-max pd-small t-medium bg-grey h-3r w-100 mn-r-smallbutton"
|
|
61
56
|
};
|
|
62
|
-
const
|
|
57
|
+
const _hoisted_19 = { class: "h-max pos-relative" };
|
|
63
58
|
const _sfc_main = {
|
|
64
59
|
__name: "Product",
|
|
65
60
|
emits: ["page-loading", "page-loaded"],
|
|
@@ -104,46 +99,23 @@ const _sfc_main = {
|
|
|
104
99
|
var _a, _b, _c, _d;
|
|
105
100
|
return state.current._id ? (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
106
101
|
createElementVNode("div", _hoisted_2, [
|
|
102
|
+
createVNode(ImagesThumbnails, {
|
|
103
|
+
images: images.value,
|
|
104
|
+
product: product.value
|
|
105
|
+
}, null, 8, ["images", "product"]),
|
|
107
106
|
createElementVNode("div", _hoisted_3, [
|
|
108
|
-
createElementVNode("div", _hoisted_4, [
|
|
109
|
-
product.value && product.value.image3d ? (openBlock(), createBlock(Images360, {
|
|
110
|
-
key: 0,
|
|
111
|
-
class: "h-100 w-100",
|
|
112
|
-
imagePath: `/assets/images/products/${product.value.image3d}`,
|
|
113
|
-
imageCount: 36
|
|
114
|
-
}, null, 8, ["imagePath"])) : createCommentVNode("", true),
|
|
115
|
-
images.value[0] && !product.value.image3d ? (openBlock(), createElementBlock("img", {
|
|
116
|
-
key: 1,
|
|
117
|
-
loading: "lazy",
|
|
118
|
-
class: "h-max h-max-15r bg-white radius-semi w-100",
|
|
119
|
-
style: { "object-fit": "contain" },
|
|
120
|
-
src: (_ctx.FILE_SERVER_URL || "") + images.value[0]
|
|
121
|
-
}, null, 8, _hoisted_5)) : createCommentVNode("", true),
|
|
122
|
-
!images.value[0] && !product.value.image3d ? (openBlock(), createBlock(PlaceholderImage, {
|
|
123
|
-
key: 2,
|
|
124
|
-
class: "h-max-20r h-100 w-100",
|
|
125
|
-
style: { "object-fit": "cover" }
|
|
126
|
-
})) : createCommentVNode("", true)
|
|
127
|
-
]),
|
|
128
|
-
images.value.length > 1 ? (openBlock(), createBlock(ImagesThumbnails, {
|
|
129
|
-
key: 0,
|
|
130
|
-
images: images.value,
|
|
131
|
-
class: "pd-semi pd-t-zero"
|
|
132
|
-
}, null, 8, ["images"])) : createCommentVNode("", true)
|
|
133
|
-
]),
|
|
134
|
-
createElementVNode("div", _hoisted_6, [
|
|
135
107
|
_ctx.accesses && _ctx.hasAccess(unref(route).params._id, "products", "edit", _ctx.accesses) ? (openBlock(), createBlock(_sfc_main$1, {
|
|
136
108
|
key: 0,
|
|
137
109
|
onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$router.push({ name: "ProductEdit", params: { _id: product.value.owner.target, product: product.value._id } })),
|
|
138
110
|
class: "pos-absolute pos-t-regular pos-r-regular i-regular t-transp"
|
|
139
111
|
})) : createCommentVNode("", true),
|
|
140
|
-
createElementVNode("h2",
|
|
112
|
+
createElementVNode("h2", _hoisted_4, toDisplayString(product.value.name), 1),
|
|
141
113
|
createVNode(_sfc_main$2, {
|
|
142
114
|
product: product.value,
|
|
143
115
|
size: "big",
|
|
144
116
|
class: "flex gap-micro flex-center pd-small br-solid br-1px br-black-transp-10 w-max mn-b-medium"
|
|
145
117
|
}, null, 8, ["product"]),
|
|
146
|
-
product.value.description || product.value.specification ? (openBlock(), createElementBlock("div",
|
|
118
|
+
product.value.description || product.value.specification ? (openBlock(), createElementBlock("div", _hoisted_5, [
|
|
147
119
|
createVNode(_sfc_main$3, {
|
|
148
120
|
selected: tabProduct.value,
|
|
149
121
|
"onUpdate:selected": _cache[1] || (_cache[1] = ($event) => tabProduct.value = $event),
|
|
@@ -156,13 +128,13 @@ const _sfc_main = {
|
|
|
156
128
|
}, null, 8, ["selected"]),
|
|
157
129
|
createVNode(Transition, { name: "slide-fade" }, {
|
|
158
130
|
default: withCtx(() => [
|
|
159
|
-
tabProduct.value === "description" ? (openBlock(), createElementBlock("div",
|
|
160
|
-
product.value.description && !product.value.localization < 1 && !_ctx.recommendation ? (openBlock(), createElementBlock("p",
|
|
161
|
-
product.value.localization && product.value.localization.length > 1 && !_ctx.recommendation ? (openBlock(), createElementBlock("p",
|
|
162
|
-
])) : (openBlock(), createElementBlock("div",
|
|
131
|
+
tabProduct.value === "description" ? (openBlock(), createElementBlock("div", _hoisted_6, [
|
|
132
|
+
product.value.description && !product.value.localization < 1 && !_ctx.recommendation ? (openBlock(), createElementBlock("p", _hoisted_7, toDisplayString(product.value.description), 1)) : createCommentVNode("", true),
|
|
133
|
+
product.value.localization && product.value.localization.length > 1 && !_ctx.recommendation ? (openBlock(), createElementBlock("p", _hoisted_8, toDisplayString(unref(t)("description")), 1)) : createCommentVNode("", true)
|
|
134
|
+
])) : (openBlock(), createElementBlock("div", _hoisted_9, [
|
|
163
135
|
product.value.information.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(product.value.information, (information) => {
|
|
164
|
-
return openBlock(), createElementBlock("div",
|
|
165
|
-
createElementVNode("p",
|
|
136
|
+
return openBlock(), createElementBlock("div", _hoisted_10, [
|
|
137
|
+
createElementVNode("p", _hoisted_11, toDisplayString(information.name), 1),
|
|
166
138
|
createElementVNode("p", null, toDisplayString(information.value), 1)
|
|
167
139
|
]);
|
|
168
140
|
}), 256)) : createCommentVNode("", true)
|
|
@@ -171,14 +143,14 @@ const _sfc_main = {
|
|
|
171
143
|
_: 1
|
|
172
144
|
})
|
|
173
145
|
])) : createCommentVNode("", true),
|
|
174
|
-
createElementVNode("div",
|
|
175
|
-
createElementVNode("div",
|
|
176
|
-
product.value.listing === "rent" ? (openBlock(), createElementBlock("div",
|
|
146
|
+
createElementVNode("div", _hoisted_12, [
|
|
147
|
+
createElementVNode("div", _hoisted_13, [
|
|
148
|
+
product.value.listing === "rent" ? (openBlock(), createElementBlock("div", _hoisted_14, [
|
|
177
149
|
createElementVNode("button", {
|
|
178
150
|
onClick: openPopup,
|
|
179
151
|
class: "cursor-pointer pd-small radius-big w-max mobile:w-100 bg-main button"
|
|
180
152
|
}, [
|
|
181
|
-
createElementVNode("div",
|
|
153
|
+
createElementVNode("div", _hoisted_15, [
|
|
182
154
|
createVNode(_sfc_main$4, { class: "i-semi" }),
|
|
183
155
|
createElementVNode("span", null, toDisplayString(unref(t)("addtoorder")), 1)
|
|
184
156
|
])
|
|
@@ -193,26 +165,26 @@ const _sfc_main = {
|
|
|
193
165
|
onConfirm: (selectedDates) => addToCart(product.value, selectedDates),
|
|
194
166
|
onClose: closePopup
|
|
195
167
|
}, null, 8, ["product", "isOpen", "showFees", "feesRate", "showVat", "vatRate", "onConfirm"])
|
|
196
|
-
])) : (openBlock(), createElementBlock("div",
|
|
168
|
+
])) : (openBlock(), createElementBlock("div", _hoisted_16, [
|
|
197
169
|
product.value.available > 0 ? (openBlock(), createBlock(_sfc_main$6, {
|
|
198
170
|
key: 0,
|
|
199
171
|
onClick: _cache[2] || (_cache[2] = ($event) => addToCart(product.value, null)),
|
|
200
172
|
class: "h-3r w-100 bg-main button"
|
|
201
173
|
}, {
|
|
202
174
|
default: withCtx(() => [
|
|
203
|
-
createElementVNode("div",
|
|
175
|
+
createElementVNode("div", _hoisted_17, [
|
|
204
176
|
createVNode(_sfc_main$4, { class: "i-semi" }),
|
|
205
177
|
createElementVNode("span", null, toDisplayString(unref(t)("addtoorder")), 1)
|
|
206
178
|
])
|
|
207
179
|
]),
|
|
208
180
|
_: 1
|
|
209
|
-
})) : (openBlock(), createElementBlock("div",
|
|
181
|
+
})) : (openBlock(), createElementBlock("div", _hoisted_18, " Out of Stock "))
|
|
210
182
|
]))
|
|
211
183
|
])
|
|
212
184
|
])
|
|
213
185
|
])
|
|
214
186
|
]),
|
|
215
|
-
createElementVNode("div",
|
|
187
|
+
createElementVNode("div", _hoisted_19, [
|
|
216
188
|
_cache[3] || (_cache[3] = createElementVNode("h3", { class: "pd-medium pd-b-small" }, "Most Popular", -1)),
|
|
217
189
|
createVNode(_sfc_main$7)
|
|
218
190
|
])
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Product.vue.js","sources":["../../../../../../../src/modules/products/components/pages/Product.vue"],"sourcesContent":["<template>\n <div v-if=\"products.state.current._id\" class=\"h-100 w-100 mobile:pd-thin pd-big bg-white\">\n <div class=\"cols-2-1_2 w-100 gap-medium\">\n <
|
|
1
|
+
{"version":3,"file":"Product.vue.js","sources":["../../../../../../../src/modules/products/components/pages/Product.vue"],"sourcesContent":["<template>\n <div v-if=\"products.state.current._id\" class=\"h-100 w-100 mobile:pd-thin pd-big bg-white\">\n <div class=\"cols-2-1_2 w-100 gap-medium\">\n\n <ImagesThumbnails\n :images=\"images\"\n :product=\"product\"\n />\n\n <div class=\"pos-relative w-100 h-100 flex-column flex-h-center flex\">\n <IconEdit\n v-if=\"accesses && hasAccess(route.params._id, 'products', 'edit', accesses)\"\n @click=\"$router.push({ name: 'ProductEdit', params: { _id: product.owner.target, product: product._id } })\"\n class=\"pos-absolute pos-t-regular pos-r-regular i-regular t-transp\"\n />\n <h2 class=\"w-100 h1-product mn-b-small\">{{ product.name }}</h2>\n <Price :product=\"product\" size=\"big\" class=\"flex gap-micro flex-center pd-small br-solid br-1px br-black-transp-10 w-max mn-b-medium\" />\n\n <div v-if=\"product.description || product.specification\" class=\"h-min-5r o-hidden radius-small bg-light mn-b-medium pos-relative\">\n <Tab\n v-model:selected=\"tabProduct\"\n :tabs=\"[\n {name: 'Description', value: 'description'},\n {name: 'Specifications', value: 'specifications'}\n ]\"\n tabClass=\"pd-thin bg-white radius-thin p-small uppercase t-medium\"\n class=\"gap-micro bg-light pos-relative z-index-2 pd-thin br-solid br-b br-black-transp-10\"\n />\n <transition name=\"slide-fade\">\n <div v-if=\"tabProduct === 'description'\" class=\"pd-medium\">\n <p v-if=\"product.description && !product.localization < 1 && !recommendation\" class=\"w-100 t-transp\">\n {{ product.description }}\n </p>\n <p v-if=\"product.localization && product.localization.length > 1 && !recommendation\" class=\"w-100 t-transp\">\n {{ t('description') }}\n </p>\n </div>\n <div v-else class=\"cols-2 pd-medium w-100 gap-small\">\n <div\n v-if=\"product.information.length > 0\"\n v-for=\"information in product.information\"\n class=\"w-100 pd-small radius-small bg-white product-information\"\n >\n <p class=\"t-demi\">{{ information.name }}</p>\n <p>{{ information.value }}</p>\n </div>\n </div>\n </transition>\n </div>\n\n <div class=\"w-max-33r\">\n <div class=\"w-max-33r\">\n\t\t <div v-if=\"product.listing === 'rent'\">\n\t\t <button @click=\"openPopup\" class=\"cursor-pointer pd-small radius-big w-max mobile:w-100 bg-main button\">\n\t\t <div class=\"gap-thin flex flex-center flex-nowrap\">\n\t\t <IconShopcartAdd class=\"i-semi\" />\n\t\t <span>{{ t('addtoorder') }}</span>\n\t\t </div>\n\t\t </button>\n\t\t <PopupDateSelector\n\t\t :product=\"product\"\n\t\t :isOpen=\"isPopupOpen\"\n\t\t :showFees=\"globals.state.options?.showFees\"\n :feesRate=\"globals.state.options?.feesRate || 0.15\"\n :showVat=\"globals.state.options?.showVat\"\n :vatRate=\"globals.state.options?.vatRate || 0\"\n\t\t :onConfirm=\"selectedDates => addToCart(product, selectedDates)\"\n\t\t @close=\"closePopup\"\n\t\t />\n\t\t </div>\n\t <div v-else>\n\t <Button\n\t v-if=\"product.available > 0\"\n\t @click=\"addToCart(product, null)\"\n\t class=\"h-3r w-100 bg-main button\"\n\t >\n\t <div class=\"gap-thin flex flex-center flex-nowrap\">\n\t <IconShopcartAdd class=\"i-semi\" />\n\t <span>{{ t('addtoorder') }}</span>\n\t </div>\n\t </Button>\n\t <div\n\t v-else\n\t class=\"flex-center flex uppercase radius-big t-black w-max pd-small t-medium bg-grey h-3r w-100 mn-r-smallbutton\"\n\t >\n\t Out of Stock\n\t </div>\n\t </div>\n\t </div>\n </div>\n </div>\n </div>\n\n <div class=\"h-max pos-relative\">\n <h3 class=\"pd-medium pd-b-small\">Most Popular</h3>\n <PopularProducts />\n </div>\n </div>\n</template>\n\n<script setup>\nimport { computed, ref, onMounted } from 'vue'\nimport { useRoute, useRouter } from 'vue-router'\nimport { useI18n } from 'vue-i18n'\nimport * as auth from '@martyrs/src/modules/auth/views/store/auth'\nimport * as globals from '@martyrs/src/modules/globals/views/store/globals'\nimport * as products from '@martyrs/src/modules/products/store/products'\nimport * as categories from '@martyrs/src/modules/products/store/categories'\nimport * as shopcart from '@martyrs/src/modules/orders/store/shopcart'\n\nimport Button from '@martyrs/src/components/Button/Button.vue'\nimport Popup from '@martyrs/src/components/Popup/Popup.vue'\nimport Tab from '@martyrs/src/components/Tab/Tab.vue'\nimport Calendar from '@martyrs/src/components/DatePicker/Calendar.vue'\nimport PopupDateSelector from '@martyrs/src/modules/globals/views/components/blocks/PopupDateSelector.vue'\nimport IconEdit from '@martyrs/src/modules/icons/navigation/IconEdit.vue'\nimport IconShopcartAdd from '@martyrs/src/modules/icons/actions/IconShopcartAdd.vue'\nimport PlaceholderImage from '@martyrs/src/modules/icons/placeholders/PlaceholderImage.vue'\nimport ImagesThumbnails from '@martyrs/src/modules/products/components/blocks/ImagesThumbnails.vue'\nimport Price from '@martyrs/src/modules/products/components/elements/Price.vue'\nimport PopularProducts from '@martyrs/src/modules/products/components/sections/PopularProducts.vue'\n\nconst route = useRoute()\nconst router = useRouter()\n\nconst product = computed(() => products.state.current)\nconst images = computed(() => products.state.current.images)\n\nconst tabProduct = ref('description')\n\nconst text = {\n en: { addtoorder: 'Add to Cart', fastorder: 'Fast Order' },\n ru: { addtoorder: 'Добавить в корзину', fastorder: 'Быстрый заказ' }\n}\n\nconst { t } = useI18n({ messages: text })\n\nconst isPopupOpen = ref(false)\n\nfunction openPopup() {\n isPopupOpen.value = true\n}\n\nfunction closePopup() {\n isPopupOpen.value = false\n}\n\n\n const emit = defineEmits(['page-loading', 'page-loaded']);\n \n\n// products.mutations.resetProduct()\nonMounted(async () => {\n emit('page-loading');\n await products.actions.read({ _id: route.params.product })\n emit('page-loaded');\n\n\n // route.meta.title.en = product.value.name\n // route.meta.title.ru = roduct.value.name\n\n})\n\n// onBeforeMounted\n\nfunction validateToCard(product) {\n return !(product.available > 0)\n}\n\nasync function addToCart(product, selectedDates = null) {\n try {\n if (shopcart.state.organization !== product.owner.target) {\n shopcart.state.organization = product.owner.target\n shopcart.state.positions = []\n }\n await shopcart.actions.addProductToCart(product, product.owner.target, selectedDates)\n return true\n } catch (error) {\n console.error('Ошибка при добавлении товара в корзину:', error)\n throw error\n }\n}\n</script>\n\n<style lang=\"scss\">\n</style>"],"names":["products.state","products.actions","product","shopcart.state","shopcart.actions"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0HA,UAAM,QAAQ,SAAQ;AACP,cAAS;AAExB,UAAM,UAAU,SAAS,MAAMA,MAAe,OAAO;AACrD,UAAM,SAAS,SAAS,MAAMA,MAAe,QAAQ,MAAM;AAE3D,UAAM,aAAa,IAAI,aAAa;AAEpC,UAAM,OAAO;AAAA,MACX,IAAI,EAAE,YAAY,eAAe,WAAW,aAAc;AAAA,MAC1D,IAAI,EAAE,YAAY,sBAAsB,WAAW,gBAAe;AAAA,IACpE;AAEA,UAAM,EAAE,EAAC,IAAK,QAAQ,EAAE,UAAU,KAAM,CAAA;AAExC,UAAM,cAAc,IAAI,KAAK;AAE7B,aAAS,YAAY;AACnB,kBAAY,QAAQ;AAAA,IACtB;AAEA,aAAS,aAAa;AACpB,kBAAY,QAAQ;AAAA,IACtB;AAGC,UAAM,OAAO;AAId,cAAU,YAAY;AACnB,WAAK,cAAc;AACpB,YAAMC,QAAiB,KAAK,EAAE,KAAK,MAAM,OAAO,QAAS,CAAA;AACzD,WAAK,aAAa;AAAA,IAMpB,CAAC;AAQD,mBAAe,UAAUC,UAAS,gBAAgB,MAAM;AACtD,UAAI;AACF,YAAIC,QAAe,iBAAiBD,SAAQ,MAAM,QAAQ;AACxDC,kBAAe,eAAeD,SAAQ,MAAM;AAC5CC,kBAAe,YAAY,CAAA;AAAA,QACjC;AACI,cAAMC,UAAiB,iBAAiBF,UAASA,SAAQ,MAAM,QAAQ,aAAa;AACpF,eAAO;AAAA,MACR,SAAQ,OAAO;AACd,gBAAQ,MAAM,2CAA2C,KAAK;AAC9D,cAAM;AAAA,MACV;AAAA,IACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/style.css
CHANGED
|
@@ -2159,39 +2159,55 @@ to {
|
|
|
2159
2159
|
width: 100%;
|
|
2160
2160
|
height: 100%;
|
|
2161
2161
|
object-fit: scale-down;
|
|
2162
|
-
transition: transform 0.
|
|
2162
|
+
transition: transform 0.05s;
|
|
2163
|
+
transform-origin: center center;
|
|
2163
2164
|
}
|
|
2164
2165
|
|
|
2165
|
-
.
|
|
2166
|
-
|
|
2166
|
+
.expand-enter-active[data-v-cd8791b7],
|
|
2167
|
+
.expand-leave-active[data-v-cd8791b7] {
|
|
2168
|
+
transition: max-height 0.5s ease-in-out;
|
|
2169
|
+
overflow: hidden;
|
|
2167
2170
|
}
|
|
2168
|
-
.
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
+
.scale-enter-active[data-v-cd8791b7],
|
|
2172
|
+
.scale-leave-active[data-v-cd8791b7] {
|
|
2173
|
+
transition: transform 0.5s ease-in-out;
|
|
2174
|
+
}
|
|
2175
|
+
.scale5-enter-from[data-v-cd8791b7],
|
|
2176
|
+
.scale5-leave-to[data-v-cd8791b7] {
|
|
2177
|
+
transform: scale(1.2);
|
|
2178
|
+
opacity: 0;
|
|
2171
2179
|
}
|
|
2172
|
-
.
|
|
2180
|
+
.scale5-enter-to[data-v-cd8791b7],
|
|
2181
|
+
.scale5-leave-from[data-v-cd8791b7] {
|
|
2182
|
+
transform: scale(1);
|
|
2183
|
+
opacity: 1;
|
|
2184
|
+
}
|
|
2185
|
+
.product-360-viewer[data-v-cd8791b7] {
|
|
2186
|
+
user-select: none;
|
|
2187
|
+
min-height: 16rem;
|
|
2188
|
+
}
|
|
2189
|
+
.product-360-viewer img[data-v-cd8791b7] {
|
|
2190
|
+
max-width: 100%;
|
|
2191
|
+
cursor: grab;
|
|
2192
|
+
|
|
2193
|
+
object-fit: cover;
|
|
2194
|
+
transition: all 0.3s ease;
|
|
2195
|
+
}
|
|
2196
|
+
.product-360-viewer img[data-v-cd8791b7]:active {
|
|
2197
|
+
cursor: grabbing;
|
|
2198
|
+
}
|
|
2199
|
+
|
|
2200
|
+
/*.product-360-viewer img:hover {
|
|
2201
|
+
transform: scale(1.1);
|
|
2202
|
+
}*/
|
|
2203
|
+
|
|
2204
|
+
.thumbnail[data-v-832a66d9] {
|
|
2173
2205
|
width: 100%;
|
|
2174
2206
|
max-width: 6rem;
|
|
2175
2207
|
height: 6rem;
|
|
2176
2208
|
object-fit: cover;
|
|
2177
2209
|
cursor: pointer;
|
|
2178
2210
|
}
|
|
2179
|
-
.popup[data-v-77776640] {
|
|
2180
|
-
position: fixed;
|
|
2181
|
-
top: 0;
|
|
2182
|
-
left: 0;
|
|
2183
|
-
width: 100vw;
|
|
2184
|
-
height: 100vh;
|
|
2185
|
-
background-color: rgba(0, 0, 0, 0.8);
|
|
2186
|
-
display: flex;
|
|
2187
|
-
justify-content: center;
|
|
2188
|
-
align-items: center;
|
|
2189
|
-
cursor: zoom-out;
|
|
2190
|
-
}
|
|
2191
|
-
.popup-image[data-v-77776640] {
|
|
2192
|
-
max-width: 90%;
|
|
2193
|
-
max-height: 90%;
|
|
2194
|
-
}
|
|
2195
2211
|
.vue-select {
|
|
2196
2212
|
background: #f7f7f7;
|
|
2197
2213
|
border-radius: 0.5rem;
|
|
@@ -2227,44 +2243,6 @@ to {
|
|
|
2227
2243
|
.spoiler-active[data-v-e326492a] {
|
|
2228
2244
|
transform: rotate(180deg);
|
|
2229
2245
|
}
|
|
2230
|
-
.expand-enter-active[data-v-cd8791b7],
|
|
2231
|
-
.expand-leave-active[data-v-cd8791b7] {
|
|
2232
|
-
transition: max-height 0.5s ease-in-out;
|
|
2233
|
-
overflow: hidden;
|
|
2234
|
-
}
|
|
2235
|
-
.scale-enter-active[data-v-cd8791b7],
|
|
2236
|
-
.scale-leave-active[data-v-cd8791b7] {
|
|
2237
|
-
transition: transform 0.5s ease-in-out;
|
|
2238
|
-
}
|
|
2239
|
-
.scale5-enter-from[data-v-cd8791b7],
|
|
2240
|
-
.scale5-leave-to[data-v-cd8791b7] {
|
|
2241
|
-
transform: scale(1.2);
|
|
2242
|
-
opacity: 0;
|
|
2243
|
-
}
|
|
2244
|
-
.scale5-enter-to[data-v-cd8791b7],
|
|
2245
|
-
.scale5-leave-from[data-v-cd8791b7] {
|
|
2246
|
-
transform: scale(1);
|
|
2247
|
-
opacity: 1;
|
|
2248
|
-
}
|
|
2249
|
-
.product-360-viewer[data-v-cd8791b7] {
|
|
2250
|
-
user-select: none;
|
|
2251
|
-
min-height: 16rem;
|
|
2252
|
-
}
|
|
2253
|
-
.product-360-viewer img[data-v-cd8791b7] {
|
|
2254
|
-
max-width: 100%;
|
|
2255
|
-
cursor: grab;
|
|
2256
|
-
|
|
2257
|
-
object-fit: cover;
|
|
2258
|
-
transition: all 0.3s ease;
|
|
2259
|
-
}
|
|
2260
|
-
.product-360-viewer img[data-v-cd8791b7]:active {
|
|
2261
|
-
cursor: grabbing;
|
|
2262
|
-
}
|
|
2263
|
-
|
|
2264
|
-
/*.product-360-viewer img:hover {
|
|
2265
|
-
transform: scale(1.1);
|
|
2266
|
-
}*/
|
|
2267
|
-
|
|
2268
2246
|
#glcanvas {
|
|
2269
2247
|
width: 100%;
|
|
2270
2248
|
height: 100%;
|
package/package.json
CHANGED
|
@@ -54,7 +54,9 @@ module.exports = function createSpaDevServer(projectRoot, { spaConfig, serverCon
|
|
|
54
54
|
Object.keys(require.cache).forEach((id) => {
|
|
55
55
|
delete require.cache[id];
|
|
56
56
|
});
|
|
57
|
-
|
|
57
|
+
|
|
58
|
+
const { createServer } = createServerPath;
|
|
59
|
+
|
|
58
60
|
let { app, server, env } = await createServer();
|
|
59
61
|
|
|
60
62
|
// Используем connect-history-api-fallback перед другими middleware
|
|
@@ -10,7 +10,7 @@ module.exports = function createSpaProdServer(projectRoot, { createServerPath })
|
|
|
10
10
|
|
|
11
11
|
// Функция для запуска сервера
|
|
12
12
|
const startServer = async () => {
|
|
13
|
-
const { createServer } =
|
|
13
|
+
const { createServer } = createServerPath;
|
|
14
14
|
|
|
15
15
|
let { app, server } = await createServer();
|
|
16
16
|
|
|
@@ -12,7 +12,7 @@ const { transformDevStats } = require("../ssr/ssr-transform-webpack-stats.js");
|
|
|
12
12
|
|
|
13
13
|
module.exports = function createSsrDevServer(projectRoot, { clientConfig, serverConfig, ssrConfig, createServerPath }) {
|
|
14
14
|
const clientCompiler = webpack(clientConfig);
|
|
15
|
-
const serverCompiler = webpack(serverConfig);
|
|
15
|
+
// const serverCompiler = webpack(serverConfig);
|
|
16
16
|
const ssrCompiler = webpack(ssrConfig);
|
|
17
17
|
|
|
18
18
|
const createDevRenderer = (onUpdate) => {
|
|
@@ -174,15 +174,15 @@ module.exports = function createSsrDevServer(projectRoot, { clientConfig, server
|
|
|
174
174
|
};
|
|
175
175
|
|
|
176
176
|
// Настройка наблюдения за изменениями
|
|
177
|
-
serverCompiler.watch({}, async (err, stats) => {
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
});
|
|
177
|
+
// serverCompiler.watch({}, async (err, stats) => {
|
|
178
|
+
// if (err) {
|
|
179
|
+
// console.error(err);
|
|
180
|
+
// return;
|
|
181
|
+
// }
|
|
182
|
+
// console.log(stats.toString(serverConfig.stats));
|
|
183
|
+
// console.log('Server.js has changed, updating...');
|
|
184
|
+
// await startServer();
|
|
185
|
+
// });
|
|
186
186
|
|
|
187
187
|
return startServer;
|
|
188
188
|
};
|