@useinsider/guido 3.20.0 → 3.20.1-beta.07e0277
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 +1 -0
- package/dist/@types/config/schemas.js +11 -10
- package/dist/components/Guido.vue.js +4 -4
- package/dist/components/Guido.vue2.js +114 -103
- package/dist/components/organisms/AutoSaveController.vue2.js +19 -9
- package/dist/components/organisms/header/AutoSaveStatus.vue.js +17 -0
- package/dist/components/organisms/header/AutoSaveStatus.vue2.js +25 -0
- package/dist/components/organisms/header/EditorActions.vue.js +13 -13
- package/dist/components/organisms/header/EditorActions.vue2.js +57 -72
- package/dist/components/organisms/header/EditorActionsMenu.vue.js +20 -0
- package/dist/components/organisms/header/EditorActionsMenu.vue2.js +98 -0
- package/dist/components/organisms/header/HeaderWrapper.vue.js +6 -6
- package/dist/components/organisms/header/HeaderWrapper.vue2.js +9 -17
- package/dist/components/organisms/header/LeftSlot.vue.js +1 -1
- package/dist/components/organisms/header/LeftSlot.vue2.js +28 -23
- package/dist/components/organisms/header/MiddleSlot.vue.js +4 -4
- package/dist/components/organisms/header/MiddleSlot.vue2.js +8 -7
- package/dist/components/organisms/header/RightSlot.vue.js +11 -10
- package/dist/components/organisms/header/RightSlot.vue2.js +13 -18
- package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue.js +18 -0
- package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue2.js +37 -0
- package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue.js +22 -0
- package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue2.js +48 -0
- package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue.js +19 -0
- package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue2.js +90 -0
- package/dist/components/organisms/onboarding/OnboardingWrapper.vue.js +12 -12
- package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +60 -35
- package/dist/composables/useAccessibilityApi.js +51 -0
- package/dist/composables/useCustomInterfaceAppearance.js +42 -41
- package/dist/composables/useLegacyStrategyConversion.js +16 -16
- package/dist/composables/useStripo.js +4 -3
- package/dist/config/compiler/itemsCompilerRules.js +21 -5
- package/dist/config/compiler/utils/itemsCompilerUtils.js +64 -17
- package/dist/config/i18n/en/labels.json.js +36 -4
- package/dist/config/i18n/en/tooltips.json.js +2 -1
- package/dist/config/migrator/itemsBlockMigrator.js +112 -108
- package/dist/extensions/Blocks/Items/block.js +76 -64
- package/dist/extensions/Blocks/Items/constants/cardWidth.js +20 -0
- package/dist/extensions/Blocks/Items/layouts/vertical.html.js +1 -1
- package/dist/extensions/Blocks/Recommendation/block.js +51 -44
- package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +103 -91
- package/dist/extensions/Blocks/Recommendation/controls/main/index.js +308 -218
- package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +209 -203
- package/dist/extensions/Blocks/Recommendation/store/recommendation.js +232 -186
- package/dist/extensions/Blocks/Recommendation/utils/blockRefresh.js +19 -0
- package/dist/extensions/Blocks/Recommendation/utils/blockUrlConfig.js +25 -0
- package/dist/extensions/Blocks/Recommendation/utils/captureStyleTemplates.js +72 -70
- package/dist/extensions/Blocks/Recommendation/utils/compositionKeys.js +69 -60
- package/dist/extensions/Blocks/Recommendation/utils/nodeConfigWriter.js +63 -27
- package/dist/extensions/Blocks/Recommendation/utils/strategyCommit.js +39 -20
- package/dist/guido.css +1 -1
- package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +271 -192
- package/dist/package.json.js +1 -1
- package/dist/sprite.svg +10 -0
- package/dist/src/@types/config/schemas.d.ts +2 -0
- package/dist/src/components/organisms/AutoSaveController.vue.d.ts +19 -1
- package/dist/src/components/organisms/header/EditorActionsMenu.vue.d.ts +2 -0
- package/dist/src/components/organisms/header/HeaderWrapper.vue.d.ts +1 -19
- package/dist/src/components/organisms/header/RightSlot.vue.d.ts +1 -19
- package/dist/src/components/organisms/header/accessibility/AccessibilityToolbar.vue.d.ts +2 -0
- package/dist/src/components/organisms/header/accessibility/ColorVisionSelect.vue.d.ts +2 -0
- package/dist/src/components/organisms/onboarding/EditorTabBarOnboarding.vue.d.ts +2 -0
- package/dist/src/composables/useAccessibilityApi.d.ts +13 -0
- package/dist/src/composables/useActionsApi.d.ts +2 -2
- package/dist/src/composables/useConfig.d.ts +2 -0
- package/dist/src/config/compiler/utils/itemsCompilerUtils.d.ts +10 -0
- package/dist/src/extensions/Blocks/Checkbox/controls/blockBackground/index.d.ts +1 -0
- package/dist/src/extensions/Blocks/CouponBlock/controls/index.d.ts +8 -0
- package/dist/src/extensions/Blocks/Items/block.d.ts +5 -0
- package/dist/src/extensions/Blocks/Items/constants/cardWidth.d.ts +12 -0
- package/dist/src/extensions/Blocks/Items/controls/index.d.ts +40 -0
- package/dist/src/extensions/Blocks/RadioButton/controls/blockBackground/index.d.ts +1 -0
- package/dist/src/extensions/Blocks/Recommendation/block.d.ts +2 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/blockBackground/index.d.ts +1 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/button/index.d.ts +11 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/cardComposition/index.d.ts +3 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/customAttribute/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/image/index.d.ts +2 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/main/index.d.ts +20 -3
- package/dist/src/extensions/Blocks/Recommendation/controls/name/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/oldPrice/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/omnibusDiscount/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/omnibusPrice/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/price/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/title/index.d.ts +7 -0
- package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +26 -6
- package/dist/src/extensions/Blocks/Recommendation/utils/blockRefresh.d.ts +17 -0
- package/dist/src/extensions/Blocks/Recommendation/utils/blockUrlConfig.d.ts +4 -0
- package/dist/src/extensions/Blocks/Recommendation/utils/compositionKeys.d.ts +4 -0
- package/dist/src/extensions/Blocks/Recommendation/utils/nodeConfigWriter.d.ts +10 -1
- package/dist/src/extensions/Blocks/Recommendation/utils/strategyCommit.d.ts +7 -0
- package/dist/src/extensions/Blocks/_Boilerplate/controls/blockBackground/index.d.ts +1 -0
- package/dist/src/extensions/Blocks/controlFactories.d.ts +22 -0
- package/dist/src/stores/autosave.d.ts +73 -1
- package/dist/src/stores/config.d.ts +20 -0
- package/dist/src/stores/editor.d.ts +109 -0
- package/dist/src/stores/onboarding.d.ts +966 -35
- package/dist/src/stores/version-history.d.ts +1 -1
- package/dist/src/utils/liquidProtection.d.ts +3 -0
- package/dist/src/utils/timeUtil.d.ts +5 -8
- package/dist/static/styles/components/accessibility.css.js +234 -0
- package/dist/static/styles/components/button.css.js +5 -0
- package/dist/static/styles/variables.css.js +2 -0
- package/dist/stores/autosave.js +12 -7
- package/dist/stores/editor.js +8 -3
- package/dist/stores/onboarding.js +48 -22
- package/dist/utils/liquidProtection.js +5 -0
- package/dist/utils/templatePreparation.js +61 -85
- package/dist/utils/timeUtil.js +6 -17
- package/package.json +3 -3
- package/dist/components/organisms/header/AutoSaveToggle.vue.js +0 -22
- package/dist/components/organisms/header/AutoSaveToggle.vue2.js +0 -19
- /package/dist/src/components/organisms/header/{AutoSaveToggle.vue.d.ts → AutoSaveStatus.vue.d.ts} +0 -0
|
@@ -1,123 +1,99 @@
|
|
|
1
|
-
import { useActionsApi as
|
|
2
|
-
import { useConfig as
|
|
3
|
-
import { useHtmlCompiler as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}), [...new Set(t)];
|
|
1
|
+
import { useActionsApi as D } from "../composables/useActionsApi.js";
|
|
2
|
+
import { useConfig as E } from "../composables/useConfig.js";
|
|
3
|
+
import { useHtmlCompiler as F } from "../composables/useHtmlCompiler.js";
|
|
4
|
+
import { useRecommendationExtensionStore as b } from "../extensions/Blocks/Recommendation/store/recommendation.js";
|
|
5
|
+
import { toBlockUrlConfig as I } from "../extensions/Blocks/Recommendation/utils/blockUrlConfig.js";
|
|
6
|
+
import { DATA_ATTRIBUTES as g } from "../extensions/Blocks/Unsubscribe/utils/constants.js";
|
|
7
|
+
import { parsePageList as R } from "../extensions/Blocks/Unsubscribe/utils/utils.js";
|
|
8
|
+
import { useDynamicContentStore as U } from "../stores/dynamic-content.js";
|
|
9
|
+
import { useEditorStore as L } from "../stores/editor.js";
|
|
10
|
+
import { useUnsubscribeStore as N } from "../stores/unsubscribe.js";
|
|
11
|
+
import { isPlainObject as v } from "./genericUtil.js";
|
|
12
|
+
import { assignTrackingIds as z } from "./linkTrackingIds.js";
|
|
13
|
+
function M(n) {
|
|
14
|
+
const r = new DOMParser().parseFromString(n, "text/html").querySelectorAll(`[${g.PAGE_LIST}]`), e = [];
|
|
15
|
+
return r.forEach((i) => {
|
|
16
|
+
const t = i.getAttribute(g.PAGE_LIST);
|
|
17
|
+
t && e.push(...R(t));
|
|
18
|
+
}), [...new Set(e)];
|
|
20
19
|
}
|
|
21
|
-
async function
|
|
22
|
-
const
|
|
23
|
-
if (
|
|
20
|
+
async function S(n) {
|
|
21
|
+
const o = new DOMParser().parseFromString(n, "text/html").querySelectorAll(".recommendation-block-v2");
|
|
22
|
+
if (o.length === 0)
|
|
24
23
|
return;
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
if (!Number.isFinite(r))
|
|
24
|
+
const r = b();
|
|
25
|
+
o.forEach((e) => {
|
|
26
|
+
const i = e.getAttribute("recommendation-id"), t = i ? Number(i) : NaN;
|
|
27
|
+
if (!Number.isFinite(t))
|
|
30
28
|
return;
|
|
31
|
-
const
|
|
32
|
-
if (!
|
|
29
|
+
const m = e.getAttribute("esd-ext-config");
|
|
30
|
+
if (!m)
|
|
33
31
|
return;
|
|
34
|
-
let
|
|
32
|
+
let a;
|
|
35
33
|
try {
|
|
36
|
-
|
|
34
|
+
a = JSON.parse(m);
|
|
37
35
|
} catch {
|
|
38
36
|
return;
|
|
39
37
|
}
|
|
40
|
-
|
|
41
|
-
return;
|
|
42
|
-
const C = !!e.strategyId || (e.configVersion ?? 0) >= x, o = {
|
|
43
|
-
// Normalize legacy strategy keys (e.g. `mostViewed` → `mostPopular`) so
|
|
44
|
-
// already-saved blocks that never re-run the migrator don't emit a
|
|
45
|
-
// strategy-less campaign URL. `||` also catches '' / undefined (SD-144882).
|
|
46
|
-
strategy: L(e.strategy) || (C ? "" : n.strategy),
|
|
47
|
-
strategyId: e.strategyId ?? n.strategyId,
|
|
48
|
-
language: e.language ?? n.language,
|
|
49
|
-
size: e.size ?? n.size,
|
|
50
|
-
// Spread the default arrays so each block gets a fresh reference
|
|
51
|
-
// instead of sharing the singleton in DEFAULT_NODE_CONFIG.
|
|
52
|
-
productIds: e.productIds ?? [...n.productIds],
|
|
53
|
-
filters: e.filters ?? [...n.filters],
|
|
54
|
-
shuffleProducts: e.shuffleProducts ?? n.shuffleProducts,
|
|
55
|
-
currencyCode: ((d = e.currency) == null ? void 0 : d.code) ?? m.code,
|
|
56
|
-
currencySymbol: ((g = e.currency) == null ? void 0 : g.symbol) ?? m.symbol,
|
|
57
|
-
currencyAlignment: ((f = e.currency) == null ? void 0 : f.alignment) ?? m.alignment,
|
|
58
|
-
currencyDecimalCount: ((s = e.currency) == null ? void 0 : s.decimalCount) ?? m.decimalCount,
|
|
59
|
-
currencyDecimalSeparator: ((y = e.currency) == null ? void 0 : y.decimalSeparator) ?? m.decimalSeparator,
|
|
60
|
-
currencyThousandSeparator: ((S = e.currency) == null ? void 0 : S.thousandSeparator) ?? m.thousandSeparator
|
|
61
|
-
};
|
|
62
|
-
i.seedBlockUrlConfig(r, o);
|
|
38
|
+
v(a) && r.seedBlockUrlConfig(t, I(a));
|
|
63
39
|
});
|
|
64
40
|
try {
|
|
65
|
-
await
|
|
66
|
-
} catch (
|
|
41
|
+
await r.fetchRecommendationCreateData();
|
|
42
|
+
} catch (e) {
|
|
67
43
|
console.warn(
|
|
68
44
|
"Recommendation reference data pre-load failed; validator will skip the availability check.",
|
|
69
|
-
|
|
45
|
+
e
|
|
70
46
|
);
|
|
71
47
|
}
|
|
72
48
|
}
|
|
73
|
-
const
|
|
74
|
-
const
|
|
49
|
+
const Y = () => {
|
|
50
|
+
const n = U(), c = L(), o = N(), { getCompiledEmail: r, getTemplateData: e, updateHtmlAndCss: i } = D(), { compileHtml: t, compileAmpHtml: m } = F(), { isFeatureEnabled: a } = E();
|
|
75
51
|
return {
|
|
76
52
|
prepareTemplateDetails: async () => {
|
|
77
|
-
let { html:
|
|
78
|
-
if (
|
|
53
|
+
let { html: s, css: u, syncModulesIds: h = [] } = await e();
|
|
54
|
+
if (a("linkTrackingIds"))
|
|
79
55
|
try {
|
|
80
|
-
const { html:
|
|
81
|
-
|
|
82
|
-
} catch (
|
|
83
|
-
console.error("Tracking-id step failed, saving anyway:",
|
|
56
|
+
const { html: d, changed: P, nextSeq: x } = z(s, c.trackIdSessionFloor);
|
|
57
|
+
c.trackIdSessionFloor = x, P && (s = d, await i(d, u));
|
|
58
|
+
} catch (d) {
|
|
59
|
+
console.error("Tracking-id step failed, saving anyway:", d);
|
|
84
60
|
}
|
|
85
|
-
const { html:
|
|
61
|
+
const { html: y, ampHtml: p = "", ampErrors: T = [] } = await r({
|
|
86
62
|
minimize: !0,
|
|
87
63
|
resetDataSavedFlag: !1
|
|
88
64
|
});
|
|
89
|
-
|
|
90
|
-
const { compiledHtml:
|
|
65
|
+
o.selectedUnsubscribePages.length && await o.fetchTemplates(), await S(s);
|
|
66
|
+
const { compiledHtml: A, stats: l, appliedRules: w } = t(y), C = p && m(p).compiledHtml, H = n.getSelectedDynamicContentList, k = b(), f = M(s);
|
|
91
67
|
return console.debug("HTML Compilation Stats:", {
|
|
92
|
-
originalSize:
|
|
93
|
-
compiledSize:
|
|
94
|
-
reduction: `${
|
|
95
|
-
appliedRules:
|
|
96
|
-
executionTime: `${
|
|
68
|
+
originalSize: l.originalSize,
|
|
69
|
+
compiledSize: l.compiledSize,
|
|
70
|
+
reduction: `${l.reductionPercentage.toFixed(2)}%`,
|
|
71
|
+
appliedRules: w,
|
|
72
|
+
executionTime: `${l.executionTime.toFixed(2)}ms`
|
|
97
73
|
}), {
|
|
98
|
-
dynamicContentList:
|
|
99
|
-
compiledHtml:
|
|
100
|
-
rawHtml:
|
|
101
|
-
css:
|
|
102
|
-
ampHtml:
|
|
103
|
-
ampErrors:
|
|
104
|
-
modules:
|
|
74
|
+
dynamicContentList: H,
|
|
75
|
+
compiledHtml: A,
|
|
76
|
+
rawHtml: s,
|
|
77
|
+
css: u,
|
|
78
|
+
ampHtml: C,
|
|
79
|
+
ampErrors: T,
|
|
80
|
+
modules: h.map(Number),
|
|
105
81
|
recommendation: {
|
|
106
|
-
campaignUrls:
|
|
82
|
+
campaignUrls: k.recommendationCampaignUrls,
|
|
107
83
|
configs: {}
|
|
108
84
|
},
|
|
109
85
|
unsubscribe: {
|
|
110
|
-
status:
|
|
111
|
-
config:
|
|
86
|
+
status: f.length > 0,
|
|
87
|
+
config: f
|
|
112
88
|
}
|
|
113
89
|
};
|
|
114
90
|
},
|
|
115
91
|
// Exposed so the back/test validate-only path can seed the reco store the
|
|
116
92
|
// same way a full save does (required-field findings depend on it).
|
|
117
|
-
hydrateRecommendationStore:
|
|
93
|
+
hydrateRecommendationStore: S
|
|
118
94
|
};
|
|
119
95
|
};
|
|
120
96
|
export {
|
|
121
97
|
M as getHtmlReferencedUnsubscribePages,
|
|
122
|
-
|
|
98
|
+
Y as useTemplatePreparation
|
|
123
99
|
};
|
package/dist/utils/timeUtil.js
CHANGED
|
@@ -1,19 +1,8 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
const { timeZone: t } = new Intl.DateTimeFormat().resolvedOptions();
|
|
7
|
-
return ((e = t.split("/").pop()) == null ? void 0 : e.replace(/_/g, " ")) ?? t;
|
|
8
|
-
}, c = (t, e = !1) => {
|
|
9
|
-
const o = t.toLocaleTimeString([], {
|
|
10
|
-
hour: "2-digit",
|
|
11
|
-
hour12: !1,
|
|
12
|
-
minute: "2-digit",
|
|
13
|
-
second: "2-digit"
|
|
14
|
-
});
|
|
15
|
-
return e ? `${o} (${r(t)} ${a()})` : o;
|
|
16
|
-
};
|
|
1
|
+
const g = (t) => String(t).padStart(2, "0"), a = (t, e) => t.getFullYear() === e.getFullYear() && t.getMonth() === e.getMonth() && t.getDate() === e.getDate(), o = (t, e = /* @__PURE__ */ new Date()) => ({
|
|
2
|
+
isToday: a(t, e),
|
|
3
|
+
time: `${g(t.getHours())}:${g(t.getMinutes())}`,
|
|
4
|
+
date: `${g(t.getDate())}.${g(t.getMonth() + 1)}.${t.getFullYear()}`
|
|
5
|
+
});
|
|
17
6
|
export {
|
|
18
|
-
|
|
7
|
+
o as autoSaveTimestamp
|
|
19
8
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@useinsider/guido",
|
|
3
|
-
"version": "3.20.
|
|
3
|
+
"version": "3.20.1-beta.07e0277",
|
|
4
4
|
"description": "Guido is a Vue + TypeScript wrapper for Email Plugin. Easily embed the email editor in your Vue applications.",
|
|
5
5
|
"main": "./dist/guido.umd.cjs",
|
|
6
6
|
"module": "./dist/library.js",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"author": "",
|
|
53
53
|
"license": "ISC",
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@stripoinc/ui-editor-extensions": "3.
|
|
55
|
+
"@stripoinc/ui-editor-extensions": "3.11.0",
|
|
56
56
|
"@useinsider/design-system-organisms": "0.0.3-beta.d816f06",
|
|
57
57
|
"@useinsider/design-system-vue": "1.5.0",
|
|
58
58
|
"@vueuse/core": "11.3.0",
|
|
@@ -123,7 +123,7 @@
|
|
|
123
123
|
},
|
|
124
124
|
"guido": {
|
|
125
125
|
"stripo": {
|
|
126
|
-
"version": "2.
|
|
126
|
+
"version": "2.79.0"
|
|
127
127
|
}
|
|
128
128
|
}
|
|
129
129
|
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import o from "./AutoSaveToggle.vue2.js";
|
|
2
|
-
/* empty css */
|
|
3
|
-
import i from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
-
var n = function() {
|
|
5
|
-
var e = this, a = e._self._c, t = e._self._setupProxy;
|
|
6
|
-
return t.isFeatureEnabled("autosave") ? a("div", { staticClass: "d-f a-i-c mr-3 auto-save-toggle", on: { mouseenter: function(s) {
|
|
7
|
-
t.isHovered = !0;
|
|
8
|
-
}, mouseleave: function(s) {
|
|
9
|
-
t.isHovered = !1;
|
|
10
|
-
} } }, [a(t.InToggle, { attrs: { id: "guido__autosave-toggle", name: "guido-autosave-toggle", checked: t.autosaveStore.isOn, disable: t.editorStore.loadingStatus }, on: { click: t.toggle } }), a("span", { staticClass: "ml-2 auto-save-toggle__label t-c-55" }, [e._v(" " + e._s(t.trans("email-editor.auto-save")) + " ")]), t.autosaveStore.status === t.AUTOSAVE_STATUS.SAVING ? a("span", { staticClass: "ml-2 d-f a-i-c f-s-1" }, [a(t.InLoading, { attrs: { "color-class": "i-c-53", size: "16" } }), a("span", { staticClass: "ml-1 t-c-53" }, [e._v(" " + e._s(t.trans("newsletter.saving")) + " ")])], 1) : t.lastSavedLabel ? a("span", { staticClass: "ml-2 f-s-1 t-c-53" }, [e._v(" " + e._s(t.lastSavedLabel) + " ")]) : e._e(), t.isHovered ? a(t.InInfoBox, { staticClass: "auto-save-toggle__info-box", attrs: { id: "guido__autosave-info-box", size: "small", variant: "information", "description-text": t.trans("email-editor.auto-save-description"), "title-text": t.trans("email-editor.auto-save-title") } }) : e._e()], 1) : e._e();
|
|
11
|
-
}, l = [], r = /* @__PURE__ */ i(
|
|
12
|
-
o,
|
|
13
|
-
n,
|
|
14
|
-
l,
|
|
15
|
-
!1,
|
|
16
|
-
null,
|
|
17
|
-
"2c964af4"
|
|
18
|
-
);
|
|
19
|
-
const d = r.exports;
|
|
20
|
-
export {
|
|
21
|
-
d as default
|
|
22
|
-
};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { defineComponent as i, ref as f, computed as u } from "vue";
|
|
2
|
-
import { useConfig as l } from "../../../composables/useConfig.js";
|
|
3
|
-
import { useTranslations as p } from "../../../composables/useTranslations.js";
|
|
4
|
-
import { useAutosaveStore as c, AUTOSAVE_STATUS as t } from "../../../stores/autosave.js";
|
|
5
|
-
import { useEditorStore as S } from "../../../stores/editor.js";
|
|
6
|
-
import { formatLocalTime as d } from "../../../utils/timeUtil.js";
|
|
7
|
-
import { InToggle as g, InLoading as _, InInfoBox as A } from "@useinsider/design-system-vue";
|
|
8
|
-
const U = /* @__PURE__ */ i({
|
|
9
|
-
__name: "AutoSaveToggle",
|
|
10
|
-
setup(v) {
|
|
11
|
-
const { isFeatureEnabled: e } = l(), r = S(), o = c(), s = p(), n = f(!1), a = u(() => o.status !== t.SAVED || !o.lastSavedAt ? "" : d(o.lastSavedAt));
|
|
12
|
-
return { __sfc: !0, isFeatureEnabled: e, editorStore: r, autosaveStore: o, trans: s, isHovered: n, lastSavedLabel: a, toggle: (m) => {
|
|
13
|
-
o.isOn = m;
|
|
14
|
-
}, AUTOSAVE_STATUS: t, InInfoBox: A, InLoading: _, InToggle: g };
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
export {
|
|
18
|
-
U as default
|
|
19
|
-
};
|
/package/dist/src/components/organisms/header/{AutoSaveToggle.vue.d.ts → AutoSaveStatus.vue.d.ts}
RENAMED
|
File without changes
|