@templatical/editor 0.39.4 → 0.40.0

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 (210) hide show
  1. package/dist/{AiChatSidebar-5qqrS6uy.js → AiChatSidebar-a8TPBAl2.js} +3 -3
  2. package/dist/{AiFeatureMenu-BBO_Ojlp.js → AiFeatureMenu-CbgDjLqk.js} +3 -3
  3. package/dist/{BlockIssueBadge-D5oGxOQP.js → BlockIssueBadge-D8KsGWY6.js} +2 -2
  4. package/dist/BlockPreviewCanvas-XNV83YGg.js +133 -0
  5. package/dist/{CloudHeaderExtras-Cg6uF-yQ.js → CloudHeaderExtras-C-tbLyfE.js} +2 -2
  6. package/dist/{CloudPanels-D1Gg4qrG.js → CloudPanels-DnWDrgnQ.js} +4 -4
  7. package/dist/{CollaboratorBar-Cmn0LccS.js → CollaboratorBar-DUmeCkyD.js} +2 -2
  8. package/dist/{CommentsPanel-twNhYUqZ.js → CommentsPanel-9k1q-79y.js} +1 -1
  9. package/dist/{CommentsSidebar-DDO0Qx8U.js → CommentsSidebar-Bc7nORmD.js} +2 -2
  10. package/dist/{CountdownBlock-DSvbf3qU.js → CountdownBlock-C6R-hn7D.js} +1 -1
  11. package/dist/{CountdownToolbar-nvHxu8Gu.js → CountdownToolbar-DkC-qSgq.js} +4 -4
  12. package/dist/{DesignReferenceSidebar-C8ohNhOd.js → DesignReferenceSidebar-OoiYJAKS.js} +3 -3
  13. package/dist/{IssuesPanel-Ck0EGoV5.js → IssuesPanel-Dnns3O9z.js} +3 -3
  14. package/dist/{LogicTagInsertButton-D8IwH-9Z.js → LogicTagInsertButton-BimKobaG.js} +67 -67
  15. package/dist/{MergeTagInput-QI-5KG2R.js → MergeTagInput-DqpVzhy7.js} +1 -1
  16. package/dist/{MergeTagModeToggle-D793Bj_E.js → MergeTagModeToggle-BkIiAgpQ.js} +4 -4
  17. package/dist/{ParagraphEditor-D6FRxr8Y.js → ParagraphEditor-D67Cqh-T.js} +19 -19
  18. package/dist/{RestoreVersionDialog--b0qfNaK.js → RestoreVersionDialog-BaKDuPCX.js} +2 -2
  19. package/dist/{RichTextEditorContent-BC5UTVnb.js → RichTextEditorContent-AEtfKvLz.js} +5 -5
  20. package/dist/{SaveBlockDialog-C0BdEGeL.js → SaveBlockDialog-BxkI52fN.js} +8 -8
  21. package/dist/{SavedBlocksBrowserModal-BzDgXtr4.js → SavedBlocksBrowserModal-C4_25Kvn.js} +6 -6
  22. package/dist/{SavedBlocksPanels-DN-bDZzy.js → SavedBlocksPanels-DQ0w9G1O.js} +1 -1
  23. package/dist/{SavedBlocksPickBar-pEi9Et8Q.js → SavedBlocksPickBar-CtH-sfxh.js} +2 -2
  24. package/dist/{TemplateScoringPanel-B1wcfE0w.js → TemplateScoringPanel-Cs0TGtRF.js} +3 -3
  25. package/dist/{TemplateSettings-C_5leDdF.js → TemplateSettings-BD1WNP4C.js} +7 -7
  26. package/dist/{TestEmailModal-maM8SLBV.js → TestEmailModal-DZi58FU9.js} +70 -65
  27. package/dist/{TestEmailPanel-8iAZYpCK.js → TestEmailPanel-D__9Wvgz.js} +1 -1
  28. package/dist/{TitleEditor-L26QXwna.js → TitleEditor-v5p89Djs.js} +9 -9
  29. package/dist/{ToggleSwitch-JvQ_CmI1.js → ToggleSwitch-CJfQ8u57.js} +1 -1
  30. package/dist/{Toolbar-B2kDLFhn.js → Toolbar-C7SjilzH.js} +540 -525
  31. package/dist/{TplModal-DVMS_nAn.js → TplModal-B8uLyoXE.js} +3 -3
  32. package/dist/{VersionHistoryMenu-BVQityes.js → VersionHistoryMenu-b0A8mS2_.js} +2 -2
  33. package/dist/{VersionHistoryPanels-D8f8KvKX.js → VersionHistoryPanels-DfNrRT6y.js} +1 -1
  34. package/dist/{VersionPreviewBanner-BaMSgA1O.js → VersionPreviewBanner-xB9r83r0.js} +1 -1
  35. package/dist/WrapperBlock-yGmKw0T-.js +34 -0
  36. package/dist/{blockTypeIcons-CdXugKyV.js → blockTypeIcons-B0Bq1WT1.js} +1 -1
  37. package/dist/bundle-stats.json +6 -6
  38. package/dist/{ca-Bqeygp1_.js → ca-Ckgw9yd0.js} +1 -0
  39. package/dist/cdn/chunks/{AiChatSidebar-ctfIU4i0.js → AiChatSidebar-mKImUXi6.js} +7 -7
  40. package/dist/cdn/chunks/{AiChatSidebar-ctfIU4i0.js.map → AiChatSidebar-mKImUXi6.js.map} +1 -1
  41. package/dist/cdn/chunks/{AiFeatureMenu-ByygdH_9.js → AiFeatureMenu-23HCL517.js} +4 -4
  42. package/dist/cdn/chunks/{AiFeatureMenu-ByygdH_9.js.map → AiFeatureMenu-23HCL517.js.map} +1 -1
  43. package/dist/cdn/chunks/{BlockIssueBadge-9hHpaXb9.js → BlockIssueBadge-DS1pUf5g.js} +3 -3
  44. package/dist/cdn/chunks/{BlockIssueBadge-9hHpaXb9.js.map → BlockIssueBadge-DS1pUf5g.js.map} +1 -1
  45. package/dist/cdn/chunks/BlockPreviewCanvas-DObWyQfh.js +135 -0
  46. package/dist/cdn/chunks/BlockPreviewCanvas-DObWyQfh.js.map +1 -0
  47. package/dist/cdn/chunks/{CloudHeaderExtras-BxsMpvVr.js → CloudHeaderExtras-DOB_uWpt.js} +3 -3
  48. package/dist/cdn/chunks/{CloudHeaderExtras-BxsMpvVr.js.map → CloudHeaderExtras-DOB_uWpt.js.map} +1 -1
  49. package/dist/cdn/chunks/{CloudPanels-DmxmqAS_.js → CloudPanels-DcAn5QW7.js} +5 -5
  50. package/dist/cdn/chunks/{CloudPanels-DmxmqAS_.js.map → CloudPanels-DcAn5QW7.js.map} +1 -1
  51. package/dist/cdn/chunks/{CollaboratorBar-B8ttqAqX.js → CollaboratorBar-C0M8c2Vv.js} +3 -3
  52. package/dist/cdn/chunks/{CollaboratorBar-B8ttqAqX.js.map → CollaboratorBar-C0M8c2Vv.js.map} +1 -1
  53. package/dist/cdn/chunks/{CommentsPanel-C8ibhaiK.js → CommentsPanel-BtAGZfF6.js} +2 -2
  54. package/dist/cdn/chunks/{CommentsPanel-C8ibhaiK.js.map → CommentsPanel-BtAGZfF6.js.map} +1 -1
  55. package/dist/cdn/chunks/{CommentsSidebar-CybWfZ3V.js → CommentsSidebar-Ws07MXYj.js} +3 -3
  56. package/dist/cdn/chunks/{CommentsSidebar-CybWfZ3V.js.map → CommentsSidebar-Ws07MXYj.js.map} +1 -1
  57. package/dist/cdn/chunks/{CountdownBlock-DdC8Lg5F.js → CountdownBlock-sVDjKkRw.js} +2 -2
  58. package/dist/cdn/chunks/{CountdownBlock-DdC8Lg5F.js.map → CountdownBlock-sVDjKkRw.js.map} +1 -1
  59. package/dist/cdn/chunks/{CountdownToolbar-DRESXiVD.js → CountdownToolbar-Bu93WiS8.js} +5 -5
  60. package/dist/cdn/chunks/{CountdownToolbar-DRESXiVD.js.map → CountdownToolbar-Bu93WiS8.js.map} +1 -1
  61. package/dist/cdn/chunks/{DesignReferenceSidebar-CtaoY-hl.js → DesignReferenceSidebar-BlSdh5B7.js} +4 -4
  62. package/dist/cdn/chunks/{DesignReferenceSidebar-CtaoY-hl.js.map → DesignReferenceSidebar-BlSdh5B7.js.map} +1 -1
  63. package/dist/cdn/chunks/{IssuesPanel-C6RlIxoi.js → IssuesPanel-CKkv9z9g.js} +4 -4
  64. package/dist/cdn/chunks/{IssuesPanel-C6RlIxoi.js.map → IssuesPanel-CKkv9z9g.js.map} +1 -1
  65. package/dist/cdn/chunks/{LogicTagInsertButton-DpyPozop.js → LogicTagInsertButton-CHc1yZ9v.js} +165 -165
  66. package/dist/cdn/chunks/{LogicTagInsertButton-DpyPozop.js.map → LogicTagInsertButton-CHc1yZ9v.js.map} +1 -1
  67. package/dist/cdn/chunks/{MergeTagInput-ERJr7bP_.js → MergeTagInput--qTYfCWk.js} +2 -2
  68. package/dist/cdn/chunks/{MergeTagInput-ERJr7bP_.js.map → MergeTagInput--qTYfCWk.js.map} +1 -1
  69. package/dist/cdn/chunks/{MergeTagModeToggle-n3nvSNeQ.js → MergeTagModeToggle-CdWIGo3Q.js} +5 -5
  70. package/dist/cdn/chunks/{MergeTagModeToggle-n3nvSNeQ.js.map → MergeTagModeToggle-CdWIGo3Q.js.map} +1 -1
  71. package/dist/cdn/chunks/{ParagraphEditor-R2ph_UOo.js → ParagraphEditor-BilbVtrG.js} +17 -17
  72. package/dist/cdn/chunks/{ParagraphEditor-R2ph_UOo.js.map → ParagraphEditor-BilbVtrG.js.map} +1 -1
  73. package/dist/cdn/chunks/{RestoreVersionDialog-C-dwbb7T.js → RestoreVersionDialog-Q-a44Vjv.js} +3 -3
  74. package/dist/cdn/chunks/{RestoreVersionDialog-C-dwbb7T.js.map → RestoreVersionDialog-Q-a44Vjv.js.map} +1 -1
  75. package/dist/cdn/chunks/{RichTextEditorContent-Ch5zeyZ7.js → RichTextEditorContent-Fzuu9pLP.js} +6 -6
  76. package/dist/cdn/chunks/{RichTextEditorContent-Ch5zeyZ7.js.map → RichTextEditorContent-Fzuu9pLP.js.map} +1 -1
  77. package/dist/cdn/chunks/{SaveBlockDialog-C_BPjVv6.js → SaveBlockDialog-DeW_M6kh.js} +9 -9
  78. package/dist/cdn/chunks/{SaveBlockDialog-C_BPjVv6.js.map → SaveBlockDialog-DeW_M6kh.js.map} +1 -1
  79. package/dist/cdn/chunks/{SavedBlocksBrowserModal-CrrGEfFb.js → SavedBlocksBrowserModal-BzQWibKG.js} +6 -6
  80. package/dist/cdn/chunks/{SavedBlocksBrowserModal-CrrGEfFb.js.map → SavedBlocksBrowserModal-BzQWibKG.js.map} +1 -1
  81. package/dist/cdn/chunks/{SavedBlocksPanels-DfTaMPAr.js → SavedBlocksPanels-Ce1RePjk.js} +2 -2
  82. package/dist/cdn/chunks/{SavedBlocksPanels-DfTaMPAr.js.map → SavedBlocksPanels-Ce1RePjk.js.map} +1 -1
  83. package/dist/cdn/chunks/{SavedBlocksPickBar-DziwHYSu.js → SavedBlocksPickBar-DIDl6xfy.js} +3 -3
  84. package/dist/cdn/chunks/{SavedBlocksPickBar-DziwHYSu.js.map → SavedBlocksPickBar-DIDl6xfy.js.map} +1 -1
  85. package/dist/cdn/chunks/{TemplateScoringPanel-CR6RG6dZ.js → TemplateScoringPanel-d_Ppowsq.js} +49 -49
  86. package/dist/cdn/chunks/{TemplateScoringPanel-CR6RG6dZ.js.map → TemplateScoringPanel-d_Ppowsq.js.map} +1 -1
  87. package/dist/cdn/chunks/{TemplateSettings-DjXiiiNr.js → TemplateSettings-Dr5OJ0Gi.js} +8 -8
  88. package/dist/cdn/chunks/{TemplateSettings-DjXiiiNr.js.map → TemplateSettings-Dr5OJ0Gi.js.map} +1 -1
  89. package/dist/cdn/chunks/{TestEmailModal-DId9Og-N.js → TestEmailModal-CWTmaJuT.js} +56 -51
  90. package/dist/cdn/chunks/TestEmailModal-CWTmaJuT.js.map +1 -0
  91. package/dist/cdn/chunks/{TestEmailPanel-B8LwXmeX.js → TestEmailPanel-BdYsVHXA.js} +2 -2
  92. package/dist/cdn/chunks/{TestEmailPanel-B8LwXmeX.js.map → TestEmailPanel-BdYsVHXA.js.map} +1 -1
  93. package/dist/cdn/chunks/{TitleEditor-C7KMzX1e.js → TitleEditor-pJeeZ-PX.js} +9 -9
  94. package/dist/cdn/chunks/{TitleEditor-C7KMzX1e.js.map → TitleEditor-pJeeZ-PX.js.map} +1 -1
  95. package/dist/cdn/chunks/{ToggleSwitch-CDy8OfcB.js → ToggleSwitch-0dGCYnRY.js} +2 -2
  96. package/dist/cdn/chunks/{ToggleSwitch-CDy8OfcB.js.map → ToggleSwitch-0dGCYnRY.js.map} +1 -1
  97. package/dist/cdn/chunks/{Toolbar-DqFhWxgW.js → Toolbar-BsiHW9gY.js} +493 -478
  98. package/dist/cdn/chunks/{Toolbar-DqFhWxgW.js.map → Toolbar-BsiHW9gY.js.map} +1 -1
  99. package/dist/cdn/chunks/{TplModal-BKqDFLq3.js → TplModal-CEuGD7pt.js} +4 -4
  100. package/dist/cdn/chunks/{TplModal-BKqDFLq3.js.map → TplModal-CEuGD7pt.js.map} +1 -1
  101. package/dist/cdn/chunks/{VersionHistoryMenu-Dij1pTEb.js → VersionHistoryMenu-B3-hNu9c.js} +3 -3
  102. package/dist/cdn/chunks/{VersionHistoryMenu-Dij1pTEb.js.map → VersionHistoryMenu-B3-hNu9c.js.map} +1 -1
  103. package/dist/cdn/chunks/{VersionHistoryPanels-DcCFFDK6.js → VersionHistoryPanels-C1yck5gT.js} +2 -2
  104. package/dist/cdn/chunks/{VersionHistoryPanels-DcCFFDK6.js.map → VersionHistoryPanels-C1yck5gT.js.map} +1 -1
  105. package/dist/cdn/chunks/{VersionPreviewBanner-Df3FVlig.js → VersionPreviewBanner-PzVQSBJE.js} +2 -2
  106. package/dist/cdn/chunks/{VersionPreviewBanner-Df3FVlig.js.map → VersionPreviewBanner-PzVQSBJE.js.map} +1 -1
  107. package/dist/cdn/chunks/WrapperBlock-DGkbmj06.js +36 -0
  108. package/dist/cdn/chunks/WrapperBlock-DGkbmj06.js.map +1 -0
  109. package/dist/cdn/chunks/{ca-Bqeygp1_.js → ca-Ckgw9yd0.js} +2 -1
  110. package/dist/cdn/chunks/ca-Ckgw9yd0.js.map +1 -0
  111. package/dist/cdn/chunks/{cloud-eaXyxZ8l.js → cloud-CIT4yPp4.js} +2 -2
  112. package/dist/cdn/chunks/{cloud-eaXyxZ8l.js.map → cloud-CIT4yPp4.js.map} +1 -1
  113. package/dist/cdn/chunks/{createCloudRuntime-D5bXzcTe.js → createCloudRuntime-COUxbPvd.js} +49 -40
  114. package/dist/cdn/chunks/createCloudRuntime-COUxbPvd.js.map +1 -0
  115. package/dist/cdn/chunks/{de-CY6SlqBx.js → de-D4dweQw8.js} +2 -1
  116. package/dist/cdn/chunks/de-D4dweQw8.js.map +1 -0
  117. package/dist/{en-8V-2kDcp.js → cdn/chunks/en-VE7R7NyL.js} +3 -0
  118. package/dist/cdn/chunks/en-VE7R7NyL.js.map +1 -0
  119. package/dist/{es-Cmn1rT3l.js → cdn/chunks/es-B9OhP8H3.js} +3 -0
  120. package/dist/cdn/chunks/es-B9OhP8H3.js.map +1 -0
  121. package/dist/cdn/chunks/{extensions-Bhu8UEE5.js → extensions-CafoGF65.js} +5 -5
  122. package/dist/cdn/chunks/{extensions-Bhu8UEE5.js.map → extensions-CafoGF65.js.map} +1 -1
  123. package/dist/cdn/chunks/{fr-2yDa4zXM.js → fr-wrXhIi00.js} +2 -1
  124. package/dist/cdn/chunks/fr-wrXhIi00.js.map +1 -0
  125. package/dist/cdn/chunks/keys-DCWeHkSF.js +12 -0
  126. package/dist/cdn/chunks/keys-DCWeHkSF.js.map +1 -0
  127. package/dist/{nl-Bzk2zRI8.js → cdn/chunks/nl-DeFatKJe.js} +3 -0
  128. package/dist/cdn/chunks/nl-DeFatKJe.js.map +1 -0
  129. package/dist/cdn/chunks/preRenderCustomBlocks-Dpj-_cOj.js +21 -0
  130. package/dist/cdn/chunks/preRenderCustomBlocks-Dpj-_cOj.js.map +1 -0
  131. package/dist/cdn/chunks/{pt-BR-DqtSCTUi.js → pt-BR-Bh1J8ey6.js} +2 -1
  132. package/dist/cdn/chunks/pt-BR-Bh1J8ey6.js.map +1 -0
  133. package/dist/cdn/chunks/{socialIcons-9VrG8X3m.js → socialIcons-BvYNMn1G.js} +264 -258
  134. package/dist/cdn/chunks/socialIcons-BvYNMn1G.js.map +1 -0
  135. package/dist/cdn/chunks/{src-CqYYKcCI.js → src-CbGCES0u.js} +175 -168
  136. package/dist/cdn/chunks/src-CbGCES0u.js.map +1 -0
  137. package/dist/cdn/chunks/{src-CaNsA_WX.js → src-Cnc5E71L.js} +258 -247
  138. package/dist/cdn/chunks/src-Cnc5E71L.js.map +1 -0
  139. package/dist/cdn/chunks/{src-Dwgq7hf4.js → src-DveVYoWS.js} +281 -181
  140. package/dist/cdn/chunks/src-DveVYoWS.js.map +1 -0
  141. package/dist/cdn/chunks/{useCloudI18n-C09JcFS0.js → useCloudI18n-CrjWbpbu.js} +2 -2
  142. package/dist/cdn/chunks/{useCloudI18n-C09JcFS0.js.map → useCloudI18n-CrjWbpbu.js.map} +1 -1
  143. package/dist/cdn/chunks/{useEditorCore-CXYI14ux.js → useEditorCore-CQraU2s_.js} +421 -408
  144. package/dist/cdn/chunks/useEditorCore-CQraU2s_.js.map +1 -0
  145. package/dist/cdn/chunks/{useEditorRoot-DFx2fXJP.js → useEditorRoot-CshefZLP.js} +2 -2
  146. package/dist/cdn/chunks/{useEditorRoot-DFx2fXJP.js.map → useEditorRoot-CshefZLP.js.map} +1 -1
  147. package/dist/cdn/chunks/{useI18n-DTZ9sIcv.js → useI18n-CyO_Nmca.js} +2 -2
  148. package/dist/cdn/chunks/{useI18n-DTZ9sIcv.js.map → useI18n-CyO_Nmca.js.map} +1 -1
  149. package/dist/cdn/chunks/{useLogicTag-E2V0Xdcb.js → useLogicTag-DF7-l66G.js} +4 -4
  150. package/dist/cdn/chunks/{useLogicTag-E2V0Xdcb.js.map → useLogicTag-DF7-l66G.js.map} +1 -1
  151. package/dist/cdn/chunks/{useMergeTag-BE8oDoha.js → useMergeTag-DbIHw4NG.js} +4 -4
  152. package/dist/cdn/chunks/{useMergeTag-BE8oDoha.js.map → useMergeTag-DbIHw4NG.js.map} +1 -1
  153. package/dist/cdn/chunks/{usePopoverPosition-gB9q-ql7.js → usePopoverPosition-BJRvAb-h.js} +2 -2
  154. package/dist/cdn/chunks/{usePopoverPosition-gB9q-ql7.js.map → usePopoverPosition-BJRvAb-h.js.map} +1 -1
  155. package/dist/cdn/chunks/{useScrollToBlock-CtTXwmiU.js → useScrollToBlock-DgHZJvID.js} +2 -2
  156. package/dist/cdn/chunks/{useScrollToBlock-CtTXwmiU.js.map → useScrollToBlock-DgHZJvID.js.map} +1 -1
  157. package/dist/cdn/editor.css +1 -1
  158. package/dist/cdn/editor.js +484 -460
  159. package/dist/cdn/editor.js.map +1 -1
  160. package/dist/{cloud-C9xWZXhg.js → cloud-DsqqUfzh.js} +1 -1
  161. package/dist/{createCloudRuntime-BGd5--Bq.js → createCloudRuntime-iLflkYzP.js} +47 -38
  162. package/dist/{de-CY6SlqBx.js → de-D4dweQw8.js} +1 -0
  163. package/dist/{dist-tGkjkX-v.js → dist-DbUZvK04.js} +277 -176
  164. package/dist/{cdn/chunks/en-8V-2kDcp.js → en-VE7R7NyL.js} +1 -2
  165. package/dist/{cdn/chunks/es-Cmn1rT3l.js → es-B9OhP8H3.js} +1 -2
  166. package/dist/{extensions-DRN-elXT.js → extensions-DDhjuVKy.js} +4 -4
  167. package/dist/{fr-2yDa4zXM.js → fr-wrXhIi00.js} +1 -0
  168. package/dist/index.d.ts +65 -0
  169. package/dist/keys-CDqfZIRt.js +10 -0
  170. package/dist/{cdn/chunks/nl-Bzk2zRI8.js → nl-DeFatKJe.js} +1 -2
  171. package/dist/preRenderCustomBlocks-BBSqQgke.js +19 -0
  172. package/dist/{pt-BR-DqtSCTUi.js → pt-BR-Bh1J8ey6.js} +1 -0
  173. package/dist/{socialIcons-DkGcpEwC.js → socialIcons-O7PZCW2P.js} +245 -239
  174. package/dist/style.css +1 -1
  175. package/dist/templatical-editor.js +520 -496
  176. package/dist/{useCloudI18n-D1iedlP3.js → useCloudI18n-DpEsiLeR.js} +1 -1
  177. package/dist/{useEditorCore-BUVbQgwb.js → useEditorCore-Dt_VWNqX.js} +817 -804
  178. package/dist/{useEditorRoot-BOxn5EfP.js → useEditorRoot-CkB_5d0h.js} +1 -1
  179. package/dist/{useI18n-Ds_-druD.js → useI18n-B_CdcBwG.js} +1 -1
  180. package/dist/{useLogicTag-DoHfc08B.js → useLogicTag-D9pvgxQR.js} +3 -3
  181. package/dist/{useMergeTag-DXyum3kG.js → useMergeTag-BaVFPdlq.js} +5 -5
  182. package/dist/{usePopoverPosition-Du-Ah8E9.js → usePopoverPosition-DH7z3Ghm.js} +1 -1
  183. package/dist/{useScrollToBlock-DXQYPCnJ.js → useScrollToBlock-Dj4v3rxr.js} +1 -1
  184. package/package.json +7 -7
  185. package/dist/BlockPreviewCanvas-BMC16_QU.js +0 -131
  186. package/dist/cdn/chunks/BlockPreviewCanvas-DeS7Sa--.js +0 -133
  187. package/dist/cdn/chunks/BlockPreviewCanvas-DeS7Sa--.js.map +0 -1
  188. package/dist/cdn/chunks/TestEmailModal-DId9Og-N.js.map +0 -1
  189. package/dist/cdn/chunks/ca-Bqeygp1_.js.map +0 -1
  190. package/dist/cdn/chunks/createCloudRuntime-D5bXzcTe.js.map +0 -1
  191. package/dist/cdn/chunks/de-CY6SlqBx.js.map +0 -1
  192. package/dist/cdn/chunks/emailFrameWidth-BmFCN2dp.js +0 -8
  193. package/dist/cdn/chunks/emailFrameWidth-BmFCN2dp.js.map +0 -1
  194. package/dist/cdn/chunks/en-8V-2kDcp.js.map +0 -1
  195. package/dist/cdn/chunks/es-Cmn1rT3l.js.map +0 -1
  196. package/dist/cdn/chunks/fr-2yDa4zXM.js.map +0 -1
  197. package/dist/cdn/chunks/keys-dJbD1QPs.js +0 -12
  198. package/dist/cdn/chunks/keys-dJbD1QPs.js.map +0 -1
  199. package/dist/cdn/chunks/nl-Bzk2zRI8.js.map +0 -1
  200. package/dist/cdn/chunks/preRenderCustomBlocks-Bdpiiw4A.js +0 -23
  201. package/dist/cdn/chunks/preRenderCustomBlocks-Bdpiiw4A.js.map +0 -1
  202. package/dist/cdn/chunks/pt-BR-DqtSCTUi.js.map +0 -1
  203. package/dist/cdn/chunks/socialIcons-9VrG8X3m.js.map +0 -1
  204. package/dist/cdn/chunks/src-CaNsA_WX.js.map +0 -1
  205. package/dist/cdn/chunks/src-CqYYKcCI.js.map +0 -1
  206. package/dist/cdn/chunks/src-Dwgq7hf4.js.map +0 -1
  207. package/dist/cdn/chunks/useEditorCore-CXYI14ux.js.map +0 -1
  208. package/dist/emailFrameWidth-BmFCN2dp.js +0 -6
  209. package/dist/keys-BdoSgsz9.js +0 -10
  210. package/dist/preRenderCustomBlocks-DFXH54Zr.js +0 -21
