@useinsider/guido 1.0.3-beta.d6f4719 → 1.0.3-beta.d8a9e56
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 +0 -126
- package/dist/{src/@types → @types}/generic.d.ts +0 -20
- package/dist/{src/components → components}/Guido.vue.d.ts +2 -2
- package/dist/components/Guido.vue.js +7 -7
- package/dist/components/Guido.vue2.js +68 -74
- package/dist/components/organisms/header/LeftSlot.vue.js +1 -1
- package/dist/components/organisms/header/LeftSlot.vue2.js +15 -16
- package/dist/components/organisms/header/RightSlot.vue.js +5 -5
- package/dist/components/organisms/header/RightSlot.vue2.js +19 -20
- package/dist/{src/components → components}/wrappers/WpDrawer.vue.d.ts +4 -6
- package/dist/components/wrappers/WpDrawer.vue.js +4 -6
- package/dist/{src/composables → composables}/usePartner.d.ts +0 -1
- package/dist/composables/usePartner.js +5 -9
- package/dist/composables/useStripo.js +42 -40
- package/dist/config/compiler/unsubscribeCompilerRules.js +29 -42
- package/dist/config/migrator/index.d.ts +1 -0
- package/dist/config/migrator/index.js +6 -7
- package/dist/enums/defaults.js +7 -15
- package/dist/enums/unsubscribe.d.ts +15 -0
- package/dist/enums/unsubscribe.js +6 -43
- package/dist/extensions/Blocks/Checkbox/control.js +53 -55
- package/dist/extensions/Blocks/RadioButton/control.js +42 -44
- package/dist/extensions/Blocks/RadioButton/template.js +6 -6
- package/dist/guido.css +1 -1
- package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +71 -83
- package/dist/{src/stores → stores}/editor.d.ts +0 -21
- package/dist/stores/editor.js +1 -2
- package/dist/stores/unsubscribe.d.ts +8 -0
- package/dist/stores/unsubscribe.js +6 -126
- package/dist/{src/utils → utils}/genericUtil.d.ts +0 -1
- package/dist/utils/genericUtil.js +7 -8
- package/dist/utils/templatePreparation.js +16 -17
- package/package.json +2 -7
- package/dist/components/organisms/extensions/recommendation/FilterItem.vue.js +0 -28
- package/dist/components/organisms/extensions/recommendation/FilterItem.vue2.js +0 -38
- package/dist/components/organisms/extensions/recommendation/FilterSelectionDrawer.vue.js +0 -17
- package/dist/components/organisms/extensions/recommendation/FilterSelectionDrawer.vue2.js +0 -37
- package/dist/components/organisms/extensions/recommendation/Filters.vue.js +0 -20
- package/dist/components/organisms/extensions/recommendation/Filters.vue2.js +0 -44
- package/dist/components/organisms/extensions/recommendation/LogicAdapter.vue.js +0 -17
- package/dist/components/organisms/extensions/recommendation/LogicAdapter.vue2.js +0 -27
- package/dist/components/organisms/unsubscribe/UnsubscribeBreadcrumb.vue.js +0 -18
- package/dist/components/organisms/unsubscribe/UnsubscribeBreadcrumb.vue2.js +0 -16
- package/dist/components/organisms/unsubscribe/UnsubscribePageSelection.vue.js +0 -24
- package/dist/components/organisms/unsubscribe/UnsubscribePageSelection.vue2.js +0 -64
- package/dist/components/organisms/unsubscribe/UnsubscribeTypeSelection.vue.js +0 -18
- package/dist/components/organisms/unsubscribe/UnsubscribeTypeSelection.vue2.js +0 -107
- package/dist/components/organisms/unsubscribe/UnsubscribeWrapper.vue.js +0 -18
- package/dist/components/organisms/unsubscribe/UnsubscribeWrapper.vue2.js +0 -12
- package/dist/composables/useBlocksConfig.js +0 -58
- package/dist/config/migrator/unsubscribeMigrator.js +0 -124
- package/dist/enums/extensions/recommendationBlock.js +0 -80
- package/dist/extensions/Blocks/Recommendation/block.js +0 -27
- package/dist/extensions/Blocks/Recommendation/control.js +0 -277
- package/dist/extensions/Blocks/Recommendation/extension.js +0 -10
- package/dist/extensions/Blocks/Recommendation/iconsRegistry.js +0 -51
- package/dist/extensions/Blocks/Recommendation/recommendation.css.js +0 -19
- package/dist/extensions/Blocks/Recommendation/settingsPanel.js +0 -32
- package/dist/extensions/Blocks/Recommendation/store/recommendation.js +0 -266
- package/dist/extensions/Blocks/Recommendation/template.js +0 -200
- package/dist/extensions/Blocks/Recommendation/utils/filterUtil.js +0 -28
- package/dist/extensions/Blocks/Unsubscribe/block.js +0 -131
- package/dist/extensions/Blocks/Unsubscribe/control.js +0 -167
- package/dist/extensions/Blocks/Unsubscribe/elements/preview.js +0 -42
- package/dist/extensions/Blocks/Unsubscribe/extension.js +0 -21
- package/dist/extensions/Blocks/Unsubscribe/iconsRegistry.js +0 -21
- package/dist/extensions/Blocks/Unsubscribe/settingsPanel.js +0 -35
- package/dist/extensions/Blocks/Unsubscribe/styles.css.js +0 -42
- package/dist/extensions/Blocks/Unsubscribe/tagRegistry.js +0 -10
- package/dist/extensions/Blocks/Unsubscribe/template.js +0 -22
- package/dist/extensions/Blocks/Unsubscribe/utils/constants.js +0 -11
- package/dist/extensions/Blocks/Unsubscribe/utils/utils.js +0 -6
- package/dist/extensions/Blocks/common-control.js +0 -102
- package/dist/package.json.js +0 -7
- package/dist/services/recommendationApi.js +0 -43
- package/dist/services/unsubscribeApi.js +0 -16
- package/dist/src/components/organisms/extensions/recommendation/FilterItem.vue.d.ts +0 -19
- package/dist/src/components/organisms/extensions/recommendation/FilterSelectionDrawer.vue.d.ts +0 -2
- package/dist/src/components/organisms/extensions/recommendation/Filters.vue.d.ts +0 -2
- package/dist/src/components/organisms/extensions/recommendation/LogicAdapter.vue.d.ts +0 -16
- package/dist/src/components/organisms/unsubscribe/UnsubscribeBreadcrumb.vue.d.ts +0 -2
- package/dist/src/components/organisms/unsubscribe/UnsubscribePageSelection.vue.d.ts +0 -2
- package/dist/src/components/organisms/unsubscribe/UnsubscribeTypeSelection.vue.d.ts +0 -2
- package/dist/src/components/organisms/unsubscribe/UnsubscribeWrapper.vue.d.ts +0 -2
- package/dist/src/composables/useBlocksConfig.d.ts +0 -11
- package/dist/src/config/migrator/index.d.ts +0 -1
- package/dist/src/config/migrator/unsubscribeMigrator.d.ts +0 -1
- package/dist/src/enums/extensions/recommendationBlock.d.ts +0 -16
- package/dist/src/enums/unsubscribe.d.ts +0 -38
- package/dist/src/extensions/Blocks/Recommendation/block.d.ts +0 -10
- package/dist/src/extensions/Blocks/Recommendation/control.d.ts +0 -29
- package/dist/src/extensions/Blocks/Recommendation/iconsRegistry.d.ts +0 -4
- package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +0 -555
- package/dist/src/extensions/Blocks/Recommendation/template.d.ts +0 -6
- package/dist/src/extensions/Blocks/Recommendation/utils/filterUtil.d.ts +0 -7
- package/dist/src/extensions/Blocks/Unsubscribe/block.d.ts +0 -32
- package/dist/src/extensions/Blocks/Unsubscribe/control.d.ts +0 -29
- package/dist/src/extensions/Blocks/Unsubscribe/elements/preview.d.ts +0 -11
- package/dist/src/extensions/Blocks/Unsubscribe/iconsRegistry.d.ts +0 -4
- package/dist/src/extensions/Blocks/Unsubscribe/settingsPanel.d.ts +0 -4
- package/dist/src/extensions/Blocks/Unsubscribe/tagRegistry.d.ts +0 -4
- package/dist/src/extensions/Blocks/Unsubscribe/template.d.ts +0 -12
- package/dist/src/extensions/Blocks/Unsubscribe/utils/constants.d.ts +0 -9
- package/dist/src/extensions/Blocks/Unsubscribe/utils/utils.d.ts +0 -7
- package/dist/src/extensions/Blocks/_Boilerplate/extension.d.ts +0 -2
- package/dist/src/extensions/Blocks/_Boilerplate/settingsPanel.d.ts +0 -4
- package/dist/src/extensions/Blocks/common-control.d.ts +0 -66
- package/dist/src/extensions/DynamicContent/extension.d.ts +0 -2
- package/dist/src/mock/api/recommendation.d.ts +0 -2
- package/dist/src/services/recommendationApi.d.ts +0 -6
- package/dist/src/services/unsubscribeApi.d.ts +0 -4
- package/dist/src/stores/config.d.ts +0 -100
- package/dist/src/stores/unsubscribe.d.ts +0 -256
- package/dist/stores/config.js +0 -17
- package/dist/{src/@types → @types}/events.d.ts +0 -0
- package/dist/{src/@types → @types}/save-as-template.d.ts +0 -0
- package/dist/{src/App.vue.d.ts → App.vue.d.ts} +0 -0
- package/dist/{src/components → components}/organisms/LoadingWrapper.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/base/Toaster.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/PreviewContainer.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/amp/AmpErrorModal.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/amp/AmpToggle.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/desktop-preview/DesktopPreview.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/desktop-preview/EmailHeaderInfo.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/desktop-preview/EmailSizeIndicator.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/mobile-preview/ContentView.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/mobile-preview/InboxView.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/email-preview/mobile-preview/MobilePreview.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/HeaderWrapper.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/LeftSlot.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/MiddleSlot.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/RightSlot.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/ViewOptions.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/version-history/RestoreButton.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/version-history/VersionHistory.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/version-history/VersionHistoryItem.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/header/version-history/ViewOptions.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/AMPOnboarding.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/GenericOnboarding.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/NewVersionPopup.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/OnboardingWrapper.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/TextBlockOnboarding.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/onboarding/VersionHistoryOnboarding.vue.d.ts +0 -0
- package/dist/{src/components → components}/organisms/save-as-template/SaveAsTemplateDrawer.vue.d.ts +0 -0
- package/dist/{src/components → components}/wrappers/WpModal.vue.d.ts +1 -1
- /package/dist/{src/composables → composables}/useActionsApi.d.ts +0 -0
- /package/dist/{src/composables → composables}/useApiExample.d.ts +0 -0
- /package/dist/{src/composables → composables}/useCodeEditorApi.d.ts +0 -0
- /package/dist/{src/composables → composables}/useConfig.d.ts +0 -0
- /package/dist/{src/composables → composables}/useCustomInterfaceAppearance.d.ts +0 -0
- /package/dist/{src/composables → composables}/useDebounce.d.ts +0 -0
- /package/dist/{src/composables → composables}/useExport.d.ts +0 -0
- /package/dist/{src/composables → composables}/useGuidoActions.d.ts +0 -0
- /package/dist/{src/composables → composables}/useHtmlCompiler.d.ts +0 -0
- /package/dist/{src/composables → composables}/useHtmlValidator.d.ts +0 -0
- /package/dist/{src/composables → composables}/useHttp.d.ts +0 -0
- /package/dist/{src/composables → composables}/usePreviewMode.d.ts +0 -0
- /package/dist/{src/composables → composables}/useProvideInject.d.ts +0 -0
- /package/dist/{src/composables → composables}/useRecommendation.d.ts +0 -0
- /package/dist/{src/composables → composables}/useResponsivePreview.d.ts +0 -0
- /package/dist/{src/composables → composables}/useSave.d.ts +0 -0
- /package/dist/{src/composables → composables}/useStripo.d.ts +0 -0
- /package/dist/{src/composables → composables}/useStripoEventHandler.d.ts +0 -0
- /package/dist/{src/composables → composables}/useToaster.d.ts +0 -0
- /package/dist/{src/composables → composables}/useTranslations.d.ts +0 -0
- /package/dist/{src/composables → composables}/useValidation.d.ts +0 -0
- /package/dist/{src/composables → composables}/useVersionHistoryApi.d.ts +0 -0
- /package/dist/{src/composables → composables}/validators/saveAsTemplate.d.ts +0 -0
- /package/dist/{src/config → config}/compiler/htmlCompilerRules.d.ts +0 -0
- /package/dist/{src/config → config}/compiler/outlookCompilerRules.d.ts +0 -0
- /package/dist/{src/config → config}/compiler/recommendationCompilerRules.d.ts +0 -0
- /package/dist/{src/config → config}/compiler/socialCompilerRules.d.ts +0 -0
- /package/dist/{src/config → config}/compiler/unsubscribeCompilerRules.d.ts +0 -0
- /package/dist/{src/config → config}/migrator/checkboxMigrator.d.ts +0 -0
- /package/dist/{src/config → config}/migrator/couponBlockMigrator.d.ts +0 -0
- /package/dist/{src/config → config}/migrator/radioButtonMigrator.d.ts +0 -0
- /package/dist/{src/enums → enums}/defaults.d.ts +0 -0
- /package/dist/{src/enums → enums}/displayConditions.d.ts +0 -0
- /package/dist/{src/enums → enums}/html-validator.d.ts +0 -0
- /package/dist/{src/enums → enums}/onboarding.d.ts +0 -0
- /package/dist/{src/enums → enums}/preview.d.ts +0 -0
- /package/dist/{src/enums → enums}/recommendation.d.ts +0 -0
- /package/dist/{src/enums → enums}/toaster.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/block.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/control.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/extension.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/iconsRegistry.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/settingsPanel.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/Checkbox/template.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/CouponBlock/block.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/CouponBlock/extension.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/CouponBlock/iconsRegistry.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/CouponBlock/settingsPanel.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/CouponBlock/template.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/block.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/control.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/extension.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/iconsRegistry.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/settingsPanel.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/RadioButton/template.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/_Boilerplate/block.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/_Boilerplate/control.d.ts +0 -0
- /package/dist/{src/extensions/Blocks/Recommendation → extensions/Blocks/_Boilerplate}/extension.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/_Boilerplate/iconsRegistry.d.ts +0 -0
- /package/dist/{src/extensions/Blocks/Recommendation → extensions/Blocks/_Boilerplate}/settingsPanel.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/Blocks/_Boilerplate/template.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/DynamicContent/dynamic-content-modal.d.ts +0 -0
- /package/dist/{src/extensions → extensions}/DynamicContent/dynamic-content.d.ts +0 -0
- /package/dist/{src/extensions/Blocks/Unsubscribe → extensions/DynamicContent}/extension.d.ts +0 -0
- /package/dist/{src/library.d.ts → library.d.ts} +0 -0
- /package/dist/{src/main.d.ts → main.d.ts} +0 -0
- /package/dist/{src/mock → mock}/api/auth.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/custom-fonts.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/default-template.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/template-library.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/unsubscribe.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/user-modal-state.d.ts +0 -0
- /package/dist/{src/mock → mock}/api/validator.d.ts +0 -0
- /package/dist/{src/mock → mock}/browser.d.ts +0 -0
- /package/dist/{src/mock → mock}/handlers.d.ts +0 -0
- /package/dist/{src/services → services}/onboardingApi.d.ts +0 -0
- /package/dist/{src/services → services}/stripoApi.d.ts +0 -0
- /package/dist/{src/services → services}/templateLibraryApi.d.ts +0 -0
- /package/dist/{src/stores → stores}/dynamic-content.d.ts +0 -0
- /package/dist/{src/stores → stores}/onboarding.d.ts +0 -0
- /package/dist/{src/stores → stores}/preview.d.ts +0 -0
- /package/dist/{src/stores → stores}/recommendation.d.ts +0 -0
- /package/dist/{src/stores → stores}/save-as-template.d.ts +0 -0
- /package/dist/{src/stores → stores}/toaster.d.ts +0 -0
- /package/dist/{src/stores → stores}/version-history.d.ts +0 -0
- /package/dist/{src/utils → utils}/arrayUtil.d.ts +0 -0
- /package/dist/{src/utils → utils}/base64.d.ts +0 -0
- /package/dist/{src/utils → utils}/dateUtil.d.ts +0 -0
- /package/dist/{src/utils → utils}/htmlCompiler.d.ts +0 -0
- /package/dist/{src/utils → utils}/templatePreparation.d.ts +0 -0
- /package/dist/{src/utils → utils}/tooltipUtils.d.ts +0 -0
package/README.md
CHANGED
|
@@ -191,10 +191,6 @@ interface GuidoConfig {
|
|
|
191
191
|
saveAsTemplate: boolean;
|
|
192
192
|
versionHistory: boolean;
|
|
193
193
|
};
|
|
194
|
-
blocks?: {
|
|
195
|
-
excludeDefaults?: GuidoBlockType[];
|
|
196
|
-
includeCustoms?: GuidoCustomBlockType[];
|
|
197
|
-
};
|
|
198
194
|
}
|
|
199
195
|
```
|
|
200
196
|
|
|
@@ -208,9 +204,6 @@ interface GuidoConfig {
|
|
|
208
204
|
| `features.dynamicContent` | `boolean` | `true` | Enable dynamic content insertion feature |
|
|
209
205
|
| `features.saveAsTemplate` | `boolean` | `true` | Enable save as template feature |
|
|
210
206
|
| `features.versionHistory` | `boolean` | `true` | Enable version history feature |
|
|
211
|
-
| `blocks` | `BlocksConfig` | `{ excludeDefaults: [], includeCustoms: [] }` | Block configuration for excluding default blocks and including custom blocks. See [Blocks Configuration](#-blocks-configuration) section below |
|
|
212
|
-
| `blocks.excludeDefaults` | `GuidoBlockType[]` | `[]` | Array of default Stripo blocks to exclude from the editor |
|
|
213
|
-
| `blocks.includeCustoms` | `GuidoCustomBlockType[]` | `[]` | Array of custom blocks to include in the editor |
|
|
214
207
|
|
|
215
208
|
```typescript
|
|
216
209
|
interface DynamicContent {
|
|
@@ -227,125 +220,6 @@ interface DynamicContent {
|
|
|
227
220
|
| `text` | `string` | '' | Visible value of the dynamic content |
|
|
228
221
|
| `fallback?` | `string` | '' | Fallback value of the dynamic content. Optional |
|
|
229
222
|
|
|
230
|
-
## 🧱 Blocks Configuration
|
|
231
|
-
|
|
232
|
-
Guido allows you to customize which blocks are available in the editor. You can exclude default Stripo blocks and selectively include custom blocks to create tailored editing experiences for different product types.
|
|
233
|
-
|
|
234
|
-
### Block Types
|
|
235
|
-
|
|
236
|
-
#### Default Blocks (GuidoBlockType)
|
|
237
|
-
|
|
238
|
-
These are the standard Stripo email editor blocks that can be excluded:
|
|
239
|
-
|
|
240
|
-
```typescript
|
|
241
|
-
type GuidoBlockType =
|
|
242
|
-
| 'amp-accordion' // AMP accordion component
|
|
243
|
-
| 'amp-carousel' // AMP image carousel
|
|
244
|
-
| 'amp-form-controls' // AMP form elements
|
|
245
|
-
| 'banner-block' // Banner/hero section
|
|
246
|
-
| 'button-block' // Call-to-action buttons
|
|
247
|
-
| 'html-block' // Custom HTML
|
|
248
|
-
| 'image-block' // Image elements
|
|
249
|
-
| 'menu-block' // Navigation menu
|
|
250
|
-
| 'social-block' // Social media links
|
|
251
|
-
| 'spacer-block' // Vertical spacing
|
|
252
|
-
| 'text-block' // Text content
|
|
253
|
-
| 'timer-block' // Countdown timer
|
|
254
|
-
| 'video-block' // Video embeds
|
|
255
|
-
```
|
|
256
|
-
|
|
257
|
-
#### Custom Blocks (GuidoCustomBlockType)
|
|
258
|
-
|
|
259
|
-
These are custom blocks that can be selectively included:
|
|
260
|
-
|
|
261
|
-
```typescript
|
|
262
|
-
type GuidoCustomBlockType =
|
|
263
|
-
| 'dynamic-content' // Dynamic content merge tags
|
|
264
|
-
| 'checkbox-block' // Checkbox form input
|
|
265
|
-
| 'radio-button-block' // Radio button form input
|
|
266
|
-
| 'recommendation-block' // Product recommendations
|
|
267
|
-
| 'unsubscribe-block' // Unsubscribe link
|
|
268
|
-
| 'coupon-block' // Coupon/promo code
|
|
269
|
-
| 'items-block' // Cart items display
|
|
270
|
-
```
|
|
271
|
-
|
|
272
|
-
### Configuration Examples
|
|
273
|
-
|
|
274
|
-
#### Example 1: Exclude Specific Default Blocks
|
|
275
|
-
|
|
276
|
-
Disable button, image, and video blocks while keeping all custom blocks:
|
|
277
|
-
|
|
278
|
-
```typescript
|
|
279
|
-
const guidoConfig = {
|
|
280
|
-
translationsPath: 'window.trans.en',
|
|
281
|
-
features: {
|
|
282
|
-
dynamicContent: true,
|
|
283
|
-
saveAsTemplate: true,
|
|
284
|
-
versionHistory: true
|
|
285
|
-
},
|
|
286
|
-
blocks: {
|
|
287
|
-
excludeDefaults: ['button-block', 'image-block', 'video-block']
|
|
288
|
-
}
|
|
289
|
-
};
|
|
290
|
-
```
|
|
291
|
-
|
|
292
|
-
**Result:**
|
|
293
|
-
- Button, Image, Video blocks disabled
|
|
294
|
-
- All other default blocks enabled
|
|
295
|
-
- All custom blocks are disabled.
|
|
296
|
-
|
|
297
|
-
#### Example 2: Include Only Specific Custom Blocks
|
|
298
|
-
|
|
299
|
-
Enable only coupon and recommendation blocks:
|
|
300
|
-
|
|
301
|
-
```typescript
|
|
302
|
-
const guidoConfig = {
|
|
303
|
-
translationsPath: 'window.trans.en',
|
|
304
|
-
features: {
|
|
305
|
-
dynamicContent: true,
|
|
306
|
-
saveAsTemplate: true,
|
|
307
|
-
versionHistory: true
|
|
308
|
-
},
|
|
309
|
-
blocks: {
|
|
310
|
-
includeCustoms: ['coupon-block', 'recommendation-block']
|
|
311
|
-
}
|
|
312
|
-
};
|
|
313
|
-
```
|
|
314
|
-
|
|
315
|
-
**Result:**
|
|
316
|
-
- All default blocks enabled
|
|
317
|
-
- Only Coupon and Recommendation extensions enabled.
|
|
318
|
-
- Other custom blocks are disabled
|
|
319
|
-
|
|
320
|
-
### Default Behavior
|
|
321
|
-
|
|
322
|
-
When `blocks` is not provided or is `undefined`:
|
|
323
|
-
|
|
324
|
-
```typescript
|
|
325
|
-
const guidoConfig = {
|
|
326
|
-
translationsPath: 'window.trans.en',
|
|
327
|
-
features: {
|
|
328
|
-
dynamicContent: true,
|
|
329
|
-
saveAsTemplate: true,
|
|
330
|
-
versionHistory: true
|
|
331
|
-
}
|
|
332
|
-
// No blocks config
|
|
333
|
-
};
|
|
334
|
-
```
|
|
335
|
-
|
|
336
|
-
**Result:**
|
|
337
|
-
- All 13 default Stripo blocks enabled
|
|
338
|
-
- All custom blocks are disabled.
|
|
339
|
-
|
|
340
|
-
### Block Configuration Interface
|
|
341
|
-
|
|
342
|
-
```typescript
|
|
343
|
-
interface BlocksConfig {
|
|
344
|
-
excludeDefaults?: GuidoBlockType[];
|
|
345
|
-
includeCustoms?: GuidoCustomBlockType[];
|
|
346
|
-
}
|
|
347
|
-
```
|
|
348
|
-
|
|
349
223
|
### TypeScript Types
|
|
350
224
|
|
|
351
225
|
The library exports the following TypeScript types:
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import type { CompilerRule } from './html-compiler';
|
|
2
|
-
type Extensions = {
|
|
3
|
-
unsubscribe?: boolean;
|
|
4
|
-
};
|
|
5
2
|
type Features = {
|
|
6
3
|
dynamicContent?: boolean;
|
|
7
4
|
saveAsTemplate?: boolean;
|
|
@@ -12,12 +9,6 @@ type Partner = {
|
|
|
12
9
|
productType: number;
|
|
13
10
|
messageType: number;
|
|
14
11
|
};
|
|
15
|
-
export type GuidoBlockType = 'amp-accordion' | 'amp-carousel' | 'amp-form-controls' | 'banner-block' | 'button-block' | 'html-block' | 'image-block' | 'menu-block' | 'social-block' | 'spacer-block' | 'text-block' | 'timer-block' | 'video-block';
|
|
16
|
-
export type GuidoCustomBlockType = 'dynamic-content' | 'checkbox-block' | 'radio-button-block' | 'recommendation-block' | 'unsubscribe-block' | 'coupon-block' | 'items-block';
|
|
17
|
-
type BlocksConfig = {
|
|
18
|
-
excludeDefaults?: GuidoBlockType[];
|
|
19
|
-
includeCustoms?: GuidoCustomBlockType[];
|
|
20
|
-
};
|
|
21
12
|
export type GuidoConfig = {
|
|
22
13
|
translationsPath: string;
|
|
23
14
|
htmlCompilerRules?: CompilerRule[];
|
|
@@ -25,14 +16,7 @@ export type GuidoConfig = {
|
|
|
25
16
|
useHeader?: boolean;
|
|
26
17
|
emailHeader: EmailHeader;
|
|
27
18
|
partner?: Partner;
|
|
28
|
-
extensions?: Extensions;
|
|
29
19
|
features?: Features;
|
|
30
|
-
blocks?: BlocksConfig;
|
|
31
|
-
};
|
|
32
|
-
export type TemplateConfig = {
|
|
33
|
-
preselectedDynamicContentList?: DynamicContent[];
|
|
34
|
-
selectedUnsubscribePages?: number[];
|
|
35
|
-
variationId?: string;
|
|
36
20
|
};
|
|
37
21
|
export type DynamicContent = {
|
|
38
22
|
value: string;
|
|
@@ -62,8 +46,4 @@ export type MergeTag = {
|
|
|
62
46
|
label: string;
|
|
63
47
|
value: string;
|
|
64
48
|
};
|
|
65
|
-
export type TextValueObject = {
|
|
66
|
-
text: string;
|
|
67
|
-
value: string;
|
|
68
|
-
};
|
|
69
49
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { DynamicContent, GuidoConfig
|
|
1
|
+
import type { DynamicContent, GuidoConfig } from '@@/Types/generic';
|
|
2
2
|
import type { SavedTemplateDetails } from '@@/Types/stripo';
|
|
3
3
|
type __VLS_Props = {
|
|
4
4
|
templateId: string;
|
|
@@ -9,8 +9,8 @@ type __VLS_Props = {
|
|
|
9
9
|
username?: string;
|
|
10
10
|
html?: string;
|
|
11
11
|
css?: string;
|
|
12
|
+
preselectedDynamicContentList: DynamicContent[];
|
|
12
13
|
guidoConfig: GuidoConfig;
|
|
13
|
-
templateConfig?: TemplateConfig;
|
|
14
14
|
};
|
|
15
15
|
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {
|
|
16
16
|
dynamicContent: {
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
1
|
+
import o from "./Guido.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import i from "../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var t = function() {
|
|
5
|
-
var
|
|
6
|
-
return r("div", { staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper, { ref: "headerWrapperRef" }), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) :
|
|
5
|
+
var a = this, r = a._self._c, e = a._self._setupProxy;
|
|
6
|
+
return r("div", { staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper, { ref: "headerWrapperRef" }), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) : a._e(), r("div", { directives: [{ name: "show", rawName: "v-show", value: !e.previewStore.isLoaded, expression: "!previewStore.isLoaded" }], staticClass: "guido-editor__container", class: { "guido-editor__no-header": e.noHeader }, attrs: { id: "guido-editor" } }), r(e.Toaster), r(e.SaveAsTemplateDrawer), e.isTestPartner() ? a._e() : r(e.OnboardingWrapper), r(e.LoadingWrapper)], 1);
|
|
7
7
|
}, s = [], d = /* @__PURE__ */ i(
|
|
8
|
-
|
|
8
|
+
o,
|
|
9
9
|
t,
|
|
10
10
|
s,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"aca05338"
|
|
14
14
|
);
|
|
15
|
-
const
|
|
15
|
+
const v = d.exports;
|
|
16
16
|
export {
|
|
17
|
-
|
|
17
|
+
v as default
|
|
18
18
|
};
|
|
@@ -1,23 +1,19 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { provideGuidoActions as
|
|
3
|
-
import { usePartner as
|
|
4
|
-
import { useStripo as
|
|
5
|
-
import { migrate as
|
|
6
|
-
import { DefaultUsername as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import
|
|
16
|
-
|
|
17
|
-
import { usePreviewStore as ae } from "../stores/preview.js";
|
|
18
|
-
import { useUnsubscribeStore as se } from "../stores/unsubscribe.js";
|
|
19
|
-
import ie from "../node_modules/lodash-es/merge.js";
|
|
20
|
-
const Ge = /* @__PURE__ */ R({
|
|
1
|
+
import { defineComponent as H, defineAsyncComponent as E, ref as R, computed as G, watch as U, onMounted as x, onUnmounted as F } from "vue";
|
|
2
|
+
import { provideGuidoActions as M } from "../composables/useGuidoActions.js";
|
|
3
|
+
import { usePartner as z } from "../composables/usePartner.js";
|
|
4
|
+
import { useStripo as B } from "../composables/useStripo.js";
|
|
5
|
+
import { migrate as P } from "../config/migrator/index.js";
|
|
6
|
+
import { DefaultUsername as K, DefaultMessageType as O, DefaultGuidoConfig as j } from "../enums/defaults.js";
|
|
7
|
+
import q from "./organisms/base/Toaster.vue.js";
|
|
8
|
+
import J from "./organisms/header/HeaderWrapper.vue.js";
|
|
9
|
+
import Q from "./organisms/LoadingWrapper.vue.js";
|
|
10
|
+
import V from "./organisms/save-as-template/SaveAsTemplateDrawer.vue.js";
|
|
11
|
+
import { useStripoApi as X } from "../services/stripoApi.js";
|
|
12
|
+
import { useDynamicContentStore as Y } from "../stores/dynamic-content.js";
|
|
13
|
+
import { useEditorStore as Z } from "../stores/editor.js";
|
|
14
|
+
import { usePreviewStore as $ } from "../stores/preview.js";
|
|
15
|
+
import ee from "../node_modules/lodash-es/merge.js";
|
|
16
|
+
const ye = /* @__PURE__ */ H({
|
|
21
17
|
__name: "Guido",
|
|
22
18
|
props: {
|
|
23
19
|
templateId: null,
|
|
@@ -28,86 +24,84 @@ const Ge = /* @__PURE__ */ R({
|
|
|
28
24
|
username: null,
|
|
29
25
|
html: null,
|
|
30
26
|
css: null,
|
|
31
|
-
|
|
32
|
-
|
|
27
|
+
preselectedDynamicContentList: null,
|
|
28
|
+
guidoConfig: null
|
|
33
29
|
},
|
|
34
30
|
emits: ["dynamic-content:open", "back", "save:start", "save:complete", "on-change", "ready"],
|
|
35
|
-
setup(
|
|
36
|
-
const
|
|
31
|
+
setup(I, { expose: L, emit: o }) {
|
|
32
|
+
const r = I, _ = E(
|
|
37
33
|
() => import("./organisms/email-preview/PreviewContainer.vue.js")
|
|
38
|
-
),
|
|
34
|
+
), W = E(
|
|
39
35
|
() => import("./organisms/onboarding/OnboardingWrapper.vue.js")
|
|
40
|
-
),
|
|
36
|
+
), d = R(), a = Y(), m = Z(), k = $(), t = G(() => m.hasChanges), i = r.preselectedDynamicContentList || [], { getPartnerName: l, getProductType: u, isTestPartner: A } = z(), p = () => {
|
|
41
37
|
var e;
|
|
42
|
-
return (e =
|
|
38
|
+
return (e = d.value) == null ? void 0 : e.handleSave(!0);
|
|
43
39
|
}, {
|
|
44
|
-
templateId:
|
|
45
|
-
userId:
|
|
46
|
-
guidoConfig:
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
preselectedDynamicContentList: d,
|
|
40
|
+
templateId: g,
|
|
41
|
+
userId: f,
|
|
42
|
+
guidoConfig: y,
|
|
43
|
+
html: n = "",
|
|
44
|
+
css: v = "",
|
|
45
|
+
partnerName: s = l(),
|
|
46
|
+
productType: c = u(),
|
|
47
|
+
messageType: C = O,
|
|
48
|
+
username: h = K
|
|
49
|
+
} = r;
|
|
50
|
+
window.GuidoConfig = ee(j, y), window.GuidoConfig.partner = {
|
|
51
|
+
partnerName: s,
|
|
52
|
+
productType: c,
|
|
53
|
+
messageType: C
|
|
54
|
+
};
|
|
55
|
+
const { initPlugin: w } = B({
|
|
56
|
+
emailId: g,
|
|
57
|
+
userId: f,
|
|
58
|
+
username: h,
|
|
59
|
+
partnerName: s,
|
|
60
|
+
productType: c,
|
|
61
|
+
preselectedDynamicContentList: i,
|
|
67
62
|
onReady: () => {
|
|
68
|
-
console.debug("guido:ready"),
|
|
63
|
+
console.debug("guido:ready"), o("ready");
|
|
69
64
|
}
|
|
70
|
-
}), { getDefaultTemplate:
|
|
65
|
+
}), { getDefaultTemplate: S } = X(), N = G(() => {
|
|
71
66
|
var e;
|
|
72
67
|
return !((e = window.GuidoConfig) != null && e.useHeader);
|
|
73
68
|
});
|
|
74
|
-
|
|
69
|
+
M({
|
|
75
70
|
onBack: () => {
|
|
76
|
-
console.debug("guido:back"),
|
|
71
|
+
console.debug("guido:back"), o("back");
|
|
77
72
|
},
|
|
78
73
|
onSaveStart: () => {
|
|
79
|
-
console.debug("guido:save:start"),
|
|
74
|
+
console.debug("guido:save:start"), o("save:start");
|
|
80
75
|
},
|
|
81
76
|
onSaveComplete: (e) => {
|
|
82
|
-
console.debug("guido:save:complete", e),
|
|
77
|
+
console.debug("guido:save:complete", e), o("save:complete", e);
|
|
83
78
|
}
|
|
84
79
|
});
|
|
85
|
-
const
|
|
80
|
+
const b = (e) => {
|
|
86
81
|
console.debug("dynamic-content:close", e), a.setSelectedDynamicContent(e), document.dispatchEvent(new CustomEvent("dynamic-content:close", { detail: e }));
|
|
87
|
-
},
|
|
82
|
+
}, D = () => {
|
|
88
83
|
console.debug("dynamic-content:close", "Without Data"), document.dispatchEvent(new CustomEvent("dynamic-content:close", { detail: { text: "", value: "" } }));
|
|
89
84
|
};
|
|
90
|
-
return
|
|
91
|
-
|
|
92
|
-
}),
|
|
85
|
+
return U(() => t.value, () => {
|
|
86
|
+
o("on-change", t.value);
|
|
87
|
+
}), x(async () => {
|
|
93
88
|
console.debug("Guido says happy coding 🎉"), console.debug("🚗 Ka-Chow");
|
|
94
89
|
try {
|
|
95
|
-
p.selectedUnsubscribePages = (o == null ? void 0 : o.selectedUnsubscribePages) || [];
|
|
96
90
|
let e = {
|
|
97
|
-
html:
|
|
98
|
-
css:
|
|
91
|
+
html: n && P(n),
|
|
92
|
+
css: v,
|
|
99
93
|
forceRecreate: !0
|
|
100
94
|
// TODO: It should be false for old templates. We will communicate with Stripo
|
|
101
95
|
};
|
|
102
|
-
e.html || (e = await
|
|
96
|
+
e.html || (e = await S(), e.html = P(e.html)), await w(e), a.selectedDynamicContentList = i;
|
|
103
97
|
} catch (e) {
|
|
104
98
|
console.error("Failed to initialize Stripo editor:", e);
|
|
105
99
|
}
|
|
106
100
|
document.addEventListener("dynamic-content:open", (e) => {
|
|
107
|
-
const
|
|
108
|
-
console.debug("dynamic-content:open",
|
|
101
|
+
const T = e;
|
|
102
|
+
console.debug("dynamic-content:open", T.detail), o("dynamic-content:open", T.detail);
|
|
109
103
|
});
|
|
110
|
-
}),
|
|
104
|
+
}), F(() => {
|
|
111
105
|
try {
|
|
112
106
|
window.UIEditor.removeEditor();
|
|
113
107
|
} catch {
|
|
@@ -115,14 +109,14 @@ const Ge = /* @__PURE__ */ R({
|
|
|
115
109
|
}
|
|
116
110
|
}), L({
|
|
117
111
|
dynamicContent: {
|
|
118
|
-
insert:
|
|
119
|
-
close:
|
|
112
|
+
insert: b,
|
|
113
|
+
close: D
|
|
120
114
|
},
|
|
121
|
-
hasChanges:
|
|
122
|
-
saveSilent:
|
|
123
|
-
}), { __sfc: !0, PreviewContainer:
|
|
115
|
+
hasChanges: t,
|
|
116
|
+
saveSilent: p
|
|
117
|
+
}), { __sfc: !0, PreviewContainer: _, OnboardingWrapper: W, headerWrapperRef: d, dynamicContentStore: a, props: r, editorStore: m, previewStore: k, hasChanges: t, preselectedDynamicContentList: i, getPartnerName: l, getProductType: u, isTestPartner: A, saveSilent: p, templateId: g, userId: f, guidoConfig: y, html: n, css: v, partnerName: s, productType: c, messageType: C, username: h, emit: o, initPlugin: w, getDefaultTemplate: S, noHeader: N, insertDynamicContent: b, closeDynamicContent: D, Toaster: q, HeaderWrapper: J, LoadingWrapper: Q, SaveAsTemplateDrawer: V };
|
|
124
118
|
}
|
|
125
119
|
});
|
|
126
120
|
export {
|
|
127
|
-
|
|
121
|
+
ye as default
|
|
128
122
|
};
|
|
@@ -1,29 +1,28 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as s, computed as c } from "vue";
|
|
2
2
|
import { useBack as m } from "../../../composables/useGuidoActions.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
const h = /* @__PURE__ */ c({
|
|
3
|
+
import { usePreviewMode as a } from "../../../composables/usePreviewMode.js";
|
|
4
|
+
import { useTranslations as p } from "../../../composables/useTranslations.js";
|
|
5
|
+
import { useVersionHistoryApi as u } from "../../../composables/useVersionHistoryApi.js";
|
|
6
|
+
import { useEditorStore as d } from "../../../stores/editor.js";
|
|
7
|
+
import { InButtonV2 as f } from "@useinsider/design-system-vue";
|
|
8
|
+
import l from "./version-history/RestoreButton.vue.js";
|
|
9
|
+
const O = /* @__PURE__ */ s({
|
|
11
10
|
__name: "LeftSlot",
|
|
12
|
-
setup(
|
|
13
|
-
const
|
|
14
|
-
return { __sfc: !0, editorStore:
|
|
15
|
-
if (
|
|
11
|
+
setup(k) {
|
|
12
|
+
const o = d(), r = m(), { closeVersionHistory: t } = u(), { closePreviewMode: i } = a(), e = p(), n = c(() => o.isVersionHistoryOpen || o.isPreviewModeOpen ? e("email-editor.back-to-editor") : e("email-editor.back-to-design"));
|
|
13
|
+
return { __sfc: !0, editorStore: o, handleBack: r, closeVersionHistory: t, closePreviewMode: i, trans: e, backButtonLabel: n, handleBackClick: () => {
|
|
14
|
+
if (o.isVersionHistoryOpen) {
|
|
16
15
|
t();
|
|
17
16
|
return;
|
|
18
17
|
}
|
|
19
|
-
if (
|
|
18
|
+
if (o.isPreviewModeOpen) {
|
|
20
19
|
i();
|
|
21
20
|
return;
|
|
22
21
|
}
|
|
23
22
|
r();
|
|
24
|
-
}, InButtonV2:
|
|
23
|
+
}, InButtonV2: f, RestoreButton: l };
|
|
25
24
|
}
|
|
26
25
|
});
|
|
27
26
|
export {
|
|
28
|
-
|
|
27
|
+
O as default
|
|
29
28
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import n from "./RightSlot.vue2.js";
|
|
2
2
|
import a from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
3
|
var l = function() {
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
return e("div", { staticClass: "d-f" }, [(
|
|
4
|
+
var s, i;
|
|
5
|
+
var o = this, e = o._self._c, t = o._self._setupProxy;
|
|
6
|
+
return e("div", { staticClass: "d-f" }, [(s = t.config.features) != null && s.versionHistory ? e(t.InButtonV2, { attrs: { id: "guido__history-button", "left-icon": "line-architect-version-history", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isVersionHistoryOpen, "tooltip-options": t.getTooltipOptions("guido__history-button"), "tooltip-text": t.versionHistoryTooltipText }, on: { click: t.handleVersionHistory } }) : o._e(), e(t.InButtonV2, { attrs: { id: "guido__export-button", "left-icon": "line-export", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isExportButtonDisabled, "label-text-status": !1, "loading-status": t.isExporting, "tooltip-options": t.getTooltipOptions("guido__export-button"), "tooltip-text": t.trans("newsletter.export") }, on: { click: t.handleExport } }), (i = t.config.features) != null && i.saveAsTemplate ? e(t.InButtonV2, { attrs: { id: "guido__save-as-button", "left-icon": "line-newsletter-save-as-template", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isSaveAsButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__save-as-button"), "tooltip-text": t.trans("newsletter.save-templates") }, on: { click: t.handleSaveAs } }) : o._e(), e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isTestButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__test-button"), "tooltip-text": t.trans("newsletter.test-email") } }), e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "loading-status": t.isSaving }, on: { click: function(p) {
|
|
7
7
|
return t.handleSave(!1);
|
|
8
8
|
} } })], 1);
|
|
9
|
-
}, r = [],
|
|
9
|
+
}, r = [], d = /* @__PURE__ */ a(
|
|
10
10
|
n,
|
|
11
11
|
l,
|
|
12
12
|
r,
|
|
@@ -14,7 +14,7 @@ var l = function() {
|
|
|
14
14
|
null,
|
|
15
15
|
null
|
|
16
16
|
);
|
|
17
|
-
const g =
|
|
17
|
+
const g = d.exports;
|
|
18
18
|
export {
|
|
19
19
|
g as default
|
|
20
20
|
};
|
|
@@ -1,36 +1,35 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useConfig as
|
|
3
|
-
import { useExport as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
|
|
11
|
-
const F = /* @__PURE__ */ H({
|
|
1
|
+
import { defineComponent as g, ref as l, computed as H } from "vue";
|
|
2
|
+
import { useConfig as _ } from "../../../composables/useConfig.js";
|
|
3
|
+
import { useExport as h } from "../../../composables/useExport.js";
|
|
4
|
+
import { useSave as V } from "../../../composables/useSave.js";
|
|
5
|
+
import { useTranslations as x } from "../../../composables/useTranslations.js";
|
|
6
|
+
import { useVersionHistoryApi as w } from "../../../composables/useVersionHistoryApi.js";
|
|
7
|
+
import { useEditorStore as T } from "../../../stores/editor.js";
|
|
8
|
+
import { getTooltipOptions as E } from "../../../utils/tooltipUtils.js";
|
|
9
|
+
import { InButtonV2 as O } from "@useinsider/design-system-vue";
|
|
10
|
+
const z = /* @__PURE__ */ g({
|
|
12
11
|
__name: "RightSlot",
|
|
13
|
-
setup(
|
|
14
|
-
const { config: u } =
|
|
12
|
+
setup(A, { expose: m }) {
|
|
13
|
+
const { config: u } = _(), { exportHtml: r } = h(), { save: n } = V(), { openVersionHistory: i, closeVersionHistory: a } = w(), o = T(), t = x(), e = l(!1), s = l(!1), c = () => {
|
|
15
14
|
if (o.isVersionHistoryOpen) {
|
|
16
15
|
a();
|
|
17
16
|
return;
|
|
18
17
|
}
|
|
19
18
|
i();
|
|
20
|
-
},
|
|
19
|
+
}, f = async () => {
|
|
21
20
|
e.value = !0, await r(), e.value = !1;
|
|
22
|
-
},
|
|
21
|
+
}, v = () => {
|
|
23
22
|
o.isSaveAsTemplateDrawerOpen = !0;
|
|
24
|
-
},
|
|
23
|
+
}, d = H(() => o.isVersionHistoryOpen ? t("newsletter.close-version-history") : t("newsletter.version-history")), p = async (y) => {
|
|
25
24
|
s.value = !0, o.loadingStatus = !0;
|
|
26
|
-
const
|
|
27
|
-
return s.value = !1, o.loadingStatus = !1,
|
|
25
|
+
const S = await n(y);
|
|
26
|
+
return s.value = !1, o.loadingStatus = !1, S;
|
|
28
27
|
};
|
|
29
28
|
return m({
|
|
30
29
|
handleSave: p
|
|
31
|
-
}), { __sfc: !0, config: u, exportHtml: r, save: n, openVersionHistory: i, closeVersionHistory: a,
|
|
30
|
+
}), { __sfc: !0, config: u, exportHtml: r, save: n, openVersionHistory: i, closeVersionHistory: a, editorStore: o, trans: t, isExporting: e, isSaving: s, handleVersionHistory: c, handleExport: f, handleSaveAs: v, versionHistoryTooltipText: d, handleSave: p, getTooltipOptions: E, InButtonV2: O };
|
|
32
31
|
}
|
|
33
32
|
});
|
|
34
33
|
export {
|
|
35
|
-
|
|
34
|
+
z as default
|
|
36
35
|
};
|
|
@@ -2,7 +2,7 @@ import type { FooterButtonGroupOptions } from '@@/Types/wrappers/wp-drawer';
|
|
|
2
2
|
interface Props {
|
|
3
3
|
id: string;
|
|
4
4
|
className?: string;
|
|
5
|
-
size?:
|
|
5
|
+
size?: string;
|
|
6
6
|
closeOnOutsideClick?: boolean;
|
|
7
7
|
descriptionStatus?: boolean;
|
|
8
8
|
descriptionText?: string;
|
|
@@ -10,11 +10,9 @@ interface Props {
|
|
|
10
10
|
status: boolean;
|
|
11
11
|
titleText: string;
|
|
12
12
|
}
|
|
13
|
-
declare var __VLS_12: {}
|
|
13
|
+
declare var __VLS_12: {};
|
|
14
14
|
type __VLS_Slots = {} & {
|
|
15
|
-
|
|
16
|
-
} & {
|
|
17
|
-
default?: (props: typeof __VLS_14) => any;
|
|
15
|
+
default?: (props: typeof __VLS_12) => any;
|
|
18
16
|
};
|
|
19
17
|
declare const __VLS_component: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
|
|
20
18
|
className: string;
|
|
@@ -34,7 +32,7 @@ declare const __VLS_component: import("vue").DefineComponent<__VLS_WithDefaults<
|
|
|
34
32
|
descriptionText: string;
|
|
35
33
|
}>>>, {
|
|
36
34
|
className: string;
|
|
37
|
-
size:
|
|
35
|
+
size: string;
|
|
38
36
|
closeOnOutsideClick: boolean;
|
|
39
37
|
descriptionStatus: boolean;
|
|
40
38
|
descriptionText: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import r from "./WpDrawer.vue2.js";
|
|
2
2
|
import s from "../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
-
var
|
|
3
|
+
var i = function() {
|
|
4
4
|
var t = this, n = t._self._c, e = t._self._setupProxy;
|
|
5
5
|
return n(e.InDrawer, { class: t.className, attrs: { id: t.id, "footer-status": "", "close-on-outside-click": t.closeOnOutsideClick, "description-status": t.descriptionStatus, "description-text": t.descriptionText, "footer-button-group-options": t.footerButtonGroupOptions, size: t.size, status: t.status, "title-text": t.titleText }, on: { cancelOrBackButtonEvent: function(o) {
|
|
6
6
|
return e.emit("cancelOrBackButtonEvent");
|
|
@@ -8,15 +8,13 @@ var u = function() {
|
|
|
8
8
|
return e.emit("onCloseEvent");
|
|
9
9
|
}, primaryButtonEvent: function(o) {
|
|
10
10
|
return e.emit("primaryButtonEvent");
|
|
11
|
-
} }, scopedSlots: t._u([
|
|
12
|
-
return [t._t("headerBottomSlot")];
|
|
13
|
-
}, proxy: !0 } : null, { key: "contentSlot", fn: function() {
|
|
11
|
+
} }, scopedSlots: t._u([{ key: "contentSlot", fn: function() {
|
|
14
12
|
return [n("div", [t._t("default")], 2)];
|
|
15
13
|
}, proxy: !0 }], null, !0) });
|
|
16
|
-
},
|
|
14
|
+
}, u = [], c = /* @__PURE__ */ s(
|
|
17
15
|
r,
|
|
18
|
-
u,
|
|
19
16
|
i,
|
|
17
|
+
u,
|
|
20
18
|
!1,
|
|
21
19
|
null,
|
|
22
20
|
null
|