@designcrowd/library.brand-page 6.2.11 → 6.2.12
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/lib/src/{CreatedOnBrandCrowd-de-de-DDcraD5S.js → CreatedOnBrandCrowd-de-de-BtVKllNQ.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-DtOeaisf.js → CreatedOnBrandCrowd-en-us-CX5V0v8u.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-BZpmJPew.js → CreatedOnBrandCrowd-es-es-CbA02PCL.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-CqRwC4e7.js → CreatedOnBrandCrowd-fr-ca-BQAKruBF.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-CqRwC4e7.js → CreatedOnBrandCrowd-fr-fr-BQAKruBF.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-DId9Dfjh.js → CreatedOnBrandCrowd-pt-br-Yk_yzB3s.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-DId9Dfjh.js → CreatedOnBrandCrowd-pt-pt-Yk_yzB3s.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-BTDfmOcm.js → CreatedOnDcom-de-de-DJZQbPSD.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-CeAu9Ayx.js → CreatedOnDcom-en-us-BJvNAa4l.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-WCv0K41H.js → CreatedOnDcom-es-es-CUwB1FRY.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-BlfevQDY.js → CreatedOnDcom-fr-ca-CK54U4oh.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-Cvt7MHPZ.js → CreatedOnDcom-fr-fr-DuUNBGrM.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-DipZuylv.js → CreatedOnDcom-pt-br-BfODpFNV.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-BCw4lcKN.js → CreatedOnDcom-pt-pt-Cf6u2GCg.js} +1 -1
- package/lib/src/brand-page/__fixtures__/production-text-style-resolver.fixture.d.ts +16 -0
- package/lib/src/brand-page/__fixtures__/production-text-style-resolver.fixture.js +35 -0
- package/lib/src/brand-page/components/contact-form/ContactForm.mixin.d.ts +3 -0
- package/lib/src/brand-page/components/contact-form/ContactForm.mixin.js +19 -13
- package/lib/src/brand-page/components/mailing-list/MailingList.mixin.d.ts +3 -1
- package/lib/src/brand-page/components/mailing-list/MailingList.mixin.js +17 -2
- package/lib/src/brand-page/components/navigation/button-carousel/ButtonCarouselNavigation.mixin.d.ts +11 -3
- package/lib/src/brand-page/components/navigation/button-carousel/ButtonCarouselNavigation.mixin.js +35 -1
- package/lib/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.d.ts +8 -2
- package/lib/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.js +27 -3
- package/lib/src/brand-page/components/page/Page.mixin.d.ts +5 -2
- package/lib/src/brand-page/components/page/Page.mixin.js +33 -27
- package/lib/src/brand-page/components/page-footer/PageFooter.mixin.d.ts +7 -2
- package/lib/src/brand-page/components/page-footer/PageFooter.mixin.js +21 -1
- package/lib/src/brand-page/components/payment/Payment.mixin.d.ts +5 -2
- package/lib/src/brand-page/components/payment/Payment.mixin.js +22 -2
- package/lib/src/brand-page/components/payment/support-me/SupportMe.mixin.d.ts +6 -2
- package/lib/src/brand-page/components/payment/support-me/SupportMe.mixin.js +32 -1
- package/lib/src/brand-page/components/social-links/SocialLinks.stories.js +0 -3
- package/lib/src/brand-page/components/testimonial-section/__fixtures__/data.js +0 -3
- package/lib/src/brand-page/components/text/Text.stories.js +0 -17
- package/lib/src/brand-page/constants/font.constants.d.ts +62 -0
- package/lib/src/brand-page/constants/font.constants.js +35 -0
- package/lib/src/brand-page/models/index.d.ts +23 -24
- package/lib/src/brand-page/models/index.js +20 -7
- package/lib/src/brand-page/models/navigation-styles.model.d.ts +1 -1
- package/lib/src/brand-page/models/navigation-styles.model.js +17 -8
- package/lib/src/brand-page/models/payment.model.d.ts +11 -6
- package/lib/src/brand-page/models/styles.model.d.ts +53 -7
- package/lib/src/brand-page/models/styles.model.js +115 -27
- package/lib/src/brand-page/utils/color-palette.util.d.ts +43 -23
- package/lib/src/brand-page/utils/color-palette.util.js +65 -27
- package/lib/src/brand-page/utils/color.util.d.ts +13 -9
- package/lib/src/brand-page/utils/color.util.js +56 -15
- package/lib/src/brand-page/utils/container-text-color.util.d.ts +46 -13
- package/lib/src/brand-page/utils/container-text-color.util.js +321 -41
- package/lib/src/brand-page/utils/index.d.ts +1 -0
- package/lib/src/brand-page/utils/index.js +1 -0
- package/lib/src/brand-page/utils/migration/migration-20.js +6 -2
- package/lib/src/brand-page/utils/migration/migration-21.js +34 -6
- package/lib/src/brand-page/utils/migration/migration-22.d.ts +99 -0
- package/lib/src/brand-page/utils/migration/migration-22.js +909 -0
- package/lib/src/brand-page/utils/migration.util.js +17 -0
- package/lib/src/brand-page/utils/model.util.d.ts +4 -0
- package/lib/src/brand-page/utils/model.util.js +4 -0
- package/lib/src/brand-page/utils/personalisation.util.js +9 -1
- package/lib/src/brand-page/utils/rte-role-lift.util.d.ts +72 -0
- package/lib/src/brand-page/utils/rte-role-lift.util.js +275 -0
- package/lib/src/brand-page/utils/style.util.d.ts +5 -1
- package/lib/src/brand-page/utils/style.util.js +34 -11
- package/lib/src/brand-page/utils/text-role-css.util.d.ts +19 -0
- package/lib/src/brand-page/utils/text-role-css.util.js +186 -0
- package/lib/src/brand-page/utils/text-role-reconnect.util.d.ts +90 -0
- package/lib/src/brand-page/utils/text-role-reconnect.util.js +434 -0
- package/lib/src/brand-page/utils/text-style.util.d.ts +53 -23
- package/lib/src/brand-page/utils/text-style.util.js +122 -22
- package/lib/src/brand-page/utils/view-model.util.d.ts +9 -1
- package/lib/src/brand-page/utils/view-model.util.js +124 -111
- package/lib/src/brand-page/view-models.d.ts +1 -0
- package/lib/src/brand-page-maker/components/action-bar/ActionBar.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.d.ts +13 -2
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.js +4 -4
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMakerTemplateSettings.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.js +0 -10
- package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/content-settings-items.fixture.js +0 -1
- package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts +23 -138
- package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.js +0 -28
- package/lib/src/brand-page-maker/components/brandpage-settings/ReplaceImageSettingsForBrandPageSettings.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/components/navigation/Navigation.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/seo-settings/SeoPageSettings.mixin.d.ts +5 -2
- package/lib/src/brand-page-maker/components/seo-settings/UrlSettings.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/components/social-share/SocialShare.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.d.ts +4 -1
- package/lib/src/brand-page-maker/composables/ai-chat/useAiMetadataBuilder.d.ts +1 -0
- package/lib/src/brand-page-maker/composables/ai-chat/useAiMetadataBuilder.js +1 -0
- package/lib/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.js +1 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/RoleTypographyFill.d.ts +16 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/RoleTypographyFill.js +61 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/RteClipboard.d.ts +11 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/RteClipboard.js +236 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/font.d.ts +2 -1
- package/lib/src/brand-page-maker/composables/rich-text-editor/font.js +25 -6
- package/lib/src/brand-page-maker/composables/rich-text-editor/formatting.d.ts +17 -4
- package/lib/src/brand-page-maker/composables/rich-text-editor/formatting.js +204 -17
- package/lib/src/brand-page-maker/composables/rich-text-editor/hyperlink.d.ts +1 -1
- package/lib/src/brand-page-maker/composables/rich-text-editor/hyperlink.js +29 -31
- package/lib/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.d.ts +20 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.js +60 -0
- package/lib/src/brand-page-maker/composables/rich-text-editor/spacing.d.ts +2 -1
- package/lib/src/brand-page-maker/composables/rich-text-editor/spacing.js +22 -6
- package/lib/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.d.ts +10 -4
- package/lib/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.js +319 -275
- package/lib/src/brand-page-maker/constants/config-settings-constant.js +1 -5
- package/lib/src/brand-page-maker/convertors/text-css-style-options.convertor.js +6 -2
- package/lib/src/brand-page-maker/convertors/text-size-value.convertor.d.ts +1 -1
- package/lib/src/brand-page-maker/convertors/text-size-value.convertor.js +3 -1
- package/lib/src/brand-page-maker/default-getters/payment-text-and-border-color.default-getter.js +7 -14
- package/lib/src/brand-page-maker/default-getters/text-color.default-getter.js +6 -13
- package/lib/src/brand-page-maker/models/content-settings.d.ts +8 -0
- package/lib/src/brand-page-maker/models/content-settings.js +112 -81
- package/lib/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store-utils.d.ts +2 -2
- package/lib/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store-utils.js +5 -2
- package/lib/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store.js +4 -3
- package/lib/src/brand-page-maker/stores/ai-checkpoint/ai-checkpoint-store.d.ts +1257 -117
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.d.ts +6 -1
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +17 -9
- package/lib/src/brand-page-maker/stores/history/history-store.d.ts +59 -5
- package/lib/src/brand-page-maker/stores/history/history-store.js +22 -2
- package/lib/src/brand-page-maker/utils/apply-color-strategy.js +26 -8
- package/lib/src/brand-page-maker/utils/index.d.ts +2 -1
- package/lib/src/brand-page-maker/utils/index.js +2 -1
- package/lib/src/brand-page-maker/utils/rich-text-editor.util.d.ts +117 -15
- package/lib/src/brand-page-maker/utils/rich-text-editor.util.js +435 -281
- package/lib/src/brand-page-maker/utils/rte-authoring.util.d.ts +4 -0
- package/lib/src/brand-page-maker/utils/rte-authoring.util.js +101 -0
- package/lib/src/brand-page-maker/utils/rte-clipboard.util.d.ts +126 -0
- package/lib/src/brand-page-maker/utils/rte-clipboard.util.js +307 -0
- package/lib/src/brand-page-maker/utils/rte-sanitize.util.js +13 -3
- package/lib/src/{bundled-translations-zfiA5Tsw.js → bundled-translations-yGrvPE5i.js} +17 -17
- package/lib/src/{bundled-translations.de-DE-ChsdSyAP.js → bundled-translations.de-DE-L4Znf8Hs.js} +17 -17
- package/lib/src/{bundled-translations.es-ES-DflsWQK0.js → bundled-translations.es-ES-D6iticrK.js} +15 -15
- package/lib/src/{bundled-translations.fr-CA-fpDRuZ52.js → bundled-translations.fr-CA-BgAVE-9k.js} +25 -25
- package/lib/src/{bundled-translations.fr-FR-Bub73Zt-.js → bundled-translations.fr-FR-B8GbyqxQ.js} +17 -17
- package/lib/src/{bundled-translations.pt-BR-BlnWE9TB.js → bundled-translations.pt-BR-DjPU3Db7.js} +25 -25
- package/lib/src/{bundled-translations.pt-PT-DmzXlnaS.js → bundled-translations.pt-PT-BaepaDpr.js} +23 -23
- package/lib/src/bundles/bundled-translations.de-DE.json +21 -2
- package/lib/src/bundles/bundled-translations.es-ES.json +21 -2
- package/lib/src/bundles/bundled-translations.fr-CA.json +21 -2
- package/lib/src/bundles/bundled-translations.fr-FR.json +21 -2
- package/lib/src/bundles/bundled-translations.json +21 -2
- package/lib/src/bundles/bundled-translations.pt-BR.json +21 -2
- package/lib/src/bundles/bundled-translations.pt-PT.json +21 -2
- package/lib/src/clients/ai-assistant-client.d.ts +1 -0
- package/lib/src/composables/useTranslate.d.ts +1 -1
- package/lib/src/composables/useTranslate.js +1 -1
- package/lib/src/css/library.brand-page-brandCrowd.min.css +303 -207
- package/lib/src/css/library.brand-page-brandPage.min.css +303 -207
- package/lib/src/css/library.brand-page-designCom.min.css +303 -207
- package/lib/src/css/library.brand-page-preview.min.css +303 -207
- package/lib/src/index.d.ts +2 -1
- package/lib/src/index.mjs +195 -191
- package/lib/src/{lib-1AqtEmvQ.js → lib-kGRlD3_P.js} +36855 -33893
- package/lib/src/lib.js +2 -1
- package/lib/src/metadata-builder/builders/footer-builder.js +4 -5
- package/lib/src/metadata-builder/builders/global-role-propagation.d.ts +58 -0
- package/lib/src/metadata-builder/builders/global-role-propagation.js +246 -0
- package/lib/src/metadata-builder/builders/global-styles-builder.d.ts +1 -0
- package/lib/src/metadata-builder/builders/global-styles-builder.js +116 -45
- package/lib/src/metadata-builder/builders/header-builder.js +13 -4
- package/lib/src/metadata-builder/builders/section-builders/about-section-builder.js +3 -3
- package/lib/src/metadata-builder/builders/section-builders/banner-section-builder.js +3 -3
- package/lib/src/metadata-builder/builders/section-builders/booking-section-builder.js +3 -3
- package/lib/src/metadata-builder/builders/section-builders/contact-form-builder.js +4 -4
- package/lib/src/metadata-builder/builders/section-builders/images-section-builder.js +3 -3
- package/lib/src/metadata-builder/builders/section-builders/mailing-list-builder.js +2 -2
- package/lib/src/metadata-builder/builders/section-builders/mailing-list-section-builder.js +2 -2
- package/lib/src/metadata-builder/builders/section-builders/profile-section-builder.js +4 -4
- package/lib/src/metadata-builder/builders/section-builders/shapes-section-builder.js +3 -3
- package/lib/src/metadata-builder/builders/section-builders/social-links-builder.js +8 -2
- package/lib/src/metadata-builder/builders/section-builders/testimonial-section-builder.js +2 -2
- package/lib/src/metadata-builder/builders/section-builders/text-section-builder.js +60 -29
- package/lib/src/metadata-builder/builders/section-field-maps.js +1 -0
- package/lib/src/metadata-builder/builders/section-field-utils.d.ts +48 -19
- package/lib/src/metadata-builder/builders/section-field-utils.js +128 -52
- package/lib/src/metadata-builder/builders/section-rules/global-styles.rules.d.ts +4 -2
- package/lib/src/metadata-builder/builders/section-rules/global-styles.rules.js +28 -12
- package/lib/src/metadata-builder/builders/section-rules/social-links.rules.js +5 -1
- package/lib/src/metadata-builder/helpers/rte.helpers.d.ts +1 -1
- package/lib/src/metadata-builder/helpers/rte.helpers.js +97 -40
- package/lib/src/metadata-builder/metadata-executor.js +23 -1
- package/lib/src/metadata-builder/models.d.ts +2 -0
- package/lib/src/metadata-builder/parsers/ai-toolcall-parser.d.ts +18 -19
- package/lib/src/metadata-builder/parsers/section-tool-arguments.d.ts +18 -1
- package/lib/src/metadata-builder/sanitizers/rte-schema-check.js +1 -1
- package/lib/src/metadata-builder/sanitizers/sanitizer-rules.d.ts +0 -1
- package/lib/src/metadata-builder/sanitizers/sanitizer-rules.js +5 -8
- package/lib/src/metadata-builder/sanitizers/section-args-validator.d.ts +7 -16
- package/lib/src/metadata-builder/sanitizers/section-args-validator.js +95 -22
- package/lib/src/shared/color-palette/section-color-matches.js +9 -25
- package/lib/src/shared/color-strategies/color-strategies.d.ts +15 -0
- package/lib/src/shared/color-strategies/color-strategies.js +31 -0
- package/lib/src/shared/color-strategies/rte-color.d.ts +8 -0
- package/lib/src/shared/color-strategies/rte-color.js +16 -0
- package/lib/src/shared/color-strategies/rte-field-pairs.d.ts +23 -0
- package/lib/src/shared/color-strategies/rte-field-pairs.js +28 -0
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.d.ts +9 -135
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.js +1 -27
- package/lib/src/shared/content-settings/components/content-settings/ReplaceImageSettingsForContent.mixin.d.ts +12 -2
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItem.mixin.d.ts +7 -0
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.d.ts +75 -6
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.js +18 -7
- package/lib/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.d.ts +6 -1
- package/lib/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.js +0 -7
- package/lib/src/shared/content-settings/components/payment-config-field/PaymentConfigField.mixin.d.ts +1 -0
- package/lib/src/shared/content-settings/components/text-items-field/TextItemsField.mixin.js +8 -4
- package/lib/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.d.ts +1255 -26
- package/lib/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.js +203 -59
- package/lib/src/shared/content-settings/store/content-settings-store.d.ts +6 -0
- package/lib/src/shared/content-settings/store/content-settings-store.js +105 -8
- package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +5 -1
- package/lib/src/shared/navigation-style-settings/store/index.d.ts +7 -3
- package/lib/src/shared/navigation-style-settings/store/index.js +40 -15
- package/lib/src/shared/page-settings/components/delete-page-modal/DeletePageModal.mixin.d.ts +1 -1
- package/lib/src/shared/page-settings/components/new-page-modal/NewPageModal.mixin.d.ts +1 -0
- package/lib/src/shared/page-settings/components/page-settings/PageSettings.mixin.d.ts +17 -5
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +70 -13
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.js +10 -2
- package/lib/src/shared/page-settings/store/page-settings-store.d.ts +2 -1
- package/lib/src/shared/page-settings/store/page-settings-store.js +17 -0
- package/lib/src/shared/publish-brand-page-with-state/PublishBrandPageModalWithState.mixin.d.ts +4 -1
- package/lib/src/shared/rte-extensions/AutoLink.d.ts +17 -0
- package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/AutoLink.js +67 -51
- package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/MaxLength.js +4 -1
- package/lib/src/shared/rte-extensions/TextEffects.d.ts +28 -0
- package/lib/src/shared/rte-extensions/TextEffects.js +96 -0
- package/lib/src/shared/rte-extensions/ViewDomParser.d.ts +2 -0
- package/lib/src/shared/rte-extensions/ViewDomParser.js +21 -0
- package/lib/src/shared/rte-extensions.util.d.ts +25 -0
- package/lib/src/{brand-page-maker/composables/rich-text-editor/getRteExtensions.js → shared/rte-extensions.util.js} +62 -7
- package/lib/src/shared/rte-link.util.d.ts +1 -0
- package/lib/src/shared/rte-link.util.js +1 -0
- package/lib/src/shared/rte-render.util.d.ts +112 -0
- package/lib/src/shared/rte-render.util.js +255 -0
- package/lib/src/shared/rte-shape.util.d.ts +6 -0
- package/lib/src/shared/rte-shape.util.js +18 -0
- package/lib/src/shared/side-bar/components/SideBar.mixin.d.ts +2 -1
- package/lib/src/shared/side-bar/components/SideBarTabButton.mixin.d.ts +1 -0
- package/lib/src/shared/side-bar/store/side-bar-store.d.ts +2 -0
- package/lib/src/shared/side-bar/store/side-bar-store.js +9 -0
- package/lib/src/shared/style-settings/components/StyleSettings.mixin.d.ts +155 -15
- package/lib/src/shared/style-settings/components/StyleSettings.mixin.js +7 -1
- package/lib/src/shared/style-settings/store/style-settings-store.d.ts +1 -9
- package/lib/src/shared/style-settings/store/style-settings-store.js +3 -33
- package/lib/src/shared/style-settings/text-style-size-order.d.ts +2 -0
- package/lib/src/shared/style-settings/text-style-size-order.js +13 -0
- package/lib/src/shared/text-role-typography.util.d.ts +64 -0
- package/lib/src/shared/text-role-typography.util.js +183 -0
- package/lib/src/utils/minify-brand-page-metadata.d.ts +16 -1
- package/lib/src/utils/minify-brand-page-metadata.js +31 -9
- package/package.json +1 -1
- package/src/brand-page/__fixtures__/migration-22-v21/edited-brandsite-sections.v21.json +982 -0
- package/src/brand-page/__fixtures__/migration-22-v21/new-brandcontact-every-section.v21.json +1231 -0
- package/src/brand-page/__fixtures__/migration-22-v21/new-brandpage-every-section.v21.json +1231 -0
- package/src/brand-page/__fixtures__/migration-22-v21/new-brandsite-every-section.v21.json +1243 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandcontact.v21.json +755 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandpage-general-link.v21.json +527 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandpage-links.v21.json +755 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandpage-social-links.v21.json +514 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandsite-about.v21.json +459 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandsite-footer.v21.json +469 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandsite-header-banner.v21.json +481 -0
- package/src/brand-page/__fixtures__/migration-22-v21/real-brandsite-sections.v21.json +800 -0
- package/src/brand-page/__fixtures__/production-text-style-resolver.fixture.ts +52 -0
- package/src/brand-page/components/about-section/AboutSection.vue.test.ts +0 -10
- package/src/brand-page/components/contact-form/ContactForm.mixin.test.ts +127 -0
- package/src/brand-page/components/contact-form/ContactForm.mixin.ts +31 -14
- package/src/brand-page/components/contact-form/ContactForm.vue +26 -12
- package/src/brand-page/components/contact-form/ContactForm.vue.test.ts +60 -0
- package/src/brand-page/components/mailing-list/MailingList.mixin.test.ts +92 -0
- package/src/brand-page/components/mailing-list/MailingList.mixin.ts +28 -3
- package/src/brand-page/components/mailing-list/MailingList.vue +9 -4
- package/src/brand-page/components/mailing-list/MailingList.vue.test.ts +63 -0
- package/src/brand-page/components/navigation/button-carousel/ButtonCarouselNavigation.mixin.ts +51 -1
- package/src/brand-page/components/navigation/button-carousel/ButtonCarouselNavigation.test.ts +114 -0
- package/src/brand-page/components/navigation/button-carousel/ButtonCarouselNavigation.vue +8 -2
- package/src/brand-page/components/navigation/navigation-carousel/NavigationCarousel.test.ts +182 -0
- package/src/brand-page/components/navigation/navigation-carousel/NavigationCarousel.vue +59 -12
- package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.ts +40 -3
- package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.vue +15 -7
- package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.vue.test.ts +133 -3
- package/src/brand-page/components/page/Page.mixin.ts +41 -34
- package/src/brand-page/components/page/Page.vue +17 -6
- package/src/brand-page/components/page/Page.vue.test.ts +91 -1
- package/src/brand-page/components/page-footer/PageFooter.mixin.ts +32 -2
- package/src/brand-page/components/page-footer/PageFooter.test.ts +79 -0
- package/src/brand-page/components/page-footer/PageFooter.vue +12 -4
- package/src/brand-page/components/payment/Payment.mixin.ts +34 -2
- package/src/brand-page/components/payment/Payment.test.ts +188 -0
- package/src/brand-page/components/payment/Payment.vue +12 -5
- package/src/brand-page/components/payment/RequestPaymentStripe.vue +1 -0
- package/src/brand-page/components/payment/support-me/SupportMe.mixin.ts +49 -2
- package/src/brand-page/components/payment/support-me/SupportMe.test.ts +100 -0
- package/src/brand-page/components/payment/support-me/SupportMe.vue +7 -1
- package/src/brand-page/components/payment/support-me/SupportMe.vue.test.ts +66 -0
- package/src/brand-page/components/save-contact/SaveContactWidget.test.ts +100 -0
- package/src/brand-page/components/save-contact/SaveContactWidget.vue +6 -3
- package/src/brand-page/components/shop/PaymentModal.vue +2 -6
- package/src/brand-page/components/shop/PaymentShippingAddress.vue +6 -0
- package/src/brand-page/components/shop/Shop.vue +15 -2
- package/src/brand-page/components/shop/Shop.vue.test.ts +74 -2
- package/src/brand-page/components/social-links/SocialLinks.stories.ts +0 -3
- package/src/brand-page/components/social-links/SocialLinks.vue.test.ts +0 -3
- package/src/brand-page/components/testimonial-section/__fixtures__/data.ts +0 -3
- package/src/brand-page/components/text/Text.stories.ts +0 -17
- package/src/brand-page/components/text-wrapper/TextWrapper.parity.test.ts +136 -0
- package/src/brand-page/components/text-wrapper/TextWrapper.test.ts +358 -0
- package/src/brand-page/components/text-wrapper/TextWrapper.vue +82 -22
- package/src/brand-page/constants/font.constants.ts +37 -0
- package/src/brand-page/models/footer-icon-color.test.ts +22 -0
- package/src/brand-page/models/index.ts +50 -28
- package/src/brand-page/models/navigation-styles.model.test.ts +77 -1
- package/src/brand-page/models/navigation-styles.model.ts +26 -9
- package/src/brand-page/models/payment.model.ts +15 -6
- package/src/brand-page/models/styles.model.test.ts +104 -0
- package/src/brand-page/models/styles.model.ts +181 -47
- package/src/brand-page/utils/__snapshots__/migration.util.test.ts.snap +619 -115
- package/src/brand-page/utils/__snapshots__/migration2.util.test.ts.snap +150 -9
- package/src/brand-page/utils/__snapshots__/model.util.test.ts.snap +300 -18
- package/src/brand-page/utils/color-palette.util.test.ts +126 -1
- package/src/brand-page/utils/color-palette.util.ts +92 -26
- package/src/brand-page/utils/color.util.test.ts +62 -29
- package/src/brand-page/utils/color.util.ts +77 -14
- package/src/brand-page/utils/container-text-color.util.test.ts +672 -26
- package/src/brand-page/utils/container-text-color.util.ts +472 -46
- package/src/brand-page/utils/index.ts +1 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/edited-brandsite-sections.v22.json +1191 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/new-brandcontact-every-section.v22.json +2026 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/new-brandpage-every-section.v22.json +2017 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/new-brandsite-every-section.v22.json +2031 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandcontact.v22.json +1145 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandpage-general-link.v22.json +645 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandpage-links.v22.json +1136 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandpage-social-links.v22.json +662 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandsite-about.v22.json +638 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandsite-footer.v22.json +610 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandsite-header-banner.v22.json +660 -0
- package/src/brand-page/utils/migration/__snapshots__/migration-22-output/real-brandsite-sections.v22.json +1132 -0
- package/src/brand-page/utils/migration/migration-01.ts +293 -237
- package/src/brand-page/utils/migration/migration-02.ts +8 -1
- package/src/brand-page/utils/migration/migration-20.ts +6 -3
- package/src/brand-page/utils/migration/migration-20_5.test.ts +5 -2
- package/src/brand-page/utils/migration/migration-21.test.ts +34 -0
- package/src/brand-page/utils/migration/migration-21.ts +46 -10
- package/src/brand-page/utils/migration/migration-22.fixed-input.test.ts +43 -0
- package/src/brand-page/utils/migration/migration-22.test.ts +4103 -0
- package/src/brand-page/utils/migration/migration-22.text-font-family.test.ts +72 -0
- package/src/brand-page/utils/migration/migration-22.ts +1336 -0
- package/src/brand-page/utils/migration.util.test.ts +146 -32
- package/src/brand-page/utils/migration.util.ts +18 -0
- package/src/brand-page/utils/model.util.ts +4 -0
- package/src/brand-page/utils/personalisation.util.test.ts +148 -3
- package/src/brand-page/utils/personalisation.util.ts +9 -1
- package/src/brand-page/utils/rte-role-lift.util.ts +409 -0
- package/src/brand-page/utils/style.util.test.ts +35 -2
- package/src/brand-page/utils/style.util.ts +45 -11
- package/src/brand-page/utils/text-role-css.util.test.ts +525 -0
- package/src/brand-page/utils/text-role-css.util.ts +321 -0
- package/src/brand-page/utils/text-role-reconnect.util.test.ts +604 -0
- package/src/brand-page/utils/text-role-reconnect.util.ts +727 -0
- package/src/brand-page/utils/text-style.util.test.ts +305 -0
- package/src/brand-page/utils/text-style.util.ts +198 -24
- package/src/brand-page/utils/view-model.page-data.test.ts +232 -0
- package/src/brand-page/utils/view-model.util.test.ts +954 -133
- package/src/brand-page/utils/view-model.util.ts +187 -139
- package/src/brand-page/view-models.ts +4 -0
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.blank-site.test.ts +57 -0
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.ts +9 -5
- package/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.ts +0 -10
- package/src/brand-page-maker/components/brand-page-maker/__fixtures__/content-settings-items.fixture.ts +0 -1
- package/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.ts +0 -44
- package/src/brand-page-maker/components/rich-text-editor/RichTextEditor.vue +253 -200
- package/src/brand-page-maker/components/shop/AddOrEditProductContainer.vue +1 -0
- package/src/brand-page-maker/components/template-preview/TemplatePreview.vue +1 -0
- package/src/brand-page-maker/composables/ai-chat/useAiMetadataBuilder.ts +2 -0
- package/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.ts +1 -0
- package/src/brand-page-maker/composables/rich-text-editor/block-typography.test.ts +519 -0
- package/src/brand-page-maker/composables/rich-text-editor/extensions/FontFamily.test.ts +1 -1
- package/src/brand-page-maker/composables/rich-text-editor/extensions/MaxLength.test.ts +26 -1
- package/src/brand-page-maker/composables/rich-text-editor/extensions/RoleTypographyFill.test.ts +110 -0
- package/src/brand-page-maker/composables/rich-text-editor/extensions/RoleTypographyFill.ts +99 -0
- package/src/brand-page-maker/composables/rich-text-editor/extensions/RteClipboard.ts +397 -0
- package/src/brand-page-maker/composables/rich-text-editor/extensions/ViewDomParser.test.ts +139 -0
- package/src/brand-page-maker/composables/rich-text-editor/font.ts +36 -5
- package/src/brand-page-maker/composables/rich-text-editor/formatting.test.ts +375 -1
- package/src/brand-page-maker/composables/rich-text-editor/formatting.ts +301 -17
- package/src/brand-page-maker/composables/rich-text-editor/hyperlink.test.ts +82 -1
- package/src/brand-page-maker/composables/rich-text-editor/hyperlink.ts +28 -34
- package/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.test.ts +80 -0
- package/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.ts +75 -0
- package/src/brand-page-maker/composables/rich-text-editor/spacing.ts +31 -6
- package/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.test.ts +2485 -0
- package/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.ts +435 -337
- package/src/brand-page-maker/constants/config-settings-constant.ts +0 -6
- package/src/brand-page-maker/convertors/text-css-style-options.convertor.test.ts +43 -0
- package/src/brand-page-maker/convertors/text-css-style-options.convertor.ts +6 -2
- package/src/brand-page-maker/convertors/text-size-value.convertor.test.ts +24 -0
- package/src/brand-page-maker/convertors/text-size-value.convertor.ts +17 -13
- package/src/brand-page-maker/default-getters/payment-text-and-border-color.default-getter.ts +7 -22
- package/src/brand-page-maker/default-getters/text-color.default-getter.ts +5 -21
- package/src/brand-page-maker/models/content-settings.test.ts +708 -0
- package/src/brand-page-maker/models/content-settings.ts +133 -82
- package/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store-utils.test.ts +63 -1
- package/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store-utils.ts +16 -3
- package/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store.test.ts +34 -0
- package/src/brand-page-maker/stores/admin-logo-settings/admin-logo-settings-store.ts +4 -2
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.test.ts +185 -1
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +22 -34
- package/src/brand-page-maker/stores/history/history-store.ts +35 -2
- package/src/brand-page-maker/utils/__snapshots__/apply-color-strategy.golden.test.ts.snap +528 -0
- package/src/brand-page-maker/utils/__snapshots__/rte-render-parity.test.ts.snap +12 -0
- package/src/brand-page-maker/utils/apply-color-strategy.golden.test.ts +2 -0
- package/src/brand-page-maker/utils/apply-color-strategy.test.ts +181 -3
- package/src/brand-page-maker/utils/apply-color-strategy.ts +36 -4
- package/src/brand-page-maker/utils/index.ts +2 -1
- package/src/brand-page-maker/utils/rich-text-editor.util.test.ts +447 -410
- package/src/brand-page-maker/utils/rich-text-editor.util.ts +610 -506
- package/src/brand-page-maker/utils/rte-authoring.util.test.ts +244 -0
- package/src/brand-page-maker/utils/rte-authoring.util.ts +175 -0
- package/src/brand-page-maker/utils/rte-clipboard.util.test.ts +558 -0
- package/src/brand-page-maker/utils/rte-clipboard.util.ts +473 -0
- package/src/brand-page-maker/utils/rte-features.test.ts +99 -3
- package/src/brand-page-maker/utils/rte-render-parity.test.ts +1 -1
- package/src/brand-page-maker/utils/rte-render.util.test.ts +230 -0
- package/src/brand-page-maker/utils/rte-sanitize-json.test.ts +1 -1
- package/src/brand-page-maker/utils/rte-sanitize.util.ts +14 -3
- package/src/brand-page-maker/utils/rte-schema-version.test.ts +102 -0
- package/src/bundles/bundled-translations.de-DE.json +21 -2
- package/src/bundles/bundled-translations.es-ES.json +21 -2
- package/src/bundles/bundled-translations.fr-CA.json +21 -2
- package/src/bundles/bundled-translations.fr-FR.json +21 -2
- package/src/bundles/bundled-translations.json +21 -2
- package/src/bundles/bundled-translations.pt-BR.json +21 -2
- package/src/bundles/bundled-translations.pt-PT.json +21 -2
- package/src/clients/ai-assistant-client.ts +1 -0
- package/src/composables/useTranslate.ts +2 -1
- package/src/lib.ts +2 -2
- package/src/metadata-builder/builders/footer-builder.test.ts +70 -45
- package/src/metadata-builder/builders/footer-builder.ts +4 -8
- package/src/metadata-builder/builders/global-role-propagation.test.ts +907 -0
- package/src/metadata-builder/builders/global-role-propagation.ts +430 -0
- package/src/metadata-builder/builders/global-styles-builder.test.ts +1020 -0
- package/src/metadata-builder/builders/global-styles-builder.ts +194 -48
- package/src/metadata-builder/builders/header-builder.test.ts +112 -40
- package/src/metadata-builder/builders/header-builder.ts +18 -8
- package/src/metadata-builder/builders/section-builders/about-section-builder.ts +5 -3
- package/src/metadata-builder/builders/section-builders/banner-section-builder.ts +5 -3
- package/src/metadata-builder/builders/section-builders/booking-section-builder.ts +5 -3
- package/src/metadata-builder/builders/section-builders/contact-form-builder.ts +7 -4
- package/src/metadata-builder/builders/section-builders/images-section-builder.ts +5 -3
- package/src/metadata-builder/builders/section-builders/mailing-list-builder.ts +3 -2
- package/src/metadata-builder/builders/section-builders/mailing-list-section-builder.ts +3 -2
- package/src/metadata-builder/builders/section-builders/profile-section-builder.ts +7 -7
- package/src/metadata-builder/builders/section-builders/shapes-section-builder.ts +5 -3
- package/src/metadata-builder/builders/section-builders/social-links-builder.test.ts +2 -2
- package/src/metadata-builder/builders/section-builders/social-links-builder.ts +21 -10
- package/src/metadata-builder/builders/section-builders/support-me-builder.test.ts +10 -0
- package/src/metadata-builder/builders/section-builders/testimonial-section-builder.ts +3 -2
- package/src/metadata-builder/builders/section-builders/text-section-builder.ts +111 -61
- package/src/metadata-builder/builders/section-field-maps.ts +1 -0
- package/src/metadata-builder/builders/section-field-utils.test.ts +545 -2
- package/src/metadata-builder/builders/section-field-utils.ts +202 -69
- package/src/metadata-builder/builders/section-rules/global-styles.rules.ts +38 -13
- package/src/metadata-builder/builders/section-rules/social-links.rules.ts +5 -0
- package/src/metadata-builder/helpers/rte.helpers.test.ts +101 -0
- package/src/metadata-builder/helpers/rte.helpers.ts +129 -43
- package/src/metadata-builder/metadata-executor.test.ts +167 -0
- package/src/metadata-builder/metadata-executor.ts +34 -1
- package/src/metadata-builder/models.ts +2 -0
- package/src/metadata-builder/parsers/ai-toolcall-parser.ts +23 -7
- package/src/metadata-builder/parsers/section-tool-arguments.ts +21 -1
- package/src/metadata-builder/sanitizers/__tests__/section-args-validator.test.ts +215 -0
- package/src/metadata-builder/sanitizers/rte-schema-check.ts +1 -1
- package/src/metadata-builder/sanitizers/sanitizer-rules.ts +4 -8
- package/src/metadata-builder/sanitizers/section-args-validator.ts +136 -53
- package/src/shared/color-palette/section-color-matches.test.ts +15 -11
- package/src/shared/color-palette/section-color-matches.ts +9 -28
- package/src/shared/color-strategies/color-strategies.ts +35 -0
- package/src/shared/color-strategies/rte-color.test.ts +1 -1
- package/src/shared/color-strategies/rte-color.ts +19 -0
- package/src/shared/color-strategies/rte-field-pairs.test.ts +26 -5
- package/src/shared/color-strategies/rte-field-pairs.ts +33 -0
- package/src/shared/content-settings/components/color-matches-panel/ColorMatchesPanel.test.ts +43 -66
- package/src/shared/content-settings/components/color-matches-panel/ColorMatchesPanel.vue +7 -1
- package/src/shared/content-settings/components/content-settings/ContentSettings.mixin.ts +1 -48
- package/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.ts +33 -7
- package/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.test.ts +128 -1
- package/src/shared/content-settings/components/draggable-item-list/DraggableItemList.vue +1 -0
- package/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.ts +0 -6
- package/src/shared/content-settings/components/logo-selection-field/LogoSelection.vue +3 -0
- package/src/shared/content-settings/components/logo-size-field/LogoSizeSlider.vue +3 -0
- package/src/shared/content-settings/components/logo-size-field/LogoSizeSliderField.vue +1 -0
- package/src/shared/content-settings/components/testimonial-items-field/TestimonialItemsField.vue +1 -0
- package/src/shared/content-settings/components/text-items-field/TextItemsField.mixin.test.ts +56 -3
- package/src/shared/content-settings/components/text-items-field/TextItemsField.mixin.ts +11 -4
- package/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.test.ts +335 -25
- package/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.ts +248 -70
- package/src/shared/content-settings/components/text-style-field/TextStyleField.vue +113 -25
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.de-DE.json +17 -10
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.es-ES.json +17 -10
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.fr-CA.json +17 -10
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.fr-FR.json +17 -10
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.json +8 -1
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.pt-BR.json +17 -10
- package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.pt-PT.json +17 -10
- package/src/shared/content-settings/components/text-style-role-dropdown/TextStyleRoleDropdown.test.ts +141 -0
- package/src/shared/content-settings/components/text-style-role-dropdown/TextStyleRoleDropdown.vue +136 -0
- package/src/shared/content-settings/store/content-settings-store.test.ts +491 -6
- package/src/shared/content-settings/store/content-settings-store.ts +159 -17
- package/src/shared/logo-settings/components/EditLogoSettings.vue +1 -0
- package/src/shared/logo-settings/components/LogoVariations.vue +1 -0
- package/src/shared/navigation-style-settings/components/navigation-style-settings/NavigationStyleSettings.vue +1 -0
- package/src/shared/navigation-style-settings/store/index.test.ts +295 -0
- package/src/shared/navigation-style-settings/store/index.ts +65 -15
- package/src/shared/page-settings/components/header-settings-panel/HeaderSettingsPanel.vue +2 -0
- package/src/shared/page-settings/components/page-settings/PageElement.vue +1 -0
- package/src/shared/page-settings/components/page-settings-section-styles/HeaderButtonSettings.test.ts +44 -4
- package/src/shared/page-settings/components/page-settings-section-styles/HeaderButtonSettings.vue +13 -4
- package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.navigation.test.ts +89 -0
- package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.text-style.test.ts +91 -0
- package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.ts +14 -2
- package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.vue +2 -0
- package/src/shared/page-settings/store/page-settings-store.text-style.test.ts +84 -0
- package/src/shared/page-settings/store/page-settings-store.ts +30 -1
- package/src/shared/rte-extensions/AutoLink.test.ts +98 -0
- package/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/AutoLink.ts +87 -58
- package/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/MaxLength.ts +4 -1
- package/src/shared/rte-extensions/TextEffects.ts +151 -0
- package/src/shared/rte-extensions/ViewDomParser.ts +27 -0
- package/src/{brand-page-maker/composables/rich-text-editor/getRteExtensions.ts → shared/rte-extensions.util.ts} +66 -9
- package/src/shared/rte-link.util.ts +2 -0
- package/src/shared/rte-render.util.ts +385 -0
- package/src/shared/rte-shape.util.ts +29 -0
- package/src/shared/side-bar/store/side-bar-store.test.ts +27 -1
- package/src/shared/side-bar/store/side-bar-store.ts +11 -0
- package/src/shared/style-settings/components/StyleSettings.mixin.ts +7 -3
- package/src/shared/style-settings/components/StyleSettings.test.ts +116 -0
- package/src/shared/style-settings/components/StyleSettings.vue +75 -25
- package/src/shared/style-settings/components/i18n/style-settings.de-DE.json +32 -20
- package/src/shared/style-settings/components/i18n/style-settings.es-ES.json +32 -20
- package/src/shared/style-settings/components/i18n/style-settings.fr-CA.json +32 -20
- package/src/shared/style-settings/components/i18n/style-settings.fr-FR.json +32 -20
- package/src/shared/style-settings/components/i18n/style-settings.json +13 -3
- package/src/shared/style-settings/components/i18n/style-settings.pt-BR.json +32 -20
- package/src/shared/style-settings/components/i18n/style-settings.pt-PT.json +32 -20
- package/src/shared/style-settings/components/text-style-options-settings-with-state/TextStyleOptionsSettingsWithState.vue +14 -34
- package/src/shared/style-settings/store/style-settings-store.ts +3 -49
- package/src/shared/style-settings/text-style-size-order.test.ts +76 -0
- package/src/shared/style-settings/text-style-size-order.ts +28 -0
- package/src/shared/template-settings/components/TemplatesSettings.vue +4 -0
- package/src/shared/text-role-typography.util.ts +277 -0
- package/src/utils/minify-brand-page-metadata.test.ts +102 -7
- package/src/utils/minify-brand-page-metadata.ts +62 -8
- package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/AutoLink.d.ts +0 -2
- package/lib/src/brand-page-maker/composables/rich-text-editor/getRteExtensions.d.ts +0 -28
- package/lib/src/brand-page-maker/utils/rte-render.util.d.ts +0 -63
- package/lib/src/brand-page-maker/utils/rte-render.util.js +0 -106
- package/lib/src/brand-page-maker/utils/rte-shape.d.ts +0 -18
- package/lib/src/brand-page-maker/utils/rte-shape.js +0 -21
- package/lib/src/metadata-builder/builders/global-font-propagation.d.ts +0 -41
- package/lib/src/metadata-builder/builders/global-font-propagation.js +0 -146
- package/src/brand-page-maker/utils/rte-render.util.ts +0 -179
- package/src/brand-page-maker/utils/rte-shape.ts +0 -29
- package/src/metadata-builder/builders/global-font-propagation.test.ts +0 -401
- package/src/metadata-builder/builders/global-font-propagation.ts +0 -238
- package/src/shared/style-settings/components/StyleSettingsSection.vue +0 -8
- /package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/FontFamily.d.ts +0 -0
- /package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/FontFamily.js +0 -0
- /package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/LetterSpacing.d.ts +0 -0
- /package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/LetterSpacing.js +0 -0
- /package/lib/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/MaxLength.d.ts +0 -0
- /package/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/FontFamily.ts +0 -0
- /package/src/{brand-page-maker/composables/rich-text-editor/extensions → shared/rte-extensions}/LetterSpacing.ts +0 -0
|
@@ -1,31 +1,131 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The element ↔ global-text-style resolution rules, in ONE place.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
* (`view-model.util.ts`) and
|
|
6
|
-
* resolved colour independently and drifted, so
|
|
7
|
-
* import from here rather than restating the chain.
|
|
4
|
+
* A near-leaf module: its only dependency is the role model (`styles.model`, a lower-level
|
|
5
|
+
* module with no back-edge to here, so no cycle). Both the renderer (`view-model.util.ts`) and
|
|
6
|
+
* the maker's Text Style panel consume it — they resolved colour independently and drifted, so
|
|
7
|
+
* the sidebar contradicted the canvas — import from here rather than restating the chain.
|
|
8
|
+
*
|
|
9
|
+
* MIGRATION-22 SNAPSHOT DEPENDENCY: `normalizeTextStyleAgainstRole` is called by its reconnect
|
|
10
|
+
* path. Do not change normalisation semantics after migration-22 releases without first pinning
|
|
11
|
+
* that migration's implementation.
|
|
8
12
|
*/
|
|
13
|
+
import { CANONICAL_TEXT_STYLE_TYPES, } from '../models/styles.model';
|
|
14
|
+
import { composeTextDecoration, NEUTRAL_TYPOGRAPHY_VALUE, TEXT_STYLE_CASCADE_PROPS, } from '@shared/text-role-typography.util';
|
|
15
|
+
export { composeTextDecoration, NEUTRAL_TYPOGRAPHY_VALUE, rteTextDecorationClassName, TEXT_STYLE_CASCADE_PROPS, } from '@shared/text-role-typography.util';
|
|
16
|
+
export { omitTypography, pickTypography, } from '@shared/text-role-typography.util';
|
|
9
17
|
/**
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* The **site-wide default** (`textStyleOptions.paragraphs.style.color`) is
|
|
17
|
-
* deliberately NOT in this chain — it reaches the text by CSS inheritance from the
|
|
18
|
-
* root element (`Page.mixin.ts` → `rootElementStyles`). So `undefined` here validly
|
|
19
|
-
* means "inherit", and mappers must not pre-seed the site default into an element
|
|
20
|
-
* style (it would read as an element override and beat the global text style).
|
|
18
|
+
* BP-5969 (ADR-0020): **a role no longer contributes colour** — a text role defines
|
|
19
|
+
* typography only. Colour resolves element-first, then an optional container middle
|
|
20
|
+
* rung; with neither set it falls to the page base coat by CSS inheritance from the
|
|
21
|
+
* root element (`Page.mixin.ts` → `rootElementStyles`), so `undefined` here validly
|
|
22
|
+
* means "inherit" and mappers must not pre-seed a default into an element style.
|
|
21
23
|
*
|
|
22
24
|
* Empty-string is treated as unset (`||`, not `??`) — a cleared colour field falls
|
|
23
|
-
*
|
|
25
|
+
* through rather than painting an invalid value.
|
|
26
|
+
*
|
|
27
|
+
* `fallbackBeforeGlobal` is the container middle rung: a context-derived default that
|
|
28
|
+
* wins over the base coat but still yields to an explicit element colour. Only
|
|
29
|
+
* container-bound blocks supply it (text on the block's own filled surface must
|
|
30
|
+
* contrast that surface, not the page — see `container-text-color.util.ts`).
|
|
31
|
+
*/
|
|
32
|
+
export const resolveTextColor = (elementStyle, fallbackBeforeGlobal) => elementStyle?.color || fallbackBeforeGlobal;
|
|
33
|
+
/**
|
|
34
|
+
* BP-5969 — the per-property text-style cascade (ADR-0019). Supersedes the old
|
|
35
|
+
* all-or-nothing rule (where a linked element took ALL typography from the role and
|
|
36
|
+
* only colour cascaded). Every typography property now resolves independently:
|
|
37
|
+
* `element[prop] ?? role[prop]`, so an element can override one property and keep the
|
|
38
|
+
* rest following its role. Empty-string is treated as unset (`||`, matching
|
|
39
|
+
* `resolveTextColor`) — a cleared field falls back to the role, and `'0'`
|
|
40
|
+
* (a valid letter-spacing) stays truthy.
|
|
41
|
+
*
|
|
42
|
+
* Colour keeps its own three-rung cascade via `resolveTextColor` (with the optional
|
|
43
|
+
* container `fallbackBeforeGlobal` middle rung). Alignment is deliberately absent —
|
|
44
|
+
* it is section-level, never a role property, and must not be resolved here.
|
|
45
|
+
*/
|
|
46
|
+
/**
|
|
47
|
+
* What the role CSS emits for a prop the role leaves unset. Props a role always defines (family /
|
|
48
|
+
* size / line-height) have none.
|
|
49
|
+
*/
|
|
50
|
+
const isUnsetTypography = (value) => value === undefined || value === null || value === '';
|
|
51
|
+
// An unset role prop renders as its neutral, so `fontStyle: 'normal'` under a role with no
|
|
52
|
+
// fontStyle is role-equal; under an italic role it is the override that turns italic off.
|
|
53
|
+
const effectiveRoleValue = (prop, value) => isUnsetTypography(value) ? NEUTRAL_TYPOGRAPHY_VALUE[prop] : value;
|
|
54
|
+
const isZeroLetterSpacing = (value) => typeof value === 'string' && /^[+-]?0(?:\.0+)?(?:em|rem|px)?$/.test(value);
|
|
55
|
+
const typographyValuesMatch = (prop, value, roleValue) => value === roleValue ||
|
|
56
|
+
(prop === 'letterSpacing' &&
|
|
57
|
+
isZeroLetterSpacing(value) &&
|
|
58
|
+
isZeroLetterSpacing(roleValue));
|
|
59
|
+
/**
|
|
60
|
+
* BP-5969 (ADR-0019) — the WRITE-side mirror of `overrideTypographyStyle`: drop any typography
|
|
61
|
+
* override equal to the block's linked role, so the persisted style stays a sparse diff and a later
|
|
62
|
+
* role edit repaints the block via the page-scoped role CSS. Colour, alignment and `applyAutoScale`
|
|
63
|
+
* are untouched. No-op for a non-style value, a legacy/unlinked role (no role class to fall back
|
|
64
|
+
* on), or an absent role table — the value passes through unchanged.
|
|
65
|
+
*
|
|
66
|
+
* Pure: the caller supplies the role table, so the maker store and the AI metadata builder share
|
|
67
|
+
* one normalization authority instead of drifting.
|
|
68
|
+
*/
|
|
69
|
+
export const normalizeTextStyleAgainstRole = (value, textStyleOptions) => {
|
|
70
|
+
const style = value;
|
|
71
|
+
const type = style?.textStyleType;
|
|
72
|
+
if (!style ||
|
|
73
|
+
typeof style !== 'object' ||
|
|
74
|
+
!type ||
|
|
75
|
+
!CANONICAL_TEXT_STYLE_TYPES.includes(type)) {
|
|
76
|
+
return value;
|
|
77
|
+
}
|
|
78
|
+
const role = textStyleOptions?.[type]?.style;
|
|
79
|
+
if (!role)
|
|
80
|
+
return value;
|
|
81
|
+
const normalized = { ...style };
|
|
82
|
+
for (const prop of TEXT_STYLE_CASCADE_PROPS) {
|
|
83
|
+
if (!(prop in normalized))
|
|
84
|
+
continue;
|
|
85
|
+
// An empty value is no override either: the resolver falls it through to the role.
|
|
86
|
+
if (isUnsetTypography(normalized[prop]) ||
|
|
87
|
+
typographyValuesMatch(prop, effectiveRoleValue(prop, normalized[prop]), effectiveRoleValue(prop, role[prop]))) {
|
|
88
|
+
delete normalized[prop];
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
return normalized;
|
|
92
|
+
};
|
|
93
|
+
export const resolveTextStyle = (elementStyle, roleStyle, fallbackBeforeGlobal) => {
|
|
94
|
+
const resolved = {};
|
|
95
|
+
for (const prop of TEXT_STYLE_CASCADE_PROPS) {
|
|
96
|
+
resolved[prop] =
|
|
97
|
+
prop === 'textDecoration'
|
|
98
|
+
? composeTextDecoration(roleStyle?.[prop], elementStyle?.[prop])
|
|
99
|
+
: elementStyle?.[prop] || roleStyle?.[prop];
|
|
100
|
+
}
|
|
101
|
+
resolved.color = resolveTextColor(elementStyle, fallbackBeforeGlobal);
|
|
102
|
+
return resolved;
|
|
103
|
+
};
|
|
104
|
+
/**
|
|
105
|
+
* BP-5969 (ADR-0019, Option B) — the render-time inverse of `resolveTextStyle`.
|
|
106
|
+
* The role's typography is supplied by a page-scoped CSS class (`text-role-css.util`),
|
|
107
|
+
* so a linked block must inline ONLY the props that DIFFER from its role — those beat
|
|
108
|
+
* the class by specificity; the rest fall through to the class, and editing the role
|
|
109
|
+
* repaints them for free. Colour is deliberately absent (it isn't in the class — it
|
|
110
|
+
* stays on its own cascade / on RTE marks).
|
|
111
|
+
*
|
|
112
|
+
* `roleStyle` undefined (no role in scope, or a non-canonical/unlinked block) returns
|
|
113
|
+
* every present typography prop — i.e. the caller bakes the full resolved style inline,
|
|
114
|
+
* exactly as before this change. That is the safe fallback: the render stays
|
|
115
|
+
* pixel-identical when the role isn't visible to the renderer.
|
|
24
116
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* container-bound blocks supply it (text sitting on the block's own filled surface
|
|
28
|
-
* must contrast that surface, not the page — see `container-text-color.util.ts`).
|
|
29
|
-
* Omitting it is byte-for-byte the original two-rung cascade.
|
|
117
|
+
* Empty-string / null are treated as unset (matching the `||` in the resolvers), and
|
|
118
|
+
* `'0'` (a valid letter-spacing) stays.
|
|
30
119
|
*/
|
|
31
|
-
export const
|
|
120
|
+
export const overrideTypographyStyle = (resolvedStyle, roleStyle) => {
|
|
121
|
+
const overrides = {};
|
|
122
|
+
for (const prop of TEXT_STYLE_CASCADE_PROPS) {
|
|
123
|
+
const value = resolvedStyle?.[prop];
|
|
124
|
+
if (value === undefined || value === null || value === '')
|
|
125
|
+
continue;
|
|
126
|
+
if (roleStyle && value === roleStyle[prop])
|
|
127
|
+
continue; // the class supplies it
|
|
128
|
+
overrides[prop] = value;
|
|
129
|
+
}
|
|
130
|
+
return overrides;
|
|
131
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ImageContent, ProfileContent, TextContent, PageStyles, Content, BrandPageModel, ImageGalleryContent, GalleryStyles, MailingListContent, ContactFormContent, BannerSectionContent, ImagesSectionContent, BrandPageType, PageHeaderDesktop, PageFooterDesktop, PageFooterMobile, PageHeaderMobile, LogoImageModel, LogoTemplateImageModel, BookingSectionContent, NavModel } from '../models';
|
|
1
|
+
import type { ImageContent, ProfileContent, TextContent, PageStyles, Content, BrandPageModel, ImageGalleryContent, GalleryStyles, MailingListContent, ContactFormContent, BannerSectionContent, ImagesSectionContent, BrandPageType, TextStyleDeclaration, TextStyles, PageHeaderDesktop, PageFooterDesktop, PageFooterMobile, PageHeaderMobile, LogoImageModel, LogoTemplateImageModel, BookingSectionContent, NavModel } from '../models';
|
|
2
2
|
import type { ImageViewModel, LogoViewModel, ProfileViewModel, TextViewModel, ContentViewModel, BrandPageViewModel, ImageGalleryViewModel, MailingListViewModel, ContactFormViewModel, PageViewModel, BannerSectionViewModel, PageHeaderViewModel, PageFooterViewModel, TextImageSectionViewModel, BookingSectionViewModel, PageStylesViewModel, NavViewModel } from '../view-models';
|
|
3
3
|
import type { ContentTextStylePropertyKey } from '../constants';
|
|
4
4
|
export declare const applyViewModelTextStyles: <T extends ContentViewModel>(content: T, styles: PageStyles, containerDefaults?: Partial<Record<ContentTextStylePropertyKey, string>>) => T;
|
|
@@ -13,6 +13,13 @@ export declare const mapToImagesSectionViewModel: (content: ImagesSectionContent
|
|
|
13
13
|
export declare const mapToBookingSectionViewModel: (content: BookingSectionContent, styles: PageStyles) => BookingSectionViewModel;
|
|
14
14
|
export declare const mapToNavViewModel: (nav: NavModel, brandPageSlug?: string, isCustomDomain?: boolean) => NavViewModel;
|
|
15
15
|
export declare const mapToPageStyleViewModel: (pageStyles: PageStyles, options: ViewModelMappingOptions) => PageStylesViewModel;
|
|
16
|
+
/**
|
|
17
|
+
* The Save Contact label's typography: only its own field, plus its role. Save Contact only ever
|
|
18
|
+
* draws through Button text (S8) — whatever role the stored field names, canonical or retired,
|
|
19
|
+
* is normalised to it, so a stray role never reaches this label. `TextWrapper` then references
|
|
20
|
+
* the role for the rest, the same as any other role-linked text.
|
|
21
|
+
*/
|
|
22
|
+
export declare const resolveSaveContactTitleStyle: (buttonTextStyle: TextStyleDeclaration | undefined, textStyles: TextStyles | undefined) => TextStyleDeclaration;
|
|
16
23
|
export declare const mapToPageHeaderViewModel: (pageHeader: PageHeaderDesktop | PageHeaderMobile, pageStyles: PageStyles, pages: PageViewModel[], useOldLogoRenderSize?: boolean) => PageHeaderViewModel;
|
|
17
24
|
export declare const mapToPageFooterViewModel: (pageFooter: PageFooterDesktop | PageFooterMobile, pageStyles: PageStyles, useOldLogoRenderSize?: boolean) => PageFooterViewModel;
|
|
18
25
|
export declare const mapToViewModel: (styles: PageStyles, brandPageType: BrandPageType, options: ViewModelMappingOptions) => (content: Content) => ContentViewModel | undefined;
|
|
@@ -40,6 +47,7 @@ export declare const applyLogoImageToBrandPageModel: (model: BrandPageModel, log
|
|
|
40
47
|
export declare const applyLogoTemplateImageToBrandPageViewModel: (viewModel: BrandPageViewModel, logoTemplateImage: LogoTemplateImageModel) => BrandPageViewModel;
|
|
41
48
|
export interface CriticalResourceURLs {
|
|
42
49
|
images: string[];
|
|
50
|
+
/** Always empty: the renderer layout preloads every font (`0036-retire-text-font-family.md`). */
|
|
43
51
|
fonts: string[];
|
|
44
52
|
shapes: string[];
|
|
45
53
|
}
|
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
import { reactive } from 'vue';
|
|
2
|
+
import { collectRteTextColors } from '@shared/color-strategies/rte-color';
|
|
2
3
|
import { assertUnreachable } from '../../helpers/ts.helper';
|
|
3
|
-
import { ButtonStyles, TEXT_STYLE_TYPES, VIEWPORTS } from '../models';
|
|
4
|
+
import { ButtonStyles, TEXT_STYLE_TYPES, VIEWPORTS, isLegacyTextStyleType, isCanonicalTextStyleType, } from '../models';
|
|
4
5
|
import { NavigationMobile, NavigationDesktop, BRAND_PAGE_TYPES, BUTTON_LINK_TYPE, NavigationMenuStyles, } from '../models';
|
|
5
6
|
import { backgroundColorFromStyle, isTransparentColour, mutedTextForBackground, withColorOpacity, } from './color.util';
|
|
6
7
|
import { resolveColorReference } from './color-palette.util';
|
|
7
|
-
import { containerTextColorDefaults, containerSurfaceForContent, } from './container-text-color.util';
|
|
8
|
-
import { CONTENT_TEXT_STYLE_PROPERTY_KEYS, FALLBACK_DEFAULT_LINK_COLOR,
|
|
8
|
+
import { containerTextColorDefaults, containerSurfaceForContent, titleSurfaceContrastFill, } from './container-text-color.util';
|
|
9
|
+
import { CONTENT_TEXT_STYLE_PROPERTY_KEYS, FALLBACK_DEFAULT_LINK_COLOR, DEFAULT_LOGO_HEIGHT, DEFAULT_LOGO_WIDTH, ALIGN_LEFT_ALIGNED, ALIGN_RIGHT_ALIGNED, MAX_IMAGES_SECTION_ALIGNMENT_ITEMS_LENGTH, DEFAULT_TEXT_ALIGN, IMAGE_RESOLUTION_PRESETS, BIG_IMAGE, ALIGN_LEFT_BIG_IMAGE, ALIGN_CARD_CENTER, ALIGN_CARD_CENTER_IMAGE, ALIGN_CARD_LEFT_IMAGE, ALIGN_LEFT_FULL_IMAGE, ALIGN_RIGHT_FULL_IMAGE, } from '../constants';
|
|
9
10
|
import uniq from 'lodash/uniq';
|
|
10
|
-
import { generateGoogleFontUrl } from './font-loader.util';
|
|
11
11
|
import { isValidSvgUrl } from './image.util';
|
|
12
12
|
import { isLogoContent } from './model.util';
|
|
13
|
-
import { resolveTextColor } from './text-style.util';
|
|
13
|
+
import { resolveTextColor, pickTypography } from './text-style.util';
|
|
14
|
+
import { contentFieldReconnectSpec, computeLegacyTargets, bestFitRole, } from './text-role-reconnect.util';
|
|
14
15
|
import { getBoxShadowValue, sectionFrameStyle } from './button.util';
|
|
15
16
|
import { findNavItemByPageId, getRouteNameByPageIndex, getRouteParamsByPage, } from './route.util';
|
|
16
17
|
import { hasRTEContent, isTiptapDocument } from '../../brand-page-maker/utils';
|
|
17
|
-
import { getPageIdFromHref
|
|
18
|
+
import { getPageIdFromHref } from '../../brand-page-maker/composables/rich-text-editor/hyperlink';
|
|
19
|
+
import { isHrefPageId } from '@shared/rte-link.util';
|
|
18
20
|
const BUTTON_BORDER_RADIUS = '9999px';
|
|
19
21
|
const CONTENT_BORDER_RADIUS = '48px';
|
|
20
22
|
const PROFILE_PADDING_TOP = '1rem';
|
|
@@ -33,53 +35,66 @@ const applyDefaultViewModelTextStyle = (textStyle) => {
|
|
|
33
35
|
wordBreak: 'normal',
|
|
34
36
|
});
|
|
35
37
|
};
|
|
36
|
-
const getTextStyleByContentTextStyle = (contentTextStyle, textStyleOptions) => {
|
|
38
|
+
const getTextStyleByContentTextStyle = (contentTextStyle, textStyleOptions, startingRole) => {
|
|
37
39
|
if (!contentTextStyle) {
|
|
38
40
|
return undefined;
|
|
39
41
|
}
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
textDecoration: textStyle.textDecoration || undefined,
|
|
51
|
-
textStyleType: textStyle.textStyleType || undefined,
|
|
52
|
-
});
|
|
53
|
-
}
|
|
54
|
-
return contentTextStyle;
|
|
42
|
+
// Page data keeps only what the field itself sets; the painter references the role for the
|
|
43
|
+
// rest (`roleTypographyStyle`). Links keep a concrete colour last resort — they must never
|
|
44
|
+
// inherit.
|
|
45
|
+
return Object.assign({}, pickTypography(contentTextStyle), {
|
|
46
|
+
color: resolveTextColor(contentTextStyle) || FALLBACK_DEFAULT_LINK_COLOR,
|
|
47
|
+
textStyleType: fallbackTextRole(undefined,
|
|
48
|
+
// Both call sites always pass a startingRole, which fallbackTextRole returns before it
|
|
49
|
+
// ever consults key — so no key value reaches contentFieldReconnectSpec here.
|
|
50
|
+
'', contentTextStyle, textStyleOptions, startingRole),
|
|
51
|
+
});
|
|
55
52
|
};
|
|
56
|
-
const getCopyrightTextStyle = (contentTextStyle, textStyleOptions) => {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
53
|
+
const getCopyrightTextStyle = (contentTextStyle, textStyleOptions) => applyDefaultViewModelTextStyle(Object.assign({}, pickTypography(contentTextStyle), {
|
|
54
|
+
color: resolveTextColor(contentTextStyle),
|
|
55
|
+
applyAutoScale: contentTextStyle.applyAutoScale,
|
|
56
|
+
textAlign: contentTextStyle.textAlign || DEFAULT_TEXT_ALIGN,
|
|
57
|
+
textStyleType: fallbackTextRole(undefined, 'copyrightStyle', contentTextStyle, textStyleOptions),
|
|
58
|
+
}));
|
|
59
|
+
/**
|
|
60
|
+
* BP-5969 (R3) — the role a field draws through once it has no built-in default to fall back
|
|
61
|
+
* on: its own role when that's one of the ten; else an explicit `startingRole`, when the caller
|
|
62
|
+
* already knows it (S3: nav tabs and the hamburger reshape their key/content-type past what
|
|
63
|
+
* `contentFieldReconnectSpec` recognises, and `mapToButtonViewModel`'s callers reuse the
|
|
64
|
+
* SECTION's content type, not a button one — passing the role the upgrade actually assigns
|
|
65
|
+
* removes the dependency on either matching); else the field's starting role
|
|
66
|
+
* (`contentFieldReconnectSpec`, e.g. every button label is on Button text); else a retired
|
|
67
|
+
* role's successor (`computeLegacyTargets`); else the role nearest its own size, or Paragraph 1
|
|
68
|
+
* (`bestFitRole`). The same rule the upgrade and the AI boundary use (ADR 0021) — a field never
|
|
69
|
+
* reaches the page with no role, so a painter always has one to reference.
|
|
70
|
+
*/
|
|
71
|
+
const fallbackTextRole = (contentType, key, ownStyle, textStyleOptions, startingRole) => {
|
|
72
|
+
const type = ownStyle?.textStyleType;
|
|
73
|
+
if (isCanonicalTextStyleType(type))
|
|
74
|
+
return type;
|
|
75
|
+
if (startingRole)
|
|
76
|
+
return startingRole;
|
|
77
|
+
const spec = contentFieldReconnectSpec(contentType, key);
|
|
78
|
+
if (spec.startingRole)
|
|
79
|
+
return spec.startingRole;
|
|
80
|
+
if (isLegacyTextStyleType(type)) {
|
|
81
|
+
return computeLegacyTargets(textStyleOptions)[type];
|
|
66
82
|
}
|
|
67
|
-
return
|
|
83
|
+
return bestFitRole(ownStyle, spec.family);
|
|
68
84
|
};
|
|
69
85
|
const getTextStyleByContentTextStyleProperty = (content, contentPropKey, textStyleOptions, containerDefault) => {
|
|
70
86
|
const contentTextStyle = content[contentPropKey];
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
}
|
|
82
|
-
return applyDefaultViewModelTextStyle(contentTextStyle);
|
|
87
|
+
// BP-5969 (R1): page data keeps only what the field sets itself. Typography no longer
|
|
88
|
+
// merges the role's values in — the painter references the role for the rest
|
|
89
|
+
// (`roleTypographyStyle`/`fillRteRunTypography`). Colour keeps its own cascade (element,
|
|
90
|
+
// else the container default). Every field draws through a canonical role, real or a
|
|
91
|
+
// fallback (R3), so `textStyleType` is never legacy or missing in page data.
|
|
92
|
+
return applyDefaultViewModelTextStyle(Object.assign({}, pickTypography(contentTextStyle), {
|
|
93
|
+
color: resolveTextColor(contentTextStyle, containerDefault),
|
|
94
|
+
applyAutoScale: contentTextStyle.applyAutoScale,
|
|
95
|
+
textAlign: contentTextStyle.textAlign || DEFAULT_TEXT_ALIGN,
|
|
96
|
+
textStyleType: fallbackTextRole(content.type, contentPropKey, contentTextStyle, textStyleOptions),
|
|
97
|
+
}));
|
|
83
98
|
};
|
|
84
99
|
export const applyViewModelTextStyles = (content, styles, containerDefaults = {}) => {
|
|
85
100
|
Object.keys(CONTENT_TEXT_STYLE_PROPERTY_KEYS)
|
|
@@ -91,17 +106,19 @@ export const applyViewModelTextStyles = (content, styles, containerDefaults = {}
|
|
|
91
106
|
};
|
|
92
107
|
const applyViewModelTextItemTextStyles = (textItems, styles) => {
|
|
93
108
|
return textItems.map((item) => {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
109
|
+
// S6 — an item with no textStyle at all (no `?.` on the old code's own reads) threw in
|
|
110
|
+
// pickTypography/bestFitRole; falling back to `{}` gives every read below the same optional
|
|
111
|
+
// chaining an own textStyle already has.
|
|
112
|
+
const ownStyle = item.textStyle ?? {};
|
|
113
|
+
// BP-5969 (ADR-0020, R1): the item's style object is a slim role link (`RteTextRole`) that
|
|
114
|
+
// keeps only its own typography — the role is a reference the RTE run resolves at render
|
|
115
|
+
// (`fillRteRunTypography`). Colour rides the RTE mark, alignment the doc node.
|
|
116
|
+
const itemTextStyle = {
|
|
117
|
+
...pickTypography(ownStyle),
|
|
118
|
+
applyAutoScale: ownStyle.applyAutoScale,
|
|
119
|
+
textAlign: ownStyle.textAlign || DEFAULT_TEXT_ALIGN,
|
|
120
|
+
textStyleType: fallbackTextRole(undefined, 'textItems', ownStyle, styles.textStyles?.textStyleOptions),
|
|
121
|
+
};
|
|
105
122
|
return {
|
|
106
123
|
...item,
|
|
107
124
|
textStyle: itemTextStyle,
|
|
@@ -201,7 +218,12 @@ const mapToButtonViewModel = (content, styles, options) => {
|
|
|
201
218
|
},
|
|
202
219
|
selectedButtonStyleId: styles.buttonStyles.selectedButtonStyleId,
|
|
203
220
|
};
|
|
204
|
-
// Extract only text-related properties from titleStyle, excluding button styling properties
|
|
221
|
+
// Extract only text-related properties from titleStyle, excluding button styling properties.
|
|
222
|
+
// No built-in line-height default (R3): an unset label follows its role, real or a fallback.
|
|
223
|
+
// Every `mapToButtonViewModel` label starts on Button text (S3): some callers (the banner/
|
|
224
|
+
// booking/images section CTA) reuse the SECTION's own content type here, which
|
|
225
|
+
// `contentFieldReconnectSpec` doesn't recognise as button content, so an explicit
|
|
226
|
+
// `startingRole` is passed rather than relying on that match.
|
|
205
227
|
const textOnlyProperties = {
|
|
206
228
|
color: options.titleStyle?.color,
|
|
207
229
|
fontFamily: options.titleStyle?.fontFamily,
|
|
@@ -209,8 +231,8 @@ const mapToButtonViewModel = (content, styles, options) => {
|
|
|
209
231
|
fontWeight: options.titleStyle?.fontWeight,
|
|
210
232
|
textAlign: options.titleStyle?.textAlign,
|
|
211
233
|
letterSpacing: options.titleStyle?.letterSpacing,
|
|
212
|
-
lineHeight: options.titleStyle?.lineHeight
|
|
213
|
-
textStyleType: options.titleStyle?.
|
|
234
|
+
lineHeight: options.titleStyle?.lineHeight,
|
|
235
|
+
textStyleType: fallbackTextRole(content.type, 'titleStyle', options.titleStyle ?? {}, styles.textStyles?.textStyleOptions, 'button'),
|
|
214
236
|
applyAutoScale: options.titleStyle?.applyAutoScale,
|
|
215
237
|
textDecoration: options.titleStyle?.textDecoration,
|
|
216
238
|
fontStyle: options.titleStyle?.fontStyle,
|
|
@@ -245,21 +267,13 @@ export const mapToProfileViewModel = (content, styles) => {
|
|
|
245
267
|
}
|
|
246
268
|
: undefined;
|
|
247
269
|
containerStyle = applyContentBorderRadius(containerStyle);
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
lineHeight: content.titleStyle?.lineHeight || LINE_HEIGHT_BODY,
|
|
252
|
-
};
|
|
270
|
+
// R3: no built-in size or line height. An unset field draws through its role — real, or a
|
|
271
|
+
// fallback nearest its own size (`fallbackTextRole`, dispatched generically below).
|
|
272
|
+
const titleStyle = { ...content.titleStyle };
|
|
253
273
|
const descriptionStyle = {
|
|
254
274
|
...content.descriptionStyle,
|
|
255
|
-
fontSize: content.descriptionStyle?.fontSize || FONT_SIZE_BODY,
|
|
256
|
-
lineHeight: content.descriptionStyle?.lineHeight || LINE_HEIGHT_BODY,
|
|
257
|
-
};
|
|
258
|
-
const nameStyle = {
|
|
259
|
-
...content.nameStyle,
|
|
260
|
-
fontSize: content.nameStyle?.fontSize || FONT_SIZE_HEADINGS,
|
|
261
|
-
lineHeight: content.nameStyle?.lineHeight || LINE_HEIGHT_HEADINGS,
|
|
262
275
|
};
|
|
276
|
+
const nameStyle = { ...content.nameStyle };
|
|
263
277
|
return applyViewModelTextStyles({
|
|
264
278
|
...content,
|
|
265
279
|
role: content.type,
|
|
@@ -280,12 +294,9 @@ export const mapToTextViewModel = (content, styles, brandPageType) => {
|
|
|
280
294
|
}
|
|
281
295
|
: undefined;
|
|
282
296
|
containerStyle = applyContentBorderRadius(containerStyle);
|
|
283
|
-
|
|
297
|
+
// Migration-22 folds legacy textSize/alignment/colour into textStyle. Rendering only reads the
|
|
298
|
+
// canonical field, so a post-migration page has no runtime legacy-style fallback.
|
|
284
299
|
const contentTextStyle = {
|
|
285
|
-
lineHeight: LINE_HEIGHT_BODY,
|
|
286
|
-
...content.textSize,
|
|
287
|
-
...content.textAlignment,
|
|
288
|
-
...content.textColor,
|
|
289
300
|
...content.textStyle,
|
|
290
301
|
};
|
|
291
302
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -337,11 +348,8 @@ export const mapToMailingListViewModel = (content, styles) => {
|
|
|
337
348
|
},
|
|
338
349
|
selectedButtonStyleId: styles.buttonStyles.selectedButtonStyleId,
|
|
339
350
|
};
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
fontWeight: 'bold',
|
|
343
|
-
...content.titleStyle,
|
|
344
|
-
};
|
|
351
|
+
// R3: no built-in size or bold. An unset title draws through its role, real or a fallback.
|
|
352
|
+
const titleStyle = { ...content.titleStyle };
|
|
345
353
|
const viewModel = applyViewModelTextStyles({
|
|
346
354
|
...content,
|
|
347
355
|
role: content.type,
|
|
@@ -352,14 +360,14 @@ export const mapToMailingListViewModel = (content, styles) => {
|
|
|
352
360
|
// The disclosure sits on the block's card, not the button. The card can differ from
|
|
353
361
|
// the button fill (it defaults to the neutral-light role), so anchor the muted colour
|
|
354
362
|
// to the same surface the title uses (the block's own fill, else the button fill).
|
|
355
|
-
viewModel.disclosureColor = disclosureColorFor(containerSurfaceForContent(content, styles) ?? viewModel.styles?.style,
|
|
363
|
+
viewModel.disclosureColor = disclosureColorFor(containerSurfaceForContent(content, styles) ?? viewModel.styles?.style,
|
|
364
|
+
// BP-5969 (ADR-0020): the RTE title's colour lives in its mark, not the style object.
|
|
365
|
+
collectRteTextColors(content.title)?.colors[0], styles.colors);
|
|
356
366
|
return viewModel;
|
|
357
367
|
};
|
|
358
368
|
const mapToSupportMeViewModel = (content, styles) => {
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
...content.titleStyle,
|
|
362
|
-
};
|
|
369
|
+
// R3: no built-in bold. An unset title draws through its role, real or a fallback.
|
|
370
|
+
const titleStyle = { ...content.titleStyle };
|
|
363
371
|
return applyViewModelTextStyles({
|
|
364
372
|
...content,
|
|
365
373
|
role: content.type,
|
|
@@ -439,7 +447,9 @@ export const mapToContactFormViewModel = (content, styles, brandPageType) => {
|
|
|
439
447
|
isFullWidth: brandPageType === BRAND_PAGE_TYPES.brandSite &&
|
|
440
448
|
content.layoutStyle !== '',
|
|
441
449
|
}, styles, containerTextColorDefaults(content, styles, brandPageType));
|
|
442
|
-
viewModel.disclosureColor = disclosureColorFor(contactFormDisclosureSurface(viewModel, brandPageType),
|
|
450
|
+
viewModel.disclosureColor = disclosureColorFor(contactFormDisclosureSurface(viewModel, brandPageType),
|
|
451
|
+
// BP-5969 (ADR-0020): the RTE title's colour lives in its mark, not the style object.
|
|
452
|
+
collectRteTextColors(content.title)?.colors[0], styles.colors);
|
|
443
453
|
return viewModel;
|
|
444
454
|
};
|
|
445
455
|
const mapGettyVideoToGettyVideoViewModel = (media, options) => {
|
|
@@ -572,7 +582,7 @@ const mapToShapesSectionViewModel = (content, styles, brandPageType) => {
|
|
|
572
582
|
items: processedItems,
|
|
573
583
|
}, styles);
|
|
574
584
|
};
|
|
575
|
-
const mapToShopViewModel = (content, styles) => {
|
|
585
|
+
const mapToShopViewModel = (content, styles, brandPageType) => {
|
|
576
586
|
const buttonStyles = new ButtonStyles({
|
|
577
587
|
selectedButtonStyleId: styles.buttonStyles.selectedButtonStyleId,
|
|
578
588
|
style: {
|
|
@@ -594,6 +604,11 @@ const mapToShopViewModel = (content, styles) => {
|
|
|
594
604
|
},
|
|
595
605
|
isFullWidth: true,
|
|
596
606
|
isShippingEnabled: content.shopPaymentConfig?.isShippingEnabled ?? false,
|
|
607
|
+
// No page base coat to inherit (ADR-0020): the "no products" label is a fixed
|
|
608
|
+
// string, not a text field, so it takes the title's own colour when the title has
|
|
609
|
+
// one, else the same contrast colour the title itself would fall back to.
|
|
610
|
+
noProductsColor: collectRteTextColors(content.title)?.colors[0] ??
|
|
611
|
+
titleSurfaceContrastFill(content, styles, brandPageType),
|
|
597
612
|
}, styles);
|
|
598
613
|
};
|
|
599
614
|
const mapToTestimonialSectionViewModel = (content, styles) => {
|
|
@@ -616,14 +631,9 @@ const mapToSocialLinksViewModel = (content, styles, brandPageType) => {
|
|
|
616
631
|
...content,
|
|
617
632
|
role: content.type,
|
|
618
633
|
type: 'social-links',
|
|
619
|
-
//
|
|
620
|
-
//
|
|
621
|
-
// entry, so no resolver touches it and nothing else supplies the icon colour.
|
|
634
|
+
// No `color` pre-seed (see the testimonial mapper). The icon fill is stored — baked at
|
|
635
|
+
// birth and by migration-22 — so it takes no seed either.
|
|
622
636
|
titleStyle: { ...content.titleStyle },
|
|
623
|
-
iconFillStyles: {
|
|
624
|
-
fill: styles.textStyles?.textStyleOptions?.paragraphs?.style?.color,
|
|
625
|
-
...content.iconFillStyles,
|
|
626
|
-
},
|
|
627
637
|
isFullWidth: brandPageType === BRAND_PAGE_TYPES.brandSite,
|
|
628
638
|
}, styles);
|
|
629
639
|
};
|
|
@@ -704,7 +714,7 @@ const mapToHeaderButtonViewModel = (headerButton, styles) => {
|
|
|
704
714
|
return undefined;
|
|
705
715
|
}
|
|
706
716
|
const titleStyle = headerButton.buttonTextStyle ?? {
|
|
707
|
-
textStyleType: TEXT_STYLE_TYPES.
|
|
717
|
+
textStyleType: TEXT_STYLE_TYPES.button,
|
|
708
718
|
};
|
|
709
719
|
const viewModel = mapToButtonViewModel({
|
|
710
720
|
id: 'page-header-button',
|
|
@@ -742,6 +752,19 @@ const mapToHeaderButtonViewModel = (headerButton, styles) => {
|
|
|
742
752
|
},
|
|
743
753
|
};
|
|
744
754
|
};
|
|
755
|
+
/**
|
|
756
|
+
* The Save Contact label's typography: only its own field, plus its role. Save Contact only ever
|
|
757
|
+
* draws through Button text (S8) — whatever role the stored field names, canonical or retired,
|
|
758
|
+
* is normalised to it, so a stray role never reaches this label. `TextWrapper` then references
|
|
759
|
+
* the role for the rest, the same as any other role-linked text.
|
|
760
|
+
*/
|
|
761
|
+
export const resolveSaveContactTitleStyle = (buttonTextStyle,
|
|
762
|
+
// Unused: the label is always Button text (S8), so no role lookup is needed here — kept so
|
|
763
|
+
// SaveContactWidget.vue's existing call site (`props.textStyles`) doesn't need to change.
|
|
764
|
+
textStyles) => Object.assign({}, pickTypography(buttonTextStyle ?? {}), {
|
|
765
|
+
color: resolveTextColor(buttonTextStyle),
|
|
766
|
+
textStyleType: 'button',
|
|
767
|
+
});
|
|
745
768
|
export const mapToPageHeaderViewModel = (pageHeader, pageStyles, pages, useOldLogoRenderSize = false) => {
|
|
746
769
|
const viewport = pageHeader.viewport;
|
|
747
770
|
const logoContent = {
|
|
@@ -758,11 +781,11 @@ export const mapToPageHeaderViewModel = (pageHeader, pageStyles, pages, useOldLo
|
|
|
758
781
|
const logoStyles = {
|
|
759
782
|
imageStyle: pageStyles.logoStyles.imageStyle,
|
|
760
783
|
};
|
|
761
|
-
const navDefaultButtonTextStyle = getTextStyleByContentTextStyle(pageHeader.navigation.defaultButtonStyle, pageStyles.textStyles.textStyleOptions);
|
|
784
|
+
const navDefaultButtonTextStyle = getTextStyleByContentTextStyle(pageHeader.navigation.defaultButtonStyle, pageStyles.textStyles.textStyleOptions, 'paragraph1');
|
|
762
785
|
const navDefaultButtonStyle = Object.assign({}, pageHeader.navigation.defaultButtonStyle, navDefaultButtonTextStyle);
|
|
763
786
|
const { backgroundColor: _defaultBg, ...navDefaultTextStyleWithoutBg } = navDefaultButtonTextStyle || {};
|
|
764
787
|
const navSelectedButtonStyle = Object.assign({}, navDefaultTextStyleWithoutBg, pageHeader.navigation.selectedButtonStyle);
|
|
765
|
-
const hamburgerButtonTextStyle = getTextStyleByContentTextStyle(pageHeader.navigation.hamburgerMenuStyle.defaultButtonStyle, pageStyles.textStyles.textStyleOptions);
|
|
788
|
+
const hamburgerButtonTextStyle = getTextStyleByContentTextStyle(pageHeader.navigation.hamburgerMenuStyle.defaultButtonStyle, pageStyles.textStyles.textStyleOptions, 'button');
|
|
766
789
|
const hamburgerButtonStyle = Object.assign({}, pageHeader.navigation.hamburgerMenuStyle.defaultButtonStyle, hamburgerButtonTextStyle);
|
|
767
790
|
const { backgroundColor: _hamburgerDefaultBg, ...hamburgerTextStyleWithoutBg } = hamburgerButtonTextStyle || {};
|
|
768
791
|
const hamburgerSelectedButtonStyle = Object.assign({}, hamburgerTextStyleWithoutBg, pageHeader.navigation.hamburgerMenuStyle.selectedButtonStyle);
|
|
@@ -833,7 +856,6 @@ export const mapToPageFooterViewModel = (pageFooter, pageStyles, useOldLogoRende
|
|
|
833
856
|
iconStyle: { ...pageFooter.iconStyle },
|
|
834
857
|
logo: mapToLogoViewModel(logoContent, logoStyles, useOldLogoRenderSize),
|
|
835
858
|
socialLinks: pageFooter.socialLinks,
|
|
836
|
-
textFontFamily: pageFooter.textFontFamily,
|
|
837
859
|
};
|
|
838
860
|
};
|
|
839
861
|
export const mapToViewModel = (styles, brandPageType, options) => (content) => {
|
|
@@ -859,7 +881,7 @@ export const mapToViewModel = (styles, brandPageType, options) => (content) => {
|
|
|
859
881
|
case 'request-payment':
|
|
860
882
|
return mapToRequestPaymentViewModel(content, styles);
|
|
861
883
|
case 'shop-section':
|
|
862
|
-
return mapToShopViewModel(content, styles);
|
|
884
|
+
return mapToShopViewModel(content, styles, brandPageType);
|
|
863
885
|
case 'profile':
|
|
864
886
|
return mapToProfileViewModel(content, styles);
|
|
865
887
|
case 'text':
|
|
@@ -959,6 +981,7 @@ export const getBrandPageViewModelFromBrandPageModel = (model, brandPageToken, s
|
|
|
959
981
|
? {
|
|
960
982
|
isSavingEnabled: model.saveContactSettings.isSavingEnabled ?? true,
|
|
961
983
|
hideBranding: model.saveContactSettings.hideBranding ?? false,
|
|
984
|
+
buttonTextStyle: model.saveContactSettings.buttonTextStyle,
|
|
962
985
|
}
|
|
963
986
|
: { isSavingEnabled: true, hideBranding: false },
|
|
964
987
|
};
|
|
@@ -1113,17 +1136,8 @@ export const applyLogoTemplateImageToBrandPageViewModel = (viewModel, logoTempla
|
|
|
1113
1136
|
*/
|
|
1114
1137
|
export const getCriticalResourceURLs = (viewModel) => {
|
|
1115
1138
|
let images = [];
|
|
1116
|
-
let fonts = [];
|
|
1117
1139
|
let shapes = [];
|
|
1118
1140
|
try {
|
|
1119
|
-
// fonts
|
|
1120
|
-
const fontFamily = viewModel.styles?.textStyles?.textFontFamily;
|
|
1121
|
-
if (typeof fontFamily !== 'undefined' && fontFamily.length) {
|
|
1122
|
-
const fontConfig = FONT_FAMILY_CONFIGS[fontFamily];
|
|
1123
|
-
if (isGoogleType(fontConfig)) {
|
|
1124
|
-
fonts.push(generateGoogleFontUrl([fontConfig]));
|
|
1125
|
-
}
|
|
1126
|
-
}
|
|
1127
1141
|
// shapes
|
|
1128
1142
|
const bgShapeFullBg = viewModel.styles?.backgroundStylesViewModel.backgroundImageUrl;
|
|
1129
1143
|
if (typeof bgShapeFullBg !== 'undefined' && isValidSvgUrl(bgShapeFullBg)) {
|
|
@@ -1139,7 +1153,6 @@ export const getCriticalResourceURLs = (viewModel) => {
|
|
|
1139
1153
|
// }
|
|
1140
1154
|
// });
|
|
1141
1155
|
// }
|
|
1142
|
-
fonts = uniq(fonts);
|
|
1143
1156
|
images = uniq(images);
|
|
1144
1157
|
shapes = uniq(shapes);
|
|
1145
1158
|
}
|
|
@@ -1148,7 +1161,7 @@ export const getCriticalResourceURLs = (viewModel) => {
|
|
|
1148
1161
|
}
|
|
1149
1162
|
return {
|
|
1150
1163
|
images,
|
|
1151
|
-
fonts,
|
|
1164
|
+
fonts: [],
|
|
1152
1165
|
shapes,
|
|
1153
1166
|
};
|
|
1154
1167
|
};
|
|
@@ -65,6 +65,7 @@ export interface ShopViewModel extends ContentViewModel, Omit<ShopContent, 'type
|
|
|
65
65
|
buttonStyles: ButtonStyles;
|
|
66
66
|
isFullWidth: boolean;
|
|
67
67
|
isShippingEnabled: boolean;
|
|
68
|
+
noProductsColor?: string;
|
|
68
69
|
}
|
|
69
70
|
export interface ContactFormViewModel extends ContentViewModel, Omit<ContactFormContent, 'type'> {
|
|
70
71
|
buttonStyles: ButtonStyles;
|
|
@@ -66,6 +66,9 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
66
66
|
setHideBranding(payload: {
|
|
67
67
|
hideBranding: boolean;
|
|
68
68
|
}): void;
|
|
69
|
+
setSaveContactButtonTextStyle(payload: {
|
|
70
|
+
buttonTextStyle: import("@brand-page/models").SaveContactOptions["buttonTextStyle"];
|
|
71
|
+
}): void;
|
|
69
72
|
setSensitiveContent(payload: {
|
|
70
73
|
sensitiveContent: string;
|
|
71
74
|
}): void;
|
|
@@ -128,7 +131,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
128
131
|
brandPageType: import("@brand-page/models").BrandPageType;
|
|
129
132
|
}): void;
|
|
130
133
|
initialiseStoresByBrandPageModelAsync(brandPageModel: import("@brand-page/models").BrandPageModel): Promise<void>;
|
|
131
|
-
initialise({ brandPage, brandPageType, logoDraftDesignAttributes, unsplashApplicationName, templateCategories, personalisationData, isPersonalisationEnabled, userPromptContentKey, showAiTemplatesTab, businessName, industry, layout, logoVariationImageUrls, shopConfigData: _shopConfigData, isServerRenderOverride, }: import("@brand-page-maker/stores").InitialisePayload): Promise<void>;
|
|
134
|
+
initialise({ brandPage, brandPageType, logoDraftDesignAttributes, unsplashApplicationName, templateCategories, personalisationData, isPersonalisationEnabled, userPromptContentKey, showAiTemplatesTab, businessName, industry, layout, logoVariationImageUrls, shopConfigData: _shopConfigData, isServerRenderOverride, isBlankSite, }: import("@brand-page-maker/stores").InitialisePayload): Promise<void>;
|
|
132
135
|
initialisePages({ pages, sections, }: {
|
|
133
136
|
pages: import("@brand-page/models").PageModel[];
|
|
134
137
|
sections: import("../../../shared/page-settings/store").PageSettingsStateSections;
|