@getlupa/vue 0.10.2 → 0.10.3
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/lupaSearch.js +12 -2
- package/dist/lupaSearch.mjs +12 -2
- package/package.json +1 -1
package/dist/lupaSearch.js
CHANGED
|
@@ -4553,6 +4553,8 @@ const _sfc_main$_ = /* @__PURE__ */ vue.defineComponent(__spreadProps(__spreadVa
|
|
|
4553
4553
|
},
|
|
4554
4554
|
setup(__props) {
|
|
4555
4555
|
const props = __props;
|
|
4556
|
+
const dynamicDataStore = useDynamicDataStore();
|
|
4557
|
+
const { dynamicDataIdMap } = storeToRefs(dynamicDataStore);
|
|
4556
4558
|
const positionValue = vue.computed(() => {
|
|
4557
4559
|
var _a;
|
|
4558
4560
|
return (_a = props.position) != null ? _a : "card";
|
|
@@ -4560,6 +4562,14 @@ const _sfc_main$_ = /* @__PURE__ */ vue.defineComponent(__spreadProps(__spreadVa
|
|
|
4560
4562
|
const anchorPosition = vue.computed(() => {
|
|
4561
4563
|
return props.options.anchor;
|
|
4562
4564
|
});
|
|
4565
|
+
const enhancedProduct = vue.computed(() => {
|
|
4566
|
+
var _a, _b, _c, _d;
|
|
4567
|
+
if (!((_a = props.options.product) == null ? void 0 : _a.id)) {
|
|
4568
|
+
return props.options.product;
|
|
4569
|
+
}
|
|
4570
|
+
const enhancementData = (_d = (_c = dynamicDataIdMap.value) == null ? void 0 : _c[(_b = props.options.product) == null ? void 0 : _b.id]) != null ? _d : {};
|
|
4571
|
+
return __spreadValues(__spreadValues({}, props.options.product), enhancementData);
|
|
4572
|
+
});
|
|
4563
4573
|
const badges = vue.computed(() => {
|
|
4564
4574
|
if (!props.options.elements) {
|
|
4565
4575
|
return [];
|
|
@@ -4570,8 +4580,8 @@ const _sfc_main$_ = /* @__PURE__ */ vue.defineComponent(__spreadProps(__spreadVa
|
|
|
4570
4580
|
}).map((x) => {
|
|
4571
4581
|
var _a;
|
|
4572
4582
|
return __spreadProps(__spreadValues({}, x), {
|
|
4573
|
-
value: ((_a =
|
|
4574
|
-
product:
|
|
4583
|
+
value: ((_a = enhancedProduct.value) == null ? void 0 : _a[x.key]) || "badge",
|
|
4584
|
+
product: enhancedProduct.value
|
|
4575
4585
|
});
|
|
4576
4586
|
});
|
|
4577
4587
|
});
|
package/dist/lupaSearch.mjs
CHANGED
|
@@ -4551,6 +4551,8 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues
|
|
|
4551
4551
|
},
|
|
4552
4552
|
setup(__props) {
|
|
4553
4553
|
const props = __props;
|
|
4554
|
+
const dynamicDataStore = useDynamicDataStore();
|
|
4555
|
+
const { dynamicDataIdMap } = storeToRefs(dynamicDataStore);
|
|
4554
4556
|
const positionValue = computed(() => {
|
|
4555
4557
|
var _a;
|
|
4556
4558
|
return (_a = props.position) != null ? _a : "card";
|
|
@@ -4558,6 +4560,14 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues
|
|
|
4558
4560
|
const anchorPosition = computed(() => {
|
|
4559
4561
|
return props.options.anchor;
|
|
4560
4562
|
});
|
|
4563
|
+
const enhancedProduct = computed(() => {
|
|
4564
|
+
var _a, _b, _c, _d;
|
|
4565
|
+
if (!((_a = props.options.product) == null ? void 0 : _a.id)) {
|
|
4566
|
+
return props.options.product;
|
|
4567
|
+
}
|
|
4568
|
+
const enhancementData = (_d = (_c = dynamicDataIdMap.value) == null ? void 0 : _c[(_b = props.options.product) == null ? void 0 : _b.id]) != null ? _d : {};
|
|
4569
|
+
return __spreadValues(__spreadValues({}, props.options.product), enhancementData);
|
|
4570
|
+
});
|
|
4561
4571
|
const badges = computed(() => {
|
|
4562
4572
|
if (!props.options.elements) {
|
|
4563
4573
|
return [];
|
|
@@ -4568,8 +4578,8 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues
|
|
|
4568
4578
|
}).map((x) => {
|
|
4569
4579
|
var _a;
|
|
4570
4580
|
return __spreadProps(__spreadValues({}, x), {
|
|
4571
|
-
value: ((_a =
|
|
4572
|
-
product:
|
|
4581
|
+
value: ((_a = enhancedProduct.value) == null ? void 0 : _a[x.key]) || "badge",
|
|
4582
|
+
product: enhancedProduct.value
|
|
4573
4583
|
});
|
|
4574
4584
|
});
|
|
4575
4585
|
});
|