@useinsider/guido 1.4.4 → 2.0.0-beta.143201d
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/README.md +295 -664
- package/dist/@types/config/defaults.js +44 -0
- package/dist/@types/config/schemas.js +231 -0
- package/dist/@types/config/validator.js +56 -0
- package/dist/components/Guido.vue.js +1 -1
- package/dist/components/Guido.vue2.js +64 -86
- package/dist/components/organisms/email-preview/desktop-preview/EmailHeaderInfo.vue2.js +13 -13
- package/dist/components/organisms/email-preview/mobile-preview/InboxView.vue.js +5 -5
- package/dist/components/organisms/email-preview/mobile-preview/InboxView.vue2.js +13 -13
- package/dist/components/organisms/header/LeftSlot.vue.js +1 -1
- package/dist/components/organisms/header/LeftSlot.vue2.js +18 -15
- package/dist/components/organisms/header/RightSlot.vue.js +10 -10
- package/dist/components/organisms/onboarding/NewVersionPopup.vue2.js +22 -19
- package/dist/components/organisms/unsubscribe/UnsubscribeBreadcrumb.vue.js +4 -4
- package/dist/components/organisms/unsubscribe/UnsubscribeBreadcrumb.vue2.js +8 -8
- package/dist/components/organisms/unsubscribe/UnsubscribeTypeSelection.vue.js +3 -3
- package/dist/components/organisms/unsubscribe/UnsubscribeTypeSelection.vue2.js +17 -17
- package/dist/components/organisms/unsubscribe/UnsubscribeWrapper.vue.js +10 -10
- package/dist/composables/useActionsApi.js +42 -25
- package/dist/composables/useBlocksConfig.js +23 -20
- package/dist/composables/useConfig.js +51 -5
- package/dist/composables/useHtmlCompiler.js +20 -19
- package/dist/composables/useHtmlValidator.js +41 -41
- package/dist/composables/usePartner.js +19 -9
- package/dist/composables/useStripo.js +51 -50
- package/dist/composables/useTimerClone.js +53 -0
- package/dist/composables/useTranslations.js +3 -2
- package/dist/config/compiler/unsubscribeCompilerRules.js +1 -1
- package/dist/enums/defaults.js +4 -67
- package/dist/enums/unsubscribe.js +23 -20
- package/dist/extensions/Blocks/Recommendation/store/recommendation.js +12 -11
- package/dist/guido.css +1 -1
- package/dist/library.js +12 -2
- package/dist/node_modules/lodash-es/_arrayLikeKeys.js +10 -10
- package/dist/node_modules/valibot/dist/index.js +476 -103
- package/dist/services/stripoApi.js +13 -14
- package/dist/services/templateLibraryApi.js +18 -18
- package/dist/src/@types/config/defaults.d.ts +68 -0
- package/dist/src/@types/config/index.d.ts +14 -0
- package/dist/src/@types/config/schemas.d.ts +509 -0
- package/dist/src/@types/config/types.d.ts +142 -0
- package/dist/src/@types/config/validator.d.ts +119 -0
- package/dist/src/@types/generic.d.ts +4 -45
- package/dist/src/components/Guido.vue.d.ts +13 -12
- package/dist/src/components/wrappers/WpModal.vue.d.ts +1 -1
- package/dist/src/composables/useActionsApi.d.ts +2 -0
- package/dist/src/composables/useConfig.d.ts +186 -2
- package/dist/src/composables/usePartner.d.ts +8 -0
- package/dist/src/composables/useTimerClone.d.ts +6 -0
- package/dist/src/enums/defaults.d.ts +5 -6
- package/dist/src/enums/unsubscribe.d.ts +5 -1
- package/dist/src/library.d.ts +3 -1
- package/dist/src/stores/config.d.ts +1564 -102
- package/dist/static/styles/components/narrow-panel.css.js +0 -10
- package/dist/stores/config.js +141 -9
- package/package.json +1 -1
- package/dist/node_modules/lodash-es/_apply.js +0 -16
- package/dist/node_modules/lodash-es/_assignMergeValue.js +0 -8
- package/dist/node_modules/lodash-es/_assignValue.js +0 -10
- package/dist/node_modules/lodash-es/_baseAssignValue.js +0 -12
- package/dist/node_modules/lodash-es/_baseCreate.js +0 -17
- package/dist/node_modules/lodash-es/_baseKeysIn.js +0 -15
- package/dist/node_modules/lodash-es/_baseMerge.js +0 -20
- package/dist/node_modules/lodash-es/_baseMergeDeep.js +0 -31
- package/dist/node_modules/lodash-es/_baseRest.js +0 -9
- package/dist/node_modules/lodash-es/_baseSetToString.js +0 -14
- package/dist/node_modules/lodash-es/_cloneArrayBuffer.js +0 -8
- package/dist/node_modules/lodash-es/_cloneBuffer.js +0 -9
- package/dist/node_modules/lodash-es/_cloneTypedArray.js +0 -8
- package/dist/node_modules/lodash-es/_copyArray.js +0 -9
- package/dist/node_modules/lodash-es/_copyObject.js +0 -14
- package/dist/node_modules/lodash-es/_createAssigner.js +0 -15
- package/dist/node_modules/lodash-es/_defineProperty.js +0 -11
- package/dist/node_modules/lodash-es/_getPrototype.js +0 -5
- package/dist/node_modules/lodash-es/_initCloneObject.js +0 -9
- package/dist/node_modules/lodash-es/_nativeKeysIn.js +0 -10
- package/dist/node_modules/lodash-es/_overRest.js +0 -15
- package/dist/node_modules/lodash-es/_safeGet.js +0 -7
- package/dist/node_modules/lodash-es/_setToString.js +0 -6
- package/dist/node_modules/lodash-es/_shortOut.js +0 -16
- package/dist/node_modules/lodash-es/constant.js +0 -8
- package/dist/node_modules/lodash-es/isArrayLikeObject.js +0 -8
- package/dist/node_modules/lodash-es/isPlainObject.js +0 -16
- package/dist/node_modules/lodash-es/keysIn.js +0 -9
- package/dist/node_modules/lodash-es/merge.js +0 -8
- package/dist/node_modules/lodash-es/toPlainObject.js +0 -8
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { RecommendationFeedSourceMaps as
|
|
2
|
-
import { useRecommendationApi as
|
|
1
|
+
import { RecommendationFeedSourceMaps as n, PriceAttributes as u } from "../../../../enums/extensions/recommendationBlock.js";
|
|
2
|
+
import { useRecommendationApi as l } from "../../../../services/recommendationApi.js";
|
|
3
|
+
import { useConfigStore as c } from "../../../../stores/config.js";
|
|
3
4
|
import { defineStore as p } from "pinia";
|
|
4
5
|
import { generateCompleteFilterQuery as m } from "../utils/filterUtil.js";
|
|
5
|
-
const a =
|
|
6
|
+
const a = l(), d = () => ({
|
|
6
7
|
recommendationCampaignUrls: {},
|
|
7
8
|
recommendationProducts: [],
|
|
8
9
|
recommendationConfigs: {
|
|
@@ -133,7 +134,7 @@ const a = c(), d = () => ({
|
|
|
133
134
|
filterSelectionDrawerStatus: !1,
|
|
134
135
|
filterList: {},
|
|
135
136
|
filterGroup: 1
|
|
136
|
-
}),
|
|
137
|
+
}), y = p("guidoRecommendationExtension", {
|
|
137
138
|
state: () => d(),
|
|
138
139
|
getters: {
|
|
139
140
|
hasFilters: (e) => !!e.recommendationConfigs.filters.length,
|
|
@@ -144,7 +145,7 @@ const a = c(), d = () => ({
|
|
|
144
145
|
getActivePredictiveAlgorithms: (e) => {
|
|
145
146
|
const t = [];
|
|
146
147
|
return e.activePredictiveAlgorithms.forEach((r) => {
|
|
147
|
-
t.push(...
|
|
148
|
+
t.push(...n.filter((i) => i.id === r));
|
|
148
149
|
}), t.map((r) => ({
|
|
149
150
|
text: r.name,
|
|
150
151
|
value: r.key
|
|
@@ -159,7 +160,7 @@ const a = c(), d = () => ({
|
|
|
159
160
|
value: t.text
|
|
160
161
|
})),
|
|
161
162
|
getFilterList: (e) => Object.values(e.filterList).map((t) => {
|
|
162
|
-
const r = t.type === "defaultAttribute", i =
|
|
163
|
+
const r = t.type === "defaultAttribute", i = u.includes(t.attributeName);
|
|
163
164
|
let o = r ? t.attributeName : `product_attributes.${t.attributeName}`;
|
|
164
165
|
return o = i ? `${o}.${e.recommendationConfigs.currencySettings.value}` : o, {
|
|
165
166
|
text: t.displayName,
|
|
@@ -240,14 +241,14 @@ const a = c(), d = () => ({
|
|
|
240
241
|
return m(this.recommendationConfigs.filters);
|
|
241
242
|
},
|
|
242
243
|
async fetchRecommendationProducts() {
|
|
243
|
-
var
|
|
244
|
-
const e = this.generateFilterQuery(), t = ((
|
|
244
|
+
var o;
|
|
245
|
+
const e = this.generateFilterQuery(), t = ((o = n.find((s) => s.key === this.recommendationConfigs.strategy)) == null ? void 0 : o.path) || "", r = c(), i = await a.fetchRecommendationProducts(
|
|
245
246
|
t,
|
|
246
247
|
{
|
|
247
248
|
// TODO: Here will be optimized and filled carefully
|
|
248
249
|
locale: this.recommendationConfigs.language,
|
|
249
250
|
currency: this.recommendationConfigs.currencySettings.value,
|
|
250
|
-
partnerName:
|
|
251
|
+
partnerName: r.partnerName,
|
|
251
252
|
productId: this.recommendationConfigs.strategy === "manualMerchandising" ? this.recommendationConfigs.productIds.join(",") : "{itemId}",
|
|
252
253
|
size: this.recommendationConfigs.size,
|
|
253
254
|
details: !0,
|
|
@@ -256,11 +257,11 @@ const a = c(), d = () => ({
|
|
|
256
257
|
}
|
|
257
258
|
);
|
|
258
259
|
this.$patch({
|
|
259
|
-
recommendationProducts:
|
|
260
|
+
recommendationProducts: i
|
|
260
261
|
});
|
|
261
262
|
}
|
|
262
263
|
}
|
|
263
264
|
});
|
|
264
265
|
export {
|
|
265
|
-
|
|
266
|
+
y as useRecommendationExtensionStore
|
|
266
267
|
};
|
package/dist/guido.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.gap-16[data-v-6562e38c],.gap-16[data-v-1ccb6d4a]{gap:16px}[data-v-
|
|
1
|
+
.gap-16[data-v-6562e38c],.gap-16[data-v-1ccb6d4a]{gap:16px}[data-v-06e6f7a7] .in-button-v2__wrapper{line-height:0}[data-v-b5997368] .in-segments-wrapper .in-tooltip-wrapper__box{text-align:left}.version-history-item[data-v-ee4b9c3f]{flex-basis:200px}.version-history-wrapper[data-v-52a77eec]{gap:8px}.view-options-wrapper[data-v-d405ca59]{position:relative;display:inline-block}.new-tag[data-v-d405ca59]{position:absolute;top:-8px;right:-16px;z-index:10}[data-v-d405ca59] .guido__verion-history-view-option-selection-desktop svg,[data-v-d405ca59] .guido__verion-history-view-option-selection-mobile svg{margin:0 0 0 2px}[data-v-d405ca59] .in-segments-wrapper__button_selected,[data-v-d405ca59] .in-segments-wrapper__button_selected:hover{background-color:#dae1fb}[data-v-d405ca59] .in-tooltip-wrapper__icon{cursor:pointer}.view-options-wrapper[data-v-195ab6d4]{position:relative;display:inline-block}.new-tag[data-v-195ab6d4]{position:absolute;top:-8px;right:-16px;z-index:10}[data-v-195ab6d4] .guido__view-option-selection-desktop svg,[data-v-195ab6d4] .guido__view-option-selection-mobile svg{margin:0 0 0 2px}[data-v-195ab6d4] .in-segments-wrapper__button_selected,[data-v-195ab6d4] .in-segments-wrapper__button_selected:hover{background-color:#dae1fb}[data-v-195ab6d4] .in-tooltip-wrapper__icon{cursor:pointer}.guido-loading__wrapper[data-v-07c4b2d8]{height:100%;top:75px!important;bottom:0!important}.guido-editor__wrapper[data-v-282ca4d1]{position:relative;width:100%;height:calc(100vh - 128px)}.guido-editor__container[data-v-282ca4d1]{width:100%;height:calc(100vh - 128px)}.guido-editor__no-header[data-v-282ca4d1]{height:calc(100vh - 75px)}[data-v-293f1c47] .in-breadcrumb-wrapper__links{cursor:pointer}.templates-wrapper[data-v-a86fc486]{gap:16px;grid-template-columns:repeat(3,1fr)}.templates-wrapper .template-wrapper[data-v-a86fc486]{cursor:pointer}.templates-wrapper .template-wrapper .template-container[data-v-a86fc486]{height:274px;padding:2px;transition:none}.templates-wrapper .template-wrapper .template-container.selected[data-v-a86fc486]{padding:1px}.templates-wrapper .template-wrapper .template-container .thumbnail[data-v-a86fc486]{object-fit:cover;transform:scale(1)}[data-v-bb3bb07c] .guido__verion-history-view-option-selection-desktop svg,[data-v-bb3bb07c] .guido__verion-history-view-option-selection-mobile svg{margin:0 0 0 2px}[data-v-bb3bb07c] .in-segments-wrapper__button_selected,[data-v-bb3bb07c] .in-segments-wrapper__button_selected:hover{background-color:#dae1fb}.error-list[data-v-7a09985c]{gap:16px}[data-v-c2adc57d] .in-progress-wrapper__progress p span:last-child{display:none!important}.desktop-preview-container[data-v-2dd60b0c],[data-v-2dd60b0c] .desktop-preview-container .in-container{min-height:720px!important;height:100%}.cropped-text[data-v-4b876c1b]{width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}[data-v-d3c52b44] .vueperslides__bullets,[data-v-dd1a237a] .vueperslides__bullets{pointer-events:none!important}[data-v-dd1a237a] .vueperslides__parallax-wrapper{height:110px!important}[data-v-a408dcea] .vueperslides__bullets{pointer-events:none!important}[data-v-a408dcea] .vueperslides__parallax-wrapper{height:110px!important}
|
package/dist/library.js
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
import { default as
|
|
1
|
+
import { default as a } from "./components/Guido.vue.js";
|
|
2
|
+
import { MessageType as f, ProductType as t } from "./@types/config/schemas.js";
|
|
3
|
+
import "./@types/config/defaults.js";
|
|
4
|
+
import { getValidationErrors as s, isValidConfig as d, parseConfig as g, parseConfigSafe as n, validateConfig as l } from "./@types/config/validator.js";
|
|
2
5
|
export {
|
|
3
|
-
|
|
6
|
+
a as Guido,
|
|
7
|
+
f as MessageType,
|
|
8
|
+
t as ProductType,
|
|
9
|
+
s as getValidationErrors,
|
|
10
|
+
d as isValidConfig,
|
|
11
|
+
g as parseConfig,
|
|
12
|
+
n as parseConfigSafe,
|
|
13
|
+
l as validateConfig
|
|
4
14
|
};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import m from "./_baseTimes.js";
|
|
2
|
+
import a from "./isArguments.js";
|
|
3
3
|
import h from "./isArray.js";
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
var
|
|
8
|
-
function l(t,
|
|
9
|
-
var
|
|
4
|
+
import g from "./isBuffer.js";
|
|
5
|
+
import b from "./_isIndex.js";
|
|
6
|
+
import d from "./isTypedArray.js";
|
|
7
|
+
var A = Object.prototype, c = A.hasOwnProperty;
|
|
8
|
+
function l(t, O) {
|
|
9
|
+
var i = h(t), o = !i && a(t), s = !i && !o && g(t), e = !i && !o && !s && d(t), n = i || o || s || e, f = n ? m(t.length, String) : [], p = f.length;
|
|
10
10
|
for (var r in t)
|
|
11
|
-
|
|
11
|
+
c.call(t, r) && !(n && // Safari 9 has enumerable `arguments.length` in strict mode.
|
|
12
12
|
(r == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
|
13
13
|
s && (r == "offset" || r == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
|
|
14
14
|
e && (r == "buffer" || r == "byteLength" || r == "byteOffset") || // Skip index properties.
|
|
15
|
-
|
|
15
|
+
b(r, p))) && f.push(r);
|
|
16
16
|
return f;
|
|
17
17
|
}
|
|
18
18
|
export {
|