@useinsider/guido 1.0.0-beta.5f64b91 → 1.0.0-beta.5fa6011
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 +23 -19
- package/dist/components/Guido.vue.d.ts +4 -0
- package/dist/components/Guido.vue.js +1 -1
- package/dist/components/Guido.vue2.js +30 -18
- package/dist/components/organisms/header/LeftSlot.vue.d.ts +1 -1
- package/dist/components/organisms/header/LeftSlot.vue.js +8 -8
- package/dist/components/organisms/header/LeftSlot.vue2.js +5 -3
- package/dist/components/organisms/header/MiddleSlot.vue.js +7 -7
- package/dist/components/organisms/header/MiddleSlot.vue2.js +6 -4
- package/dist/components/organisms/header/RightSlot.vue.d.ts +1 -1
- package/dist/components/organisms/header/RightSlot.vue.js +4 -5
- package/dist/components/organisms/header/RightSlot.vue2.js +8 -10
- package/dist/components/organisms/header/ViewOptions.vue.js +1 -1
- package/dist/components/organisms/header/version-history/RestoreButton.vue.d.ts +2 -0
- package/dist/components/organisms/header/version-history/RestoreButton.vue.js +19 -0
- package/dist/components/organisms/header/version-history/RestoreButton.vue2.js +14 -0
- package/dist/components/organisms/header/version-history/VersionHistory.vue.d.ts +13 -1
- package/dist/components/organisms/header/version-history/VersionHistory.vue.js +11 -11
- package/dist/components/organisms/header/version-history/VersionHistory.vue2.js +13 -9
- package/dist/components/organisms/header/version-history/VersionHistoryItem.vue.d.ts +16 -0
- package/dist/components/organisms/header/version-history/VersionHistoryItem.vue.js +18 -0
- package/dist/components/organisms/header/version-history/VersionHistoryItem.vue2.js +16 -0
- package/dist/components/organisms/header/version-history/ViewOptions.vue.js +1 -1
- package/dist/composables/useCustomInterfaceAppearance.js +43 -9
- package/dist/composables/useHttp.js +84 -0
- package/dist/composables/usePartner.d.ts +4 -0
- package/dist/composables/usePartner.js +16 -0
- package/dist/composables/useStripo.d.ts +2 -2
- package/dist/composables/useStripo.js +52 -56
- package/dist/composables/useToaster.d.ts +1 -0
- package/dist/composables/useToaster.js +24 -16
- package/dist/composables/useVersionHistoryApi.d.ts +1 -0
- package/dist/composables/useVersionHistoryApi.js +30 -12
- package/dist/enums/defaults.d.ts +2 -0
- package/dist/enums/defaults.js +5 -3
- package/dist/enums/displayConditions.d.ts +2 -0
- package/dist/enums/displayConditions.js +80 -0
- package/dist/guido.css +1 -1
- package/dist/mock/api/custom-fonts.d.ts +2 -0
- package/dist/services/stripoApi.d.ts +7 -0
- package/dist/services/stripoApi.js +29 -0
- package/dist/static/styles/base.css.js +11 -0
- package/dist/static/styles/components/alert-message.css.js +39 -0
- package/dist/static/styles/components/amp-block.css.js +18 -0
- package/dist/static/styles/components/base-input.css.js +47 -0
- package/dist/static/styles/components/button-group.css.js +54 -0
- package/dist/static/styles/components/button.css.js +106 -0
- package/dist/static/styles/components/combobox.css.js +49 -0
- package/dist/static/styles/components/counter.css.js +42 -0
- package/dist/static/styles/components/dropdown-menu.css.js +44 -0
- package/dist/static/styles/components/narrow-panel.css.js +38 -0
- package/dist/static/styles/components/switcher.css.js +11 -0
- package/dist/static/styles/components/tabs.css.js +97 -0
- package/dist/static/styles/components/tools.css.js +23 -0
- package/dist/static/styles/components/wide-panel.css.js +135 -0
- package/dist/static/styles/variables.css.js +23 -0
- package/dist/stores/editor.js +1 -1
- package/dist/stores/version-history.d.ts +1 -2
- package/dist/stores/version-history.js +1 -1
- package/dist/utils/dateUtil.d.ts +1 -0
- package/dist/utils/dateUtil.js +16 -0
- package/package.json +1 -1
- package/dist/node_modules/pinia/dist/pinia.js +0 -317
- package/dist/node_modules/pinia/node_modules/vue-demi/lib/index.js +0 -11
- package/dist/static/editor.css.js +0 -182
package/README.md
CHANGED
|
@@ -24,6 +24,7 @@ npm install @useinsider/guido
|
|
|
24
24
|
<div>
|
|
25
25
|
<Guido
|
|
26
26
|
:email-id="emailId"
|
|
27
|
+
:user-id="userId"
|
|
27
28
|
:guido-config="guidoConfig"
|
|
28
29
|
/>
|
|
29
30
|
</div>
|
|
@@ -39,6 +40,7 @@ export default {
|
|
|
39
40
|
data() {
|
|
40
41
|
return {
|
|
41
42
|
emailId: 'abc123',
|
|
43
|
+
userId: '12345',
|
|
42
44
|
guidoConfig: {
|
|
43
45
|
translationsPath: 'window.trans.en'
|
|
44
46
|
}
|
|
@@ -55,6 +57,10 @@ export default {
|
|
|
55
57
|
| Prop | Type | Required | Default | Description |
|
|
56
58
|
|------|------|----------|---------|-------------|
|
|
57
59
|
| `emailId` | `string` | ✅ | - | Unique identifier for the email draft |
|
|
60
|
+
| `userId` | `string` | ✅ | - | Unique identifier for the user draft |
|
|
61
|
+
| `username` | `string` | ⚪ | Guido User | User name |
|
|
62
|
+
| `partnerName` | `string` | ⚪ | Getting from URL host | Unique identifier for the partner draft |
|
|
63
|
+
| `productType` | `string` | ⚪ | Getting from URL path | Unique identifier for the product draft |
|
|
58
64
|
| `guidoConfig` | `GuidoConfig` | ✅ | - | Configuration object for the editor |
|
|
59
65
|
|
|
60
66
|
### GuidoConfig Interface
|
|
@@ -138,24 +144,17 @@ VITE_STRIPO_ROLE=your_role
|
|
|
138
144
|
|
|
139
145
|
```
|
|
140
146
|
src/
|
|
141
|
-
├── components/
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
├──
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
├──
|
|
151
|
-
|
|
152
|
-
│ ├── stripo.d.ts # Stripo-specific types
|
|
153
|
-
│ └── events.ts # Event types
|
|
154
|
-
├── static/
|
|
155
|
-
│ ├── editor.css # Custom editor styles
|
|
156
|
-
│ └── templates/
|
|
157
|
-
│ └── default/ # Default email template
|
|
158
|
-
└── library.ts # Main export for library
|
|
147
|
+
├── components/ # Vue components
|
|
148
|
+
├── composables/ # Vue composables & business logic
|
|
149
|
+
├── services/ # API layer
|
|
150
|
+
├── stores/ # State management
|
|
151
|
+
├── @types/ # TypeScript definitions
|
|
152
|
+
├── static/ # Static assets & templates
|
|
153
|
+
├── utils/ # Utility functions
|
|
154
|
+
├── enums/ # Constants & enums
|
|
155
|
+
├── mock/ # Mock data for development
|
|
156
|
+
├── plugins/ # Vue plugins
|
|
157
|
+
└── library.ts # Main export
|
|
159
158
|
```
|
|
160
159
|
|
|
161
160
|
## 🌐 i18n
|
|
@@ -212,7 +211,12 @@ ISC License
|
|
|
212
211
|
- [@useinsider/design-system-vue](https://github.com/useinsider/design-system-vue) - Insider's Vue design system
|
|
213
212
|
|
|
214
213
|
## 🎯 TODO:
|
|
215
|
-
-
|
|
214
|
+
- CSS part should be optimized with variables & `sass-loader`.
|
|
216
215
|
- Master Version Generator should be fixed.
|
|
217
216
|
- Playwright integration
|
|
218
217
|
- Commitlint & Precommit Hooks integration
|
|
218
|
+
- We need to emit save event and we should return template config to it
|
|
219
|
+
- Default template should be same with production
|
|
220
|
+
- Open Guido with saved template
|
|
221
|
+
- Get User ID, Email and Unique Template ID as dynamic from props
|
|
222
|
+
- Get Pre-built display conditions from API
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import type { GuidoConfig } from '@@/Types/generic';
|
|
2
2
|
type __VLS_Props = {
|
|
3
3
|
emailId: string;
|
|
4
|
+
userId: string;
|
|
5
|
+
partnerName?: string;
|
|
6
|
+
productType?: string;
|
|
7
|
+
username?: string;
|
|
4
8
|
guidoConfig: GuidoConfig;
|
|
5
9
|
};
|
|
6
10
|
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, {}, {}, {}, import("vue/types/v3-component-options").ComponentOptionsMixin, import("vue/types/v3-component-options").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>>, {}>;
|
|
@@ -1,31 +1,43 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
|
|
1
|
+
import { defineComponent as f, onMounted as c } from "vue";
|
|
2
|
+
import { usePartner as g } from "../composables/usePartner.js";
|
|
3
|
+
import { useStripo as _ } from "../composables/useStripo.js";
|
|
4
|
+
import { useTemplates as y } from "../composables/useTemplates.js";
|
|
5
|
+
import { DefaultUsername as C, DefaultGuidoConfig as T } from "../enums/defaults.js";
|
|
6
|
+
import w from "./organisms/header/HeaderWrapper.vue.js";
|
|
7
|
+
const h = /* @__PURE__ */ f({
|
|
7
8
|
__name: "Guido",
|
|
8
9
|
props: {
|
|
9
10
|
emailId: null,
|
|
11
|
+
userId: null,
|
|
12
|
+
partnerName: null,
|
|
13
|
+
productType: null,
|
|
14
|
+
username: null,
|
|
10
15
|
guidoConfig: null
|
|
11
16
|
},
|
|
12
|
-
setup(
|
|
13
|
-
const o = r
|
|
17
|
+
setup(d) {
|
|
18
|
+
const o = d, { getPartnerName: r, getProductType: t } = g(), {
|
|
19
|
+
emailId: n,
|
|
20
|
+
userId: i,
|
|
21
|
+
guidoConfig: a,
|
|
22
|
+
partnerName: u = r(),
|
|
23
|
+
productType: p = t(),
|
|
24
|
+
username: m = C
|
|
25
|
+
} = o;
|
|
14
26
|
window.GuidoConfig = {
|
|
15
|
-
...
|
|
16
|
-
...
|
|
27
|
+
...T,
|
|
28
|
+
...a
|
|
17
29
|
};
|
|
18
|
-
const { initPlugin:
|
|
19
|
-
return
|
|
30
|
+
const { initPlugin: l } = _({ emailId: n, userId: i, username: m, partnerName: u, productType: p }), { getDefaultTemplate: s } = y();
|
|
31
|
+
return c(async () => {
|
|
20
32
|
try {
|
|
21
|
-
const
|
|
22
|
-
await e
|
|
23
|
-
} catch (
|
|
24
|
-
console.error("Failed to initialize Stripo editor:",
|
|
33
|
+
const e = await s();
|
|
34
|
+
await l(e);
|
|
35
|
+
} catch (e) {
|
|
36
|
+
console.error("Failed to initialize Stripo editor:", e);
|
|
25
37
|
}
|
|
26
|
-
}), { __sfc: !0, props: o, initPlugin:
|
|
38
|
+
}), { __sfc: !0, props: o, getPartnerName: r, getProductType: t, emailId: n, userId: i, guidoConfig: a, partnerName: u, productType: p, username: m, initPlugin: l, getDefaultTemplate: s, HeaderWrapper: w };
|
|
27
39
|
}
|
|
28
40
|
});
|
|
29
41
|
export {
|
|
30
|
-
|
|
42
|
+
h as default
|
|
31
43
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options").ComponentOptionsMixin, import("vue/types/v3-component-options").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
2
2
|
export default _default;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import r from "./LeftSlot.vue2.js";
|
|
2
2
|
import o from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
-
var
|
|
4
|
-
var t = this, e = t._self._c,
|
|
5
|
-
return e("div", [e(
|
|
6
|
-
},
|
|
3
|
+
var n = function() {
|
|
4
|
+
var t = this, e = t._self._c, s = t._self._setupProxy;
|
|
5
|
+
return e("div", { staticClass: "d-f a-i-c" }, [e(s.InButtonV2, { staticClass: "p-2", attrs: { id: "guido__back-button", "label-text": "Back", "left-icon": "line-arrow-left", styling: "text", type: "secondary" } }), s.editorStore.isVersionHistoryOpen ? e(s.RestoreButton, { staticClass: "ml-3" }) : t._e()], 1);
|
|
6
|
+
}, a = [], i = /* @__PURE__ */ o(
|
|
7
7
|
r,
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
n,
|
|
9
|
+
a,
|
|
10
10
|
!1,
|
|
11
11
|
null,
|
|
12
12
|
null
|
|
13
13
|
);
|
|
14
|
-
const
|
|
14
|
+
const f = i.exports;
|
|
15
15
|
export {
|
|
16
|
-
|
|
16
|
+
f as default
|
|
17
17
|
};
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { defineComponent as t } from "vue";
|
|
2
|
-
import {
|
|
2
|
+
import { useEditorStore as o } from "../../../stores/editor.js";
|
|
3
|
+
import { InButtonV2 as r } from "@useinsider/design-system-vue";
|
|
4
|
+
import e from "./version-history/RestoreButton.vue.js";
|
|
3
5
|
const _ = /* @__PURE__ */ t({
|
|
4
6
|
__name: "LeftSlot",
|
|
5
|
-
setup(
|
|
6
|
-
return { __sfc: !0,
|
|
7
|
+
setup(m) {
|
|
8
|
+
return { __sfc: !0, editorStore: o(), InButtonV2: r, RestoreButton: e };
|
|
7
9
|
}
|
|
8
10
|
});
|
|
9
11
|
export {
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import s from "./MiddleSlot.vue2.js";
|
|
2
|
-
import
|
|
3
|
-
var
|
|
2
|
+
import i from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var n = function() {
|
|
4
4
|
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
5
|
-
return t.editorStore.isVersionHistoryOpen ? o(t.VersionHistory) : o("div", { staticClass: "d-f" }, [o(t.InButtonV2, { attrs: { id: "guido__undo-button", "left-icon": "line-undo", styling: "ghost", type: "secondary", "label-text-status": !1 } }), o(t.InButtonV2, { attrs: { id: "guido__redo-button", "left-icon": "line-redo", styling: "ghost", type: "secondary", "label-text-status": !1 } }), o(t.InButtonV2, { attrs: { id: "guido__code-button", "left-icon": "line-code", styling: "ghost", "tooltip-text": "Code Editor", type: "secondary", "label-text-status": !1, "selected-status": t.editorStore.isCodeEditorOpen, "tooltip-options": t.getTooltipOptions("guido__code-button") } }), o(t.InButtonV2, { attrs: { id: "guido__preview-button", "left-icon": "line-show-on", styling: "ghost", type: "secondary", "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__preview-button"), "tooltip-text": t.trans("newsletter.email-preview") } })], 1);
|
|
6
|
-
}, l = [], r = /* @__PURE__ */
|
|
5
|
+
return t.editorStore.isVersionHistoryOpen ? o("div", { staticClass: "d-f" }, [o(t.VersionHistory), o(t.VersionHistoryViewOptions)], 1) : o("div", { staticClass: "d-f" }, [o(t.InButtonV2, { attrs: { id: "guido__undo-button", "left-icon": "line-undo", styling: "ghost", type: "secondary", "label-text-status": !1 } }), o(t.InButtonV2, { attrs: { id: "guido__redo-button", "left-icon": "line-redo", styling: "ghost", type: "secondary", "label-text-status": !1 } }), o(t.InButtonV2, { attrs: { id: "guido__code-button", "left-icon": "line-code", styling: "ghost", "tooltip-text": "Code Editor", type: "secondary", "label-text-status": !1, "selected-status": t.editorStore.isCodeEditorOpen, "tooltip-options": t.getTooltipOptions("guido__code-button") } }), o(t.InButtonV2, { attrs: { id: "guido__preview-button", "left-icon": "line-show-on", styling: "ghost", type: "secondary", "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__preview-button"), "tooltip-text": t.trans("newsletter.email-preview") } }), o(t.ViewOptions, { staticClass: "ml-3" })], 1);
|
|
6
|
+
}, l = [], r = /* @__PURE__ */ i(
|
|
7
7
|
s,
|
|
8
|
-
|
|
8
|
+
n,
|
|
9
9
|
l,
|
|
10
10
|
!1,
|
|
11
11
|
null,
|
|
12
12
|
null
|
|
13
13
|
);
|
|
14
|
-
const
|
|
14
|
+
const p = r.exports;
|
|
15
15
|
export {
|
|
16
|
-
|
|
16
|
+
p as default
|
|
17
17
|
};
|
|
@@ -3,18 +3,20 @@ import { useTranslations as s } from "../../../composables/useTranslations.js";
|
|
|
3
3
|
import { useEditorStore as n } from "../../../stores/editor.js";
|
|
4
4
|
import { InButtonV2 as e } from "@useinsider/design-system-vue";
|
|
5
5
|
import m from "./version-history/VersionHistory.vue.js";
|
|
6
|
-
|
|
6
|
+
import p from "./version-history/ViewOptions.vue.js";
|
|
7
|
+
import f from "./ViewOptions.vue.js";
|
|
8
|
+
const y = /* @__PURE__ */ r({
|
|
7
9
|
__name: "MiddleSlot",
|
|
8
|
-
setup(
|
|
10
|
+
setup(a) {
|
|
9
11
|
const o = n(), t = s();
|
|
10
12
|
return { __sfc: !0, editorStore: o, trans: t, getTooltipOptions: (i) => ({
|
|
11
13
|
id: `${i}-tooltip`,
|
|
12
14
|
dynamicPosition: !1,
|
|
13
15
|
staticPosition: "bottom center",
|
|
14
16
|
iconStatus: !1
|
|
15
|
-
}), InButtonV2: e, VersionHistory: m };
|
|
17
|
+
}), InButtonV2: e, VersionHistory: m, VersionHistoryViewOptions: p, ViewOptions: f };
|
|
16
18
|
}
|
|
17
19
|
});
|
|
18
20
|
export {
|
|
19
|
-
|
|
21
|
+
y as default
|
|
20
22
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options").ComponentOptionsMixin, import("vue/types/v3-component-options").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
2
2
|
export default _default;
|
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
import o from "./RightSlot.vue2.js";
|
|
2
|
-
/* empty css */
|
|
3
2
|
import i from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
3
|
var n = function() {
|
|
5
4
|
var s = this, e = s._self._c, t = s._self._setupProxy;
|
|
6
|
-
return e("div", { staticClass: "d-f
|
|
5
|
+
return e("div", { staticClass: "d-f" }, [e(t.InButtonV2, { attrs: { id: "guido__history-button", "left-icon": "line-architect-version-history", styling: "ghost", type: "secondary", "label-text-status": !1, "selected-status": t.editorStore.isVersionHistoryOpen }, on: { click: t.handleVersionHistory } }), e(t.InButtonV2, { attrs: { id: "guido__export-button", "left-icon": "line-export", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryOpen, "label-text-status": !1 }, on: { click: t.exportHtml } }), e(t.InButtonV2, { attrs: { id: "guido__save-as-button", "left-icon": "line-newsletter-save-as-template", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryOpen, "label-text-status": !1 } }), e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryOpen, "label-text-status": !1 } }), e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": t.editorStore.isVersionHistoryOpen } })], 1);
|
|
7
6
|
}, r = [], a = /* @__PURE__ */ i(
|
|
8
7
|
o,
|
|
9
8
|
n,
|
|
10
9
|
r,
|
|
11
10
|
!1,
|
|
12
11
|
null,
|
|
13
|
-
|
|
12
|
+
null
|
|
14
13
|
);
|
|
15
|
-
const
|
|
14
|
+
const c = a.exports;
|
|
16
15
|
export {
|
|
17
|
-
|
|
16
|
+
c as default
|
|
18
17
|
};
|
|
@@ -1,23 +1,21 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useExport as
|
|
1
|
+
import { defineComponent as s } from "vue";
|
|
2
|
+
import { useExport as i } from "../../../composables/useExport.js";
|
|
3
3
|
import { useVersionHistoryApi as n } from "../../../composables/useVersionHistoryApi.js";
|
|
4
4
|
import { useEditorStore as p } from "../../../stores/editor.js";
|
|
5
5
|
import { InButtonV2 as m } from "@useinsider/design-system-vue";
|
|
6
|
-
|
|
7
|
-
import V from "./ViewOptions.vue.js";
|
|
8
|
-
const x = /* @__PURE__ */ e({
|
|
6
|
+
const d = /* @__PURE__ */ s({
|
|
9
7
|
__name: "RightSlot",
|
|
10
|
-
setup(
|
|
11
|
-
const { exportHtml:
|
|
12
|
-
return { __sfc: !0, exportHtml:
|
|
8
|
+
setup(f) {
|
|
9
|
+
const { exportHtml: e } = i(), { openVersionHistory: o, closeVersionHistory: r } = n(), t = p();
|
|
10
|
+
return { __sfc: !0, exportHtml: e, openVersionHistory: o, closeVersionHistory: r, editorStore: t, handleVersionHistory: () => {
|
|
13
11
|
if (t.isVersionHistoryOpen) {
|
|
14
12
|
r();
|
|
15
13
|
return;
|
|
16
14
|
}
|
|
17
15
|
o();
|
|
18
|
-
}, InButtonV2: m
|
|
16
|
+
}, InButtonV2: m };
|
|
19
17
|
}
|
|
20
18
|
});
|
|
21
19
|
export {
|
|
22
|
-
|
|
20
|
+
d as default
|
|
23
21
|
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options").ComponentOptionsMixin, import("vue/types/v3-component-options").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
2
|
+
export default _default;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import n from "./RestoreButton.vue2.js";
|
|
2
|
+
import o from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var s = function() {
|
|
4
|
+
var e = this, r = e._self._c, t = e._self._setupProxy;
|
|
5
|
+
return r(t.InButtonV2, { attrs: { id: "guido__restore-button", "label-text": "Restore", type: "subtle-primary" }, on: { click: function(a) {
|
|
6
|
+
return t.restoreVersion(t.versionHistoryStore.currentPatch.id);
|
|
7
|
+
} } });
|
|
8
|
+
}, _ = [], i = /* @__PURE__ */ o(
|
|
9
|
+
n,
|
|
10
|
+
s,
|
|
11
|
+
_,
|
|
12
|
+
!1,
|
|
13
|
+
null,
|
|
14
|
+
null
|
|
15
|
+
);
|
|
16
|
+
const f = i.exports;
|
|
17
|
+
export {
|
|
18
|
+
f as default
|
|
19
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { defineComponent as t } from "vue";
|
|
2
|
+
import { useVersionHistoryApi as e } from "../../../../composables/useVersionHistoryApi.js";
|
|
3
|
+
import { useVersionHistoryStore as s } from "../../../../stores/version-history.js";
|
|
4
|
+
import { InButtonV2 as n } from "@useinsider/design-system-vue";
|
|
5
|
+
const _ = /* @__PURE__ */ t({
|
|
6
|
+
__name: "RestoreButton",
|
|
7
|
+
setup(i) {
|
|
8
|
+
const { restoreVersion: o } = e(), r = s();
|
|
9
|
+
return { __sfc: !0, restoreVersion: o, versionHistoryStore: r, InButtonV2: n };
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
export {
|
|
13
|
+
_ as default
|
|
14
|
+
};
|
|
@@ -1,2 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
itemStatus?: boolean;
|
|
3
|
+
};
|
|
4
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>>, {}>;
|
|
2
5
|
export default _default;
|
|
6
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
7
|
+
type __VLS_TypePropsToOption<T> = {
|
|
8
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
9
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
10
|
+
} : {
|
|
11
|
+
type: import('vue').PropType<T[K]>;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import o from "./VersionHistory.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
3
|
+
import i from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var n = function() {
|
|
5
|
-
var
|
|
6
|
-
return
|
|
5
|
+
var s = this, e = s._self._c, t = s._self._setupProxy;
|
|
6
|
+
return e("div", { staticClass: "version-history-wrapper d-f a-i-c f-g-1 mx-3" }, [t.itemStatus ? e(t.VersionHistoryItem, { attrs: { "text-align": "right", date: t.versionHistoryStore.previousPatch.date, description: t.versionHistoryStore.previousPatch.description } }) : s._e(), e("div", { staticClass: "d-f" }, [e(t.InButtonV2, { attrs: { id: "guido__undo-button", "left-icon": "line-undo", styling: "ghost", type: "secondary", "disabled-status": !t.versionHistoryStore.hasPreviousPatch, "label-text-status": !1 }, on: { click: function(r) {
|
|
7
7
|
return t.previewVersion(t.versionHistoryStore.previousPatch.id);
|
|
8
|
-
} } }),
|
|
8
|
+
} } }), e(t.InButtonV2, { attrs: { id: "guido__redo-button", "left-icon": "line-redo", styling: "ghost", type: "secondary", "disabled-status": !t.versionHistoryStore.hasNextPatch, "label-text-status": !1 }, on: { click: function(r) {
|
|
9
9
|
return t.previewVersion(t.versionHistoryStore.nextPatch.id);
|
|
10
|
-
} } })], 1),
|
|
11
|
-
}, a = [],
|
|
12
|
-
|
|
10
|
+
} } })], 1), t.itemStatus ? e(t.VersionHistoryItem, { attrs: { "text-align": "left", date: t.versionHistoryStore.nextPatch.date, description: t.versionHistoryStore.nextPatch.description } }) : s._e()], 1);
|
|
11
|
+
}, a = [], c = /* @__PURE__ */ i(
|
|
12
|
+
o,
|
|
13
13
|
n,
|
|
14
14
|
a,
|
|
15
15
|
!1,
|
|
16
16
|
null,
|
|
17
|
-
"
|
|
17
|
+
"52a77eec"
|
|
18
18
|
);
|
|
19
|
-
const
|
|
19
|
+
const _ = c.exports;
|
|
20
20
|
export {
|
|
21
|
-
|
|
21
|
+
_ as default
|
|
22
22
|
};
|
|
@@ -1,14 +1,18 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useVersionHistoryApi as
|
|
3
|
-
import { useVersionHistoryStore as
|
|
4
|
-
import { InButtonV2 as
|
|
5
|
-
|
|
1
|
+
import { defineComponent as i } from "vue";
|
|
2
|
+
import { useVersionHistoryApi as n } from "../../../../composables/useVersionHistoryApi.js";
|
|
3
|
+
import { useVersionHistoryStore as m } from "../../../../stores/version-history.js";
|
|
4
|
+
import { InButtonV2 as p } from "@useinsider/design-system-vue";
|
|
5
|
+
import f from "./VersionHistoryItem.vue.js";
|
|
6
|
+
const _ = /* @__PURE__ */ i({
|
|
6
7
|
__name: "VersionHistory",
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
props: {
|
|
9
|
+
itemStatus: { type: Boolean }
|
|
10
|
+
},
|
|
11
|
+
setup(t) {
|
|
12
|
+
const o = t, r = m(), { previewVersion: e } = n(), { itemStatus: s = !1 } = o;
|
|
13
|
+
return { __sfc: !0, versionHistoryStore: r, previewVersion: e, props: o, itemStatus: s, InButtonV2: p, VersionHistoryItem: f };
|
|
10
14
|
}
|
|
11
15
|
});
|
|
12
16
|
export {
|
|
13
|
-
|
|
17
|
+
_ as default
|
|
14
18
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
description: string;
|
|
3
|
+
date: number;
|
|
4
|
+
textAlign: string;
|
|
5
|
+
};
|
|
6
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, {}, {}, {}, import("vue/types/v3-component-options").ComponentOptionsMixin, import("vue/types/v3-component-options").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>>, {}>;
|
|
7
|
+
export default _default;
|
|
8
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
9
|
+
type __VLS_TypePropsToOption<T> = {
|
|
10
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
11
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
12
|
+
} : {
|
|
13
|
+
type: import('vue').PropType<T[K]>;
|
|
14
|
+
required: true;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import e from "./VersionHistoryItem.vue2.js";
|
|
2
|
+
/* empty css */
|
|
3
|
+
import o from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
+
var i = function() {
|
|
5
|
+
var s = this, r = s._self._c, t = s._self._setupProxy;
|
|
6
|
+
return r("div", { staticClass: "version-history-item f-g-1" }, [t.props.description ? r("div", { staticClass: "d-f f-d-c", class: { "t-a-r": t.props.textAlign === "right" } }, [r("div", { staticClass: "t-o-e o-h w-s-n-w", domProps: { innerHTML: s._s(t.props.description) } }), r("div", { staticClass: "f-s-1" }, [s._v(" " + s._s(t.formatPatchDate(t.props.date)) + " ")])]) : s._e()]);
|
|
7
|
+
}, a = [], n = /* @__PURE__ */ o(
|
|
8
|
+
e,
|
|
9
|
+
i,
|
|
10
|
+
a,
|
|
11
|
+
!1,
|
|
12
|
+
null,
|
|
13
|
+
"0e2ff42d"
|
|
14
|
+
);
|
|
15
|
+
const d = n.exports;
|
|
16
|
+
export {
|
|
17
|
+
d as default
|
|
18
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { defineComponent as o } from "vue";
|
|
2
|
+
import { formatPatchDate as e } from "../../../../utils/dateUtil.js";
|
|
3
|
+
const s = /* @__PURE__ */ o({
|
|
4
|
+
__name: "VersionHistoryItem",
|
|
5
|
+
props: {
|
|
6
|
+
description: null,
|
|
7
|
+
date: null,
|
|
8
|
+
textAlign: null
|
|
9
|
+
},
|
|
10
|
+
setup(t) {
|
|
11
|
+
return { __sfc: !0, props: t, formatPatchDate: e };
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
export {
|
|
15
|
+
s as default
|
|
16
|
+
};
|
|
@@ -1,13 +1,47 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import S from "../static/styles/base.css.js";
|
|
2
|
+
import e from "../static/styles/components/alert-message.css.js";
|
|
3
|
+
import m from "../static/styles/components/amp-block.css.js";
|
|
4
|
+
import i from "../static/styles/components/base-input.css.js";
|
|
5
|
+
import p from "../static/styles/components/button-group.css.js";
|
|
6
|
+
import n from "../static/styles/components/button.css.js";
|
|
7
|
+
import s from "../static/styles/components/combobox.css.js";
|
|
8
|
+
import C from "../static/styles/components/counter.css.js";
|
|
9
|
+
import f from "../static/styles/components/dropdown-menu.css.js";
|
|
10
|
+
import a from "../static/styles/components/narrow-panel.css.js";
|
|
11
|
+
import u from "../static/styles/components/switcher.css.js";
|
|
12
|
+
import c from "../static/styles/components/tabs.css.js";
|
|
13
|
+
import d from "../static/styles/components/tools.css.js";
|
|
14
|
+
import l from "../static/styles/components/wide-panel.css.js";
|
|
15
|
+
import h from "../static/styles/variables.css.js";
|
|
16
|
+
const w = [
|
|
17
|
+
h,
|
|
18
|
+
// Must be on top
|
|
19
|
+
S,
|
|
20
|
+
// Must be on top
|
|
21
|
+
e,
|
|
22
|
+
m,
|
|
23
|
+
i,
|
|
24
|
+
p,
|
|
25
|
+
n,
|
|
26
|
+
s,
|
|
27
|
+
C,
|
|
28
|
+
f,
|
|
29
|
+
a,
|
|
30
|
+
u,
|
|
31
|
+
c,
|
|
32
|
+
d,
|
|
33
|
+
l
|
|
34
|
+
].join(`
|
|
35
|
+
|
|
36
|
+
`), N = () => ({ importCss: () => {
|
|
37
|
+
const o = new CSSStyleSheet();
|
|
38
|
+
o.replaceSync(w);
|
|
39
|
+
const r = document.querySelector("ui-editor");
|
|
40
|
+
if (!r)
|
|
7
41
|
return;
|
|
8
|
-
const
|
|
9
|
-
|
|
42
|
+
const t = r.shadowRoot;
|
|
43
|
+
t && (t.adoptedStyleSheets = [o]);
|
|
10
44
|
} });
|
|
11
45
|
export {
|
|
12
|
-
|
|
46
|
+
N as useCustomInterfaceAppearance
|
|
13
47
|
};
|