@@ -0,0 +1 @@
1
+ {"version":3,"file":"es-B9OhP8H3.js","names":[],"sources":["../../../src/i18n/locales/es.ts"],"sourcesContent":["import type en from \"./en\";\n\nconst es: typeof en = {\n // Footer (OSS only)\n footer: {\n poweredBy: \"Con la tecnología de\",\n openSource: \"Código abierto\",\n },\n\n // Header — nombre de la plantilla + estado de guardado. Solo se muestra cuando\n // hay un proveedor de plantillas configurado.\n header: {\n save: \"Guardar\",\n saving: \"Guardando...\",\n saved: \"Guardado\",\n unsaved: \"Sin guardar\",\n saveFailed: \"Error al guardar\",\n saveNoTemplate: \"Carga o crea una plantilla primero\",\n templateName: \"Nombre de la plantilla\",\n rename: \"Cambiar el nombre de la plantilla\",\n untitled: \"Sin título\",\n updatedAt: \"Actualizado {time}\",\n createdAt: \"Creado {time}\",\n updatedJustNow: \"Actualizado ahora mismo\",\n createdJustNow: \"Creado ahora mismo\",\n },\n\n // Relative timestamps, shared by every surface that shows one: the header's\n // updated line, saved blocks, comments and version history.\n time: {\n justNow: \"Ahora mismo\",\n minutesAgo: \"hace {minutes} min\",\n hoursAgo: \"hace {hours} h\",\n daysAgo: \"hace {days} d\",\n },\n\n // History (undo/redo)\n history: {\n collabWarning:\n \"Deshacer puede afectar a los cambios recientes de los colaboradores\",\n undo: \"Deshacer\",\n redo: \"Rehacer\",\n },\n\n // Viewport toggle\n viewport: {\n label: \"Área de visualización\",\n desktop: \"Escritorio\",\n mobile: \"Móvil\",\n },\n\n // Dark mode preview\n darkMode: {\n enable: \"Vista previa en modo oscuro\",\n disable: \"Vista previa en modo claro\",\n },\n\n // Preview mode\n previewMode: {\n enable: \"Modo vista previa\",\n disable: \"Salir de la vista previa\",\n },\n\n // Sidebar - Block types\n blocks: {\n section: \"Sección\",\n image: \"Imagen\",\n title: \"Título\",\n paragraph: \"Párrafo\",\n button: \"Botón\",\n divider: \"Divisor\",\n video: \"Vídeo\",\n social: \"Redes sociales\",\n spacer: \"Espaciador\",\n html: \"HTML\",\n menu: \"Menú\",\n table: \"Tabla\",\n countdown: \"Cuenta atrás\",\n },\n\n // Placeholder text a newly inserted block starts with. Author-facing\n // prompts, meant to be overwritten — so they follow the editor UI locale.\n // Recipient-facing defaults live in `i18n/contentDefaults.ts` and follow\n // the template's own `settings.locale` instead.\n blockDefaults: {\n title: \"Escribe tu título\",\n paragraph: \"Escribe tu texto aquí\",\n button: \"Haz clic aquí\",\n },\n\n // Right sidebar\n sidebar: {\n content: \"Contenido\",\n settings: \"Configuración\",\n noSelection: \"Ningún elemento seleccionado\",\n noSelectionHint: \"Selecciona un bloque en el lienzo para editarlo\",\n },\n\n // Toolbar - Common\n toolbar: {\n duplicate: \"Duplicar\",\n delete: \"Eliminar\",\n },\n\n // Title editor toolbar\n titleEditor: {\n toolbar: \"Formato del título\",\n bold: \"Negrita (Ctrl+B)\",\n italic: \"Cursiva (Ctrl+I)\",\n addLink: \"Añadir enlace\",\n },\n\n // Paragraph editor toolbar\n paragraphEditor: {\n toolbar: \"Formato del texto\",\n bold: \"Negrita (Ctrl+B)\",\n italic: \"Cursiva (Ctrl+I)\",\n underline: \"Subrayado (Ctrl+U)\",\n strikethrough: \"Tachado\",\n subscript: \"Subíndice\",\n superscript: \"Superíndice\",\n addLink: \"Añadir enlace\",\n bulletList: \"Lista con viñetas\",\n numberedList: \"Lista numerada\",\n alignLeft: \"Alinear a la izquierda\",\n alignCenter: \"Alinear al centro\",\n alignRight: \"Alinear a la derecha\",\n alignJustify: \"Justificar\",\n clearFormatting: \"Borrar formato\",\n insertEmoji: \"Insertar emoji\",\n fontFamily: \"Familia tipográfica\",\n defaultFont: \"Por defecto\",\n fontSize: \"Tamaño de fuente\",\n defaultSize: \"Por defecto\",\n textColor: \"Color del texto\",\n highlightColor: \"Color de resaltado\",\n lineHeight: \"Interlineado\",\n letterSpacing: \"Espaciado entre letras\",\n emojiItemLabel: \"Insertar emoji {emoji}\",\n },\n\n // Block actions (BlockWrapper)\n blockActions: {\n drag: \"Arrastra para reordenar o pulsa Espacio para mover con el teclado\",\n dragLifted:\n \"Moviendo {block}. Usa las flechas arriba y abajo para reposicionar, Espacio o Intro para soltar, Esc para cancelar.\",\n duplicate: \"Duplicar bloque\",\n delete: \"Eliminar bloque\",\n hiddenOnViewport: \"Oculto en {viewport}\",\n saveAsBlock: \"Guardar como bloque\",\n conditionToggle: \"Alternar condición de visualización\",\n comments: \"Comentarios ({count})\",\n lifted: \"{block} levantado. Posición {position} de {total}.\",\n moved: \"{block} movido a la posición {position} de {total}.\",\n dropped: \"{block} soltado en la posición {position} de {total}.\",\n cancelled: \"Movimiento cancelado. {block} volvió a la posición {position}.\",\n },\n\n // Toolbar - Section\n section: {\n dropHere: \"Suelta los bloques aquí\",\n columns: \"Columnas\",\n column1: \"1 columna\",\n column2: \"2 columnas\",\n column3: \"3 columnas\",\n ratio12: \"Proporción 1:2\",\n ratio21: \"Proporción 2:1\",\n borderRadius: \"Radio del borde\",\n wrapperEnable: \"Añadir contenedor\",\n wrapperLayoutConflict:\n \"Este editor ya enmarca el correo. Un marco extra en esta sección no es compatible — la vista previa y la exportación fallarán.\",\n stackOnMobile: \"Apilar en móvil\",\n },\n\n // Text editor link dialog\n linkDialog: {\n editLink: \"Editar enlace\",\n insertLink: \"Insertar enlace\",\n updateLink: \"Actualizar enlace\",\n removeLink: \"Eliminar enlace\",\n cancel: \"Cancelar\",\n urlPlaceholder: \"https://example.com\",\n urlLabel: \"URL\",\n colorLabel: \"Color del enlace\",\n },\n\n // Toolbar - Title\n title: {\n level: \"Nivel de encabezado\",\n heading1: \"Encabezado 1 (36px)\",\n heading2: \"Encabezado 2 (28px)\",\n heading3: \"Encabezado 3 (22px)\",\n heading4: \"Encabezado 4 (18px)\",\n fontFamily: \"Familia tipográfica\",\n inheritFont: \"Usar fuente de la plantilla\",\n color: \"Color\",\n align: \"Alineación\",\n alignLeft: \"Izquierda\",\n alignCenter: \"Centro\",\n alignRight: \"Derecha\",\n },\n\n // Emoji picker\n emoji: {\n smileys: \"Emoticonos\",\n gestures: \"Gestos\",\n objects: \"Objetos\",\n },\n\n // Toolbar - Image\n image: {\n imageUrl: \"URL de la imagen\",\n imageUrlPlaceholder: \"https://...\",\n altText: \"Texto alternativo\",\n altTextPlaceholder: \"Descripción de la imagen\",\n width: \"Ancho\",\n fullWidth: \"Ancho completo\",\n widthCustom: \"Personalizado\",\n height: \"Altura\",\n heightAuto: \"Automática\",\n heightCustom: \"Personalizada\",\n borderRadius: \"Radio del borde\",\n linkUrl: \"URL del enlace\",\n openInNewTab: \"Abrir en una nueva pestaña\",\n placeholderUrl: \"Imagen de muestra\",\n optional: \"(opcional)\",\n placeholderUrlPlaceholder: \"https://... (solo para diseño)\",\n placeholderUrlTooltip:\n \"Dado que la URL de la imagen utiliza una etiqueta de combinación, puedes proporcionar una imagen real aquí para previsualizar el diseño mientras diseñas. Esto no se incluirá en el resultado final.\",\n clickToAdd: \"Haz clic para añadir la URL de la imagen\",\n browseMedia: \"Explorar archivos multimedia\",\n dropToUpload: \"Suelta la imagen para subirla\",\n uploading: \"Subiendo...\",\n decorative: \"Imagen decorativa\",\n decorativeHint:\n \"Oculto para los lectores de pantalla. Utilízalo solo para espaciadores y adornos visuales.\",\n },\n\n // Toolbar - Video\n video: {\n videoUrl: \"URL del vídeo\",\n videoUrlPlaceholder: \"https://youtube.com/...\",\n openInNewTab: \"Abrir en una nueva pestaña\",\n customThumbnail: \"Miniatura personalizada\",\n optional: \"(opcional)\",\n thumbnailPlaceholder: \"Generada automáticamente desde la URL del vídeo\",\n altText: \"Texto alternativo\",\n altTextPlaceholder: \"Descripción del vídeo\",\n width: \"Ancho\",\n fullWidth: \"Ancho completo\",\n height: \"Altura\",\n heightAuto: \"Automática\",\n heightCustom: \"Personalizada\",\n placeholderUrl: \"Miniatura de muestra\",\n placeholderUrlPlaceholder: \"https://... (solo para diseño)\",\n placeholderUrlTooltip:\n \"Dado que la URL del vídeo utiliza una etiqueta de combinación, puedes proporcionar una miniatura real aquí para previsualizar el diseño mientras diseñas. Esto no se incluirá en el resultado final.\",\n addVideo: \"Añadir una URL de vídeo\",\n },\n\n // Toolbar - Button\n button: {\n fontFamily: \"Familia tipográfica\",\n inheritFont: \"Usar fuente de la plantilla\",\n text: \"Texto\",\n url: \"URL\",\n urlPlaceholder: \"https://...\",\n openInNewTab: \"Abrir en una nueva pestaña\",\n background: \"Fondo\",\n textColor: \"Color del texto\",\n borderRadius: \"Radio del borde\",\n fontSize: \"Tamaño de fuente\",\n width: \"Ancho\",\n widthAuto: \"Ajustar al contenido\",\n fullWidth: \"Ancho completo\",\n widthCustom: \"Personalizado\",\n },\n\n // Toolbar - Divider\n divider: {\n style: \"Estilo\",\n solid: \"Sólido\",\n dashed: \"Discontinuo\",\n dotted: \"Punteado\",\n color: \"Color\",\n thickness: \"Grosor\",\n },\n\n // Toolbar - Social Icons\n social: {\n icons: \"Iconos\",\n addIcon: \"Añadir icono\",\n addIcons: \"Añadir iconos de redes sociales\",\n removeIcon: \"Eliminar\",\n urlPlaceholder: \"https://...\",\n style: \"Estilo\",\n styleSolid: \"Sólido\",\n styleOutlined: \"Contorneado\",\n styleRounded: \"Redondeado\",\n styleSquare: \"Cuadrado\",\n styleCircle: \"Círculo\",\n size: \"Tamaño\",\n sizeSmall: \"S\",\n sizeMedium: \"M\",\n sizeLarge: \"L\",\n spacing: \"Espaciado\",\n align: \"Alineación\",\n platforms: {\n facebook: \"Facebook\",\n twitter: \"X (Twitter)\",\n instagram: \"Instagram\",\n linkedin: \"LinkedIn\",\n youtube: \"YouTube\",\n tiktok: \"TikTok\",\n pinterest: \"Pinterest\",\n email: \"Correo electrónico\",\n website: \"Sitio web\",\n whatsapp: \"WhatsApp\",\n telegram: \"Telegram\",\n discord: \"Discord\",\n snapchat: \"Snapchat\",\n reddit: \"Reddit\",\n github: \"GitHub\",\n dribbble: \"Dribbble\",\n behance: \"Behance\",\n },\n },\n\n // Toolbar - Menu\n menu: {\n items: \"Elementos del menú\",\n addItem: \"Añadir elemento\",\n removeItem: \"Eliminar\",\n text: \"Texto\",\n urlPlaceholder: \"https://example.com\",\n openInNewTab: \"Abrir en una nueva pestaña\",\n bold: \"Negrita\",\n underline: \"Subrayado\",\n color: \"Color\",\n linkColor: \"Color del enlace\",\n fontSize: \"Tamaño de fuente\",\n fontFamily: \"Familia tipográfica\",\n separator: \"Separador\",\n separatorColor: \"Color del separador\",\n spacing: \"Espaciado\",\n textAlign: \"Alineación\",\n addLinks: \"Añadir enlaces al menú\",\n },\n\n // Toolbar - Table\n table: {\n dimensions: \"Dimensiones\",\n rows: \"Filas\",\n columns: \"Columnas\",\n hasHeaderRow: \"Fila de encabezado\",\n headerBackgroundColor: \"Fondo del encabezado\",\n noHeaderBg: \"Sin fondo\",\n borderColor: \"Color del borde\",\n borderWidth: \"Grosor del borde\",\n cellPadding: \"Relleno de la celda\",\n fontFamily: \"Familia tipográfica\",\n fontSize: \"Tamaño de fuente\",\n color: \"Color del texto\",\n textAlign: \"Alineación\",\n cellPlaceholder: \"Introduce el texto...\",\n empty: \"Añadir una tabla\",\n },\n\n // Toolbar - Paragraph\n paragraph: {\n paragraphSpacing: \"Espaciado entre párrafos\",\n },\n\n // Toolbar - Spacer\n spacer: {\n height: \"Altura\",\n },\n\n // Toolbar - Countdown\n countdown: {\n targetDate: \"Fecha límite\",\n timezone: \"Zona horaria\",\n display: \"Visualización\",\n days: \"Días\",\n hours: \"Horas\",\n minutes: \"Minutos\",\n seconds: \"Segundos\",\n separator: \"Separador\",\n fontFamily: \"Familia tipográfica\",\n inheritFont: \"Por defecto\",\n digitFontSize: \"Tamaño de los dígitos\",\n digitColor: \"Color de los dígitos\",\n labelColor: \"Color de la etiqueta\",\n labelFontSize: \"Tamaño de la etiqueta\",\n background: \"Fondo\",\n labels: \"Etiquetas\",\n expiry: \"Mensaje de expiración\",\n expiredMessagePlaceholder: \"Esta oferta ha expirado\",\n expiredImageUrl: \"URL de la imagen caducada\",\n hideOnExpiry: \"Ocultar al expirar\",\n setDate: \"Establece una fecha límite en el panel de configuración\",\n hidden: \"Oculto (expirado)\",\n },\n\n // Custom Blocks\n customBlocks: {\n definitionNotFound:\n \"Tipo de bloque desconocido: este bloque no está registrado\",\n renderError:\n \"No se pudo renderizar este bloque. Comprueba si hay errores en la plantilla del bloque.\",\n fields: {\n required: \"Obligatorio\",\n addItem: \"Añadir elemento\",\n removeItem: \"Eliminar\",\n maxItemsReached: \"Se ha alcanzado el máximo de elementos\",\n minItemsRequired: \"Se requiere un mínimo de {count} elementos\",\n },\n toolbar: {\n noDefinition:\n \"Registra este tipo de bloque en la configuración de tu SDK para editar sus propiedades\",\n },\n dataSource: {\n fetchButton: \"Cargar contenido\",\n changeButton: \"Cambiar\",\n fetching: \"Cargando...\",\n readOnlyTooltip: \"Este valor se carga desde tu fuente de datos\",\n fetchError: \"Error al cargar el contenido\",\n },\n },\n\n // Toolbar - HTML\n html: {\n content: \"Contenido HTML\",\n preview: \"Bloque HTML personalizado\",\n empty: \"Añadir contenido HTML en el panel\",\n sanitizationHint:\n \"El HTML se exporta tal cual y no se sanea — asegúrate de que el contenido sea seguro.\",\n },\n\n // Toolbar - Common block settings\n blockSettings: {\n spacing: \"Espaciado\",\n padding: \"Relleno\",\n background: \"Fondo\",\n color: \"Color\",\n display: \"Visualización\",\n showOnDesktop: \"Mostrar en escritorio\",\n showOnMobile: \"Mostrar en móvil\",\n hiddenOnDevice: \"Oculto en {device}\",\n displayCondition: \"Condición de visualización\",\n selectCondition: \"Seleccionar condición\",\n removeCondition: \"Eliminar condición\",\n noCondition: \"Siempre visible\",\n conditionApplied: \"Condición aplicada\",\n customCondition: \"Condición personalizada\",\n customConditionLabel: \"Nombre de la condición\",\n customConditionBefore: \"Antes (lógica de apertura)\",\n customConditionAfter: \"Después (lógica de cierre)\",\n applyCondition: \"Aplicar\",\n cancelCondition: \"Cancelar\",\n customBadge: \"Personalizado\",\n restoreHiddenBlocks: \"Mostrar todos los bloques ocultos\",\n },\n\n // Template settings\n templateSettings: {\n layout: \"Diseño\",\n widthPreset: \"Ancho predefinido\",\n customWidth: \"Ancho personalizado\",\n appearance: \"Apariencia\",\n backgroundColor: \"Color de fondo\",\n textColor: \"Color del texto\",\n linkColor: \"Color del enlace\",\n linkUnderline: \"Subrayar enlaces\",\n fontFamily: \"Familia tipográfica\",\n preheaderText: \"Texto del preencabezado\",\n preheaderTextPlaceholder:\n \"Texto de vista previa que se muestra después del asunto en la bandeja de entrada...\",\n preheaderTextHint:\n \"Este texto aparece después del asunto en las vistas previas de los clientes de correo electrónico. Admite etiquetas de combinación.\",\n language: \"Idioma\",\n contentLocale: \"Idioma del contenido\",\n contentLocaleHint:\n \"Código BCP 47 (por ejemplo, es, en, de). Establece el atributo lang del correo electrónico renderizado para que los lectores de pantalla pronuncien el contenido correctamente.\",\n contentDirection: \"De derecha a izquierda\",\n contentDirectionHint:\n \"Dirección de escritura del correo, independiente del idioma del editor. Si no se indica, sigue el idioma del contenido (árabe, hebreo, …).\",\n tips: \"Consejos\",\n tip1: \"600px es el ancho estándar para las plantillas de correo electrónico\",\n tip2: \"Usa fuentes seguras para la web para una mejor compatibilidad\",\n tip3: \"Los fondos claros funcionan mejor para la legibilidad\",\n },\n\n // Spacing control\n spacingControl: {\n lockAll: \"Bloquear todos los lados\",\n unlock: \"Desbloquear lados\",\n top: \"Superior\",\n right: \"Derecho\",\n bottom: \"Inferior\",\n left: \"Izquierdo\",\n decreaseTop: \"Disminuir superior\",\n increaseTop: \"Aumentar superior\",\n decreaseLeft: \"Disminuir izquierdo\",\n increaseLeft: \"Aumentar izquierdo\",\n decreaseRight: \"Disminuir derecho\",\n increaseRight: \"Aumentar derecho\",\n decreaseBottom: \"Disminuir inferior\",\n increaseBottom: \"Aumentar inferior\",\n },\n\n // Color Picker\n colorPicker: {\n pickColor: \"Elegir un color\",\n hexValue: \"Valor de color Hex\",\n notSet: \"No establecido\",\n clear: \"Limpiar color\",\n presetColors: \"Colores predefinidos\",\n },\n\n // Merge Tag\n mergeTag: {\n editAsText: \"Editar como texto\",\n fieldGroup: \"Valor con etiquetas de combinación\",\n remove: \"Eliminar etiqueta de combinación\",\n insert: \"Insertar etiqueta de combinación\",\n insertShort: \"Etiqueta de combinación\",\n editValue: \"Editar valor de la etiqueta de combinación\",\n changeTag: \"Cambiar etiqueta de combinación: {label}\",\n unknownLabel: \"Etiqueta de combinación\",\n deleteMergeTag: \"Eliminar etiqueta de combinación\",\n suggestionEmpty: \"No hay etiquetas de combinación coincidentes\",\n picker: {\n title: \"Insertar etiqueta de combinación\",\n changeTitle: \"Cambiar etiqueta de combinación\",\n searchPlaceholder: \"Buscar etiquetas de combinación\",\n searchAriaLabel: \"Buscar etiquetas de combinación\",\n noResults: \"No hay etiquetas de combinación coincidentes\",\n empty: \"No hay etiquetas de combinación configuradas\",\n otherGroup: \"Otro\",\n close: \"Cerrar\",\n groupCount: \"{count}\",\n sample: \"Vista previa: {sample}\",\n },\n },\n\n // Logic tags (standalone, separate from merge tags)\n logicTag: {\n insert: \"Insertar lógica\",\n insertShort: \"Lógica\",\n picker: {\n title: \"Insertar lógica\",\n searchPlaceholder: \"Buscar etiquetas de lógica\",\n searchAriaLabel: \"Buscar etiquetas de lógica\",\n noResults: \"No hay etiquetas de lógica coincidentes\",\n empty: \"No hay etiquetas de lógica configuradas\",\n otherGroup: \"Otro\",\n close: \"Cerrar\",\n },\n },\n\n // Canvas\n canvas: {\n noBlocks: \"Aún no hay bloques\",\n dragHint: \"Comienza desde cero arrastrando bloques desde la barra lateral\",\n dropHere: \"Suelta aquí\",\n aiHintChat: \"o deja que\",\n aiHintChatSuffix: \"genere una plantilla completa para ti en segundos\",\n aiHintDesign:\n \"¿Tienes un diseño existente? Sube una captura de pantalla, imagen o PDF y\",\n aiHintDesignSuffix: \"lo recreará instantáneamente\",\n },\n\n // Sidebar\n savedBlocks: {\n title: \"Bloques guardados\",\n saveAsBlock: \"Guardar como bloque\",\n name: \"Nombre\",\n namePlaceholder: \"p. ej. Encabezado, Pie de página, CTA...\",\n save: \"Guardar bloque\",\n saving: \"Guardando...\",\n cancel: \"Cancelar\",\n empty: \"Aún no hay bloques guardados\",\n emptyHint: \"Guarda bloques de tus plantillas para reutilizarlos más tarde.\",\n noResults: \"Ningún bloque guardado coincide con tu búsqueda\",\n search: \"Buscar bloques guardados...\",\n loading: \"Cargando bloques guardados…\",\n category: \"Categoría\",\n categoryPlaceholder: \"p. ej. Cabeceras, Promociones... (opcional)\",\n allCategories: \"Todas las categorías\",\n filterByCategory: \"Filtrar por categoría\",\n insert: \"Insertar\",\n rename: \"Cambiar nombre\",\n delete: \"Eliminar\",\n deleteConfirm: \"¿Eliminar este bloque guardado?\",\n blockCount: \"{count} bloque(s)\",\n browse: \"Explorar bloques guardados\",\n selectToPreview: \"Selecciona un bloque guardado para previsualizarlo\",\n insertAtBeginning: \"Al principio\",\n insertAfterBlock: \"Después de {block}\",\n insertAtEnd: \"Al final\",\n insertPosition: \"Posición de inserción\",\n close: \"Cerrar\",\n pickToolbar: \"Selección de bloque guardado\",\n pickCount: \"{count} bloque(s) seleccionado(s)\",\n pickHint: \"Haz clic en los bloques para añadirlos o quitarlos\",\n savingCount: \"Guardando {count} bloque(s):\",\n reorderHint:\n \"Arrastra para reordenar: los bloques se guardan en este orden\",\n reorderHandle: \"Reordenar {block}, posición {position} de {total}\",\n reorderAnnouncement: \"{block} movido a la posición {position} de {total}\",\n expand: \"Expandir\",\n collapse: \"Contraer\",\n expandPreview: \"Expandir la vista previa de {block}\",\n collapsePreview: \"Contraer la vista previa de {block}\",\n },\n comments: {\n button: \"Comentarios\",\n title: \"Comentarios\",\n close: \"Cerrar\",\n placeholder: \"Escribe un comentario...\",\n replyPlaceholder: \"Escribe una respuesta...\",\n reply: \"Responder\",\n resolve: \"Resolver\",\n unresolve: \"Reabrir\",\n delete: \"Eliminar\",\n edit: \"Editar\",\n cancel: \"Cancelar\",\n save: \"Guardar\",\n noComments: \"Aún no hay comentarios\",\n noCommentsHint:\n \"Inicia una conversación añadiendo un comentario a la plantilla o a un bloque concreto.\",\n deleteConfirm: \"¿Eliminar este comentario?\",\n filterAll: \"Todos\",\n filterUnresolved: \"Sin resolver\",\n filterBlock: \"Este bloque\",\n jumpToBlock: \"Bloque\",\n ownedByYou: \"Tú\",\n edited: \"editado\",\n resolvedBy: \"Resuelto por {name}\",\n replyOne: \"{count} respuesta\",\n replyMany: \"{count} respuestas\",\n missingBlock: \"Bloque no encontrado\",\n saveTemplateFirst: \"Guarda la plantilla antes de comentar en este bloque.\",\n },\n versionHistory: {\n tooltip: \"Historial de versiones\",\n dropdownTitle: \"Historial de versiones\",\n empty: \"Todavía no hay versiones\",\n auto: \"auto\",\n olderVersion: \"Versión anterior\",\n newerVersion: \"Versión más reciente\",\n },\n versionPreview: {\n message: \"Estás viendo una versión anterior de esta plantilla.\",\n cancel: \"Cancelar\",\n restore: \"Restaurar esta versión\",\n restoreConfirm: {\n title: \"¿Restaurar esta versión?\",\n unsavedWithSave:\n \"Tienes cambios sin guardar. Guárdalos primero y se conservarán en el historial; si restauras sin guardar, se perderán.\",\n unsavedNoSave:\n \"Tienes cambios sin guardar y no hay dónde guardarlos. Al restaurar esta versión se perderán.\",\n saveAndRestore: \"Guardar y restaurar\",\n restoreAnyway: \"Restaurar de todos modos\",\n cancel: \"Cancelar\",\n },\n },\n previewResolution: {\n resolving: \"Resolviendo la vista previa…\",\n failed:\n \"No se pudo resolver la vista previa; se muestra la plantilla sin resolver.\",\n hint: \"La vista previa usa datos resueltos por tu backend.\",\n },\n mergeTagPreview: {\n label: \"Vista de etiquetas de combinación\",\n sample: \"Ejemplo\",\n labelView: \"Etiqueta\",\n },\n testEmail: {\n title: \"Enviar correo de prueba\",\n recipientLabel: \"Destinatario\",\n recipientPlaceholder: \"tu@ejemplo.com\",\n invalidAddress: \"Introduce una dirección de correo válida.\",\n preview: \"Vista previa\",\n previewHint:\n \"Las etiquetas de combinación se muestran sin resolver — tu backend las rellena.\",\n previewHintSample:\n \"Las etiquetas de combinación muestran valores de ejemplo; tu backend inserta los datos reales.\",\n recipientNotAllowed:\n \"Esa dirección no está en la lista de destinatarios permitidos.\",\n send: \"Enviar\",\n sending: \"Enviando...\",\n cancel: \"Cancelar\",\n success: \"Correo de prueba enviado correctamente\",\n button: \"Prueba\",\n },\n sidebarNav: {\n browseSavedBlocks: \"Explorar bloques guardados\",\n palette: \"Paleta de bloques\",\n insertBlock: \"Insertar bloque {block}\",\n },\n\n // Landmark region labels for assistive technology\n landmarks: {\n canvas: \"Lienzo del correo electrónico\",\n blockToolbar: \"Propiedades del bloque\",\n rightSidebar: \"Propiedades del bloque y configuración de la plantilla\",\n reorderAnnouncements: \"Anuncios de reordenación de bloques\",\n },\n\n // Design Reference (cloud)\n errors: {\n editorLoading: \"Cargando el editor...\",\n editorLoadFailed: \"Error al cargar el editor.\",\n retry: \"Reintentar\",\n },\n\n issues: {\n panelTitle: \"Problemes\",\n panelTabLabel: \"Problemes\",\n groupErrors: \"Errores\",\n groupWarnings: \"Advertencias\",\n groupInfo: \"Información\",\n jump: \"Saltar al bloque\",\n fix: \"Corregir\",\n emptyState: \"Sin problemas, todo se ve bien.\",\n badgeError: \"Tiene errores\",\n badgeWarning: \"Tiene advertencias\",\n issueCountTooltip: \"{count} problema(s)\",\n },\n\n smallScreen: {\n title: \"Se requiere una pantalla más grande\",\n message:\n \"El editor necesita más espacio del que ofrece esta pantalla. Ábrelo en una tableta o computadora de escritorio para comenzar a editar.\",\n },\n};\n\nexport default es;\n"],"mappings":";AAEA,IAAM,IAAgB;CAEpB,QAAQ;EACN,WAAW;EACX,YAAY;CACd;CAIA,QAAQ;EACN,MAAM;EACN,QAAQ;EACR,OAAO;EACP,SAAS;EACT,YAAY;EACZ,gBAAgB;EAChB,cAAc;EACd,QAAQ;EACR,UAAU;EACV,WAAW;EACX,WAAW;EACX,gBAAgB;EAChB,gBAAgB;CAClB;CAIA,MAAM;EACJ,SAAS;EACT,YAAY;EACZ,UAAU;EACV,SAAS;CACX;CAGA,SAAS;EACP,eACE;EACF,MAAM;EACN,MAAM;CACR;CAGA,UAAU;EACR,OAAO;EACP,SAAS;EACT,QAAQ;CACV;CAGA,UAAU;EACR,QAAQ;EACR,SAAS;CACX;CAGA,aAAa;EACX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S;EACT,aAAa;CACf;CAGA,WAAW;EACT,QAAQ;EACR,cAAc;EACd,cAAc;EACd,sBAAsB;CACxB;CAGA,QAAQ;EACN,eAAe;EACf,kBAAkB;EAClB,OAAO;CACT;CAEA,QAAQ;EACN,YAAY;EACZ,eAAe;EACf,aAAa;EACb,eAAe;EACf,WAAW;EACX,MAAM;EACN,KAAK;EACL,YAAY;EACZ,YAAY;EACZ,cAAc;EACd,mBAAmB;CACrB;CAEA,aAAa;EACX,OAAO;EACP,SACE;CACJ;AACF"}
@@ -1,9 +1,9 @@
1
1
  import { H as e, N as t, Q as n, S as r, U as i, Y as a, at as o, c as s, ct as c, f as l, g as u, h as d, k as f, l as p, lt as m, m as h, o as g, p as _, ut as v } from "./draggable-IB4x6w2O.js";
