@templatical/editor 0.44.3 → 0.45.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.
- package/dist/{AiChatSidebar-BUR5Jshu.js → AiChatSidebar-BlFWWhBv.js} +15 -19
- package/dist/{AiFeatureMenu-CXqrbDNb.js → AiFeatureMenu-CvWygUmC.js} +7 -7
- package/dist/{BlockIssueBadge-CWZEwMXX.js → BlockIssueBadge-CZA1XvAh.js} +5 -5
- package/dist/{BlockPreviewCanvas-DCeZid0G.js → BlockPreviewCanvas-DwxJOTzH.js} +5 -5
- package/dist/{CloudHeaderExtras-B38fU84y.js → CloudHeaderExtras-BzM1QU1r.js} +5 -5
- package/dist/{CloudPanels-B2Mz-TwS.js → CloudPanels-d36YXXyn.js} +8 -8
- package/dist/{CollaboratorBar-CL70aVnL.js → CollaboratorBar-rwXe_Qd2.js} +4 -4
- package/dist/{CommentsPanel-CYMHfFcn.js → CommentsPanel-Bn6P5crU.js} +2 -2
- package/dist/{CommentsSidebar-uvQyCMUe.js → CommentsSidebar-B8wT932T.js} +14 -14
- package/dist/{CountdownBlock-C6R-hn7D.js → CountdownBlock-RNx3hIu0.js} +3 -3
- package/dist/{CountdownToolbar-C052mx2P.js → CountdownToolbar-lbjCc8ik.js} +62 -61
- package/dist/{DesignReferenceSidebar-ZKJ7y7-G.js → DesignReferenceSidebar-zlJQsP0X.js} +25 -26
- package/dist/{IssuesPanel-DAlNiJX_.js → IssuesPanel-CHx3m8SP.js} +8 -8
- package/dist/{LoadingTrack-C1Epulqq.js → LoadingTrack-DROqNuuD.js} +1 -1
- package/dist/{LogicTagInsertButton-DMUfVsPr.js → LogicTagInsertButton-BvftbkL4.js} +13 -19
- package/dist/{MediaEditModal-Cmd9tQXZ.js → MediaEditModal-EY1YYcpw.js} +6 -14
- package/dist/{MediaPanels-DoBhG5gg.js → MediaPanels-CRVFGFZW.js} +2 -2
- package/dist/{MergeTagInput-DoQWMSW4.js → MergeTagInput-CR1kcj8X.js} +2 -2
- package/dist/{MergeTagModeToggle-DOHixe4G.js → MergeTagModeToggle-DssKrVYb.js} +7 -7
- package/dist/{ParagraphEditor-CHlX3nAk.js → ParagraphEditor-DFizsZRc.js} +140 -139
- package/dist/{RestoreVersionDialog-C8Qt-sJV.js → RestoreVersionDialog-Cp3q2mU4.js} +5 -5
- package/dist/{RichTextEditorContent-BedBVHXS.js → RichTextEditorContent-Cj3oaPMk.js} +9 -9
- package/dist/{SaveBlockDialog-CsielLi1.js → SaveBlockDialog-BR8vW_XF.js} +12 -12
- package/dist/{SavedBlocksBrowserModal-RKo9mq3U.js → SavedBlocksBrowserModal-DmwbmKxI.js} +15 -18
- package/dist/{SavedBlocksPanels-B7IlFCQp.js → SavedBlocksPanels-D4XKrs-a.js} +2 -2
- package/dist/{SavedBlocksPickBar-BYCwMUR6.js → SavedBlocksPickBar-gfc-o5sR.js} +4 -4
- package/dist/{TemplateScoringPanel-DXsyp0_A.js → TemplateScoringPanel-3lHzuCl0.js} +16 -16
- package/dist/TemplateSettings-D7aNrd0d.js +246 -0
- package/dist/{TestEmailModal-Btbk0B1s.js → TestEmailModal-DUmtcSm-.js} +11 -11
- package/dist/{TestEmailPanel-kdF_QluO.js → TestEmailPanel-s9gISTI8.js} +2 -2
- package/dist/{TitleEditor-Cl6AmEy9.js → TitleEditor-C-uHqtml.js} +13 -13
- package/dist/{ToggleSwitch-D7GLaT8s.js → ToggleSwitch-CTwwCIVA.js} +2 -2
- package/dist/{Toolbar-CWxqqBHE.js → Toolbar-CLpA36RO.js} +518 -520
- package/dist/{TplModal-DD1xZyBq.js → TplModal-D6XtxusQ.js} +5 -5
- package/dist/{VersionHistoryMenu-fLrx-Lvi.js → VersionHistoryMenu-D7zaTMrb.js} +10 -10
- package/dist/{VersionHistoryPanels-Caa2_niu.js → VersionHistoryPanels-Dvowtt7V.js} +2 -2
- package/dist/{VersionPreviewBanner-CWuxq_bb.js → VersionPreviewBanner-BUKb9gc6.js} +3 -3
- package/dist/{WrapperBlock-Do8kLejT.js → WrapperBlock-CzJa2Mxw.js} +3 -3
- package/dist/{blockTypeIcons-DEvNVvBj.js → blockTypeIcons-D3aj5u_5.js} +2 -2
- package/dist/bundle-stats.json +7 -7
- package/dist/{ca-DES69VJW.js → ca-C__Dzq--.js} +5 -0
- package/dist/cdn/chunks/{AiChatSidebar-Cvp9beXR.js → AiChatSidebar-SRGBP-SL.js} +9 -13
- package/dist/cdn/chunks/{AiChatSidebar-Cvp9beXR.js.map → AiChatSidebar-SRGBP-SL.js.map} +1 -1
- package/dist/cdn/chunks/{AiFeatureMenu-B291Us2g.js → AiFeatureMenu-oZhlgsGh.js} +6 -6
- package/dist/cdn/chunks/{AiFeatureMenu-B291Us2g.js.map → AiFeatureMenu-oZhlgsGh.js.map} +1 -1
- package/dist/cdn/chunks/{BlockIssueBadge-CKIrYROg.js → BlockIssueBadge-05Q3L4RV.js} +5 -5
- package/dist/cdn/chunks/{BlockIssueBadge-CKIrYROg.js.map → BlockIssueBadge-05Q3L4RV.js.map} +1 -1
- package/dist/cdn/chunks/{BlockPreviewCanvas-CRJZBmwV.js → BlockPreviewCanvas-hKxE6f-k.js} +6 -6
- package/dist/cdn/chunks/{BlockPreviewCanvas-CRJZBmwV.js.map → BlockPreviewCanvas-hKxE6f-k.js.map} +1 -1
- package/dist/cdn/chunks/{CloudHeaderExtras-BvCPpih5.js → CloudHeaderExtras-t-_ZlHwn.js} +5 -5
- package/dist/cdn/chunks/{CloudHeaderExtras-BvCPpih5.js.map → CloudHeaderExtras-t-_ZlHwn.js.map} +1 -1
- package/dist/cdn/chunks/{CloudPanels-vlPH6N3s.js → CloudPanels-DR2eEcpX.js} +7 -7
- package/dist/cdn/chunks/{CloudPanels-vlPH6N3s.js.map → CloudPanels-DR2eEcpX.js.map} +1 -1
- package/dist/cdn/chunks/{CollaboratorBar-Xt3WJ-rn.js → CollaboratorBar-w8_2WPE0.js} +5 -5
- package/dist/cdn/chunks/{CollaboratorBar-Xt3WJ-rn.js.map → CollaboratorBar-w8_2WPE0.js.map} +1 -1
- package/dist/cdn/chunks/{CommentsPanel-BjHRj_Yw.js → CommentsPanel-VH_NJ5HZ.js} +3 -3
- package/dist/cdn/chunks/{CommentsPanel-BjHRj_Yw.js.map → CommentsPanel-VH_NJ5HZ.js.map} +1 -1
- package/dist/cdn/chunks/{CommentsSidebar-CpCfqSq4.js → CommentsSidebar-CYPH5rVi.js} +5 -5
- package/dist/cdn/chunks/{CommentsSidebar-CpCfqSq4.js.map → CommentsSidebar-CYPH5rVi.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownBlock-sVDjKkRw.js → CountdownBlock-lHU3Lu7Q.js} +4 -4
- package/dist/cdn/chunks/{CountdownBlock-sVDjKkRw.js.map → CountdownBlock-lHU3Lu7Q.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownToolbar-C9QpHQcv.js → CountdownToolbar-CvNuDR5Z.js} +63 -62
- package/dist/cdn/chunks/CountdownToolbar-CvNuDR5Z.js.map +1 -0
- package/dist/cdn/chunks/{DesignReferenceSidebar-BO0xz1wC.js → DesignReferenceSidebar-CJg_5GXU.js} +21 -22
- package/dist/cdn/chunks/{DesignReferenceSidebar-BO0xz1wC.js.map → DesignReferenceSidebar-CJg_5GXU.js.map} +1 -1
- package/dist/cdn/chunks/{IssuesPanel--62qud8w.js → IssuesPanel-DXqlRk19.js} +6 -6
- package/dist/cdn/chunks/{IssuesPanel--62qud8w.js.map → IssuesPanel-DXqlRk19.js.map} +1 -1
- package/dist/cdn/chunks/{LoadingTrack-_7DH_5aw.js → LoadingTrack-Cg1HRIND.js} +2 -2
- package/dist/cdn/chunks/{LoadingTrack-_7DH_5aw.js.map → LoadingTrack-Cg1HRIND.js.map} +1 -1
- package/dist/cdn/chunks/{LogicTagInsertButton-gc8ICURV.js → LogicTagInsertButton-DnHghQHb.js} +11 -17
- package/dist/cdn/chunks/{LogicTagInsertButton-gc8ICURV.js.map → LogicTagInsertButton-DnHghQHb.js.map} +1 -1
- package/dist/cdn/chunks/{MediaEditModal-BuDXKwx4.js → MediaEditModal-CD3fVbWI.js} +6 -14
- package/dist/cdn/chunks/{MediaEditModal-BuDXKwx4.js.map → MediaEditModal-CD3fVbWI.js.map} +1 -1
- package/dist/cdn/chunks/{MediaPanels-xFpaxFRH.js → MediaPanels-B2AyUUcf.js} +3 -3
- package/dist/cdn/chunks/{MediaPanels-xFpaxFRH.js.map → MediaPanels-B2AyUUcf.js.map} +1 -1
- package/dist/cdn/chunks/{MergeTagInput-DsPKWbWr.js → MergeTagInput-heTX9P_k.js} +3 -3
- package/dist/cdn/chunks/{MergeTagInput-DsPKWbWr.js.map → MergeTagInput-heTX9P_k.js.map} +1 -1
- package/dist/cdn/chunks/{MergeTagModeToggle-DU0WqgVH.js → MergeTagModeToggle-C9EfuZIP.js} +6 -6
- package/dist/cdn/chunks/{MergeTagModeToggle-DU0WqgVH.js.map → MergeTagModeToggle-C9EfuZIP.js.map} +1 -1
- package/dist/cdn/chunks/{ParagraphEditor-BWfx94pb.js → ParagraphEditor-B5DN4Sy4.js} +145 -144
- package/dist/cdn/chunks/ParagraphEditor-B5DN4Sy4.js.map +1 -0
- package/dist/cdn/chunks/{RestoreVersionDialog-DWUnyA0B.js → RestoreVersionDialog-DBgJ-Nui.js} +5 -5
- package/dist/cdn/chunks/{RestoreVersionDialog-DWUnyA0B.js.map → RestoreVersionDialog-DBgJ-Nui.js.map} +1 -1
- package/dist/cdn/chunks/{RichTextEditorContent-Dkcts8Vh.js → RichTextEditorContent-LOas4rfU.js} +8 -8
- package/dist/cdn/chunks/{RichTextEditorContent-Dkcts8Vh.js.map → RichTextEditorContent-LOas4rfU.js.map} +1 -1
- package/dist/cdn/chunks/{SaveBlockDialog-CcfyxDfZ.js → SaveBlockDialog-Dx-QVQCX.js} +10 -10
- package/dist/cdn/chunks/{SaveBlockDialog-CcfyxDfZ.js.map → SaveBlockDialog-Dx-QVQCX.js.map} +1 -1
- package/dist/cdn/chunks/{SavedBlocksBrowserModal-DauQ_V9N.js → SavedBlocksBrowserModal-C2RQ-JCc.js} +11 -14
- package/dist/cdn/chunks/{SavedBlocksBrowserModal-DauQ_V9N.js.map → SavedBlocksBrowserModal-C2RQ-JCc.js.map} +1 -1
- package/dist/cdn/chunks/{SavedBlocksPanels-J5v2PsFv.js → SavedBlocksPanels-BmRbvqqL.js} +3 -3
- package/dist/cdn/chunks/{SavedBlocksPanels-J5v2PsFv.js.map → SavedBlocksPanels-BmRbvqqL.js.map} +1 -1
- package/dist/cdn/chunks/{SavedBlocksPickBar-v3AMSqli.js → SavedBlocksPickBar-BzwKojoJ.js} +5 -5
- package/dist/cdn/chunks/{SavedBlocksPickBar-v3AMSqli.js.map → SavedBlocksPickBar-BzwKojoJ.js.map} +1 -1
- package/dist/cdn/chunks/{TemplateScoringPanel-BBRHCNcR.js → TemplateScoringPanel-C_57Bfkf.js} +8 -8
- package/dist/cdn/chunks/{TemplateScoringPanel-BBRHCNcR.js.map → TemplateScoringPanel-C_57Bfkf.js.map} +1 -1
- package/dist/cdn/chunks/{TemplateSettings-vsFOU0oA.js → TemplateSettings-G-yV7C1C.js} +48 -47
- package/dist/cdn/chunks/TemplateSettings-G-yV7C1C.js.map +1 -0
- package/dist/cdn/chunks/{TestEmailModal-CW9EFpFR.js → TestEmailModal-lOeztfTN.js} +10 -10
- package/dist/cdn/chunks/{TestEmailModal-CW9EFpFR.js.map → TestEmailModal-lOeztfTN.js.map} +1 -1
- package/dist/cdn/chunks/{TestEmailPanel-D1Hchlr7.js → TestEmailPanel-CZswVkk_.js} +3 -3
- package/dist/cdn/chunks/{TestEmailPanel-D1Hchlr7.js.map → TestEmailPanel-CZswVkk_.js.map} +1 -1
- package/dist/cdn/chunks/{TitleEditor-nDV6P-ag.js → TitleEditor-CnTT2Y3H.js} +12 -12
- package/dist/cdn/chunks/{TitleEditor-nDV6P-ag.js.map → TitleEditor-CnTT2Y3H.js.map} +1 -1
- package/dist/cdn/chunks/{ToggleSwitch-DoUNcLPP.js → ToggleSwitch-CLHteVMO.js} +3 -3
- package/dist/cdn/chunks/{ToggleSwitch-DoUNcLPP.js.map → ToggleSwitch-CLHteVMO.js.map} +1 -1
- package/dist/cdn/chunks/{Toolbar-CnfNUkOY.js → Toolbar-K4tIkpG1.js} +415 -417
- package/dist/cdn/chunks/Toolbar-K4tIkpG1.js.map +1 -0
- package/dist/cdn/chunks/{TplModal-VuZ9bDw9.js → TplModal-OOT36AjS.js} +5 -5
- package/dist/cdn/chunks/{TplModal-VuZ9bDw9.js.map → TplModal-OOT36AjS.js.map} +1 -1
- package/dist/cdn/chunks/{VersionHistoryMenu-Cp3EHO_P.js → VersionHistoryMenu-DbxuJgDO.js} +6 -6
- package/dist/cdn/chunks/{VersionHistoryMenu-Cp3EHO_P.js.map → VersionHistoryMenu-DbxuJgDO.js.map} +1 -1
- package/dist/cdn/chunks/{VersionHistoryPanels-BChjjMC6.js → VersionHistoryPanels-BrpYRSfW.js} +3 -3
- package/dist/cdn/chunks/{VersionHistoryPanels-BChjjMC6.js.map → VersionHistoryPanels-BrpYRSfW.js.map} +1 -1
- package/dist/cdn/chunks/{VersionPreviewBanner-BgkroXnG.js → VersionPreviewBanner-HRERIH-v.js} +4 -4
- package/dist/cdn/chunks/{VersionPreviewBanner-BgkroXnG.js.map → VersionPreviewBanner-HRERIH-v.js.map} +1 -1
- package/dist/cdn/chunks/{WrapperBlock-DDnue8oy.js → WrapperBlock-DdrnwH80.js} +4 -4
- package/dist/cdn/chunks/{WrapperBlock-DDnue8oy.js.map → WrapperBlock-DdrnwH80.js.map} +1 -1
- package/dist/cdn/chunks/{blockTypeIcons-BMZi7sdX.js → blockTypeIcons-DdZP-3FM.js} +2 -2
- package/dist/cdn/chunks/{blockTypeIcons-BMZi7sdX.js.map → blockTypeIcons-DdZP-3FM.js.map} +1 -1
- package/dist/cdn/chunks/{ca-DES69VJW.js → ca-C__Dzq--.js} +6 -1
- package/dist/cdn/chunks/ca-C__Dzq--.js.map +1 -0
- package/dist/cdn/chunks/{cloud-DLQU5l0Z.js → cloud-bhW8qTnh.js} +4 -4
- package/dist/cdn/chunks/{cloud-DLQU5l0Z.js.map → cloud-bhW8qTnh.js.map} +1 -1
- package/dist/cdn/chunks/{createCloudRuntime-Mnx8kV2W.js → createCloudRuntime-CeRJkLR2.js} +9 -12
- package/dist/cdn/chunks/{createCloudRuntime-Mnx8kV2W.js.map → createCloudRuntime-CeRJkLR2.js.map} +1 -1
- package/dist/{de-MlrDhC3Y.js → cdn/chunks/de-CGjbQ2mt.js} +7 -0
- package/dist/cdn/chunks/de-CGjbQ2mt.js.map +1 -0
- package/dist/cdn/chunks/{dist-BRZhN8qJ.js → dist-B7W-Lb65.js} +2 -2
- package/dist/cdn/chunks/{dist-BRZhN8qJ.js.map → dist-B7W-Lb65.js.map} +1 -1
- package/dist/cdn/chunks/{dist-CXB2_kBa.js → dist-C5nRd_ua.js} +5 -13
- package/dist/cdn/chunks/{dist-CXB2_kBa.js.map → dist-C5nRd_ua.js.map} +1 -1
- package/dist/cdn/chunks/{draggable-IB4x6w2O.js → draggable-BUTN5vZC.js} +32 -77
- package/dist/cdn/chunks/{draggable-IB4x6w2O.js.map → draggable-BUTN5vZC.js.map} +1 -1
- package/dist/cdn/chunks/{editor-modal-B7NNAFI5.js → editor-modal-BpsbYA4_.js} +14 -34
- package/dist/cdn/chunks/{editor-modal-B7NNAFI5.js.map → editor-modal-BpsbYA4_.js.map} +1 -1
- package/dist/{en-6vJh7KCM.js → cdn/chunks/en-BTiiAC-B.js} +7 -0
- package/dist/cdn/chunks/en-BTiiAC-B.js.map +1 -0
- package/dist/cdn/chunks/en-CAt6y87e.js +1 -0
- package/dist/{es-ewL03EaP.js → cdn/chunks/es-CdTOcSTf.js} +7 -0
- package/dist/cdn/chunks/es-CdTOcSTf.js.map +1 -0
- package/dist/cdn/chunks/{extensions-ClmkNA8R.js → extensions-xjRsIjMP.js} +9 -17
- package/dist/cdn/chunks/{extensions-ClmkNA8R.js.map → extensions-xjRsIjMP.js.map} +1 -1
- package/dist/{fr-D1syuxs1.js → cdn/chunks/fr-B6lcLLzC.js} +7 -0
- package/dist/cdn/chunks/fr-B6lcLLzC.js.map +1 -0
- package/dist/cdn/chunks/{htmlparser-ClUZ6waR.js → htmlparser-CDRsn-gn.js} +3 -11
- package/dist/cdn/chunks/{htmlparser-ClUZ6waR.js.map → htmlparser-CDRsn-gn.js.map} +1 -1
- package/dist/cdn/chunks/{icons-BjvraR-Y.js → icons-Dr9erFGs.js} +48 -48
- package/dist/cdn/chunks/{icons-BjvraR-Y.js.map → icons-Dr9erFGs.js.map} +1 -1
- package/dist/{ja-Dd_nytwe.js → cdn/chunks/ja-BhdkqENz.js} +7 -0
- package/dist/cdn/chunks/ja-BhdkqENz.js.map +1 -0
- package/dist/cdn/chunks/{keys-DCWeHkSF.js → keys-BKu-LOk5.js} +2 -2
- package/dist/cdn/chunks/{keys-DCWeHkSF.js.map → keys-BKu-LOk5.js.map} +1 -1
- package/dist/cdn/chunks/{liquid.browser-DXPjcePu.js → liquid.browser-Bbt17cVz.js} +30 -56
- package/dist/cdn/chunks/{liquid.browser-DXPjcePu.js.map → liquid.browser-Bbt17cVz.js.map} +1 -1
- package/dist/{nl-DD1t_qxS.js → cdn/chunks/nl-CE3YItYg.js} +7 -0
- package/dist/cdn/chunks/nl-CE3YItYg.js.map +1 -0
- package/dist/cdn/chunks/{preRenderCustomBlocks-Bg3rIgGJ.js → preRenderCustomBlocks-CFwa7nP9.js} +2 -2
- package/dist/cdn/chunks/{preRenderCustomBlocks-Bg3rIgGJ.js.map → preRenderCustomBlocks-CFwa7nP9.js.map} +1 -1
- package/dist/{pt-BR-BmtO0R7k.js → cdn/chunks/pt-BR-CUIT4rq4.js} +7 -0
- package/dist/cdn/chunks/pt-BR-CUIT4rq4.js.map +1 -0
- package/dist/cdn/chunks/{pusher-BbIHJKf3.js → pusher-C8DeiO2X.js} +18 -57
- package/dist/cdn/chunks/{pusher-BbIHJKf3.js.map → pusher-C8DeiO2X.js.map} +1 -1
- package/dist/cdn/chunks/{socialIcons-CnUJBZTO.js → socialIcons-CsYnPPll.js} +14 -24
- package/dist/cdn/chunks/socialIcons-CsYnPPll.js.map +1 -0
- package/dist/cdn/chunks/{src-QIGNPFkl.js → src-BcqNlDMe.js} +258 -237
- package/dist/cdn/chunks/src-BcqNlDMe.js.map +1 -0
- package/dist/cdn/chunks/{src-CjjJWoUZ.js → src-CkXmV2I2.js} +174 -179
- package/dist/cdn/chunks/src-CkXmV2I2.js.map +1 -0
- package/dist/cdn/chunks/{src-B5-VKcRQ.js → src-HA9F2kvk.js} +141 -179
- package/dist/cdn/chunks/{src-B5-VKcRQ.js.map → src-HA9F2kvk.js.map} +1 -1
- package/dist/cdn/chunks/{tiptap-02G9FGkl.js → tiptap-CYDXLO17.js} +87 -134
- package/dist/cdn/chunks/{tiptap-02G9FGkl.js.map → tiptap-CYDXLO17.js.map} +1 -1
- package/dist/cdn/chunks/{useAliveFlag-DAlQLbM2.js → useAliveFlag-DzyXG-8A.js} +2 -2
- package/dist/cdn/chunks/{useAliveFlag-DAlQLbM2.js.map → useAliveFlag-DzyXG-8A.js.map} +1 -1
- package/dist/cdn/chunks/{useCloudI18n-CrjWbpbu.js → useCloudI18n-Cgk0ts_F.js} +3 -3
- package/dist/cdn/chunks/{useCloudI18n-CrjWbpbu.js.map → useCloudI18n-Cgk0ts_F.js.map} +1 -1
- package/dist/cdn/chunks/{useEditorCore-q0G4q-52.js → useEditorCore-BF1ZhcGu.js} +476 -520
- package/dist/cdn/chunks/useEditorCore-BF1ZhcGu.js.map +1 -0
- package/dist/cdn/chunks/useEditorRoot-DDPIcEOO.js +10 -0
- package/dist/cdn/chunks/{useEditorRoot-CshefZLP.js.map → useEditorRoot-DDPIcEOO.js.map} +1 -1
- package/dist/cdn/chunks/{useI18n-CyO_Nmca.js → useI18n-DO4NTunW.js} +3 -3
- package/dist/cdn/chunks/{useI18n-CyO_Nmca.js.map → useI18n-DO4NTunW.js.map} +1 -1
- package/dist/cdn/chunks/{useLogicTag-D6lWY0bD.js → useLogicTag-91bO_SOi.js} +4 -4
- package/dist/cdn/chunks/{useLogicTag-D6lWY0bD.js.map → useLogicTag-91bO_SOi.js.map} +1 -1
- package/dist/cdn/chunks/{useMergeTag-2iW-BKWW.js → useMergeTag-hwifK582.js} +4 -4
- package/dist/cdn/chunks/{useMergeTag-2iW-BKWW.js.map → useMergeTag-hwifK582.js.map} +1 -1
- package/dist/cdn/chunks/{usePopoverPosition-DGXjXKjM.js → usePopoverPosition-CtVNwoHj.js} +3 -3
- package/dist/cdn/chunks/{usePopoverPosition-DGXjXKjM.js.map → usePopoverPosition-CtVNwoHj.js.map} +1 -1
- package/dist/cdn/chunks/{useScrollToBlock-DgHZJvID.js → useScrollToBlock-BDNJ25X1.js} +3 -3
- package/dist/cdn/chunks/{useScrollToBlock-DgHZJvID.js.map → useScrollToBlock-BDNJ25X1.js.map} +1 -1
- package/dist/cdn/chunks/withCurrentFont-DeCbPVaE.js +32 -0
- package/dist/cdn/chunks/withCurrentFont-DeCbPVaE.js.map +1 -0
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +56 -93
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{check-DNyj-E0y.js → check-ZKvtMdpe.js} +1 -1
- package/dist/{chevron-down-BYnhkMsA.js → chevron-down-RrwkYMlp.js} +1 -1
- package/dist/{chevron-right-D9HGBqJo.js → chevron-right-CklHaa1U.js} +1 -1
- package/dist/{chevron-up-BnIR1-ma.js → chevron-up-DjN2NTbo.js} +1 -1
- package/dist/{circle-alert-B6xl1B_M.js → circle-alert-BR1_Yfb-.js} +1 -1
- package/dist/{clock-Cs5Wd3dW.js → clock-BEagNj21.js} +1 -1
- package/dist/{cloud-BNEL7bxL.js → cloud-CVfwPu19.js} +2 -2
- package/dist/{copy-6uKc-WBk.js → copy-D6DNoSq1.js} +1 -1
- package/dist/{createCloudRuntime-CaZapQZ6.js → createCloudRuntime-GRv_TDb2.js} +8 -11
- package/dist/{createLucideIcon-BVcoovvP.js → createLucideIcon-BAPyioGd.js} +6 -6
- package/dist/{cdn/chunks/de-MlrDhC3Y.js → de-CGjbQ2mt.js} +5 -2
- package/dist/{dist-CmwBvyW0.js → dist-1H4cnaoD.js} +3 -3
- package/dist/{dist-D4HP93ZF.js → dist-5DAb7bYT.js} +1 -1
- package/dist/{dist-DdSWMtEP.js → dist-5KNKxglR.js} +1 -1
- package/dist/{dist-BDuPwOyn.js → dist-B_vYjCsk.js} +4 -12
- package/dist/{dist-Ceew_u40.js → dist-Bc30883t.js} +6 -22
- package/dist/{dist-Czzst9ng.js → dist-Bd7khQsg.js} +3 -11
- package/dist/{dist-8VFzbeu9.js → dist-C-VFTX82.js} +1 -1
- package/dist/{dist-BYg1EL5g.js → dist-C3eH9-N2.js} +1 -1
- package/dist/{dist-Dw2_11LA.js → dist-CFC4pg2o.js} +1 -1
- package/dist/{dist-BgSLW3Hn.js → dist-CMcFD7gP.js} +72 -87
- package/dist/{dist-HjILVdTA.js → dist-CSaWqmWM.js} +143 -126
- package/dist/{dist-DmQckB4p.js → dist-DHensKDY.js} +1 -1
- package/dist/{dist-CWc7nIkA.js → dist-DapsJxn_.js} +1 -1
- package/dist/{dist-D2m55Lvs.js → dist-j2FavQmU.js} +1 -1
- package/dist/{dist-8By0p8ah.js → dist-lL3nVbxV.js} +1 -1
- package/dist/{editor-modal-Co-rZGaf.js → editor-modal-oRmkDlUs.js} +27 -47
- package/dist/{cdn/chunks/en-6vJh7KCM.js → en-BTiiAC-B.js} +5 -2
- package/dist/en-Bk4iCfjp.js +1 -0
- package/dist/{cdn/chunks/es-ewL03EaP.js → es-CdTOcSTf.js} +5 -2
- package/dist/{extensions-DXSI8Dyj.js → extensions-B65sfZRk.js} +42 -58
- package/dist/{eye-Nbtw_q05.js → eye-DvsTBI57.js} +1 -1
- package/dist/{cdn/chunks/fr-D1syuxs1.js → fr-B6lcLLzC.js} +5 -2
- package/dist/{image-up-C1jC7NzQ.js → image-up-BoFGZm5Q.js} +1 -1
- package/dist/index.d.ts +12 -1
- package/dist/{info-ClH66pKN.js → info-0bQQGjTV.js} +1 -1
- package/dist/{cdn/chunks/ja-Dd_nytwe.js → ja-BhdkqENz.js} +5 -2
- package/dist/{keys-CDqfZIRt.js → keys-injl74ob.js} +1 -1
- package/dist/{link-y47GNW0o.js → link-Cstrr3Ep.js} +1 -1
- package/dist/{liquid.browser-Cs4gOjeX.js → liquid.browser-Ct2-EezB.js} +29 -55
- package/dist/{list-DiLMlMaE.js → list-Dx9Rmy5s.js} +1 -1
- package/dist/{loader-circle-BRdCPW5h.js → loader-circle-D8Qqs0MG.js} +1 -1
- package/dist/{message-circle-CNgIpVJv.js → message-circle-D78ELX6I.js} +1 -1
- package/dist/{cdn/chunks/nl-DD1t_qxS.js → nl-CE3YItYg.js} +5 -2
- package/dist/{package-B9OWk-Kp.js → package-DOvM9sHE.js} +1 -1
- package/dist/{pencil-BDnjo24u.js → pencil-B6m0OG0n.js} +1 -1
- package/dist/{plus-BMgjN7lI.js → plus-D-nEKxTc.js} +1 -1
- package/dist/{preRenderCustomBlocks-C_PIxBp7.js → preRenderCustomBlocks-DAS48ZCp.js} +1 -1
- package/dist/{cdn/chunks/pt-BR-BmtO0R7k.js → pt-BR-CUIT4rq4.js} +5 -2
- package/dist/{refresh-cw-CR5lenxl.js → refresh-cw-CXZS-R1U.js} +1 -1
- package/dist/{runtime-dom.esm-bundler-BGbPz4-g.js → runtime-dom.esm-bundler-CO67ema2.js} +15 -16
- package/dist/{search-CxRUiOSF.js → search-DSvil0jo.js} +1 -1
- package/dist/{send-Bu2RysGL.js → send-BBR28V94.js} +1 -1
- package/dist/{shield-check-Cg8f4LB0.js → shield-check-ByxUnaU9.js} +1 -1
- package/dist/{smartphone-CHf-8lHp.js → smartphone-CNOwGf5T.js} +1 -1
- package/dist/{socialIcons-D1gkHc_i.js → socialIcons-CvAixjj8.js} +14 -24
- package/dist/{sparkles-_DQGv4ub.js → sparkles-DO1hzwzf.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/templatical-editor.js +70 -107
- package/dist/{text-align-start-PHo-Ep5i.js → text-align-start-BKEKMheq.js} +13 -13
- package/dist/{trash-BxIzHAri.js → trash-CKEQH4vH.js} +1 -1
- package/dist/{triangle-alert-fcb2KoA-.js → triangle-alert-BHnfd3fV.js} +1 -1
- package/dist/{upload-BxBtMPMv.js → upload-C8uO7KsR.js} +1 -1
- package/dist/{useAliveFlag-BkKyhkwZ.js → useAliveFlag-6PtarpNZ.js} +1 -1
- package/dist/{useCloudI18n-DpEsiLeR.js → useCloudI18n-GvIOLziA.js} +2 -2
- package/dist/{useEditorCore-B1CWeFTj.js → useEditorCore-DQSeKPE9.js} +940 -1007
- package/dist/{useEditorRoot-CkB_5d0h.js → useEditorRoot-OWzNpDdT.js} +2 -2
- package/dist/{useI18n-B_CdcBwG.js → useI18n-uF11q85g.js} +2 -2
- package/dist/{useLogicTag-wqfdwYYR.js → useLogicTag-BH87j1vZ.js} +3 -3
- package/dist/{useMergeTag-D3XDE_58.js → useMergeTag-DfPKX2Tk.js} +3 -3
- package/dist/{usePopoverPosition-BYmd-lhR.js → usePopoverPosition-DkBrHfCo.js} +2 -2
- package/dist/{useScrollToBlock-DA_aIJXS.js → useScrollToBlock-Dr7Sb6Tr.js} +3 -3
- package/dist/{vue.runtime.esm-bundler-CyqhBwpY.js → vue.runtime.esm-bundler-CctRY8kr.js} +13 -45
- package/dist/withCurrentFont-DeCbPVaE.js +30 -0
- package/dist/{x-DrZO5tt0.js → x-gEC0yMci.js} +1 -1
- package/package.json +12 -12
- package/dist/TemplateSettings-Bh10NFIN.js +0 -245
- package/dist/cdn/chunks/CountdownToolbar-C9QpHQcv.js.map +0 -1
- package/dist/cdn/chunks/ParagraphEditor-BWfx94pb.js.map +0 -1
- package/dist/cdn/chunks/TemplateSettings-vsFOU0oA.js.map +0 -1
- package/dist/cdn/chunks/Toolbar-CnfNUkOY.js.map +0 -1
- package/dist/cdn/chunks/ca-DES69VJW.js.map +0 -1
- package/dist/cdn/chunks/de-MlrDhC3Y.js.map +0 -1
- package/dist/cdn/chunks/en-6vJh7KCM.js.map +0 -1
- package/dist/cdn/chunks/en-C3n0qWte.js +0 -2
- package/dist/cdn/chunks/es-ewL03EaP.js.map +0 -1
- package/dist/cdn/chunks/fr-D1syuxs1.js.map +0 -1
- package/dist/cdn/chunks/ja-Dd_nytwe.js.map +0 -1
- package/dist/cdn/chunks/nl-DD1t_qxS.js.map +0 -1
- package/dist/cdn/chunks/pt-BR-BmtO0R7k.js.map +0 -1
- package/dist/cdn/chunks/socialIcons-CnUJBZTO.js.map +0 -1
- package/dist/cdn/chunks/src-CjjJWoUZ.js.map +0 -1
- package/dist/cdn/chunks/src-QIGNPFkl.js.map +0 -1
- package/dist/cdn/chunks/useEditorCore-q0G4q-52.js.map +0 -1
- package/dist/cdn/chunks/useEditorRoot-CshefZLP.js +0 -10
- package/dist/en-B-xoKkWi.js +0 -2
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { A as e, B as t, E as n, F as r, H as i, I as a, K as o, N as s, P as c, Q as l, R as u, S as d, U as f, X as p, Y as m, at as h, b as g, c as _, ct as v, et as y, f as b, g as x, h as S, it as C, j as w, k as T, l as E, lt as D, m as O, p as k, q as A, rt as j, s as M, t as N, u as P, ut as F, w as I, x as L, y as R } from "./draggable-
|
|
2
|
-
import { A as z, B, F as V, G as H, H as ee, I as te, J as ne, M as re, N as ie, O as ae, P as oe, R as se, T as ce, V as le, Y as ue, Z as de, _ as fe,
|
|
3
|
-
import { a as
|
|
4
|
-
import { _ as
|
|
5
|
-
import { a as G, c as
|
|
6
|
-
import { $ as
|
|
1
|
+
import { A as e, B as t, E as n, F as r, H as i, I as a, K as o, N as s, P as c, Q as l, R as u, S as d, U as f, X as p, Y as m, at as h, b as g, c as _, ct as v, et as y, f as b, g as x, h as S, it as C, j as w, k as T, l as E, lt as D, m as O, p as k, q as A, rt as j, s as M, t as N, u as P, ut as F, w as I, x as L, y as R } from "./draggable-BUTN5vZC.js";
|
|
2
|
+
import { A as z, B, F as V, G as H, H as ee, I as te, J as ne, M as re, N as ie, O as ae, P as oe, R as se, St as U, T as ce, V as le, Y as ue, Z as de, _ as fe, a as pe, b as me, bt as he, d as ge, f as _e, g as ve, h as ye, ht as be, i as W, j as xe, k as Se, l as Ce, m as we, mt as Te, n as Ee, o as De, p as Oe, pt as ke, q as Ae, r as je, s as Me, u as Ne, ut as Pe, vt as Fe, xt as Ie, yt as Le, z as Re } from "./src-BcqNlDMe.js";
|
|
3
|
+
import { a as ze, b as Be, g as Ve, h as He, i as Ue, m as We, n as Ge, o as Ke, t as qe, v as Je, y as Ye } from "./socialIcons-CsYnPPll.js";
|
|
4
|
+
import { _ as Xe, h as Ze, v as Qe, y as $e } from "./dist-B7W-Lb65.js";
|
|
5
|
+
import { a as G, c as et, i as tt } from "./dist-C5nRd_ua.js";
|
|
6
|
+
import { $ as nt, A as rt, B as it, C as at, D as ot, E as st, F as K, G as ct, H as lt, I as ut, J as dt, K as ft, L as pt, M as mt, N as ht, O as q, P as gt, Q as J, R as _t, S as vt, T as yt, V as bt, X as xt, Y as St, Z as Ct, _ as wt, a as Tt, b as Et, c as Dt, d as Ot, f as kt, g as Y, h as At, j as jt, k as Mt, l as Nt, m as Pt, n as Ft, o as It, p as Lt, q as Rt, r as zt, s as Bt, v as Vt, w as Ht, x as Ut, y as Wt, z as Gt } from "./keys-BKu-LOk5.js";
|
|
7
7
|
import "./timeouts-DHPZQ0G3.js";
|
|
8
|
-
import { t as X } from "./useI18n-
|
|
8
|
+
import { t as X } from "./useI18n-DO4NTunW.js";
|
|
9
9
|
import { t as Z } from "./logger-ByvdoAwq.js";
|
|
10
|
-
import { i as
|
|
11
|
-
import { r as
|
|
12
|
-
import { Bt as
|
|
13
|
-
import { t as
|
|
14
|
-
import { t as
|
|
15
|
-
import { t as
|
|
16
|
-
import "./useCloudI18n-
|
|
17
|
-
import { t as
|
|
18
|
-
import { t as
|
|
19
|
-
import { t as
|
|
10
|
+
import { i as Kt, r as qt, s as Jt, t as Yt } from "./usePopoverPosition-CtVNwoHj.js";
|
|
11
|
+
import { r as Xt, t as Zt } from "./templateSettingsFields-YCFVBVYh.js";
|
|
12
|
+
import { Bt as Qt, Dt as $t, Tt as en, U as tn, Vt as nn, Z as rn, at as an, d as on, f as sn, gt as cn, j as ln, kt as un, nt as dn, o as fn, pt as pn, s as mn, y as hn, yt as gn } from "./icons-Dr9erFGs.js";
|
|
13
|
+
import { t as _n } from "./LoadingTrack-Cg1HRIND.js";
|
|
14
|
+
import { t as vn } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
15
|
+
import { t as yn } from "./useEditorRoot-DDPIcEOO.js";
|
|
16
|
+
import "./useCloudI18n-Cgk0ts_F.js";
|
|
17
|
+
import { t as bn } from "./useMergeTag-hwifK582.js";
|
|
18
|
+
import { t as xn } from "./useLogicTag-91bO_SOi.js";
|
|
19
|
+
import { t as Sn } from "./useAliveFlag-DzyXG-8A.js";
|
|
20
20
|
//#region src/utils/activeEditorTracker.ts
|
|
21
|
-
var
|
|
22
|
-
function
|
|
23
|
-
let e = ++
|
|
24
|
-
return
|
|
21
|
+
var Cn = /* @__PURE__ */ new Set(), Q = 0, wn = 0;
|
|
22
|
+
function Tn() {
|
|
23
|
+
let e = ++wn;
|
|
24
|
+
return Cn.add(e), Q === 0 && (Q = e), {
|
|
25
25
|
id: e,
|
|
26
|
-
isActive: () =>
|
|
26
|
+
isActive: () => Cn.size <= 1 || Q === e,
|
|
27
27
|
claim: () => {
|
|
28
28
|
Q = e;
|
|
29
29
|
},
|
|
30
30
|
dispose: () => {
|
|
31
|
-
if (
|
|
32
|
-
let e = Array.from(
|
|
31
|
+
if (Cn.delete(e), Q === e) {
|
|
32
|
+
let e = Array.from(Cn);
|
|
33
33
|
Q = e[e.length - 1] ?? 0;
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -37,8 +37,8 @@ function Sn() {
|
|
|
37
37
|
}
|
|
38
38
|
//#endregion
|
|
39
39
|
//#region src/composables/usePreviewResolution.ts
|
|
40
|
-
var
|
|
41
|
-
function
|
|
40
|
+
var En = 500;
|
|
41
|
+
function Dn(e) {
|
|
42
42
|
let n = typeof e.resolvePreview == "function", r = l(null), i = l(!1), a = l(!1), o = 0, s = null;
|
|
43
43
|
function c() {
|
|
44
44
|
s !== null && (clearTimeout(s), s = null);
|
|
@@ -55,7 +55,7 @@ function wn(e) {
|
|
|
55
55
|
try {
|
|
56
56
|
let e = await t(s);
|
|
57
57
|
if (n !== o) return;
|
|
58
|
-
if (!
|
|
58
|
+
if (!Ee(e)) {
|
|
59
59
|
a.value = !0;
|
|
60
60
|
return;
|
|
61
61
|
}
|
|
@@ -68,22 +68,12 @@ function wn(e) {
|
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
70
|
function d() {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
return;
|
|
75
|
-
}
|
|
76
|
-
s = setTimeout(() => {
|
|
77
|
-
s = null, u();
|
|
78
|
-
}, Cn);
|
|
79
|
-
}
|
|
71
|
+
n && (c(), r.value === null ? u() : s = setTimeout(() => {
|
|
72
|
+
s = null, u();
|
|
73
|
+
}, En));
|
|
80
74
|
}
|
|
81
75
|
return t(() => [e.isActive(), e.getRecipient?.()], ([e]) => {
|
|
82
|
-
|
|
83
|
-
c(), o++, i.value = !1, r.value = null, a.value = !1;
|
|
84
|
-
return;
|
|
85
|
-
}
|
|
86
|
-
d();
|
|
76
|
+
e ? d() : (c(), o++, i.value = !1, r.value = null, a.value = !1);
|
|
87
77
|
}, { immediate: !0 }), m(() => {
|
|
88
78
|
c(), o++;
|
|
89
79
|
}), {
|
|
@@ -97,7 +87,7 @@ function wn(e) {
|
|
|
97
87
|
}
|
|
98
88
|
//#endregion
|
|
99
89
|
//#region src/composables/useImageUrlResolver.ts
|
|
100
|
-
function
|
|
90
|
+
function On(e) {
|
|
101
91
|
let t = p(/* @__PURE__ */ new Map()), n = /* @__PURE__ */ new Set();
|
|
102
92
|
function r(e) {
|
|
103
93
|
return t.get(e);
|
|
@@ -114,15 +104,11 @@ function Tn(e) {
|
|
|
114
104
|
t.set(r, null);
|
|
115
105
|
return;
|
|
116
106
|
}
|
|
117
|
-
|
|
118
|
-
t.set(r, a);
|
|
119
|
-
return;
|
|
120
|
-
}
|
|
121
|
-
n.add(r), Promise.resolve(a).then((e) => {
|
|
107
|
+
a === null || typeof a == "string" ? t.set(r, a) : (n.add(r), Promise.resolve(a).then((e) => {
|
|
122
108
|
t.set(r, typeof e == "string" ? e : null);
|
|
123
109
|
}, () => {
|
|
124
110
|
t.set(r, null);
|
|
125
|
-
}).finally(() => n.delete(r));
|
|
111
|
+
}).finally(() => n.delete(r)));
|
|
126
112
|
}
|
|
127
113
|
return {
|
|
128
114
|
get: r,
|
|
@@ -130,8 +116,8 @@ function Tn(e) {
|
|
|
130
116
|
lookup: a
|
|
131
117
|
};
|
|
132
118
|
}
|
|
133
|
-
function
|
|
134
|
-
let r = n(
|
|
119
|
+
function kn(e) {
|
|
120
|
+
let r = n(Ut, null), i = b(e);
|
|
135
121
|
if (!r) return i;
|
|
136
122
|
let a;
|
|
137
123
|
function s() {
|
|
@@ -142,15 +128,9 @@ function En(e) {
|
|
|
142
128
|
return t(i, (e) => {
|
|
143
129
|
s();
|
|
144
130
|
let t = c;
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
return;
|
|
149
|
-
}
|
|
150
|
-
a = setTimeout(() => {
|
|
151
|
-
a = void 0, r.lookup(e);
|
|
152
|
-
}, 300);
|
|
153
|
-
}
|
|
131
|
+
c = !1, e && !r.has(e) && (t ? r.lookup(e) : a = setTimeout(() => {
|
|
132
|
+
a = void 0, r.lookup(e);
|
|
133
|
+
}, 300));
|
|
154
134
|
}, { immediate: !0 }), b(() => {
|
|
155
135
|
let e = i.value;
|
|
156
136
|
if (!e) return e;
|
|
@@ -160,7 +140,7 @@ function En(e) {
|
|
|
160
140
|
}
|
|
161
141
|
//#endregion
|
|
162
142
|
//#region src/composables/useMergeTagPicker.ts
|
|
163
|
-
function
|
|
143
|
+
function An() {
|
|
164
144
|
let e = l(!1), t = l([]), n = l(null), r = null;
|
|
165
145
|
function i(i, a) {
|
|
166
146
|
if (r) {
|
|
@@ -191,7 +171,7 @@ function Dn() {
|
|
|
191
171
|
}
|
|
192
172
|
//#endregion
|
|
193
173
|
//#region src/composables/useLogicTagPicker.ts
|
|
194
|
-
function
|
|
174
|
+
function jn() {
|
|
195
175
|
let e = l(!1), t = l([]), n = l([]), r = null;
|
|
196
176
|
function i(i, a) {
|
|
197
177
|
if (r) {
|
|
@@ -222,17 +202,17 @@ function On() {
|
|
|
222
202
|
}
|
|
223
203
|
//#endregion
|
|
224
204
|
//#region src/composables/useTemplateLint.ts
|
|
225
|
-
function
|
|
205
|
+
function Mn(e) {
|
|
226
206
|
return e ? e.disabled === !0 || e.accessibility === !1 && e.structure === !1 && e.links === !1 : !1;
|
|
227
207
|
}
|
|
228
|
-
function
|
|
229
|
-
let n = l([]), r = l(!1), i = l(!1), a = y(null), o =
|
|
208
|
+
function Nn(e) {
|
|
209
|
+
let n = l([]), r = l(!1), i = l(!1), a = y(null), o = Mn(e.options), s = null, c = !1;
|
|
230
210
|
o || u();
|
|
231
211
|
async function u() {
|
|
232
212
|
try {
|
|
233
|
-
let t = await import("./src-
|
|
213
|
+
let t = await import("./src-HA9F2kvk.js");
|
|
234
214
|
if (c) return;
|
|
235
|
-
a.value = { lintTemplate: t.lintTemplate }, r.value = !0, d(), s =
|
|
215
|
+
a.value = { lintTemplate: t.lintTemplate }, r.value = !0, d(), s = $e(e.content, d, {
|
|
236
216
|
debounce: e.debounce ?? 500,
|
|
237
217
|
deep: !0
|
|
238
218
|
});
|
|
@@ -267,7 +247,7 @@ function An(e) {
|
|
|
267
247
|
}
|
|
268
248
|
//#endregion
|
|
269
249
|
//#region src/composables/useKeyboardReorder.ts
|
|
270
|
-
function
|
|
250
|
+
function Pn(e, t, n = []) {
|
|
271
251
|
let r = l(null), i = l(""), a = null;
|
|
272
252
|
function o(t) {
|
|
273
253
|
let n = e.content.value.blocks, r = n.findIndex((e) => e.id === t);
|
|
@@ -294,7 +274,7 @@ function jn(e, t, n = []) {
|
|
|
294
274
|
let i = o(r);
|
|
295
275
|
if (!i) return "";
|
|
296
276
|
let a = (i.sectionId ? c(i.sectionId, i.columnIndex ?? 0) : e.content.value.blocks)?.[i.index];
|
|
297
|
-
return a ?
|
|
277
|
+
return a ? Ke(a, t.t, n) : "";
|
|
298
278
|
}
|
|
299
279
|
function c(t, n) {
|
|
300
280
|
return e.content.value.blocks.find((e) => e.id === t && e.type === "section")?.children[n] ?? null;
|
|
@@ -363,13 +343,13 @@ function jn(e, t, n = []) {
|
|
|
363
343
|
}
|
|
364
344
|
//#endregion
|
|
365
345
|
//#region src/composables/useUiTheme.ts
|
|
366
|
-
function
|
|
367
|
-
let t =
|
|
346
|
+
function Fn(e) {
|
|
347
|
+
let t = et("(prefers-color-scheme: dark)");
|
|
368
348
|
return { resolvedTheme: b(() => e.value === "auto" ? t.value ? "dark" : "light" : e.value) };
|
|
369
349
|
}
|
|
370
350
|
//#endregion
|
|
371
351
|
//#region src/composables/useThemeStyles.ts
|
|
372
|
-
var
|
|
352
|
+
var In = {
|
|
373
353
|
bg: "--tpl-bg",
|
|
374
354
|
bgElevated: "--tpl-bg-elevated",
|
|
375
355
|
bgHover: "--tpl-bg-hover",
|
|
@@ -393,10 +373,10 @@ var Nn = {
|
|
|
393
373
|
dangerLight: "--tpl-danger-light",
|
|
394
374
|
canvasBg: "--tpl-canvas-bg"
|
|
395
375
|
};
|
|
396
|
-
function
|
|
376
|
+
function Ln({ themeOverrides: e, resolvedTheme: t, extraStyles: n }) {
|
|
397
377
|
return { themeStyles: b(() => {
|
|
398
378
|
let r = {}, i = e.value, a = t.value === "dark" ? i.dark : i;
|
|
399
|
-
if (a) for (let [e, t] of Object.entries(
|
|
379
|
+
if (a) for (let [e, t] of Object.entries(In)) {
|
|
400
380
|
let n = a[e];
|
|
401
381
|
n && (r[t] = n);
|
|
402
382
|
}
|
|
@@ -405,7 +385,7 @@ function Pn({ themeOverrides: e, resolvedTheme: t, extraStyles: n }) {
|
|
|
405
385
|
}
|
|
406
386
|
//#endregion
|
|
407
387
|
//#region src/composables/useBlockRegistry.ts
|
|
408
|
-
function
|
|
388
|
+
function Rn() {
|
|
409
389
|
let e = y(/* @__PURE__ */ new Map());
|
|
410
390
|
function t(t, n) {
|
|
411
391
|
e.value.set(t, n), C(e);
|
|
@@ -439,7 +419,7 @@ function Fn() {
|
|
|
439
419
|
let t = a(e.customType);
|
|
440
420
|
if (!t) return o("Block definition not found");
|
|
441
421
|
try {
|
|
442
|
-
let { Liquid: n } = await import("./liquid.browser-
|
|
422
|
+
let { Liquid: n } = await import("./liquid.browser-Bbt17cVz.js");
|
|
443
423
|
return await new n({
|
|
444
424
|
strictVariables: !1,
|
|
445
425
|
strictFilters: !1
|
|
@@ -463,9 +443,9 @@ function Fn() {
|
|
|
463
443
|
}
|
|
464
444
|
//#endregion
|
|
465
445
|
//#region src/composables/useCustomBlockStylesheets.ts
|
|
466
|
-
function
|
|
446
|
+
function zn(e, t) {
|
|
467
447
|
return b(() => {
|
|
468
|
-
let n =
|
|
448
|
+
let n = Bn(e.value.blocks);
|
|
469
449
|
if (n.size === 0) return [];
|
|
470
450
|
let r = /* @__PURE__ */ new Set(), i = [];
|
|
471
451
|
for (let e of n) {
|
|
@@ -477,26 +457,21 @@ function In(e, t) {
|
|
|
477
457
|
return i;
|
|
478
458
|
});
|
|
479
459
|
}
|
|
480
|
-
function
|
|
460
|
+
function Bn(e) {
|
|
481
461
|
let t = /* @__PURE__ */ new Set();
|
|
482
|
-
return
|
|
462
|
+
return Vn(e, t), t;
|
|
483
463
|
}
|
|
484
|
-
function
|
|
485
|
-
for (let n of e)
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
let e = n.children;
|
|
492
|
-
if (!e) continue;
|
|
493
|
-
for (let n of e) Rn(n, t);
|
|
494
|
-
} else Pe(n) && Rn(n.children, t);
|
|
495
|
-
}
|
|
464
|
+
function Vn(e, t) {
|
|
465
|
+
for (let n of e) if (de(n)) t.add(n.customType);
|
|
466
|
+
else if (n.type === "section") {
|
|
467
|
+
let e = n.children;
|
|
468
|
+
if (!e) continue;
|
|
469
|
+
for (let n of e) Vn(n, t);
|
|
470
|
+
} else Pe(n) && Vn(n.children, t);
|
|
496
471
|
}
|
|
497
472
|
//#endregion
|
|
498
473
|
//#region src/utils/registerBuiltInBlocks.ts
|
|
499
|
-
var
|
|
474
|
+
var Hn = [
|
|
500
475
|
{
|
|
501
476
|
type: "section",
|
|
502
477
|
createBlock: te
|
|
@@ -519,7 +494,7 @@ var zn = [
|
|
|
519
494
|
},
|
|
520
495
|
{
|
|
521
496
|
type: "divider",
|
|
522
|
-
createBlock:
|
|
497
|
+
createBlock: xe
|
|
523
498
|
},
|
|
524
499
|
{
|
|
525
500
|
type: "video",
|
|
@@ -539,7 +514,7 @@ var zn = [
|
|
|
539
514
|
},
|
|
540
515
|
{
|
|
541
516
|
type: "spacer",
|
|
542
|
-
createBlock:
|
|
517
|
+
createBlock: Re
|
|
543
518
|
},
|
|
544
519
|
{
|
|
545
520
|
type: "html",
|
|
@@ -547,11 +522,11 @@ var zn = [
|
|
|
547
522
|
},
|
|
548
523
|
{
|
|
549
524
|
type: "countdown",
|
|
550
|
-
createBlock:
|
|
525
|
+
createBlock: Se
|
|
551
526
|
}
|
|
552
527
|
];
|
|
553
|
-
function
|
|
554
|
-
for (let n of
|
|
528
|
+
function Un(e, t) {
|
|
529
|
+
for (let n of Hn) {
|
|
555
530
|
let r = t[n.type];
|
|
556
531
|
r && e.registerBuiltIn(n.type, {
|
|
557
532
|
component: r,
|
|
@@ -561,23 +536,23 @@ function Bn(e, t) {
|
|
|
561
536
|
}
|
|
562
537
|
//#endregion
|
|
563
538
|
//#region src/utils/resolveHtmlBlockPreview.ts
|
|
564
|
-
function
|
|
539
|
+
function Wn(e) {
|
|
565
540
|
return typeof e == "boolean" ? e : e?.enabled ?? !1;
|
|
566
541
|
}
|
|
567
542
|
//#endregion
|
|
568
543
|
//#region src/utils/collectOffPaletteDefaults.ts
|
|
569
|
-
function
|
|
544
|
+
function Gn(e) {
|
|
570
545
|
return typeof e == "object" && !!e && !Array.isArray(e);
|
|
571
546
|
}
|
|
572
|
-
function
|
|
573
|
-
let r = new Set(e.map((e) =>
|
|
574
|
-
for (let [n, o] of Object.entries(e)) typeof o == "string" ? o !== "" && /color$/i.test(n) && !r.has(
|
|
547
|
+
function Kn(e, t, n) {
|
|
548
|
+
let r = new Set(e.map((e) => qt(e))), i = [], a = (e, t) => {
|
|
549
|
+
for (let [n, o] of Object.entries(e)) typeof o == "string" ? o !== "" && /color$/i.test(n) && !r.has(qt(o)) && i.push(`${t}.${n}: ${o}`) : Gn(o) && a(o, `${t}.${n}`);
|
|
575
550
|
}, o = t;
|
|
576
551
|
for (let [e, t] of Object.entries(Ae)) {
|
|
577
552
|
let n = o?.[e];
|
|
578
553
|
a({
|
|
579
554
|
...t,
|
|
580
|
-
...
|
|
555
|
+
...Gn(n) ? n : {}
|
|
581
556
|
}, e);
|
|
582
557
|
}
|
|
583
558
|
return a({
|
|
@@ -587,7 +562,7 @@ function Un(e, t, n) {
|
|
|
587
562
|
}
|
|
588
563
|
//#endregion
|
|
589
564
|
//#region src/utils/localizedBlockDefaults.ts
|
|
590
|
-
function
|
|
565
|
+
function qn(e) {
|
|
591
566
|
return {
|
|
592
567
|
title: { content: `<p>${e.blockDefaults.title}</p>` },
|
|
593
568
|
paragraph: { content: `<p>${e.blockDefaults.paragraph}</p>` },
|
|
@@ -596,59 +571,59 @@ function Wn(e) {
|
|
|
596
571
|
}
|
|
597
572
|
//#endregion
|
|
598
573
|
//#region src/i18n/index.ts
|
|
599
|
-
var
|
|
600
|
-
"./locales/ca.ts": () => import("./ca-
|
|
601
|
-
"./locales/de.ts": () => import("./de-
|
|
602
|
-
"./locales/en.ts": () => import("./en-
|
|
603
|
-
"./locales/es.ts": () => import("./es-
|
|
604
|
-
"./locales/fr.ts": () => import("./fr-
|
|
605
|
-
"./locales/ja.ts": () => import("./ja-
|
|
606
|
-
"./locales/nl.ts": () => import("./nl-
|
|
607
|
-
"./locales/pt-BR.ts": () => import("./pt-BR-
|
|
608
|
-
}),
|
|
574
|
+
var Jn = /* #__PURE__ */ Object.assign({
|
|
575
|
+
"./locales/ca.ts": () => import("./ca-C__Dzq--.js"),
|
|
576
|
+
"./locales/de.ts": () => import("./de-CGjbQ2mt.js"),
|
|
577
|
+
"./locales/en.ts": () => import("./en-BTiiAC-B.js"),
|
|
578
|
+
"./locales/es.ts": () => import("./es-CdTOcSTf.js"),
|
|
579
|
+
"./locales/fr.ts": () => import("./fr-B6lcLLzC.js"),
|
|
580
|
+
"./locales/ja.ts": () => import("./ja-BhdkqENz.js"),
|
|
581
|
+
"./locales/nl.ts": () => import("./nl-CE3YItYg.js"),
|
|
582
|
+
"./locales/pt-BR.ts": () => import("./pt-BR-CUIT4rq4.js")
|
|
583
|
+
}), Yn = /* #__PURE__ */ Object.assign({
|
|
609
584
|
"./locales/cloud/de.ts": () => import("./de-mMY5yQJu.js"),
|
|
610
585
|
"./locales/cloud/en.ts": () => import("./en-ChVeGQBY.js"),
|
|
611
586
|
"./locales/cloud/pt-BR.ts": () => import("./pt-BR-CoCwRUi0.js")
|
|
612
587
|
});
|
|
613
|
-
function
|
|
588
|
+
function Xn(e) {
|
|
614
589
|
return Object.keys(e).map((e) => e.match(/\/([^/]+)\.ts$/)?.[1]).filter((e) => !!e);
|
|
615
590
|
}
|
|
616
|
-
var
|
|
617
|
-
function
|
|
591
|
+
var Zn = Xn(Jn), Qn = Xn(Yn);
|
|
592
|
+
function $n(e) {
|
|
618
593
|
return e.trim().replace(/_/g, "-").toLowerCase();
|
|
619
594
|
}
|
|
620
|
-
function
|
|
621
|
-
let n =
|
|
622
|
-
return t.find((e) =>
|
|
595
|
+
function er(e, t) {
|
|
596
|
+
let n = $n(e);
|
|
597
|
+
return t.find((e) => $n(e) === n);
|
|
623
598
|
}
|
|
624
|
-
function
|
|
625
|
-
return
|
|
599
|
+
function tr(e) {
|
|
600
|
+
return $n(e).split("-")[0];
|
|
626
601
|
}
|
|
627
|
-
function
|
|
628
|
-
return
|
|
602
|
+
function nr(e, t) {
|
|
603
|
+
return er(e, t) ?? er(tr(e), t);
|
|
629
604
|
}
|
|
630
|
-
function
|
|
631
|
-
return
|
|
605
|
+
function rr(e, t) {
|
|
606
|
+
return nr(e, t) ?? "en";
|
|
632
607
|
}
|
|
633
|
-
async function
|
|
634
|
-
let t =
|
|
608
|
+
async function ir(e) {
|
|
609
|
+
let t = Jn[`./locales/${rr(e, Zn)}.ts`];
|
|
635
610
|
return (await t()).default;
|
|
636
611
|
}
|
|
637
|
-
async function
|
|
638
|
-
let t =
|
|
612
|
+
async function ar(e) {
|
|
613
|
+
let t = Yn[`./locales/cloud/${rr(e, Qn)}.ts`];
|
|
639
614
|
return (await t()).default;
|
|
640
615
|
}
|
|
641
|
-
function
|
|
642
|
-
return
|
|
616
|
+
function or(e) {
|
|
617
|
+
return nr(e, Zn) !== void 0;
|
|
643
618
|
}
|
|
644
|
-
function
|
|
645
|
-
return
|
|
619
|
+
function sr(e) {
|
|
620
|
+
return nr(e, Qn) !== void 0;
|
|
646
621
|
}
|
|
647
|
-
function
|
|
648
|
-
return [...
|
|
622
|
+
function cr() {
|
|
623
|
+
return [...Zn];
|
|
649
624
|
}
|
|
650
|
-
function
|
|
651
|
-
return [...
|
|
625
|
+
function lr() {
|
|
626
|
+
return [...Qn];
|
|
652
627
|
}
|
|
653
628
|
//#endregion
|
|
654
629
|
//#region src/i18n/contentDefaults.ts
|
|
@@ -717,16 +692,16 @@ var $ = {
|
|
|
717
692
|
seconds: "秒",
|
|
718
693
|
expired: "このオファーは終了しました"
|
|
719
694
|
}
|
|
720
|
-
},
|
|
721
|
-
function
|
|
695
|
+
}, ur = new Map(Object.keys($).map((e) => [e.toLowerCase(), e]));
|
|
696
|
+
function dr(e) {
|
|
722
697
|
if (!e) return $.en;
|
|
723
|
-
let t = e.trim().replace(/_/g, "-").toLowerCase(), n =
|
|
698
|
+
let t = e.trim().replace(/_/g, "-").toLowerCase(), n = ur.get(t);
|
|
724
699
|
if (n) return $[n];
|
|
725
|
-
let r =
|
|
700
|
+
let r = ur.get(tr(t));
|
|
726
701
|
return r ? $[r] : $.en;
|
|
727
702
|
}
|
|
728
|
-
function
|
|
729
|
-
let t =
|
|
703
|
+
function fr(e) {
|
|
704
|
+
let t = dr(e);
|
|
730
705
|
return {
|
|
731
706
|
video: { alt: t.video },
|
|
732
707
|
countdown: {
|
|
@@ -740,9 +715,9 @@ function lr(e) {
|
|
|
740
715
|
}
|
|
741
716
|
//#endregion
|
|
742
717
|
//#region src/utils/collectColorFieldIssues.ts
|
|
743
|
-
function
|
|
718
|
+
function pr(e, t) {
|
|
744
719
|
let n = [], r = (r, i) => {
|
|
745
|
-
let a =
|
|
720
|
+
let a = ze(r, t), o = `custom block "${e.type}" field "${i}"`, s = (t) => `${e.type}:${i}:${t}`;
|
|
746
721
|
if (a.invalidPresets.length > 0 && n.push({
|
|
747
722
|
id: s("invalid-presets"),
|
|
748
723
|
message: `${o}: presets skipped invalid entries: ${a.invalidPresets.join(", ")} — presets must be hex colors (#rgb or #rrggbb).` + (a.presetsInherited ? " No valid entries are left, so the field inherits colors.presets." : "")
|
|
@@ -753,8 +728,8 @@ function ur(e, t) {
|
|
|
753
728
|
id: s("allow-custom-ignored"),
|
|
754
729
|
message: `${o}: allowCustom: true is ignored because colors.allowCustom is false — a field can narrow the editor-wide palette, never unlock it.`
|
|
755
730
|
}), !a.allowCustom && a.presets.length > 0) {
|
|
756
|
-
let e = r.default ?? "", t = new Set(a.presets.map((e) =>
|
|
757
|
-
e !== "" && !t.has(
|
|
731
|
+
let e = r.default ?? "", t = new Set(a.presets.map((e) => qt(e)));
|
|
732
|
+
e !== "" && !t.has(qt(e)) && n.push({
|
|
758
733
|
id: s("off-palette-default"),
|
|
759
734
|
message: `${o} locks custom colours, but its default ${e} falls outside the field's presets: ${a.presets.join(", ")}. New blocks start on a colour the picker can't reselect — set the default from the same palette.`
|
|
760
735
|
});
|
|
@@ -766,7 +741,7 @@ function ur(e, t) {
|
|
|
766
741
|
}
|
|
767
742
|
//#endregion
|
|
768
743
|
//#region src/utils/keyboardShortcuts.ts
|
|
769
|
-
function
|
|
744
|
+
function mr(e) {
|
|
770
745
|
for (let t of e.composedPath()) {
|
|
771
746
|
if (!(t instanceof HTMLElement)) continue;
|
|
772
747
|
if (t.isContentEditable) return !0;
|
|
@@ -775,75 +750,68 @@ function dr(e) {
|
|
|
775
750
|
}
|
|
776
751
|
return !1;
|
|
777
752
|
}
|
|
778
|
-
function
|
|
753
|
+
function hr(e, t) {
|
|
779
754
|
let n = e.metaKey || e.ctrlKey;
|
|
780
|
-
if (n && e.key.toLowerCase() === "s")
|
|
781
|
-
|
|
782
|
-
return;
|
|
783
|
-
}
|
|
784
|
-
if (n && e.key.toLowerCase() === "z") {
|
|
785
|
-
if (dr(e)) return;
|
|
755
|
+
if (n && e.key.toLowerCase() === "s") e.preventDefault(), t.onSave?.();
|
|
756
|
+
else if (n && e.key.toLowerCase() === "z") {
|
|
757
|
+
if (mr(e)) return;
|
|
786
758
|
e.preventDefault(), e.shiftKey ? t.history.redo() : (t.onBeforeUndo?.(), t.history.undo());
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
759
|
+
} else {
|
|
760
|
+
if (t.isPicking?.() && !mr(e)) {
|
|
761
|
+
if (e.key === "Escape") {
|
|
762
|
+
e.preventDefault(), t.onCancelPick?.();
|
|
763
|
+
return;
|
|
764
|
+
}
|
|
765
|
+
if (e.key === "Enter") {
|
|
766
|
+
e.preventDefault(), t.onConfirmPick?.();
|
|
767
|
+
return;
|
|
768
|
+
}
|
|
769
|
+
if (e.key === "Delete" || e.key === "Backspace") {
|
|
770
|
+
e.preventDefault();
|
|
771
|
+
return;
|
|
772
|
+
}
|
|
801
773
|
}
|
|
774
|
+
e.key === "Escape" ? t.selectBlock(null) : (e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !mr(e) && (e.preventDefault(), t.history.record(), t.removeBlock(t.getSelectedBlockId()));
|
|
802
775
|
}
|
|
803
|
-
if (e.key === "Escape") {
|
|
804
|
-
t.selectBlock(null);
|
|
805
|
-
return;
|
|
806
|
-
}
|
|
807
|
-
(e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !dr(e) && (e.preventDefault(), t.history.record(), t.removeBlock(t.getSelectedBlockId()));
|
|
808
776
|
}
|
|
809
777
|
//#endregion
|
|
810
778
|
//#region src/utils/blockComponentResolver.ts
|
|
811
|
-
function
|
|
779
|
+
function gr(e) {
|
|
812
780
|
let t = { fontFamily: e.fontFamily };
|
|
813
781
|
return e.textColor && (t.color = e.textColor), e.linkColor && (t["--tpl-doc-link-color"] = e.linkColor), e.linkUnderline && (t["--tpl-doc-link-underline"] = "underline"), t;
|
|
814
782
|
}
|
|
815
|
-
function
|
|
783
|
+
function _r(e, t, n) {
|
|
816
784
|
if (t) {
|
|
817
785
|
let n = t.getComponent(e);
|
|
818
786
|
if (n) return n;
|
|
819
787
|
}
|
|
820
788
|
return n[e.type] ?? null;
|
|
821
789
|
}
|
|
822
|
-
function
|
|
790
|
+
function vr(e) {
|
|
823
791
|
if (e.type === "wrapper") return {};
|
|
824
792
|
let { padding: t, backgroundColor: n } = e.styles, r = {
|
|
825
793
|
padding: `${t.top}px ${t.right}px ${t.bottom}px ${t.left}px`,
|
|
826
794
|
backgroundColor: n || "transparent"
|
|
827
795
|
};
|
|
828
|
-
if ((e.type === "paragraph" || e.type === "title") && (r["--tpl-doc-paragraph-spacing"] = `${e.type === "paragraph" ? e.paragraphSpacing ??
|
|
829
|
-
let t =
|
|
830
|
-
t !== null && (r.borderRadius = t), Object.assign(r,
|
|
796
|
+
if ((e.type === "paragraph" || e.type === "title") && (r["--tpl-doc-paragraph-spacing"] = `${e.type === "paragraph" ? e.paragraphSpacing ?? Le.paragraphGap : Le.paragraphGap}px`), e.type === "section") {
|
|
797
|
+
let t = U(e.borderRadius);
|
|
798
|
+
t !== null && (r.borderRadius = t), Object.assign(r, yr(e.border));
|
|
831
799
|
}
|
|
832
800
|
return r;
|
|
833
801
|
}
|
|
834
|
-
function
|
|
802
|
+
function yr(e) {
|
|
835
803
|
let t = {};
|
|
836
|
-
for (let [n, r] of Object.entries(
|
|
804
|
+
for (let [n, r] of Object.entries(Ie(e))) t[n.replace(/-(\w)/g, (e, t) => t.toUpperCase())] = r;
|
|
837
805
|
return t;
|
|
838
806
|
}
|
|
839
|
-
function
|
|
807
|
+
function br(e) {
|
|
840
808
|
if (e.type !== "section" || !e.wrapper) return null;
|
|
841
809
|
let t = e.wrapper, n = {};
|
|
842
810
|
t.backgroundColor && (n.backgroundColor = t.backgroundColor), t.padding && (n.padding = `${t.padding.top}px ${t.padding.right}px ${t.padding.bottom}px ${t.padding.left}px`);
|
|
843
|
-
let r =
|
|
811
|
+
let r = U(t.borderRadius);
|
|
844
812
|
return r !== null && (n.borderRadius = r), n;
|
|
845
813
|
}
|
|
846
|
-
function
|
|
814
|
+
function xr(e) {
|
|
847
815
|
if (e.type !== "wrapper") return null;
|
|
848
816
|
let t = {};
|
|
849
817
|
if (e.styles.backgroundColor && (t.backgroundColor = e.styles.backgroundColor), e.styles.padding) {
|
|
@@ -854,7 +822,7 @@ function vr(e) {
|
|
|
854
822
|
}
|
|
855
823
|
//#endregion
|
|
856
824
|
//#region src/utils/mergeTagLabelSegments.ts
|
|
857
|
-
function
|
|
825
|
+
function Sr(e, t, n, r = !1) {
|
|
858
826
|
if (!e) return [];
|
|
859
827
|
let i = RegExp(`(${n.value.source}|${n.logic.source})`, "g"), a = [], o = 0, s;
|
|
860
828
|
for (; (s = i.exec(e)) !== null;) {
|
|
@@ -867,14 +835,14 @@ function yr(e, t, n, r = !1) {
|
|
|
867
835
|
let e = r ? Me(i, t) : void 0;
|
|
868
836
|
a.push(e === void 0 ? {
|
|
869
837
|
type: "tag",
|
|
870
|
-
value:
|
|
838
|
+
value: De(i, t)
|
|
871
839
|
} : {
|
|
872
840
|
type: "text",
|
|
873
841
|
value: e
|
|
874
842
|
});
|
|
875
843
|
} else ge(i, n) ? a.push({
|
|
876
844
|
type: "tag",
|
|
877
|
-
value:
|
|
845
|
+
value: pe(i, n)
|
|
878
846
|
}) : a.push({
|
|
879
847
|
type: "text",
|
|
880
848
|
value: i
|
|
@@ -888,20 +856,20 @@ function yr(e, t, n, r = !1) {
|
|
|
888
856
|
}
|
|
889
857
|
//#endregion
|
|
890
858
|
//#region src/components/MergeTagPreviewText.vue
|
|
891
|
-
var
|
|
859
|
+
var Cr = d({
|
|
892
860
|
name: "MergeTagPreviewText",
|
|
893
861
|
props: { text: {
|
|
894
862
|
type: String,
|
|
895
863
|
required: !0
|
|
896
864
|
} },
|
|
897
865
|
setup(e) {
|
|
898
|
-
let t = n(q, K), r = n(
|
|
866
|
+
let t = n(q, K), r = n(gt, je.liquid), i = n(J, null), a = b(() => Sr(e.text, t.value, r, i?.value ?? !1));
|
|
899
867
|
return () => a.value.map((e, t) => e.type === "tag" ? I("span", {
|
|
900
868
|
key: t,
|
|
901
869
|
class: "tpl-merge-tag-label"
|
|
902
870
|
}, e.value) : e.value);
|
|
903
871
|
}
|
|
904
|
-
}),
|
|
872
|
+
}), wr = ["href"], Tr = /* @__PURE__ */ d({
|
|
905
873
|
__name: "ButtonBlock",
|
|
906
874
|
props: {
|
|
907
875
|
block: {},
|
|
@@ -917,23 +885,23 @@ var br = d({
|
|
|
917
885
|
fontSize: `${t.block.fontSize}px`,
|
|
918
886
|
fontWeight: "bold",
|
|
919
887
|
textDecoration: "none",
|
|
920
|
-
borderRadius: typeof t.block.borderRadius == "number" ? `${t.block.borderRadius}px` :
|
|
888
|
+
borderRadius: typeof t.block.borderRadius == "number" ? `${t.block.borderRadius}px` : U(t.block.borderRadius) ?? "0px",
|
|
921
889
|
textAlign: "center"
|
|
922
890
|
};
|
|
923
|
-
return Object.assign(e,
|
|
891
|
+
return Object.assign(e, yr(t.block.border)), t.block.fontFamily && (e.fontFamily = t.block.fontFamily), t.block.width === "full" ? (e.display = "block", e.width = "100%", e.boxSizing = "border-box") : typeof t.block.width == "number" && (e.width = `${t.block.width}px`, e.boxSizing = "border-box"), e;
|
|
924
892
|
}), r = b(() => ({ textAlign: t.block.align ?? "center" }));
|
|
925
893
|
return (t, i) => (s(), x("div", { style: D(r.value) }, [k("a", {
|
|
926
894
|
href: e.block.url || "#",
|
|
927
895
|
style: D(n.value),
|
|
928
896
|
class: "tpl:cursor-default",
|
|
929
897
|
onClick: i[0] ||= E(() => {}, ["prevent"])
|
|
930
|
-
}, [g(
|
|
898
|
+
}, [g(Cr, { text: e.block.text }, null, 8, ["text"])], 12, wr)], 4));
|
|
931
899
|
}
|
|
932
|
-
}),
|
|
900
|
+
}), Er = ["innerHTML"], Dr = [
|
|
933
901
|
"src",
|
|
934
902
|
"width",
|
|
935
903
|
"height"
|
|
936
|
-
],
|
|
904
|
+
], Or = /* @__PURE__ */ d({
|
|
937
905
|
__name: "CustomBlockIcon",
|
|
938
906
|
props: {
|
|
939
907
|
icon: {},
|
|
@@ -949,24 +917,24 @@ var br = d({
|
|
|
949
917
|
height: `${n.value}px`
|
|
950
918
|
}),
|
|
951
919
|
innerHTML: e.icon
|
|
952
|
-
}, null, 12,
|
|
920
|
+
}, null, 12, Er)) : i.value ? (s(), x("img", {
|
|
953
921
|
key: 1,
|
|
954
922
|
src: e.icon,
|
|
955
923
|
width: n.value,
|
|
956
924
|
height: n.value,
|
|
957
925
|
class: "tpl:inline-block",
|
|
958
926
|
alt: ""
|
|
959
|
-
}, null, 8,
|
|
927
|
+
}, null, 8, Dr)) : (s(), O(h(Qt), {
|
|
960
928
|
key: 2,
|
|
961
929
|
size: n.value,
|
|
962
930
|
"stroke-width": 1.5
|
|
963
931
|
}, null, 8, ["size"]));
|
|
964
932
|
}
|
|
965
|
-
}),
|
|
966
|
-
function
|
|
967
|
-
let r =
|
|
933
|
+
}), kr = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
|
|
934
|
+
function Ar(e, n) {
|
|
935
|
+
let r = yn(), i = null, a = null, o = null;
|
|
968
936
|
function s() {
|
|
969
|
-
return e.value ? Array.from(e.value.querySelectorAll(
|
|
937
|
+
return e.value ? Array.from(e.value.querySelectorAll(kr)).filter((e) => e.offsetParent !== null) : [];
|
|
970
938
|
}
|
|
971
939
|
function c(e) {
|
|
972
940
|
if (e.key !== "Tab") return;
|
|
@@ -996,8 +964,8 @@ function Dr(e, n) {
|
|
|
996
964
|
}
|
|
997
965
|
//#endregion
|
|
998
966
|
//#region src/composables/useEmoji.ts
|
|
999
|
-
function
|
|
1000
|
-
let [e, n] =
|
|
967
|
+
function jr() {
|
|
968
|
+
let [e, n] = Qe(!1), r = y([]), i = !1;
|
|
1001
969
|
m(() => {
|
|
1002
970
|
i = !0;
|
|
1003
971
|
}), t(e, async (e) => {
|
|
@@ -1022,7 +990,7 @@ function Or() {
|
|
|
1022
990
|
}
|
|
1023
991
|
//#endregion
|
|
1024
992
|
//#region src/composables/useFonts.ts
|
|
1025
|
-
var
|
|
993
|
+
var Mr = [
|
|
1026
994
|
{
|
|
1027
995
|
value: "Arial",
|
|
1028
996
|
label: "Arial"
|
|
@@ -1051,7 +1019,7 @@ var kr = [
|
|
|
1051
1019
|
value: "Courier New",
|
|
1052
1020
|
label: "Courier New"
|
|
1053
1021
|
}
|
|
1054
|
-
],
|
|
1022
|
+
], Nr = {
|
|
1055
1023
|
arial: "Arial, sans-serif",
|
|
1056
1024
|
helvetica: "Helvetica, sans-serif",
|
|
1057
1025
|
georgia: "Georgia, serif",
|
|
@@ -1059,23 +1027,19 @@ var kr = [
|
|
|
1059
1027
|
verdana: "Verdana, sans-serif",
|
|
1060
1028
|
"trebuchet ms": "'Trebuchet MS', sans-serif",
|
|
1061
1029
|
"courier new": "'Courier New', monospace"
|
|
1062
|
-
},
|
|
1063
|
-
function
|
|
1064
|
-
if (e === void 0 || e === !0) return [...
|
|
1030
|
+
}, Pr = "Arial, sans-serif";
|
|
1031
|
+
function Fr(e) {
|
|
1032
|
+
if (e === void 0 || e === !0) return [...Mr];
|
|
1065
1033
|
if (e === !1) return [];
|
|
1066
1034
|
let t = [], n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set();
|
|
1067
1035
|
for (let i of e) {
|
|
1068
|
-
let e = i.toLowerCase(), a =
|
|
1069
|
-
|
|
1070
|
-
r.has(e) || (r.add(e), Z.warn(`config.fonts.builtIns: "${i}" is not a built-in font — skipping it. Built-in fonts are: ${kr.map((e) => e.value).join(", ")}.`));
|
|
1071
|
-
continue;
|
|
1072
|
-
}
|
|
1073
|
-
n.has(a.value) || (n.add(a.value), t.push(a));
|
|
1036
|
+
let e = i.toLowerCase(), a = Mr.find((t) => t.value.toLowerCase() === e);
|
|
1037
|
+
a ? n.has(a.value) || (n.add(a.value), t.push(a)) : r.has(e) || (r.add(e), Z.warn(`config.fonts.builtIns: "${i}" is not a built-in font — skipping it. Built-in fonts are: ${Mr.map((e) => e.value).join(", ")}.`));
|
|
1074
1038
|
}
|
|
1075
1039
|
return t;
|
|
1076
1040
|
}
|
|
1077
|
-
function
|
|
1078
|
-
let t = l(e?.customFonts ?? []), n = l(!1), r =
|
|
1041
|
+
function Ir(e) {
|
|
1042
|
+
let t = l(e?.customFonts ?? []), n = l(!1), r = Fr(e?.builtIns), i = b(() => e?.defaultFallback ?? Pr), a = b(() => {
|
|
1079
1043
|
let e = [...r], n = t.value.map((e) => ({
|
|
1080
1044
|
value: e.name,
|
|
1081
1045
|
label: e.name,
|
|
@@ -1086,20 +1050,20 @@ function Nr(e) {
|
|
|
1086
1050
|
function s(e) {
|
|
1087
1051
|
return a.value.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
|
|
1088
1052
|
}
|
|
1089
|
-
let c = e?.defaultFont ??
|
|
1053
|
+
let c = e?.defaultFont ?? Pr.split(",")[0].trim();
|
|
1090
1054
|
s(c) || Z.warn(`config.fonts: new templates seed "${c}", which the font picker doesn't offer — authors can't reselect it. Either add it to fonts.builtIns, or set fonts.defaultFont to an offered font.`);
|
|
1091
1055
|
function u() {
|
|
1092
1056
|
if (e?.defaultFont && s(e.defaultFont)) {
|
|
1093
1057
|
let t = a.value.find((t) => t.label.toLowerCase() === e.defaultFont.toLowerCase() || t.value.toLowerCase().startsWith(e.defaultFont.toLowerCase()));
|
|
1094
1058
|
if (t) return t.value;
|
|
1095
1059
|
}
|
|
1096
|
-
return
|
|
1060
|
+
return Pr;
|
|
1097
1061
|
}
|
|
1098
1062
|
let d = b(() => u());
|
|
1099
1063
|
function f(e) {
|
|
1100
1064
|
if (!e) return i.value;
|
|
1101
1065
|
let n = t.value.find((t) => t.name.toLowerCase() === e.toLowerCase());
|
|
1102
|
-
return n ? `'${n.name}', ${n.fallback ?? i.value}` :
|
|
1066
|
+
return n ? `'${n.name}', ${n.fallback ?? i.value}` : Nr[e.toLowerCase()] || (e.includes(",") ? e : `${e}, ${i.value}`);
|
|
1103
1067
|
}
|
|
1104
1068
|
let p = [], h = !1;
|
|
1105
1069
|
async function g() {
|
|
@@ -1140,12 +1104,12 @@ function Nr(e) {
|
|
|
1140
1104
|
}
|
|
1141
1105
|
//#endregion
|
|
1142
1106
|
//#region src/utils/mergeTagNodeSpec.ts
|
|
1143
|
-
function
|
|
1107
|
+
function Lr(e, t, n) {
|
|
1144
1108
|
return ge(e, n) ? {
|
|
1145
1109
|
type: "logicMergeTagNode",
|
|
1146
1110
|
attrs: {
|
|
1147
1111
|
value: e,
|
|
1148
|
-
keyword:
|
|
1112
|
+
keyword: pe(e, n)
|
|
1149
1113
|
}
|
|
1150
1114
|
} : {
|
|
1151
1115
|
type: "mergeTagNode",
|
|
@@ -1157,37 +1121,33 @@ function Pr(e, t, n) {
|
|
|
1157
1121
|
}
|
|
1158
1122
|
//#endregion
|
|
1159
1123
|
//#region src/utils/insertLogicTag.ts
|
|
1160
|
-
function
|
|
1124
|
+
function Rr(e) {
|
|
1161
1125
|
return "before" in e && "after" in e;
|
|
1162
1126
|
}
|
|
1163
|
-
function
|
|
1164
|
-
if (!
|
|
1165
|
-
e.chain().focus().insertContent(
|
|
1127
|
+
function zr(e, t, n) {
|
|
1128
|
+
if (!Rr(t)) {
|
|
1129
|
+
e.chain().focus().insertContent(Lr(t.value, t.label, n)).run();
|
|
1166
1130
|
return;
|
|
1167
1131
|
}
|
|
1168
|
-
let r =
|
|
1169
|
-
|
|
1170
|
-
e.chain().focus().insertContentAt(o, i).insertContentAt(a, r).run();
|
|
1171
|
-
return;
|
|
1172
|
-
}
|
|
1173
|
-
e.chain().focus().insertContentAt(a, [r, i]).setTextSelection(a + 1).run();
|
|
1132
|
+
let r = Lr(t.before, t.label, n), i = Lr(t.after, t.label, n), { from: a, to: o } = e.state.selection;
|
|
1133
|
+
a === o ? e.chain().focus().insertContentAt(a, [r, i]).setTextSelection(a + 1).run() : e.chain().focus().insertContentAt(o, i).insertContentAt(a, r).run();
|
|
1174
1134
|
}
|
|
1175
1135
|
//#endregion
|
|
1176
1136
|
//#region src/utils/linkColorExtension.ts
|
|
1177
|
-
function
|
|
1137
|
+
function Br(e) {
|
|
1178
1138
|
if (!e) return null;
|
|
1179
1139
|
let t = e.trim();
|
|
1180
1140
|
return /^#[0-9a-f]{3,8}$/i.test(t) || /^(rgb|rgba|hsl|hsla)\(\s*[0-9.,%/\s]+\)$/i.test(t) || /^[a-z]+$/i.test(t) ? t : null;
|
|
1181
1141
|
}
|
|
1182
|
-
function
|
|
1142
|
+
function Vr(e) {
|
|
1183
1143
|
return e.extend({ addAttributes() {
|
|
1184
1144
|
return {
|
|
1185
1145
|
...this.parent?.(),
|
|
1186
1146
|
color: {
|
|
1187
1147
|
default: null,
|
|
1188
|
-
parseHTML: (e) =>
|
|
1148
|
+
parseHTML: (e) => Br(Kt(e.style.color)),
|
|
1189
1149
|
renderHTML: (e) => {
|
|
1190
|
-
let t =
|
|
1150
|
+
let t = Br(e.color);
|
|
1191
1151
|
return t ? { style: `color: ${t}` } : {};
|
|
1192
1152
|
}
|
|
1193
1153
|
}
|
|
@@ -1196,9 +1156,9 @@ function Rr(e) {
|
|
|
1196
1156
|
}
|
|
1197
1157
|
//#endregion
|
|
1198
1158
|
//#region src/composables/useRichTextLinkDialog.ts
|
|
1199
|
-
function
|
|
1159
|
+
function Hr(e, t = je.liquid) {
|
|
1200
1160
|
let n = l(!1), r = l(""), i = l(""), a = l(null);
|
|
1201
|
-
|
|
1161
|
+
Ar(a, n);
|
|
1202
1162
|
function o() {
|
|
1203
1163
|
let t = e.value?.getAttributes("link") ?? {};
|
|
1204
1164
|
r.value = t.href || "", i.value = t.color || "", n.value = !0;
|
|
@@ -1207,7 +1167,7 @@ function zr(e, t = je.liquid) {
|
|
|
1207
1167
|
if (r.value) {
|
|
1208
1168
|
let t = d(r.value);
|
|
1209
1169
|
if (t !== null) {
|
|
1210
|
-
let n =
|
|
1170
|
+
let n = Br(i.value), r = e.value?.chain().focus().extendMarkRange("link").setLink({ href: t }).updateAttributes("link", { color: n });
|
|
1211
1171
|
n && typeof e.value?.commands.unsetColor == "function" && r?.unsetColor(), r?.run();
|
|
1212
1172
|
}
|
|
1213
1173
|
}
|
|
@@ -1257,13 +1217,13 @@ function zr(e, t = je.liquid) {
|
|
|
1257
1217
|
}
|
|
1258
1218
|
//#endregion
|
|
1259
1219
|
//#region src/composables/useRichTextEditor.ts
|
|
1260
|
-
function
|
|
1261
|
-
let i = n(Y, null), { mergeTags: a, canRequestMergeTag: o, isRequesting: s, requestMergeTag: c, syntax: u, autocomplete: d } =
|
|
1220
|
+
function Ur(r) {
|
|
1221
|
+
let i = n(Y, null), { mergeTags: a, canRequestMergeTag: o, isRequesting: s, requestMergeTag: c, syntax: u, autocomplete: d } = bn(), { canInsertLogicTag: f, isRequesting: p, requestLogicTag: m } = xn(), h = n(St, null), g = (A(h) ? h.value : h)?.mergeTag?.suggestionEmpty ?? "No matching merge tags", _ = Ce(u), v = y(null), b = () => H(i?.content?.value?.settings ?? { locale: "en" });
|
|
1262
1222
|
t(b, (e) => {
|
|
1263
1223
|
let t = v.value?.view.dom;
|
|
1264
1224
|
t && t.setAttribute("dir", e);
|
|
1265
1225
|
});
|
|
1266
|
-
let { showLinkDialog: x, linkUrl: S, linkColor: C, linkDialogRef: w, openLinkDialog: T, insertLink: E, removeLink: D, closeLinkDialog: O, handleLinkKeydown: k } =
|
|
1226
|
+
let { showLinkDialog: x, linkUrl: S, linkColor: C, linkDialogRef: w, openLinkDialog: T, insertLink: E, removeLink: D, closeLinkDialog: O, handleLinkKeydown: k } = Hr(v, u), { start: j, stop: M } = Xe(() => v.value?.commands.focus("end"), 0, { immediate: !1 }), N = y(null), P = l(!0), F = l(null), I = !1;
|
|
1267
1227
|
async function L() {
|
|
1268
1228
|
F.value = null, P.value = !0;
|
|
1269
1229
|
try {
|
|
@@ -1324,7 +1284,7 @@ function Br(r) {
|
|
|
1324
1284
|
}
|
|
1325
1285
|
async function ee() {
|
|
1326
1286
|
let e = await m();
|
|
1327
|
-
I || (e && v.value ?
|
|
1287
|
+
I || (e && v.value ? zr(v.value, e, u) : v.value?.commands.focus());
|
|
1328
1288
|
}
|
|
1329
1289
|
return {
|
|
1330
1290
|
editor: v,
|
|
@@ -1353,9 +1313,9 @@ function Br(r) {
|
|
|
1353
1313
|
}
|
|
1354
1314
|
//#endregion
|
|
1355
1315
|
//#region src/composables/useSmallScreenNotice.ts
|
|
1356
|
-
var
|
|
1357
|
-
function
|
|
1358
|
-
let t =
|
|
1316
|
+
var Wr = "(max-width: 767px)";
|
|
1317
|
+
function Gr(e) {
|
|
1318
|
+
let t = et(Wr);
|
|
1359
1319
|
return {
|
|
1360
1320
|
isSmallScreen: t,
|
|
1361
1321
|
showNotice: b(() => (j(e) ?? !0) && t.value)
|
|
@@ -1363,20 +1323,20 @@ function Hr(e) {
|
|
|
1363
1323
|
}
|
|
1364
1324
|
//#endregion
|
|
1365
1325
|
//#region src/components/blocks/CustomBlock.vue?vue&type=script&setup=true&lang.ts
|
|
1366
|
-
var
|
|
1326
|
+
var Kr = { class: "tpl:w-full" }, qr = {
|
|
1367
1327
|
key: 0,
|
|
1368
1328
|
class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-warning)] tpl:bg-[var(--tpl-warning-light)]"
|
|
1369
|
-
},
|
|
1329
|
+
}, Jr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Yr = {
|
|
1370
1330
|
key: 1,
|
|
1371
1331
|
class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-danger)] tpl:bg-[var(--tpl-danger-light)]"
|
|
1372
|
-
},
|
|
1332
|
+
}, Xr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Zr = {
|
|
1373
1333
|
key: 2,
|
|
1374
1334
|
class: "tpl:relative"
|
|
1375
|
-
},
|
|
1335
|
+
}, Qr = ["innerHTML"], $r = {
|
|
1376
1336
|
key: 0,
|
|
1377
1337
|
class: "tpl:absolute tpl:inset-0 tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-3 tpl:rounded tpl:backdrop-blur-[2px]",
|
|
1378
1338
|
style: { "background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)" }
|
|
1379
|
-
},
|
|
1339
|
+
}, ei = /* @__PURE__ */ d({
|
|
1380
1340
|
__name: "CustomBlock",
|
|
1381
1341
|
props: {
|
|
1382
1342
|
block: {},
|
|
@@ -1384,7 +1344,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1384
1344
|
},
|
|
1385
1345
|
emits: ["fetchData"],
|
|
1386
1346
|
setup(e, { emit: r }) {
|
|
1387
|
-
let i = e, a = r, { t: o } = X(), c = n(
|
|
1347
|
+
let i = e, a = r, { t: o } = X(), c = n(Bt, null), u = l(""), d = l(!1), f = b(() => c?.getDefinition(i.block.customType)), p = b(() => !!f.value), m = b(() => i.block), { isFetching: _, fetch: v, needsFetch: y, hasDataSource: C } = He({
|
|
1388
1348
|
definition: f,
|
|
1389
1349
|
block: m,
|
|
1390
1350
|
onUpdate: (e, t) => {
|
|
@@ -1413,17 +1373,17 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1413
1373
|
}
|
|
1414
1374
|
}
|
|
1415
1375
|
}
|
|
1416
|
-
let M =
|
|
1376
|
+
let M = Ze(j, 150);
|
|
1417
1377
|
return w(() => {
|
|
1418
1378
|
j();
|
|
1419
1379
|
}), t(() => i.block.fieldValues, () => {
|
|
1420
1380
|
M();
|
|
1421
1381
|
}, { deep: !0 }), t(() => D?.value, () => {
|
|
1422
1382
|
M();
|
|
1423
|
-
}), (e, t) => (s(), x("div",
|
|
1383
|
+
}), (e, t) => (s(), x("div", Kr, [p.value ? d.value ? (s(), x("div", Yr, [g(h(on), {
|
|
1424
1384
|
size: 24,
|
|
1425
1385
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
1426
|
-
}), k("span",
|
|
1386
|
+
}), k("span", Xr, F(h(o).customBlocks.renderError), 1)])) : (s(), x("div", Zr, [k("div", { innerHTML: u.value }, null, 8, Qr), h(C) && h(y) ? (s(), x("div", $r, [h(_) ? (s(), O(_n, {
|
|
1427
1387
|
key: 1,
|
|
1428
1388
|
class: "tpl:w-48"
|
|
1429
1389
|
})) : (s(), x("button", {
|
|
@@ -1431,16 +1391,16 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1431
1391
|
type: "button",
|
|
1432
1392
|
class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-2 tpl:text-sm tpl:font-semibold tpl:shadow-[var(--tpl-shadow)] tpl:transition-all tpl:hover:border-[var(--tpl-primary)] tpl:hover:shadow-[var(--tpl-shadow-md)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
1433
1393
|
onClick: t[0] ||= E((...e) => h(v) && h(v)(...e), ["stop"])
|
|
1434
|
-
}, [f.value?.icon ? (s(), O(
|
|
1394
|
+
}, [f.value?.icon ? (s(), O(Or, {
|
|
1435
1395
|
key: 0,
|
|
1436
1396
|
icon: f.value.icon,
|
|
1437
1397
|
size: 16
|
|
1438
|
-
}, null, 8, ["icon"])) : S("", !0), R(" " + F(f.value?.dataSource?.label || h(o).customBlocks.dataSource.fetchButton), 1)]))])) : S("", !0)])) : (s(), x("div",
|
|
1398
|
+
}, null, 8, ["icon"])) : S("", !0), R(" " + F(f.value?.dataSource?.label || h(o).customBlocks.dataSource.fetchButton), 1)]))])) : S("", !0)])) : (s(), x("div", qr, [g(h(tn), {
|
|
1439
1399
|
size: 24,
|
|
1440
1400
|
class: "tpl:text-[var(--tpl-warning)]"
|
|
1441
|
-
}), k("span",
|
|
1401
|
+
}), k("span", Jr, F(h(o).customBlocks.definitionNotFound), 1)]))]));
|
|
1442
1402
|
}
|
|
1443
|
-
}),
|
|
1403
|
+
}), ti = { class: "tpl:w-full" }, ni = /* @__PURE__ */ d({
|
|
1444
1404
|
__name: "DividerBlock",
|
|
1445
1405
|
props: {
|
|
1446
1406
|
block: {},
|
|
@@ -1452,28 +1412,28 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1452
1412
|
width: t.block.width === "full" ? "100%" : typeof t.block.width == "number" ? `${t.block.width}px` : t.block.width,
|
|
1453
1413
|
margin: t.block.width === "full" ? "0" : "0 auto"
|
|
1454
1414
|
}));
|
|
1455
|
-
return (e, t) => (s(), x("div",
|
|
1415
|
+
return (e, t) => (s(), x("div", ti, [k("hr", {
|
|
1456
1416
|
class: "tpl:m-0 tpl:border-none",
|
|
1457
1417
|
style: D(n.value)
|
|
1458
1418
|
}, null, 4)]));
|
|
1459
1419
|
}
|
|
1460
|
-
}),
|
|
1420
|
+
}), ri = { class: "tpl:w-full" }, ii = ["srcdoc", "title"], ai = {
|
|
1461
1421
|
key: 1,
|
|
1462
1422
|
class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)]"
|
|
1463
|
-
},
|
|
1423
|
+
}, oi = {
|
|
1464
1424
|
key: 0,
|
|
1465
1425
|
class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]"
|
|
1466
|
-
},
|
|
1426
|
+
}, si = {
|
|
1467
1427
|
key: 1,
|
|
1468
1428
|
class: "tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
|
|
1469
|
-
},
|
|
1429
|
+
}, ci = /* @__PURE__ */ d({
|
|
1470
1430
|
__name: "HtmlBlock",
|
|
1471
1431
|
props: {
|
|
1472
1432
|
block: {},
|
|
1473
1433
|
viewport: {}
|
|
1474
1434
|
},
|
|
1475
1435
|
setup(r) {
|
|
1476
|
-
let i = r, { t: a } = X(), o = n(
|
|
1436
|
+
let i = r, { t: a } = X(), o = n(Et, !1), c = b(() => i.block.content.trim().length > 0), u = b(() => o && c.value), d = n(q, K), f = n(J, null), p = b(() => f?.value ? fe(i.block.content, d.value) : i.block.content), m = l(null), _ = l(60), v = null;
|
|
1477
1437
|
function y() {
|
|
1478
1438
|
let e = m.value?.contentDocument;
|
|
1479
1439
|
e && (_.value = Math.max(e.body?.scrollHeight ?? 0, e.documentElement?.scrollHeight ?? 0));
|
|
@@ -1487,7 +1447,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1487
1447
|
e || (v?.disconnect(), v = null);
|
|
1488
1448
|
}), e(() => {
|
|
1489
1449
|
v?.disconnect(), v = null;
|
|
1490
|
-
}), (e, t) => (s(), x("div",
|
|
1450
|
+
}), (e, t) => (s(), x("div", ri, [u.value ? (s(), x("iframe", {
|
|
1491
1451
|
key: 0,
|
|
1492
1452
|
ref_key: "iframeRef",
|
|
1493
1453
|
ref: m,
|
|
@@ -1497,22 +1457,22 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1497
1457
|
class: "tpl:block tpl:w-full tpl:border-0",
|
|
1498
1458
|
style: D({ height: `${_.value}px` }),
|
|
1499
1459
|
onLoad: S
|
|
1500
|
-
}, null, 44,
|
|
1460
|
+
}, null, 44, ii)) : (s(), x("div", ai, [g(h(un), {
|
|
1501
1461
|
size: 24,
|
|
1502
1462
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
1503
|
-
}), c.value ? (s(), x("span",
|
|
1463
|
+
}), c.value ? (s(), x("span", oi, F(h(a).html.preview), 1)) : (s(), x("span", si, F(h(a).html.empty), 1))]))]));
|
|
1504
1464
|
}
|
|
1505
|
-
}),
|
|
1465
|
+
}), li = ["data-drop-enabled"], ui = {
|
|
1506
1466
|
key: 0,
|
|
1507
1467
|
class: "tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-10 tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-xs tpl:font-medium tpl:border-[var(--tpl-primary)] tpl:text-[var(--tpl-primary)]",
|
|
1508
1468
|
style: { "background-color": "color-mix(in srgb, var(--tpl-bg) 85%, transparent)" }
|
|
1509
|
-
},
|
|
1469
|
+
}, di = ["href"], fi = ["src", "alt"], pi = ["src", "alt"], mi = {
|
|
1510
1470
|
class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
|
|
1511
1471
|
style: { opacity: "0.7" }
|
|
1512
|
-
},
|
|
1472
|
+
}, hi = ["href"], gi = ["src", "alt"], _i = ["src", "alt"], vi = {
|
|
1513
1473
|
key: 4,
|
|
1514
1474
|
class: "tpl:flex tpl:min-h-[100px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
|
|
1515
|
-
},
|
|
1475
|
+
}, yi = ["aria-label"], bi = { key: 1 }, xi = /* @__PURE__ */ d({
|
|
1516
1476
|
__name: "ImageBlock",
|
|
1517
1477
|
props: {
|
|
1518
1478
|
block: {},
|
|
@@ -1520,7 +1480,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1520
1480
|
},
|
|
1521
1481
|
emits: ["update"],
|
|
1522
1482
|
setup(e, { emit: t }) {
|
|
1523
|
-
let r = e, i = t, { t: a } = X(), { syntax: o } =
|
|
1483
|
+
let r = e, i = t, { t: a } = X(), { syntax: o } = bn(), c = n(pt, null), u = n(Dt, null), d = b(() => !!c), f = Sn();
|
|
1524
1484
|
async function p() {
|
|
1525
1485
|
let e = await c?.({ accept: ["images"] });
|
|
1526
1486
|
if (f.alive && e) {
|
|
@@ -1547,12 +1507,12 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1547
1507
|
}
|
|
1548
1508
|
}
|
|
1549
1509
|
}
|
|
1550
|
-
let { isOver: C } =
|
|
1510
|
+
let { isOver: C } = Ue({
|
|
1551
1511
|
target: m,
|
|
1552
1512
|
enabled: v,
|
|
1553
1513
|
onFiles: y
|
|
1554
1514
|
}), w = b(() => ({ textAlign: r.block.align })), T = b(() => {
|
|
1555
|
-
let e = r.block.border, t = ["left", "right"].map((t) =>
|
|
1515
|
+
let e = r.block.border, t = ["left", "right"].map((t) => he(e?.[t]) === null ? 0 : e[t].width).reduce((e, t) => e + t, 0);
|
|
1556
1516
|
return t > 0 ? `calc(100% - ${t}px)` : "100%";
|
|
1557
1517
|
}), O = b(() => {
|
|
1558
1518
|
let e = r.block.align;
|
|
@@ -1560,13 +1520,13 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1560
1520
|
maxWidth: "100%",
|
|
1561
1521
|
width: r.block.width === "full" ? T.value : `${r.block.width}px`,
|
|
1562
1522
|
height: r.block.height ? `${r.block.height}px` : void 0,
|
|
1563
|
-
borderRadius:
|
|
1564
|
-
...
|
|
1523
|
+
borderRadius: U(r.block.borderRadius) ?? void 0,
|
|
1524
|
+
...yr(r.block.border),
|
|
1565
1525
|
display: "block",
|
|
1566
1526
|
marginLeft: e === "center" || e === "right" ? "auto" : void 0,
|
|
1567
1527
|
marginRight: e === "center" ? "auto" : void 0
|
|
1568
1528
|
};
|
|
1569
|
-
}), A = b(() =>
|
|
1529
|
+
}), A = b(() => W(r.block.src, o)), j = kn(() => A.value ? void 0 : r.block.src), M = kn(() => A.value ? r.block.placeholderUrl : void 0);
|
|
1570
1530
|
return (t, n) => (s(), x("div", {
|
|
1571
1531
|
ref_key: "dropZoneRef",
|
|
1572
1532
|
ref: m,
|
|
@@ -1574,11 +1534,11 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1574
1534
|
"data-drop-enabled": v.value,
|
|
1575
1535
|
class: "tpl:relative tpl:w-full",
|
|
1576
1536
|
style: D(w.value)
|
|
1577
|
-
}, [v.value && (h(C) || _.value) ? (s(), x("div",
|
|
1537
|
+
}, [v.value && (h(C) || _.value) ? (s(), x("div", ui, [_.value ? (s(), x(P, { key: 0 }, [g(h(an), {
|
|
1578
1538
|
class: "tpl-spinner",
|
|
1579
1539
|
size: 20,
|
|
1580
1540
|
"stroke-width": 2
|
|
1581
|
-
}), R(" " + F(h(a).image.uploading), 1)], 64)) : (s(), x(P, { key: 1 }, [g(h(
|
|
1541
|
+
}), R(" " + F(h(a).image.uploading), 1)], 64)) : (s(), x(P, { key: 1 }, [g(h(mn), {
|
|
1582
1542
|
size: 20,
|
|
1583
1543
|
"stroke-width": 1.5
|
|
1584
1544
|
}), R(" " + F(h(a).image.dropToUpload), 1)], 64))])) : S("", !0), e.block.src && A.value && e.block.placeholderUrl ? (s(), x(P, { key: 1 }, [e.block.linkUrl ? (s(), x("a", {
|
|
@@ -1593,22 +1553,22 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1593
1553
|
src: h(M),
|
|
1594
1554
|
alt: e.block.alt || h(a).image.altTextPlaceholder,
|
|
1595
1555
|
style: D(O.value)
|
|
1596
|
-
}, null, 12,
|
|
1556
|
+
}, null, 12, fi)], 8, di)) : (s(), x("img", {
|
|
1597
1557
|
key: 1,
|
|
1598
1558
|
class: "tpl:border-0",
|
|
1599
1559
|
src: h(M),
|
|
1600
1560
|
alt: e.block.alt,
|
|
1601
1561
|
style: D(O.value)
|
|
1602
|
-
}, null, 12,
|
|
1562
|
+
}, null, 12, pi))], 64)) : e.block.src && A.value ? (s(), x("div", {
|
|
1603
1563
|
key: 2,
|
|
1604
1564
|
class: "tpl:!flex tpl:min-h-[120px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
|
|
1605
1565
|
style: D([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, O.value])
|
|
1606
|
-
}, [g(h(
|
|
1566
|
+
}, [g(h(pn), {
|
|
1607
1567
|
size: 32,
|
|
1608
1568
|
"stroke-width": 1.5,
|
|
1609
1569
|
class: "tpl:text-[var(--tpl-primary)]",
|
|
1610
1570
|
style: { opacity: "0.5" }
|
|
1611
|
-
}), k("span",
|
|
1571
|
+
}), k("span", mi, [g(Cr, { text: e.block.src }, null, 8, ["text"])])], 4)) : e.block.src ? (s(), x(P, { key: 3 }, [e.block.linkUrl ? (s(), x("a", {
|
|
1612
1572
|
key: 0,
|
|
1613
1573
|
href: e.block.linkUrl,
|
|
1614
1574
|
target: "_blank",
|
|
@@ -1620,26 +1580,26 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1620
1580
|
src: h(j),
|
|
1621
1581
|
alt: e.block.alt || h(a).image.altTextPlaceholder,
|
|
1622
1582
|
style: D(O.value)
|
|
1623
|
-
}, null, 12,
|
|
1583
|
+
}, null, 12, gi)], 8, hi)) : (s(), x("img", {
|
|
1624
1584
|
key: 1,
|
|
1625
1585
|
class: "tpl:border-0",
|
|
1626
1586
|
src: h(j),
|
|
1627
1587
|
alt: e.block.alt,
|
|
1628
1588
|
style: D(O.value)
|
|
1629
|
-
}, null, 12,
|
|
1589
|
+
}, null, 12, _i))], 64)) : (s(), x("div", vi, [d.value ? (s(), x("button", {
|
|
1630
1590
|
key: 0,
|
|
1631
1591
|
"aria-label": h(a).image.browseMedia,
|
|
1632
1592
|
class: "tpl:flex tpl:items-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:cursor-pointer tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)] tpl:bg-[var(--tpl-bg)]",
|
|
1633
1593
|
onClick: E(p, ["stop"])
|
|
1634
|
-
}, [g(h(
|
|
1594
|
+
}, [g(h(pn), {
|
|
1635
1595
|
size: 14,
|
|
1636
1596
|
"stroke-width": 1.5
|
|
1637
|
-
}), R(" " + F(h(a).image.browseMedia), 1)], 8,
|
|
1597
|
+
}), R(" " + F(h(a).image.browseMedia), 1)], 8, yi)) : (s(), x("span", bi, F(h(a).image.clickToAdd), 1))]))], 12, li));
|
|
1638
1598
|
}
|
|
1639
|
-
}),
|
|
1599
|
+
}), Si = { class: "tpl:w-full" }, Ci = ["href"], wi = {
|
|
1640
1600
|
key: 1,
|
|
1641
1601
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
1642
|
-
},
|
|
1602
|
+
}, Ti = /* @__PURE__ */ d({
|
|
1643
1603
|
__name: "MenuBlock",
|
|
1644
1604
|
props: {
|
|
1645
1605
|
block: {},
|
|
@@ -1658,7 +1618,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1658
1618
|
function o(e) {
|
|
1659
1619
|
return e || t.block.linkColor || t.block.color;
|
|
1660
1620
|
}
|
|
1661
|
-
return (t, c) => (s(), x("div",
|
|
1621
|
+
return (t, c) => (s(), x("div", Si, [a.value ? (s(), x("div", {
|
|
1662
1622
|
key: 0,
|
|
1663
1623
|
style: D(i.value)
|
|
1664
1624
|
}, [(s(!0), x(P, null, r(e.block.items, (t, n) => (s(), x(P, { key: t.id }, [k("a", {
|
|
@@ -1670,15 +1630,15 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1670
1630
|
textDecoration: t.underline ? "underline" : "none"
|
|
1671
1631
|
}),
|
|
1672
1632
|
onClick: c[0] ||= E(() => {}, ["prevent"])
|
|
1673
|
-
}, [g(
|
|
1633
|
+
}, [g(Cr, { text: t.text || "..." }, null, 8, ["text"])], 12, Ci), n < e.block.items.length - 1 ? (s(), x("span", {
|
|
1674
1634
|
key: 0,
|
|
1675
1635
|
style: D({
|
|
1676
1636
|
color: e.block.separatorColor,
|
|
1677
1637
|
padding: `0 ${e.block.spacing}px`
|
|
1678
1638
|
})
|
|
1679
|
-
}, F(e.block.separator), 5)) : S("", !0)], 64))), 128))], 4)) : (s(), x("div",
|
|
1639
|
+
}, F(e.block.separator), 5)) : S("", !0)], 64))), 128))], 4)) : (s(), x("div", wi, [g(h(rn), { size: 16 }), k("span", null, F(h(n).menu.addLinks), 1)]))]));
|
|
1680
1640
|
}
|
|
1681
|
-
}),
|
|
1641
|
+
}), Ei = /* @__PURE__ */ new Set([
|
|
1682
1642
|
"http",
|
|
1683
1643
|
"https",
|
|
1684
1644
|
"mailto",
|
|
@@ -1688,7 +1648,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1688
1648
|
"sms",
|
|
1689
1649
|
"xmpp",
|
|
1690
1650
|
"cid"
|
|
1691
|
-
]),
|
|
1651
|
+
]), Di = /* @__PURE__ */ new Set([
|
|
1692
1652
|
"SCRIPT",
|
|
1693
1653
|
"STYLE",
|
|
1694
1654
|
"IFRAME",
|
|
@@ -1698,7 +1658,7 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1698
1658
|
"META",
|
|
1699
1659
|
"BASE",
|
|
1700
1660
|
"FORM"
|
|
1701
|
-
]),
|
|
1661
|
+
]), Oi = /* @__PURE__ */ new Set([
|
|
1702
1662
|
"href",
|
|
1703
1663
|
"xlink:href",
|
|
1704
1664
|
"formaction",
|
|
@@ -1707,16 +1667,16 @@ var Ur = { class: "tpl:w-full" }, Wr = {
|
|
|
1707
1667
|
"background",
|
|
1708
1668
|
"poster"
|
|
1709
1669
|
]);
|
|
1710
|
-
function
|
|
1670
|
+
function ki(e, t) {
|
|
1711
1671
|
let n = e.replace(/[\t\n\r]/g, "").replace(/^[\u0000-\u0020]+/, "").trimEnd();
|
|
1712
1672
|
if (!n || n.startsWith("#")) return !0;
|
|
1713
1673
|
let r = /^([a-z][a-z0-9+.-]*):/i.exec(n);
|
|
1714
1674
|
if (!r) return !0;
|
|
1715
1675
|
let i = r[1].toLowerCase();
|
|
1716
|
-
return
|
|
1676
|
+
return Ei.has(i) ? !0 : t && i === "data" ? /^data:image\/(png|jpe?g|gif|webp|svg\+xml);/i.test(n) : !1;
|
|
1717
1677
|
}
|
|
1718
|
-
function
|
|
1719
|
-
if (
|
|
1678
|
+
function Ai(e) {
|
|
1679
|
+
if (Di.has(e.tagName)) {
|
|
1720
1680
|
e.remove();
|
|
1721
1681
|
return;
|
|
1722
1682
|
}
|
|
@@ -1724,33 +1684,21 @@ function Di(e) {
|
|
|
1724
1684
|
for (let n = 0; n < e.attributes.length; n++) t.push(e.attributes[n].name);
|
|
1725
1685
|
for (let n of t) {
|
|
1726
1686
|
let t = n.toLowerCase();
|
|
1727
|
-
|
|
1728
|
-
e.removeAttribute(n);
|
|
1729
|
-
continue;
|
|
1730
|
-
}
|
|
1731
|
-
if (Ti.has(t)) {
|
|
1732
|
-
Ei(e.getAttribute(n) ?? "", !1) || e.removeAttribute(n);
|
|
1733
|
-
continue;
|
|
1734
|
-
}
|
|
1735
|
-
if (t === "src") {
|
|
1736
|
-
Ei(e.getAttribute(n) ?? "", !0) || e.removeAttribute(n);
|
|
1737
|
-
continue;
|
|
1738
|
-
}
|
|
1739
|
-
t === "srcdoc" && e.removeAttribute(n);
|
|
1687
|
+
t.startsWith("on") ? e.removeAttribute(n) : Oi.has(t) ? ki(e.getAttribute(n) ?? "", !1) || e.removeAttribute(n) : t === "src" ? ki(e.getAttribute(n) ?? "", !0) || e.removeAttribute(n) : t === "srcdoc" && e.removeAttribute(n);
|
|
1740
1688
|
}
|
|
1741
1689
|
let n = Array.from(e.children);
|
|
1742
|
-
for (let e of n)
|
|
1690
|
+
for (let e of n) Ai(e);
|
|
1743
1691
|
}
|
|
1744
|
-
function
|
|
1692
|
+
function ji(e) {
|
|
1745
1693
|
if (typeof DOMParser > "u") return e;
|
|
1746
1694
|
let t = new DOMParser().parseFromString(`<!doctype html><body>${e}</body>`, "text/html").body, n = Array.from(t.children);
|
|
1747
|
-
for (let e of n)
|
|
1695
|
+
for (let e of n) Ai(e);
|
|
1748
1696
|
return t.innerHTML;
|
|
1749
1697
|
}
|
|
1750
1698
|
//#endregion
|
|
1751
1699
|
//#region src/composables/useEditableTextBlock.ts
|
|
1752
|
-
function
|
|
1753
|
-
let t = n(q, K), r = n(J, null), { syntax: i } =
|
|
1700
|
+
function Mi(e) {
|
|
1701
|
+
let t = n(q, K), r = n(J, null), { syntax: i } = bn(), a = b(() => r?.value ? ve(e(), t.value) : we(e(), t.value)), o = b(() => ji(Oe(a.value, i))), s = l(!1), c = l(null), { top: u, left: d } = tt(c), { toLocal: f } = Yt(), p = b(() => f({
|
|
1754
1702
|
top: u.value - 8,
|
|
1755
1703
|
left: d.value
|
|
1756
1704
|
}));
|
|
@@ -1771,14 +1719,14 @@ function ki(e) {
|
|
|
1771
1719
|
}
|
|
1772
1720
|
//#endregion
|
|
1773
1721
|
//#region src/components/blocks/ParagraphBlock.vue?vue&type=script&setup=true&lang.ts
|
|
1774
|
-
var
|
|
1722
|
+
var Ni = ["innerHTML"], Pi = /* @__PURE__ */ d({
|
|
1775
1723
|
__name: "ParagraphBlock",
|
|
1776
1724
|
props: {
|
|
1777
1725
|
block: {},
|
|
1778
1726
|
viewport: {}
|
|
1779
1727
|
},
|
|
1780
1728
|
setup(e) {
|
|
1781
|
-
let t = e, n = L(() => import("./ParagraphEditor-
|
|
1729
|
+
let t = e, n = L(() => import("./ParagraphEditor-B5DN4Sy4.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: c, handleEditorDone: l } = Mi(() => t.block.content);
|
|
1782
1730
|
return (t, u) => (s(), x("div", {
|
|
1783
1731
|
ref_key: "blockRef",
|
|
1784
1732
|
ref: i,
|
|
@@ -1797,26 +1745,26 @@ var Ai = ["innerHTML"], ji = /* @__PURE__ */ d({
|
|
|
1797
1745
|
key: 1,
|
|
1798
1746
|
class: "tpl-text-content tpl:outline-none",
|
|
1799
1747
|
innerHTML: h(o)
|
|
1800
|
-
}, null, 8,
|
|
1748
|
+
}, null, 8, Ni))], 544));
|
|
1801
1749
|
}
|
|
1802
|
-
}),
|
|
1750
|
+
}), Fi = [
|
|
1803
1751
|
"data-block-id",
|
|
1804
1752
|
"data-block-type",
|
|
1805
1753
|
"data-tpl-picked"
|
|
1806
|
-
],
|
|
1754
|
+
], Ii = ["aria-label"], Li = [
|
|
1807
1755
|
"aria-label",
|
|
1808
1756
|
"aria-pressed",
|
|
1809
1757
|
"title"
|
|
1810
|
-
],
|
|
1758
|
+
], Ri = ["aria-label", "title"], zi = ["aria-label", "title"], Bi = ["aria-label", "title"], Vi = {
|
|
1811
1759
|
key: 1,
|
|
1812
1760
|
class: "tpl-block-hidden-overlay tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-[5] tpl:flex tpl:items-center tpl:justify-center tpl:rounded-sm"
|
|
1813
|
-
},
|
|
1761
|
+
}, Hi = { class: "tpl:flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-2 tpl:py-1 tpl:text-[10px] tpl:font-medium tpl:bg-[var(--tpl-chrome-bg-elevated)] tpl:text-[var(--tpl-chrome-text-muted)] tpl:shadow-[var(--tpl-shadow-sm)]" }, Ui = {
|
|
1814
1762
|
key: 2,
|
|
1815
1763
|
class: "tpl:absolute tpl:-left-1 tpl:top-1/2 tpl:z-[5] tpl:-translate-x-full tpl:-translate-y-1/2"
|
|
1816
|
-
},
|
|
1764
|
+
}, Wi = ["aria-label", "title"], Gi = {
|
|
1817
1765
|
key: 3,
|
|
1818
1766
|
class: "tpl:absolute tpl:-right-1 tpl:-top-1 tpl:z-[5] tpl:translate-x-full"
|
|
1819
|
-
},
|
|
1767
|
+
}, Ki = ["aria-label"], qi = /*#__PURE__*/ vn(/* @__PURE__ */ d({
|
|
1820
1768
|
__name: "BlockWrapper",
|
|
1821
1769
|
props: {
|
|
1822
1770
|
block: {},
|
|
@@ -1828,33 +1776,17 @@ var Ai = ["innerHTML"], ji = /* @__PURE__ */ d({
|
|
|
1828
1776
|
},
|
|
1829
1777
|
emits: ["select"],
|
|
1830
1778
|
setup(e, { emit: t }) {
|
|
1831
|
-
let r = L(() => import("./BlockIssueBadge-
|
|
1779
|
+
let r = L(() => import("./BlockIssueBadge-05Q3L4RV.js")), i = e, o = t, { t: c, format: u } = X(), d = n(vt, null), f = l(null), p = b(() => d?.liftedBlockId.value === i.block.id), m = b(() => p.value ? u(c.blockActions.dragLifted, { block: i.block.type }) : c.blockActions.drag);
|
|
1832
1780
|
async function _() {
|
|
1833
1781
|
await T(), f.value?.focus();
|
|
1834
1782
|
}
|
|
1835
1783
|
function y(e) {
|
|
1836
|
-
|
|
1837
|
-
if (e.key === " " || e.key === "Enter") {
|
|
1838
|
-
e.preventDefault(), e.stopPropagation(), p.value ? d.drop(i.block.id) : d.lift(i.block.id);
|
|
1839
|
-
return;
|
|
1840
|
-
}
|
|
1841
|
-
if (p.value) {
|
|
1842
|
-
if (e.key === "Escape") {
|
|
1843
|
-
e.preventDefault(), e.stopPropagation(), d.cancel(), _();
|
|
1844
|
-
return;
|
|
1845
|
-
}
|
|
1846
|
-
if (e.key === "ArrowUp") {
|
|
1847
|
-
e.preventDefault(), e.stopPropagation(), d.moveUp(i.block.id), _();
|
|
1848
|
-
return;
|
|
1849
|
-
}
|
|
1850
|
-
e.key === "ArrowDown" && (e.preventDefault(), e.stopPropagation(), d.moveDown(i.block.id), _());
|
|
1851
|
-
}
|
|
1852
|
-
}
|
|
1784
|
+
d && (e.key === " " || e.key === "Enter" ? (e.preventDefault(), e.stopPropagation(), p.value ? d.drop(i.block.id) : d.lift(i.block.id)) : p.value && (e.key === "Escape" ? (e.preventDefault(), e.stopPropagation(), d.cancel(), _()) : e.key === "ArrowUp" ? (e.preventDefault(), e.stopPropagation(), d.moveUp(i.block.id), _()) : e.key === "ArrowDown" && (e.preventDefault(), e.stopPropagation(), d.moveDown(i.block.id), _())));
|
|
1853
1785
|
}
|
|
1854
1786
|
let C = b(() => !i.viewport || !i.block.visibility ? !1 : i.block.visibility[i.viewport] === !1), w = b(() => i.previewMode === !0 && C.value), O = b(() => i.viewport ? {
|
|
1855
1787
|
desktop: c.viewport.desktop,
|
|
1856
1788
|
mobile: c.viewport.mobile
|
|
1857
|
-
}[i.viewport] ?? i.viewport : ""), A = b(() => !!i.block.displayCondition), j = n(
|
|
1789
|
+
}[i.viewport] ?? i.viewport : ""), A = b(() => !!i.block.displayCondition), j = n(Tt, null), M = n(kt, null), N = n(Nt, {}), P = b(() => N.savedBlocks?.isPicking.value === !0), I = b(() => !i.nested && N.savedBlocks?.isAvailable.value === !0 && N.savedBlocks?.canCreate.value === !0), z = b(() => i.isSelected && !P.value), B = b(() => N.comments?.getBlockCount(i.block.id) ?? 0), V = b(() => vr(i.block)), H = b(() => br(i.block));
|
|
1858
1790
|
function ee(e) {
|
|
1859
1791
|
i.previewMode || (e.target?.closest("a") && e.preventDefault(), e.stopPropagation(), o("select"));
|
|
1860
1792
|
}
|
|
@@ -1899,61 +1831,61 @@ var Ai = ["innerHTML"], ji = /* @__PURE__ */ d({
|
|
|
1899
1831
|
"aria-keyshortcuts": "Space Enter ArrowUp ArrowDown Escape",
|
|
1900
1832
|
title: h(c).blockActions.drag,
|
|
1901
1833
|
onKeydown: y
|
|
1902
|
-
}, [g(h(
|
|
1834
|
+
}, [g(h(cn), {
|
|
1903
1835
|
size: 14,
|
|
1904
1836
|
"stroke-width": 1.5
|
|
1905
|
-
})], 40,
|
|
1837
|
+
})], 40, Li),
|
|
1906
1838
|
k("button", {
|
|
1907
1839
|
class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors",
|
|
1908
1840
|
"aria-label": h(c).blockActions.duplicate,
|
|
1909
1841
|
title: h(c).blockActions.duplicate,
|
|
1910
1842
|
onClick: E(ne, ["stop"])
|
|
1911
|
-
}, [g(h(
|
|
1843
|
+
}, [g(h($t), {
|
|
1912
1844
|
size: 14,
|
|
1913
1845
|
"stroke-width": 1.5
|
|
1914
|
-
})], 8,
|
|
1846
|
+
})], 8, Ri),
|
|
1915
1847
|
I.value ? (s(), x("button", {
|
|
1916
1848
|
key: 0,
|
|
1917
1849
|
class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors",
|
|
1918
1850
|
"aria-label": h(c).blockActions.saveAsBlock,
|
|
1919
1851
|
title: h(c).blockActions.saveAsBlock,
|
|
1920
1852
|
onClick: E(re, ["stop"])
|
|
1921
|
-
}, [g(h(
|
|
1853
|
+
}, [g(h(nn), {
|
|
1922
1854
|
size: 14,
|
|
1923
1855
|
"stroke-width": 1.5
|
|
1924
|
-
})], 8,
|
|
1856
|
+
})], 8, zi)) : S("", !0),
|
|
1925
1857
|
k("button", {
|
|
1926
1858
|
class: "tpl-block-action-btn tpl-block-delete-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors",
|
|
1927
1859
|
"aria-label": h(c).blockActions.delete,
|
|
1928
1860
|
title: h(c).blockActions.delete,
|
|
1929
1861
|
onClick: E(te, ["stop"])
|
|
1930
|
-
}, [g(h(
|
|
1862
|
+
}, [g(h(sn), {
|
|
1931
1863
|
size: 14,
|
|
1932
1864
|
"stroke-width": 1.5
|
|
1933
|
-
})], 8,
|
|
1934
|
-
], 8,
|
|
1935
|
-
C.value ? (s(), x("div",
|
|
1865
|
+
})], 8, Bi)
|
|
1866
|
+
], 8, Ii)) : S("", !0),
|
|
1867
|
+
C.value ? (s(), x("div", Vi, [k("span", Hi, [g(h(en), {
|
|
1936
1868
|
size: 12,
|
|
1937
1869
|
"stroke-width": 1.5
|
|
1938
1870
|
}), R(" " + F(h(u)(h(c).blockActions.hiddenOnViewport, { viewport: O.value })), 1)])])) : S("", !0),
|
|
1939
|
-
A.value && !C.value ? (s(), x("div",
|
|
1871
|
+
A.value && !C.value ? (s(), x("div", Ui, [k("button", {
|
|
1940
1872
|
"data-testid": "condition-toggle",
|
|
1941
1873
|
class: "tpl-condition-toggle tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:p-1 tpl:transition-colors tpl:bg-[var(--tpl-chrome-bg-elevated)] tpl:text-[var(--tpl-primary)] tpl:border tpl:border-[var(--tpl-border)]",
|
|
1942
1874
|
"aria-label": h(c).blockActions.conditionToggle,
|
|
1943
1875
|
title: e.block.displayCondition?.label,
|
|
1944
1876
|
onClick: E(ie, ["stop"])
|
|
1945
|
-
}, [g(h(
|
|
1877
|
+
}, [g(h(gn), {
|
|
1946
1878
|
size: 12,
|
|
1947
1879
|
"stroke-width": 2
|
|
1948
|
-
})], 8,
|
|
1949
|
-
B.value > 0 && !C.value ? (s(), x("div",
|
|
1880
|
+
})], 8, Wi)])) : S("", !0),
|
|
1881
|
+
B.value > 0 && !C.value ? (s(), x("div", Gi, [k("button", {
|
|
1950
1882
|
class: "tpl-comment-indicator tpl:flex tpl:min-h-6 tpl:min-w-6 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:gap-0.5 tpl:rounded-full tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-semibold tpl:transition-colors tpl:bg-[var(--tpl-chrome-primary-light)] tpl:text-[var(--tpl-primary)]",
|
|
1951
1883
|
"aria-label": h(u)(h(c).blockActions.comments, { count: String(B.value) }),
|
|
1952
1884
|
onClick: n[0] ||= E((t) => h(N).comments?.openForBlock(e.block.id), ["stop"])
|
|
1953
|
-
}, [g(h(
|
|
1885
|
+
}, [g(h(dn), {
|
|
1954
1886
|
size: 12,
|
|
1955
1887
|
"stroke-width": 2.5
|
|
1956
|
-
}), R(" " + F(B.value), 1)], 8,
|
|
1888
|
+
}), R(" " + F(B.value), 1)], 8, Ki)])) : S("", !0),
|
|
1957
1889
|
H.value ? (s(), x("div", {
|
|
1958
1890
|
key: 4,
|
|
1959
1891
|
class: "tpl-section-wrapper",
|
|
@@ -1966,31 +1898,31 @@ var Ai = ["innerHTML"], ji = /* @__PURE__ */ d({
|
|
|
1966
1898
|
class: "tpl-block-content",
|
|
1967
1899
|
style: D(V.value)
|
|
1968
1900
|
}, [a(t.$slots, "default", {}, void 0, !0)], 4))
|
|
1969
|
-
], 10,
|
|
1901
|
+
], 10, Fi));
|
|
1970
1902
|
}
|
|
1971
1903
|
}), [["__scopeId", "data-v-2c239048"]]);
|
|
1972
1904
|
//#endregion
|
|
1973
1905
|
//#region src/utils/unwrapParagraph.ts
|
|
1974
|
-
function
|
|
1906
|
+
function Ji(e) {
|
|
1975
1907
|
let t = e.match(/^\s*<p\b[^>]*>([\s\S]*)<\/p>\s*$/);
|
|
1976
1908
|
return !t || /<\/p>\s*<p\b/i.test(t[1]) ? e : t[1];
|
|
1977
1909
|
}
|
|
1978
1910
|
//#endregion
|
|
1979
1911
|
//#region src/components/blocks/TitleBlock.vue
|
|
1980
|
-
var
|
|
1912
|
+
var Yi = /* @__PURE__ */ d({
|
|
1981
1913
|
__name: "TitleBlock",
|
|
1982
1914
|
props: {
|
|
1983
1915
|
block: {},
|
|
1984
1916
|
viewport: {}
|
|
1985
1917
|
},
|
|
1986
1918
|
setup(e) {
|
|
1987
|
-
let t = e, n = L(() => import("./TitleEditor-
|
|
1919
|
+
let t = e, n = L(() => import("./TitleEditor-CnTT2Y3H.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: c, handleEditorDone: l } = Mi(() => t.block.content), d = b(() => {
|
|
1988
1920
|
let e = {
|
|
1989
|
-
fontSize: `${
|
|
1921
|
+
fontSize: `${Fe[t.block.level]}px`,
|
|
1990
1922
|
textAlign: t.block.textAlign
|
|
1991
1923
|
};
|
|
1992
1924
|
return t.block.color && (e.color = t.block.color), t.block.fontFamily && (e.fontFamily = t.block.fontFamily), e;
|
|
1993
|
-
}), f = b(() => `h${t.block.level}`), p = b(() =>
|
|
1925
|
+
}), f = b(() => `h${t.block.level}`), p = b(() => Ji(o.value));
|
|
1994
1926
|
return (t, o) => (s(), x("div", {
|
|
1995
1927
|
ref_key: "blockRef",
|
|
1996
1928
|
ref: i,
|
|
@@ -2016,16 +1948,16 @@ var Ki = /* @__PURE__ */ d({
|
|
|
2016
1948
|
});
|
|
2017
1949
|
//#endregion
|
|
2018
1950
|
//#region src/utils/sectionColumnDrop.ts
|
|
2019
|
-
function
|
|
1951
|
+
function Xi(e) {
|
|
2020
1952
|
return e.dataset.blockType !== "section" && e.dataset.paletteType !== "section";
|
|
2021
1953
|
}
|
|
2022
1954
|
//#endregion
|
|
2023
1955
|
//#region src/components/blocks/SectionBlock.vue?vue&type=script&setup=true&lang.ts
|
|
2024
|
-
var
|
|
1956
|
+
var Zi = { class: "tpl:w-full" }, Qi = {
|
|
2025
1957
|
key: 0,
|
|
2026
1958
|
"data-testid": "section-drop-hint",
|
|
2027
1959
|
class: "tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:flex tpl:items-center tpl:justify-center tpl:text-xs tpl:text-[var(--tpl-chrome-text-dim)]"
|
|
2028
|
-
},
|
|
1960
|
+
}, $i = /* @__PURE__ */ d({
|
|
2029
1961
|
__name: "SectionBlock",
|
|
2030
1962
|
props: {
|
|
2031
1963
|
block: {},
|
|
@@ -2033,22 +1965,18 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2033
1965
|
},
|
|
2034
1966
|
setup(e) {
|
|
2035
1967
|
let t = {
|
|
2036
|
-
title:
|
|
2037
|
-
paragraph:
|
|
2038
|
-
image:
|
|
2039
|
-
button:
|
|
2040
|
-
divider:
|
|
2041
|
-
custom:
|
|
2042
|
-
}, a = e, { t: o } = X(), c =
|
|
2043
|
-
function
|
|
2044
|
-
let t =
|
|
2045
|
-
|
|
2046
|
-
t.togglePick(a.block.id);
|
|
2047
|
-
return;
|
|
2048
|
-
}
|
|
2049
|
-
c.selectBlock(e);
|
|
1968
|
+
title: Yi,
|
|
1969
|
+
paragraph: Pi,
|
|
1970
|
+
image: xi,
|
|
1971
|
+
button: Tr,
|
|
1972
|
+
divider: ni,
|
|
1973
|
+
custom: ei
|
|
1974
|
+
}, a = e, { t: o } = X(), c = nt(Y, "SectionBlock"), d = n(kt, null), p = n(Bt, null), m = n(Nt, {}), _ = n(zt, null);
|
|
1975
|
+
function y(e) {
|
|
1976
|
+
let t = m.savedBlocks;
|
|
1977
|
+
t?.isPicking.value ? t.togglePick(a.block.id) : c.selectBlock(e);
|
|
2050
1978
|
}
|
|
2051
|
-
let
|
|
1979
|
+
let C = b(() => {
|
|
2052
1980
|
switch (a.block.columns) {
|
|
2053
1981
|
case "2": return ["50%", "50%"];
|
|
2054
1982
|
case "3": return [
|
|
@@ -2060,38 +1988,48 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2060
1988
|
case "2-1": return ["66.67%", "33.33%"];
|
|
2061
1989
|
default: return ["100%"];
|
|
2062
1990
|
}
|
|
2063
|
-
}),
|
|
2064
|
-
let e =
|
|
1991
|
+
}), w = b(() => {
|
|
1992
|
+
let e = C.value.length, t = [...a.block.children];
|
|
2065
1993
|
for (; t.length < e;) t.push([]);
|
|
2066
1994
|
return t.slice(0, e);
|
|
2067
|
-
}),
|
|
2068
|
-
function
|
|
2069
|
-
return
|
|
1995
|
+
}), T = b(() => a.viewport === "mobile" && a.block.stackOnMobile !== !1);
|
|
1996
|
+
function E(e) {
|
|
1997
|
+
return w.value[e] || [];
|
|
2070
1998
|
}
|
|
2071
|
-
function
|
|
1999
|
+
function A(e) {
|
|
2000
|
+
return _?.value === !1 || !d?.isHidden(e);
|
|
2001
|
+
}
|
|
2002
|
+
function j(e) {
|
|
2003
|
+
return !E(e).some((e) => A(e.id));
|
|
2004
|
+
}
|
|
2005
|
+
let I = l(null);
|
|
2006
|
+
function L(e) {
|
|
2007
|
+
return j(e) ? !0 : I.value === e && E(e).filter((e) => A(e.id)).length <= 1;
|
|
2008
|
+
}
|
|
2009
|
+
function R(e, t) {
|
|
2072
2010
|
let n = t.map((e) => JSON.parse(JSON.stringify(e))), r = [...a.block.children];
|
|
2073
2011
|
for (; r.length <= e;) r.push([]);
|
|
2074
2012
|
r[e] = n, c.updateBlock(a.block.id, { children: r });
|
|
2075
2013
|
}
|
|
2076
|
-
function
|
|
2077
|
-
return
|
|
2014
|
+
function z(e) {
|
|
2015
|
+
return _r(e, p, t);
|
|
2078
2016
|
}
|
|
2079
|
-
function
|
|
2017
|
+
function B(e, t) {
|
|
2080
2018
|
e.type === "custom" && c.updateBlock(e.id, {
|
|
2081
2019
|
fieldValues: t.fieldValues,
|
|
2082
2020
|
dataSourceFetched: t.dataSourceFetched
|
|
2083
2021
|
});
|
|
2084
2022
|
}
|
|
2085
|
-
return (t, n) => (s(), x("div",
|
|
2086
|
-
key:
|
|
2087
|
-
class: v(["tpl:relative tpl:
|
|
2088
|
-
style: D({ width:
|
|
2023
|
+
return (t, n) => (s(), x("div", Zi, [k("div", { class: v(["tpl:flex tpl:gap-0", { "tpl:flex-col": T.value }]) }, [(s(!0), x(P, null, r(w.value, (t, a) => (s(), x("div", {
|
|
2024
|
+
key: a,
|
|
2025
|
+
class: v(["tpl:relative tpl:flex tpl:flex-col tpl:rounded", E(a).length === 0 ? "tpl:border tpl:border-dashed tpl:border-[var(--tpl-border)]" : ""]),
|
|
2026
|
+
style: D({ width: T.value ? "100%" : C.value[a] })
|
|
2089
2027
|
}, [g(h(N), {
|
|
2090
|
-
"model-value":
|
|
2028
|
+
"model-value": E(a),
|
|
2091
2029
|
group: {
|
|
2092
2030
|
name: "blocks",
|
|
2093
2031
|
pull: !0,
|
|
2094
|
-
put: (e, t, n) => h(
|
|
2032
|
+
put: (e, t, n) => h(Xi)(n)
|
|
2095
2033
|
},
|
|
2096
2034
|
animation: 150,
|
|
2097
2035
|
"ghost-class": "tpl-ghost",
|
|
@@ -2101,21 +2039,23 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2101
2039
|
"inverted-swap-threshold": .65,
|
|
2102
2040
|
"empty-insert-threshold": 20,
|
|
2103
2041
|
"force-fallback": !0,
|
|
2104
|
-
class: "tpl:min-h-[60px]",
|
|
2105
|
-
|
|
2042
|
+
class: v(["tpl:grow", { "tpl:min-h-[60px]": L(a) }]),
|
|
2043
|
+
onStart: (e) => I.value = a,
|
|
2044
|
+
onEnd: n[0] ||= (e) => I.value = null,
|
|
2045
|
+
"onUpdate:modelValue": (e) => R(a, e)
|
|
2106
2046
|
}, {
|
|
2107
|
-
default: i(() => [(s(!0), x(P, null, r(
|
|
2047
|
+
default: i(() => [(s(!0), x(P, null, r(E(a), (t) => f((s(), x("div", { key: t.id }, [g(qi, {
|
|
2108
2048
|
block: t,
|
|
2109
2049
|
"is-selected": h(c).state.selectedBlockId === t.id,
|
|
2110
2050
|
viewport: e.viewport,
|
|
2111
2051
|
"preview-mode": h(c).state.previewMode,
|
|
2112
2052
|
nested: "",
|
|
2113
|
-
onSelect: (e) =>
|
|
2053
|
+
onSelect: (e) => y(t.id)
|
|
2114
2054
|
}, {
|
|
2115
|
-
default: i(() => [(s(), O(u(
|
|
2055
|
+
default: i(() => [(s(), O(u(z(t)), {
|
|
2116
2056
|
block: t,
|
|
2117
2057
|
viewport: e.viewport,
|
|
2118
|
-
onFetchData: (e) =>
|
|
2058
|
+
onFetchData: (e) => B(t, e),
|
|
2119
2059
|
onUpdate: (e) => h(c).updateBlock(t.id, e)
|
|
2120
2060
|
}, null, 40, [
|
|
2121
2061
|
"block",
|
|
@@ -2130,76 +2070,98 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2130
2070
|
"viewport",
|
|
2131
2071
|
"preview-mode",
|
|
2132
2072
|
"onSelect"
|
|
2133
|
-
])])), [[M,
|
|
2073
|
+
])])), [[M, A(t.id)]])), 128))]),
|
|
2134
2074
|
_: 2
|
|
2135
2075
|
}, 1032, [
|
|
2136
2076
|
"model-value",
|
|
2137
2077
|
"group",
|
|
2078
|
+
"class",
|
|
2079
|
+
"onStart",
|
|
2138
2080
|
"onUpdate:modelValue"
|
|
2139
|
-
]),
|
|
2140
|
-
}
|
|
2141
|
-
}),
|
|
2142
|
-
"
|
|
2143
|
-
"
|
|
2144
|
-
"
|
|
2145
|
-
|
|
2081
|
+
]), E(a).length === 0 ? (s(), x("div", Qi, [k("span", null, F(h(o).section.dropHere), 1)])) : S("", !0)], 6))), 128))], 2)]));
|
|
2082
|
+
}
|
|
2083
|
+
}), ea = ["width", "height"], ta = [
|
|
2084
|
+
"d",
|
|
2085
|
+
"stroke",
|
|
2086
|
+
"stroke-opacity",
|
|
2087
|
+
"stroke-width"
|
|
2088
|
+
], na = ["d", "fill"], ra = /* @__PURE__ */ d({
|
|
2146
2089
|
__name: "SocialIconSvg",
|
|
2147
2090
|
props: {
|
|
2148
2091
|
platform: {},
|
|
2149
2092
|
iconStyle: {},
|
|
2093
|
+
iconTone: {},
|
|
2150
2094
|
iconSize: {}
|
|
2151
2095
|
},
|
|
2152
2096
|
setup(e) {
|
|
2153
|
-
let t = e, n = b(() =>
|
|
2097
|
+
let t = e, n = b(() => Ge[t.platform]), r = b(() => qe[t.iconSize]), i = b(() => ke(t.platform, t.iconTone)), a = b(() => be(t.iconStyle, t.iconTone)), o = b(() => {
|
|
2154
2098
|
let e = {
|
|
2155
2099
|
display: "inline-flex",
|
|
2156
2100
|
alignItems: "center",
|
|
2157
2101
|
justifyContent: "center",
|
|
2158
2102
|
width: `${r.value}px`,
|
|
2159
2103
|
height: `${r.value}px`
|
|
2160
|
-
};
|
|
2104
|
+
}, n = i.value.fill;
|
|
2161
2105
|
switch (t.iconStyle) {
|
|
2162
2106
|
case "solid": return {
|
|
2163
2107
|
...e,
|
|
2164
|
-
backgroundColor: n
|
|
2108
|
+
backgroundColor: n,
|
|
2165
2109
|
borderRadius: "4px"
|
|
2166
2110
|
};
|
|
2167
2111
|
case "outlined": return {
|
|
2168
2112
|
...e,
|
|
2169
2113
|
backgroundColor: "transparent",
|
|
2170
|
-
border: `2px solid ${n
|
|
2171
|
-
borderRadius: "4px"
|
|
2114
|
+
border: `2px solid ${n}`,
|
|
2115
|
+
borderRadius: "4px",
|
|
2116
|
+
...a.value && { boxShadow: u(a.value) }
|
|
2172
2117
|
};
|
|
2173
2118
|
case "rounded": return {
|
|
2174
2119
|
...e,
|
|
2175
|
-
backgroundColor: n
|
|
2120
|
+
backgroundColor: n,
|
|
2176
2121
|
borderRadius: "8px"
|
|
2177
2122
|
};
|
|
2178
2123
|
case "square": return {
|
|
2179
2124
|
...e,
|
|
2180
|
-
backgroundColor: n
|
|
2125
|
+
backgroundColor: n,
|
|
2181
2126
|
borderRadius: "0"
|
|
2182
2127
|
};
|
|
2183
2128
|
case "circle": return {
|
|
2184
2129
|
...e,
|
|
2185
|
-
backgroundColor: n
|
|
2130
|
+
backgroundColor: n,
|
|
2186
2131
|
borderRadius: "50%"
|
|
2187
2132
|
};
|
|
2188
2133
|
default: return e;
|
|
2189
2134
|
}
|
|
2190
|
-
}),
|
|
2191
|
-
|
|
2192
|
-
width
|
|
2193
|
-
|
|
2135
|
+
}), c = b(() => Te(t.iconStyle)), l = b(() => Math.floor(r.value * c.value));
|
|
2136
|
+
function u(e) {
|
|
2137
|
+
let t = `${e.width / 2 * r.value / 24}px`, n = Math.round(e.opacity * 255).toString(16).padStart(2, "0"), i = `${e.color}${n}`;
|
|
2138
|
+
return `0 0 0 ${t} ${i}, inset 0 0 0 ${t} ${i}`;
|
|
2139
|
+
}
|
|
2140
|
+
let d = b(() => t.iconStyle === "outlined" || t.iconStyle === "plain" ? i.value.fill : i.value.onFill);
|
|
2141
|
+
return (e, t) => (s(), x("span", { style: D(o.value) }, [(s(), x("svg", {
|
|
2142
|
+
width: l.value,
|
|
2143
|
+
height: l.value,
|
|
2194
2144
|
viewBox: "0 0 24 24",
|
|
2195
|
-
|
|
2145
|
+
overflow: "visible",
|
|
2196
2146
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2197
|
-
}, [
|
|
2198
|
-
|
|
2199
|
-
|
|
2147
|
+
}, [a.value ? (s(), x("path", {
|
|
2148
|
+
key: 0,
|
|
2149
|
+
"data-testid": "social-icon-halo",
|
|
2150
|
+
d: n.value.path,
|
|
2151
|
+
fill: "none",
|
|
2152
|
+
stroke: a.value.color,
|
|
2153
|
+
"stroke-opacity": a.value.opacity,
|
|
2154
|
+
"stroke-width": a.value.width / c.value,
|
|
2155
|
+
"stroke-linejoin": "round"
|
|
2156
|
+
}, null, 8, ta)) : S("", !0), k("path", {
|
|
2157
|
+
d: n.value.path,
|
|
2158
|
+
fill: d.value
|
|
2159
|
+
}, null, 8, na)], 8, ea))], 4));
|
|
2160
|
+
}
|
|
2161
|
+
}), ia = { class: "tpl:w-full" }, aa = ["href"], oa = {
|
|
2200
2162
|
key: 1,
|
|
2201
2163
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
2202
|
-
},
|
|
2164
|
+
}, sa = /* @__PURE__ */ d({
|
|
2203
2165
|
__name: "SocialIconsBlock",
|
|
2204
2166
|
props: {
|
|
2205
2167
|
block: {},
|
|
@@ -2212,7 +2174,7 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2212
2174
|
gap: `${t.block.spacing}px`,
|
|
2213
2175
|
justifyContent: t.block.align === "left" ? "flex-start" : t.block.align === "right" ? "flex-end" : "center"
|
|
2214
2176
|
})), a = b(() => t.block.icons.length > 0);
|
|
2215
|
-
return (t, o) => (s(), x("div",
|
|
2177
|
+
return (t, o) => (s(), x("div", ia, [a.value ? (s(), x("div", {
|
|
2216
2178
|
key: 0,
|
|
2217
2179
|
style: D(i.value)
|
|
2218
2180
|
}, [(s(!0), x(P, null, r(e.block.icons, (t) => (s(), x("a", {
|
|
@@ -2220,52 +2182,54 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2220
2182
|
href: t.url || "#",
|
|
2221
2183
|
class: "tpl:cursor-default",
|
|
2222
2184
|
onClick: o[0] ||= E(() => {}, ["prevent"])
|
|
2223
|
-
}, [g(
|
|
2185
|
+
}, [g(ra, {
|
|
2224
2186
|
platform: t.platform,
|
|
2225
2187
|
"icon-style": e.block.iconStyle,
|
|
2188
|
+
"icon-tone": e.block.iconTone,
|
|
2226
2189
|
"icon-size": e.block.iconSize
|
|
2227
2190
|
}, null, 8, [
|
|
2228
2191
|
"platform",
|
|
2229
2192
|
"icon-style",
|
|
2193
|
+
"icon-tone",
|
|
2230
2194
|
"icon-size"
|
|
2231
|
-
])], 8,
|
|
2195
|
+
])], 8, aa))), 128))], 4)) : (s(), x("div", oa, [g(h(ln), { size: 16 }), k("span", null, F(h(n).social.addIcons), 1)]))]));
|
|
2232
2196
|
}
|
|
2233
|
-
}),
|
|
2197
|
+
}), ca = { class: "tpl:w-full" }, la = {
|
|
2234
2198
|
key: 0,
|
|
2235
2199
|
class: "tpl:absolute tpl:rounded tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-medium",
|
|
2236
2200
|
style: {
|
|
2237
2201
|
"background-color": "var(--tpl-bg-hover)",
|
|
2238
2202
|
color: "var(--tpl-text-dim)"
|
|
2239
2203
|
}
|
|
2240
|
-
},
|
|
2204
|
+
}, ua = /* @__PURE__ */ d({
|
|
2241
2205
|
__name: "SpacerBlock",
|
|
2242
2206
|
props: {
|
|
2243
2207
|
block: {},
|
|
2244
2208
|
viewport: {}
|
|
2245
2209
|
},
|
|
2246
2210
|
setup(e) {
|
|
2247
|
-
let t = e, n =
|
|
2211
|
+
let t = e, n = nt(Y, "SpacerBlock"), r = b(() => ({
|
|
2248
2212
|
height: `${t.block.height}px`,
|
|
2249
2213
|
minHeight: `${t.block.height}px`,
|
|
2250
2214
|
...n.state.previewMode ? {} : { borderColor: "var(--tpl-border)" }
|
|
2251
2215
|
}));
|
|
2252
|
-
return (t, i) => (s(), x("div",
|
|
2216
|
+
return (t, i) => (s(), x("div", ca, [k("div", {
|
|
2253
2217
|
style: D(r.value),
|
|
2254
2218
|
class: v(["tpl:relative tpl:flex tpl:items-center tpl:justify-center", { "tpl:border-y tpl:border-dashed": !h(n).state.previewMode }])
|
|
2255
|
-
}, [h(n).state.previewMode ? S("", !0) : (s(), x("span",
|
|
2219
|
+
}, [h(n).state.previewMode ? S("", !0) : (s(), x("span", la, F(e.block.height) + "px ", 1))], 6)]));
|
|
2256
2220
|
}
|
|
2257
|
-
}),
|
|
2221
|
+
}), da = { class: "tpl:w-full" }, fa = { key: 0 }, pa = [
|
|
2258
2222
|
"aria-label",
|
|
2259
2223
|
"data-placeholder",
|
|
2260
2224
|
"onBlur"
|
|
2261
|
-
],
|
|
2225
|
+
], ma = [
|
|
2262
2226
|
"aria-label",
|
|
2263
2227
|
"data-placeholder",
|
|
2264
2228
|
"onBlur"
|
|
2265
|
-
],
|
|
2229
|
+
], ha = {
|
|
2266
2230
|
key: 1,
|
|
2267
2231
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
2268
|
-
},
|
|
2232
|
+
}, ga = /*#__PURE__*/ vn(/* @__PURE__ */ d({
|
|
2269
2233
|
__name: "TableBlock",
|
|
2270
2234
|
props: {
|
|
2271
2235
|
block: {},
|
|
@@ -2279,7 +2243,7 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2279
2243
|
updated(e, t) {
|
|
2280
2244
|
t.value !== t.oldValue && e.getRootNode().activeElement !== e && (e.textContent = t.value ?? "");
|
|
2281
2245
|
}
|
|
2282
|
-
}, n = e, { t: i } = X(), a =
|
|
2246
|
+
}, n = e, { t: i } = X(), a = nt(Y, "TableBlock"), o = b(() => n.block.rows.length > 0), c = b(() => {
|
|
2283
2247
|
let e = {
|
|
2284
2248
|
width: "100%",
|
|
2285
2249
|
borderCollapse: "collapse",
|
|
@@ -2310,11 +2274,11 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2310
2274
|
} : n);
|
|
2311
2275
|
a.updateBlock(n.block.id, { rows: o });
|
|
2312
2276
|
}
|
|
2313
|
-
return (e, n) => (s(), x("div",
|
|
2277
|
+
return (e, n) => (s(), x("div", da, [o.value ? (s(), x("table", {
|
|
2314
2278
|
key: 0,
|
|
2315
2279
|
style: D(c.value),
|
|
2316
2280
|
class: "tpl-table-editable"
|
|
2317
|
-
}, [d.value ? (s(), x("thead",
|
|
2281
|
+
}, [d.value ? (s(), x("thead", fa, [k("tr", null, [(s(!0), x(P, null, r(d.value.cells, (e) => f((s(), x("th", {
|
|
2318
2282
|
key: e.id,
|
|
2319
2283
|
style: D(u.value),
|
|
2320
2284
|
"aria-label": h(i).table.cellPlaceholder,
|
|
@@ -2323,7 +2287,7 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2323
2287
|
onBlur: (t) => v(d.value.id, e.id, t),
|
|
2324
2288
|
onKeydown: n[0] ||= _(E((e) => e.target.blur(), ["prevent"]), ["enter"]),
|
|
2325
2289
|
onClick: E(m, ["stop"])
|
|
2326
|
-
}, null, 44,
|
|
2290
|
+
}, null, 44, pa)), [[t, e.content]])), 128))])])) : S("", !0), k("tbody", null, [(s(!0), x(P, null, r(p.value, (e) => (s(), x("tr", { key: e.id }, [(s(!0), x(P, null, r(e.cells, (r) => f((s(), x("td", {
|
|
2327
2291
|
key: r.id,
|
|
2328
2292
|
style: D(l.value),
|
|
2329
2293
|
"aria-label": h(i).table.cellPlaceholder,
|
|
@@ -2332,9 +2296,9 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2332
2296
|
onBlur: (t) => v(e.id, r.id, t),
|
|
2333
2297
|
onKeydown: n[1] ||= _(E((e) => e.target.blur(), ["prevent"]), ["enter"]),
|
|
2334
2298
|
onClick: E(m, ["stop"])
|
|
2335
|
-
}, null, 44,
|
|
2299
|
+
}, null, 44, ma)), [[t, r.content]])), 128))]))), 128))])], 4)) : (s(), x("div", ha, [g(h(hn), { size: 16 }), k("span", null, F(h(i).table.empty), 1)]))]));
|
|
2336
2300
|
}
|
|
2337
|
-
}), [["__scopeId", "data-v-963ac422"]]),
|
|
2301
|
+
}), [["__scopeId", "data-v-963ac422"]]), _a = /* @__PURE__ */ d({
|
|
2338
2302
|
__name: "VideoPlayButton",
|
|
2339
2303
|
props: { hoverEffect: {
|
|
2340
2304
|
type: Boolean,
|
|
@@ -2352,7 +2316,7 @@ var Ji = { class: "tpl:w-full" }, Yi = {
|
|
|
2352
2316
|
});
|
|
2353
2317
|
//#endregion
|
|
2354
2318
|
//#region src/utils/videoThumbnail.ts
|
|
2355
|
-
function
|
|
2319
|
+
function va(e) {
|
|
2356
2320
|
if (!e) return {
|
|
2357
2321
|
platform: "unknown",
|
|
2358
2322
|
videoId: null,
|
|
@@ -2384,25 +2348,25 @@ function ma(e) {
|
|
|
2384
2348
|
thumbnailUrl: null
|
|
2385
2349
|
};
|
|
2386
2350
|
}
|
|
2387
|
-
function
|
|
2388
|
-
return t ||
|
|
2351
|
+
function ya(e, t) {
|
|
2352
|
+
return t || va(e).thumbnailUrl;
|
|
2389
2353
|
}
|
|
2390
2354
|
//#endregion
|
|
2391
2355
|
//#region src/components/blocks/VideoBlock.vue?vue&type=script&setup=true&lang.ts
|
|
2392
|
-
var
|
|
2356
|
+
var ba = ["src", "alt"], xa = {
|
|
2393
2357
|
class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
|
|
2394
2358
|
style: { opacity: "0.7" }
|
|
2395
|
-
},
|
|
2359
|
+
}, Sa = ["href"], Ca = ["src", "alt"], wa = ["src", "alt"], Ta = {
|
|
2396
2360
|
key: 3,
|
|
2397
2361
|
class: "tpl:flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
|
|
2398
|
-
},
|
|
2362
|
+
}, Ea = /* @__PURE__ */ d({
|
|
2399
2363
|
__name: "VideoBlock",
|
|
2400
2364
|
props: {
|
|
2401
2365
|
block: {},
|
|
2402
2366
|
viewport: {}
|
|
2403
2367
|
},
|
|
2404
2368
|
setup(e) {
|
|
2405
|
-
let t = e, { t: n } = X(), { syntax: r } =
|
|
2369
|
+
let t = e, { t: n } = X(), { syntax: r } = bn(), i = b(() => W(t.block.url, r) || W(t.block.thumbnailUrl, r)), a = kn(() => i.value ? void 0 : t.block.thumbnailUrl || void 0), o = kn(() => i.value ? t.block.placeholderUrl : void 0), c = b(() => i.value ? null : t.block.thumbnailUrl ? a.value ?? null : ya(t.block.url)), l = b(() => ({ textAlign: t.block.align })), u = b(() => {
|
|
2406
2370
|
let e = t.block.align;
|
|
2407
2371
|
return {
|
|
2408
2372
|
maxWidth: "100%",
|
|
@@ -2412,7 +2376,7 @@ var ga = ["src", "alt"], _a = {
|
|
|
2412
2376
|
marginLeft: e === "center" || e === "right" ? "auto" : void 0,
|
|
2413
2377
|
marginRight: e === "center" ? "auto" : void 0
|
|
2414
2378
|
};
|
|
2415
|
-
}), d = b(() => ({ height: t.block.height ? `${t.block.height}px` : void 0 })), f = b(() =>
|
|
2379
|
+
}), d = b(() => ({ height: t.block.height ? `${t.block.height}px` : void 0 })), f = b(() => W(t.block.url, r) ? t.block.url : t.block.thumbnailUrl);
|
|
2416
2380
|
return (t, r) => (s(), x("div", {
|
|
2417
2381
|
class: "tpl:w-full",
|
|
2418
2382
|
style: D(l.value)
|
|
@@ -2425,16 +2389,16 @@ var ga = ["src", "alt"], _a = {
|
|
|
2425
2389
|
src: h(o),
|
|
2426
2390
|
alt: e.block.alt,
|
|
2427
2391
|
style: D(d.value)
|
|
2428
|
-
}, null, 12,
|
|
2392
|
+
}, null, 12, ba), g(_a)], 4)) : i.value ? (s(), x("div", {
|
|
2429
2393
|
key: 1,
|
|
2430
2394
|
class: "tpl:relative tpl:!flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
|
|
2431
2395
|
style: D([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, u.value])
|
|
2432
|
-
}, [g(h(
|
|
2396
|
+
}, [g(h(fn), {
|
|
2433
2397
|
size: 36,
|
|
2434
2398
|
"stroke-width": 1.5,
|
|
2435
2399
|
class: "tpl:text-[var(--tpl-primary)]",
|
|
2436
2400
|
style: { opacity: "0.5" }
|
|
2437
|
-
}), k("span",
|
|
2401
|
+
}), k("span", xa, [g(Cr, { text: f.value }, null, 8, ["text"])])], 4)) : c.value ? (s(), x(P, { key: 2 }, [e.block.url ? (s(), x("a", {
|
|
2438
2402
|
key: 0,
|
|
2439
2403
|
href: e.block.url,
|
|
2440
2404
|
target: "_blank",
|
|
@@ -2447,7 +2411,7 @@ var ga = ["src", "alt"], _a = {
|
|
|
2447
2411
|
src: c.value,
|
|
2448
2412
|
alt: e.block.alt,
|
|
2449
2413
|
style: D(d.value)
|
|
2450
|
-
}, null, 12,
|
|
2414
|
+
}, null, 12, Ca), g(_a, { "hover-effect": "" })], 12, Sa)) : (s(), x("div", {
|
|
2451
2415
|
key: 1,
|
|
2452
2416
|
class: "tpl:relative tpl:inline-block",
|
|
2453
2417
|
style: D(u.value)
|
|
@@ -2456,54 +2420,54 @@ var ga = ["src", "alt"], _a = {
|
|
|
2456
2420
|
src: c.value,
|
|
2457
2421
|
alt: e.block.alt,
|
|
2458
2422
|
style: D(d.value)
|
|
2459
|
-
}, null, 12,
|
|
2423
|
+
}, null, 12, wa), g(_a)], 4))], 64)) : (s(), x("div", Ta, [g(h(fn), {
|
|
2460
2424
|
size: 40,
|
|
2461
2425
|
"stroke-width": 1.5,
|
|
2462
2426
|
class: "tpl:text-[var(--tpl-border-light)]"
|
|
2463
2427
|
}), k("span", null, F(h(n).video.addVideo), 1)]))], 4));
|
|
2464
2428
|
}
|
|
2465
|
-
}),
|
|
2466
|
-
section:
|
|
2467
|
-
title:
|
|
2468
|
-
paragraph:
|
|
2469
|
-
image:
|
|
2470
|
-
button:
|
|
2471
|
-
divider:
|
|
2472
|
-
video:
|
|
2473
|
-
social:
|
|
2474
|
-
menu:
|
|
2475
|
-
table:
|
|
2476
|
-
spacer:
|
|
2477
|
-
html:
|
|
2478
|
-
countdown: L(() => import("./CountdownBlock-
|
|
2429
|
+
}), Da = {
|
|
2430
|
+
section: $i,
|
|
2431
|
+
title: Yi,
|
|
2432
|
+
paragraph: Pi,
|
|
2433
|
+
image: xi,
|
|
2434
|
+
button: Tr,
|
|
2435
|
+
divider: ni,
|
|
2436
|
+
video: Ea,
|
|
2437
|
+
social: sa,
|
|
2438
|
+
menu: Ti,
|
|
2439
|
+
table: ga,
|
|
2440
|
+
spacer: ua,
|
|
2441
|
+
html: ci,
|
|
2442
|
+
countdown: L(() => import("./CountdownBlock-lHU3Lu7Q.js"))
|
|
2479
2443
|
};
|
|
2480
|
-
function
|
|
2481
|
-
let { editor: n, config: r, translations: i, fontsManager: a } = e, { t: s, format: u } = X(i), d = b(() => ue(ue(ue(
|
|
2444
|
+
function Oa(e) {
|
|
2445
|
+
let { editor: n, config: r, translations: i, fontsManager: a } = e, { t: s, format: u } = X(i), d = b(() => ue(ue(ue(qn(i), fr(n.content.value.settings?.locale)), H(n.content.value.settings) === "rtl" ? {
|
|
2482
2446
|
title: { textAlign: "right" },
|
|
2483
2447
|
table: { textAlign: "right" }
|
|
2484
2448
|
} : {}), r.blockDefaults ?? {}));
|
|
2485
2449
|
n.setUiTheme(r.uiTheme ?? "auto");
|
|
2486
|
-
let { resolvedTheme: f } =
|
|
2450
|
+
let { resolvedTheme: f } = Fn(b(() => n.state.uiTheme)), p = l(r.theme ?? {}), { themeStyles: h } = Ln({
|
|
2487
2451
|
themeOverrides: p,
|
|
2488
2452
|
resolvedTheme: f,
|
|
2489
2453
|
extraStyles: () => ({
|
|
2490
2454
|
"--tpl-drop-text": `"${i.canvas.dropHere}"`,
|
|
2491
2455
|
...e.themeExtraStyles?.()
|
|
2492
2456
|
})
|
|
2493
|
-
}), g =
|
|
2457
|
+
}), g = Be({
|
|
2494
2458
|
content: n.content,
|
|
2495
2459
|
setContent: (e, t) => n.setContent(e, t),
|
|
2496
2460
|
...e.historyOptions
|
|
2497
2461
|
});
|
|
2498
|
-
|
|
2499
|
-
let _ =
|
|
2462
|
+
We(n, g);
|
|
2463
|
+
let _ = Ye({
|
|
2500
2464
|
addBlock: n.addBlock,
|
|
2501
2465
|
removeBlock: n.removeBlock,
|
|
2502
2466
|
updateBlock: n.updateBlock,
|
|
2503
2467
|
selectBlock: n.selectBlock,
|
|
2504
2468
|
findBlockLocation: n.findBlockLocation,
|
|
2505
2469
|
blockDefaults: () => d.value
|
|
2506
|
-
}), v =
|
|
2470
|
+
}), v = Ve(n), x = e.autoSaveOptions !== null && e.autoSaveOptions !== void 0 ? Je({
|
|
2507
2471
|
content: n.content,
|
|
2508
2472
|
isDirty: () => n.state.isDirty,
|
|
2509
2473
|
...e.autoSaveOptions
|
|
@@ -2511,27 +2475,27 @@ function wa(e) {
|
|
|
2511
2475
|
x && (S = t(g.isNavigating, (e) => {
|
|
2512
2476
|
e ? x.pause() : x.resume();
|
|
2513
2477
|
}));
|
|
2514
|
-
let C =
|
|
2478
|
+
let C = Pn(n, {
|
|
2515
2479
|
t: s,
|
|
2516
2480
|
format: u
|
|
2517
|
-
}, r.customBlocks ?? []), w =
|
|
2481
|
+
}, r.customBlocks ?? []), w = Jt(r.colors);
|
|
2518
2482
|
if (w.allowCustomIgnored && Z.warn("config.colors.allowCustom: false is ignored without presets — keeping the color wheel and hex input so a color can still be chosen."), w.invalidPresets.length > 0 && Z.warn(`config.colors.presets skipped invalid entries: ${w.invalidPresets.join(", ")} — presets must be hex colors (#rgb or #rrggbb).`), w.allowCustom === !1) {
|
|
2519
|
-
let e =
|
|
2483
|
+
let e = Kn(w.presets, r.blockDefaults, r.templateDefaults);
|
|
2520
2484
|
e.length > 0 && Z.warn(`config.colors locks custom colours, but these block/template default colours fall outside colors.presets: ${e.join(", ")}. New blocks start on a colour the palette can't reselect — set blockDefaults / templateDefaults from the same palette.`);
|
|
2521
2485
|
}
|
|
2522
|
-
let T =
|
|
2523
|
-
for (let e of T.unknown) Z.warn(`config.templateSettings.fields: "${e}" is not a template setting (expected one of ${
|
|
2524
|
-
let E =
|
|
2525
|
-
|
|
2486
|
+
let T = Xt(r.templateSettings);
|
|
2487
|
+
for (let e of T.unknown) Z.warn(`config.templateSettings.fields: "${e}" is not a template setting (expected one of ${Zt.join(", ")}) — skipping it.`);
|
|
2488
|
+
let E = Rn();
|
|
2489
|
+
Un(E, Da);
|
|
2526
2490
|
let D = /* @__PURE__ */ new Set();
|
|
2527
2491
|
function O(e) {
|
|
2528
2492
|
for (let t of e) {
|
|
2529
|
-
E.registerCustom(t,
|
|
2530
|
-
for (let e of
|
|
2493
|
+
E.registerCustom(t, ei);
|
|
2494
|
+
for (let e of pr(t, w)) D.has(e.id) || (D.add(e.id), Z.warn(e.message));
|
|
2531
2495
|
}
|
|
2532
2496
|
}
|
|
2533
2497
|
r.customBlocks?.length && O(r.customBlocks);
|
|
2534
|
-
let k =
|
|
2498
|
+
let k = Tn();
|
|
2535
2499
|
if (o() && m(k.dispose), e.containerEl) {
|
|
2536
2500
|
let t = e.containerEl;
|
|
2537
2501
|
G(document, "pointerdown", (e) => {
|
|
@@ -2541,14 +2505,10 @@ function wa(e) {
|
|
|
2541
2505
|
}
|
|
2542
2506
|
function A() {
|
|
2543
2507
|
let t = e.capabilities?.templates;
|
|
2544
|
-
|
|
2545
|
-
t.save();
|
|
2546
|
-
return;
|
|
2547
|
-
}
|
|
2548
|
-
x?.flush();
|
|
2508
|
+
t ? t.save() : x?.flush();
|
|
2549
2509
|
}
|
|
2550
2510
|
function j(t) {
|
|
2551
|
-
k.isActive() &&
|
|
2511
|
+
k.isActive() && hr(t, {
|
|
2552
2512
|
history: g,
|
|
2553
2513
|
selectBlock: (e) => n.selectBlock(e),
|
|
2554
2514
|
getSelectedBlockId: () => n.state.selectedBlockId,
|
|
@@ -2562,39 +2522,35 @@ function wa(e) {
|
|
|
2562
2522
|
}
|
|
2563
2523
|
G(document, "keydown", j);
|
|
2564
2524
|
let M = l(null);
|
|
2565
|
-
c(
|
|
2566
|
-
let N =
|
|
2525
|
+
c(wt, e.editorRoot ?? document), c(it, M), c(St, i), c(Y, n), c(Wt, g), c(Tt, _), c(kt, v), c(Vt, a), c(dt, h), c(Ct, f), c(It, d), c(xt, r.locale), c(Bt, E), c(Lt, r.customBlocks ?? []), c(Gt, r.paletteBlocks), c(Et, Wn(r.htmlBlockPreview)), c(at, r.layout), c(ct, r.sectionWrapper), c(Ot, w), c(Rt, T.fields), c(Pt, zn(n.content, E));
|
|
2526
|
+
let N = ye(r.mergeTags?.syntax), P = y(r.mergeTags?.tags ?? []);
|
|
2567
2527
|
function F(e) {
|
|
2568
|
-
|
|
2569
|
-
Z.warn(`setMergeTags() expects an array of merge tags, received ${typeof e} — ignoring.`);
|
|
2570
|
-
return;
|
|
2571
|
-
}
|
|
2572
|
-
P.value = e;
|
|
2528
|
+
Array.isArray(e) ? P.value = e : Z.warn(`setMergeTags() expects an array of merge tags, received ${typeof e} — ignoring.`);
|
|
2573
2529
|
}
|
|
2574
|
-
c(q, P), c(
|
|
2530
|
+
c(q, P), c(gt, N), c(_t, r.mergeTags?.onRequest ?? null), c(Mt, r.mergeTags?.autocomplete !== !1), c(ht, r.mergeTags?.showRawValue !== !1);
|
|
2575
2531
|
let I = l(Ne(r.mergeTags?.tags ?? []));
|
|
2576
|
-
c(
|
|
2577
|
-
let L =
|
|
2532
|
+
c(mt, I);
|
|
2533
|
+
let L = Dn({
|
|
2578
2534
|
resolvePreview: r.resolvePreview,
|
|
2579
2535
|
getContent: () => {
|
|
2580
2536
|
let e = n.content.value;
|
|
2581
|
-
return r.layout && n.state.previewMode ?
|
|
2537
|
+
return r.layout && n.state.previewMode ? me(r.layout, e) : e;
|
|
2582
2538
|
},
|
|
2583
2539
|
isActive: () => n.state.previewMode
|
|
2584
2540
|
});
|
|
2585
|
-
c(
|
|
2541
|
+
c(bt, L), c(lt, r.resolvePreview);
|
|
2586
2542
|
let R = b(() => !(n.state.previewMode && L.isConfigured));
|
|
2587
|
-
c(
|
|
2588
|
-
let z =
|
|
2589
|
-
c(
|
|
2590
|
-
let B =
|
|
2543
|
+
c(zt, R);
|
|
2544
|
+
let z = An();
|
|
2545
|
+
c(rt, z), c(jt, l(!1)), c(ot, l(!1)), c(yt, r.logicTags?.tags ?? []), c(Ht, r.logicTags?.pairs ?? []), c(ut, r.logicTags?.onRequest ?? null), c(st, jn()), c(pt, r.onRequestMedia ?? null), c(Dt, r.canDropMedia ?? null), c(Ut, r.resolveImageUrl ? On(r.resolveImageUrl) : null), c(At, r.displayConditions?.conditions ?? []), c(Ft, r.displayConditions?.allowCustom ?? !1), c(Nt, e.capabilities ?? {}), c(vt, C);
|
|
2546
|
+
let B = Mn(r.lint) ? null : Nn({
|
|
2591
2547
|
content: n.content,
|
|
2592
2548
|
options: r.lint ?? {},
|
|
2593
2549
|
updateBlock: n.updateBlock,
|
|
2594
2550
|
updateSettings: n.updateSettings,
|
|
2595
2551
|
removeBlock: n.removeBlock
|
|
2596
2552
|
});
|
|
2597
|
-
c(
|
|
2553
|
+
c(ft, B);
|
|
2598
2554
|
function V() {
|
|
2599
2555
|
S?.(), B?.destroy(), x?.destroy(), g.destroy();
|
|
2600
2556
|
}
|
|
@@ -2621,6 +2577,6 @@ function wa(e) {
|
|
|
2621
2577
|
};
|
|
2622
2578
|
}
|
|
2623
2579
|
//#endregion
|
|
2624
|
-
export {
|
|
2580
|
+
export { sr as A, vr as C, tr as D, _r as E, ar as M, ir as N, lr as O, Dn as P, Tr as S, xr as T, Vr as _, sa as a, Ar as b, qi as c, xi as d, ci as f, Ur as g, Gr as h, ua as i, or as j, cr as k, Pi as l, ei as m, Ea as n, $i as o, ni as p, ga as r, Yi as s, Oa as t, Ti as u, Ir as v, gr as w, Or as x, jr as y };
|
|
2625
2581
|
|
|
2626
|
-
//# sourceMappingURL=useEditorCore-
|
|
2582
|
+
//# sourceMappingURL=useEditorCore-BF1ZhcGu.js.map
|