@designcrowd/library.brand-page 6.1.16-style-v2-2 → 6.1.17-ast-header-button

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.
Files changed (258) hide show
  1. package/lib/src/{CreatedOnBrandCrowd-de-de-Bi-zaYmr.js → CreatedOnBrandCrowd-de-de-Cwq9enJs.js} +1 -1
  2. package/lib/src/{CreatedOnBrandCrowd-en-us-SjIxE2Pg.js → CreatedOnBrandCrowd-en-us-ILK04gFj.js} +1 -1
  3. package/lib/src/{CreatedOnBrandCrowd-es-es-BYOu05ik.js → CreatedOnBrandCrowd-es-es-CbjxLxtu.js} +1 -1
  4. package/lib/src/{CreatedOnBrandCrowd-fr-fr-emgmIyJV.js → CreatedOnBrandCrowd-fr-ca-BwBDiK9z.js} +1 -1
  5. package/lib/src/{CreatedOnBrandCrowd-fr-ca-emgmIyJV.js → CreatedOnBrandCrowd-fr-fr-BwBDiK9z.js} +1 -1
  6. package/lib/src/{CreatedOnBrandCrowd-pt-pt-m5RFTaxL.js → CreatedOnBrandCrowd-pt-br-DvhJROpG.js} +1 -1
  7. package/lib/src/{CreatedOnBrandCrowd-pt-br-m5RFTaxL.js → CreatedOnBrandCrowd-pt-pt-DvhJROpG.js} +1 -1
  8. package/lib/src/{CreatedOnDcom-de-de-BeGHrZgm.js → CreatedOnDcom-de-de-BK9imWOh.js} +1 -1
  9. package/lib/src/{CreatedOnDcom-en-us-DvVpYfyp.js → CreatedOnDcom-en-us-CyH-_qz1.js} +1 -1
  10. package/lib/src/{CreatedOnDcom-es-es-D9khuP5r.js → CreatedOnDcom-es-es-Dh51qYEA.js} +1 -1
  11. package/lib/src/{CreatedOnDcom-fr-ca-BNIVPoPK.js → CreatedOnDcom-fr-ca-BArRxwWX.js} +1 -1
  12. package/lib/src/{CreatedOnDcom-fr-fr-CtdfFR8H.js → CreatedOnDcom-fr-fr-CdglI-ZB.js} +1 -1
  13. package/lib/src/{CreatedOnDcom-pt-br-nFGKCRjM.js → CreatedOnDcom-pt-br-DCehns-G.js} +1 -1
  14. package/lib/src/{CreatedOnDcom-pt-pt-BCFCFJoy.js → CreatedOnDcom-pt-pt-B8hl-oew.js} +1 -1
  15. package/lib/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.d.ts +27 -2
  16. package/lib/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.js +26 -0
  17. package/lib/src/brand-page/components/page/Page.mixin.d.ts +1 -4
  18. package/lib/src/brand-page/components/page/Page.mixin.js +9 -26
  19. package/lib/src/brand-page/components/page-header/PageHeader.mixin.d.ts +3 -1
  20. package/lib/src/brand-page/components/page-header/PageHeader.mixin.js +12 -0
  21. package/lib/src/brand-page/components/social-links/SocialLinks.stories.js +3 -0
  22. package/lib/src/brand-page/components/testimonial-section/__fixtures__/data.js +3 -0
  23. package/lib/src/brand-page/components/text/Text.stories.js +17 -0
  24. package/lib/src/brand-page/constants/font.constants.d.ts +0 -62
  25. package/lib/src/brand-page/constants/font.constants.js +0 -35
  26. package/lib/src/brand-page/models/index.d.ts +32 -20
  27. package/lib/src/brand-page/models/index.js +3 -0
  28. package/lib/src/brand-page/models/styles.model.d.ts +1 -45
  29. package/lib/src/brand-page/models/styles.model.js +22 -106
  30. package/lib/src/brand-page/utils/button.util.d.ts +5 -0
  31. package/lib/src/brand-page/utils/button.util.js +4 -0
  32. package/lib/src/brand-page/utils/container-text-color.util.d.ts +13 -21
  33. package/lib/src/brand-page/utils/container-text-color.util.js +27 -71
  34. package/lib/src/brand-page/utils/index.d.ts +0 -1
  35. package/lib/src/brand-page/utils/index.js +0 -1
  36. package/lib/src/brand-page/utils/migration/migration-21.js +4 -15
  37. package/lib/src/brand-page/utils/migration.util.js +0 -16
  38. package/lib/src/brand-page/utils/text-style.util.d.ts +18 -45
  39. package/lib/src/brand-page/utils/text-style.util.js +18 -69
  40. package/lib/src/brand-page/utils/view-model.util.d.ts +1 -0
  41. package/lib/src/brand-page/utils/view-model.util.js +70 -25
  42. package/lib/src/brand-page/view-models.d.ts +3 -1
  43. package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.d.ts +1 -2
  44. package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.js +10 -0
  45. package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/content-settings-items.fixture.js +1 -0
  46. package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts +135 -6
  47. package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.js +28 -0
  48. package/lib/src/brand-page-maker/components/navigation/Navigation.mixin.d.ts +1 -1
  49. package/lib/src/brand-page-maker/composables/rich-text-editor/font.d.ts +1 -2
  50. package/lib/src/brand-page-maker/composables/rich-text-editor/font.js +6 -25
  51. package/lib/src/brand-page-maker/composables/rich-text-editor/formatting.d.ts +3 -17
  52. package/lib/src/brand-page-maker/composables/rich-text-editor/formatting.js +14 -108
  53. package/lib/src/brand-page-maker/composables/rich-text-editor/getRteExtensions.js +0 -4
  54. package/lib/src/brand-page-maker/composables/rich-text-editor/spacing.d.ts +1 -2
  55. package/lib/src/brand-page-maker/composables/rich-text-editor/spacing.js +6 -22
  56. package/lib/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.d.ts +0 -7
  57. package/lib/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.js +175 -216
  58. package/lib/src/brand-page-maker/default-getters/payment-text-and-border-color.default-getter.js +14 -7
  59. package/lib/src/brand-page-maker/default-getters/text-color.default-getter.js +13 -6
  60. package/lib/src/brand-page-maker/models/content-settings.js +48 -48
  61. package/lib/src/brand-page-maker/stores/ai-checkpoint/ai-checkpoint-store.d.ts +1180 -1048
  62. package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +9 -2
  63. package/lib/src/brand-page-maker/stores/history/history-store.d.ts +1 -1
  64. package/lib/src/brand-page-maker/utils/index.d.ts +0 -1
  65. package/lib/src/brand-page-maker/utils/index.js +0 -1
  66. package/lib/src/brand-page-maker/utils/rich-text-editor.util.d.ts +7 -52
  67. package/lib/src/brand-page-maker/utils/rich-text-editor.util.js +262 -205
  68. package/lib/src/brand-page-maker/utils/rte-render.util.d.ts +0 -10
  69. package/lib/src/brand-page-maker/utils/rte-render.util.js +0 -19
  70. package/lib/src/brand-page-maker/utils/rte-sanitize.util.js +3 -7
  71. package/lib/src/{bundled-translations-CQ8dZIIe.js → bundled-translations-B8fAEel0.js} +9 -9
  72. package/lib/src/{bundled-translations.de-DE-D10ohBT0.js → bundled-translations.de-DE-FhH2H_rd.js} +9 -9
  73. package/lib/src/{bundled-translations.es-ES-C1o3tbHg.js → bundled-translations.es-ES-_ZExxMi7.js} +5 -5
  74. package/lib/src/{bundled-translations.fr-CA-ClHWmoIS.js → bundled-translations.fr-CA-Tg-ODIiC.js} +9 -9
  75. package/lib/src/{bundled-translations.fr-FR-C_PgkOpB.js → bundled-translations.fr-FR-C0sU51Mz.js} +9 -9
  76. package/lib/src/{bundled-translations.pt-BR-Csr8_jy7.js → bundled-translations.pt-BR-MYFIhA4u.js} +25 -25
  77. package/lib/src/{bundled-translations.pt-PT-D-vjMoOD.js → bundled-translations.pt-PT-DeUBSzCB.js} +17 -17
  78. package/lib/src/bundles/bundled-translations.de-DE.json +1 -17
  79. package/lib/src/bundles/bundled-translations.es-ES.json +1 -17
  80. package/lib/src/bundles/bundled-translations.fr-CA.json +1 -17
  81. package/lib/src/bundles/bundled-translations.fr-FR.json +1 -17
  82. package/lib/src/bundles/bundled-translations.json +9 -19
  83. package/lib/src/bundles/bundled-translations.pt-BR.json +1 -17
  84. package/lib/src/bundles/bundled-translations.pt-PT.json +1 -17
  85. package/lib/src/composables/useTranslate.d.ts +1 -1
  86. package/lib/src/composables/useTranslate.js +1 -1
  87. package/lib/src/css/library.brand-page-brandCrowd.min.css +403 -276
  88. package/lib/src/css/library.brand-page-brandPage.min.css +403 -276
  89. package/lib/src/css/library.brand-page-designCom.min.css +403 -276
  90. package/lib/src/css/library.brand-page-preview.min.css +403 -276
  91. package/lib/src/index.d.ts +1 -0
  92. package/lib/src/index.mjs +192 -194
  93. package/lib/src/{lib-D8usF-qk.js → lib-KFjPFfxn.js} +28918 -29318
  94. package/lib/src/lib.js +1 -0
  95. package/lib/src/metadata-builder/metadata-executor.js +1 -16
  96. package/lib/src/shared/color-palette/section-color-matches.js +24 -8
  97. package/lib/src/shared/color-strategies/rte-field-pairs.d.ts +0 -14
  98. package/lib/src/shared/color-strategies/rte-field-pairs.js +0 -23
  99. package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.d.ts +135 -2
  100. package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.js +27 -1
  101. package/lib/src/shared/content-settings/components/content-settings/ReplaceImageSettingsForContent.mixin.d.ts +1 -2
  102. package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItem.mixin.d.ts +0 -1
  103. package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.d.ts +2 -3
  104. package/lib/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.d.ts +1 -1
  105. package/lib/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.js +7 -0
  106. package/lib/src/shared/content-settings/components/payment-config-field/PaymentConfigField.mixin.d.ts +1 -1
  107. package/lib/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.d.ts +11 -1238
  108. package/lib/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.js +47 -160
  109. package/lib/src/shared/content-settings/store/content-settings-store.d.ts +0 -1
  110. package/lib/src/shared/content-settings/store/content-settings-store.js +7 -75
  111. package/lib/src/shared/ecommerce-settings/util/refreshDuplicatedMetadata.d.ts +11 -0
  112. package/lib/src/shared/ecommerce-settings/util/refreshDuplicatedMetadata.js +80 -0
  113. package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +1 -1
  114. package/lib/src/shared/navigation-style-settings/store/index.js +2 -3
  115. package/lib/src/shared/page-settings/components/delete-page-modal/DeletePageModal.mixin.d.ts +1 -1
  116. package/lib/src/shared/page-settings/components/new-page-modal/NewPageModal.mixin.d.ts +1 -1
  117. package/lib/src/shared/page-settings/components/page-settings/PageSettings.mixin.d.ts +113 -2
  118. package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +118 -3
  119. package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.js +43 -1
  120. package/lib/src/shared/page-settings/store/page-settings-store.d.ts +2 -2
  121. package/lib/src/shared/style-settings/components/StyleSettings.mixin.d.ts +5 -150
  122. package/lib/src/shared/style-settings/store/style-settings-store.d.ts +1 -0
  123. package/lib/src/shared/style-settings/store/style-settings-store.js +4 -3
  124. package/package.json +1 -1
  125. package/src/brand-page/components/about-section/AboutSection.vue.test.ts +10 -0
  126. package/src/brand-page/components/button/Button.vue +35 -8
  127. package/src/brand-page/components/button/Button.vue.test.ts +59 -0
  128. package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.mixin.ts +29 -1
  129. package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.vue +36 -0
  130. package/src/brand-page/components/navigation/navigation-side-menu/NavigationSideMenu.vue.test.ts +175 -0
  131. package/src/brand-page/components/page/Page.mixin.ts +11 -32
  132. package/src/brand-page/components/page/Page.vue +6 -6
  133. package/src/brand-page/components/page-header/HeaderLayout.vue +198 -4
  134. package/src/brand-page/components/page-header/PageHeader.mixin.ts +16 -1
  135. package/src/brand-page/components/page-header/PageHeader.vue +23 -1
  136. package/src/brand-page/components/page-header/PageHeader.vue.test.ts +378 -0
  137. package/src/brand-page/components/social-links/SocialLinks.stories.ts +3 -0
  138. package/src/brand-page/components/social-links/SocialLinks.vue.test.ts +3 -0
  139. package/src/brand-page/components/testimonial-section/__fixtures__/data.ts +3 -0
  140. package/src/brand-page/components/text/Text.stories.ts +17 -0
  141. package/src/brand-page/components/text-wrapper/TextWrapper.vue +14 -139
  142. package/src/brand-page/constants/font.constants.ts +0 -37
  143. package/src/brand-page/models/header-button.model.test.ts +86 -0
  144. package/src/brand-page/models/index.ts +35 -20
  145. package/src/brand-page/models/styles.model.ts +38 -161
  146. package/src/brand-page/utils/__snapshots__/migration.util.test.ts.snap +38 -591
  147. package/src/brand-page/utils/__snapshots__/migration2.util.test.ts.snap +6 -150
  148. package/src/brand-page/utils/__snapshots__/model.util.test.ts.snap +12 -300
  149. package/src/brand-page/utils/button.util.ts +8 -0
  150. package/src/brand-page/utils/container-text-color.util.test.ts +15 -106
  151. package/src/brand-page/utils/container-text-color.util.ts +32 -92
  152. package/src/brand-page/utils/index.ts +0 -1
  153. package/src/brand-page/utils/migration/migration-01.ts +237 -293
  154. package/src/brand-page/utils/migration/migration-02.ts +1 -8
  155. package/src/brand-page/utils/migration/migration-20_5.test.ts +1 -1
  156. package/src/brand-page/utils/migration/migration-21.ts +5 -24
  157. package/src/brand-page/utils/migration.util.test.ts +31 -92
  158. package/src/brand-page/utils/migration.util.ts +0 -17
  159. package/src/brand-page/utils/text-style.util.ts +20 -95
  160. package/src/brand-page/utils/view-model.util.test.ts +231 -219
  161. package/src/brand-page/utils/view-model.util.ts +96 -32
  162. package/src/brand-page/view-models.ts +3 -0
  163. package/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.ts +10 -0
  164. package/src/brand-page-maker/components/brand-page-maker/__fixtures__/content-settings-items.fixture.ts +1 -0
  165. package/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.ts +44 -0
  166. package/src/brand-page-maker/components/rich-text-editor/RichTextEditor.vue +181 -388
  167. package/src/brand-page-maker/composables/rich-text-editor/font.ts +5 -36
  168. package/src/brand-page-maker/composables/rich-text-editor/formatting.test.ts +0 -88
  169. package/src/brand-page-maker/composables/rich-text-editor/formatting.ts +14 -153
  170. package/src/brand-page-maker/composables/rich-text-editor/getRteExtensions.ts +0 -4
  171. package/src/brand-page-maker/composables/rich-text-editor/spacing.ts +6 -31
  172. package/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.ts +187 -285
  173. package/src/brand-page-maker/default-getters/payment-text-and-border-color.default-getter.ts +22 -7
  174. package/src/brand-page-maker/default-getters/text-color.default-getter.ts +21 -5
  175. package/src/brand-page-maker/models/content-settings.ts +48 -48
  176. package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +35 -0
  177. package/src/brand-page-maker/utils/__snapshots__/rte-render-parity.test.ts.snap +0 -9
  178. package/src/brand-page-maker/utils/index.ts +0 -1
  179. package/src/brand-page-maker/utils/rich-text-editor.util.test.ts +409 -186
  180. package/src/brand-page-maker/utils/rich-text-editor.util.ts +485 -240
  181. package/src/brand-page-maker/utils/rte-render.util.ts +0 -26
  182. package/src/brand-page-maker/utils/rte-sanitize.util.ts +3 -7
  183. package/src/bundles/bundled-translations.de-DE.json +1 -17
  184. package/src/bundles/bundled-translations.es-ES.json +1 -17
  185. package/src/bundles/bundled-translations.fr-CA.json +1 -17
  186. package/src/bundles/bundled-translations.fr-FR.json +1 -17
  187. package/src/bundles/bundled-translations.json +9 -19
  188. package/src/bundles/bundled-translations.pt-BR.json +1 -17
  189. package/src/bundles/bundled-translations.pt-PT.json +1 -17
  190. package/src/composables/useTranslate.ts +1 -2
  191. package/src/lib.ts +1 -0
  192. package/src/metadata-builder/metadata-executor.ts +1 -18
  193. package/src/shared/color-palette/section-color-matches.test.ts +11 -15
  194. package/src/shared/color-palette/section-color-matches.ts +27 -8
  195. package/src/shared/color-strategies/rte-field-pairs.ts +0 -28
  196. package/src/shared/content-settings/components/color-matches-panel/ColorMatchesPanel.test.ts +66 -43
  197. package/src/shared/content-settings/components/color-matches-panel/ColorMatchesPanel.vue +1 -7
  198. package/src/shared/content-settings/components/content-settings/ContentSettings.mixin.ts +48 -1
  199. package/src/shared/content-settings/components/focused-content-item-settings/FocusedContentItemSettings.mixin.ts +6 -0
  200. package/src/shared/content-settings/components/text-items-field/TextItemsField.mixin.test.ts +1 -0
  201. package/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.test.ts +23 -247
  202. package/src/shared/content-settings/components/text-style-field/TextStyleField.mixin.ts +53 -179
  203. package/src/shared/content-settings/components/text-style-field/TextStyleField.vue +1 -39
  204. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.de-DE.json +10 -15
  205. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.es-ES.json +10 -15
  206. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.fr-CA.json +10 -15
  207. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.fr-FR.json +10 -15
  208. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.json +1 -6
  209. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.pt-BR.json +10 -15
  210. package/src/shared/content-settings/components/text-style-field/i18n/text-style-field.pt-PT.json +10 -15
  211. package/src/shared/content-settings/store/content-settings-store.test.ts +5 -111
  212. package/src/shared/content-settings/store/content-settings-store.ts +16 -107
  213. package/src/shared/ecommerce-settings/util/refreshDuplicatedMetadata.test.ts +399 -0
  214. package/src/shared/ecommerce-settings/util/refreshDuplicatedMetadata.ts +99 -0
  215. package/src/shared/navigation-style-settings/store/index.ts +3 -3
  216. package/src/shared/page-settings/components/header-settings-panel/HeaderSettingsPanel.button-section.test.ts +126 -0
  217. package/src/shared/page-settings/components/header-settings-panel/HeaderSettingsPanel.vue +43 -6
  218. package/src/shared/page-settings/components/page-settings-section-styles/HeaderButtonSettings.test.ts +167 -0
  219. package/src/shared/page-settings/components/page-settings-section-styles/HeaderButtonSettings.vue +237 -0
  220. package/src/shared/page-settings/components/page-settings-section-styles/HeaderDisplayStyle.test.ts +160 -0
  221. package/src/shared/page-settings/components/page-settings-section-styles/HeaderDisplayStyle.vue +37 -8
  222. package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.header-button.test.ts +113 -0
  223. package/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.ts +47 -0
  224. package/src/shared/page-settings/components/page-settings-section-styles/i18n/page-settings-section.json +7 -1
  225. package/src/shared/page-settings/store/page-settings-store.ts +2 -0
  226. package/src/shared/style-settings/components/StyleSettings.vue +25 -29
  227. package/src/shared/style-settings/components/StyleSettingsSection.vue +8 -0
  228. package/src/shared/style-settings/components/i18n/style-settings.de-DE.json +20 -31
  229. package/src/shared/style-settings/components/i18n/style-settings.es-ES.json +20 -31
  230. package/src/shared/style-settings/components/i18n/style-settings.fr-CA.json +20 -31
  231. package/src/shared/style-settings/components/i18n/style-settings.fr-FR.json +20 -31
  232. package/src/shared/style-settings/components/i18n/style-settings.json +3 -12
  233. package/src/shared/style-settings/components/i18n/style-settings.pt-BR.json +20 -31
  234. package/src/shared/style-settings/components/i18n/style-settings.pt-PT.json +20 -31
  235. package/src/shared/style-settings/components/text-style-options-settings-with-state/TextStyleOptionsSettingsWithState.vue +34 -13
  236. package/src/shared/style-settings/store/style-settings-store.ts +4 -3
  237. package/lib/src/brand-page/utils/migration/migration-22.d.ts +0 -102
  238. package/lib/src/brand-page/utils/migration/migration-22.js +0 -605
  239. package/lib/src/brand-page/utils/text-role-css.util.d.ts +0 -112
  240. package/lib/src/brand-page/utils/text-role-css.util.js +0 -262
  241. package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/TextEffects.d.ts +0 -27
  242. package/lib/src/brand-page-maker/composables/rich-text-editor/extensions/TextEffects.js +0 -68
  243. package/lib/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.d.ts +0 -20
  244. package/lib/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.js +0 -60
  245. package/lib/src/brand-page-maker/utils/rte-authoring.util.d.ts +0 -2
  246. package/lib/src/brand-page-maker/utils/rte-authoring.util.js +0 -85
  247. package/src/brand-page/components/text-wrapper/TextWrapper.test.ts +0 -116
  248. package/src/brand-page/utils/migration/migration-22.test.ts +0 -929
  249. package/src/brand-page/utils/migration/migration-22.ts +0 -876
  250. package/src/brand-page/utils/text-role-css.util.test.ts +0 -268
  251. package/src/brand-page/utils/text-role-css.util.ts +0 -348
  252. package/src/brand-page/utils/text-style.util.test.ts +0 -138
  253. package/src/brand-page-maker/composables/rich-text-editor/block-typography.test.ts +0 -163
  254. package/src/brand-page-maker/composables/rich-text-editor/extensions/TextEffects.ts +0 -110
  255. package/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.test.ts +0 -80
  256. package/src/brand-page-maker/composables/rich-text-editor/keepMarksOnEmpty.ts +0 -75
  257. package/src/brand-page-maker/utils/rte-authoring.util.test.ts +0 -202
  258. package/src/brand-page-maker/utils/rte-authoring.util.ts +0 -156
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "275",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "251",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "250",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "237",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "237",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "263",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as e, createElementBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-D8usF-qk.js";
2
+ import { _ as t } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, h = {
4
4
  width: "263",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-D8usF-qk.js";
2
+ import { _ as e } from "./lib-KFjPFfxn.js";
3
3
  const M = {}, Z = {
4
4
  width: "242",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-D8usF-qk.js";
2
+ import { _ as e } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, M = {
4
4
  width: "231",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-D8usF-qk.js";
2
+ import { _ as e } from "./lib-KFjPFfxn.js";
3
3
  const M = {}, Z = {
4
4
  width: "230",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-D8usF-qk.js";
2
+ import { _ as e } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, l = {
4
4
  width: "216",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-D8usF-qk.js";
2
+ import { _ as e } from "./lib-KFjPFfxn.js";
3
3
  const i = {}, l = {
4
4
  width: "216",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as M } from "./lib-D8usF-qk.js";
2
+ import { _ as M } from "./lib-KFjPFfxn.js";
3
3
  const Z = {}, e = {
4
4
  width: "232",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { openBlock as H, createElementBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as M } from "./lib-D8usF-qk.js";
2
+ import { _ as M } from "./lib-KFjPFfxn.js";
3
3
  const Z = {}, e = {
4
4
  width: "232",
5
5
  height: "36",
@@ -1,6 +1,6 @@
1
1
  import type { PropType } from 'vue';
2
2
  import type { BrandPageContext, NavigationDesktop, NavigationMobile } from '../../../models';
3
- import type { NavItemViewModel } from '../../../view-models';
3
+ import type { ButtonViewModel, NavItemViewModel } from '../../../view-models';
4
4
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
5
5
  context: {
6
6
  type: PropType<BrandPageContext>;
@@ -18,6 +18,16 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
18
18
  type: PropType<NavigationDesktop | NavigationMobile>;
19
19
  required: true;
20
20
  };
21
+ headerButtonViewModel: {
22
+ type: PropType<ButtonViewModel>;
23
+ required: false;
24
+ default: undefined;
25
+ };
26
+ isMobile: {
27
+ type: BooleanConstructor;
28
+ required: false;
29
+ default: boolean;
30
+ };
21
31
  }>, {}, {
22
32
  expandedItems: Record<string, boolean>;
23
33
  }, {
@@ -27,12 +37,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
27
37
  selectedButtonStyle(): BrandPageCssStyle;
28
38
  defaultWrapperStyle(): BrandPageCssStyle;
29
39
  selectedWrapperStyle(): BrandPageCssStyle;
40
+ showHeaderButton(): boolean;
30
41
  routes(): any[];
31
42
  }, {
32
43
  filterHiddenNavItems(navItems: NavItemViewModel[]): NavItemViewModel[];
33
44
  isCurrentPage(navItem: NavItemViewModel): boolean;
34
45
  getSubNavItemStyle(navItem: NavItemViewModel): BrandPageCssStyle;
35
46
  closeSideMenu(): void;
47
+ onDrawerCtaClick(event: MouseEvent): void;
36
48
  toggleExpanded(pageId: string): void;
37
49
  isExpanded(pageId: string): boolean;
38
50
  expandSubPageIfCurrentPage(): void;
@@ -53,7 +65,20 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
53
65
  type: PropType<NavigationDesktop | NavigationMobile>;
54
66
  required: true;
55
67
  };
68
+ headerButtonViewModel: {
69
+ type: PropType<ButtonViewModel>;
70
+ required: false;
71
+ default: undefined;
72
+ };
73
+ isMobile: {
74
+ type: BooleanConstructor;
75
+ required: false;
76
+ default: boolean;
77
+ };
56
78
  }>> & Readonly<{
57
79
  "onClose-side-menu"?: ((...args: any[]) => any) | undefined;
58
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
80
+ }>, {
81
+ isMobile: boolean;
82
+ headerButtonViewModel: ButtonViewModel;
83
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
59
84
  export default _default;
@@ -18,6 +18,18 @@ export default defineComponent({
18
18
  type: Object,
19
19
  required: true,
20
20
  },
21
+ headerButtonViewModel: {
22
+ type: Object,
23
+ required: false,
24
+ default: undefined,
25
+ },
26
+ // The desktop drawer suppresses the header CTA — the desktop header row already
27
+ // renders it. Only the mobile drawer carries the button.
28
+ isMobile: {
29
+ type: Boolean,
30
+ required: false,
31
+ default: false,
32
+ },
21
33
  },
22
34
  emits: ['close-side-menu'],
23
35
  data() {
@@ -50,6 +62,9 @@ export default defineComponent({
50
62
  const { fontSize: _fontSize, lineHeight: _lineHeight, letterSpacing: _letterSpacing, ...rest } = this.selectedButtonStyle;
51
63
  return rest;
52
64
  },
65
+ showHeaderButton() {
66
+ return this.isMobile && Boolean(this.headerButtonViewModel);
67
+ },
53
68
  routes() {
54
69
  return this.visibleNavItems.map((navItem, _i) => {
55
70
  return {
@@ -85,6 +100,17 @@ export default defineComponent({
85
100
  closeSideMenu() {
86
101
  this.$emit('close-side-menu');
87
102
  },
103
+ // In the maker preview the CTA is inert (BP-5852 decision): capture-phase so the
104
+ // prevent lands before the inner anchor/router-link fires. On the published site
105
+ // the click follows the link and the drawer closes behind it.
106
+ onDrawerCtaClick(event) {
107
+ if (this.context.isPreview) {
108
+ event.preventDefault();
109
+ event.stopPropagation();
110
+ return;
111
+ }
112
+ this.closeSideMenu();
113
+ },
88
114
  toggleExpanded(pageId) {
89
115
  const isCurrentlyExpanded = this.expandedItems[pageId];
90
116
  this.expandedItems = {};
@@ -54,7 +54,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
54
54
  }, {
55
55
  brandPageToken(): string | null;
56
56
  paletteStyleHtml(): string;
57
- textRoleStyleHtml(): string;
58
57
  pageScopeAttrs(): Record<string, string | undefined>;
59
58
  contents(): ContentViewModel[];
60
59
  /**
@@ -168,7 +167,5 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
168
167
  isContentSelected: boolean;
169
168
  isHeaderSelected: boolean;
170
169
  isFooterSelected: boolean;
171
- }, {}, {}, {}, string, () => {
172
- [x: symbol]: import("vue").ComputedRef<any>;
173
- }, true, {}, any>;
170
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
174
171
  export default _default;
@@ -1,6 +1,6 @@
1
- import { computed, defineComponent } from 'vue';
1
+ import { defineComponent } from 'vue';
2
2
  import { DEFAULT_FONT_FAMILY_KEY, FALLBACK_FONT_FAMILIES, FONT_FAMILY_CONFIGS, } from '../../constants';
3
- import { getSlugFromContext, getPageHeadingText, buildPaletteRootCss, buildPaletteScopedCss, buildTextRoleRootCss, buildTextRoleScopedCss, TEXT_ROLE_OPTIONS_KEY, PAGE_SCOPE_ID_ATTRIBUTE, resolveColorReference, } from '@brand-page/utils';
3
+ import { getSlugFromContext, getPageHeadingText, buildPaletteRootCss, buildPaletteScopedCss, PAGE_SCOPE_ID_ATTRIBUTE, resolveColorReference, } from '@brand-page/utils';
4
4
  import { findNavItemByRelativePath } from '@brand-page/utils/route.util';
5
5
  import { BRAND_PAGE_TYPES } from '@brand-page/models';
6
6
  import { hasProfileContent as checkHasProfileContent } from '@brand-page/utils/vcard.util';
@@ -72,15 +72,6 @@ export default defineComponent({
72
72
  }),
73
73
  };
74
74
  },
75
- // BP-5969: expose the live role options to every descendant TextWrapper so it can
76
- // inline only its overrides and leave the role typography to the CSS class. A computed
77
- // keeps it reactive (a role edit repaints), and `this` is the instance in Options-API
78
- // provide(). Descendants that render outside a Page get `undefined` and bake inline.
79
- provide() {
80
- return {
81
- [TEXT_ROLE_OPTIONS_KEY]: computed(() => this.viewModel?.styles?.textStyles?.textStyleOptions),
82
- };
83
- },
84
75
  data() {
85
76
  return {
86
77
  isSideMenuOpen: false,
@@ -104,17 +95,6 @@ export default defineComponent({
104
95
  ? buildPaletteScopedCss(colors, this.pageScopeId)
105
96
  : buildPaletteRootCss(colors);
106
97
  },
107
- // BP-5969: the global text roles as a page-scoped <style> of CSS classes
108
- // (design-token render). Same root/scoped split as the palette above: a role
109
- // edit is one CSS-rule change that repaints every block carrying the role class.
110
- textRoleStyleHtml() {
111
- const options = this.viewModel?.styles?.textStyles?.textStyleOptions;
112
- if (!options)
113
- return '';
114
- return this.context?.isTemplate
115
- ? buildTextRoleScopedCss(options, this.pageScopeId)
116
- : buildTextRoleRootCss(options);
117
- },
118
98
  // Spread onto EVERY top-level node of Page's fragment (template mode only).
119
99
  // The root-background/overlay siblings paint values that can hold
120
100
  // `var(--palette-…)`, and a custom property applies to its own node too.
@@ -181,10 +161,13 @@ export default defineComponent({
181
161
  ...this.viewModel?.styles?.backgroundStylesViewModel?.style,
182
162
  };
183
163
  }
184
- // BP-5969 (ADR-0019): no page base coat. A role defines typography only, so `:root`
185
- // no longer paints a text colour — every text element carries its own contrast-derived
186
- // colour (baked at birth, or by migration-22 for existing sites). Form controls and SVG
187
- // `currentColor` fills fall back to the browser default.
164
+ // The page base coat — anything with no colour of its own inherits this
165
+ // (RTE text, form controls, SVG `currentColor` fills).
166
+ const baseTextColour = this.viewModel?.styles?.textStyles?.textStyleOptions?.paragraphs?.style
167
+ ?.color;
168
+ if (baseTextColour) {
169
+ styles.color = baseTextColour;
170
+ }
188
171
  const textFontFamilyKey = this.viewModel.styles?.textStyles.textFontFamily ||
189
172
  DEFAULT_FONT_FAMILY_KEY;
190
173
  const textFontFamilyConfig = FONT_FAMILY_CONFIGS[textFontFamilyKey];
@@ -1,6 +1,6 @@
1
1
  import type { PropType } from 'vue';
2
2
  import type { BrandPageContext } from '@brand-page/models';
3
- import type { PageHeaderViewModel } from '@brand-page/view-models';
3
+ import type { ButtonViewModel, PageHeaderViewModel } from '@brand-page/view-models';
4
4
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
5
5
  navId: {
6
6
  type: StringConstructor;
@@ -23,9 +23,11 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
23
23
  LOGO_SLIDER_DESKTOP_MAX: number;
24
24
  }, {
25
25
  containerCss(): BrandPageCssStyle;
26
+ headerButtonViewModel(): ButtonViewModel | undefined;
26
27
  showNav(): boolean;
27
28
  }, {
28
29
  onHeaderContainerClick(): void;
30
+ onHeaderCtaClick(event: MouseEvent): void;
29
31
  }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "header-container-click"[], "header-container-click", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
30
32
  navId: {
31
33
  type: StringConstructor;
@@ -33,6 +33,9 @@ export default defineComponent({
33
33
  padding: '1.5rem 0', // var(--page-padding) 0
34
34
  };
35
35
  },
36
+ headerButtonViewModel() {
37
+ return this.viewModel.headerButtonViewModel;
38
+ },
36
39
  showNav() {
37
40
  const visibleNavItems = this.context.nav.navItems.filter((item) => !item.isHidden);
38
41
  return (visibleNavItems.length > 1 ||
@@ -45,5 +48,14 @@ export default defineComponent({
45
48
  onHeaderContainerClick() {
46
49
  this.$emit('header-container-click');
47
50
  },
51
+ // In the maker preview the CTA is inert (BP-5852 decision): capture-phase so the
52
+ // prevent lands before the inner anchor/router-link fires, and the stop keeps the
53
+ // click from selecting the header panel. On the published site it does nothing.
54
+ onHeaderCtaClick(event) {
55
+ if (this.context.isPreview) {
56
+ event.preventDefault();
57
+ event.stopPropagation();
58
+ }
59
+ },
48
60
  },
49
61
  });
@@ -49,6 +49,9 @@ const viewModel = {
49
49
  iconBackgroundStyles: {},
50
50
  backgroundStyles: {},
51
51
  titleStyle: {
52
+ color: '#000000',
53
+ fontSize: '2.25rem',
54
+ fontWeight: 'bold',
52
55
  textAlign: 'center',
53
56
  },
54
57
  role: 'social-links',
@@ -37,6 +37,9 @@ export const viewModel = {
37
37
  },
38
38
  ],
39
39
  titleStyle: {
40
+ color: 'rgba(0, 0, 0, 1)',
41
+ fontSize: '2.25rem',
42
+ fontWeight: 'bold',
40
43
  textAlign: 'center',
41
44
  },
42
45
  testimonialStyle: {
@@ -12,7 +12,12 @@ const BPviewModel = {
12
12
  textItems: [],
13
13
  type: 'text',
14
14
  textStyle: {
15
+ fontSize: '1rem',
16
+ lineHeight: '1.5rem',
17
+ fontFamily: 'Lato',
15
18
  textAlign: 'left',
19
+ overflowWrap: 'anywhere',
20
+ wordBreak: 'normal',
16
21
  },
17
22
  columnStyle: '1',
18
23
  backgroundColor: {},
@@ -29,6 +34,7 @@ const BSviewModel = {
29
34
  id: 'text-item-1',
30
35
  text: 'lorem ipsum',
31
36
  textStyle: {
37
+ fontSize: '1rem',
32
38
  textAlign: 'left',
33
39
  textStyleType: 'paragraphs',
34
40
  },
@@ -37,6 +43,7 @@ const BSviewModel = {
37
43
  id: 'text-item-2',
38
44
  text: 'lorem ipsum',
39
45
  textStyle: {
46
+ fontSize: '1rem',
40
47
  textAlign: 'left',
41
48
  textStyleType: 'paragraphs',
42
49
  },
@@ -44,7 +51,12 @@ const BSviewModel = {
44
51
  ],
45
52
  type: 'text',
46
53
  textStyle: {
54
+ fontSize: '1rem',
55
+ lineHeight: '1.5rem',
56
+ fontFamily: 'Lato',
47
57
  textAlign: 'left',
58
+ overflowWrap: 'anywhere',
59
+ wordBreak: 'normal',
48
60
  },
49
61
  columnStyle: '2',
50
62
  backgroundColor: {},
@@ -59,7 +71,12 @@ const BSEmptyTextItem = {
59
71
  textItems: [],
60
72
  type: 'text',
61
73
  textStyle: {
74
+ fontSize: '1rem',
75
+ lineHeight: '1.5rem',
76
+ fontFamily: 'Lato',
62
77
  textAlign: 'left',
78
+ overflowWrap: 'anywhere',
79
+ wordBreak: 'normal',
63
80
  },
64
81
  columnStyle: '1',
65
82
  backgroundColor: {},
@@ -2,16 +2,6 @@ export declare const DISPLAY_TEXT_TITLE = "Titles";
2
2
  export declare const DISPLAY_TEXT_HEADINGS = "Headings";
3
3
  export declare const DISPLAY_TEXT_BODY = "Paragraphs";
4
4
  export declare const DISPlAY_TEXT_BUTTONS = "Button Texts";
5
- export declare const DISPLAY_TEXT_HEADING_1 = "Heading 1";
6
- export declare const DISPLAY_TEXT_HEADING_2 = "Heading 2";
7
- export declare const DISPLAY_TEXT_HEADING_3 = "Heading 3";
8
- export declare const DISPLAY_TEXT_HEADING_4 = "Heading 4";
9
- export declare const DISPLAY_TEXT_HEADING_5 = "Heading 5";
10
- export declare const DISPLAY_TEXT_HEADING_6 = "Heading 6";
11
- export declare const DISPLAY_TEXT_PARAGRAPH_1 = "Paragraph 1";
12
- export declare const DISPLAY_TEXT_PARAGRAPH_2 = "Paragraph 2";
13
- export declare const DISPLAY_TEXT_PARAGRAPH_3 = "Paragraph 3";
14
- export declare const DISPLAY_TEXT_BUTTON = "Button";
15
5
  export declare const DEFAULT_TEXT_DECORATION: undefined;
16
6
  export declare const DEFAULT_FONT_STYLE: undefined;
17
7
  export declare const FONT_SIZE_TITLE = "2.25em";
@@ -23,58 +13,6 @@ export declare const FONT_WEIGHT_NORMAL = "normal";
23
13
  export declare const LINE_HEIGHT_TITLE = "1.3";
24
14
  export declare const LINE_HEIGHT_HEADINGS = "1.4";
25
15
  export declare const LINE_HEIGHT_BODY = "1.5";
26
- export declare const TEXT_ROLE_STYLE_DEFAULTS: {
27
- readonly heading1: {
28
- readonly fontSize: "6.875em";
29
- readonly fontWeight: "bold";
30
- readonly lineHeight: "1.2";
31
- };
32
- readonly heading2: {
33
- readonly fontSize: "5.25em";
34
- readonly fontWeight: "bold";
35
- readonly lineHeight: "1.2";
36
- };
37
- readonly heading3: {
38
- readonly fontSize: "3.1875em";
39
- readonly fontWeight: "bold";
40
- readonly lineHeight: "1.25";
41
- };
42
- readonly heading4: {
43
- readonly fontSize: "2.1875em";
44
- readonly fontWeight: "bold";
45
- readonly lineHeight: "1.3";
46
- };
47
- readonly heading5: {
48
- readonly fontSize: "1.4375em";
49
- readonly fontWeight: "bold";
50
- readonly lineHeight: "1.35";
51
- };
52
- readonly heading6: {
53
- readonly fontSize: "1em";
54
- readonly fontWeight: "bold";
55
- readonly lineHeight: "1.4";
56
- };
57
- readonly paragraph1: {
58
- readonly fontSize: "1.375em";
59
- readonly fontWeight: "normal";
60
- readonly lineHeight: "1.5";
61
- };
62
- readonly paragraph2: {
63
- readonly fontSize: "1.125em";
64
- readonly fontWeight: "normal";
65
- readonly lineHeight: "1.5";
66
- };
67
- readonly paragraph3: {
68
- readonly fontSize: "0.875em";
69
- readonly fontWeight: "normal";
70
- readonly lineHeight: "1.6";
71
- };
72
- readonly button: {
73
- readonly fontSize: "1em";
74
- readonly fontWeight: "normal";
75
- readonly lineHeight: "1.2";
76
- };
77
- };
78
16
  export declare const DEFAULT_FONT_SIZE = 12;
79
17
  export declare const MIN_TEXT_SIZE_PX = 12;
80
18
  export declare const MAX_TEXT_SIZE_PX = 128;
@@ -3,18 +3,6 @@ export const DISPLAY_TEXT_TITLE = 'Titles';
3
3
  export const DISPLAY_TEXT_HEADINGS = 'Headings';
4
4
  export const DISPLAY_TEXT_BODY = 'Paragraphs';
5
5
  export const DISPlAY_TEXT_BUTTONS = 'Button Texts';
6
- // BP-5969 — display names for the 10 global text roles (English fallback; the
7
- // panel/picker use i18n `styleSettingsTr(<role>)`, these back it up).
8
- export const DISPLAY_TEXT_HEADING_1 = 'Heading 1';
9
- export const DISPLAY_TEXT_HEADING_2 = 'Heading 2';
10
- export const DISPLAY_TEXT_HEADING_3 = 'Heading 3';
11
- export const DISPLAY_TEXT_HEADING_4 = 'Heading 4';
12
- export const DISPLAY_TEXT_HEADING_5 = 'Heading 5';
13
- export const DISPLAY_TEXT_HEADING_6 = 'Heading 6';
14
- export const DISPLAY_TEXT_PARAGRAPH_1 = 'Paragraph 1';
15
- export const DISPLAY_TEXT_PARAGRAPH_2 = 'Paragraph 2';
16
- export const DISPLAY_TEXT_PARAGRAPH_3 = 'Paragraph 3';
17
- export const DISPLAY_TEXT_BUTTON = 'Button';
18
6
  export const DEFAULT_TEXT_DECORATION = undefined;
19
7
  export const DEFAULT_FONT_STYLE = undefined;
20
8
  export const FONT_SIZE_TITLE = '2.25em';
@@ -26,29 +14,6 @@ export const FONT_WEIGHT_NORMAL = 'normal';
26
14
  export const LINE_HEIGHT_TITLE = '1.3';
27
15
  export const LINE_HEIGHT_HEADINGS = '1.4';
28
16
  export const LINE_HEIGHT_BODY = '1.5';
29
- // BP-5969 — §4 default typography for the 10 global text roles. Sizes in `em`
30
- // (relative to the 16px root). Weights/letter-spacing are new: the legacy 4
31
- // roles carried none, so these apply to new sites only — existing sites keep
32
- // their persisted role definitions (migration-22 preserves appearance).
33
- // Weight is strictly binary (BP-5969): headings default `bold`, body + button
34
- // `normal`. No semibold tier — the RTE exposes only a normal/bold toggle, so the
35
- // role defaults use the same `bold`/`normal` keywords that toggle (and every weight
36
- // reader) speaks, not numeric weights.
37
- //
38
- // Sizes are a display scale in em @ 16px root; the px each em resolves to is noted
39
- // inline. Headings anchor H1 110px → H6 16px; body runs 22/18/14; button stays 16px.
40
- export const TEXT_ROLE_STYLE_DEFAULTS = {
41
- heading1: { fontSize: '6.875em', fontWeight: 'bold', lineHeight: '1.2' }, // 110px
42
- heading2: { fontSize: '5.25em', fontWeight: 'bold', lineHeight: '1.2' }, // 84px
43
- heading3: { fontSize: '3.1875em', fontWeight: 'bold', lineHeight: '1.25' }, // 51px
44
- heading4: { fontSize: '2.1875em', fontWeight: 'bold', lineHeight: '1.3' }, // 35px
45
- heading5: { fontSize: '1.4375em', fontWeight: 'bold', lineHeight: '1.35' }, // 23px
46
- heading6: { fontSize: '1em', fontWeight: 'bold', lineHeight: '1.4' }, // 16px
47
- paragraph1: { fontSize: '1.375em', fontWeight: 'normal', lineHeight: '1.5' }, // 22px
48
- paragraph2: { fontSize: '1.125em', fontWeight: 'normal', lineHeight: '1.5' }, // 18px
49
- paragraph3: { fontSize: '0.875em', fontWeight: 'normal', lineHeight: '1.6' }, // 14px
50
- button: { fontSize: '1em', fontWeight: 'normal', lineHeight: '1.2' }, // 16px
51
- };
52
17
  export const DEFAULT_FONT_SIZE = 12;
53
18
  export const MIN_TEXT_SIZE_PX = 12;
54
19
  export const MAX_TEXT_SIZE_PX = 128;