2
- import { a as y, d as b, o as x, r as S } from "./src-Dwgq7hf4.js";
3
- import { t as C } from "./useI18n-DTZ9sIcv.js";
4
- import { t as w } from "./useMergeTag-BE8oDoha.js";
2
+ import { a as y, d as b, o as x, r as S } from "./src-DveVYoWS.js";
3
+ import { t as C } from "./useI18n-CyO_Nmca.js";
4
+ import { t as w } from "./useMergeTag-DbIHw4NG.js";
5
5
  import { _ as T, g as E, h as D, n as O, r as k, t as A, v as j, y as M } from "./tiptap-DhLuKyDc.js";
6
- import { a as N, o as P, s as F } from "./LogicTagInsertButton-DpyPozop.js";
6
+ import { a as N, o as P, s as F } from "./LogicTagInsertButton-CHc1yZ9v.js";
7
7
  //#region src/extensions/FontSize.ts
8
8
  var I = D.create({
9
9
  name: "fontSize",
@@ -527,4 +527,4 @@ var $ = D.create({
527
527
  //#endregion
528
528
  export { I as FontSize, L as LetterSpacing, R as LineBoundaryKeys, z as LineHeight, K as LogicMergeTagNode, Z as MergeTagNode, $ as MergeTagSuggestion, P as filterMergeTags, F as handleSuggestionKeyDown };
529
529
 
530
- //# sourceMappingURL=extensions-Bhu8UEE5.js.map
530
+ //# sourceMappingURL=extensions-CafoGF65.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"extensions-Bhu8UEE5.js","names":[],"sources":["../../../src/extensions/FontSize.ts","../../../src/extensions/LetterSpacing.ts","../../../src/extensions/LineBoundaryKeys.ts","../../../src/extensions/LineHeight.ts","../../../src/extensions/LogicMergeTagNodeView.vue","../../../src/extensions/LogicMergeTagNodeView.vue","../../../src/extensions/isNodeSelected.ts","../../../src/extensions/renderVueNodeView.ts","../../../src/extensions/LogicMergeTagNode.ts","../../../src/extensions/MergeTagNodeView.vue","../../../src/extensions/MergeTagNodeView.vue","../../../src/extensions/MergeTagNode.ts","../../../src/extensions/MergeTagSuggestion.ts"],"sourcesContent":["import { Extension } from \"@tiptap/core\";\n\nexport interface FontSizeOptions {\n types: string[];\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n fontSize: {\n setFontSize: (size: string) => ReturnType;\n unsetFontSize: () => ReturnType;\n };\n }\n}\n\nexport const FontSize = Extension.create<FontSizeOptions>({\n name: \"fontSize\",\n\n addOptions() {\n return {\n types: [\"textStyle\"],\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n fontSize: {\n default: null,\n parseHTML: (element) =>\n element.style.fontSize?.replace(/['\"]+/g, \"\") || null,\n renderHTML: (attributes) => {\n if (!attributes.fontSize) {\n return {};\n }\n return {\n style: `font-size: ${attributes.fontSize}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setFontSize:\n (size: string) =>\n ({ chain }) => {\n return chain().setMark(\"textStyle\", { fontSize: size }).run();\n },\n unsetFontSize:\n () =>\n ({ chain }) => {\n return chain()\n .setMark(\"textStyle\", { fontSize: null })\n .removeEmptyTextStyle()\n .run();\n },\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\nexport interface LetterSpacingOptions {\n types: string[];\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n letterSpacing: {\n setLetterSpacing: (spacing: string) => ReturnType;\n unsetLetterSpacing: () => ReturnType;\n };\n }\n}\n\nexport const LetterSpacing = Extension.create<LetterSpacingOptions>({\n name: \"letterSpacing\",\n\n addOptions() {\n return {\n types: [\"textStyle\"],\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n letterSpacing: {\n default: null,\n parseHTML: (element) =>\n element.style.letterSpacing?.replace(/['\"]+/g, \"\") || null,\n renderHTML: (attributes) => {\n if (!attributes.letterSpacing) {\n return {};\n }\n return {\n style: `letter-spacing: ${attributes.letterSpacing}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setLetterSpacing:\n (spacing: string) =>\n ({ chain }) => {\n return chain().setMark(\"textStyle\", { letterSpacing: spacing }).run();\n },\n unsetLetterSpacing:\n () =>\n ({ chain }) => {\n return chain()\n .setMark(\"textStyle\", { letterSpacing: null })\n .removeEmptyTextStyle()\n .run();\n },\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\n/**\n * Routes plain End/Home through `Selection.modify` instead of the browser's\n * native caret movement.\n *\n * Chromium (verified 140–151, including stable Chrome) has a bug where a\n * native End or Home pressed while a triple-click selection is active puts\n * Blink's selection state into a mode where the next typed character\n * natively smooth-scrolls the nearest scrollable ancestor (the editor's\n * canvas, `.tpl-body`) to its very bottom (End) or top (Home), dragging the\n * caret out of view. The state cannot be repaired after the fact — clearing\n * or re-setting the DOM selection, blur/refocus, and preventDefault on the\n * clicks all fail — but a programmatic caret move never arms it.\n *\n * `Selection.modify(\"move\", direction, \"lineboundary\")` is the exact\n * equivalent of the native key (visual line boundary, bidi-aware via the\n * logical forward/backward directions), so behavior is unchanged for users.\n * Shift+End / Shift+Home extend selections natively and do not trigger the\n * bug, so only the plain keys are bound — a keymap entry without modifiers\n * never matches the shifted keys.\n */\nexport const LineBoundaryKeys = Extension.create({\n name: \"lineBoundaryKeys\",\n\n addKeyboardShortcuts() {\n const moveToLineBoundary =\n (direction: \"forward\" | \"backward\") =>\n ({ editor }: { editor: { view: unknown } }): boolean => {\n const view = editor.view as {\n composing: boolean;\n root: DocumentOrShadowRoot & {\n getSelection?: () => Selection | null;\n };\n dom: HTMLElement;\n };\n // During IME composition End/Home commit the composition; leave\n // that to the browser.\n if (!view || view.composing) return false;\n // `view.root` is the editable's Document or ShadowRoot, so the\n // selection resolves correctly in both mount modes. ShadowRoot's\n // getSelection is Chromium-only; elsewhere fall back to the owner\n // document (Chromium is also the only engine with the bug).\n const selection =\n typeof view.root?.getSelection === \"function\"\n ? view.root.getSelection()\n : (view.dom?.ownerDocument?.getSelection?.() ?? null);\n // `modify` is non-standard; without it, or with a selection that\n // is not ours, native handling is the safer default.\n if (!selection || typeof selection.modify !== \"function\") return false;\n if (!selection.anchorNode || !view.dom.contains(selection.anchorNode)) {\n return false;\n }\n selection.modify(\"move\", direction, \"lineboundary\");\n return true;\n };\n\n return {\n End: moveToLineBoundary(\"forward\"),\n Home: moveToLineBoundary(\"backward\"),\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\nexport interface LineHeightOptions {\n types: string[];\n defaultLineHeight: string;\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n lineHeight: {\n setLineHeight: (lineHeight: string) => ReturnType;\n unsetLineHeight: () => ReturnType;\n };\n }\n}\n\nexport const LineHeight = Extension.create<LineHeightOptions>({\n name: \"lineHeight\",\n\n addOptions() {\n return {\n types: [\"paragraph\"],\n defaultLineHeight: \"1.5\",\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n lineHeight: {\n default: null,\n parseHTML: (element) => element.style.lineHeight || null,\n renderHTML: (attributes) => {\n if (!attributes.lineHeight) {\n return {};\n }\n return {\n style: `line-height: ${attributes.lineHeight}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setLineHeight:\n (lineHeight: string) =>\n ({ commands }) => {\n return this.options.types.every((type) =>\n commands.updateAttributes(type, { lineHeight }),\n );\n },\n unsetLineHeight:\n () =>\n ({ commands }) => {\n return this.options.types.every((type) =>\n commands.resetAttributes(type, \"lineHeight\"),\n );\n },\n };\n },\n});\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n} from \"@templatical/types\";\nimport type { Editor } from \"@tiptap/core\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n value: string;\n keyword: string;\n };\n };\n editor: Editor;\n getPos: () => number;\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst { syntax } = useMergeTag();\nconst { t } = useI18n();\n\nconst isValid = computed(() =>\n isLogicMergeTagValue(props.node.attrs.value, syntax),\n);\nconst displayKeyword = computed(() =>\n getLogicMergeTagKeyword(props.node.attrs.value, syntax),\n);\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\nlet handled = false;\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n handled = false;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\nfunction finishEditing(): void {\n if (handled) {\n return;\n }\n handled = true;\n\n const newValue = editValue.value.trim();\n if (!newValue) {\n isEditing.value = false;\n return;\n }\n\n if (newValue !== props.node.attrs.value) {\n props.updateAttributes({\n value: newValue,\n keyword: isLogicMergeTagValue(newValue, syntax)\n ? getLogicMergeTagKeyword(newValue, syntax)\n : \"\",\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n :class=\"\n isValid\n ? 'tpl-logic-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.8em] tpl:font-bold tpl:tracking-wide tpl:uppercase tpl:select-none'\n : ''\n \"\n :style=\"\n isValid\n ? 'background-color: transparent; border: 1.5px solid color-mix(in srgb, var(--tpl-primary) 50%, transparent); color: var(--tpl-primary);'\n : ''\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n class=\"tpl:w-40 tpl:rounded tpl:border-none tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:normal-case tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode: valid merge tag -->\n <span\n v-else-if=\"isValid\"\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n class=\"tpl-tooltip tpl:cursor-pointer\"\n :data-tooltip=\"node.attrs.value\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ displayKeyword }}\n </span>\n <!-- Display mode: invalid (plain text) -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ node.attrs.value }}\n </span>\n <button\n v-if=\"isValid\"\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n} from \"@templatical/types\";\nimport type { Editor } from \"@tiptap/core\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n value: string;\n keyword: string;\n };\n };\n editor: Editor;\n getPos: () => number;\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst { syntax } = useMergeTag();\nconst { t } = useI18n();\n\nconst isValid = computed(() =>\n isLogicMergeTagValue(props.node.attrs.value, syntax),\n);\nconst displayKeyword = computed(() =>\n getLogicMergeTagKeyword(props.node.attrs.value, syntax),\n);\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\nlet handled = false;\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n handled = false;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\nfunction finishEditing(): void {\n if (handled) {\n return;\n }\n handled = true;\n\n const newValue = editValue.value.trim();\n if (!newValue) {\n isEditing.value = false;\n return;\n }\n\n if (newValue !== props.node.attrs.value) {\n props.updateAttributes({\n value: newValue,\n keyword: isLogicMergeTagValue(newValue, syntax)\n ? getLogicMergeTagKeyword(newValue, syntax)\n : \"\",\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n :class=\"\n isValid\n ? 'tpl-logic-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.8em] tpl:font-bold tpl:tracking-wide tpl:uppercase tpl:select-none'\n : ''\n \"\n :style=\"\n isValid\n ? 'background-color: transparent; border: 1.5px solid color-mix(in srgb, var(--tpl-primary) 50%, transparent); color: var(--tpl-primary);'\n : ''\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n class=\"tpl:w-40 tpl:rounded tpl:border-none tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:normal-case tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode: valid merge tag -->\n <span\n v-else-if=\"isValid\"\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n class=\"tpl-tooltip tpl:cursor-pointer\"\n :data-tooltip=\"node.attrs.value\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ displayKeyword }}\n </span>\n <!-- Display mode: invalid (plain text) -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ node.attrs.value }}\n </span>\n <button\n v-if=\"isValid\"\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","import type { Editor } from \"@tiptap/core\";\n\n/**\n * Decides whether MergeTagNode / LogicMergeTagNode should swallow a\n * Backspace/Delete keystroke (returning `true` from a TipTap keymap\n * suppresses the default behavior).\n *\n * Only suppresses in the cursor-adjacent case so the \"first press\n * selects the atom, second press deletes it\" UX works. Range selections\n * (Cmd+A, drag-select, double-click-word) explicitly fall through —\n * default `replaceSelection` then deletes the entire range including\n * any merge-tag atoms inside it.\n *\n * Earlier revisions also returned `true` whenever `nodesBetween($from,\n * $to)` found a merge tag anywhere in the selection range — which\n * silently broke Cmd+A + Backspace for any paragraph containing a\n * merge tag (entire deletion was cancelled, nothing happened). The\n * cursor-adjacent protection is the only piece that should survive.\n */\nexport function isNodeSelected(editor: Editor, nodeTypeName: string): boolean {\n const { $from, $to } = editor.state.selection;\n\n // Range selection: let TipTap's default range-delete run. Even when\n // the range contains atom nodes, ProseMirror's replaceSelection\n // handles atomic deletion correctly.\n if ($from.pos !== $to.pos) return false;\n\n // Cursor-adjacent atom: protect from single-keystroke deletion.\n // (`$from.pos > 0` guards against reading `nodeBefore` at doc start\n // where ProseMirror's index would be undefined for nodeBefore.)\n if ($from.pos > 0 && $from.nodeBefore?.type.name === nodeTypeName) {\n return true;\n }\n if ($from.nodeAfter?.type.name === nodeTypeName) {\n return true;\n }\n\n return false;\n}\n","import type { Component } from \"vue\";\nimport { VueNodeViewRenderer } from \"@tiptap/vue-3\";\n\n/**\n * Typed wrapper for VueNodeViewRenderer that handles the known type mismatch\n * between Vue SFC default exports and TipTap's expected component type.\n */\nexport function renderVueNodeView(component: Component) {\n return VueNodeViewRenderer(\n component as Parameters<typeof VueNodeViewRenderer>[0],\n );\n}\n","import LogicMergeTagNodeView from \"./LogicMergeTagNodeView.vue\";\nimport type { SyntaxPreset } from \"@templatical/types\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n SYNTAX_PRESETS,\n} from \"@templatical/types\";\nimport { InputRule, mergeAttributes, Node, PasteRule } from \"@tiptap/core\";\nimport { isNodeSelected } from \"./isNodeSelected\";\nimport { renderVueNodeView } from \"./renderVueNodeView\";\n\nexport interface LogicMergeTagNodeOptions {\n syntax: SyntaxPreset;\n}\n\nexport const LogicMergeTagNode = Node.create<LogicMergeTagNodeOptions>({\n name: \"logicMergeTagNode\",\n\n group: \"inline\",\n\n inline: true,\n\n atom: true,\n\n addOptions() {\n return {\n syntax: SYNTAX_PRESETS.liquid,\n };\n },\n\n addAttributes() {\n return {\n // Both attributes are state, not markup, same as `MergeTagNode`:\n // `renderHTML()` emits the canonical `data-logic-merge-tag` /\n // `data-keyword` pair and `parseHTML` reads only those. `rendered: false`\n // keeps TipTap from also serializing each attribute under its own name,\n // which would put a write-only duplicate of the same data on every tag.\n value: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-logic-merge-tag\") || \"\",\n },\n keyword: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-keyword\") || element.textContent || \"\",\n },\n };\n },\n\n parseHTML() {\n return [\n {\n tag: \"span[data-logic-merge-tag]\",\n },\n ];\n },\n\n renderHTML({ node, HTMLAttributes }) {\n if (!isLogicMergeTagValue(node.attrs.value, this.options.syntax)) {\n return [\"span\", {}, node.attrs.value];\n }\n\n const keyword = getLogicMergeTagKeyword(\n node.attrs.value,\n this.options.syntax,\n );\n\n return [\n \"span\",\n mergeAttributes(HTMLAttributes, {\n \"data-logic-merge-tag\": node.attrs.value,\n \"data-keyword\": keyword,\n }),\n keyword,\n ];\n },\n\n addNodeView() {\n return renderVueNodeView(LogicMergeTagNodeView);\n },\n\n addKeyboardShortcuts() {\n return {\n Backspace: () => isNodeSelected(this.editor, this.name),\n Delete: () => isNodeSelected(this.editor, this.name),\n };\n },\n\n addInputRules() {\n const inputRegex = new RegExp(this.options.syntax.logic.source + \"$\", \"\");\n\n return [\n new InputRule({\n find: inputRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n if (!isLogicMergeTagValue(fullValue, this.options.syntax)) {\n return;\n }\n\n const keyword = getLogicMergeTagKeyword(\n fullValue,\n this.options.syntax,\n );\n\n const node = this.type.create({\n value: fullValue,\n keyword,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n\n addPasteRules() {\n const pasteRegex = new RegExp(this.options.syntax.logic.source, \"g\");\n\n return [\n new PasteRule({\n find: pasteRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n if (!isLogicMergeTagValue(fullValue, this.options.syntax)) {\n return;\n }\n\n const keyword = getLogicMergeTagKeyword(\n fullValue,\n this.options.syntax,\n );\n\n const node = this.type.create({\n value: fullValue,\n keyword,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n});\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, onScopeDispose, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n label: string;\n value: string;\n };\n };\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst {\n getMergeTagLabel,\n getMergeTagDisplayLabel,\n findMergeTag,\n canRepickMergeTag,\n showRawValue,\n isMergeTagValue,\n requestMergeTag,\n} = useMergeTag();\nconst { t, format } = useI18n();\n\n// `node.attrs.label` is the label captured when the tag was inserted. It is\n// only ever a fallback — the configured tags win, which is what keeps a\n// relabelled tag from rendering its stale stored copy.\nconst displayLabel = computed(() =>\n getMergeTagDisplayLabel(props.node.attrs.value, props.node.attrs.label),\n);\nconst canRepick = computed(() => canRepickMergeTag(props.node.attrs.value));\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\n\n// The chooser mounts in the popover root, outside this node view, so the node\n// can be torn down while it is open — a collaborator edit, a block change, the\n// editor unmounting. Writing attributes onto a destroyed node view throws.\nlet disposed = false;\nonScopeDispose(() => {\n disposed = true;\n});\n\n/** Whether the text currently in the raw input is a usable merge tag. */\nconst isEditValueValid = computed(\n () =>\n editValue.value.trim() === \"\" || isMergeTagValue(editValue.value.trim()),\n);\n\n/**\n * Swap this tag for another one, chosen through the same chooser insertion\n * uses. `requestMergeTag` sets the editor-wide requesting flag for the whole\n * await, which is what stops `useRichTextEditor`'s click-outside handler\n * finishing the block when the user clicks a row in the chooser — that would\n * dispose this node view and silently drop the update.\n */\nasync function repick(): Promise<void> {\n const replacement = await requestMergeTag({\n reason: \"edit\",\n current: findMergeTag(props.node.attrs.value),\n });\n if (disposed || !replacement) return;\n props.updateAttributes({\n value: replacement.value,\n label: replacement.label,\n });\n}\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\n/**\n * Activating the chip opens the chooser when one can resolve this token, and\n * the raw input only when none can. Editing a token as free text is how a\n * chip ends up holding something that is not a merge tag at all, which the\n * renderer then emits verbatim into the sent email.\n */\nfunction activate(): void {\n if (canRepick.value) {\n void repick();\n return;\n }\n startEditing();\n}\n\nfunction finishEditing(): void {\n const newValue = editValue.value.trim();\n // Never commit something that isn't a merge tag: `renderHTML` writes the\n // value straight into `data-merge-tag`, and the renderer drops that into the\n // MJML unchanged, so a typo would ship as literal text in the email.\n if (\n newValue &&\n newValue !== props.node.attrs.value &&\n isMergeTagValue(newValue)\n ) {\n props.updateAttributes({\n // The honest resolution, not the display chain: this is written into the\n // document as `data-label`, so a placeholder would be persisted as if it\n // were the tag's name.\n value: newValue,\n label: getMergeTagLabel(newValue),\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n // Enter on an invalid value keeps the input open rather than discarding\n // what was typed — the border and `aria-invalid` already say why.\n if (!isEditValueValid.value) return;\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n class=\"tpl-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.9em] tpl:font-medium tpl:select-none tpl:text-[var(--tpl-primary)]\"\n style=\"\n background-color: color-mix(in srgb, var(--tpl-primary) 20%, transparent);\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n :aria-invalid=\"isEditValueValid ? undefined : 'true'\"\n class=\"tpl:w-32 tpl:rounded tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n :class=\"\n isEditValueValid\n ? 'tpl:border-none'\n : 'tpl:border tpl:border-[var(--tpl-danger)]'\n \"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"\n canRepick\n ? format(t.mergeTag.changeTag, { label: displayLabel })\n : t.mergeTag.editValue\n \"\n class=\"tpl:cursor-pointer\"\n :class=\"showRawValue ? 'tpl-tooltip' : ''\"\n :data-tooltip=\"showRawValue ? node.attrs.value : undefined\"\n @click.stop=\"activate\"\n @keydown.enter.stop=\"activate\"\n @keydown.space.prevent.stop=\"activate\"\n >\n {{ displayLabel }}\n </span>\n <button\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, onScopeDispose, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n label: string;\n value: string;\n };\n };\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst {\n getMergeTagLabel,\n getMergeTagDisplayLabel,\n findMergeTag,\n canRepickMergeTag,\n showRawValue,\n isMergeTagValue,\n requestMergeTag,\n} = useMergeTag();\nconst { t, format } = useI18n();\n\n// `node.attrs.label` is the label captured when the tag was inserted. It is\n// only ever a fallback — the configured tags win, which is what keeps a\n// relabelled tag from rendering its stale stored copy.\nconst displayLabel = computed(() =>\n getMergeTagDisplayLabel(props.node.attrs.value, props.node.attrs.label),\n);\nconst canRepick = computed(() => canRepickMergeTag(props.node.attrs.value));\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\n\n// The chooser mounts in the popover root, outside this node view, so the node\n// can be torn down while it is open — a collaborator edit, a block change, the\n// editor unmounting. Writing attributes onto a destroyed node view throws.\nlet disposed = false;\nonScopeDispose(() => {\n disposed = true;\n});\n\n/** Whether the text currently in the raw input is a usable merge tag. */\nconst isEditValueValid = computed(\n () =>\n editValue.value.trim() === \"\" || isMergeTagValue(editValue.value.trim()),\n);\n\n/**\n * Swap this tag for another one, chosen through the same chooser insertion\n * uses. `requestMergeTag` sets the editor-wide requesting flag for the whole\n * await, which is what stops `useRichTextEditor`'s click-outside handler\n * finishing the block when the user clicks a row in the chooser — that would\n * dispose this node view and silently drop the update.\n */\nasync function repick(): Promise<void> {\n const replacement = await requestMergeTag({\n reason: \"edit\",\n current: findMergeTag(props.node.attrs.value),\n });\n if (disposed || !replacement) return;\n props.updateAttributes({\n value: replacement.value,\n label: replacement.label,\n });\n}\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\n/**\n * Activating the chip opens the chooser when one can resolve this token, and\n * the raw input only when none can. Editing a token as free text is how a\n * chip ends up holding something that is not a merge tag at all, which the\n * renderer then emits verbatim into the sent email.\n */\nfunction activate(): void {\n if (canRepick.value) {\n void repick();\n return;\n }\n startEditing();\n}\n\nfunction finishEditing(): void {\n const newValue = editValue.value.trim();\n // Never commit something that isn't a merge tag: `renderHTML` writes the\n // value straight into `data-merge-tag`, and the renderer drops that into the\n // MJML unchanged, so a typo would ship as literal text in the email.\n if (\n newValue &&\n newValue !== props.node.attrs.value &&\n isMergeTagValue(newValue)\n ) {\n props.updateAttributes({\n // The honest resolution, not the display chain: this is written into the\n // document as `data-label`, so a placeholder would be persisted as if it\n // were the tag's name.\n value: newValue,\n label: getMergeTagLabel(newValue),\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n // Enter on an invalid value keeps the input open rather than discarding\n // what was typed — the border and `aria-invalid` already say why.\n if (!isEditValueValid.value) return;\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n class=\"tpl-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.9em] tpl:font-medium tpl:select-none tpl:text-[var(--tpl-primary)]\"\n style=\"\n background-color: color-mix(in srgb, var(--tpl-primary) 20%, transparent);\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n :aria-invalid=\"isEditValueValid ? undefined : 'true'\"\n class=\"tpl:w-32 tpl:rounded tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n :class=\"\n isEditValueValid\n ? 'tpl:border-none'\n : 'tpl:border tpl:border-[var(--tpl-danger)]'\n \"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"\n canRepick\n ? format(t.mergeTag.changeTag, { label: displayLabel })\n : t.mergeTag.editValue\n \"\n class=\"tpl:cursor-pointer\"\n :class=\"showRawValue ? 'tpl-tooltip' : ''\"\n :data-tooltip=\"showRawValue ? node.attrs.value : undefined\"\n @click.stop=\"activate\"\n @keydown.enter.stop=\"activate\"\n @keydown.space.prevent.stop=\"activate\"\n >\n {{ displayLabel }}\n </span>\n <button\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","import MergeTagNodeView from \"./MergeTagNodeView.vue\";\nimport type { MergeTag, SyntaxPreset } from \"@templatical/types\";\nimport { getMergeTagLabel, SYNTAX_PRESETS } from \"@templatical/types\";\nimport { InputRule, mergeAttributes, Node, PasteRule } from \"@tiptap/core\";\nimport { isNodeSelected } from \"./isNodeSelected\";\nimport { renderVueNodeView } from \"./renderVueNodeView\";\n\nexport interface MergeTagNodeOptions {\n /**\n * Read live, not captured. `renderHTML` and the input/paste rules resolve a\n * label every time they run, and `editor.setMergeTags` can replace the list\n * while a block is open for editing.\n */\n mergeTags: () => MergeTag[];\n syntax: SyntaxPreset;\n}\n\n/**\n * Inserted-node attrs are intentionally limited to `label` + `value`. The\n * `MergeTag` interface also carries optional `group` / `description` for\n * the built-in picker, but those are display-only and must NOT leak into\n * the document JSON — they would bloat templates and pollute serialized\n * state. `Pick<>` makes the constraint explicit at the type level.\n */\nexport type InsertMergeTagAttrs = Pick<MergeTag, \"label\" | \"value\">;\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n mergeTagNode: {\n insertMergeTag: (attrs: InsertMergeTagAttrs) => ReturnType;\n };\n }\n}\n\nexport const MergeTagNode = Node.create<MergeTagNodeOptions>({\n name: \"mergeTagNode\",\n\n group: \"inline\",\n\n inline: true,\n\n atom: true,\n\n addOptions() {\n return {\n mergeTags: () => [],\n syntax: SYNTAX_PRESETS.liquid,\n };\n },\n\n addAttributes() {\n return {\n // Both attributes are state, not markup: `renderHTML()` below emits the\n // canonical `data-merge-tag` / `data-label` pair and `parseHTML` reads\n // only those. `rendered: false` keeps TipTap from also serializing each\n // attribute under its own name, which would put a write-only duplicate\n // of the same data on every tag — invalid on a `<span>`, and paid again\n // through storage, autosave, snapshots and version history.\n label: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-label\") || element.textContent || \"\",\n },\n value: {\n default: \"\",\n rendered: false,\n parseHTML: (element) => element.getAttribute(\"data-merge-tag\") || \"\",\n },\n };\n },\n\n parseHTML() {\n return [\n {\n tag: \"span[data-merge-tag]\",\n },\n ];\n },\n\n renderHTML({ node, HTMLAttributes }) {\n const label = getMergeTagLabel(node.attrs.value, this.options.mergeTags());\n\n return [\n \"span\",\n mergeAttributes(HTMLAttributes, {\n \"data-merge-tag\": node.attrs.value,\n \"data-label\": label,\n }),\n label,\n ];\n },\n\n addNodeView() {\n return renderVueNodeView(MergeTagNodeView);\n },\n\n addCommands() {\n return {\n insertMergeTag:\n (attrs: InsertMergeTagAttrs) =>\n ({ commands }) => {\n // Whitelist explicitly — even if a caller smuggles extra keys via\n // a wider type assertion, only label/value reach the node attrs.\n return commands.insertContent({\n type: this.name,\n attrs: { label: attrs.label, value: attrs.value },\n });\n },\n };\n },\n\n addKeyboardShortcuts() {\n return {\n Backspace: () => isNodeSelected(this.editor, this.name),\n Delete: () => isNodeSelected(this.editor, this.name),\n };\n },\n\n addInputRules() {\n const inputRegex = new RegExp(this.options.syntax.value.source + \"$\", \"\");\n\n return [\n new InputRule({\n find: inputRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n const label = getMergeTagLabel(fullValue, this.options.mergeTags());\n\n const node = this.type.create({\n label,\n value: fullValue,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n\n addPasteRules() {\n const pasteRegex = new RegExp(this.options.syntax.value.source, \"g\");\n\n return [\n new PasteRule({\n find: pasteRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n const label = getMergeTagLabel(fullValue, this.options.mergeTags());\n\n const node = this.type.create({\n label,\n value: fullValue,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n});\n","import type { MergeTag } from \"@templatical/types\";\nimport { Extension } from \"@tiptap/core\";\nimport Suggestion, {\n type SuggestionOptions,\n type SuggestionProps,\n type SuggestionKeyDownProps,\n} from \"@tiptap/suggestion\";\nimport type { Ref } from \"vue\";\nimport { createMergeTagPopup, filterMergeTags } from \"../utils/mergeTagPopup\";\n\nexport interface MergeTagSuggestionOptions {\n /** Available merge tags */\n /**\n * Read live, not captured: the list can be replaced while a block is being\n * edited (`editor.setMergeTags`), and a snapshot taken when the extension\n * was configured would keep suggesting the old tags.\n */\n mergeTags: () => MergeTag[];\n /** Trigger string (e.g. \"{{\", \"*|\", \"%%=\") */\n char: string;\n /** Localized empty-state label */\n emptyText: string;\n /**\n * Mount target for the suggestion popup. When provided with a non-null\n * `.value`, the popup attaches into that element instead of\n * `document.body` — keeping it inside the editor's effective DOM root\n * (shadow-aware). Pass the ref returned by `usePopoverRoot()`.\n *\n * Falls back to `document.body` when omitted or when the ref's value is\n * null at popup-open time (e.g. headless/test editors without an editor\n * shell). Preserves pre-Phase-3 behavior for callers that don't migrate.\n */\n popoverRoot?: Ref<HTMLElement | null> | null;\n}\n\n/**\n * Builds the `@tiptap/suggestion` `render` factory for the merge-tag popup.\n * A thin adapter over {@link createMergeTagPopup}: it maps ProseMirror's\n * `SuggestionProps` (items, `clientRect`, `view.dom`, `command`) onto the\n * controller. Exported as a standalone function so that mapping can be\n * unit-tested with mocked `SuggestionProps` instead of a full editor.\n */\nexport function createMergeTagSuggestionRenderer(\n emptyText: string,\n popoverRootRef?: Ref<HTMLElement | null> | null,\n): NonNullable<SuggestionOptions<MergeTag>[\"render\"]> {\n return () => {\n const popup = createMergeTagPopup(emptyText, popoverRootRef);\n\n return {\n onStart: (props: SuggestionProps<MergeTag>) => {\n // Use view.dom (ProseMirror contenteditable, actually\n // attached to the DOM) rather than options.element, which may\n // be a detached div when no `element` is passed to the editor\n // constructor (as is the case with @tiptap/vue-3 EditorContent).\n const viewDom = props.editor.view?.dom as HTMLElement | undefined;\n popup.open({\n items: props.items,\n getRect: props.clientRect ?? null,\n anchorEl: viewDom ?? null,\n onCommand: (item) => props.command(item),\n });\n },\n onUpdate: (props: SuggestionProps<MergeTag>) => {\n popup.update({\n items: props.items,\n getRect: props.clientRect ?? null,\n onCommand: (item) => props.command(item),\n });\n },\n onKeyDown: (props: SuggestionKeyDownProps): boolean => {\n // Escape closes via TipTap's suggestion plugin (→ onExit); report it\n // handled without selecting.\n if (props.event.key === \"Escape\") {\n return true;\n }\n return popup.handleKeyDown(props.event);\n },\n onExit: () => popup.close(),\n };\n };\n}\n\nexport const MergeTagSuggestion = Extension.create<MergeTagSuggestionOptions>({\n name: \"mergeTagSuggestion\",\n\n addOptions() {\n return {\n mergeTags: () => [],\n char: \"{{\",\n emptyText: \"No matching merge tags\",\n popoverRoot: null,\n };\n },\n\n addProseMirrorPlugins() {\n const tags = this.options.mergeTags();\n const emptyText = this.options.emptyText;\n const popoverRootRef = this.options.popoverRoot;\n\n const config: Omit<SuggestionOptions<MergeTag>, \"editor\"> = {\n char: this.options.char,\n allowSpaces: false,\n startOfLine: false,\n // Default is [\" \"] which requires whitespace/line-start before the\n // trigger char — so `.{{` would not fire. Allow any preceding char.\n allowedPrefixes: null,\n items: ({ query }: { query: string }) => filterMergeTags(tags, query),\n command: ({\n editor,\n range,\n props,\n }: {\n editor: SuggestionProps<MergeTag>[\"editor\"];\n range: { from: number; to: number };\n props: MergeTag;\n }) => {\n // Use insertContentAt for atomic replace (matches the canonical\n // @tiptap/suggestion + Mention pattern). Avoids edge cases where\n // chained deleteRange + insertMergeTag fails to insert when the\n // selection state shifts mid-chain.\n editor\n .chain()\n .focus()\n .insertContentAt(range, {\n type: \"mergeTagNode\",\n attrs: { label: props.label, value: props.value },\n })\n .run();\n },\n render: createMergeTagSuggestionRenderer(emptyText, popoverRootRef),\n };\n\n return [\n Suggestion({\n editor: this.editor,\n ...config,\n }),\n ];\n },\n});\n"],"mappings":";;;;;;;AAeA,IAAa,IAAW,EAAU,OAAwB;CACxD,MAAM;CAEN,aAAa;EACX,OAAO,EACL,OAAO,CAAC,WAAW,EACrB;CACF;CAEA,sBAAsB;EACpB,OAAO,CACL;GACE,OAAO,KAAK,QAAQ;GACpB,YAAY,EACV,UAAU;IACR,SAAS;IACT,YAAY,MACV,EAAQ,MAAM,UAAU,QAAQ,UAAU,EAAE,KAAK;IACnD,aAAa,MACN,EAAW,WAGT,EACL,OAAO,cAAc,EAAW,WAClC,IAJS,CAAC;GAMd,EACF;EACF,CACF;CACF;CAEA,cAAc;EACZ,OAAO;GACL,cACG,OACA,EAAE,eACM,EAAM,CAAC,CAAC,QAAQ,aAAa,EAAE,UAAU,EAAK,CAAC,CAAC,CAAC,IAAI;GAEhE,sBAEG,EAAE,eACM,EAAM,CAAC,CACX,QAAQ,aAAa,EAAE,UAAU,KAAK,CAAC,CAAC,CACxC,qBAAqB,CAAC,CACtB,IAAI;EAEb;CACF;AACF,CAAC,GCjDY,IAAgB,EAAU,OAA6B;CAClE,MAAM;CAEN,aAAa;EACX,OAAO,EACL,OAAO,CAAC,WAAW,EACrB;CACF;CAEA,sBAAsB;EACpB,OAAO,CACL;GACE,OAAO,KAAK,QAAQ;GACpB,YAAY,EACV,eAAe;IACb,SAAS;IACT,YAAY,MACV,EAAQ,MAAM,eAAe,QAAQ,UAAU,EAAE,KAAK;IACxD,aAAa,MACN,EAAW,gBAGT,EACL,OAAO,mBAAmB,EAAW,gBACvC,IAJS,CAAC;GAMd,EACF;EACF,CACF;CACF;CAEA,cAAc;EACZ,OAAO;GACL,mBACG,OACA,EAAE,eACM,EAAM,CAAC,CAAC,QAAQ,aAAa,EAAE,eAAe,EAAQ,CAAC,CAAC,CAAC,IAAI;GAExE,2BAEG,EAAE,eACM,EAAM,CAAC,CACX,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AO,KAAK,QAAQ,UAAU,GAC9B,IAAY,KAAK,QAAQ,WACzB,IAAiB,KAAK,QAAQ,aAE9B,IAAsD;GAC1D,MAAM,KAAK,QAAQ;GACnB,aAAa;GACb,aAAa;GAGb,iBAAiB;GACjB,QAAQ,EAAE,eAA+B,EAAgB,GAAM,CAAK;GACpE,UAAU,EACR,WACA,UACA,eAKI;IAKJ,EACG,MAAM,CAAC,CACP,MAAM,CAAC,CACP,gBAAgB,GAAO;KACtB,MAAM;KACN,OAAO;MAAE,OAAO,EAAM;MAAO,OAAO,EAAM;KAAM;IAClD,CAAC,CAAC,CACD,IAAI;GACT;GACA,QAAQ,EAAiC,GAAW,CAAc;EACpE;EAEA,OAAO,CACL,EAAW;GACT,QAAQ,KAAK;GACb,GAAG;EACL,CAAC,CACH;CACF;AACF,CAAC"}
1
+ {"version":3,"file":"extensions-CafoGF65.js","names":[],"sources":["../../../src/extensions/FontSize.ts","../../../src/extensions/LetterSpacing.ts","../../../src/extensions/LineBoundaryKeys.ts","../../../src/extensions/LineHeight.ts","../../../src/extensions/LogicMergeTagNodeView.vue","../../../src/extensions/LogicMergeTagNodeView.vue","../../../src/extensions/isNodeSelected.ts","../../../src/extensions/renderVueNodeView.ts","../../../src/extensions/LogicMergeTagNode.ts","../../../src/extensions/MergeTagNodeView.vue","../../../src/extensions/MergeTagNodeView.vue","../../../src/extensions/MergeTagNode.ts","../../../src/extensions/MergeTagSuggestion.ts"],"sourcesContent":["import { Extension } from \"@tiptap/core\";\n\nexport interface FontSizeOptions {\n types: string[];\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n fontSize: {\n setFontSize: (size: string) => ReturnType;\n unsetFontSize: () => ReturnType;\n };\n }\n}\n\nexport const FontSize = Extension.create<FontSizeOptions>({\n name: \"fontSize\",\n\n addOptions() {\n return {\n types: [\"textStyle\"],\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n fontSize: {\n default: null,\n parseHTML: (element) =>\n element.style.fontSize?.replace(/['\"]+/g, \"\") || null,\n renderHTML: (attributes) => {\n if (!attributes.fontSize) {\n return {};\n }\n return {\n style: `font-size: ${attributes.fontSize}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setFontSize:\n (size: string) =>\n ({ chain }) => {\n return chain().setMark(\"textStyle\", { fontSize: size }).run();\n },\n unsetFontSize:\n () =>\n ({ chain }) => {\n return chain()\n .setMark(\"textStyle\", { fontSize: null })\n .removeEmptyTextStyle()\n .run();\n },\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\nexport interface LetterSpacingOptions {\n types: string[];\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n letterSpacing: {\n setLetterSpacing: (spacing: string) => ReturnType;\n unsetLetterSpacing: () => ReturnType;\n };\n }\n}\n\nexport const LetterSpacing = Extension.create<LetterSpacingOptions>({\n name: \"letterSpacing\",\n\n addOptions() {\n return {\n types: [\"textStyle\"],\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n letterSpacing: {\n default: null,\n parseHTML: (element) =>\n element.style.letterSpacing?.replace(/['\"]+/g, \"\") || null,\n renderHTML: (attributes) => {\n if (!attributes.letterSpacing) {\n return {};\n }\n return {\n style: `letter-spacing: ${attributes.letterSpacing}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setLetterSpacing:\n (spacing: string) =>\n ({ chain }) => {\n return chain().setMark(\"textStyle\", { letterSpacing: spacing }).run();\n },\n unsetLetterSpacing:\n () =>\n ({ chain }) => {\n return chain()\n .setMark(\"textStyle\", { letterSpacing: null })\n .removeEmptyTextStyle()\n .run();\n },\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\n/**\n * Routes plain End/Home through `Selection.modify` instead of the browser's\n * native caret movement.\n *\n * Chromium (verified 140–151, including stable Chrome) has a bug where a\n * native End or Home pressed while a triple-click selection is active puts\n * Blink's selection state into a mode where the next typed character\n * natively smooth-scrolls the nearest scrollable ancestor (the editor's\n * canvas, `.tpl-body`) to its very bottom (End) or top (Home), dragging the\n * caret out of view. The state cannot be repaired after the fact — clearing\n * or re-setting the DOM selection, blur/refocus, and preventDefault on the\n * clicks all fail — but a programmatic caret move never arms it.\n *\n * `Selection.modify(\"move\", direction, \"lineboundary\")` is the exact\n * equivalent of the native key (visual line boundary, bidi-aware via the\n * logical forward/backward directions), so behavior is unchanged for users.\n * Shift+End / Shift+Home extend selections natively and do not trigger the\n * bug, so only the plain keys are bound — a keymap entry without modifiers\n * never matches the shifted keys.\n */\nexport const LineBoundaryKeys = Extension.create({\n name: \"lineBoundaryKeys\",\n\n addKeyboardShortcuts() {\n const moveToLineBoundary =\n (direction: \"forward\" | \"backward\") =>\n ({ editor }: { editor: { view: unknown } }): boolean => {\n const view = editor.view as {\n composing: boolean;\n root: DocumentOrShadowRoot & {\n getSelection?: () => Selection | null;\n };\n dom: HTMLElement;\n };\n // During IME composition End/Home commit the composition; leave\n // that to the browser.\n if (!view || view.composing) return false;\n // `view.root` is the editable's Document or ShadowRoot, so the\n // selection resolves correctly in both mount modes. ShadowRoot's\n // getSelection is Chromium-only; elsewhere fall back to the owner\n // document (Chromium is also the only engine with the bug).\n const selection =\n typeof view.root?.getSelection === \"function\"\n ? view.root.getSelection()\n : (view.dom?.ownerDocument?.getSelection?.() ?? null);\n // `modify` is non-standard; without it, or with a selection that\n // is not ours, native handling is the safer default.\n if (!selection || typeof selection.modify !== \"function\") return false;\n if (!selection.anchorNode || !view.dom.contains(selection.anchorNode)) {\n return false;\n }\n selection.modify(\"move\", direction, \"lineboundary\");\n return true;\n };\n\n return {\n End: moveToLineBoundary(\"forward\"),\n Home: moveToLineBoundary(\"backward\"),\n };\n },\n});\n","import { Extension } from \"@tiptap/core\";\n\nexport interface LineHeightOptions {\n types: string[];\n defaultLineHeight: string;\n}\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n lineHeight: {\n setLineHeight: (lineHeight: string) => ReturnType;\n unsetLineHeight: () => ReturnType;\n };\n }\n}\n\nexport const LineHeight = Extension.create<LineHeightOptions>({\n name: \"lineHeight\",\n\n addOptions() {\n return {\n types: [\"paragraph\"],\n defaultLineHeight: \"1.5\",\n };\n },\n\n addGlobalAttributes() {\n return [\n {\n types: this.options.types,\n attributes: {\n lineHeight: {\n default: null,\n parseHTML: (element) => element.style.lineHeight || null,\n renderHTML: (attributes) => {\n if (!attributes.lineHeight) {\n return {};\n }\n return {\n style: `line-height: ${attributes.lineHeight}`,\n };\n },\n },\n },\n },\n ];\n },\n\n addCommands() {\n return {\n setLineHeight:\n (lineHeight: string) =>\n ({ commands }) => {\n return this.options.types.every((type) =>\n commands.updateAttributes(type, { lineHeight }),\n );\n },\n unsetLineHeight:\n () =>\n ({ commands }) => {\n return this.options.types.every((type) =>\n commands.resetAttributes(type, \"lineHeight\"),\n );\n },\n };\n },\n});\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n} from \"@templatical/types\";\nimport type { Editor } from \"@tiptap/core\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n value: string;\n keyword: string;\n };\n };\n editor: Editor;\n getPos: () => number;\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst { syntax } = useMergeTag();\nconst { t } = useI18n();\n\nconst isValid = computed(() =>\n isLogicMergeTagValue(props.node.attrs.value, syntax),\n);\nconst displayKeyword = computed(() =>\n getLogicMergeTagKeyword(props.node.attrs.value, syntax),\n);\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\nlet handled = false;\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n handled = false;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\nfunction finishEditing(): void {\n if (handled) {\n return;\n }\n handled = true;\n\n const newValue = editValue.value.trim();\n if (!newValue) {\n isEditing.value = false;\n return;\n }\n\n if (newValue !== props.node.attrs.value) {\n props.updateAttributes({\n value: newValue,\n keyword: isLogicMergeTagValue(newValue, syntax)\n ? getLogicMergeTagKeyword(newValue, syntax)\n : \"\",\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n :class=\"\n isValid\n ? 'tpl-logic-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.8em] tpl:font-bold tpl:tracking-wide tpl:uppercase tpl:select-none'\n : ''\n \"\n :style=\"\n isValid\n ? 'background-color: transparent; border: 1.5px solid color-mix(in srgb, var(--tpl-primary) 50%, transparent); color: var(--tpl-primary);'\n : ''\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n class=\"tpl:w-40 tpl:rounded tpl:border-none tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:normal-case tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode: valid merge tag -->\n <span\n v-else-if=\"isValid\"\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n class=\"tpl-tooltip tpl:cursor-pointer\"\n :data-tooltip=\"node.attrs.value\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ displayKeyword }}\n </span>\n <!-- Display mode: invalid (plain text) -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ node.attrs.value }}\n </span>\n <button\n v-if=\"isValid\"\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n} from \"@templatical/types\";\nimport type { Editor } from \"@tiptap/core\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n value: string;\n keyword: string;\n };\n };\n editor: Editor;\n getPos: () => number;\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst { syntax } = useMergeTag();\nconst { t } = useI18n();\n\nconst isValid = computed(() =>\n isLogicMergeTagValue(props.node.attrs.value, syntax),\n);\nconst displayKeyword = computed(() =>\n getLogicMergeTagKeyword(props.node.attrs.value, syntax),\n);\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\nlet handled = false;\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n handled = false;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\nfunction finishEditing(): void {\n if (handled) {\n return;\n }\n handled = true;\n\n const newValue = editValue.value.trim();\n if (!newValue) {\n isEditing.value = false;\n return;\n }\n\n if (newValue !== props.node.attrs.value) {\n props.updateAttributes({\n value: newValue,\n keyword: isLogicMergeTagValue(newValue, syntax)\n ? getLogicMergeTagKeyword(newValue, syntax)\n : \"\",\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n :class=\"\n isValid\n ? 'tpl-logic-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.8em] tpl:font-bold tpl:tracking-wide tpl:uppercase tpl:select-none'\n : ''\n \"\n :style=\"\n isValid\n ? 'background-color: transparent; border: 1.5px solid color-mix(in srgb, var(--tpl-primary) 50%, transparent); color: var(--tpl-primary);'\n : ''\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n class=\"tpl:w-40 tpl:rounded tpl:border-none tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:normal-case tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode: valid merge tag -->\n <span\n v-else-if=\"isValid\"\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n class=\"tpl-tooltip tpl:cursor-pointer\"\n :data-tooltip=\"node.attrs.value\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ displayKeyword }}\n </span>\n <!-- Display mode: invalid (plain text) -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"t.mergeTag.editValue\"\n @click.stop=\"startEditing\"\n @keydown.enter.stop=\"startEditing\"\n @keydown.space.prevent.stop=\"startEditing\"\n >\n {{ node.attrs.value }}\n </span>\n <button\n v-if=\"isValid\"\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","import type { Editor } from \"@tiptap/core\";\n\n/**\n * Decides whether MergeTagNode / LogicMergeTagNode should swallow a\n * Backspace/Delete keystroke (returning `true` from a TipTap keymap\n * suppresses the default behavior).\n *\n * Only suppresses in the cursor-adjacent case so the \"first press\n * selects the atom, second press deletes it\" UX works. Range selections\n * (Cmd+A, drag-select, double-click-word) explicitly fall through —\n * default `replaceSelection` then deletes the entire range including\n * any merge-tag atoms inside it.\n *\n * Earlier revisions also returned `true` whenever `nodesBetween($from,\n * $to)` found a merge tag anywhere in the selection range — which\n * silently broke Cmd+A + Backspace for any paragraph containing a\n * merge tag (entire deletion was cancelled, nothing happened). The\n * cursor-adjacent protection is the only piece that should survive.\n */\nexport function isNodeSelected(editor: Editor, nodeTypeName: string): boolean {\n const { $from, $to } = editor.state.selection;\n\n // Range selection: let TipTap's default range-delete run. Even when\n // the range contains atom nodes, ProseMirror's replaceSelection\n // handles atomic deletion correctly.\n if ($from.pos !== $to.pos) return false;\n\n // Cursor-adjacent atom: protect from single-keystroke deletion.\n // (`$from.pos > 0` guards against reading `nodeBefore` at doc start\n // where ProseMirror's index would be undefined for nodeBefore.)\n if ($from.pos > 0 && $from.nodeBefore?.type.name === nodeTypeName) {\n return true;\n }\n if ($from.nodeAfter?.type.name === nodeTypeName) {\n return true;\n }\n\n return false;\n}\n","import type { Component } from \"vue\";\nimport { VueNodeViewRenderer } from \"@tiptap/vue-3\";\n\n/**\n * Typed wrapper for VueNodeViewRenderer that handles the known type mismatch\n * between Vue SFC default exports and TipTap's expected component type.\n */\nexport function renderVueNodeView(component: Component) {\n return VueNodeViewRenderer(\n component as Parameters<typeof VueNodeViewRenderer>[0],\n );\n}\n","import LogicMergeTagNodeView from \"./LogicMergeTagNodeView.vue\";\nimport type { SyntaxPreset } from \"@templatical/types\";\nimport {\n getLogicMergeTagKeyword,\n isLogicMergeTagValue,\n SYNTAX_PRESETS,\n} from \"@templatical/types\";\nimport { InputRule, mergeAttributes, Node, PasteRule } from \"@tiptap/core\";\nimport { isNodeSelected } from \"./isNodeSelected\";\nimport { renderVueNodeView } from \"./renderVueNodeView\";\n\nexport interface LogicMergeTagNodeOptions {\n syntax: SyntaxPreset;\n}\n\nexport const LogicMergeTagNode = Node.create<LogicMergeTagNodeOptions>({\n name: \"logicMergeTagNode\",\n\n group: \"inline\",\n\n inline: true,\n\n atom: true,\n\n addOptions() {\n return {\n syntax: SYNTAX_PRESETS.liquid,\n };\n },\n\n addAttributes() {\n return {\n // Both attributes are state, not markup, same as `MergeTagNode`:\n // `renderHTML()` emits the canonical `data-logic-merge-tag` /\n // `data-keyword` pair and `parseHTML` reads only those. `rendered: false`\n // keeps TipTap from also serializing each attribute under its own name,\n // which would put a write-only duplicate of the same data on every tag.\n value: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-logic-merge-tag\") || \"\",\n },\n keyword: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-keyword\") || element.textContent || \"\",\n },\n };\n },\n\n parseHTML() {\n return [\n {\n tag: \"span[data-logic-merge-tag]\",\n },\n ];\n },\n\n renderHTML({ node, HTMLAttributes }) {\n if (!isLogicMergeTagValue(node.attrs.value, this.options.syntax)) {\n return [\"span\", {}, node.attrs.value];\n }\n\n const keyword = getLogicMergeTagKeyword(\n node.attrs.value,\n this.options.syntax,\n );\n\n return [\n \"span\",\n mergeAttributes(HTMLAttributes, {\n \"data-logic-merge-tag\": node.attrs.value,\n \"data-keyword\": keyword,\n }),\n keyword,\n ];\n },\n\n addNodeView() {\n return renderVueNodeView(LogicMergeTagNodeView);\n },\n\n addKeyboardShortcuts() {\n return {\n Backspace: () => isNodeSelected(this.editor, this.name),\n Delete: () => isNodeSelected(this.editor, this.name),\n };\n },\n\n addInputRules() {\n const inputRegex = new RegExp(this.options.syntax.logic.source + \"$\", \"\");\n\n return [\n new InputRule({\n find: inputRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n if (!isLogicMergeTagValue(fullValue, this.options.syntax)) {\n return;\n }\n\n const keyword = getLogicMergeTagKeyword(\n fullValue,\n this.options.syntax,\n );\n\n const node = this.type.create({\n value: fullValue,\n keyword,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n\n addPasteRules() {\n const pasteRegex = new RegExp(this.options.syntax.logic.source, \"g\");\n\n return [\n new PasteRule({\n find: pasteRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n if (!isLogicMergeTagValue(fullValue, this.options.syntax)) {\n return;\n }\n\n const keyword = getLogicMergeTagKeyword(\n fullValue,\n this.options.syntax,\n );\n\n const node = this.type.create({\n value: fullValue,\n keyword,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n});\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, onScopeDispose, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n label: string;\n value: string;\n };\n };\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst {\n getMergeTagLabel,\n getMergeTagDisplayLabel,\n findMergeTag,\n canRepickMergeTag,\n showRawValue,\n isMergeTagValue,\n requestMergeTag,\n} = useMergeTag();\nconst { t, format } = useI18n();\n\n// `node.attrs.label` is the label captured when the tag was inserted. It is\n// only ever a fallback — the configured tags win, which is what keeps a\n// relabelled tag from rendering its stale stored copy.\nconst displayLabel = computed(() =>\n getMergeTagDisplayLabel(props.node.attrs.value, props.node.attrs.label),\n);\nconst canRepick = computed(() => canRepickMergeTag(props.node.attrs.value));\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\n\n// The chooser mounts in the popover root, outside this node view, so the node\n// can be torn down while it is open — a collaborator edit, a block change, the\n// editor unmounting. Writing attributes onto a destroyed node view throws.\nlet disposed = false;\nonScopeDispose(() => {\n disposed = true;\n});\n\n/** Whether the text currently in the raw input is a usable merge tag. */\nconst isEditValueValid = computed(\n () =>\n editValue.value.trim() === \"\" || isMergeTagValue(editValue.value.trim()),\n);\n\n/**\n * Swap this tag for another one, chosen through the same chooser insertion\n * uses. `requestMergeTag` sets the editor-wide requesting flag for the whole\n * await, which is what stops `useRichTextEditor`'s click-outside handler\n * finishing the block when the user clicks a row in the chooser — that would\n * dispose this node view and silently drop the update.\n */\nasync function repick(): Promise<void> {\n const replacement = await requestMergeTag({\n reason: \"edit\",\n current: findMergeTag(props.node.attrs.value),\n });\n if (disposed || !replacement) return;\n props.updateAttributes({\n value: replacement.value,\n label: replacement.label,\n });\n}\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\n/**\n * Activating the chip opens the chooser when one can resolve this token, and\n * the raw input only when none can. Editing a token as free text is how a\n * chip ends up holding something that is not a merge tag at all, which the\n * renderer then emits verbatim into the sent email.\n */\nfunction activate(): void {\n if (canRepick.value) {\n void repick();\n return;\n }\n startEditing();\n}\n\nfunction finishEditing(): void {\n const newValue = editValue.value.trim();\n // Never commit something that isn't a merge tag: `renderHTML` writes the\n // value straight into `data-merge-tag`, and the renderer drops that into the\n // MJML unchanged, so a typo would ship as literal text in the email.\n if (\n newValue &&\n newValue !== props.node.attrs.value &&\n isMergeTagValue(newValue)\n ) {\n props.updateAttributes({\n // The honest resolution, not the display chain: this is written into the\n // document as `data-label`, so a placeholder would be persisted as if it\n // were the tag's name.\n value: newValue,\n label: getMergeTagLabel(newValue),\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n // Enter on an invalid value keeps the input open rather than discarding\n // what was typed — the border and `aria-invalid` already say why.\n if (!isEditValueValid.value) return;\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n class=\"tpl-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.9em] tpl:font-medium tpl:select-none tpl:text-[var(--tpl-primary)]\"\n style=\"\n background-color: color-mix(in srgb, var(--tpl-primary) 20%, transparent);\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n :aria-invalid=\"isEditValueValid ? undefined : 'true'\"\n class=\"tpl:w-32 tpl:rounded tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n :class=\"\n isEditValueValid\n ? 'tpl:border-none'\n : 'tpl:border tpl:border-[var(--tpl-danger)]'\n \"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"\n canRepick\n ? format(t.mergeTag.changeTag, { label: displayLabel })\n : t.mergeTag.editValue\n \"\n class=\"tpl:cursor-pointer\"\n :class=\"showRawValue ? 'tpl-tooltip' : ''\"\n :data-tooltip=\"showRawValue ? node.attrs.value : undefined\"\n @click.stop=\"activate\"\n @keydown.enter.stop=\"activate\"\n @keydown.space.prevent.stop=\"activate\"\n >\n {{ displayLabel }}\n </span>\n <button\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","<script setup lang=\"ts\">\nimport { useI18n } from \"../composables/useI18n\";\nimport { useMergeTag } from \"../composables/useMergeTag\";\nimport { NodeViewWrapper } from \"@tiptap/vue-3\";\nimport { computed, nextTick, onScopeDispose, ref } from \"vue\";\n\nconst props = defineProps<{\n node: {\n attrs: {\n label: string;\n value: string;\n };\n };\n deleteNode: () => void;\n updateAttributes: (attrs: Record<string, unknown>) => void;\n}>();\n\nconst {\n getMergeTagLabel,\n getMergeTagDisplayLabel,\n findMergeTag,\n canRepickMergeTag,\n showRawValue,\n isMergeTagValue,\n requestMergeTag,\n} = useMergeTag();\nconst { t, format } = useI18n();\n\n// `node.attrs.label` is the label captured when the tag was inserted. It is\n// only ever a fallback — the configured tags win, which is what keeps a\n// relabelled tag from rendering its stale stored copy.\nconst displayLabel = computed(() =>\n getMergeTagDisplayLabel(props.node.attrs.value, props.node.attrs.label),\n);\nconst canRepick = computed(() => canRepickMergeTag(props.node.attrs.value));\n\nconst isEditing = ref(false);\nconst editValue = ref(\"\");\nconst inputRef = ref<HTMLInputElement | null>(null);\n\n// The chooser mounts in the popover root, outside this node view, so the node\n// can be torn down while it is open — a collaborator edit, a block change, the\n// editor unmounting. Writing attributes onto a destroyed node view throws.\nlet disposed = false;\nonScopeDispose(() => {\n disposed = true;\n});\n\n/** Whether the text currently in the raw input is a usable merge tag. */\nconst isEditValueValid = computed(\n () =>\n editValue.value.trim() === \"\" || isMergeTagValue(editValue.value.trim()),\n);\n\n/**\n * Swap this tag for another one, chosen through the same chooser insertion\n * uses. `requestMergeTag` sets the editor-wide requesting flag for the whole\n * await, which is what stops `useRichTextEditor`'s click-outside handler\n * finishing the block when the user clicks a row in the chooser — that would\n * dispose this node view and silently drop the update.\n */\nasync function repick(): Promise<void> {\n const replacement = await requestMergeTag({\n reason: \"edit\",\n current: findMergeTag(props.node.attrs.value),\n });\n if (disposed || !replacement) return;\n props.updateAttributes({\n value: replacement.value,\n label: replacement.label,\n });\n}\n\nfunction startEditing(): void {\n editValue.value = props.node.attrs.value;\n isEditing.value = true;\n nextTick(() => {\n inputRef.value?.focus();\n inputRef.value?.select();\n });\n}\n\n/**\n * Activating the chip opens the chooser when one can resolve this token, and\n * the raw input only when none can. Editing a token as free text is how a\n * chip ends up holding something that is not a merge tag at all, which the\n * renderer then emits verbatim into the sent email.\n */\nfunction activate(): void {\n if (canRepick.value) {\n void repick();\n return;\n }\n startEditing();\n}\n\nfunction finishEditing(): void {\n const newValue = editValue.value.trim();\n // Never commit something that isn't a merge tag: `renderHTML` writes the\n // value straight into `data-merge-tag`, and the renderer drops that into the\n // MJML unchanged, so a typo would ship as literal text in the email.\n if (\n newValue &&\n newValue !== props.node.attrs.value &&\n isMergeTagValue(newValue)\n ) {\n props.updateAttributes({\n // The honest resolution, not the display chain: this is written into the\n // document as `data-label`, so a placeholder would be persisted as if it\n // were the tag's name.\n value: newValue,\n label: getMergeTagLabel(newValue),\n });\n }\n isEditing.value = false;\n}\n\nfunction handleKeydown(event: KeyboardEvent): void {\n if (event.key === \"Enter\") {\n event.preventDefault();\n // Enter on an invalid value keeps the input open rather than discarding\n // what was typed — the border and `aria-invalid` already say why.\n if (!isEditValueValid.value) return;\n finishEditing();\n } else if (event.key === \"Escape\") {\n isEditing.value = false;\n }\n}\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"span\"\n class=\"tpl-merge-tag-node tpl:group tpl:mx-0.5 tpl:inline-flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.9em] tpl:font-medium tpl:select-none tpl:text-[var(--tpl-primary)]\"\n style=\"\n background-color: color-mix(in srgb, var(--tpl-primary) 20%, transparent);\n \"\n contenteditable=\"false\"\n >\n <!-- Edit mode -->\n <input\n v-if=\"isEditing\"\n ref=\"inputRef\"\n v-model=\"editValue\"\n type=\"text\"\n :aria-invalid=\"isEditValueValid ? undefined : 'true'\"\n class=\"tpl:w-32 tpl:rounded tpl:bg-transparent tpl:px-0.5 tpl:py-0 tpl:text-[1em] tpl:font-medium tpl:outline-none tpl:text-[var(--tpl-primary)]\"\n :class=\"\n isEditValueValid\n ? 'tpl:border-none'\n : 'tpl:border tpl:border-[var(--tpl-danger)]'\n \"\n @blur=\"finishEditing\"\n @keydown=\"handleKeydown\"\n />\n <!-- Display mode -->\n <span\n v-else\n role=\"button\"\n tabindex=\"0\"\n :aria-label=\"\n canRepick\n ? format(t.mergeTag.changeTag, { label: displayLabel })\n : t.mergeTag.editValue\n \"\n class=\"tpl:cursor-pointer\"\n :class=\"showRawValue ? 'tpl-tooltip' : ''\"\n :data-tooltip=\"showRawValue ? node.attrs.value : undefined\"\n @click.stop=\"activate\"\n @keydown.enter.stop=\"activate\"\n @keydown.space.prevent.stop=\"activate\"\n >\n {{ displayLabel }}\n </span>\n <button\n type=\"button\"\n :aria-label=\"t.mergeTag.deleteMergeTag\"\n class=\"tpl-merge-tag-delete tpl:flex tpl:size-5 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:opacity-60 tpl:transition-all tpl:hover:opacity-100 tpl:text-[var(--tpl-primary)]\"\n contenteditable=\"false\"\n @click.stop.prevent=\"deleteNode\"\n >\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n aria-hidden=\"true\"\n >\n <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\" />\n <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\" />\n </svg>\n </button>\n </NodeViewWrapper>\n</template>\n","import MergeTagNodeView from \"./MergeTagNodeView.vue\";\nimport type { MergeTag, SyntaxPreset } from \"@templatical/types\";\nimport { getMergeTagLabel, SYNTAX_PRESETS } from \"@templatical/types\";\nimport { InputRule, mergeAttributes, Node, PasteRule } from \"@tiptap/core\";\nimport { isNodeSelected } from \"./isNodeSelected\";\nimport { renderVueNodeView } from \"./renderVueNodeView\";\n\nexport interface MergeTagNodeOptions {\n /**\n * Read live, not captured. `renderHTML` and the input/paste rules resolve a\n * label every time they run, and `editor.setMergeTags` can replace the list\n * while a block is open for editing.\n */\n mergeTags: () => MergeTag[];\n syntax: SyntaxPreset;\n}\n\n/**\n * Inserted-node attrs are intentionally limited to `label` + `value`. The\n * `MergeTag` interface also carries optional `group` / `description` for\n * the built-in picker, but those are display-only and must NOT leak into\n * the document JSON — they would bloat templates and pollute serialized\n * state. `Pick<>` makes the constraint explicit at the type level.\n */\nexport type InsertMergeTagAttrs = Pick<MergeTag, \"label\" | \"value\">;\n\ndeclare module \"@tiptap/core\" {\n interface Commands<ReturnType> {\n mergeTagNode: {\n insertMergeTag: (attrs: InsertMergeTagAttrs) => ReturnType;\n };\n }\n}\n\nexport const MergeTagNode = Node.create<MergeTagNodeOptions>({\n name: \"mergeTagNode\",\n\n group: \"inline\",\n\n inline: true,\n\n atom: true,\n\n addOptions() {\n return {\n mergeTags: () => [],\n syntax: SYNTAX_PRESETS.liquid,\n };\n },\n\n addAttributes() {\n return {\n // Both attributes are state, not markup: `renderHTML()` below emits the\n // canonical `data-merge-tag` / `data-label` pair and `parseHTML` reads\n // only those. `rendered: false` keeps TipTap from also serializing each\n // attribute under its own name, which would put a write-only duplicate\n // of the same data on every tag — invalid on a `<span>`, and paid again\n // through storage, autosave, snapshots and version history.\n label: {\n default: \"\",\n rendered: false,\n parseHTML: (element) =>\n element.getAttribute(\"data-label\") || element.textContent || \"\",\n },\n value: {\n default: \"\",\n rendered: false,\n parseHTML: (element) => element.getAttribute(\"data-merge-tag\") || \"\",\n },\n };\n },\n\n parseHTML() {\n return [\n {\n tag: \"span[data-merge-tag]\",\n },\n ];\n },\n\n renderHTML({ node, HTMLAttributes }) {\n const label = getMergeTagLabel(node.attrs.value, this.options.mergeTags());\n\n return [\n \"span\",\n mergeAttributes(HTMLAttributes, {\n \"data-merge-tag\": node.attrs.value,\n \"data-label\": label,\n }),\n label,\n ];\n },\n\n addNodeView() {\n return renderVueNodeView(MergeTagNodeView);\n },\n\n addCommands() {\n return {\n insertMergeTag:\n (attrs: InsertMergeTagAttrs) =>\n ({ commands }) => {\n // Whitelist explicitly — even if a caller smuggles extra keys via\n // a wider type assertion, only label/value reach the node attrs.\n return commands.insertContent({\n type: this.name,\n attrs: { label: attrs.label, value: attrs.value },\n });\n },\n };\n },\n\n addKeyboardShortcuts() {\n return {\n Backspace: () => isNodeSelected(this.editor, this.name),\n Delete: () => isNodeSelected(this.editor, this.name),\n };\n },\n\n addInputRules() {\n const inputRegex = new RegExp(this.options.syntax.value.source + \"$\", \"\");\n\n return [\n new InputRule({\n find: inputRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n const label = getMergeTagLabel(fullValue, this.options.mergeTags());\n\n const node = this.type.create({\n label,\n value: fullValue,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n\n addPasteRules() {\n const pasteRegex = new RegExp(this.options.syntax.value.source, \"g\");\n\n return [\n new PasteRule({\n find: pasteRegex,\n handler: ({ state, range, match }) => {\n const fullValue = match[0];\n const label = getMergeTagLabel(fullValue, this.options.mergeTags());\n\n const node = this.type.create({\n label,\n value: fullValue,\n });\n\n state.tr.replaceWith(range.from, range.to, node);\n },\n }),\n ];\n },\n});\n","import type { MergeTag } from \"@templatical/types\";\nimport { Extension } from \"@tiptap/core\";\nimport Suggestion, {\n type SuggestionOptions,\n type SuggestionProps,\n type SuggestionKeyDownProps,\n} from \"@tiptap/suggestion\";\nimport type { Ref } from \"vue\";\nimport { createMergeTagPopup, filterMergeTags } from \"../utils/mergeTagPopup\";\n\nexport interface MergeTagSuggestionOptions {\n /** Available merge tags */\n /**\n * Read live, not captured: the list can be replaced while a block is being\n * edited (`editor.setMergeTags`), and a snapshot taken when the extension\n * was configured would keep suggesting the old tags.\n */\n mergeTags: () => MergeTag[];\n /** Trigger string (e.g. \"{{\", \"*|\", \"%%=\") */\n char: string;\n /** Localized empty-state label */\n emptyText: string;\n /**\n * Mount target for the suggestion popup. When provided with a non-null\n * `.value`, the popup attaches into that element instead of\n * `document.body` — keeping it inside the editor's effective DOM root\n * (shadow-aware). Pass the ref returned by `usePopoverRoot()`.\n *\n * Falls back to `document.body` when omitted or when the ref's value is\n * null at popup-open time (e.g. headless/test editors without an editor\n * shell). Preserves pre-Phase-3 behavior for callers that don't migrate.\n */\n popoverRoot?: Ref<HTMLElement | null> | null;\n}\n\n/**\n * Builds the `@tiptap/suggestion` `render` factory for the merge-tag popup.\n * A thin adapter over {@link createMergeTagPopup}: it maps ProseMirror's\n * `SuggestionProps` (items, `clientRect`, `view.dom`, `command`) onto the\n * controller. Exported as a standalone function so that mapping can be\n * unit-tested with mocked `SuggestionProps` instead of a full editor.\n */\nexport function createMergeTagSuggestionRenderer(\n emptyText: string,\n popoverRootRef?: Ref<HTMLElement | null> | null,\n): NonNullable<SuggestionOptions<MergeTag>[\"render\"]> {\n return () => {\n const popup = createMergeTagPopup(emptyText, popoverRootRef);\n\n return {\n onStart: (props: SuggestionProps<MergeTag>) => {\n // Use view.dom (ProseMirror contenteditable, actually\n // attached to the DOM) rather than options.element, which may\n // be a detached div when no `element` is passed to the editor\n // constructor (as is the case with @tiptap/vue-3 EditorContent).\n const viewDom = props.editor.view?.dom as HTMLElement | undefined;\n popup.open({\n items: props.items,\n getRect: props.clientRect ?? null,\n anchorEl: viewDom ?? null,\n onCommand: (item) => props.command(item),\n });\n },\n onUpdate: (props: SuggestionProps<MergeTag>) => {\n popup.update({\n items: props.items,\n getRect: props.clientRect ?? null,\n onCommand: (item) => props.command(item),\n });\n },\n onKeyDown: (props: SuggestionKeyDownProps): boolean => {\n // Escape closes via TipTap's suggestion plugin (→ onExit); report it\n // handled without selecting.\n if (props.event.key === \"Escape\") {\n return true;\n }\n return popup.handleKeyDown(props.event);\n },\n onExit: () => popup.close(),\n };\n };\n}\n\nexport const MergeTagSuggestion = Extension.create<MergeTagSuggestionOptions>({\n name: \"mergeTagSuggestion\",\n\n addOptions() {\n return {\n mergeTags: () => [],\n char: \"{{\",\n emptyText: \"No matching merge tags\",\n popoverRoot: null,\n };\n },\n\n addProseMirrorPlugins() {\n const tags = this.options.mergeTags();\n const emptyText = this.options.emptyText;\n const popoverRootRef = this.options.popoverRoot;\n\n const config: Omit<SuggestionOptions<MergeTag>, \"editor\"> = {\n char: this.options.char,\n allowSpaces: false,\n startOfLine: false,\n // Default is [\" \"] which requires whitespace/line-start before the\n // trigger char — so `.{{` would not fire. Allow any preceding char.\n allowedPrefixes: null,\n items: ({ query }: { query: string }) => filterMergeTags(tags, query),\n command: ({\n editor,\n range,\n props,\n }: {\n editor: SuggestionProps<MergeTag>[\"editor\"];\n range: { from: number; to: number };\n props: MergeTag;\n }) => {\n // Use insertContentAt for atomic replace (matches the canonical\n // @tiptap/suggestion + Mention pattern). Avoids edge cases where\n // chained deleteRange + insertMergeTag fails to insert when the\n // selection state shifts mid-chain.\n editor\n .chain()\n .focus()\n .insertContentAt(range, {\n type: \"mergeTagNode\",\n attrs: { label: props.label, value: props.value },\n })\n .run();\n },\n render: createMergeTagSuggestionRenderer(emptyText, popoverRootRef),\n };\n\n return [\n Suggestion({\n editor: this.editor,\n ...config,\n }),\n ];\n },\n});\n"],"mappings":";;;;;;;AAeA,IAAa,IAAW,EAAU,OAAwB;CACxD,MAAM;CAEN,aAAa;EACX,OAAO,EACL,OAAO,CAAC,WAAW,EACrB;CACF;CAEA,sBAAsB;EACpB,OAAO,CACL;GACE,OAAO,KAAK,QAAQ;GACpB,YAAY,EACV,UAAU;IACR,SAAS;IACT,YAAY,MACV,EAAQ,MAAM,UAAU,QAAQ,UAAU,EAAE,KAAK;IACnD,aAAa,MACN,EAAW,WAGT,EACL,OAAO,cAAc,EAAW,WAClC,IAJS,CAAC;GAMd,EACF;EACF,CACF;CACF;CAEA,cAAc;EACZ,OAAO;GACL,cACG,OACA,EAAE,eACM,EAAM,CAAC,CAAC,QAAQ,aAAa,EAAE,UAAU,EAAK,CAAC,CAAC,CAAC,IAAI;GAEhE,sBAEG,EAAE,eACM,EAAM,CAAC,CACX,QAAQ,aAAa,EAAE,UAAU,KAAK,CAAC,CAAC,CACxC,qBAAqB,CAAC,CACtB,IAAI;EAEb;CACF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,EAAM;KACb,SAAS,EAAM,cAAc;KAC7B,UAJc,EAAM,OAAO,MAAM,OAIZ;KACrB,YAAY,MAAS,EAAM,QAAQ,CAAI;IACzC,CAAC;GACH;GACA,WAAW,MAAqC;IAC9C,EAAM,OAAO;KACX,OAAO,EAAM;KACb,SAAS,EAAM,cAAc;KAC7B,YAAY,MAAS,EAAM,QAAQ,CAAI;IACzC,CAAC;GACH;GACA,YAAY,MAGN,EAAM,MAAM,QAAQ,YAGjB,EAAM,cAAc,EAAM,KAAK;GAExC,cAAc,EAAM,MAAM;EAC5B;CACF;AACF;AAEA,IAAa,IAAqB,EAAU,OAAkC;CAC5E,MAAM;CAEN,aAAa;EACX,OAAO;GACL,iBAAiB,CAAC;GAClB,MAAM;GACN,WAAW;GACX,aAAa;EACf;CACF;CAEA,wBAAwB;EACtB,IAAM,IAAO,KAAK,QAAQ,UAAU,GAC9B,IAAY,KAAK,QAAQ,WACzB,IAAiB,KAAK,QAAQ,aAE9B,IAAsD;GAC1D,MAAM,KAAK,QAAQ;GACnB,aAAa;GACb,aAAa;GAGb,iBAAiB;GACjB,QAAQ,EAAE,eAA+B,EAAgB,GAAM,CAAK;GACpE,UAAU,EACR,WACA,UACA,eAKI;IAKJ,EACG,MAAM,CAAC,CACP,MAAM,CAAC,CACP,gBAAgB,GAAO;KACtB,MAAM;KACN,OAAO;MAAE,OAAO,EAAM;MAAO,OAAO,EAAM;KAAM;IAClD,CAAC,CAAC,CACD,IAAI;GACT;GACA,QAAQ,EAAiC,GAAW,CAAc;EACpE;EAEA,OAAO,CACL,EAAW;GACT,QAAQ,KAAK;GACb,GAAG;EACL,CAAC,CACH;CACF;AACF,CAAC"}
@@ -131,6 +131,7 @@ var e = {
131
131
  ratio21: "Ratio 2:1",
132
132
  borderRadius: "Rayon de bordure",
133
133
  wrapperEnable: "Ajouter un conteneur",
134
+ wrapperLayoutConflict: "Cet éditeur encadre déjà l'e-mail. Un cadre supplémentaire sur cette section n'est pas pris en charge — l'aperçu et l'export échoueront.",
134
135
  stackOnMobile: "Empiler sur mobile"
135
136
  },
136
137
  linkDialog: {
@@ -621,4 +622,4 @@ var e = {
621
622
  //#endregion
622
623
  export { e as default };
623
624
 
624
- //# sourceMappingURL=fr-2yDa4zXM.js.map
625
+ //# sourceMappingURL=fr-wrXhIi00.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fr-wrXhIi00.js","names":[],"sources":["../../../src/i18n/locales/fr.ts"],"sourcesContent":["import type en from \"./en\";\n\nconst fr: typeof en = {\n footer: {\n poweredBy: \"Propulsé par\",\n openSource: \"Open Source\",\n },\n\n header: {\n save: \"Enregistrer\",\n saving: \"Enregistrement...\",\n saved: \"Enregistré\",\n unsaved: \"Non enregistré\",\n saveFailed: \"Échec de l'enregistrement\",\n saveNoTemplate: \"Chargez ou créez d'abord un modèle\",\n templateName: \"Nom du modèle\",\n rename: \"Renommer le modèle\",\n untitled: \"Sans titre\",\n updatedAt: \"Modifié {time}\",\n createdAt: \"Créé {time}\",\n updatedJustNow: \"Modifié à l'instant\",\n createdJustNow: \"Créé à l'instant\",\n },\n\n // Relative timestamps, shared by every surface that shows one: the header's\n // updated line, saved blocks, comments and version history.\n time: {\n justNow: \"À l'instant\",\n minutesAgo: \"il y a {minutes} min\",\n hoursAgo: \"il y a {hours} h\",\n daysAgo: \"il y a {days} j\",\n },\n\n // Toolbar - Paragraph\n paragraph: {\n paragraphSpacing: \"Espacement des paragraphes\",\n },\n\n history: {\n collabWarning:\n \"Annuler peut affecter les modifications récentes de vos collaborateurs\",\n undo: \"Annuler\",\n redo: \"Rétablir\",\n },\n viewport: {\n label: \"Affichage\",\n desktop: \"Ordinateur\",\n mobile: \"Mobile\",\n },\n darkMode: {\n enable: \"Aperçu en mode sombre\",\n disable: \"Aperçu en mode clair\",\n },\n previewMode: {\n enable: \"Mode aperçu\",\n disable: \"Quitter l'aperçu\",\n },\n blocks: {\n section: \"Section\",\n image: \"Image\",\n title: \"Titre\",\n paragraph: \"Paragraphe\",\n button: \"Bouton\",\n divider: \"Séparateur\",\n video: \"Vidéo\",\n social: \"Réseaux sociaux\",\n spacer: \"Espaceur\",\n html: \"HTML\",\n menu: \"Menu\",\n table: \"Tableau\",\n countdown: \"Compte à rebours\",\n },\n\n // Placeholder text a newly inserted block starts with. Author-facing\n // prompts, meant to be overwritten — so they follow the editor UI locale.\n // Recipient-facing defaults live in `i18n/contentDefaults.ts` and follow\n // the template's own `settings.locale` instead.\n blockDefaults: {\n title: \"Saisissez votre titre\",\n paragraph: \"Saisissez votre texte ici\",\n button: \"Cliquez ici\",\n },\n sidebar: {\n content: \"Contenu\",\n settings: \"Paramètres\",\n noSelection: \"Aucun élément sélectionné\",\n noSelectionHint: \"Sélectionnez un bloc sur le canevas pour le modifier\",\n },\n toolbar: {\n duplicate: \"Dupliquer\",\n delete: \"Supprimer\",\n },\n titleEditor: {\n toolbar: \"Mise en forme du titre\",\n bold: \"Gras (Ctrl+B)\",\n italic: \"Italique (Ctrl+I)\",\n addLink: \"Ajouter un lien\",\n },\n paragraphEditor: {\n toolbar: \"Mise en forme du texte\",\n bold: \"Gras (Ctrl+B)\",\n italic: \"Italique (Ctrl+I)\",\n underline: \"Souligné (Ctrl+U)\",\n strikethrough: \"Barré\",\n subscript: \"Indice\",\n superscript: \"Exposant\",\n addLink: \"Ajouter un lien\",\n bulletList: \"Liste à puces\",\n numberedList: \"Liste numérotée\",\n alignLeft: \"Aligner à gauche\",\n alignCenter: \"Centrer\",\n alignRight: \"Aligner à droite\",\n alignJustify: \"Justifier\",\n clearFormatting: \"Effacer la mise en forme\",\n insertEmoji: \"Insérer un émoji\",\n fontFamily: \"Police\",\n defaultFont: \"Par défaut\",\n fontSize: \"Taille de police\",\n defaultSize: \"Par défaut\",\n textColor: \"Couleur du texte\",\n highlightColor: \"Couleur de surlignage\",\n lineHeight: \"Interligne\",\n letterSpacing: \"Espacement des lettres\",\n emojiItemLabel: \"Insérer l'émoji {emoji}\",\n },\n blockActions: {\n drag: \"Faites glisser pour réorganiser, ou appuyez sur Espace pour déplacer au clavier\",\n dragLifted:\n \"Déplacement de {block}. Utilisez les flèches haut et bas pour repositionner, Espace ou Entrée pour déposer, Échap pour annuler.\",\n duplicate: \"Dupliquer le bloc\",\n delete: \"Supprimer le bloc\",\n hiddenOnViewport: \"Masqué sur {viewport}\",\n saveAsBlock: \"Enregistrer comme bloc\",\n conditionToggle: \"Basculer la condition d'affichage\",\n comments: \"Commentaires ({count})\",\n lifted: \"{block} saisi. Position {position} sur {total}.\",\n moved: \"{block} déplacé en position {position} sur {total}.\",\n dropped: \"{block} déposé en position {position} sur {total}.\",\n cancelled: \"Déplacement annulé. {block} est revenu en position {position}.\",\n },\n section: {\n dropHere: \"Déposez des blocs ici\",\n columns: \"Colonnes\",\n column1: \"1 colonne\",\n column2: \"2 colonnes\",\n column3: \"3 colonnes\",\n ratio12: \"Ratio 1:2\",\n ratio21: \"Ratio 2:1\",\n borderRadius: \"Rayon de bordure\",\n wrapperEnable: \"Ajouter un conteneur\",\n wrapperLayoutConflict:\n \"Cet éditeur encadre déjà l'e-mail. Un cadre supplémentaire sur cette section n'est pas pris en charge — l'aperçu et l'export échoueront.\",\n stackOnMobile: \"Empiler sur mobile\",\n },\n linkDialog: {\n editLink: \"Modifier le lien\",\n insertLink: \"Insérer un lien\",\n updateLink: \"Mettre à jour le lien\",\n removeLink: \"Supprimer le lien\",\n cancel: \"Annuler\",\n urlPlaceholder: \"https://example.com\",\n urlLabel: \"URL\",\n colorLabel: \"Couleur du lien\",\n },\n title: {\n level: \"Niveau de titre\",\n heading1: \"Titre 1 (36px)\",\n heading2: \"Titre 2 (28px)\",\n heading3: \"Titre 3 (22px)\",\n heading4: \"Titre 4 (18px)\",\n fontFamily: \"Police\",\n inheritFont: \"Utiliser la police du modèle\",\n color: \"Couleur\",\n align: \"Aligner\",\n alignLeft: \"Gauche\",\n alignCenter: \"Centre\",\n alignRight: \"Droite\",\n },\n emoji: {\n smileys: \"Smileys\",\n gestures: \"Gestes\",\n objects: \"Objets\",\n },\n image: {\n imageUrl: \"URL de l'image\",\n imageUrlPlaceholder: \"https://...\",\n altText: \"Texte alternatif\",\n altTextPlaceholder: \"Description de l'image\",\n width: \"Largeur\",\n fullWidth: \"Pleine largeur\",\n widthCustom: \"Personnalisée\",\n height: \"Hauteur\",\n heightAuto: \"Automatique\",\n heightCustom: \"Personnalisée\",\n borderRadius: \"Rayon de bordure\",\n linkUrl: \"URL du lien\",\n openInNewTab: \"Ouvrir dans un nouvel onglet\",\n placeholderUrl: \"Image de substitution\",\n optional: \"(facultatif)\",\n placeholderUrlPlaceholder: \"https://... (conception uniquement)\",\n placeholderUrlTooltip:\n \"L'URL de l'image utilisant une balise de fusion, vous pouvez fournir ici une vraie image pour prévisualiser la mise en page pendant la conception. Elle n'est pas incluse dans le résultat final.\",\n clickToAdd: \"Cliquez pour ajouter l'URL de l'image\",\n browseMedia: \"Parcourir la médiathèque\",\n dropToUpload: \"Déposez une image pour la téléverser\",\n uploading: \"Téléversement…\",\n decorative: \"Image décorative\",\n decorativeHint:\n \"Masquée pour les lecteurs d'écran. À réserver aux espaceurs et ornements visuels.\",\n },\n video: {\n videoUrl: \"URL de la vidéo\",\n videoUrlPlaceholder: \"https://youtube.com/...\",\n openInNewTab: \"Ouvrir dans un nouvel onglet\",\n customThumbnail: \"Miniature personnalisée\",\n optional: \"(facultatif)\",\n thumbnailPlaceholder: \"Générée automatiquement depuis l'URL de la vidéo\",\n altText: \"Texte alternatif\",\n altTextPlaceholder: \"Description de la vidéo\",\n width: \"Largeur\",\n fullWidth: \"Pleine largeur\",\n height: \"Hauteur\",\n heightAuto: \"Automatique\",\n heightCustom: \"Personnalisée\",\n placeholderUrl: \"Miniature de substitution\",\n placeholderUrlPlaceholder: \"https://... (conception uniquement)\",\n placeholderUrlTooltip:\n \"L'URL de la vidéo utilisant une balise de fusion, vous pouvez fournir ici une vraie miniature pour prévisualiser la mise en page pendant la conception. Elle n'est pas incluse dans le résultat final.\",\n addVideo: \"Ajoutez une URL de vidéo\",\n },\n button: {\n fontFamily: \"Police\",\n inheritFont: \"Utiliser la police du modèle\",\n text: \"Texte\",\n url: \"URL\",\n urlPlaceholder: \"https://...\",\n openInNewTab: \"Ouvrir dans un nouvel onglet\",\n background: \"Fond\",\n textColor: \"Couleur du texte\",\n borderRadius: \"Rayon de bordure\",\n fontSize: \"Taille de police\",\n width: \"Largeur\",\n widthAuto: \"Ajuster au contenu\",\n fullWidth: \"Pleine largeur\",\n widthCustom: \"Personnalisée\",\n },\n divider: {\n style: \"Style\",\n solid: \"Continu\",\n dashed: \"Tirets\",\n dotted: \"Pointillés\",\n color: \"Couleur\",\n thickness: \"Épaisseur\",\n },\n social: {\n icons: \"Icônes\",\n addIcon: \"Ajouter une icône\",\n addIcons: \"Ajoutez des icônes de réseaux sociaux\",\n removeIcon: \"Supprimer\",\n urlPlaceholder: \"https://...\",\n style: \"Style\",\n styleSolid: \"Plein\",\n styleOutlined: \"Contour\",\n styleRounded: \"Arrondi\",\n styleSquare: \"Carré\",\n styleCircle: \"Cercle\",\n size: \"Taille\",\n sizeSmall: \"S\",\n sizeMedium: \"M\",\n sizeLarge: \"L\",\n spacing: \"Espacement\",\n align: \"Alignement\",\n platforms: {\n facebook: \"Facebook\",\n twitter: \"X (Twitter)\",\n instagram: \"Instagram\",\n linkedin: \"LinkedIn\",\n youtube: \"YouTube\",\n tiktok: \"TikTok\",\n pinterest: \"Pinterest\",\n email: \"E-mail\",\n website: \"Site web\",\n whatsapp: \"WhatsApp\",\n telegram: \"Telegram\",\n discord: \"Discord\",\n snapchat: \"Snapchat\",\n reddit: \"Reddit\",\n github: \"GitHub\",\n dribbble: \"Dribbble\",\n behance: \"Behance\",\n },\n },\n menu: {\n items: \"Éléments du menu\",\n addItem: \"Ajouter un élément\",\n removeItem: \"Supprimer\",\n text: \"Texte\",\n urlPlaceholder: \"https://example.com\",\n openInNewTab: \"Ouvrir dans un nouvel onglet\",\n bold: \"Gras\",\n underline: \"Souligné\",\n color: \"Couleur\",\n linkColor: \"Couleur des liens\",\n fontSize: \"Taille de police\",\n fontFamily: \"Police\",\n separator: \"Séparateur\",\n separatorColor: \"Couleur du séparateur\",\n spacing: \"Espacement\",\n textAlign: \"Alignement\",\n addLinks: \"Ajoutez des liens de menu\",\n },\n table: {\n dimensions: \"Dimensions\",\n rows: \"Lignes\",\n columns: \"Colonnes\",\n hasHeaderRow: \"Ligne d'en-tête\",\n headerBackgroundColor: \"Fond de l'en-tête\",\n noHeaderBg: \"Sans fond\",\n borderColor: \"Couleur de bordure\",\n borderWidth: \"Épaisseur de bordure\",\n cellPadding: \"Marge intérieure des cellules\",\n fontFamily: \"Police\",\n fontSize: \"Taille de police\",\n color: \"Couleur du texte\",\n textAlign: \"Alignement\",\n cellPlaceholder: \"Saisissez du texte...\",\n empty: \"Ajoutez un tableau\",\n },\n spacer: {\n height: \"Hauteur\",\n },\n countdown: {\n targetDate: \"Date cible\",\n timezone: \"Fuseau horaire\",\n display: \"Affichage\",\n days: \"Jours\",\n hours: \"Heures\",\n minutes: \"Minutes\",\n seconds: \"Secondes\",\n separator: \"Séparateur\",\n fontFamily: \"Police\",\n inheritFont: \"Par défaut\",\n digitFontSize: \"Taille des chiffres\",\n digitColor: \"Couleur des chiffres\",\n labelColor: \"Couleur des libellés\",\n labelFontSize: \"Taille des libellés\",\n background: \"Fond\",\n labels: \"Libellés\",\n expiry: \"Message d'expiration\",\n expiredMessagePlaceholder: \"Cette offre a expiré\",\n expiredImageUrl: \"URL de l'image d'expiration\",\n hideOnExpiry: \"Masquer à l'expiration\",\n setDate: \"Définissez une date cible dans le panneau des paramètres\",\n hidden: \"Masqué (expiré)\",\n },\n customBlocks: {\n definitionNotFound: \"Type de bloc inconnu — ce bloc n'est pas enregistré\",\n renderError:\n \"Ce bloc n'a pas pu être rendu. Vérifiez les erreurs dans le modèle du bloc.\",\n fields: {\n required: \"Obligatoire\",\n addItem: \"Ajouter un élément\",\n removeItem: \"Supprimer\",\n maxItemsReached: \"Nombre maximal d'éléments atteint\",\n minItemsRequired: \"Minimum {count} éléments requis\",\n },\n toolbar: {\n noDefinition:\n \"Enregistrez ce type de bloc dans la configuration du SDK pour modifier ses propriétés\",\n },\n dataSource: {\n fetchButton: \"Charger le contenu\",\n changeButton: \"Changer\",\n fetching: \"Chargement...\",\n readOnlyTooltip: \"Cette valeur provient de votre source de données\",\n fetchError: \"Échec du chargement du contenu\",\n },\n },\n html: {\n content: \"Contenu HTML\",\n preview: \"Bloc HTML personnalisé\",\n empty: \"Ajoutez du contenu HTML dans le panneau\",\n sanitizationHint:\n \"Le HTML est exporté tel quel, sans assainissement — assurez-vous que le contenu est sûr.\",\n },\n blockSettings: {\n spacing: \"Espacement\",\n padding: \"Marge intérieure\",\n background: \"Fond\",\n color: \"Couleur\",\n display: \"Affichage\",\n showOnDesktop: \"Afficher sur ordinateur\",\n showOnMobile: \"Afficher sur mobile\",\n hiddenOnDevice: \"Masqué sur {device}\",\n displayCondition: \"Condition d'affichage\",\n selectCondition: \"Sélectionner une condition\",\n removeCondition: \"Supprimer la condition\",\n noCondition: \"Toujours visible\",\n conditionApplied: \"Condition appliquée\",\n customCondition: \"Condition personnalisée\",\n customConditionLabel: \"Nom de la condition\",\n customConditionBefore: \"Avant (logique d'ouverture)\",\n customConditionAfter: \"Après (logique de fermeture)\",\n applyCondition: \"Appliquer\",\n cancelCondition: \"Annuler\",\n customBadge: \"Personnalisée\",\n restoreHiddenBlocks: \"Afficher tous les blocs masqués\",\n },\n templateSettings: {\n layout: \"Mise en page\",\n widthPreset: \"Largeur prédéfinie\",\n customWidth: \"Largeur personnalisée\",\n appearance: \"Apparence\",\n backgroundColor: \"Couleur de fond\",\n textColor: \"Couleur du texte\",\n linkColor: \"Couleur des liens\",\n linkUnderline: \"Souligner les liens\",\n fontFamily: \"Police\",\n preheaderText: \"Texte d'aperçu (preheader)\",\n preheaderTextPlaceholder:\n \"Texte d'aperçu affiché après l'objet dans la boîte de réception...\",\n preheaderTextHint:\n \"Ce texte apparaît après l'objet dans les aperçus des clients de messagerie. Les balises de fusion sont prises en charge.\",\n language: \"Langue\",\n contentLocale: \"Langue du contenu\",\n contentLocaleHint:\n \"Code BCP 47 (ex. fr, de, pt-BR). Définit l'attribut lang de l'e-mail rendu pour que les lecteurs d'écran prononcent correctement le contenu.\",\n contentDirection: \"De droite à gauche\",\n contentDirectionHint:\n \"Sens d'écriture de l'e-mail, indépendant de la langue de l'éditeur. S'il n'est pas défini, il suit la langue du contenu (arabe, hébreu, …).\",\n tips: \"Conseils\",\n tip1: \"600px est la largeur standard des modèles d'e-mail\",\n tip2: \"Utilisez des polices web sûres pour une compatibilité maximale\",\n tip3: \"Les fonds clairs offrent la meilleure lisibilité\",\n },\n spacingControl: {\n lockAll: \"Verrouiller tous les côtés\",\n unlock: \"Déverrouiller les côtés\",\n top: \"Haut\",\n right: \"Droite\",\n bottom: \"Bas\",\n left: \"Gauche\",\n decreaseTop: \"Réduire en haut\",\n increaseTop: \"Augmenter en haut\",\n decreaseLeft: \"Réduire à gauche\",\n increaseLeft: \"Augmenter à gauche\",\n decreaseRight: \"Réduire à droite\",\n increaseRight: \"Augmenter à droite\",\n decreaseBottom: \"Réduire en bas\",\n increaseBottom: \"Augmenter en bas\",\n },\n colorPicker: {\n pickColor: \"Choisir une couleur\",\n hexValue: \"Valeur hexadécimale de la couleur\",\n notSet: \"Non définie\",\n clear: \"Effacer la couleur\",\n presetColors: \"Couleurs prédéfinies\",\n },\n mergeTag: {\n editAsText: \"Modifier comme texte\",\n fieldGroup: \"Valeur avec balises de fusion\",\n remove: \"Supprimer la balise de fusion\",\n insert: \"Insérer une balise de fusion\",\n insertShort: \"Balise de fusion\",\n editValue: \"Modifier la valeur de la balise de fusion\",\n changeTag: \"Remplacer la balise de fusion : {label}\",\n unknownLabel: \"Balise de fusion\",\n deleteMergeTag: \"Supprimer la balise de fusion\",\n suggestionEmpty: \"Aucune balise de fusion correspondante\",\n picker: {\n title: \"Insérer une balise de fusion\",\n changeTitle: \"Remplacer la balise de fusion\",\n searchPlaceholder: \"Rechercher des balises de fusion\",\n searchAriaLabel: \"Rechercher des balises de fusion\",\n noResults: \"Aucune balise de fusion correspondante\",\n empty: \"Aucune balise de fusion configurée\",\n otherGroup: \"Autres\",\n close: \"Fermer\",\n groupCount: \"{count}\",\n sample: \"Aperçu : {sample}\",\n },\n },\n logicTag: {\n insert: \"Insérer une logique\",\n insertShort: \"Logique\",\n picker: {\n title: \"Insérer une logique\",\n searchPlaceholder: \"Rechercher des balises logiques\",\n searchAriaLabel: \"Rechercher des balises logiques\",\n noResults: \"Aucune balise logique correspondante\",\n empty: \"Aucune balise logique configurée\",\n otherGroup: \"Autres\",\n close: \"Fermer\",\n },\n },\n canvas: {\n noBlocks: \"Aucun bloc pour l'instant\",\n dragHint:\n \"Partez de zéro en faisant glisser des blocs depuis la barre latérale\",\n dropHere: \"Déposez ici\",\n aiHintChat: \"ou laissez\",\n aiHintChatSuffix:\n \"générer un modèle complet pour vous en quelques secondes\",\n aiHintDesign:\n \"Vous avez déjà un design ? Téléversez une capture d'écran, une image ou un PDF et\",\n aiHintDesignSuffix: \"le recréera instantanément\",\n },\n savedBlocks: {\n title: \"Blocs enregistrés\",\n saveAsBlock: \"Enregistrer comme bloc\",\n name: \"Nom\",\n namePlaceholder: \"p. ex. En-tête, Pied de page, CTA...\",\n save: \"Enregistrer le bloc\",\n saving: \"Enregistrement...\",\n cancel: \"Annuler\",\n empty: \"Aucun bloc enregistré pour l'instant\",\n emptyHint:\n \"Enregistrez des blocs depuis vos modèles pour les réutiliser plus tard.\",\n noResults: \"Aucun bloc enregistré ne correspond à votre recherche\",\n search: \"Rechercher des blocs enregistrés...\",\n loading: \"Chargement des blocs enregistrés…\",\n category: \"Catégorie\",\n categoryPlaceholder: \"p. ex. En-têtes, Promos... (facultatif)\",\n allCategories: \"Toutes les catégories\",\n filterByCategory: \"Filtrer par catégorie\",\n insert: \"Insérer\",\n rename: \"Renommer\",\n delete: \"Supprimer\",\n deleteConfirm: \"Supprimer ce bloc enregistré ?\",\n blockCount: \"{count} bloc(s)\",\n browse: \"Parcourir les blocs enregistrés\",\n selectToPreview: \"Sélectionnez un bloc enregistré pour l'afficher\",\n insertAtBeginning: \"Au début\",\n insertAfterBlock: \"Après {block}\",\n insertAtEnd: \"À la fin\",\n insertPosition: \"Position d'insertion\",\n close: \"Fermer\",\n pickToolbar: \"Sélection de blocs à enregistrer\",\n pickCount: \"{count} bloc(s) sélectionné(s)\",\n pickHint: \"Cliquez sur les blocs pour les ajouter ou les retirer\",\n savingCount: \"Enregistrement de {count} bloc(s) :\",\n reorderHint:\n \"Glissez pour réordonner — les blocs sont enregistrés dans cet ordre\",\n reorderHandle: \"Réordonner {block}, position {position} sur {total}\",\n reorderAnnouncement: \"{block} déplacé en position {position} sur {total}\",\n expand: \"Développer\",\n collapse: \"Réduire\",\n expandPreview: \"Développer l'aperçu de {block}\",\n collapsePreview: \"Réduire l'aperçu de {block}\",\n },\n comments: {\n button: \"Commentaires\",\n title: \"Commentaires\",\n close: \"Fermer\",\n placeholder: \"Écrire un commentaire...\",\n replyPlaceholder: \"Écrire une réponse...\",\n reply: \"Répondre\",\n resolve: \"Résoudre\",\n unresolve: \"Réouvrir\",\n delete: \"Supprimer\",\n edit: \"Modifier\",\n cancel: \"Annuler\",\n save: \"Enregistrer\",\n noComments: \"Aucun commentaire\",\n noCommentsHint:\n \"Démarrez une conversation en ajoutant un commentaire au modèle ou à un bloc précis.\",\n deleteConfirm: \"Supprimer ce commentaire ?\",\n filterAll: \"Tous\",\n filterUnresolved: \"Non résolus\",\n filterBlock: \"Ce bloc\",\n jumpToBlock: \"Bloc\",\n ownedByYou: \"Vous\",\n edited: \"modifié\",\n resolvedBy: \"Résolu par {name}\",\n replyOne: \"{count} réponse\",\n replyMany: \"{count} réponses\",\n missingBlock: \"Bloc introuvable\",\n saveTemplateFirst: \"Enregistrez le modèle avant de commenter ce bloc.\",\n },\n versionHistory: {\n tooltip: \"Historique des versions\",\n dropdownTitle: \"Historique des versions\",\n empty: \"Aucune version pour l’instant\",\n auto: \"auto\",\n olderVersion: \"Version précédente\",\n newerVersion: \"Version plus récente\",\n },\n versionPreview: {\n message: \"Vous consultez une version antérieure de ce modèle.\",\n cancel: \"Annuler\",\n restore: \"Restaurer cette version\",\n restoreConfirm: {\n title: \"Restaurer cette version ?\",\n unsavedWithSave:\n \"Vous avez des modifications non enregistrées. Enregistrez-les d’abord et elles resteront dans l’historique ; restaurez sans enregistrer et elles seront perdues.\",\n unsavedNoSave:\n \"Vous avez des modifications non enregistrées et aucun endroit où les enregistrer. Restaurer cette version les fera disparaître.\",\n saveAndRestore: \"Enregistrer, puis restaurer\",\n restoreAnyway: \"Restaurer quand même\",\n cancel: \"Annuler\",\n },\n },\n previewResolution: {\n resolving: \"Résolution de l’aperçu…\",\n failed:\n \"L’aperçu n’a pas pu être résolu — le modèle non résolu est affiché.\",\n hint: \"L’aperçu utilise des données résolues par votre backend.\",\n },\n mergeTagPreview: {\n label: \"Affichage des balises de fusion\",\n sample: \"Exemple\",\n labelView: \"Libellé\",\n },\n testEmail: {\n title: \"Envoyer un e-mail de test\",\n recipientLabel: \"Destinataire\",\n recipientPlaceholder: \"vous@exemple.fr\",\n invalidAddress: \"Saisissez une adresse e-mail valide.\",\n preview: \"Aperçu\",\n previewHint:\n \"Les balises de fusion sont affichées non résolues — votre backend les remplace.\",\n previewHintSample:\n \"Les balises de fusion affichent des valeurs d’exemple — votre backend insère les données réelles.\",\n recipientNotAllowed:\n \"Cette adresse ne figure pas dans la liste des destinataires autorisés.\",\n send: \"Envoyer\",\n sending: \"Envoi en cours...\",\n cancel: \"Annuler\",\n success: \"E-mail de test envoyé avec succès\",\n button: \"Test\",\n },\n sidebarNav: {\n browseSavedBlocks: \"Parcourir les blocs enregistrés\",\n palette: \"Palette de blocs\",\n insertBlock: \"Insérer un bloc {block}\",\n },\n landmarks: {\n canvas: \"Canevas de l'e-mail\",\n blockToolbar: \"Propriétés du bloc\",\n rightSidebar: \"Propriétés du bloc et paramètres du modèle\",\n reorderAnnouncements: \"Annonces de réorganisation des blocs\",\n },\n errors: {\n editorLoading: \"Chargement de l'éditeur...\",\n editorLoadFailed: \"Échec du chargement de l'éditeur.\",\n retry: \"Réessayer\",\n },\n issues: {\n panelTitle: \"Problèmes\",\n panelTabLabel: \"Problèmes\",\n groupErrors: \"Erreurs\",\n groupWarnings: \"Avertissements\",\n groupInfo: \"Infos\",\n jump: \"Aller au bloc\",\n fix: \"Corriger\",\n emptyState: \"Aucun problème — tout va bien.\",\n badgeError: \"Contient des erreurs\",\n badgeWarning: \"Contient des avertissements\",\n issueCountTooltip: \"{count} problème(s)\",\n },\n smallScreen: {\n title: \"Écran plus grand requis\",\n message:\n \"L'éditeur a besoin de plus d'espace que cet écran n'en offre. Ouvrez-le sur une tablette ou un ordinateur pour commencer à modifier.\",\n },\n};\n\nexport default fr;\n"],"mappings":";AAEA,IAAM,IAAgB;CACpB,QAAQ;EACN,WAAW;EACX,YAAY;CACd;CAEA,QAAQ;EACN,MAAM;EACN,QAAQ;EACR,OAAO;EACP,SAAS;EACT,YAAY;EACZ,gBAAgB;EAChB,cAAc;EACd,QAAQ;EACR,UAAU;EACV,WAAW;EACX,WAAW;EACX,gBAAgB;EAChB,gBAAgB;CAClB;CAIA,MAAM;EACJ,SAAS;EACT,YAAY;EACZ,UAAU;EACV,SAAS;CACX;CAGA,WAAW,EACT,kBAAkB,6BACpB;CAEA,SAAS;EACP,eACE;EACF,MAAM;EACN,MAAM;CACR;CACA,UAAU;EACR,OAAO;EACP,SAAS;EACT,QAAQ;CACV;CACA,UAAU;EACR,QAAQ;EACR,SAAS;CACX;CACA,aAAa;EACX,QAAQ;EACR,SAAS;CACX;CACA,QAAQ;EACN,SAAS;EACT,OAAO;EACP,OAAO;EACP,WAAW;EACX,QAAQ;EACR,SAAS;EACT,OAAO;EACP,QAAQ;EACR,QAAQ;EACR,MAAM;EACN,MAAM;EACN,OAAO;EACP,WAAW;CACb;CAMA,eAAe;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AmB;CACrB;CACA,aAAa;EACX,OAAO;EACP,SACE;CACJ;AACF"}
@@ -0,0 +1,12 @@
1
+ import { E as e, et as t } from "./draggable-IB4x6w2O.js";
2
+ //#region src/keys.ts
3
+ var n = Symbol("translations"), r = Symbol("editor"), i = Symbol("history"), a = Symbol("blockActions"), o = Symbol("conditionPreview"), s = Symbol("appliesConditionFilter"), c = Symbol("fontsManager"), l = Symbol("themeStyles"), u = Symbol("tplUiTheme"), d = Symbol("tplUiLocale"), f = Symbol("blockDefaults"), p = Symbol("blockRegistry"), m = Symbol("customBlockDefinitions"), h = Symbol("paletteBlocks"), g = Symbol("htmlBlockPreview"), _ = Symbol("layout"), v = Symbol("sectionWrapper"), y = Symbol("colors"), b = Symbol("templateSettingsFields"), x = Symbol("customBlockStylesheets"), S = Symbol("mergeTags"), C = t([]), w = Symbol("mergeTagSyntax"), T = Symbol("onRequestMergeTag"), E = Symbol("mergeTagAutocomplete"), D = Symbol("mergeTagShowRawValue"), ee = Symbol("mergeTagSampleMode"), O = Symbol("useMergeTagSamples"), k = Symbol("resolvePreview"), A = Symbol("previewResolution"), j = Symbol("mergeTagPicker"), M = Symbol("mergeTagRequesting"), N = Symbol("logicTagRequesting"), P = Symbol("logicTags"), F = Symbol("logicPairs"), I = Symbol("logicPicker"), L = Symbol("onRequestLogic"), R = Symbol("onRequestMedia"), z = Symbol("canDropMedia"), B = Symbol("imageUrlResolver"), V = Symbol("displayConditions"), H = Symbol("allowCustomConditions"), U = Symbol("capabilities"), W = Symbol("keyboardReorder"), G = Symbol("templateLint"), K = Symbol("editorRoot"), q = Symbol("popoverRoot"), J = Symbol("savedBlocks"), Y = Symbol("authManager"), X = Symbol("aiConfig"), Z = Symbol("scoring"), Q = Symbol("cloudTranslations");
4
+ function $(t, n) {
5
+ let r = e(t, null);
6
+ if (r == null) throw Error(`${n} requires a provider for ${t.description ?? "unknown key"}. Ensure it renders inside the editor, below Editor.vue.`);
7
+ return r;
8
+ }
9
+ //#endregion
10
+ export { $, j as A, q as B, _ as C, N as D, I as E, C as F, v as G, k as H, L as I, l as J, G as K, R as L, ee as M, D as N, S as O, w as P, O as Q, T as R, W as S, P as T, J as U, A as V, Z as W, d as X, n as Y, u as Z, K as _, a, g as b, z as c, y as d, o as f, r as g, V as h, Y as i, M as j, E as k, U as l, x as m, H as n, f as o, m as p, b as q, s as r, p as s, X as t, Q as u, c as v, F as w, B as x, i as y, h as z };
11
+
12
+ //# sourceMappingURL=keys-DCWeHkSF.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"keys-DCWeHkSF.js","names":[],"sources":["../../../src/keys.ts"],"sourcesContent":["import {\n inject,\n shallowRef,\n type InjectionKey,\n type ComputedRef,\n type Ref,\n type ShallowRef,\n} from \"vue\";\nimport type {\n UseHistoryReturn,\n UseBlockActionsReturn,\n UseConditionPreviewReturn,\n} from \"@templatical/core\";\nimport type {\n BlockDefaults,\n CustomBlockDefinition,\n DisplayCondition,\n LogicPair,\n LogicTag,\n MergeTag,\n MergeTagRequestContext,\n ResolvePreview,\n SyntaxPreset,\n TemplateContent,\n} from \"@templatical/types\";\nimport type { Translations, CloudTranslations } from \"./i18n\";\nimport type {\n AuthManager,\n UseAiConfigReturn,\n UseTemplateScoringReturn,\n} from \"@templatical/core/cloud\";\nimport type { UseSavedBlocksReturn } from \"@templatical/core\";\nimport type { BaseEditorReturn } from \"./composables/useEditorCore\";\nimport type { ImageUrlResolver } from \"./composables/useImageUrlResolver\";\nimport type { UseFontsReturn } from \"./composables/useFonts\";\nimport type { UseBlockRegistryReturn } from \"./composables/useBlockRegistry\";\nimport type { UseKeyboardReorderReturn } from \"./composables/useKeyboardReorder\";\nimport type { EditorCapabilities } from \"./types/editor-capabilities\";\nimport type { OnRequestMedia } from \"./index\";\n\n// ---------------------------------------------------------------------------\n// Shared keys (provided by useEditorCore, consumed by all components)\n// ---------------------------------------------------------------------------\n\nexport const TRANSLATIONS_KEY: InjectionKey<Translations> =\n Symbol(\"translations\");\n\nexport const EDITOR_KEY: InjectionKey<BaseEditorReturn> = Symbol(\"editor\");\n\nexport const HISTORY_KEY: InjectionKey<UseHistoryReturn> = Symbol(\"history\");\n\nexport const BLOCK_ACTIONS_KEY: InjectionKey<UseBlockActionsReturn> =\n Symbol(\"blockActions\");\n\nexport const CONDITION_PREVIEW_KEY: InjectionKey<UseConditionPreviewReturn> =\n Symbol(\"conditionPreview\");\n\n/**\n * Whether the hand-toggled display-condition filter applies on this surface —\n * provided per-surface, exactly like `USE_MERGE_TAG_SAMPLES_KEY`, and for the\n * same reason: the rule folds in both `previewMode` and whether a resolver owns\n * the preview, so a component that re-derived it from `CONDITION_PREVIEW_KEY`\n * plus the editor's `previewMode` could get one half wrong on its own.\n *\n * Absent means \"applies\" — a surface with no provider filters as it always has.\n */\nexport const APPLIES_CONDITION_FILTER_KEY: InjectionKey<ComputedRef<boolean>> =\n Symbol(\"appliesConditionFilter\");\n\nexport const FONTS_MANAGER_KEY: InjectionKey<UseFontsReturn> =\n Symbol(\"fontsManager\");\n\nexport const THEME_STYLES_KEY: InjectionKey<\n ComputedRef<Record<string, string>>\n> = Symbol(\"themeStyles\");\n\nexport const UI_THEME_KEY: InjectionKey<ComputedRef<string>> =\n Symbol(\"tplUiTheme\");\n\n/**\n * The editor's UI locale, exactly as the consumer passed it to\n * `init({ locale })` — unresolved, so it may be unsupported or malformed.\n *\n * For `Intl` formatting only. Translated *strings* come from\n * `TRANSLATIONS_KEY`, which is already resolved to a supported bundle; this is\n * for the labels `Intl` builds itself (dates), where the browser's own locale\n * would otherwise win and disagree with the surrounding chrome. Always format\n * through `formatAbsoluteDateTime`, which guards the malformed case.\n *\n * Not the template's `settings.locale` — that is the *email's* language and\n * belongs to content, not chrome.\n */\nexport const UI_LOCALE_KEY: InjectionKey<string | undefined> =\n Symbol(\"tplUiLocale\");\n\n// A ref, not a plain object: the recipient-facing half of these defaults\n// (video alt, countdown labels) tracks the template's own `settings.locale`,\n// which the author can change while the editor is open. Read it at insert\n// time — a value destructured at setup goes stale.\nexport const BLOCK_DEFAULTS_KEY: InjectionKey<ComputedRef<BlockDefaults>> =\n Symbol(\"blockDefaults\");\n\nexport const BLOCK_REGISTRY_KEY: InjectionKey<UseBlockRegistryReturn> =\n Symbol(\"blockRegistry\");\n\nexport const CUSTOM_BLOCK_DEFINITIONS_KEY: InjectionKey<\n CustomBlockDefinition[]\n> = Symbol(\"customBlockDefinitions\");\n\n/**\n * Consumer-supplied block-palette allowlist + order (`config.paletteBlocks`).\n * `undefined` means the default full palette. Consumed by `Sidebar.vue`.\n */\nexport const PALETTE_BLOCKS_KEY: InjectionKey<string[] | undefined> =\n Symbol(\"paletteBlocks\");\n\n/**\n * Whether HTML blocks render a live sandboxed-iframe preview in the canvas\n * (`config.htmlBlockPreview`), normalized to a boolean. `false` (the default)\n * keeps the static placeholder card. Consumed by `HtmlBlock.vue`.\n */\nexport const HTML_BLOCK_PREVIEW_KEY: InjectionKey<boolean> =\n Symbol(\"htmlBlockPreview\");\n\n/**\n * Embedder layout overlay (`config.layout`). Provided by `useEditorCore`.\n * `undefined` when the host configured none. Consumed by preview surfaces\n * and the section toolbar; never written into editor content.\n */\nexport const LAYOUT_KEY: InjectionKey<TemplateContent | undefined> =\n Symbol(\"layout\");\n\n/**\n * Whether the section toolbar offers Add wrapper (`config.sectionWrapper`).\n * Provided by `useEditorCore`. `undefined` when the host configured none,\n * which is on (`!== false`). Consumed by `SectionToolbar`. Own key — not\n * folded into `LAYOUT_KEY`.\n */\nexport const SECTION_WRAPPER_KEY: InjectionKey<boolean | undefined> =\n Symbol(\"sectionWrapper\");\n\n/**\n * Consumer-supplied color-picker palette (`config.colors`), normalized to\n * `{ presets, allowCustom, allowCustomIgnored }` by `resolveColorsConfig`.\n * Provided by `useEditorCore`, consumed by every `ColorPicker`. The inject\n * default (`DEFAULT_RESOLVED_COLORS` = `{ presets: [], allowCustom: true,\n * allowCustomIgnored: false }`) makes an unconfigured picker render exactly\n * as before.\n */\nexport const COLORS_KEY: InjectionKey<\n import(\"./utils/resolveColorsConfig\").ResolvedColors\n> = Symbol(\"colors\");\n\n/**\n * The template settings the panel may render (`config.templateSettings.fields`),\n * resolved to a set of `TemplateSettings` member names by\n * `resolveTemplateSettingsFields`. Provided by `useEditorCore`, consumed by\n * `TemplateSettings.vue` for its cards and by `RightSidebar.vue` for the\n * Settings tab.\n *\n * Consumers inject with `ALL_TEMPLATE_SETTINGS_FIELDS` as the default, never an\n * empty set: the key is absent for anyone who configured nothing, and this\n * config only ever narrows.\n */\nexport const TEMPLATE_SETTINGS_FIELDS_KEY: InjectionKey<\n ReadonlySet<import(\"./utils/templateSettingsFields\").TemplateSettingsField>\n> = Symbol(\"templateSettingsFields\");\n\nexport const CUSTOM_BLOCK_STYLESHEETS_KEY: InjectionKey<ComputedRef<string[]>> =\n Symbol(\"customBlockStylesheets\");\n\n/**\n * The configured merge tags, as a ref so `editor.setMergeTags()` repaints\n * everything that renders one. `useEditorCore` is the only writer.\n *\n * `shallowRef`, not `ref`: the list is replaced wholesale, and a deep proxy\n * would make an in-place `push` by a consumer holding the original array\n * behave differently from the same push today. Consumers must go through\n * `setMergeTags`.\n */\nexport const MERGE_TAGS_KEY: InjectionKey<ShallowRef<MergeTag[]>> =\n Symbol(\"mergeTags\");\n\n/**\n * Inject default for {@link MERGE_TAGS_KEY} — headless callers and tests mount\n * components with no editor above them. Shared rather than allocated per call,\n * and never written: an editor always provides its own ref.\n */\nexport const NO_MERGE_TAGS: ShallowRef<MergeTag[]> = shallowRef([]);\n\nexport const MERGE_TAG_SYNTAX_KEY: InjectionKey<SyntaxPreset> =\n Symbol(\"mergeTagSyntax\");\n\nexport const ON_REQUEST_MERGE_TAG_KEY: InjectionKey<\n ((context?: MergeTagRequestContext) => Promise<MergeTag | null>) | null\n> = Symbol(\"onRequestMergeTag\");\n\nexport const MERGE_TAG_AUTOCOMPLETE_KEY: InjectionKey<boolean> = Symbol(\n \"mergeTagAutocomplete\",\n);\n\n/**\n * Whether a merge tag's tooltip reveals the raw token behind its label.\n * Resolved once from `mergeTags.showRawValue` and read by every surface that\n * renders a tag, so a chip in a sidebar field and a chip on the canvas cannot\n * disagree about whether the token is visible.\n */\nexport const MERGE_TAG_SHOW_RAW_VALUE_KEY: InjectionKey<boolean> = Symbol(\n \"mergeTagShowRawValue\",\n);\n\n/**\n * The user's choice between the previews' two merge-tag views: `true` for\n * Sample (tags replaced by their `MergeTag.sample`, rendered as ordinary text)\n * and `false` for Label (tags shown as their label with the usual cue).\n *\n * Session state owned by `useEditorCore` and driven by a toggle that exists\n * only on preview surfaces. Defaults to Sample.\n */\nexport const MERGE_TAG_SAMPLE_MODE_KEY: InjectionKey<Ref<boolean>> =\n Symbol(\"mergeTagSampleMode\");\n\n/**\n * Whether **the current render surface** substitutes samples.\n *\n * Provided per surface rather than globally, and that is the whole point:\n * substitution must never happen while editing, so `Canvas.vue` folds in its\n * `previewMode` flag and provides `false` whenever the canvas is editable, no\n * matter what the mode ref says. Preview surfaces provide the mode directly.\n *\n * Block components inject **this** key. They must never read\n * `MERGE_TAG_SAMPLE_MODE_KEY`, which would bypass the editing guard.\n */\nexport const USE_MERGE_TAG_SAMPLES_KEY: InjectionKey<ComputedRef<boolean>> =\n Symbol(\"useMergeTagSamples\");\n\n/**\n * The `resolvePreview` seam — resolved content plus its loading and failure\n * state. Provided by `useEditorCore` so every preview surface shares one\n * lifecycle; `null` when the consumer configured no hook.\n *\n * Surfaces read `content` from here instead of `editor.content`, and gate the\n * Sample/Label toggle on `supersedesSamples`.\n */\n/**\n * The raw `config.resolvePreview` hook.\n *\n * Provided alongside PREVIEW_RESOLUTION_KEY because the test-email dialog needs\n * its **own** resolution instance — it resolves for the selected recipient,\n * which the editor's canvas has no notion of — and so cannot reuse the shared\n * one. `undefined` when the consumer configured no hook.\n */\nexport const RESOLVE_PREVIEW_KEY: InjectionKey<ResolvePreview | undefined> =\n Symbol(\"resolvePreview\");\n\nexport const PREVIEW_RESOLUTION_KEY: InjectionKey<\n import(\"./composables/usePreviewResolution\").UsePreviewResolutionReturn | null\n> = Symbol(\"previewResolution\");\n\n/**\n * Singleton state for the built-in merge tag picker modal. Provided by\n * `useEditorCore`, consumed by `useMergeTag.requestMergeTag()` (to open\n * the modal as a fall-through when only `mergeTags.tags` is configured)\n * and by `MergeTagPickerModal.vue` (to render and resolve).\n */\nexport const MERGE_TAG_PICKER_KEY: InjectionKey<\n import(\"./composables/useMergeTagPicker\").UseMergeTagPickerReturn\n> = Symbol(\"mergeTagPicker\");\n\n/**\n * One \"a merge tag request is in flight\" flag per editor, provided by\n * `useEditorCore` and injected by every `useMergeTag()` call.\n *\n * Shared, not per-call: `useRichTextEditor.handleClickOutside` suppresses\n * editor teardown while this is set, because the picker modal mounts in the\n * popover root — outside `.tpl-text-editor-wrapper`. A ref private to one\n * `useMergeTag()` instance leaves that guard blind to a picker opened from\n * any other host (the link dialog's URL field), so the click on a picker row\n * tears the block out of edit mode and the pending insert then no-ops on its\n * own disposal guard. Falls back to a private ref for headless callers.\n */\nexport const MERGE_TAG_REQUESTING_KEY: InjectionKey<Ref<boolean>> =\n Symbol(\"mergeTagRequesting\");\n\n/** Logic-tag counterpart of {@link MERGE_TAG_REQUESTING_KEY}. */\nexport const LOGIC_TAG_REQUESTING_KEY: InjectionKey<Ref<boolean>> =\n Symbol(\"logicTagRequesting\");\n\n// ---------------------------------------------------------------------------\n// Logic tags — a standalone feature, separate from merge tags. Native\n// highlighting (LogicMergeTagNode) is always on; these drive the dedicated\n// logic picker + insertion.\n// ---------------------------------------------------------------------------\n\nexport const LOGIC_TAGS_KEY: InjectionKey<LogicTag[]> = Symbol(\"logicTags\");\n\nexport const LOGIC_PAIRS_KEY: InjectionKey<LogicPair[]> = Symbol(\"logicPairs\");\n\n/**\n * Singleton state for the built-in logic picker modal. Provided by\n * `useEditorCore`, consumed by `useLogicTag.requestLogicTag()` (to open the modal)\n * and by `LogicTagPickerModal.vue` (to render and resolve).\n */\nexport const LOGIC_TAG_PICKER_KEY: InjectionKey<\n import(\"./composables/useLogicTagPicker\").UseLogicTagPickerReturn\n> = Symbol(\"logicPicker\");\n\nexport const ON_REQUEST_LOGIC_TAG_KEY: InjectionKey<\n (() => Promise<LogicTag | LogicPair | null>) | null\n> = Symbol(\"onRequestLogic\");\n\nexport const ON_REQUEST_MEDIA_KEY: InjectionKey<OnRequestMedia | null> =\n Symbol(\"onRequestMedia\");\n\n/**\n * Whether a dropped image file may be uploaded. Distinct from Browse: a\n * read-only provider (`create: false`) still opens the library, but the\n * drop zone must not highlight. True when a host `onRequestMedia` is set\n * (the callback receives `files`) or when `provider.create` is a function.\n *\n * `null` when neither a provider nor a callback is configured — image\n * fields stay URL-only and drop is off. Injected as a computed; consumed\n * by ImageBlock / ImageToolbar / ImageField with a `null` default.\n */\nexport const CAN_DROP_MEDIA_KEY: InjectionKey<ComputedRef<boolean> | null> =\n Symbol(\"canDropMedia\");\n\n/**\n * Per-editor display-only image URL resolver (`config.resolveImageUrl`),\n * wrapped with a per-src cache by `createImageUrlResolver`. `null` when the\n * host doesn't resolve — the canvas then displays canonical src values\n * verbatim. Consumed via `useResolvedImageSrc` in image-displaying blocks.\n */\nexport const IMAGE_URL_RESOLVER_KEY: InjectionKey<ImageUrlResolver | null> =\n Symbol(\"imageUrlResolver\");\n\nexport const DISPLAY_CONDITIONS_KEY: InjectionKey<DisplayCondition[]> =\n Symbol(\"displayConditions\");\n\nexport const ALLOW_CUSTOM_CONDITIONS_KEY: InjectionKey<boolean> = Symbol(\n \"allowCustomConditions\",\n);\n\nexport const CAPABILITIES_KEY: InjectionKey<EditorCapabilities> =\n Symbol(\"capabilities\");\n\nexport const KEYBOARD_REORDER_KEY: InjectionKey<UseKeyboardReorderReturn> =\n Symbol(\"keyboardReorder\");\n\nexport const TEMPLATE_LINT_KEY: InjectionKey<\n import(\"./composables/useTemplateLint\").UseTemplateLintReturn | null\n> = Symbol(\"templateLint\");\n\n/**\n * The editor's effective DOM root — `Document` in light-DOM mode, `ShadowRoot`\n * when `shadowDom: true`. Composables that read `document.activeElement`,\n * popup mount targets, etc. should inject this and use the root-aware API\n * (both `Document` and `ShadowRoot` expose `activeElement` etc.).\n */\nexport const EDITOR_ROOT_KEY: InjectionKey<Document | ShadowRoot> =\n Symbol(\"editorRoot\");\n\n/**\n * Mount target for popovers, toolbars, and modal dialogs — never\n * `document.body`. Provided by `useEditorCore` as a ref bound\n * to a `<div class=\"tpl-popover-root\" />` rendered at the top level of the\n * editor template. Teleports use `:to=\"popoverRoot\"` so popups land inside\n * the editor's effective root — `document` in light-DOM mode, `ShadowRoot`\n * when `shadowDom: true` — instead of escaping the shadow boundary.\n *\n * Null until the editor's template mounts; consumers must guard with\n * `v-if=\"popoverRoot\"` before passing to `<Teleport>`.\n */\nexport const POPOVER_ROOT_KEY: InjectionKey<Ref<HTMLElement | null>> =\n Symbol(\"popoverRoot\");\n\n/**\n * Reactive saved-blocks state, provided by `useSavedBlocksFeature` when a\n * `SavedBlocksProvider` is configured. Shared by OSS and Cloud — the storage\n * transport lives behind the provider, so this key is not cloud-specific.\n */\nexport const SAVED_BLOCKS_KEY: InjectionKey<UseSavedBlocksReturn> =\n Symbol(\"savedBlocks\");\n\n// ---------------------------------------------------------------------------\n// Cloud-only keys (provided by createCloudRuntime, consumed by cloud components)\n// ---------------------------------------------------------------------------\n\nexport const AUTH_MANAGER_KEY: InjectionKey<AuthManager> =\n Symbol(\"authManager\");\n\nexport const AI_CONFIG_KEY: InjectionKey<UseAiConfigReturn> =\n Symbol(\"aiConfig\");\n\n// Comments are deliberately not injected: the panel takes `useCommentsFeature`'s\n// return as a **prop** the way `TestEmailPanel` and `SavedBlocksPanels` do, and the\n// per-block indicators read the comments entry on `CAPABILITIES_KEY`. Nothing\n// injects the composable itself.\n\nexport const SCORING_KEY: InjectionKey<UseTemplateScoringReturn> =\n Symbol(\"scoring\");\n\nexport const CLOUD_TRANSLATIONS_KEY: InjectionKey<CloudTranslations> =\n Symbol(\"cloudTranslations\");\n\n// ---------------------------------------------------------------------------\n// Helper for required injections with explicit null default + throw\n// ---------------------------------------------------------------------------\n\nexport function requireInject<T>(\n key: InjectionKey<T>,\n componentName: string,\n): T {\n const value = inject(key, null) as T | null;\n if (value === null || value === undefined) {\n throw new Error(\n `${componentName} requires a provider for ${key.description ?? \"unknown key\"}. Ensure it renders inside the editor, below Editor.vue.`,\n );\n }\n return value;\n}\n"],"mappings":";;AA4CA,IAAa,IACX,OAAO,cAAc,GAEV,IAA6C,OAAO,QAAQ,GAE5D,IAA8C,OAAO,SAAS,GAE9D,IACX,OAAO,cAAc,GAEV,IACX,OAAO,kBAAkB,GAWd,IACX,OAAO,wBAAwB,GAEpB,IACX,OAAO,cAAc,GAEV,IAET,OAAO,aAAa,GAEX,IACX,OAAO,YAAY,GAeR,IACX,OAAO,aAAa,GAMT,IACX,OAAO,eAAe,GAEX,IACX,OAAO,eAAe,GAEX,IAET,OAAO,wBAAwB,GAMtB,IACX,OAAO,eAAe,GAOX,IACX,OAAO,kBAAkB,GAOd,IACX,OAAO,QAAQ,GAQJ,IACX,OAAO,gBAAgB,GAUZ,IAET,OAAO,QAAQ,GAaN,IAET,OAAO,wBAAwB,GAEtB,IACX,OAAO,wBAAwB,GAWpB,IACX,OAAO,WAAW,GAOP,IAAwC,EAAW,CAAC,CAAC,GAErD,IACX,OAAO,gBAAgB,GAEZ,IAET,OAAO,mBAAmB,GAEjB,IAAoD,OAC/D,sBACF,GAQa,IAAsD,OACjE,sBACF,GAUa,KACX,OAAO,oBAAoB,GAahB,IACX,OAAO,oBAAoB,GAkBhB,IACX,OAAO,gBAAgB,GAEZ,IAET,OAAO,mBAAmB,GAQjB,IAET,OAAO,gBAAgB,GAcd,IACX,OAAO,oBAAoB,GAGhB,IACX,OAAO,oBAAoB,GAQhB,IAA2C,OAAO,WAAW,GAE7D,IAA6C,OAAO,YAAY,GAOhE,IAET,OAAO,aAAa,GAEX,IAET,OAAO,gBAAgB,GAEd,IACX,OAAO,gBAAgB,GAYZ,IACX,OAAO,cAAc,GAQV,IACX,OAAO,kBAAkB,GAEd,IACX,OAAO,mBAAmB,GAEf,IAAqD,OAChE,uBACF,GAEa,IACX,OAAO,cAAc,GAEV,IACX,OAAO,iBAAiB,GAEb,IAET,OAAO,cAAc,GAQZ,IACX,OAAO,YAAY,GAaR,IACX,OAAO,aAAa,GAOT,IACX,OAAO,aAAa,GAMT,IACX,OAAO,aAAa,GAET,IACX,OAAO,UAAU,GAON,IACX,OAAO,SAAS,GAEL,IACX,OAAO,mBAAmB;AAM5B,SAAgB,EACd,GACA,GACG;CACH,IAAM,IAAQ,EAAO,GAAK,IAAI;CAC9B,IAAI,KAAU,MACZ,MAAU,MACR,GAAG,EAAc,2BAA2B,EAAI,eAAe,cAAc,yDAC/E;CAEF,OAAO;AACT"}
@@ -131,6 +131,7 @@ var e = {
131
131
  ratio21: "Verhouding 2:1",
132
132
  borderRadius: "Hoekafronding",
133
133
  wrapperEnable: "Omhulsel toevoegen",
134
+ wrapperLayoutConflict: "Deze editor kadert de e-mail al in. Een extra kader op deze sectie wordt niet ondersteund — voorbeeld en export zullen mislukken.",
134
135
  stackOnMobile: "Stapelen op mobiel"
135
136
  },
136
137
  linkDialog: {
@@ -620,3 +621,5 @@ var e = {
620
621
  };
621
622
  //#endregion
622
623
  export { e as default };
624
+
625
+ //# sourceMappingURL=nl-DeFatKJe.js.map