@templatical/editor 0.52.1 → 0.53.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/README.md +1 -1
- package/dist/AiAltTextPopover-NMJqQKvD.js +106 -0
- package/dist/{AiAltTextReview-9ySsXOTU.js → AiAltTextReview-Ci4zHwRc.js} +68 -66
- package/dist/AiChatPanel-DdhtfsmO.js +561 -0
- package/dist/{AiPanels-DqT4PgQ0.js → AiPanels-HBx7xoJR.js} +6 -6
- package/dist/{AiRewriteMenu-28agTycW.js → AiRewriteMenu-DPzSekZt.js} +76 -105
- package/dist/BlockIssueBadge-eIXZJ9M3.js +33 -0
- package/dist/BlockPreviewCanvas-DO-2TP_6.js +140 -0
- package/dist/{CloudHeaderExtras-QI82yF54.js → CloudHeaderExtras-XpjJjn3o.js} +4 -4
- package/dist/{CloudPanels-BKJaLkUN.js → CloudPanels-i2kZdrdP.js} +53 -53
- package/dist/CollaborationNotices-DANsjl7c.js +65 -0
- package/dist/{CollaboratorBar-CXQqN3VP.js → CollaboratorBar-CbbAA0m1.js} +24 -24
- package/dist/CommentsPanel-CYW3LWis.js +16 -0
- package/dist/CommentsSidebar-CcF4ISMi.js +526 -0
- package/dist/{CountdownBlock-CU2yTWtF.js → CountdownBlock-BMezkFbJ.js} +15 -15
- package/dist/CountdownToolbar-D3Lv74kU.js +258 -0
- package/dist/IssuesPanel-BMAG9042.js +371 -0
- package/dist/LanguageMenu-FlP_Jbup.js +403 -0
- package/dist/{LoadingTrack-DM4g6j7b.js → LoadingTrack-BG8cg9xi.js} +2 -2
- package/dist/LocaleNotices-DAnVszWu.js +46 -0
- package/dist/LogicTagInsertButton-BjYs-UQX.js +1096 -0
- package/dist/{MediaEditModal-Dy08GEwE.js → MediaEditModal-LnG-cF_S.js} +451 -451
- package/dist/{MediaPanels-BgEp7iCp.js → MediaPanels-C2r5fiFo.js} +4 -4
- package/dist/{MergeTagInput-B9dtUthD.js → MergeTagInput-BsnogCeY.js} +30 -30
- package/dist/{MergeTagModeToggle-DxujhYJ4.js → MergeTagModeToggle-DiufIQ-_.js} +49 -49
- package/dist/MergeTagTextarea-BweI-Xsi.js +126 -0
- package/dist/ParagraphEditor-qgBp5yIB.js +825 -0
- package/dist/{RestoreVersionDialog-C4s_JYCx.js → RestoreVersionDialog-DdYUrFiK.js} +23 -23
- package/dist/{RichTextEditorContent-o6HmE8GR.js → RichTextEditorContent-C5MAzx3E.js} +47 -47
- package/dist/{SaveBlockDialog-CWLrly6l.js → SaveBlockDialog-eK6fjtTy.js} +86 -86
- package/dist/{cdn/chunks/SavedBlocksBrowserModal-BPYcRoGa.js → SavedBlocksBrowserModal-D2QHd2Yp.js} +135 -132
- package/dist/{SavedBlocksPanels-BE1N9rNZ.js → SavedBlocksPanels-Cl61f4Mf.js} +9 -9
- package/dist/{SavedBlocksPickBar-Dwl94xhP.js → SavedBlocksPickBar-CXP2dkeB.js} +15 -15
- package/dist/TemplateSettings-BKJrdZcH.js +294 -0
- package/dist/TestEmailModal-DQotJg6g.js +212 -0
- package/dist/{TestEmailPanel-DaFjP9QK.js → TestEmailPanel-CwiTzJsh.js} +4 -4
- package/dist/TitleEditor-CzSvsPAn.js +202 -0
- package/dist/ToggleSwitch-R3wCCYE6.js +43 -0
- package/dist/Toolbar-Cd75ci5W.js +3711 -0
- package/dist/{TplModal-DLMssVlt.js → TplModal-ZoXu40T9.js} +17 -17
- package/dist/{VersionHistoryMenu-BkbYUs0Q.js → VersionHistoryMenu-BvhN-Ofk.js} +39 -39
- package/dist/{VersionHistoryPanels-DP7HaYWv.js → VersionHistoryPanels-DPWMnYbd.js} +5 -5
- package/dist/VersionPreviewBanner-CuJnasxH.js +37 -0
- package/dist/WrapperBlock-D4fPwO0t.js +44 -0
- package/dist/{blockTypeIcons-BHjlPnPf.js → blockTypeIcons-BXMxu86H.js} +7 -7
- package/dist/bundle-stats.json +8 -8
- package/dist/{cdn/chunks/ca-CD-Kt1qz.js → ca-DOuIxWRv.js} +114 -2
- package/dist/cdn/chunks/AiAltTextPopover-ByZ0FEqI.js +107 -0
- package/dist/cdn/chunks/AiAltTextPopover-ByZ0FEqI.js.map +1 -0
- package/dist/cdn/chunks/{AiAltTextReview-BGLLSKLm.js → AiAltTextReview-Dtm3A2cD.js} +70 -68
- package/dist/cdn/chunks/AiAltTextReview-Dtm3A2cD.js.map +1 -0
- package/dist/cdn/chunks/AiChatPanel-DciEt27y.js +487 -0
- package/dist/cdn/chunks/AiChatPanel-DciEt27y.js.map +1 -0
- package/dist/cdn/chunks/{AiPanels-0wBarZSH.js → AiPanels-BV5D1itk.js} +11 -11
- package/dist/cdn/chunks/{AiPanels-0wBarZSH.js.map → AiPanels-BV5D1itk.js.map} +1 -1
- package/dist/cdn/chunks/{AiRewriteMenu-qf-cfEpy.js → AiRewriteMenu-D3jkh6Xb.js} +79 -79
- package/dist/cdn/chunks/AiRewriteMenu-D3jkh6Xb.js.map +1 -0
- package/dist/cdn/chunks/BlockIssueBadge-DyEgBZtR.js +34 -0
- package/dist/cdn/chunks/BlockIssueBadge-DyEgBZtR.js.map +1 -0
- package/dist/cdn/chunks/BlockPreviewCanvas-RQFilqXC.js +142 -0
- package/dist/cdn/chunks/{BlockPreviewCanvas-DGBh6mqe.js.map → BlockPreviewCanvas-RQFilqXC.js.map} +1 -1
- package/dist/cdn/chunks/{CloudHeaderExtras-BMNK_F9p.js → CloudHeaderExtras-BtqdN777.js} +4 -4
- package/dist/cdn/chunks/{CloudHeaderExtras-BMNK_F9p.js.map → CloudHeaderExtras-BtqdN777.js.map} +1 -1
- package/dist/cdn/chunks/{CloudPanels-JMWIoVWh.js → CloudPanels-BSJ-Z5Hw.js} +45 -45
- package/dist/cdn/chunks/{CloudPanels-JMWIoVWh.js.map → CloudPanels-BSJ-Z5Hw.js.map} +1 -1
- package/dist/cdn/chunks/CollaborationNotices-BS7xrlPE.js +67 -0
- package/dist/cdn/chunks/CollaborationNotices-BS7xrlPE.js.map +1 -0
- package/dist/cdn/chunks/{CollaboratorBar-CXByAoUz.js → CollaboratorBar-Bc9914Az.js} +17 -17
- package/dist/cdn/chunks/{CollaboratorBar-CXByAoUz.js.map → CollaboratorBar-Bc9914Az.js.map} +1 -1
- package/dist/cdn/chunks/CommentsPanel-DbR9phAk.js +18 -0
- package/dist/cdn/chunks/{CommentsPanel-DoJnKLXI.js.map → CommentsPanel-DbR9phAk.js.map} +1 -1
- package/dist/cdn/chunks/CommentsSidebar-BD4--XP2.js +496 -0
- package/dist/cdn/chunks/CommentsSidebar-BD4--XP2.js.map +1 -0
- package/dist/cdn/chunks/{CountdownBlock-BqRw147R.js → CountdownBlock-CjMhMhnv.js} +22 -22
- package/dist/cdn/chunks/{CountdownBlock-BqRw147R.js.map → CountdownBlock-CjMhMhnv.js.map} +1 -1
- package/dist/cdn/chunks/CountdownToolbar-DxwYBw-d.js +260 -0
- package/dist/cdn/chunks/CountdownToolbar-DxwYBw-d.js.map +1 -0
- package/dist/cdn/chunks/{IssuesPanel-C7LfxaAY.js → IssuesPanel-CUmI4HMm.js} +133 -121
- package/dist/cdn/chunks/IssuesPanel-CUmI4HMm.js.map +1 -0
- package/dist/cdn/chunks/LanguageMenu-3ydCozQJ.js +359 -0
- package/dist/cdn/chunks/LanguageMenu-3ydCozQJ.js.map +1 -0
- package/dist/cdn/chunks/{LoadingTrack-CZuLTazv.js → LoadingTrack-DUYcDHOV.js} +2 -2
- package/dist/cdn/chunks/{LoadingTrack-CZuLTazv.js.map → LoadingTrack-DUYcDHOV.js.map} +1 -1
- package/dist/cdn/chunks/LocaleNotices-BfoH6gST.js +47 -0
- package/dist/cdn/chunks/LocaleNotices-BfoH6gST.js.map +1 -0
- package/dist/{LogicTagInsertButton-CfscnwCn.js → cdn/chunks/LogicTagInsertButton-5Z3fFzjc.js} +422 -449
- package/dist/cdn/chunks/LogicTagInsertButton-5Z3fFzjc.js.map +1 -0
- package/dist/cdn/chunks/{MediaEditModal-Cpcod6_U.js → MediaEditModal-DDCIwr9U.js} +421 -421
- package/dist/cdn/chunks/MediaEditModal-DDCIwr9U.js.map +1 -0
- package/dist/cdn/chunks/{MediaPanels-BIdcW_1f.js → MediaPanels-Dz79oy8P.js} +5 -5
- package/dist/cdn/chunks/{MediaPanels-BIdcW_1f.js.map → MediaPanels-Dz79oy8P.js.map} +1 -1
- package/dist/cdn/chunks/{MergeTagInput-BvWg8o5E.js → MergeTagInput-CIWy-cXf.js} +28 -28
- package/dist/cdn/chunks/{MergeTagInput-BvWg8o5E.js.map → MergeTagInput-CIWy-cXf.js.map} +1 -1
- package/dist/cdn/chunks/{MergeTagModeToggle-BgKEVUtV.js → MergeTagModeToggle-BrP5GR-x.js} +52 -52
- package/dist/cdn/chunks/MergeTagModeToggle-BrP5GR-x.js.map +1 -0
- package/dist/cdn/chunks/MergeTagTextarea-D3nNDlhV.js +128 -0
- package/dist/cdn/chunks/MergeTagTextarea-D3nNDlhV.js.map +1 -0
- package/dist/cdn/chunks/ParagraphEditor-DDolH_Pf.js +660 -0
- package/dist/cdn/chunks/ParagraphEditor-DDolH_Pf.js.map +1 -0
- package/dist/cdn/chunks/{RestoreVersionDialog-CjOdD2xj.js → RestoreVersionDialog-Crj1DBqC.js} +22 -22
- package/dist/cdn/chunks/{RestoreVersionDialog-CjOdD2xj.js.map → RestoreVersionDialog-Crj1DBqC.js.map} +1 -1
- package/dist/cdn/chunks/{RichTextEditorContent-DNjR_sNN.js → RichTextEditorContent-rCCqFlwJ.js} +44 -44
- package/dist/cdn/chunks/{RichTextEditorContent-DNjR_sNN.js.map → RichTextEditorContent-rCCqFlwJ.js.map} +1 -1
- package/dist/cdn/chunks/{SaveBlockDialog-CUhpawq0.js → SaveBlockDialog-C34RW1aM.js} +77 -77
- package/dist/cdn/chunks/{SaveBlockDialog-CUhpawq0.js.map → SaveBlockDialog-C34RW1aM.js.map} +1 -1
- package/dist/{SavedBlocksBrowserModal-CE8n4EBS.js → cdn/chunks/SavedBlocksBrowserModal-CJnwWPT-.js} +103 -106
- package/dist/cdn/chunks/{SavedBlocksBrowserModal-BPYcRoGa.js.map → SavedBlocksBrowserModal-CJnwWPT-.js.map} +1 -1
- package/dist/cdn/chunks/{SavedBlocksPanels-C6--Bc81.js → SavedBlocksPanels-CA2PqXIH.js} +9 -9
- package/dist/cdn/chunks/{SavedBlocksPanels-C6--Bc81.js.map → SavedBlocksPanels-CA2PqXIH.js.map} +1 -1
- package/dist/cdn/chunks/{SavedBlocksPickBar-DUavxpbU.js → SavedBlocksPickBar-Dj3ortee.js} +16 -16
- package/dist/cdn/chunks/{SavedBlocksPickBar-DUavxpbU.js.map → SavedBlocksPickBar-Dj3ortee.js.map} +1 -1
- package/dist/cdn/chunks/TemplateSettings-sW0ZlDl1.js +266 -0
- package/dist/cdn/chunks/TemplateSettings-sW0ZlDl1.js.map +1 -0
- package/dist/cdn/chunks/TestEmailModal-BXeCtTjU.js +212 -0
- package/dist/cdn/chunks/TestEmailModal-BXeCtTjU.js.map +1 -0
- package/dist/cdn/chunks/{TestEmailPanel-CcUpEpAn.js → TestEmailPanel-CpZcpB9D.js} +5 -5
- package/dist/cdn/chunks/{TestEmailPanel-CcUpEpAn.js.map → TestEmailPanel-CpZcpB9D.js.map} +1 -1
- package/dist/cdn/chunks/TitleEditor-Bv3SmSO6.js +202 -0
- package/dist/cdn/chunks/TitleEditor-Bv3SmSO6.js.map +1 -0
- package/dist/cdn/chunks/ToggleSwitch-BSkySwA1.js +45 -0
- package/dist/cdn/chunks/ToggleSwitch-BSkySwA1.js.map +1 -0
- package/dist/cdn/chunks/Toolbar-BJKpJ2Mg.js +3626 -0
- package/dist/cdn/chunks/Toolbar-BJKpJ2Mg.js.map +1 -0
- package/dist/cdn/chunks/{TplModal-CFPDgbwQ.js → TplModal-DDDUDMYC.js} +20 -20
- package/dist/cdn/chunks/{TplModal-CFPDgbwQ.js.map → TplModal-DDDUDMYC.js.map} +1 -1
- package/dist/cdn/chunks/{VersionHistoryMenu-BYlLRvRJ.js → VersionHistoryMenu-DSElv3Sv.js} +33 -33
- package/dist/cdn/chunks/{VersionHistoryMenu-BYlLRvRJ.js.map → VersionHistoryMenu-DSElv3Sv.js.map} +1 -1
- package/dist/cdn/chunks/{VersionHistoryPanels-C6SOVoiT.js → VersionHistoryPanels-H2nuik1l.js} +6 -6
- package/dist/cdn/chunks/{VersionHistoryPanels-C6SOVoiT.js.map → VersionHistoryPanels-H2nuik1l.js.map} +1 -1
- package/dist/cdn/chunks/VersionPreviewBanner-Whwxh55w.js +39 -0
- package/dist/cdn/chunks/VersionPreviewBanner-Whwxh55w.js.map +1 -0
- package/dist/cdn/chunks/WrapperBlock-jTqsuLnS.js +46 -0
- package/dist/cdn/chunks/WrapperBlock-jTqsuLnS.js.map +1 -0
- package/dist/cdn/chunks/{blockTypeIcons-D7FW7Ypo.js → blockTypeIcons-DMgLcuI8.js} +5 -5
- package/dist/cdn/chunks/{blockTypeIcons-D7FW7Ypo.js.map → blockTypeIcons-DMgLcuI8.js.map} +1 -1
- package/dist/{ca-CD-Kt1qz.js → cdn/chunks/ca-DOuIxWRv.js} +116 -0
- package/dist/cdn/chunks/ca-DOuIxWRv.js.map +1 -0
- package/dist/cdn/chunks/composables-D0UYam2P.js +3039 -0
- package/dist/cdn/chunks/composables-D0UYam2P.js.map +1 -0
- package/dist/cdn/chunks/{createCloudRuntime-Cth2JCEh.js → createCloudRuntime-BdsclY8_.js} +75 -73
- package/dist/cdn/chunks/createCloudRuntime-BdsclY8_.js.map +1 -0
- package/dist/{de-CeFJ6wbM.js → cdn/chunks/de-DaOUfYBX.js} +116 -0
- package/dist/cdn/chunks/de-DaOUfYBX.js.map +1 -0
- package/dist/cdn/chunks/{dist-8ym3y-pH.js → dist-BzXULHvI.js} +48 -48
- package/dist/cdn/chunks/{dist-8ym3y-pH.js.map → dist-BzXULHvI.js.map} +1 -1
- package/dist/cdn/chunks/{dist-BMzNabtD.js → dist-DqGgijFI.js} +114 -114
- package/dist/cdn/chunks/{dist-BMzNabtD.js.map → dist-DqGgijFI.js.map} +1 -1
- package/dist/cdn/chunks/{draggable-Du8AUMFT.js → draggable-DepKdldn.js} +1491 -1486
- package/dist/cdn/chunks/draggable-DepKdldn.js.map +1 -0
- package/dist/cdn/chunks/{editor-modal-CyCe560f.js → editor-modal-CPbgthOv.js} +781 -781
- package/dist/cdn/chunks/{editor-modal-CyCe560f.js.map → editor-modal-CPbgthOv.js.map} +1 -1
- package/dist/{en-D14i5nFh.js → cdn/chunks/en-C0pHHMiR.js} +116 -0
- package/dist/cdn/chunks/en-C0pHHMiR.js.map +1 -0
- package/dist/cdn/chunks/en-IYVryJRl.js +1 -0
- package/dist/{es-zDacbMhs.js → cdn/chunks/es-CxyEKr6n.js} +116 -0
- package/dist/cdn/chunks/es-CxyEKr6n.js.map +1 -0
- package/dist/cdn/chunks/{extensions-CFF2KWy-.js → extensions-Uh9vuFfK.js} +59 -59
- package/dist/cdn/chunks/{extensions-CFF2KWy-.js.map → extensions-Uh9vuFfK.js.map} +1 -1
- package/dist/{fr-CSgYtjOd.js → cdn/chunks/fr-CYbamiI6.js} +116 -0
- package/dist/cdn/chunks/fr-CYbamiI6.js.map +1 -0
- package/dist/cdn/chunks/{icons-okSPsLOa.js → icons-CSSMtbGK.js} +150 -109
- package/dist/cdn/chunks/icons-CSSMtbGK.js.map +1 -0
- package/dist/{ja-B7H3ID8O.js → cdn/chunks/ja-DfaIAoGI.js} +116 -0
- package/dist/cdn/chunks/ja-DfaIAoGI.js.map +1 -0
- package/dist/cdn/chunks/keys-CoQtCqNv.js +11 -0
- package/dist/cdn/chunks/keys-CoQtCqNv.js.map +1 -0
- package/dist/cdn/chunks/languageName-DEEOhDWI.js +12 -0
- package/dist/cdn/chunks/languageName-DEEOhDWI.js.map +1 -0
- package/dist/{nl-176ySmc5.js → cdn/chunks/nl-DkrB-VKZ.js} +116 -0
- package/dist/cdn/chunks/nl-DkrB-VKZ.js.map +1 -0
- package/dist/cdn/chunks/normalizeMergeTagMarkup-oGhwVscw.js +290 -0
- package/dist/cdn/chunks/normalizeMergeTagMarkup-oGhwVscw.js.map +1 -0
- package/dist/cdn/chunks/noticeTones-D7BPu-Le.js +16 -0
- package/dist/cdn/chunks/noticeTones-D7BPu-Le.js.map +1 -0
- package/dist/cdn/chunks/plural-CyxrJXL1.js +17 -0
- package/dist/cdn/chunks/plural-CyxrJXL1.js.map +1 -0
- package/dist/cdn/chunks/{preRenderCustomBlocks-BcXIz7oJ.js → preRenderCustomBlocks-C8k7tw98.js} +5 -5
- package/dist/cdn/chunks/{preRenderCustomBlocks-BcXIz7oJ.js.map → preRenderCustomBlocks-C8k7tw98.js.map} +1 -1
- package/dist/{pt-BR-dDlTwX18.js → cdn/chunks/pt-BR-CY5Ye7eP.js} +116 -0
- package/dist/cdn/chunks/pt-BR-CY5Ye7eP.js.map +1 -0
- package/dist/cdn/chunks/sanitizeHtml-DYklmvgX.js +61 -0
- package/dist/cdn/chunks/sanitizeHtml-DYklmvgX.js.map +1 -0
- package/dist/cdn/chunks/socialIcons-BAiuHyJs.js +2638 -0
- package/dist/cdn/chunks/socialIcons-BAiuHyJs.js.map +1 -0
- package/dist/cdn/chunks/src-CACM3o--.js +2606 -0
- package/dist/cdn/chunks/src-CACM3o--.js.map +1 -0
- package/dist/cdn/chunks/{src-C7bkofBL.js → src-Ddpm4HsS.js} +222 -256
- package/dist/cdn/chunks/src-Ddpm4HsS.js.map +1 -0
- package/dist/cdn/chunks/{src-DEd87i_U.js → src-DheBmnvF.js} +635 -478
- package/dist/cdn/chunks/src-DheBmnvF.js.map +1 -0
- package/dist/{styleConstants-B8xVRiwX.js → cdn/chunks/styleConstants-CgiNKdnc.js} +7 -5
- package/dist/cdn/chunks/styleConstants-CgiNKdnc.js.map +1 -0
- package/dist/cdn/chunks/templateSettingsFields-cjlP-jdw.js.map +1 -1
- package/dist/cdn/chunks/{tiptap-CbiTlECY.js → tiptap-Dipw_zOQ.js} +40 -40
- package/dist/cdn/chunks/{tiptap-CbiTlECY.js.map → tiptap-Dipw_zOQ.js.map} +1 -1
- package/dist/cdn/chunks/{useCloudI18n-DY8_-ETE.js → useCloudI18n-Cc5NZqiI.js} +3 -3
- package/dist/cdn/chunks/{useCloudI18n-DY8_-ETE.js.map → useCloudI18n-Cc5NZqiI.js.map} +1 -1
- package/dist/cdn/chunks/useEditorRoot-D_LuZ_hE.js +9 -0
- package/dist/cdn/chunks/{useEditorRoot-vjZJwKrV.js.map → useEditorRoot-D_LuZ_hE.js.map} +1 -1
- package/dist/cdn/chunks/{useI18n-D8pY4LTq.js → useI18n-BnJYydPv.js} +3 -3
- package/dist/cdn/chunks/{useI18n-D8pY4LTq.js.map → useI18n-BnJYydPv.js.map} +1 -1
- package/dist/cdn/chunks/useLocalizedDisplay-yXbRKNrs.js +33 -0
- package/dist/cdn/chunks/useLocalizedDisplay-yXbRKNrs.js.map +1 -0
- package/dist/cdn/chunks/{useLogicTag-DBJDtpKA.js → useLogicTag-B7RpqVFQ.js} +5 -5
- package/dist/cdn/chunks/{useLogicTag-DBJDtpKA.js.map → useLogicTag-B7RpqVFQ.js.map} +1 -1
- package/dist/cdn/chunks/{useMergeTag-B-aG--s1.js → useMergeTag-C-32ETjj.js} +6 -6
- package/dist/cdn/chunks/{useMergeTag-B-aG--s1.js.map → useMergeTag-C-32ETjj.js.map} +1 -1
- package/dist/cdn/chunks/usePopoverPosition-BWAXWeBv.js +78 -0
- package/dist/cdn/chunks/usePopoverPosition-BWAXWeBv.js.map +1 -0
- package/dist/cdn/chunks/{useScrollToBlock-vjQ0fe-L.js → useScrollToBlock-Ct1AwLD-.js} +5 -5
- package/dist/cdn/chunks/useScrollToBlock-Ct1AwLD-.js.map +1 -0
- package/dist/cdn/chunks/{withCurrentFont-hZTvYBHO.js → withCurrentFont-D33ZXoWp.js} +2 -2
- package/dist/cdn/chunks/{withCurrentFont-hZTvYBHO.js.map → withCurrentFont-D33ZXoWp.js.map} +1 -1
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +2190 -1496
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{check-BZ8o0eet.js → check-ChQ0l8EQ.js} +1 -1
- package/dist/{chevron-down-DfAAfILv.js → chevron-down-Bh6cp6PI.js} +1 -1
- package/dist/{chevron-right-Bk4mGdr7.js → chevron-right-LUgdqdoW.js} +1 -1
- package/dist/{chevron-up-MhUf_azW.js → chevron-up-XsDeJxQN.js} +1 -1
- package/dist/{circle-alert-CShJwVFv.js → circle-alert-lODfDsrj.js} +1 -1
- package/dist/{clock-CTfD6OCt.js → clock-DrqFEZkT.js} +1 -1
- package/dist/composables-BOP3ERRP.js +4517 -0
- package/dist/{createCloudRuntime-DCgO4A1r.js → createCloudRuntime-DGV5a5Af.js} +54 -52
- package/dist/{createLucideIcon-CvhTA2KG.js → createLucideIcon-Dw5e5gVE.js} +11 -11
- package/dist/{cdn/chunks/de-CeFJ6wbM.js → de-DaOUfYBX.js} +114 -2
- package/dist/{dist-ByCWA2Tv.js → dist-0alKVRc_.js} +101 -101
- package/dist/{dist-Cy8I5scI.js → dist-54VCNoC0.js} +2 -2
- package/dist/dist-6DU0me3E.js +4 -0
- package/dist/{dist-p3wymUDt.js → dist-B8dY8drK.js} +2 -2
- package/dist/{dist-Dd5MU2Ev.js → dist-B9a7iVye.js} +2 -2
- package/dist/{dist-V7W1UhVr.js → dist-BWflWcpW.js} +2 -2
- package/dist/{dist-D6fZec6r.js → dist-C3hu_C3w.js} +2 -2
- package/dist/{dist-CVy-7PHQ.js → dist-CX7skkvG.js} +48 -48
- package/dist/dist-CcOn7WCo.js +4 -0
- package/dist/dist-Cdkm20M6.js +2542 -0
- package/dist/{dist-BS5uKktL.js → dist-ChOb5XHW.js} +2 -2
- package/dist/{dist-BF5zEHop.js → dist-DZ3X-uB8.js} +2 -2
- package/dist/{dist-CWSG7Kj0.js → dist-D_XrUEET.js} +5 -5
- package/dist/{dist-txQLT2sF.js → dist-TAv500j6.js} +2 -2
- package/dist/{dist-D6cMdrfG.js → dist-fqSers8_.js} +55 -55
- package/dist/{editor-modal-zaZHcmlO.js → editor-modal-B_2EAOjN.js} +953 -952
- package/dist/{cdn/chunks/en-D14i5nFh.js → en-C0pHHMiR.js} +114 -2
- package/dist/en-DTtwco2Q.js +1 -0
- package/dist/{cdn/chunks/es-zDacbMhs.js → es-CxyEKr6n.js} +114 -2
- package/dist/{extensions-fo_c-vqf.js → extensions-DOLZkLzV.js} +173 -173
- package/dist/{eye-7W4t5e0Q.js → eye-DChfk0gi.js} +1 -1
- package/dist/{cdn/chunks/fr-CSgYtjOd.js → fr-CYbamiI6.js} +114 -2
- package/dist/{image-BDiRFzSd.js → image--Hj2by1G.js} +1 -1
- package/dist/index.d.ts +182 -14
- package/dist/{info-Cxi3-Kh9.js → info-BbXgy82f.js} +1 -1
- package/dist/{cdn/chunks/ja-B7H3ID8O.js → ja-DfaIAoGI.js} +114 -2
- package/dist/keys-BCqskl51.js +9 -0
- package/dist/languageName-DEEOhDWI.js +10 -0
- package/dist/{link-ju_2Cmir.js → link-C2_8yJno.js} +1 -1
- package/dist/{list-DYZJf0aZ.js → list-DLGs2n0V.js} +1 -1
- package/dist/{loader-circle-BZRD0a4I.js → loader-circle-BbDItE_O.js} +1 -1
- package/dist/{message-circle-DuEw4Zfx.js → message-circle-NAModq0p.js} +1 -1
- package/dist/{cdn/chunks/nl-176ySmc5.js → nl-DkrB-VKZ.js} +114 -2
- package/dist/normalizeMergeTagMarkup-CUCo7B5X.js +288 -0
- package/dist/noticeTones-D7BPu-Le.js +14 -0
- package/dist/{package-CePMr2kK.js → package-BuzsfRyH.js} +1 -1
- package/dist/{pencil-D3aFCL7c.js → pencil-BTUUECH4.js} +1 -1
- package/dist/plural-CyxrJXL1.js +15 -0
- package/dist/plus-Dm7DN65T.js +13 -0
- package/dist/{preRenderCustomBlocks--_xc0XK3.js → preRenderCustomBlocks-Bs3N9no-.js} +4 -4
- package/dist/{cdn/chunks/pt-BR-dDlTwX18.js → pt-BR-CY5Ye7eP.js} +114 -2
- package/dist/{refresh-cw-xnro7_Sk.js → refresh-cw-xMURqGWi.js} +2 -12
- package/dist/rotate-ccw-DqVcEIn5.js +13 -0
- package/dist/{runtime-dom.esm-bundler-BURR-bj5.js → runtime-dom.esm-bundler-DlHp8xgy.js} +154 -154
- package/dist/sanitizeHtml-mKgNUdME.js +962 -0
- package/dist/{search-CDrstRBv.js → search-Cfr3W44N.js} +1 -1
- package/dist/{send-DROkPOaX.js → send-CH1SrvyB.js} +1 -1
- package/dist/{smartphone-Bx6u_tjn.js → smartphone-pAkvzjdI.js} +1 -1
- package/dist/socialIcons-Dqr4DJOz.js +2705 -0
- package/dist/{sparkles-CdaTtvoz.js → sparkles-CRO0cCnp.js} +1 -1
- package/dist/{square-BbCROH_f.js → square-CaQWMntx.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{cdn/chunks/styleConstants-B8xVRiwX.js → styleConstants-CgiNKdnc.js} +5 -7
- package/dist/templatical-editor.js +2438 -1752
- package/dist/{text-align-start-CGacJ9Vw.js → text-align-start-BQ39AaRK.js} +1 -1
- package/dist/{trash-DxCd7zIy.js → trash-BL5gEFHN.js} +1 -1
- package/dist/{triangle-alert-7_oaitpf.js → triangle-alert-BYbKu7zZ.js} +1 -1
- package/dist/{upload-DuFEOi_0.js → upload-BhmL4Vqx.js} +1 -1
- package/dist/{useCloudI18n-DEMmUKuO.js → useCloudI18n-Dh2iydo1.js} +4 -4
- package/dist/useEditorRoot-DY3mgcHm.js +7 -0
- package/dist/{useI18n-BBrHTdu8.js → useI18n-CgtvtF4C.js} +4 -4
- package/dist/useLocalizedDisplay-DNNwDRxL.js +31 -0
- package/dist/{useLogicTag-ZPC39rfH.js → useLogicTag-BXXXQQmi.js} +4 -4
- package/dist/{useMergeTag-BQ4qqWpQ.js → useMergeTag-C9Okr87y.js} +5 -5
- package/dist/usePopoverPosition-VDQjyX_A.js +76 -0
- package/dist/{useScrollToBlock-BSyAV4pk.js → useScrollToBlock-C0Kapxdh.js} +5 -5
- package/dist/{vue.runtime.esm-bundler-CnEeTfhs.js → vue.runtime.esm-bundler-BJXc_Mri.js} +1373 -1368
- package/dist/withCurrentFont-DJiQqZzL.js +18 -0
- package/dist/{x-BpfG7v9g.js → x-B7NZYzhx.js} +1 -1
- package/package.json +20 -20
- package/dist/AiAltTextPopover-DawbUywc.js +0 -105
- package/dist/AiChatPanel-CupPhmsN.js +0 -548
- package/dist/BlockIssueBadge-BxpDy3u-.js +0 -33
- package/dist/BlockPreviewCanvas-B-4bmJ3t.js +0 -140
- package/dist/CollaborationNotices-CTw4JThq.js +0 -75
- package/dist/CommentsPanel-DwwFuh1h.js +0 -16
- package/dist/CommentsSidebar-9ZfiC2DO.js +0 -500
- package/dist/CountdownToolbar-BqoYzf_6.js +0 -197
- package/dist/IssuesPanel-4ykrf1ax.js +0 -359
- package/dist/MergeTagTextarea-CPFEjJZd.js +0 -69
- package/dist/ParagraphEditor-CWXfurGh.js +0 -796
- package/dist/TemplateSettings-CS0f1Ues.js +0 -236
- package/dist/TestEmailModal-DBD0X5nV.js +0 -209
- package/dist/TitleEditor-DSqtle77.js +0 -198
- package/dist/ToggleSwitch-JykPyD_8.js +0 -36
- package/dist/Toolbar-BZPFfKrf.js +0 -3145
- package/dist/VersionPreviewBanner-DECaBwLq.js +0 -37
- package/dist/WrapperBlock-BsJv_Fiw.js +0 -44
- package/dist/cdn/chunks/AiAltTextPopover-SEEjkd-I.js +0 -106
- package/dist/cdn/chunks/AiAltTextPopover-SEEjkd-I.js.map +0 -1
- package/dist/cdn/chunks/AiAltTextReview-BGLLSKLm.js.map +0 -1
- package/dist/cdn/chunks/AiChatPanel-DKDAaBNi.js +0 -474
- package/dist/cdn/chunks/AiChatPanel-DKDAaBNi.js.map +0 -1
- package/dist/cdn/chunks/AiRewriteMenu-qf-cfEpy.js.map +0 -1
- package/dist/cdn/chunks/BlockIssueBadge-jdf91-nk.js +0 -34
- package/dist/cdn/chunks/BlockIssueBadge-jdf91-nk.js.map +0 -1
- package/dist/cdn/chunks/BlockPreviewCanvas-DGBh6mqe.js +0 -142
- package/dist/cdn/chunks/CollaborationNotices-Bsf1rGW9.js +0 -77
- package/dist/cdn/chunks/CollaborationNotices-Bsf1rGW9.js.map +0 -1
- package/dist/cdn/chunks/CommentsPanel-DoJnKLXI.js +0 -18
- package/dist/cdn/chunks/CommentsSidebar-CUtgvdBC.js +0 -470
- package/dist/cdn/chunks/CommentsSidebar-CUtgvdBC.js.map +0 -1
- package/dist/cdn/chunks/CountdownToolbar-xobieKoU.js +0 -199
- package/dist/cdn/chunks/CountdownToolbar-xobieKoU.js.map +0 -1
- package/dist/cdn/chunks/IssuesPanel-C7LfxaAY.js.map +0 -1
- package/dist/cdn/chunks/LogicTagInsertButton-BIi05UQu.js +0 -1051
- package/dist/cdn/chunks/LogicTagInsertButton-BIi05UQu.js.map +0 -1
- package/dist/cdn/chunks/MediaEditModal-Cpcod6_U.js.map +0 -1
- package/dist/cdn/chunks/MergeTagModeToggle-BgKEVUtV.js.map +0 -1
- package/dist/cdn/chunks/MergeTagTextarea-tBz8McZf.js +0 -71
- package/dist/cdn/chunks/MergeTagTextarea-tBz8McZf.js.map +0 -1
- package/dist/cdn/chunks/ParagraphEditor-B3Rj_cWF.js +0 -631
- package/dist/cdn/chunks/ParagraphEditor-B3Rj_cWF.js.map +0 -1
- package/dist/cdn/chunks/TemplateSettings-CKtI-dof.js +0 -208
- package/dist/cdn/chunks/TemplateSettings-CKtI-dof.js.map +0 -1
- package/dist/cdn/chunks/TestEmailModal-CDQTgESD.js +0 -209
- package/dist/cdn/chunks/TestEmailModal-CDQTgESD.js.map +0 -1
- package/dist/cdn/chunks/TitleEditor-Cob7RLyK.js +0 -198
- package/dist/cdn/chunks/TitleEditor-Cob7RLyK.js.map +0 -1
- package/dist/cdn/chunks/ToggleSwitch-J7Vwhvha.js +0 -38
- package/dist/cdn/chunks/ToggleSwitch-J7Vwhvha.js.map +0 -1
- package/dist/cdn/chunks/Toolbar-CdpsvNOR.js +0 -3061
- package/dist/cdn/chunks/Toolbar-CdpsvNOR.js.map +0 -1
- package/dist/cdn/chunks/VersionPreviewBanner-Dvg0ZfAW.js +0 -39
- package/dist/cdn/chunks/VersionPreviewBanner-Dvg0ZfAW.js.map +0 -1
- package/dist/cdn/chunks/WrapperBlock-C7Md56IT.js +0 -46
- package/dist/cdn/chunks/WrapperBlock-C7Md56IT.js.map +0 -1
- package/dist/cdn/chunks/ca-CD-Kt1qz.js.map +0 -1
- package/dist/cdn/chunks/createCloudRuntime-Cth2JCEh.js.map +0 -1
- package/dist/cdn/chunks/de-CeFJ6wbM.js.map +0 -1
- package/dist/cdn/chunks/draggable-Du8AUMFT.js.map +0 -1
- package/dist/cdn/chunks/en-D14i5nFh.js.map +0 -1
- package/dist/cdn/chunks/en-TIqv4ag3.js +0 -1
- package/dist/cdn/chunks/es-zDacbMhs.js.map +0 -1
- package/dist/cdn/chunks/fr-CSgYtjOd.js.map +0 -1
- package/dist/cdn/chunks/icons-okSPsLOa.js.map +0 -1
- package/dist/cdn/chunks/ja-B7H3ID8O.js.map +0 -1
- package/dist/cdn/chunks/keys-CUj6UA38.js +0 -11
- package/dist/cdn/chunks/keys-CUj6UA38.js.map +0 -1
- package/dist/cdn/chunks/nl-176ySmc5.js.map +0 -1
- package/dist/cdn/chunks/normalizeMergeTagMarkup-C_KlfSW4.js +0 -198
- package/dist/cdn/chunks/normalizeMergeTagMarkup-C_KlfSW4.js.map +0 -1
- package/dist/cdn/chunks/pt-BR-dDlTwX18.js.map +0 -1
- package/dist/cdn/chunks/sanitizeHtml-CN85EDrO.js +0 -72
- package/dist/cdn/chunks/sanitizeHtml-CN85EDrO.js.map +0 -1
- package/dist/cdn/chunks/socialIcons-jsTDmkbb.js +0 -2008
- package/dist/cdn/chunks/socialIcons-jsTDmkbb.js.map +0 -1
- package/dist/cdn/chunks/src-C7bkofBL.js.map +0 -1
- package/dist/cdn/chunks/src-DEd87i_U.js.map +0 -1
- package/dist/cdn/chunks/src-DwWrYnUj.js +0 -1404
- package/dist/cdn/chunks/src-DwWrYnUj.js.map +0 -1
- package/dist/cdn/chunks/styleConstants-B8xVRiwX.js.map +0 -1
- package/dist/cdn/chunks/useEditorCore-BrY66C2y.js +0 -2582
- package/dist/cdn/chunks/useEditorCore-BrY66C2y.js.map +0 -1
- package/dist/cdn/chunks/useEditorRoot-vjZJwKrV.js +0 -9
- package/dist/cdn/chunks/usePopoverPosition-DSMtmu2W.js +0 -70
- package/dist/cdn/chunks/usePopoverPosition-DSMtmu2W.js.map +0 -1
- package/dist/cdn/chunks/useScrollToBlock-vjQ0fe-L.js.map +0 -1
- package/dist/dist-CKi_npZM.js +0 -1344
- package/dist/dist-DyFArF_G.js +0 -4
- package/dist/dist-pA3ooG6N.js +0 -4
- package/dist/en-Db76vJbY.js +0 -1
- package/dist/keys-BgRERHzu.js +0 -9
- package/dist/normalizeMergeTagMarkup-CELnOlgK.js +0 -196
- package/dist/sanitizeHtml-BzfzpYJY.js +0 -942
- package/dist/socialIcons-D7MGsg0d.js +0 -2075
- package/dist/useEditorCore-BSo2sSID.js +0 -4059
- package/dist/useEditorRoot-BMcoCLBx.js +0 -7
- package/dist/usePopoverPosition-DV1PxL66.js +0 -68
- package/dist/withCurrentFont-B22FXAF5.js +0 -18
package/dist/Toolbar-BZPFfKrf.js
DELETED
|
@@ -1,3145 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./rolldown-runtime-CGnMp29N.js";
|
|
2
|
-
import { $ as t, C as n, H as r, I as i, Mt as a, N as o, Nt as s, P as c, U as l, X as u, Z as d, _ as f, c as p, d as m, f as h, g, j as _, jt as v, l as y, r as b, st as x, u as S, v as C, y as w, z as T } from "./vue.runtime.esm-bundler-CnEeTfhs.js";
|
|
3
|
-
import { a as E, o as D } from "./runtime-dom.esm-bundler-BURR-bj5.js";
|
|
4
|
-
import { At as O, C as k, S as A, X as j, Y as M, at as N, i as P, jt as F, n as ee, p as te, pt as ne, r as re, rt as I, t as ie, u as ae, vt as oe } from "./dist-CKi_npZM.js";
|
|
5
|
-
import { C as se, O as ce, R as le, b as ue, c as de, d as fe, f as pe, g as me, h as he, i as ge, l as _e, m as L, o as ve, p as R, r as ye, u as z, x as be } from "./socialIcons-D7MGsg0d.js";
|
|
6
|
-
import { _ as xe } from "./dist-CVy-7PHQ.js";
|
|
7
|
-
import { $ as Se, C as Ce, L as we, P as Te, W as Ee, d as De, g as Oe, h as ke, n as Ae, p as je, v as Me, x as Ne } from "./keys-BgRERHzu.js";
|
|
8
|
-
import { t as B } from "./useI18n-BBrHTdu8.js";
|
|
9
|
-
import { o as Pe } from "./usePopoverPosition-DV1PxL66.js";
|
|
10
|
-
import { t as Fe } from "./createLucideIcon-CvhTA2KG.js";
|
|
11
|
-
import { c as V } from "./LogicTagInsertButton-CfscnwCn.js";
|
|
12
|
-
import { t as Ie } from "./chevron-down-DfAAfILv.js";
|
|
13
|
-
import { t as Le } from "./circle-alert-CShJwVFv.js";
|
|
14
|
-
import { n as Re, t as ze } from "./blockTypeIcons-BHjlPnPf.js";
|
|
15
|
-
import { n as Be } from "./upload-DuFEOi_0.js";
|
|
16
|
-
import { t as Ve } from "./image-BDiRFzSd.js";
|
|
17
|
-
import { t as He } from "./info-Cxi3-Kh9.js";
|
|
18
|
-
import { t as Ue } from "./link-ju_2Cmir.js";
|
|
19
|
-
import { n as We, t as Ge } from "./smartphone-Bx6u_tjn.js";
|
|
20
|
-
import { n as H, t as Ke } from "./refresh-cw-xnro7_Sk.js";
|
|
21
|
-
import { n as qe, r as Je, t as Ye } from "./text-align-start-CGacJ9Vw.js";
|
|
22
|
-
import { t as Xe } from "./trash-DxCd7zIy.js";
|
|
23
|
-
import { t as Ze } from "./x-BpfG7v9g.js";
|
|
24
|
-
import { t as Qe } from "./_plugin-vue_export-helper-Djzt4Yr7.js";
|
|
25
|
-
import { _ as $e, b as et, c as tt, g as U, h as W, m as G, p as K, r as nt, v as rt } from "./styleConstants-B8xVRiwX.js";
|
|
26
|
-
import { t as it } from "./MergeTagTextarea-CPFEjJZd.js";
|
|
27
|
-
import { t as q } from "./ToggleSwitch-JykPyD_8.js";
|
|
28
|
-
import { n as at, t as ot } from "./withCurrentFont-B22FXAF5.js";
|
|
29
|
-
import { t as J } from "./MergeTagInput-B9dtUthD.js";
|
|
30
|
-
var st = Fe({
|
|
31
|
-
name: "lock-open",
|
|
32
|
-
size: 24,
|
|
33
|
-
node: [["rect", {
|
|
34
|
-
width: "18",
|
|
35
|
-
height: "11",
|
|
36
|
-
x: "3",
|
|
37
|
-
y: "11",
|
|
38
|
-
rx: "2",
|
|
39
|
-
ry: "2",
|
|
40
|
-
key: "1w4ew1"
|
|
41
|
-
}], ["path", {
|
|
42
|
-
d: "M7 11V7a5 5 0 0 1 9.9-1",
|
|
43
|
-
key: "1mm8w8"
|
|
44
|
-
}]],
|
|
45
|
-
aliases: ["unlock"]
|
|
46
|
-
}), ct = Fe({
|
|
47
|
-
name: "lock",
|
|
48
|
-
size: 24,
|
|
49
|
-
node: [["rect", {
|
|
50
|
-
width: "18",
|
|
51
|
-
height: "11",
|
|
52
|
-
x: "3",
|
|
53
|
-
y: "11",
|
|
54
|
-
rx: "2",
|
|
55
|
-
ry: "2",
|
|
56
|
-
key: "1w4ew1"
|
|
57
|
-
}], ["path", {
|
|
58
|
-
d: "M7 11V7a5 5 0 0 1 10 0v4",
|
|
59
|
-
key: "fwvmzm"
|
|
60
|
-
}]]
|
|
61
|
-
}), lt = Fe({
|
|
62
|
-
name: "unlink",
|
|
63
|
-
size: 24,
|
|
64
|
-
node: [
|
|
65
|
-
["path", {
|
|
66
|
-
d: "m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71",
|
|
67
|
-
key: "yqzxt4"
|
|
68
|
-
}],
|
|
69
|
-
["path", {
|
|
70
|
-
d: "m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71",
|
|
71
|
-
key: "4qinb0"
|
|
72
|
-
}],
|
|
73
|
-
["line", {
|
|
74
|
-
x1: "8",
|
|
75
|
-
x2: "8",
|
|
76
|
-
y1: "2",
|
|
77
|
-
y2: "5",
|
|
78
|
-
key: "1041cp"
|
|
79
|
-
}],
|
|
80
|
-
["line", {
|
|
81
|
-
x1: "2",
|
|
82
|
-
x2: "5",
|
|
83
|
-
y1: "8",
|
|
84
|
-
y2: "8",
|
|
85
|
-
key: "14m1p5"
|
|
86
|
-
}],
|
|
87
|
-
["line", {
|
|
88
|
-
x1: "16",
|
|
89
|
-
x2: "16",
|
|
90
|
-
y1: "19",
|
|
91
|
-
y2: "22",
|
|
92
|
-
key: "rzdirn"
|
|
93
|
-
}],
|
|
94
|
-
["line", {
|
|
95
|
-
x1: "19",
|
|
96
|
-
x2: "22",
|
|
97
|
-
y1: "16",
|
|
98
|
-
y2: "16",
|
|
99
|
-
key: "ox905f"
|
|
100
|
-
}]
|
|
101
|
-
]
|
|
102
|
-
}), ut = [
|
|
103
|
-
"aria-checked",
|
|
104
|
-
"aria-label",
|
|
105
|
-
"disabled",
|
|
106
|
-
"aria-disabled",
|
|
107
|
-
"title",
|
|
108
|
-
"onClick"
|
|
109
|
-
], dt = { key: 1 }, Y = /* @__PURE__ */ w({
|
|
110
|
-
__name: "SlidingPillSelect",
|
|
111
|
-
props: {
|
|
112
|
-
options: {},
|
|
113
|
-
modelValue: {}
|
|
114
|
-
},
|
|
115
|
-
emits: ["update:modelValue"],
|
|
116
|
-
setup(e, { emit: t }) {
|
|
117
|
-
let n = e, r = t, c = p(() => n.options.findIndex((e) => e.value === n.modelValue)), l = p(() => `translateX(${Math.max(c.value, 0) * 100}%)`);
|
|
118
|
-
return (t, n) => (_(), h("div", {
|
|
119
|
-
role: "radiogroup",
|
|
120
|
-
class: "tpl:relative tpl:grid tpl:rounded-[var(--tpl-radius-sm)] tpl:p-1",
|
|
121
|
-
style: a({
|
|
122
|
-
gridTemplateColumns: `repeat(${e.options.length}, 1fr)`,
|
|
123
|
-
backgroundColor: "var(--tpl-bg-hover)"
|
|
124
|
-
})
|
|
125
|
-
}, [c.value >= 0 ? (_(), h("div", {
|
|
126
|
-
key: 0,
|
|
127
|
-
class: "tpl:absolute tpl:inset-y-1 tpl:rounded-[var(--tpl-radius-sm)]",
|
|
128
|
-
style: a({
|
|
129
|
-
left: "4px",
|
|
130
|
-
width: `calc((100% - 8px) / ${e.options.length})`,
|
|
131
|
-
transform: l.value,
|
|
132
|
-
backgroundColor: "var(--tpl-bg)",
|
|
133
|
-
boxShadow: "var(--tpl-shadow)",
|
|
134
|
-
transition: "transform 120ms cubic-bezier(0.16, 1, 0.3, 1)"
|
|
135
|
-
})
|
|
136
|
-
}, null, 4)) : m("", !0), (_(!0), h(b, null, o(e.options, (t) => (_(), h("button", {
|
|
137
|
-
key: t.value,
|
|
138
|
-
role: "radio",
|
|
139
|
-
"aria-checked": e.modelValue === t.value,
|
|
140
|
-
"aria-label": t.label,
|
|
141
|
-
disabled: t.disabled,
|
|
142
|
-
"aria-disabled": t.disabled ? "true" : void 0,
|
|
143
|
-
class: "tpl:relative tpl:z-10 tpl:flex tpl:cursor-pointer tpl:disabled:cursor-not-allowed tpl:items-center tpl:justify-center tpl:gap-1 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:bg-transparent tpl:px-2.5 tpl:py-[5px] tpl:text-xs tpl:font-medium",
|
|
144
|
-
style: a({
|
|
145
|
-
color: t.disabled ? "var(--tpl-text-dim)" : e.modelValue === t.value ? "var(--tpl-primary)" : "var(--tpl-text-muted)",
|
|
146
|
-
transition: "color 120ms cubic-bezier(0.16, 1, 0.3, 1)"
|
|
147
|
-
}),
|
|
148
|
-
title: t.label,
|
|
149
|
-
onClick: (e) => t.disabled || r("update:modelValue", t.value)
|
|
150
|
-
}, [t.icon ? (_(), S(i(t.icon), {
|
|
151
|
-
key: 0,
|
|
152
|
-
size: 14,
|
|
153
|
-
"stroke-width": 2
|
|
154
|
-
})) : (_(), h("span", dt, s(t.label), 1))], 12, ut))), 128))], 4));
|
|
155
|
-
}
|
|
156
|
-
}), ft = { class: "tpl:flex tpl:items-stretch" }, pt = [
|
|
157
|
-
"data-testid",
|
|
158
|
-
"value",
|
|
159
|
-
"min",
|
|
160
|
-
"max"
|
|
161
|
-
], X = /* @__PURE__ */ w({
|
|
162
|
-
__name: "NumberWithSuffix",
|
|
163
|
-
props: {
|
|
164
|
-
modelValue: {},
|
|
165
|
-
min: {},
|
|
166
|
-
max: {},
|
|
167
|
-
suffix: {},
|
|
168
|
-
testid: {}
|
|
169
|
-
},
|
|
170
|
-
emits: ["update:modelValue"],
|
|
171
|
-
setup(e, { emit: t }) {
|
|
172
|
-
let n = t;
|
|
173
|
-
function r(e) {
|
|
174
|
-
let t = e.target;
|
|
175
|
-
t.validity?.badInput || n("update:modelValue", Number(t.value));
|
|
176
|
-
}
|
|
177
|
-
return (t, n) => (_(), h("div", ft, [y("input", {
|
|
178
|
-
type: "number",
|
|
179
|
-
"data-testid": e.testid,
|
|
180
|
-
class: v(x(G)),
|
|
181
|
-
value: e.modelValue,
|
|
182
|
-
min: e.min,
|
|
183
|
-
max: e.max,
|
|
184
|
-
onInput: r
|
|
185
|
-
}, null, 42, pt), y("span", { class: v(x(W)) }, s(e.suffix), 3)]));
|
|
186
|
-
}
|
|
187
|
-
}), mt = [
|
|
188
|
-
"aria-pressed",
|
|
189
|
-
"aria-label",
|
|
190
|
-
"title",
|
|
191
|
-
"data-testid"
|
|
192
|
-
], ht = /* @__PURE__ */ w({
|
|
193
|
-
__name: "LinkToggle",
|
|
194
|
-
props: {
|
|
195
|
-
linked: { type: Boolean },
|
|
196
|
-
linkLabel: {},
|
|
197
|
-
unlinkLabel: {},
|
|
198
|
-
testid: {}
|
|
199
|
-
},
|
|
200
|
-
emits: ["toggle"],
|
|
201
|
-
setup(e, { emit: t }) {
|
|
202
|
-
let n = t;
|
|
203
|
-
return (t, r) => (_(), h("button", {
|
|
204
|
-
type: "button",
|
|
205
|
-
class: v(["tpl:flex tpl:h-7 tpl:w-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", e.linked ? "tpl:border-[var(--tpl-primary)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]" : "tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text-muted)] tpl:hover:bg-[var(--tpl-bg-hover)]"]),
|
|
206
|
-
"aria-pressed": e.linked ? "true" : "false",
|
|
207
|
-
"aria-label": e.linked ? e.unlinkLabel : e.linkLabel,
|
|
208
|
-
title: e.linked ? e.unlinkLabel : e.linkLabel,
|
|
209
|
-
"data-testid": e.testid,
|
|
210
|
-
onClick: r[0] ||= (e) => n("toggle")
|
|
211
|
-
}, [e.linked ? (_(), S(x(Ue), {
|
|
212
|
-
key: 0,
|
|
213
|
-
size: 14,
|
|
214
|
-
"stroke-width": 2
|
|
215
|
-
})) : (_(), S(x(lt), {
|
|
216
|
-
key: 1,
|
|
217
|
-
size: 14,
|
|
218
|
-
"stroke-width": 2
|
|
219
|
-
}))], 10, mt));
|
|
220
|
-
}
|
|
221
|
-
}), gt = { class: "tpl:mb-3.5" }, _t = { class: "tpl:mb-2 tpl:flex tpl:items-center tpl:justify-between" }, vt = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, yt = {
|
|
222
|
-
key: 0,
|
|
223
|
-
class: "tpl:mb-3.5"
|
|
224
|
-
}, bt = { class: "tpl:mb-3.5" }, xt = { class: "tpl:mb-3.5" }, St = /* @__PURE__ */ w({
|
|
225
|
-
__name: "BorderControl",
|
|
226
|
-
props: {
|
|
227
|
-
modelValue: {},
|
|
228
|
-
testidPrefix: {}
|
|
229
|
-
},
|
|
230
|
-
emits: ["update:modelValue"],
|
|
231
|
-
setup(e, { emit: n }) {
|
|
232
|
-
let r = e, i = n, { t: a } = B(), o = {
|
|
233
|
-
width: 0,
|
|
234
|
-
style: "solid",
|
|
235
|
-
color: "#000000"
|
|
236
|
-
};
|
|
237
|
-
function c(e, t) {
|
|
238
|
-
return e.width === t.width && e.style === t.style && e.color === t.color;
|
|
239
|
-
}
|
|
240
|
-
let l = p(() => {
|
|
241
|
-
let e = r.modelValue;
|
|
242
|
-
return !e || P.every((t) => c(e[t], e.top));
|
|
243
|
-
}), u = t(l.value);
|
|
244
|
-
T(l, (e) => {
|
|
245
|
-
!e && u.value && (u.value = !1);
|
|
246
|
-
});
|
|
247
|
-
let d = t("top"), g = p(() => {
|
|
248
|
-
let e = u.value ? "top" : d.value;
|
|
249
|
-
return r.modelValue?.[e] ?? o;
|
|
250
|
-
}), S = (e) => !!e && e.width > 0;
|
|
251
|
-
function C(e) {
|
|
252
|
-
if (u.value) {
|
|
253
|
-
i("update:modelValue", S(e) ? F(e) : void 0);
|
|
254
|
-
return;
|
|
255
|
-
}
|
|
256
|
-
let t = {
|
|
257
|
-
...r.modelValue ?? F(o),
|
|
258
|
-
[d.value]: e
|
|
259
|
-
}, n = P.some((e) => S(t[e]));
|
|
260
|
-
i("update:modelValue", n ? t : void 0);
|
|
261
|
-
}
|
|
262
|
-
function w(e) {
|
|
263
|
-
C({
|
|
264
|
-
...g.value,
|
|
265
|
-
width: e > 0 ? e : 0
|
|
266
|
-
});
|
|
267
|
-
}
|
|
268
|
-
function E(e) {
|
|
269
|
-
C({
|
|
270
|
-
...g.value,
|
|
271
|
-
...e
|
|
272
|
-
});
|
|
273
|
-
}
|
|
274
|
-
function D() {
|
|
275
|
-
if (u.value) {
|
|
276
|
-
u.value = !1;
|
|
277
|
-
return;
|
|
278
|
-
}
|
|
279
|
-
u.value = !0;
|
|
280
|
-
let e = r.modelValue;
|
|
281
|
-
if (!e) return;
|
|
282
|
-
let t = S(e[d.value]) ? e[d.value] : P.map((t) => e[t]).find(S);
|
|
283
|
-
i("update:modelValue", t ? F(t) : void 0);
|
|
284
|
-
}
|
|
285
|
-
let O = p(() => P.map((e) => ({
|
|
286
|
-
value: e,
|
|
287
|
-
label: a.spacingControl[e]
|
|
288
|
-
})));
|
|
289
|
-
return (t, n) => (_(), h("div", gt, [
|
|
290
|
-
y("div", _t, [y("span", vt, s(x(a).blockSettings.border), 1), f(ht, {
|
|
291
|
-
linked: u.value,
|
|
292
|
-
"link-label": x(a).blockSettings.linkSides,
|
|
293
|
-
"unlink-label": x(a).blockSettings.unlinkSides,
|
|
294
|
-
testid: `${e.testidPrefix}-border-link`,
|
|
295
|
-
onToggle: D
|
|
296
|
-
}, null, 8, [
|
|
297
|
-
"linked",
|
|
298
|
-
"link-label",
|
|
299
|
-
"unlink-label",
|
|
300
|
-
"testid"
|
|
301
|
-
])]),
|
|
302
|
-
u.value ? m("", !0) : (_(), h("div", yt, [y("label", { class: v(x(U)) }, s(x(a).blockSettings.borderSide), 3), f(Y, {
|
|
303
|
-
options: O.value,
|
|
304
|
-
"model-value": d.value,
|
|
305
|
-
"onUpdate:modelValue": n[0] ||= (e) => d.value = e
|
|
306
|
-
}, null, 8, ["options", "model-value"])])),
|
|
307
|
-
y("div", bt, [y("label", { class: v(x(U)) }, s(x(a).blockSettings.borderWidth), 3), f(X, {
|
|
308
|
-
"model-value": g.value.width,
|
|
309
|
-
min: 0,
|
|
310
|
-
suffix: "px",
|
|
311
|
-
testid: `${e.testidPrefix}-border-width-input`,
|
|
312
|
-
"onUpdate:modelValue": w
|
|
313
|
-
}, null, 8, ["model-value", "testid"])]),
|
|
314
|
-
g.value.width > 0 ? (_(), h(b, { key: 1 }, [y("div", xt, [y("label", { class: v(x(U)) }, s(x(a).blockSettings.borderStyle), 3), f(Y, {
|
|
315
|
-
options: [
|
|
316
|
-
{
|
|
317
|
-
value: "solid",
|
|
318
|
-
label: x(a).divider.solid
|
|
319
|
-
},
|
|
320
|
-
{
|
|
321
|
-
value: "dashed",
|
|
322
|
-
label: x(a).divider.dashed
|
|
323
|
-
},
|
|
324
|
-
{
|
|
325
|
-
value: "dotted",
|
|
326
|
-
label: x(a).divider.dotted
|
|
327
|
-
}
|
|
328
|
-
],
|
|
329
|
-
"model-value": g.value.style,
|
|
330
|
-
"onUpdate:modelValue": n[1] ||= (e) => E({ style: e })
|
|
331
|
-
}, null, 8, ["options", "model-value"])]), y("div", null, [y("label", { class: v(x(U)) }, s(x(a).blockSettings.borderColor), 3), f(V, {
|
|
332
|
-
"model-value": g.value.color,
|
|
333
|
-
"onUpdate:modelValue": n[2] ||= (e) => E({ color: e })
|
|
334
|
-
}, null, 8, ["model-value"])])], 64)) : m("", !0)
|
|
335
|
-
]));
|
|
336
|
-
}
|
|
337
|
-
}), Ct = { class: "tpl:mb-3.5" }, wt = { class: "tpl:mb-2 tpl:flex tpl:items-center tpl:justify-between" }, Tt = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, Et = {
|
|
338
|
-
key: 1,
|
|
339
|
-
class: "tpl:grid tpl:grid-cols-2 tpl:gap-2"
|
|
340
|
-
}, Dt = { class: "tpl:mb-1 tpl:block tpl:text-[10px] tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, Ot = /* @__PURE__ */ w({
|
|
341
|
-
__name: "RadiusControl",
|
|
342
|
-
props: {
|
|
343
|
-
modelValue: {},
|
|
344
|
-
label: {},
|
|
345
|
-
testidPrefix: {},
|
|
346
|
-
max: {}
|
|
347
|
-
},
|
|
348
|
-
emits: ["update:modelValue"],
|
|
349
|
-
setup(e, { emit: n }) {
|
|
350
|
-
let r = e, i = n, { t: a } = B(), c = {
|
|
351
|
-
topLeft: "cornerTopLeft",
|
|
352
|
-
topRight: "cornerTopRight",
|
|
353
|
-
bottomRight: "cornerBottomRight",
|
|
354
|
-
bottomLeft: "cornerBottomLeft"
|
|
355
|
-
}, l = [
|
|
356
|
-
"topLeft",
|
|
357
|
-
"topRight",
|
|
358
|
-
"bottomLeft",
|
|
359
|
-
"bottomRight"
|
|
360
|
-
], u = p(() => {
|
|
361
|
-
let e = r.modelValue ?? 0;
|
|
362
|
-
return typeof e == "number" ? {
|
|
363
|
-
topLeft: e,
|
|
364
|
-
topRight: e,
|
|
365
|
-
bottomRight: e,
|
|
366
|
-
bottomLeft: e
|
|
367
|
-
} : e;
|
|
368
|
-
}), d = p(() => re.every((e) => u.value[e] === u.value.topLeft)), m = t(d.value);
|
|
369
|
-
T(d, (e) => {
|
|
370
|
-
!e && m.value && (m.value = !1);
|
|
371
|
-
});
|
|
372
|
-
function g(e) {
|
|
373
|
-
return Number.isFinite(e) && e >= 0;
|
|
374
|
-
}
|
|
375
|
-
function v(e) {
|
|
376
|
-
g(e) && i("update:modelValue", e);
|
|
377
|
-
}
|
|
378
|
-
function C(e, t) {
|
|
379
|
-
g(t) && i("update:modelValue", {
|
|
380
|
-
...u.value,
|
|
381
|
-
[e]: t
|
|
382
|
-
});
|
|
383
|
-
}
|
|
384
|
-
function w() {
|
|
385
|
-
m.value = !m.value, m.value && i("update:modelValue", u.value.topLeft);
|
|
386
|
-
}
|
|
387
|
-
return (t, n) => (_(), h("div", Ct, [y("div", wt, [y("span", Tt, s(e.label), 1), f(ht, {
|
|
388
|
-
linked: m.value,
|
|
389
|
-
"link-label": x(a).blockSettings.linkCorners,
|
|
390
|
-
"unlink-label": x(a).blockSettings.unlinkCorners,
|
|
391
|
-
testid: `${e.testidPrefix}-border-radius-link`,
|
|
392
|
-
onToggle: w
|
|
393
|
-
}, null, 8, [
|
|
394
|
-
"linked",
|
|
395
|
-
"link-label",
|
|
396
|
-
"unlink-label",
|
|
397
|
-
"testid"
|
|
398
|
-
])]), m.value ? (_(), S(X, {
|
|
399
|
-
key: 0,
|
|
400
|
-
"model-value": u.value.topLeft,
|
|
401
|
-
min: 0,
|
|
402
|
-
max: e.max,
|
|
403
|
-
suffix: "px",
|
|
404
|
-
testid: `${e.testidPrefix}-border-radius-input`,
|
|
405
|
-
"onUpdate:modelValue": v
|
|
406
|
-
}, null, 8, [
|
|
407
|
-
"model-value",
|
|
408
|
-
"max",
|
|
409
|
-
"testid"
|
|
410
|
-
])) : (_(), h("div", Et, [(_(), h(b, null, o(l, (t) => y("div", { key: t }, [y("label", Dt, s(x(a).blockSettings[c[t]]), 1), f(X, {
|
|
411
|
-
"model-value": u.value[t],
|
|
412
|
-
min: 0,
|
|
413
|
-
max: e.max,
|
|
414
|
-
suffix: "px",
|
|
415
|
-
testid: `${e.testidPrefix}-border-radius-${t}-input`,
|
|
416
|
-
"onUpdate:modelValue": (e) => C(t, e)
|
|
417
|
-
}, null, 8, [
|
|
418
|
-
"model-value",
|
|
419
|
-
"max",
|
|
420
|
-
"testid",
|
|
421
|
-
"onUpdate:modelValue"
|
|
422
|
-
])])), 64))]))]));
|
|
423
|
-
}
|
|
424
|
-
}), kt = { class: "tpl:mb-3.5" }, At = ["value"], jt = { value: "" }, Mt = ["value"], Nt = { class: "tpl:mb-3.5" }, Pt = { class: "tpl:mb-3.5" }, Ft = { class: "tpl:mb-3.5" }, It = { class: "tpl:mb-3.5" }, Lt = { class: "tpl:mb-3.5" }, Rt = { class: "tpl:flex tpl:items-stretch" }, zt = ["value"], Bt = { class: "tpl:mb-3.5" }, Vt = ["value"], Ht = { value: "auto" }, Ut = { value: "full" }, Wt = { value: "custom" }, Gt = {
|
|
425
|
-
key: 0,
|
|
426
|
-
class: "tpl:mt-2 tpl:flex tpl:items-stretch"
|
|
427
|
-
}, Kt = ["value"], qt = { class: "tpl:mb-3.5" }, Jt = 200, Yt = /* @__PURE__ */ w({
|
|
428
|
-
__name: "ButtonToolbar",
|
|
429
|
-
props: {
|
|
430
|
-
block: {},
|
|
431
|
-
fontFamilies: {}
|
|
432
|
-
},
|
|
433
|
-
emits: ["update"],
|
|
434
|
-
setup(e, { emit: t }) {
|
|
435
|
-
let n = e, r = t, { t: i } = B(), a = p(() => n.block.width === "full" ? "full" : typeof n.block.width == "number" ? "custom" : "auto");
|
|
436
|
-
function c(e, t) {
|
|
437
|
-
r("update", { [e]: t });
|
|
438
|
-
}
|
|
439
|
-
function l(e) {
|
|
440
|
-
e === "full" ? c("width", "full") : e === "custom" ? c("width", typeof n.block.width == "number" ? n.block.width : Jt) : c("width", void 0);
|
|
441
|
-
}
|
|
442
|
-
function u(e) {
|
|
443
|
-
let t = Number(e);
|
|
444
|
-
!Number.isFinite(t) || t <= 0 || c("width", t);
|
|
445
|
-
}
|
|
446
|
-
return (t, n) => (_(), h(b, null, [
|
|
447
|
-
y("div", kt, [y("label", { class: v(x(U)) }, s(x(i).button.fontFamily), 3), y("select", {
|
|
448
|
-
class: v(x(K)),
|
|
449
|
-
value: x(ot)(e.block.fontFamily),
|
|
450
|
-
onChange: n[0] ||= (e) => c("fontFamily", e.target.value || void 0)
|
|
451
|
-
}, [y("option", jt, s(x(i).button.inheritFont), 1), (_(!0), h(b, null, o(e.fontFamilies, (e) => (_(), h("option", {
|
|
452
|
-
key: e.value,
|
|
453
|
-
value: e.value
|
|
454
|
-
}, s(e.label), 9, Mt))), 128))], 42, At)]),
|
|
455
|
-
y("div", Nt, [y("label", { class: v(x(U)) }, s(x(i).button.text), 3), f(J, {
|
|
456
|
-
"model-value": e.block.text,
|
|
457
|
-
type: "text",
|
|
458
|
-
"onUpdate:modelValue": n[1] ||= (e) => c("text", e)
|
|
459
|
-
}, null, 8, ["model-value"])]),
|
|
460
|
-
y("div", Pt, [
|
|
461
|
-
y("label", { class: v(x(U)) }, s(x(i).button.url), 3),
|
|
462
|
-
f(J, {
|
|
463
|
-
"model-value": e.block.url,
|
|
464
|
-
type: "url",
|
|
465
|
-
placeholder: x(i).button.urlPlaceholder,
|
|
466
|
-
"onUpdate:modelValue": n[2] ||= (e) => c("url", e)
|
|
467
|
-
}, null, 8, ["model-value", "placeholder"]),
|
|
468
|
-
e.block.url ? (_(), S(q, {
|
|
469
|
-
key: 0,
|
|
470
|
-
class: "tpl:mt-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]",
|
|
471
|
-
"model-value": e.block.openInNewTab ?? !1,
|
|
472
|
-
label: x(i).button.openInNewTab,
|
|
473
|
-
"onUpdate:modelValue": n[3] ||= (e) => c("openInNewTab", e)
|
|
474
|
-
}, null, 8, ["model-value", "label"])) : m("", !0)
|
|
475
|
-
]),
|
|
476
|
-
y("div", Ft, [y("label", { class: v(x(U)) }, s(x(i).button.background), 3), f(V, {
|
|
477
|
-
"model-value": e.block.backgroundColor,
|
|
478
|
-
"allow-transparent": "",
|
|
479
|
-
"onUpdate:modelValue": n[4] ||= (e) => c("backgroundColor", e)
|
|
480
|
-
}, null, 8, ["model-value"])]),
|
|
481
|
-
y("div", It, [y("label", { class: v(x(U)) }, s(x(i).button.textColor), 3), f(V, {
|
|
482
|
-
"model-value": e.block.textColor,
|
|
483
|
-
"onUpdate:modelValue": n[5] ||= (e) => c("textColor", e)
|
|
484
|
-
}, null, 8, ["model-value"])]),
|
|
485
|
-
f(St, {
|
|
486
|
-
"model-value": e.block.border,
|
|
487
|
-
"testid-prefix": "button",
|
|
488
|
-
"onUpdate:modelValue": n[6] ||= (e) => c("border", e)
|
|
489
|
-
}, null, 8, ["model-value"]),
|
|
490
|
-
f(Ot, {
|
|
491
|
-
"model-value": e.block.borderRadius,
|
|
492
|
-
label: x(i).button.borderRadius,
|
|
493
|
-
max: 50,
|
|
494
|
-
"testid-prefix": "button",
|
|
495
|
-
"onUpdate:modelValue": n[7] ||= (e) => c("borderRadius", e)
|
|
496
|
-
}, null, 8, ["model-value", "label"]),
|
|
497
|
-
y("div", Lt, [y("label", { class: v(x(U)) }, s(x(i).button.fontSize), 3), y("div", Rt, [y("input", {
|
|
498
|
-
type: "number",
|
|
499
|
-
class: v(x(G)),
|
|
500
|
-
value: e.block.fontSize,
|
|
501
|
-
min: "10",
|
|
502
|
-
max: "36",
|
|
503
|
-
onInput: n[8] ||= (e) => c("fontSize", Number(e.target.value))
|
|
504
|
-
}, null, 42, zt), y("span", { class: v(x(W)) }, "px", 2)])]),
|
|
505
|
-
y("div", Bt, [
|
|
506
|
-
y("label", { class: v(x(U)) }, s(x(i).button.width), 3),
|
|
507
|
-
y("select", {
|
|
508
|
-
class: v(x(K)),
|
|
509
|
-
value: a.value,
|
|
510
|
-
onChange: n[9] ||= (e) => l(e.target.value)
|
|
511
|
-
}, [
|
|
512
|
-
y("option", Ht, s(x(i).button.widthAuto), 1),
|
|
513
|
-
y("option", Ut, s(x(i).button.fullWidth), 1),
|
|
514
|
-
y("option", Wt, s(x(i).button.widthCustom), 1)
|
|
515
|
-
], 42, Vt),
|
|
516
|
-
a.value === "custom" ? (_(), h("div", Gt, [y("input", {
|
|
517
|
-
type: "number",
|
|
518
|
-
class: v(x(G)),
|
|
519
|
-
value: typeof e.block.width == "number" ? e.block.width : Jt,
|
|
520
|
-
min: "20",
|
|
521
|
-
onInput: n[10] ||= (e) => u(e.target.value)
|
|
522
|
-
}, null, 42, Kt), y("span", { class: v(x(W)) }, "px", 2)])) : m("", !0)
|
|
523
|
-
]),
|
|
524
|
-
y("div", qt, [y("label", { class: v(x(U)) }, s(x(i).title.align), 3), f(Y, {
|
|
525
|
-
options: [
|
|
526
|
-
{
|
|
527
|
-
value: "left",
|
|
528
|
-
label: x(i).title.alignLeft
|
|
529
|
-
},
|
|
530
|
-
{
|
|
531
|
-
value: "center",
|
|
532
|
-
label: x(i).title.alignCenter
|
|
533
|
-
},
|
|
534
|
-
{
|
|
535
|
-
value: "right",
|
|
536
|
-
label: x(i).title.alignRight
|
|
537
|
-
}
|
|
538
|
-
],
|
|
539
|
-
"model-value": e.block.align ?? "center",
|
|
540
|
-
"onUpdate:modelValue": n[11] ||= (e) => c("align", e)
|
|
541
|
-
}, null, 8, ["options", "model-value"])])
|
|
542
|
-
], 64));
|
|
543
|
-
}
|
|
544
|
-
}), Xt = { class: "spacing-control" }, Zt = { class: "tpl:mb-2 tpl:block tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, Qt = { class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-1.5" }, $t = { class: "tpl:flex tpl:items-center" }, en = ["aria-label"], tn = ["value", "aria-label"], nn = ["aria-label"], rn = { class: "tpl:flex tpl:items-center tpl:gap-2" }, an = { class: "tpl:flex tpl:items-center" }, on = ["aria-label"], sn = ["value", "aria-label"], cn = ["aria-label"], ln = ["aria-label", "title"], un = { class: "tpl:flex tpl:items-center" }, dn = ["aria-label"], fn = ["value", "aria-label"], pn = ["aria-label"], mn = { class: "tpl:flex tpl:items-center" }, hn = ["aria-label"], gn = ["value", "aria-label"], _n = ["aria-label"], Z = "tpl:flex tpl:items-center tpl:justify-center tpl:w-8 tpl:h-8 tpl:text-[var(--tpl-text-muted)] tpl:bg-[var(--tpl-bg)] tpl:border tpl:border-[var(--tpl-border)] tpl:cursor-pointer tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)] tpl:hover:bg-[var(--tpl-bg-hover)] tpl:hover:text-[var(--tpl-text)] tpl:active:bg-[var(--tpl-bg-active)]", vn = "tpl:w-10 tpl:h-8 tpl:text-center tpl:text-xs tpl:font-medium tpl:border-y tpl:border-x-0 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text)] tpl:bg-[var(--tpl-bg)] tpl:outline-none tpl:transition-all tpl:duration-[120ms] tpl:focus:border-[var(--tpl-primary)] tpl:focus:shadow-[var(--tpl-ring)]", yn = /*#__PURE__*/ Qe(/* @__PURE__ */ w({
|
|
545
|
-
__name: "SpacingControl",
|
|
546
|
-
props: {
|
|
547
|
-
modelValue: {},
|
|
548
|
-
label: {}
|
|
549
|
-
},
|
|
550
|
-
emits: ["update:modelValue"],
|
|
551
|
-
setup(e, { emit: n }) {
|
|
552
|
-
let r = e, i = n, { t: a } = B(), o = p(() => r.modelValue.top === r.modelValue.right && r.modelValue.right === r.modelValue.bottom && r.modelValue.bottom === r.modelValue.left), c = t(o.value);
|
|
553
|
-
T(o, (e) => {
|
|
554
|
-
!e && c.value && (c.value = !1);
|
|
555
|
-
});
|
|
556
|
-
function l(e, t) {
|
|
557
|
-
let n = r.modelValue[e], a = Math.max(0, n + t);
|
|
558
|
-
c.value ? i("update:modelValue", {
|
|
559
|
-
top: a,
|
|
560
|
-
right: a,
|
|
561
|
-
bottom: a,
|
|
562
|
-
left: a
|
|
563
|
-
}) : i("update:modelValue", {
|
|
564
|
-
...r.modelValue,
|
|
565
|
-
[e]: a
|
|
566
|
-
});
|
|
567
|
-
}
|
|
568
|
-
function u(e, t) {
|
|
569
|
-
let n = Math.max(0, t);
|
|
570
|
-
c.value ? i("update:modelValue", {
|
|
571
|
-
top: n,
|
|
572
|
-
right: n,
|
|
573
|
-
bottom: n,
|
|
574
|
-
left: n
|
|
575
|
-
}) : i("update:modelValue", {
|
|
576
|
-
...r.modelValue,
|
|
577
|
-
[e]: n
|
|
578
|
-
});
|
|
579
|
-
}
|
|
580
|
-
function d() {
|
|
581
|
-
if (c.value = !c.value, c.value) {
|
|
582
|
-
let e = r.modelValue.top;
|
|
583
|
-
i("update:modelValue", {
|
|
584
|
-
top: e,
|
|
585
|
-
right: e,
|
|
586
|
-
bottom: e,
|
|
587
|
-
left: e
|
|
588
|
-
});
|
|
589
|
-
}
|
|
590
|
-
}
|
|
591
|
-
return (t, n) => (_(), h("div", Xt, [y("label", Zt, s(e.label), 1), y("div", Qt, [
|
|
592
|
-
y("div", $t, [
|
|
593
|
-
y("button", {
|
|
594
|
-
"aria-label": x(a).spacingControl.decreaseTop,
|
|
595
|
-
class: v([Z, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
596
|
-
onClick: n[0] ||= (e) => l("top", -1)
|
|
597
|
-
}, [f(x(Re), {
|
|
598
|
-
size: 12,
|
|
599
|
-
"stroke-width": 2
|
|
600
|
-
})], 10, en),
|
|
601
|
-
y("input", {
|
|
602
|
-
type: "number",
|
|
603
|
-
class: v(vn),
|
|
604
|
-
value: e.modelValue.top,
|
|
605
|
-
"aria-label": x(a).spacingControl.top,
|
|
606
|
-
min: "0",
|
|
607
|
-
onInput: n[1] ||= (e) => u("top", Number(e.target.value))
|
|
608
|
-
}, null, 40, tn),
|
|
609
|
-
y("button", {
|
|
610
|
-
"aria-label": x(a).spacingControl.increaseTop,
|
|
611
|
-
class: v([Z, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
612
|
-
onClick: n[2] ||= (e) => l("top", 1)
|
|
613
|
-
}, [f(x(H), {
|
|
614
|
-
size: 12,
|
|
615
|
-
"stroke-width": 2
|
|
616
|
-
})], 10, nn)
|
|
617
|
-
]),
|
|
618
|
-
y("div", rn, [
|
|
619
|
-
y("div", an, [
|
|
620
|
-
y("button", {
|
|
621
|
-
"aria-label": x(a).spacingControl.decreaseLeft,
|
|
622
|
-
class: v([Z, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
623
|
-
onClick: n[3] ||= (e) => l("left", -1)
|
|
624
|
-
}, [f(x(Re), {
|
|
625
|
-
size: 12,
|
|
626
|
-
"stroke-width": 2
|
|
627
|
-
})], 10, on),
|
|
628
|
-
y("input", {
|
|
629
|
-
type: "number",
|
|
630
|
-
class: v(vn),
|
|
631
|
-
value: e.modelValue.left,
|
|
632
|
-
"aria-label": x(a).spacingControl.left,
|
|
633
|
-
min: "0",
|
|
634
|
-
onInput: n[4] ||= (e) => u("left", Number(e.target.value))
|
|
635
|
-
}, null, 40, sn),
|
|
636
|
-
y("button", {
|
|
637
|
-
"aria-label": x(a).spacingControl.increaseLeft,
|
|
638
|
-
class: v([Z, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
639
|
-
onClick: n[5] ||= (e) => l("left", 1)
|
|
640
|
-
}, [f(x(H), {
|
|
641
|
-
size: 12,
|
|
642
|
-
"stroke-width": 2
|
|
643
|
-
})], 10, cn)
|
|
644
|
-
]),
|
|
645
|
-
y("button", {
|
|
646
|
-
class: v(["tpl:flex tpl:h-8 tpl:w-8 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", c.value ? "tpl:border-[var(--tpl-primary)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]" : "tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text-muted)] tpl:hover:bg-[var(--tpl-bg-hover)]"]),
|
|
647
|
-
"aria-label": c.value ? x(a).spacingControl.unlock : x(a).spacingControl.lockAll,
|
|
648
|
-
title: c.value ? x(a).spacingControl.unlock : x(a).spacingControl.lockAll,
|
|
649
|
-
onClick: d
|
|
650
|
-
}, [c.value ? (_(), S(x(ct), {
|
|
651
|
-
key: 0,
|
|
652
|
-
size: 14,
|
|
653
|
-
"stroke-width": 2
|
|
654
|
-
})) : (_(), S(x(st), {
|
|
655
|
-
key: 1,
|
|
656
|
-
size: 14,
|
|
657
|
-
"stroke-width": 2
|
|
658
|
-
}))], 10, ln),
|
|
659
|
-
y("div", un, [
|
|
660
|
-
y("button", {
|
|
661
|
-
"aria-label": x(a).spacingControl.decreaseRight,
|
|
662
|
-
class: v([Z, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
663
|
-
onClick: n[6] ||= (e) => l("right", -1)
|
|
664
|
-
}, [f(x(Re), {
|
|
665
|
-
size: 12,
|
|
666
|
-
"stroke-width": 2
|
|
667
|
-
})], 10, dn),
|
|
668
|
-
y("input", {
|
|
669
|
-
type: "number",
|
|
670
|
-
class: v(vn),
|
|
671
|
-
value: e.modelValue.right,
|
|
672
|
-
"aria-label": x(a).spacingControl.right,
|
|
673
|
-
min: "0",
|
|
674
|
-
onInput: n[7] ||= (e) => u("right", Number(e.target.value))
|
|
675
|
-
}, null, 40, fn),
|
|
676
|
-
y("button", {
|
|
677
|
-
"aria-label": x(a).spacingControl.increaseRight,
|
|
678
|
-
class: v([Z, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
679
|
-
onClick: n[8] ||= (e) => l("right", 1)
|
|
680
|
-
}, [f(x(H), {
|
|
681
|
-
size: 12,
|
|
682
|
-
"stroke-width": 2
|
|
683
|
-
})], 10, pn)
|
|
684
|
-
])
|
|
685
|
-
]),
|
|
686
|
-
y("div", mn, [
|
|
687
|
-
y("button", {
|
|
688
|
-
"aria-label": x(a).spacingControl.decreaseBottom,
|
|
689
|
-
class: v([Z, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
690
|
-
onClick: n[9] ||= (e) => l("bottom", -1)
|
|
691
|
-
}, [f(x(Re), {
|
|
692
|
-
size: 12,
|
|
693
|
-
"stroke-width": 2
|
|
694
|
-
})], 10, hn),
|
|
695
|
-
y("input", {
|
|
696
|
-
type: "number",
|
|
697
|
-
class: v(vn),
|
|
698
|
-
value: e.modelValue.bottom,
|
|
699
|
-
"aria-label": x(a).spacingControl.bottom,
|
|
700
|
-
min: "0",
|
|
701
|
-
onInput: n[10] ||= (e) => u("bottom", Number(e.target.value))
|
|
702
|
-
}, null, 40, gn),
|
|
703
|
-
y("button", {
|
|
704
|
-
"aria-label": x(a).spacingControl.increaseBottom,
|
|
705
|
-
class: v([Z, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
706
|
-
onClick: n[11] ||= (e) => l("bottom", 1)
|
|
707
|
-
}, [f(x(H), {
|
|
708
|
-
size: 12,
|
|
709
|
-
"stroke-width": 2
|
|
710
|
-
})], 10, _n)
|
|
711
|
-
])
|
|
712
|
-
])]));
|
|
713
|
-
}
|
|
714
|
-
}), [["__scopeId", "data-v-69591c1e"]]);
|
|
715
|
-
// src/composables/useNaturalImageSize.ts
|
|
716
|
-
function bn(e) {
|
|
717
|
-
let n = t(null), r = () => {};
|
|
718
|
-
return T(e, (e) => {
|
|
719
|
-
r(), n.value = null, e && (r = pe(e, (e) => {
|
|
720
|
-
n.value = e;
|
|
721
|
-
}));
|
|
722
|
-
}, { immediate: !0 }), n;
|
|
723
|
-
}
|
|
724
|
-
function xn() {
|
|
725
|
-
let e = n(Ne, null);
|
|
726
|
-
return async (t) => R(e ? await Sn(e, t) : t);
|
|
727
|
-
}
|
|
728
|
-
function Sn(e, t) {
|
|
729
|
-
let n = (e) => typeof e == "string" && e.length > 0 ? e : t;
|
|
730
|
-
e.lookup(t);
|
|
731
|
-
let r = e.get(t);
|
|
732
|
-
return r === void 0 ? new Promise((r) => {
|
|
733
|
-
let i = T(() => e.get(t), (e) => {
|
|
734
|
-
e !== void 0 && (i(), r(n(e)));
|
|
735
|
-
});
|
|
736
|
-
}) : Promise.resolve(n(r));
|
|
737
|
-
}
|
|
738
|
-
// src/components/toolbar/BackgroundImageControl.vue?vue&type=script&setup=true&lang.ts
|
|
739
|
-
var Cn = { class: "tpl:space-y-3.5" }, wn = ["data-testid"], Tn = ["data-testid"], En = ["data-testid"], Dn = ["aria-label", "data-testid"], On = [
|
|
740
|
-
"aria-label",
|
|
741
|
-
"title",
|
|
742
|
-
"aria-pressed",
|
|
743
|
-
"data-testid",
|
|
744
|
-
"onClick"
|
|
745
|
-
], kn = ["data-testid"], An = /* @__PURE__ */ w({
|
|
746
|
-
__name: "BackgroundImageControl",
|
|
747
|
-
props: {
|
|
748
|
-
modelValue: {},
|
|
749
|
-
testidPrefix: {},
|
|
750
|
-
measure: { type: Boolean },
|
|
751
|
-
heroMode: { type: Boolean }
|
|
752
|
-
},
|
|
753
|
-
emits: ["update:modelValue"],
|
|
754
|
-
setup(e, { emit: r }) {
|
|
755
|
-
let i = e, a = r, { t: c } = B(), l = n(Te, te.liquid), d = p(() => typeof i.modelValue?.url == "string" ? i.modelValue.url : ""), C = p(() => d.value.trim() !== ""), w = xn(), T;
|
|
756
|
-
u(() => clearTimeout(T));
|
|
757
|
-
function E(e) {
|
|
758
|
-
i.measure && !A(e, l) && (T = setTimeout(async () => {
|
|
759
|
-
let t = await w(e), n = i.modelValue;
|
|
760
|
-
t && n?.url === e && a("update:modelValue", {
|
|
761
|
-
...n,
|
|
762
|
-
...L(t)
|
|
763
|
-
});
|
|
764
|
-
}, 300));
|
|
765
|
-
}
|
|
766
|
-
function D(e, t = null) {
|
|
767
|
-
if (clearTimeout(T), e.trim() === "") {
|
|
768
|
-
a("update:modelValue", void 0);
|
|
769
|
-
return;
|
|
770
|
-
}
|
|
771
|
-
let { naturalWidth: n, naturalHeight: r, ...o } = i.modelValue ?? k(e), s = i.measure ? t : null;
|
|
772
|
-
a("update:modelValue", {
|
|
773
|
-
...o,
|
|
774
|
-
url: e,
|
|
775
|
-
...s ? L(s) : {}
|
|
776
|
-
}), s || E(e);
|
|
777
|
-
}
|
|
778
|
-
function O(e) {
|
|
779
|
-
i.modelValue && a("update:modelValue", {
|
|
780
|
-
...i.modelValue,
|
|
781
|
-
...e
|
|
782
|
-
});
|
|
783
|
-
}
|
|
784
|
-
let j = p(() => [
|
|
785
|
-
{
|
|
786
|
-
value: "cover",
|
|
787
|
-
label: c.blockSettings.backgroundSizeCover
|
|
788
|
-
},
|
|
789
|
-
{
|
|
790
|
-
value: "contain",
|
|
791
|
-
label: c.blockSettings.backgroundSizeContain
|
|
792
|
-
},
|
|
793
|
-
{
|
|
794
|
-
value: "auto",
|
|
795
|
-
label: c.blockSettings.backgroundSizeAuto
|
|
796
|
-
}
|
|
797
|
-
]), M = p(() => ({
|
|
798
|
-
"top-left": c.blockSettings.backgroundPositionTopLeft,
|
|
799
|
-
"top-center": c.blockSettings.backgroundPositionTopCenter,
|
|
800
|
-
"top-right": c.blockSettings.backgroundPositionTopRight,
|
|
801
|
-
"center-left": c.blockSettings.backgroundPositionCenterLeft,
|
|
802
|
-
"center-center": c.blockSettings.backgroundPositionCenter,
|
|
803
|
-
"center-right": c.blockSettings.backgroundPositionCenterRight,
|
|
804
|
-
"bottom-left": c.blockSettings.backgroundPositionBottomLeft,
|
|
805
|
-
"bottom-center": c.blockSettings.backgroundPositionBottomCenter,
|
|
806
|
-
"bottom-right": c.blockSettings.backgroundPositionBottomRight
|
|
807
|
-
})), N = p(() => ee.flatMap((e) => ie.map((t) => ({
|
|
808
|
-
x: t,
|
|
809
|
-
y: e,
|
|
810
|
-
label: M.value[`${e}-${t}`]
|
|
811
|
-
}))));
|
|
812
|
-
function P(e) {
|
|
813
|
-
return i.modelValue?.position?.x === e.x && i.modelValue?.position?.y === e.y;
|
|
814
|
-
}
|
|
815
|
-
let F = t(), { canBrowse: ne, isUploading: re, showOverlay: I, openMediaBrowser: ae } = _e({
|
|
816
|
-
target: F,
|
|
817
|
-
blocked: () => A(d.value, l),
|
|
818
|
-
apply: (e) => D(e.url, me(e.width, e.height))
|
|
819
|
-
});
|
|
820
|
-
return (t, n) => (_(), h("div", Cn, [y("div", null, [y("label", { class: v(x(U)) }, s(x(c).blockSettings.backgroundImage), 3), y("div", {
|
|
821
|
-
ref_key: "dropZoneRef",
|
|
822
|
-
ref: F,
|
|
823
|
-
class: "tpl:relative",
|
|
824
|
-
"data-testid": `${e.testidPrefix}-bg-url`
|
|
825
|
-
}, [
|
|
826
|
-
x(I) ? (_(), S(fe, {
|
|
827
|
-
key: 0,
|
|
828
|
-
uploading: x(re)
|
|
829
|
-
}, null, 8, ["uploading"])) : m("", !0),
|
|
830
|
-
f(J, {
|
|
831
|
-
"model-value": d.value,
|
|
832
|
-
type: "url",
|
|
833
|
-
placeholder: x(c).blockSettings.backgroundImagePlaceholder,
|
|
834
|
-
"onUpdate:modelValue": D
|
|
835
|
-
}, null, 8, ["model-value", "placeholder"]),
|
|
836
|
-
x(ne) ? (_(), h("button", {
|
|
837
|
-
key: 1,
|
|
838
|
-
type: "button",
|
|
839
|
-
"data-testid": `${e.testidPrefix}-bg-browse`,
|
|
840
|
-
class: "tpl:mt-2 tpl:flex tpl:w-full tpl:items-center tpl:justify-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",
|
|
841
|
-
style: {
|
|
842
|
-
"border-color": "var(--tpl-border)",
|
|
843
|
-
color: "var(--tpl-primary)",
|
|
844
|
-
"background-color": "var(--tpl-bg)"
|
|
845
|
-
},
|
|
846
|
-
onClick: n[0] ||= (...e) => x(ae) && x(ae)(...e)
|
|
847
|
-
}, [f(x(Ve), {
|
|
848
|
-
size: 14,
|
|
849
|
-
"stroke-width": 1.5
|
|
850
|
-
}), g(" " + s(x(c).image.browseMedia), 1)], 8, Tn)) : m("", !0)
|
|
851
|
-
], 8, wn)]), C.value && e.modelValue ? (_(), h(b, { key: 0 }, [
|
|
852
|
-
e.heroMode ? m("", !0) : (_(), h("div", {
|
|
853
|
-
key: 0,
|
|
854
|
-
"data-testid": `${e.testidPrefix}-bg-size`
|
|
855
|
-
}, [y("label", { class: v(x(U)) }, s(x(c).blockSettings.backgroundSize), 3), f(Y, {
|
|
856
|
-
options: j.value,
|
|
857
|
-
"model-value": e.modelValue.size,
|
|
858
|
-
"onUpdate:modelValue": n[1] ||= (e) => O({ size: e })
|
|
859
|
-
}, null, 8, ["options", "model-value"])], 8, En)),
|
|
860
|
-
y("div", null, [y("label", { class: v(x(U)) }, s(x(c).blockSettings.backgroundPosition), 3), y("div", {
|
|
861
|
-
role: "group",
|
|
862
|
-
"aria-label": x(c).blockSettings.backgroundPosition,
|
|
863
|
-
"data-testid": `${e.testidPrefix}-bg-position`,
|
|
864
|
-
class: "tpl:grid tpl:w-24 tpl:grid-cols-3 tpl:gap-1"
|
|
865
|
-
}, [(_(!0), h(b, null, o(N.value, (t) => (_(), h("button", {
|
|
866
|
-
key: `${t.y}-${t.x}`,
|
|
867
|
-
type: "button",
|
|
868
|
-
"aria-label": t.label,
|
|
869
|
-
title: t.label,
|
|
870
|
-
"aria-pressed": P(t),
|
|
871
|
-
"data-testid": `${e.testidPrefix}-bg-position-${t.y}-${t.x}`,
|
|
872
|
-
class: v(["tpl:flex tpl:h-6 tpl:items-center tpl:justify-center tpl:rounded tpl:border tpl:transition-colors", P(t) ? "tpl:border-[var(--tpl-primary)]" : "tpl:border-[var(--tpl-border)] tpl:hover:border-[var(--tpl-text-dim)]"]),
|
|
873
|
-
onClick: (e) => O({ position: {
|
|
874
|
-
x: t.x,
|
|
875
|
-
y: t.y
|
|
876
|
-
} })
|
|
877
|
-
}, [y("span", { class: v(["tpl:block tpl:h-1.5 tpl:w-1.5 tpl:rounded-full", P(t) ? "tpl:bg-[var(--tpl-primary)]" : "tpl:bg-[var(--tpl-text-dim)]"]) }, null, 2)], 10, On))), 128))], 8, Dn)]),
|
|
878
|
-
e.heroMode ? m("", !0) : (_(), h("div", {
|
|
879
|
-
key: 1,
|
|
880
|
-
"data-testid": `${e.testidPrefix}-bg-repeat`
|
|
881
|
-
}, [f(q, {
|
|
882
|
-
class: "tpl:text-xs tpl:text-[var(--tpl-text)]",
|
|
883
|
-
"model-value": e.modelValue.repeat,
|
|
884
|
-
label: x(c).blockSettings.backgroundRepeat,
|
|
885
|
-
"onUpdate:modelValue": n[2] ||= (e) => O({ repeat: e })
|
|
886
|
-
}, null, 8, ["model-value", "label"])], 8, kn))
|
|
887
|
-
], 64)) : m("", !0)]));
|
|
888
|
-
}
|
|
889
|
-
}), jn = ["data-testid"], Mn = { class: "tpl:mt-3" }, Nn = /* @__PURE__ */ w({
|
|
890
|
-
__name: "CollapsibleSection",
|
|
891
|
-
props: {
|
|
892
|
-
title: {},
|
|
893
|
-
open: { type: Boolean },
|
|
894
|
-
noBorder: { type: Boolean },
|
|
895
|
-
headerTestId: {}
|
|
896
|
-
},
|
|
897
|
-
emits: ["toggle"],
|
|
898
|
-
setup(e) {
|
|
899
|
-
return (t, n) => (_(), h("div", { class: v(["tpl:py-3", e.noBorder ? "" : "tpl:border-t tpl:border-[var(--tpl-border)]"]) }, [y("button", {
|
|
900
|
-
type: "button",
|
|
901
|
-
"data-testid": e.headerTestId,
|
|
902
|
-
class: "tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-center tpl:gap-1.5 tpl:border-none tpl:bg-transparent tpl:p-0 tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]",
|
|
903
|
-
onClick: n[0] ||= (e) => t.$emit("toggle")
|
|
904
|
-
}, [f(x(Ie), {
|
|
905
|
-
class: v(["tpl:transition-transform tpl:duration-200", e.open ? "tpl:rotate-0" : "tpl:-rotate-90"]),
|
|
906
|
-
size: 12,
|
|
907
|
-
"stroke-width": 2
|
|
908
|
-
}, null, 8, ["class"]), y("span", null, s(e.title), 1)], 8, jn), l(y("div", Mn, [c(t.$slots, "default")], 512), [[D, e.open]])], 2));
|
|
909
|
-
}
|
|
910
|
-
}), Pn = {
|
|
911
|
-
key: 0,
|
|
912
|
-
"data-testid": "section-hero-columns-note",
|
|
913
|
-
class: "tpl:mt-3.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
914
|
-
}, Fn = {
|
|
915
|
-
key: 1,
|
|
916
|
-
"data-testid": "section-hero",
|
|
917
|
-
class: "tpl:mt-3.5 tpl:space-y-3.5"
|
|
918
|
-
}, In = { "data-testid": "section-hero-height" }, Ln = {
|
|
919
|
-
key: 0,
|
|
920
|
-
class: "tpl:mt-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
921
|
-
}, Rn = {
|
|
922
|
-
key: 1,
|
|
923
|
-
class: "tpl:mt-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
924
|
-
}, zn = {
|
|
925
|
-
key: 1,
|
|
926
|
-
"data-testid": "section-hero-align"
|
|
927
|
-
}, Bn = 300, Vn = /* @__PURE__ */ w({
|
|
928
|
-
__name: "HeroControl",
|
|
929
|
-
props: { section: {} },
|
|
930
|
-
emits: ["update"],
|
|
931
|
-
setup(e, { emit: t }) {
|
|
932
|
-
function r(e) {
|
|
933
|
-
return typeof e == "number" && Number.isFinite(e) && e >= 1;
|
|
934
|
-
}
|
|
935
|
-
let i = e, a = t, { t: o } = B(), c = n(Te, te.liquid), l = n(Oe, null), u = n(Ce, void 0), d = xn(), g = p(() => typeof i.section.backgroundImage?.url == "string" ? i.section.backgroundImage.url : ""), b = p(() => g.value.trim() !== ""), C = p(() => A(g.value, c)), w = p(() => i.section.hero), T = p(() => i.section.columns === "1"), E = p(() => w.value ? r(w.value.height) ? "fixed" : "image" : "fit"), D = p(() => r(w.value?.height) ? w.value.height : Bn), O = p(() => [
|
|
936
|
-
{
|
|
937
|
-
value: "fit",
|
|
938
|
-
label: o.blockSettings.heroHeightFit
|
|
939
|
-
},
|
|
940
|
-
{
|
|
941
|
-
value: "image",
|
|
942
|
-
label: o.blockSettings.heroHeightImage,
|
|
943
|
-
disabled: C.value
|
|
944
|
-
},
|
|
945
|
-
{
|
|
946
|
-
value: "fixed",
|
|
947
|
-
label: o.blockSettings.heroHeightFixed
|
|
948
|
-
}
|
|
949
|
-
]), k = p(() => [
|
|
950
|
-
{
|
|
951
|
-
value: "top",
|
|
952
|
-
label: o.blockSettings.heroAlignTop
|
|
953
|
-
},
|
|
954
|
-
{
|
|
955
|
-
value: "middle",
|
|
956
|
-
label: o.blockSettings.heroAlignMiddle
|
|
957
|
-
},
|
|
958
|
-
{
|
|
959
|
-
value: "bottom",
|
|
960
|
-
label: o.blockSettings.heroAlignBottom
|
|
961
|
-
}
|
|
962
|
-
]), j = p(() => E.value === "image" && b.value && !C.value && I(i.section.backgroundImage) === null);
|
|
963
|
-
function M() {
|
|
964
|
-
return (l ? ve(l.content.value, i.section.id, u) : null) ?? de(l?.state.content.settings);
|
|
965
|
-
}
|
|
966
|
-
function N(e) {
|
|
967
|
-
let t = w.value?.verticalAlign ?? "middle";
|
|
968
|
-
if (e === "image") {
|
|
969
|
-
E.value !== "image" && a("update", { hero: {
|
|
970
|
-
height: "image",
|
|
971
|
-
verticalAlign: t
|
|
972
|
-
} }), P();
|
|
973
|
-
return;
|
|
974
|
-
}
|
|
975
|
-
if (e === E.value) return;
|
|
976
|
-
if (e === "fit") {
|
|
977
|
-
a("update", { hero: void 0 });
|
|
978
|
-
return;
|
|
979
|
-
}
|
|
980
|
-
let n = I(i.section.backgroundImage), r = n === null ? Bn : Math.round(M() * n);
|
|
981
|
-
a("update", { hero: {
|
|
982
|
-
height: r,
|
|
983
|
-
verticalAlign: t
|
|
984
|
-
} });
|
|
985
|
-
}
|
|
986
|
-
async function P() {
|
|
987
|
-
let e = i.section.backgroundImage;
|
|
988
|
-
if (!e || !b.value || C.value || I(e) !== null) return;
|
|
989
|
-
let t = e.url, n = await d(t), r = i.section.backgroundImage;
|
|
990
|
-
n && r && r.url === t && a("update", { backgroundImage: {
|
|
991
|
-
...r,
|
|
992
|
-
...L(n)
|
|
993
|
-
} });
|
|
994
|
-
}
|
|
995
|
-
function F(e) {
|
|
996
|
-
!w.value || !Number.isFinite(e) || e < 1 || a("update", { hero: {
|
|
997
|
-
...w.value,
|
|
998
|
-
height: Math.round(e)
|
|
999
|
-
} });
|
|
1000
|
-
}
|
|
1001
|
-
function ee(e) {
|
|
1002
|
-
w.value && a("update", { hero: {
|
|
1003
|
-
...w.value,
|
|
1004
|
-
verticalAlign: e
|
|
1005
|
-
} });
|
|
1006
|
-
}
|
|
1007
|
-
return (e, t) => !T.value && w.value ? (_(), h("p", Pn, s(x(o).section.heroNeedsOneColumn), 1)) : T.value && (b.value || w.value) ? (_(), h("div", Fn, [
|
|
1008
|
-
y("div", In, [
|
|
1009
|
-
y("label", { class: v(x(U)) }, s(x(o).blockSettings.heroHeight), 3),
|
|
1010
|
-
f(Y, {
|
|
1011
|
-
options: O.value,
|
|
1012
|
-
"model-value": E.value,
|
|
1013
|
-
"onUpdate:modelValue": N
|
|
1014
|
-
}, null, 8, ["options", "model-value"]),
|
|
1015
|
-
C.value ? (_(), h("p", Ln, s(x(o).blockSettings.heroMatchImageMergeTag), 1)) : j.value ? (_(), h("p", Rn, s(x(o).blockSettings.heroSizeUnknown), 1)) : m("", !0)
|
|
1016
|
-
]),
|
|
1017
|
-
E.value === "fixed" ? (_(), S(X, {
|
|
1018
|
-
key: 0,
|
|
1019
|
-
"model-value": D.value,
|
|
1020
|
-
min: 1,
|
|
1021
|
-
suffix: "px",
|
|
1022
|
-
testid: "section-hero-height-px",
|
|
1023
|
-
"onUpdate:modelValue": F
|
|
1024
|
-
}, null, 8, ["model-value"])) : m("", !0),
|
|
1025
|
-
w.value ? (_(), h("div", zn, [y("label", { class: v(x(U)) }, s(x(o).blockSettings.heroAlign), 3), f(Y, {
|
|
1026
|
-
options: k.value,
|
|
1027
|
-
"model-value": w.value.verticalAlign,
|
|
1028
|
-
"onUpdate:modelValue": ee
|
|
1029
|
-
}, null, 8, ["options", "model-value"])])) : m("", !0)
|
|
1030
|
-
])) : m("", !0);
|
|
1031
|
-
}
|
|
1032
|
-
}), Hn = { class: "tpl:space-y-2" }, Un = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Wn = { class: "tpl:space-y-2" }, Gn = ["value"], Kn = { value: "" }, qn = ["label"], Jn = ["value"], Yn = ["value"], Xn = {
|
|
1033
|
-
key: 0,
|
|
1034
|
-
value: "__custom__"
|
|
1035
|
-
}, Zn = {
|
|
1036
|
-
key: 0,
|
|
1037
|
-
class: "tpl:space-y-2"
|
|
1038
|
-
}, Qn = { class: "tpl:mb-1 tpl:block tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, $n = { class: "tpl:mb-1 tpl:block tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, er = { class: "tpl:flex tpl:justify-end" }, tr = ["disabled"], nr = {
|
|
1039
|
-
key: 0,
|
|
1040
|
-
class: "tpl:text-[10px] tpl:text-[var(--tpl-text-muted)]"
|
|
1041
|
-
}, rr = { class: "tpl:space-y-1" }, ir = { class: "tpl:m-0 tpl:overflow-x-auto tpl:rounded tpl:bg-[var(--tpl-bg)] tpl:p-2 tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-muted)]" }, ar = {
|
|
1042
|
-
key: 0,
|
|
1043
|
-
class: "tpl:m-0 tpl:overflow-x-auto tpl:rounded tpl:bg-[var(--tpl-bg)] tpl:p-2 tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-muted)]"
|
|
1044
|
-
}, or = /* @__PURE__ */ w({
|
|
1045
|
-
__name: "CommonBlockSettings",
|
|
1046
|
-
props: {
|
|
1047
|
-
block: {},
|
|
1048
|
-
isFirstSection: { type: Boolean }
|
|
1049
|
-
},
|
|
1050
|
-
emits: ["update"],
|
|
1051
|
-
setup(e, { emit: a }) {
|
|
1052
|
-
let c = e, u = a, { t: C } = B(), w = n(ke, []), D = n(Ae, !1), O = d(/* @__PURE__ */ new Set()), k = t(!1), A = t(""), j = t(""), M = [{
|
|
1053
|
-
key: "desktop",
|
|
1054
|
-
icon: We,
|
|
1055
|
-
labelKey: "showOnDesktop"
|
|
1056
|
-
}, {
|
|
1057
|
-
key: "mobile",
|
|
1058
|
-
icon: Ge,
|
|
1059
|
-
labelKey: "showOnMobile"
|
|
1060
|
-
}];
|
|
1061
|
-
function N(e) {
|
|
1062
|
-
O.has(e) ? O.delete(e) : O.add(e);
|
|
1063
|
-
}
|
|
1064
|
-
let P = p(() => w.length > 0 || D), F = p(() => c.block.displayCondition ? !w.some((e) => e.label === c.block.displayCondition?.label) : !1);
|
|
1065
|
-
function ee() {
|
|
1066
|
-
k.value = !0, F.value && c.block.displayCondition ? (A.value = c.block.displayCondition.before, j.value = c.block.displayCondition.after ?? "") : (A.value = "", j.value = "");
|
|
1067
|
-
}
|
|
1068
|
-
function te() {
|
|
1069
|
-
A.value.trim() && (u("update", { displayCondition: {
|
|
1070
|
-
label: C.blockSettings.customCondition,
|
|
1071
|
-
before: A.value.trim(),
|
|
1072
|
-
after: j.value.trim()
|
|
1073
|
-
} }), k.value = !1, A.value = "", j.value = "");
|
|
1074
|
-
}
|
|
1075
|
-
T(() => c.block.displayCondition, (e) => {
|
|
1076
|
-
e ? F.value && (A.value = e.before, j.value = e.after ?? "") : (k.value = !1, A.value = "", j.value = "");
|
|
1077
|
-
}, { immediate: !0 });
|
|
1078
|
-
let ne = p(() => {
|
|
1079
|
-
let e = {};
|
|
1080
|
-
for (let t of w) {
|
|
1081
|
-
let n = t.group ?? "";
|
|
1082
|
-
e[n] || (e[n] = []), e[n].push(t);
|
|
1083
|
-
}
|
|
1084
|
-
return e;
|
|
1085
|
-
}), re = p(() => c.block.type === "section" && oe(c.block)?.applied === !0);
|
|
1086
|
-
function I(e, t) {
|
|
1087
|
-
u("update", { styles: {
|
|
1088
|
-
...c.block.styles,
|
|
1089
|
-
[e]: t
|
|
1090
|
-
} });
|
|
1091
|
-
}
|
|
1092
|
-
function ie(e) {
|
|
1093
|
-
return c.block.visibility?.[e] !== !1;
|
|
1094
|
-
}
|
|
1095
|
-
function ae(e) {
|
|
1096
|
-
let t = {
|
|
1097
|
-
desktop: ie("desktop"),
|
|
1098
|
-
mobile: ie("mobile")
|
|
1099
|
-
};
|
|
1100
|
-
t[e] = !t[e], u("update", { visibility: t });
|
|
1101
|
-
}
|
|
1102
|
-
return (t, n) => (_(), h("div", { class: v(["tpl:flex tpl:flex-col", e.isFirstSection ? "" : "tpl:mt-4"]) }, [
|
|
1103
|
-
f(Nn, {
|
|
1104
|
-
title: x(C).blockSettings.spacing,
|
|
1105
|
-
open: O.has("spacing"),
|
|
1106
|
-
"no-border": e.isFirstSection,
|
|
1107
|
-
onToggle: n[1] ||= (e) => N("spacing")
|
|
1108
|
-
}, {
|
|
1109
|
-
default: r(() => [f(yn, {
|
|
1110
|
-
label: x(C).blockSettings.padding,
|
|
1111
|
-
"model-value": e.block.styles.padding,
|
|
1112
|
-
"onUpdate:modelValue": n[0] ||= (e) => I("padding", e)
|
|
1113
|
-
}, null, 8, ["label", "model-value"])]),
|
|
1114
|
-
_: 1
|
|
1115
|
-
}, 8, [
|
|
1116
|
-
"title",
|
|
1117
|
-
"open",
|
|
1118
|
-
"no-border"
|
|
1119
|
-
]),
|
|
1120
|
-
f(Nn, {
|
|
1121
|
-
title: x(C).blockSettings.background,
|
|
1122
|
-
open: O.has("bg"),
|
|
1123
|
-
"header-test-id": "block-settings-background",
|
|
1124
|
-
onToggle: n[5] ||= (e) => N("bg")
|
|
1125
|
-
}, {
|
|
1126
|
-
default: r(() => [
|
|
1127
|
-
y("label", { class: v(x(U)) }, s(x(C).blockSettings.color), 3),
|
|
1128
|
-
f(V, {
|
|
1129
|
-
"model-value": e.block.styles.backgroundColor ?? "",
|
|
1130
|
-
"allow-transparent": "",
|
|
1131
|
-
"onUpdate:modelValue": n[2] ||= (e) => I("backgroundColor", e)
|
|
1132
|
-
}, null, 8, ["model-value"]),
|
|
1133
|
-
e.block.type === "section" ? (_(), S(An, {
|
|
1134
|
-
key: 0,
|
|
1135
|
-
class: "tpl:mt-3.5",
|
|
1136
|
-
"model-value": e.block.backgroundImage,
|
|
1137
|
-
"testid-prefix": "section",
|
|
1138
|
-
measure: "",
|
|
1139
|
-
"hero-mode": re.value,
|
|
1140
|
-
"onUpdate:modelValue": n[3] ||= (e) => u("update", { backgroundImage: e })
|
|
1141
|
-
}, null, 8, ["model-value", "hero-mode"])) : m("", !0),
|
|
1142
|
-
e.block.type === "section" ? (_(), S(Vn, {
|
|
1143
|
-
key: 1,
|
|
1144
|
-
section: e.block,
|
|
1145
|
-
onUpdate: n[4] ||= (e) => u("update", e)
|
|
1146
|
-
}, null, 8, ["section"])) : m("", !0)
|
|
1147
|
-
]),
|
|
1148
|
-
_: 1
|
|
1149
|
-
}, 8, ["title", "open"]),
|
|
1150
|
-
f(Nn, {
|
|
1151
|
-
title: x(C).blockSettings.display,
|
|
1152
|
-
open: O.has("display"),
|
|
1153
|
-
onToggle: n[6] ||= (e) => N("display")
|
|
1154
|
-
}, {
|
|
1155
|
-
default: r(() => [y("div", Hn, [(_(), h(b, null, o(M, (e) => f(q, {
|
|
1156
|
-
key: e.key,
|
|
1157
|
-
class: "tpl:text-xs tpl:text-[var(--tpl-text)]",
|
|
1158
|
-
"model-value": ie(e.key),
|
|
1159
|
-
label: x(C).blockSettings[e.labelKey],
|
|
1160
|
-
"onUpdate:modelValue": (t) => ae(e.key)
|
|
1161
|
-
}, {
|
|
1162
|
-
default: r(() => [y("span", Un, [(_(), S(i(e.icon), {
|
|
1163
|
-
size: 14,
|
|
1164
|
-
"stroke-width": 1.5
|
|
1165
|
-
})), g(" " + s(x(C).blockSettings[e.labelKey]), 1)])]),
|
|
1166
|
-
_: 2
|
|
1167
|
-
}, 1032, [
|
|
1168
|
-
"model-value",
|
|
1169
|
-
"label",
|
|
1170
|
-
"onUpdate:modelValue"
|
|
1171
|
-
])), 64))])]),
|
|
1172
|
-
_: 1
|
|
1173
|
-
}, 8, ["title", "open"]),
|
|
1174
|
-
P.value ? (_(), S(Nn, {
|
|
1175
|
-
key: 0,
|
|
1176
|
-
"header-test-id": "display-condition-section",
|
|
1177
|
-
title: x(C).blockSettings.displayCondition,
|
|
1178
|
-
open: O.has("condition"),
|
|
1179
|
-
onToggle: n[10] ||= (e) => N("condition")
|
|
1180
|
-
}, {
|
|
1181
|
-
default: r(() => [y("div", Wn, [y("select", {
|
|
1182
|
-
"data-testid": "display-condition-select",
|
|
1183
|
-
class: v(["tpl:w-full tpl:rounded-md tpl:border tpl:px-2.5 tpl:py-2 tpl:text-xs tpl:outline-none tpl:transition-all tpl:focus:border-[var(--tpl-primary)] tpl:focus:shadow-[0_0_0_3px_var(--tpl-primary-light)]", e.block.displayCondition ? "tpl:border-[var(--tpl-primary)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-text)]" : "tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]"]),
|
|
1184
|
-
value: k.value || F.value ? "__custom__" : e.block.displayCondition?.label ?? "",
|
|
1185
|
-
onChange: n[7] ||= (e) => {
|
|
1186
|
-
let t = e.target.value;
|
|
1187
|
-
if (t === "__custom__") {
|
|
1188
|
-
ee();
|
|
1189
|
-
return;
|
|
1190
|
-
}
|
|
1191
|
-
if (k.value = !1, !t) {
|
|
1192
|
-
u("update", { displayCondition: void 0 });
|
|
1193
|
-
return;
|
|
1194
|
-
}
|
|
1195
|
-
let n = x(w).find((e) => e.label === t);
|
|
1196
|
-
n && u("update", { displayCondition: n });
|
|
1197
|
-
}
|
|
1198
|
-
}, [
|
|
1199
|
-
y("option", Kn, s(x(C).blockSettings.noCondition), 1),
|
|
1200
|
-
(_(!0), h(b, null, o(ne.value, (e, t) => (_(), h(b, { key: t }, [t ? (_(), h("optgroup", {
|
|
1201
|
-
key: 0,
|
|
1202
|
-
label: String(t)
|
|
1203
|
-
}, [(_(!0), h(b, null, o(e, (e) => (_(), h("option", {
|
|
1204
|
-
key: e.label,
|
|
1205
|
-
value: e.label
|
|
1206
|
-
}, s(e.label), 9, Jn))), 128))], 8, qn)) : (_(!0), h(b, { key: 1 }, o(e, (e) => (_(), h("option", {
|
|
1207
|
-
key: e.label,
|
|
1208
|
-
value: e.label
|
|
1209
|
-
}, s(e.label), 9, Yn))), 128))], 64))), 128)),
|
|
1210
|
-
x(D) ? (_(), h("option", Xn, s(x(C).blockSettings.customCondition), 1)) : m("", !0)
|
|
1211
|
-
], 42, Gn), k.value || F.value ? (_(), h("div", Zn, [
|
|
1212
|
-
y("div", null, [y("label", Qn, s(x(C).blockSettings.customConditionBefore), 1), l(y("textarea", {
|
|
1213
|
-
"onUpdate:modelValue": n[8] ||= (e) => A.value = e,
|
|
1214
|
-
rows: "2",
|
|
1215
|
-
class: v(x($e))
|
|
1216
|
-
}, null, 2), [[E, A.value]])]),
|
|
1217
|
-
y("div", null, [y("label", $n, s(x(C).blockSettings.customConditionAfter), 1), l(y("textarea", {
|
|
1218
|
-
"onUpdate:modelValue": n[9] ||= (e) => j.value = e,
|
|
1219
|
-
rows: "2",
|
|
1220
|
-
class: v(x($e))
|
|
1221
|
-
}, null, 2), [[E, j.value]])]),
|
|
1222
|
-
y("div", er, [y("button", {
|
|
1223
|
-
type: "button",
|
|
1224
|
-
class: v(x(rt)),
|
|
1225
|
-
disabled: !A.value.trim(),
|
|
1226
|
-
onClick: te
|
|
1227
|
-
}, s(x(C).blockSettings.applyCondition), 11, tr)])
|
|
1228
|
-
])) : e.block.displayCondition && !F.value ? (_(), h(b, { key: 1 }, [e.block.displayCondition.description ? (_(), h("p", nr, s(e.block.displayCondition.description), 1)) : m("", !0), y("div", rr, [y("pre", ir, s(e.block.displayCondition.before), 1), e.block.displayCondition.after ? (_(), h("pre", ar, s(e.block.displayCondition.after), 1)) : m("", !0)])], 64)) : m("", !0)])]),
|
|
1229
|
-
_: 1
|
|
1230
|
-
}, 8, ["title", "open"])) : m("", !0)
|
|
1231
|
-
], 2));
|
|
1232
|
-
}
|
|
1233
|
-
}), sr = ["title"], cr = /* @__PURE__ */ w({
|
|
1234
|
-
__name: "BooleanField",
|
|
1235
|
-
props: {
|
|
1236
|
-
field: {},
|
|
1237
|
-
modelValue: { type: Boolean },
|
|
1238
|
-
readOnly: { type: Boolean }
|
|
1239
|
-
},
|
|
1240
|
-
emits: ["update:modelValue"],
|
|
1241
|
-
setup(e, { emit: t }) {
|
|
1242
|
-
let n = t, { t: i } = B();
|
|
1243
|
-
return (t, a) => (_(), h("div", {
|
|
1244
|
-
class: "tpl:mb-3.5",
|
|
1245
|
-
title: e.readOnly ? x(i).customBlocks.dataSource.readOnlyTooltip : void 0
|
|
1246
|
-
}, [f(q, {
|
|
1247
|
-
class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]",
|
|
1248
|
-
"model-value": e.modelValue,
|
|
1249
|
-
label: e.field.label,
|
|
1250
|
-
required: e.field.required,
|
|
1251
|
-
disabled: e.readOnly,
|
|
1252
|
-
"onUpdate:modelValue": a[0] ||= (e) => n("update:modelValue", e)
|
|
1253
|
-
}, {
|
|
1254
|
-
default: r(() => [g(s(e.field.label) + " ", 1), e.readOnly ? (_(), S(x(ct), {
|
|
1255
|
-
key: 0,
|
|
1256
|
-
size: 12,
|
|
1257
|
-
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]"
|
|
1258
|
-
})) : m("", !0)]),
|
|
1259
|
-
_: 1
|
|
1260
|
-
}, 8, [
|
|
1261
|
-
"model-value",
|
|
1262
|
-
"label",
|
|
1263
|
-
"required",
|
|
1264
|
-
"disabled"
|
|
1265
|
-
])], 8, sr));
|
|
1266
|
-
}
|
|
1267
|
-
}), lr = { class: "tpl:mb-3.5" }, ur = ["title"], dr = { class: "tpl-sr-only" }, fr = ["title"], pr = { class: "tpl-sr-only" }, Q = /* @__PURE__ */ w({
|
|
1268
|
-
__name: "FieldWrapper",
|
|
1269
|
-
props: {
|
|
1270
|
-
label: {},
|
|
1271
|
-
required: { type: Boolean },
|
|
1272
|
-
readOnly: { type: Boolean }
|
|
1273
|
-
},
|
|
1274
|
-
setup(e) {
|
|
1275
|
-
let { t } = B();
|
|
1276
|
-
return (n, r) => (_(), h("div", lr, [y("label", { class: v(x(U)) }, [
|
|
1277
|
-
g(s(e.label) + " ", 1),
|
|
1278
|
-
e.readOnly ? (_(), h("span", {
|
|
1279
|
-
key: 0,
|
|
1280
|
-
title: x(t).customBlocks.dataSource.readOnlyTooltip
|
|
1281
|
-
}, [f(x(ct), {
|
|
1282
|
-
size: 12,
|
|
1283
|
-
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]",
|
|
1284
|
-
"aria-hidden": "true"
|
|
1285
|
-
}), y("span", dr, s(x(t).customBlocks.dataSource.readOnlyTooltip), 1)], 8, ur)) : m("", !0),
|
|
1286
|
-
e.required ? (_(), h("span", {
|
|
1287
|
-
key: 1,
|
|
1288
|
-
class: "tpl:text-[var(--tpl-danger)]",
|
|
1289
|
-
title: x(t).customBlocks.fields.required
|
|
1290
|
-
}, [r[0] ||= y("span", { "aria-hidden": "true" }, "*", -1), y("span", pr, s(x(t).customBlocks.fields.required), 1)], 8, fr)) : m("", !0)
|
|
1291
|
-
], 2), c(n.$slots, "default")]));
|
|
1292
|
-
}
|
|
1293
|
-
}), mr = /* @__PURE__ */ w({
|
|
1294
|
-
__name: "ColorField",
|
|
1295
|
-
props: {
|
|
1296
|
-
field: {},
|
|
1297
|
-
modelValue: {},
|
|
1298
|
-
readOnly: { type: Boolean }
|
|
1299
|
-
},
|
|
1300
|
-
emits: ["update:modelValue"],
|
|
1301
|
-
setup(e, { emit: t }) {
|
|
1302
|
-
let i = e, a = t, { t: o } = B(), s = n(De, Pe), c = p(() => be(i.field, s));
|
|
1303
|
-
return (t, n) => (_(), S(Q, {
|
|
1304
|
-
label: e.field.label,
|
|
1305
|
-
required: e.field.required,
|
|
1306
|
-
"read-only": e.readOnly
|
|
1307
|
-
}, {
|
|
1308
|
-
default: r(() => [f(V, {
|
|
1309
|
-
"model-value": e.modelValue,
|
|
1310
|
-
placeholder: e.field.placeholder,
|
|
1311
|
-
disabled: e.readOnly,
|
|
1312
|
-
presets: c.value.presets,
|
|
1313
|
-
"allow-custom": c.value.allowCustom,
|
|
1314
|
-
title: e.readOnly ? x(o).customBlocks.dataSource.readOnlyTooltip : void 0,
|
|
1315
|
-
"onUpdate:modelValue": n[0] ||= (e) => a("update:modelValue", e)
|
|
1316
|
-
}, null, 8, [
|
|
1317
|
-
"model-value",
|
|
1318
|
-
"placeholder",
|
|
1319
|
-
"disabled",
|
|
1320
|
-
"presets",
|
|
1321
|
-
"allow-custom",
|
|
1322
|
-
"title"
|
|
1323
|
-
])]),
|
|
1324
|
-
_: 1
|
|
1325
|
-
}, 8, [
|
|
1326
|
-
"label",
|
|
1327
|
-
"required",
|
|
1328
|
-
"read-only"
|
|
1329
|
-
]));
|
|
1330
|
-
}
|
|
1331
|
-
}), hr = [
|
|
1332
|
-
"value",
|
|
1333
|
-
"placeholder",
|
|
1334
|
-
"title"
|
|
1335
|
-
], gr = ["value", "placeholder"], _r = /* @__PURE__ */ w({
|
|
1336
|
-
__name: "ImageField",
|
|
1337
|
-
props: {
|
|
1338
|
-
field: {},
|
|
1339
|
-
modelValue: {},
|
|
1340
|
-
readOnly: { type: Boolean }
|
|
1341
|
-
},
|
|
1342
|
-
emits: ["update:modelValue"],
|
|
1343
|
-
setup(e, { emit: n }) {
|
|
1344
|
-
let i = e, a = n, { t: o } = B(), c = t(), { canBrowse: l, isUploading: u, showOverlay: d, openMediaBrowser: p } = _e({
|
|
1345
|
-
target: c,
|
|
1346
|
-
blocked: () => !!i.readOnly,
|
|
1347
|
-
apply: (e) => a("update:modelValue", e.url)
|
|
1348
|
-
});
|
|
1349
|
-
return (t, n) => (_(), S(Q, {
|
|
1350
|
-
label: e.field.label,
|
|
1351
|
-
required: e.field.required,
|
|
1352
|
-
"read-only": e.readOnly
|
|
1353
|
-
}, {
|
|
1354
|
-
default: r(() => [y("div", {
|
|
1355
|
-
ref_key: "dropZoneRef",
|
|
1356
|
-
ref: c,
|
|
1357
|
-
class: "tpl:relative"
|
|
1358
|
-
}, [
|
|
1359
|
-
x(d) ? (_(), S(fe, {
|
|
1360
|
-
key: 0,
|
|
1361
|
-
uploading: x(u)
|
|
1362
|
-
}, null, 8, ["uploading"])) : m("", !0),
|
|
1363
|
-
e.readOnly ? (_(), h("input", {
|
|
1364
|
-
key: 1,
|
|
1365
|
-
type: "url",
|
|
1366
|
-
class: v([x(K), "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1367
|
-
value: e.modelValue,
|
|
1368
|
-
placeholder: e.field.placeholder || "https://...",
|
|
1369
|
-
disabled: "",
|
|
1370
|
-
title: x(o).customBlocks.dataSource.readOnlyTooltip
|
|
1371
|
-
}, null, 10, hr)) : (_(), h("input", {
|
|
1372
|
-
key: 2,
|
|
1373
|
-
type: "url",
|
|
1374
|
-
class: v(x(K)),
|
|
1375
|
-
value: e.modelValue,
|
|
1376
|
-
placeholder: e.field.placeholder || "https://...",
|
|
1377
|
-
onInput: n[0] ||= (e) => a("update:modelValue", e.target.value)
|
|
1378
|
-
}, null, 42, gr)),
|
|
1379
|
-
x(l) && !e.readOnly ? (_(), h("button", {
|
|
1380
|
-
key: 3,
|
|
1381
|
-
class: "tpl:mt-2 tpl:flex tpl:w-full tpl:items-center tpl:justify-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:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)] tpl:bg-[var(--tpl-bg)]",
|
|
1382
|
-
onClick: n[1] ||= (e) => x(p)()
|
|
1383
|
-
}, [f(x(Ve), {
|
|
1384
|
-
size: 14,
|
|
1385
|
-
"stroke-width": 1.5
|
|
1386
|
-
}), g(" " + s(x(o).image.browseMedia), 1)])) : m("", !0)
|
|
1387
|
-
], 512)]),
|
|
1388
|
-
_: 1
|
|
1389
|
-
}, 8, [
|
|
1390
|
-
"label",
|
|
1391
|
-
"required",
|
|
1392
|
-
"read-only"
|
|
1393
|
-
]));
|
|
1394
|
-
}
|
|
1395
|
-
}), vr = [
|
|
1396
|
-
"value",
|
|
1397
|
-
"placeholder",
|
|
1398
|
-
"min",
|
|
1399
|
-
"max",
|
|
1400
|
-
"step",
|
|
1401
|
-
"disabled",
|
|
1402
|
-
"title"
|
|
1403
|
-
], yr = /* @__PURE__ */ w({
|
|
1404
|
-
__name: "NumberField",
|
|
1405
|
-
props: {
|
|
1406
|
-
field: {},
|
|
1407
|
-
modelValue: {},
|
|
1408
|
-
readOnly: { type: Boolean }
|
|
1409
|
-
},
|
|
1410
|
-
emits: ["update:modelValue"],
|
|
1411
|
-
setup(e, { emit: t }) {
|
|
1412
|
-
let n = t, { t: i } = B();
|
|
1413
|
-
return (t, a) => (_(), S(Q, {
|
|
1414
|
-
label: e.field.label,
|
|
1415
|
-
required: e.field.required,
|
|
1416
|
-
"read-only": e.readOnly
|
|
1417
|
-
}, {
|
|
1418
|
-
default: r(() => [y("input", {
|
|
1419
|
-
type: "number",
|
|
1420
|
-
class: v([x(K), e.readOnly && "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1421
|
-
value: e.modelValue,
|
|
1422
|
-
placeholder: e.field.placeholder,
|
|
1423
|
-
min: e.field.min,
|
|
1424
|
-
max: e.field.max,
|
|
1425
|
-
step: e.field.step,
|
|
1426
|
-
disabled: e.readOnly,
|
|
1427
|
-
title: e.readOnly ? x(i).customBlocks.dataSource.readOnlyTooltip : void 0,
|
|
1428
|
-
onInput: a[0] ||= (t) => !e.readOnly && n("update:modelValue", Number(t.target.value))
|
|
1429
|
-
}, null, 42, vr)]),
|
|
1430
|
-
_: 1
|
|
1431
|
-
}, 8, [
|
|
1432
|
-
"label",
|
|
1433
|
-
"required",
|
|
1434
|
-
"read-only"
|
|
1435
|
-
]));
|
|
1436
|
-
}
|
|
1437
|
-
}), br = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, xr = { class: "tpl:mb-2 tpl:flex tpl:items-center tpl:justify-between" }, Sr = { class: "tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-dim)]" }, Cr = ["title", "onClick"], wr = {
|
|
1438
|
-
key: 1,
|
|
1439
|
-
class: "tpl:m-0 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
1440
|
-
}, Tr = {
|
|
1441
|
-
key: 2,
|
|
1442
|
-
class: "tpl:m-0 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
1443
|
-
}, Er = /* @__PURE__ */ w({
|
|
1444
|
-
__name: "RepeatableField",
|
|
1445
|
-
props: {
|
|
1446
|
-
field: {},
|
|
1447
|
-
modelValue: {},
|
|
1448
|
-
readOnly: { type: Boolean }
|
|
1449
|
-
},
|
|
1450
|
-
emits: ["update:modelValue"],
|
|
1451
|
-
setup(e, { emit: t }) {
|
|
1452
|
-
let n = e, a = t, { t: c, format: l } = B(), u = p(() => n.modelValue || []), d = p(() => !n.field.maxItems || u.value.length < n.field.maxItems), C = p(() => !n.field.minItems || u.value.length > n.field.minItems);
|
|
1453
|
-
function w() {
|
|
1454
|
-
if (!d.value || n.readOnly) return;
|
|
1455
|
-
let e = {};
|
|
1456
|
-
for (let t of n.field.fields) e[t.key] = t.default ?? "";
|
|
1457
|
-
a("update:modelValue", [...u.value, e]);
|
|
1458
|
-
}
|
|
1459
|
-
function T(e) {
|
|
1460
|
-
if (!C.value || n.readOnly) return;
|
|
1461
|
-
let t = [...u.value];
|
|
1462
|
-
t.splice(e, 1), a("update:modelValue", t);
|
|
1463
|
-
}
|
|
1464
|
-
function E(e, t, n) {
|
|
1465
|
-
let r = u.value.map((r, i) => i === e ? {
|
|
1466
|
-
...r,
|
|
1467
|
-
[t]: n
|
|
1468
|
-
} : r);
|
|
1469
|
-
a("update:modelValue", r);
|
|
1470
|
-
}
|
|
1471
|
-
return (t, n) => (_(), S(Q, {
|
|
1472
|
-
label: e.field.label,
|
|
1473
|
-
required: e.field.required,
|
|
1474
|
-
"read-only": e.readOnly
|
|
1475
|
-
}, {
|
|
1476
|
-
default: r(() => [y("div", br, [
|
|
1477
|
-
(_(!0), h(b, null, o(u.value, (t, n) => (_(), h("div", {
|
|
1478
|
-
key: `${e.field.key}-${n}`,
|
|
1479
|
-
class: "tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-3"
|
|
1480
|
-
}, [y("div", xr, [y("span", Sr, " #" + s(n + 1), 1), C.value && !e.readOnly ? (_(), h("button", {
|
|
1481
|
-
key: 0,
|
|
1482
|
-
type: "button",
|
|
1483
|
-
class: "tpl:flex tpl:size-6 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:hover:border-[var(--tpl-danger)] tpl:hover:bg-[var(--tpl-danger-light)] tpl:hover:text-[var(--tpl-danger)]",
|
|
1484
|
-
title: x(c).customBlocks.fields.removeItem,
|
|
1485
|
-
onClick: (e) => T(n)
|
|
1486
|
-
}, [f(x(Xe), {
|
|
1487
|
-
size: 12,
|
|
1488
|
-
"stroke-width": 2
|
|
1489
|
-
})], 8, Cr)) : m("", !0)]), (_(!0), h(b, null, o(e.field.fields, (r) => (_(), S(i(x(Fr)(r.type)), {
|
|
1490
|
-
key: r.key,
|
|
1491
|
-
field: r,
|
|
1492
|
-
"model-value": t[r.key],
|
|
1493
|
-
"read-only": e.readOnly,
|
|
1494
|
-
"onUpdate:modelValue": (e) => E(n, r.key, e)
|
|
1495
|
-
}, null, 8, [
|
|
1496
|
-
"field",
|
|
1497
|
-
"model-value",
|
|
1498
|
-
"read-only",
|
|
1499
|
-
"onUpdate:modelValue"
|
|
1500
|
-
]))), 128))]))), 128)),
|
|
1501
|
-
d.value && !e.readOnly ? (_(), h("button", {
|
|
1502
|
-
key: 0,
|
|
1503
|
-
type: "button",
|
|
1504
|
-
class: v(x(tt)),
|
|
1505
|
-
onClick: w
|
|
1506
|
-
}, [f(x(H), {
|
|
1507
|
-
size: 14,
|
|
1508
|
-
"stroke-width": 2
|
|
1509
|
-
}), g(" " + s(x(c).customBlocks.fields.addItem), 1)], 2)) : m("", !0),
|
|
1510
|
-
!d.value && !e.readOnly ? (_(), h("p", wr, s(x(c).customBlocks.fields.maxItemsReached), 1)) : m("", !0),
|
|
1511
|
-
!C.value && !e.readOnly ? (_(), h("p", Tr, s(x(l)(x(c).customBlocks.fields.minItemsRequired, { count: e.field.minItems ?? 0 })), 1)) : m("", !0)
|
|
1512
|
-
])]),
|
|
1513
|
-
_: 1
|
|
1514
|
-
}, 8, [
|
|
1515
|
-
"label",
|
|
1516
|
-
"required",
|
|
1517
|
-
"read-only"
|
|
1518
|
-
]));
|
|
1519
|
-
}
|
|
1520
|
-
}), Dr = [
|
|
1521
|
-
"value",
|
|
1522
|
-
"disabled",
|
|
1523
|
-
"title"
|
|
1524
|
-
], Or = ["value"], kr = /* @__PURE__ */ w({
|
|
1525
|
-
__name: "SelectField",
|
|
1526
|
-
props: {
|
|
1527
|
-
field: {},
|
|
1528
|
-
modelValue: {},
|
|
1529
|
-
readOnly: { type: Boolean }
|
|
1530
|
-
},
|
|
1531
|
-
emits: ["update:modelValue"],
|
|
1532
|
-
setup(e, { emit: t }) {
|
|
1533
|
-
let n = t, { t: i } = B();
|
|
1534
|
-
return (t, a) => (_(), S(Q, {
|
|
1535
|
-
label: e.field.label,
|
|
1536
|
-
required: e.field.required,
|
|
1537
|
-
"read-only": e.readOnly
|
|
1538
|
-
}, {
|
|
1539
|
-
default: r(() => [y("select", {
|
|
1540
|
-
class: v([x(K), e.readOnly && "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1541
|
-
value: e.modelValue,
|
|
1542
|
-
disabled: e.readOnly,
|
|
1543
|
-
title: e.readOnly ? x(i).customBlocks.dataSource.readOnlyTooltip : void 0,
|
|
1544
|
-
onChange: a[0] ||= (t) => !e.readOnly && n("update:modelValue", t.target.value)
|
|
1545
|
-
}, [(_(!0), h(b, null, o(e.field.options, (e) => (_(), h("option", {
|
|
1546
|
-
key: e.value,
|
|
1547
|
-
value: e.value
|
|
1548
|
-
}, s(e.label), 9, Or))), 128))], 42, Dr)]),
|
|
1549
|
-
_: 1
|
|
1550
|
-
}, 8, [
|
|
1551
|
-
"label",
|
|
1552
|
-
"required",
|
|
1553
|
-
"read-only"
|
|
1554
|
-
]));
|
|
1555
|
-
}
|
|
1556
|
-
}), Ar = [
|
|
1557
|
-
"value",
|
|
1558
|
-
"placeholder",
|
|
1559
|
-
"title"
|
|
1560
|
-
], jr = /* @__PURE__ */ w({
|
|
1561
|
-
__name: "TextField",
|
|
1562
|
-
props: {
|
|
1563
|
-
field: {},
|
|
1564
|
-
modelValue: {},
|
|
1565
|
-
readOnly: { type: Boolean }
|
|
1566
|
-
},
|
|
1567
|
-
emits: ["update:modelValue"],
|
|
1568
|
-
setup(e, { emit: t }) {
|
|
1569
|
-
let n = t, { t: i } = B();
|
|
1570
|
-
return (t, a) => (_(), S(Q, {
|
|
1571
|
-
label: e.field.label,
|
|
1572
|
-
required: e.field.required,
|
|
1573
|
-
"read-only": e.readOnly
|
|
1574
|
-
}, {
|
|
1575
|
-
default: r(() => [e.readOnly ? (_(), h("input", {
|
|
1576
|
-
key: 0,
|
|
1577
|
-
type: "text",
|
|
1578
|
-
class: v([x(K), "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1579
|
-
value: e.modelValue,
|
|
1580
|
-
placeholder: e.field.placeholder,
|
|
1581
|
-
disabled: "",
|
|
1582
|
-
title: x(i).customBlocks.dataSource.readOnlyTooltip
|
|
1583
|
-
}, null, 10, Ar)) : (_(), S(J, {
|
|
1584
|
-
key: 1,
|
|
1585
|
-
"model-value": e.modelValue,
|
|
1586
|
-
placeholder: e.field.placeholder,
|
|
1587
|
-
"onUpdate:modelValue": a[0] ||= (e) => n("update:modelValue", e)
|
|
1588
|
-
}, null, 8, ["model-value", "placeholder"]))]),
|
|
1589
|
-
_: 1
|
|
1590
|
-
}, 8, [
|
|
1591
|
-
"label",
|
|
1592
|
-
"required",
|
|
1593
|
-
"read-only"
|
|
1594
|
-
]));
|
|
1595
|
-
}
|
|
1596
|
-
}), Mr = [
|
|
1597
|
-
"value",
|
|
1598
|
-
"placeholder",
|
|
1599
|
-
"title"
|
|
1600
|
-
], Nr = "tpl:w-full tpl:resize-y tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-2 tpl:text-sm tpl:text-[var(--tpl-text)] tpl:outline-none tpl:opacity-60 tpl:cursor-not-allowed", Pr = {
|
|
1601
|
-
text: jr,
|
|
1602
|
-
textarea: /* @__PURE__ */ w({
|
|
1603
|
-
__name: "TextareaField",
|
|
1604
|
-
props: {
|
|
1605
|
-
field: {},
|
|
1606
|
-
modelValue: {},
|
|
1607
|
-
readOnly: { type: Boolean }
|
|
1608
|
-
},
|
|
1609
|
-
emits: ["update:modelValue"],
|
|
1610
|
-
setup(e, { emit: t }) {
|
|
1611
|
-
let n = t, { t: i } = B();
|
|
1612
|
-
return (t, a) => (_(), S(Q, {
|
|
1613
|
-
label: e.field.label,
|
|
1614
|
-
required: e.field.required,
|
|
1615
|
-
"read-only": e.readOnly
|
|
1616
|
-
}, {
|
|
1617
|
-
default: r(() => [e.readOnly ? (_(), h("textarea", {
|
|
1618
|
-
key: 0,
|
|
1619
|
-
value: e.modelValue,
|
|
1620
|
-
placeholder: e.field.placeholder,
|
|
1621
|
-
rows: "3",
|
|
1622
|
-
disabled: "",
|
|
1623
|
-
title: x(i).customBlocks.dataSource.readOnlyTooltip,
|
|
1624
|
-
class: v(Nr)
|
|
1625
|
-
}, null, 8, Mr)) : (_(), S(it, {
|
|
1626
|
-
key: 1,
|
|
1627
|
-
"model-value": e.modelValue,
|
|
1628
|
-
placeholder: e.field.placeholder,
|
|
1629
|
-
"onUpdate:modelValue": a[0] ||= (e) => n("update:modelValue", e)
|
|
1630
|
-
}, null, 8, ["model-value", "placeholder"]))]),
|
|
1631
|
-
_: 1
|
|
1632
|
-
}, 8, [
|
|
1633
|
-
"label",
|
|
1634
|
-
"required",
|
|
1635
|
-
"read-only"
|
|
1636
|
-
]));
|
|
1637
|
-
}
|
|
1638
|
-
}),
|
|
1639
|
-
image: _r,
|
|
1640
|
-
color: mr,
|
|
1641
|
-
number: yr,
|
|
1642
|
-
select: kr,
|
|
1643
|
-
boolean: cr,
|
|
1644
|
-
repeatable: Er
|
|
1645
|
-
};
|
|
1646
|
-
function Fr(e) {
|
|
1647
|
-
return Pr[e] ?? jr;
|
|
1648
|
-
}
|
|
1649
|
-
// src/components/toolbar/CustomBlockToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
1650
|
-
var Ir = {
|
|
1651
|
-
key: 0,
|
|
1652
|
-
class: "tpl:p-4"
|
|
1653
|
-
}, Lr = { class: "tpl:m-0 tpl:text-center tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Rr = { key: 1 }, zr = {
|
|
1654
|
-
key: 0,
|
|
1655
|
-
class: "tpl:m-0 tpl:mb-3 tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
1656
|
-
}, Br = {
|
|
1657
|
-
key: 1,
|
|
1658
|
-
class: "tpl:mb-4"
|
|
1659
|
-
}, Vr = {
|
|
1660
|
-
key: 1,
|
|
1661
|
-
class: "tpl:flex tpl:h-[32px] tpl:items-center"
|
|
1662
|
-
}, Hr = {
|
|
1663
|
-
key: 0,
|
|
1664
|
-
class: "tpl:w-full tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
1665
|
-
}, Ur = {
|
|
1666
|
-
key: 2,
|
|
1667
|
-
class: "tpl:m-0 tpl:mt-2 tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-danger)]"
|
|
1668
|
-
}, Wr = /* @__PURE__ */ w({
|
|
1669
|
-
__name: "CustomBlockToolbar",
|
|
1670
|
-
props: { block: {} },
|
|
1671
|
-
emits: ["updateFieldValues", "updateDataSourceFetched"],
|
|
1672
|
-
setup(e, { emit: t }) {
|
|
1673
|
-
let r = e, a = t, { t: c } = B(), l = n(je, []), u = p(() => l.find((e) => e.type === r.block.customType)), d = p(() => r.block), { isFetching: v, fetchError: C, fetch: w, hasDataSource: T, needsFetch: E } = le({
|
|
1674
|
-
definition: u,
|
|
1675
|
-
block: d,
|
|
1676
|
-
onUpdate: (e, t) => {
|
|
1677
|
-
a("updateFieldValues", e), a("updateDataSourceFetched", t);
|
|
1678
|
-
}
|
|
1679
|
-
});
|
|
1680
|
-
function D(e) {
|
|
1681
|
-
return e.readOnly === !0 && T.value && !!r.block.dataSourceFetched;
|
|
1682
|
-
}
|
|
1683
|
-
function O(e, t) {
|
|
1684
|
-
a("updateFieldValues", {
|
|
1685
|
-
...r.block.fieldValues,
|
|
1686
|
-
[e]: t
|
|
1687
|
-
});
|
|
1688
|
-
}
|
|
1689
|
-
return (t, n) => u.value ? (_(), h("div", Rr, [
|
|
1690
|
-
u.value.description ? (_(), h("p", zr, s(u.value.description), 1)) : m("", !0),
|
|
1691
|
-
x(T) ? (_(), h("div", Br, [x(E) && !x(v) ? (_(), h("button", {
|
|
1692
|
-
key: 0,
|
|
1693
|
-
type: "button",
|
|
1694
|
-
class: "tpl:flex tpl:w-full tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded-md tpl:px-3 tpl:py-2.5 tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-on-primary)] tpl:transition-all tpl:bg-[var(--tpl-primary)]",
|
|
1695
|
-
onClick: n[0] ||= (...e) => x(w) && x(w)(...e)
|
|
1696
|
-
}, s(u.value?.dataSource?.label || x(c).customBlocks.dataSource.fetchButton), 1)) : (_(), h("div", Vr, [x(v) ? (_(), h("div", Hr, s(x(c).customBlocks.dataSource.fetching), 1)) : (_(), h("button", {
|
|
1697
|
-
key: 1,
|
|
1698
|
-
type: "button",
|
|
1699
|
-
class: "tpl:flex tpl:w-full tpl:items-center tpl:justify-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:hover:border-[var(--tpl-primary)] tpl:hover:text-[var(--tpl-primary)]",
|
|
1700
|
-
onClick: n[1] ||= (...e) => x(w) && x(w)(...e)
|
|
1701
|
-
}, [f(x(Ke), { size: 12 }), g(" " + s(x(c).customBlocks.dataSource.changeButton), 1)]))])), x(C) ? (_(), h("p", Ur, [f(x(Le), {
|
|
1702
|
-
size: 14,
|
|
1703
|
-
class: "tpl:shrink-0"
|
|
1704
|
-
}), g(" " + s(x(c).customBlocks.dataSource.fetchError), 1)])) : m("", !0)])) : m("", !0),
|
|
1705
|
-
(_(!0), h(b, null, o(u.value.fields, (t) => (_(), S(i(x(Fr)(t.type)), {
|
|
1706
|
-
key: t.key,
|
|
1707
|
-
field: t,
|
|
1708
|
-
"model-value": e.block.fieldValues[t.key],
|
|
1709
|
-
"read-only": D(t),
|
|
1710
|
-
"onUpdate:modelValue": (e) => O(t.key, e)
|
|
1711
|
-
}, null, 8, [
|
|
1712
|
-
"field",
|
|
1713
|
-
"model-value",
|
|
1714
|
-
"read-only",
|
|
1715
|
-
"onUpdate:modelValue"
|
|
1716
|
-
]))), 128))
|
|
1717
|
-
])) : (_(), h("div", Ir, [y("p", Lr, s(x(c).customBlocks.toolbar.noDefinition), 1)]));
|
|
1718
|
-
}
|
|
1719
|
-
}), Gr = { class: "tpl:mb-3.5" }, Kr = { class: "tpl:mb-3.5" }, qr = { class: "tpl:mb-3.5" }, Jr = { class: "tpl:flex tpl:items-stretch" }, Yr = ["value"], Xr = /* @__PURE__ */ w({
|
|
1720
|
-
__name: "DividerToolbar",
|
|
1721
|
-
props: { block: {} },
|
|
1722
|
-
emits: ["update"],
|
|
1723
|
-
setup(e, { emit: t }) {
|
|
1724
|
-
let n = t, { t: r } = B();
|
|
1725
|
-
function i(e, t) {
|
|
1726
|
-
n("update", { [e]: t });
|
|
1727
|
-
}
|
|
1728
|
-
return (t, n) => (_(), h(b, null, [
|
|
1729
|
-
y("div", Gr, [y("label", { class: v(x(U)) }, s(x(r).divider.style), 3), f(Y, {
|
|
1730
|
-
options: [
|
|
1731
|
-
{
|
|
1732
|
-
value: "solid",
|
|
1733
|
-
label: x(r).divider.solid
|
|
1734
|
-
},
|
|
1735
|
-
{
|
|
1736
|
-
value: "dashed",
|
|
1737
|
-
label: x(r).divider.dashed
|
|
1738
|
-
},
|
|
1739
|
-
{
|
|
1740
|
-
value: "dotted",
|
|
1741
|
-
label: x(r).divider.dotted
|
|
1742
|
-
}
|
|
1743
|
-
],
|
|
1744
|
-
"model-value": e.block.lineStyle,
|
|
1745
|
-
"onUpdate:modelValue": n[0] ||= (e) => i("lineStyle", e)
|
|
1746
|
-
}, null, 8, ["options", "model-value"])]),
|
|
1747
|
-
y("div", Kr, [y("label", { class: v(x(U)) }, s(x(r).divider.color), 3), f(V, {
|
|
1748
|
-
"model-value": e.block.color,
|
|
1749
|
-
"onUpdate:modelValue": n[1] ||= (e) => i("color", e)
|
|
1750
|
-
}, null, 8, ["model-value"])]),
|
|
1751
|
-
y("div", qr, [y("label", { class: v(x(U)) }, s(x(r).divider.thickness), 3), y("div", Jr, [y("input", {
|
|
1752
|
-
type: "number",
|
|
1753
|
-
class: v(x(G)),
|
|
1754
|
-
value: e.block.thickness,
|
|
1755
|
-
min: "1",
|
|
1756
|
-
max: "10",
|
|
1757
|
-
onInput: n[2] ||= (e) => i("thickness", Number(e.target.value))
|
|
1758
|
-
}, null, 42, Yr), y("span", { class: v(x(W)) }, "px", 2)])])
|
|
1759
|
-
], 64));
|
|
1760
|
-
}
|
|
1761
|
-
}), Zr = { class: "tpl:mb-3.5" }, Qr = ["value"], $r = { class: "tpl:mt-1.5 tpl:flex tpl:items-start tpl:gap-1.5 tpl:text-[10px] tpl:text-[var(--tpl-text-dim)]" }, ei = /* @__PURE__ */ w({
|
|
1762
|
-
__name: "HtmlToolbar",
|
|
1763
|
-
props: { block: {} },
|
|
1764
|
-
emits: ["update"],
|
|
1765
|
-
setup(e, { emit: t }) {
|
|
1766
|
-
let n = t, { t: r } = B();
|
|
1767
|
-
return (t, i) => (_(), h("div", Zr, [
|
|
1768
|
-
y("label", { class: v(x(U)) }, s(x(r).html.content), 3),
|
|
1769
|
-
y("textarea", {
|
|
1770
|
-
value: e.block.content,
|
|
1771
|
-
placeholder: "<div>...</div>",
|
|
1772
|
-
rows: "10",
|
|
1773
|
-
class: v(x($e)),
|
|
1774
|
-
onInput: i[0] ||= (e) => n("update", { content: e.target.value })
|
|
1775
|
-
}, null, 42, Qr),
|
|
1776
|
-
y("p", $r, [f(x(He), {
|
|
1777
|
-
size: 12,
|
|
1778
|
-
class: "tpl:mt-0.5 tpl:shrink-0"
|
|
1779
|
-
}), g(" " + s(x(r).html.sanitizationHint), 1)])
|
|
1780
|
-
]));
|
|
1781
|
-
}
|
|
1782
|
-
});
|
|
1783
|
-
// src/composables/useImageAspectLock.ts
|
|
1784
|
-
function ti(e) {
|
|
1785
|
-
let n = t(!1), r = t(null);
|
|
1786
|
-
T(() => e.block().id, () => {
|
|
1787
|
-
n.value = !1, r.value = null;
|
|
1788
|
-
});
|
|
1789
|
-
let i = p(() => he(e.block()) ?? e.measured()), a = p(() => {
|
|
1790
|
-
let t = e.block().width;
|
|
1791
|
-
return t === "full" ? e.room() : t;
|
|
1792
|
-
}), o = p(() => {
|
|
1793
|
-
let e = i.value, t = a.value;
|
|
1794
|
-
return !e || t === null ? null : Math.round(t * e.height / e.width);
|
|
1795
|
-
}), s = p(() => i.value !== null), c = p(() => {
|
|
1796
|
-
let t = e.block().height;
|
|
1797
|
-
return t === void 0 || o.value !== null && Math.abs(o.value - t) <= 1;
|
|
1798
|
-
}), l = p(() => s.value && !n.value && c.value);
|
|
1799
|
-
function u() {
|
|
1800
|
-
if (he(e.block())) return {};
|
|
1801
|
-
let t = e.measured();
|
|
1802
|
-
return t ? L(t) : {};
|
|
1803
|
-
}
|
|
1804
|
-
function d(t) {
|
|
1805
|
-
if (r.value = null, !t) return n.value = !0, null;
|
|
1806
|
-
if (n.value = !1, !s.value) return null;
|
|
1807
|
-
let i = { ...u() };
|
|
1808
|
-
return e.block().height !== void 0 && (i.height = void 0), Object.keys(i).length > 0 ? i : null;
|
|
1809
|
-
}
|
|
1810
|
-
function f(e) {
|
|
1811
|
-
return r.value = null, l.value ? {
|
|
1812
|
-
width: e,
|
|
1813
|
-
height: void 0,
|
|
1814
|
-
...u()
|
|
1815
|
-
} : { width: e };
|
|
1816
|
-
}
|
|
1817
|
-
function m(t) {
|
|
1818
|
-
let n = i.value;
|
|
1819
|
-
if (!l.value || !n || !Number.isFinite(t) || t <= 0) return null;
|
|
1820
|
-
let a = Math.round(t * n.width / n.height);
|
|
1821
|
-
if (a < 1) return null;
|
|
1822
|
-
let o = e.room();
|
|
1823
|
-
return o !== null && a >= o ? (r.value = Math.round(o * n.height / n.width), {
|
|
1824
|
-
width: "full",
|
|
1825
|
-
height: void 0,
|
|
1826
|
-
...u()
|
|
1827
|
-
}) : (r.value = null, {
|
|
1828
|
-
width: a,
|
|
1829
|
-
height: void 0,
|
|
1830
|
-
...u()
|
|
1831
|
-
});
|
|
1832
|
-
}
|
|
1833
|
-
return {
|
|
1834
|
-
available: s,
|
|
1835
|
-
locked: l,
|
|
1836
|
-
derivedHeight: o,
|
|
1837
|
-
cappedHeight: r,
|
|
1838
|
-
setLocked: d,
|
|
1839
|
-
widthUpdates: f,
|
|
1840
|
-
heightUpdates: m
|
|
1841
|
-
};
|
|
1842
|
-
}
|
|
1843
|
-
// src/components/toolbar/ImageToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
1844
|
-
var ni = { class: "tpl:mb-3.5" }, ri = {
|
|
1845
|
-
key: 0,
|
|
1846
|
-
class: "tpl:mb-3.5"
|
|
1847
|
-
}, ii = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, ai = [
|
|
1848
|
-
"value",
|
|
1849
|
-
"placeholder",
|
|
1850
|
-
"title"
|
|
1851
|
-
], oi = { class: "tpl:mb-3.5" }, si = { class: "tpl:block tpl:text-[var(--tpl-text-dim)]" }, ci = { class: "tpl:mb-3.5" }, li = ["value"], ui = { value: "full" }, di = { value: "custom" }, fi = {
|
|
1852
|
-
key: 0,
|
|
1853
|
-
class: "tpl:mt-2 tpl:flex tpl:items-stretch"
|
|
1854
|
-
}, pi = ["value"], mi = { class: "tpl:mb-3.5" }, hi = {
|
|
1855
|
-
key: 0,
|
|
1856
|
-
class: "tpl:mb-1.5 tpl:flex tpl:items-center tpl:justify-between"
|
|
1857
|
-
}, gi = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, _i = { class: "tpl:flex tpl:items-stretch" }, vi = ["value"], yi = {
|
|
1858
|
-
key: 0,
|
|
1859
|
-
class: "tpl:mt-1.5 tpl:text-xs tpl:text-[var(--tpl-text-dim)]",
|
|
1860
|
-
role: "status",
|
|
1861
|
-
"data-testid": "image-height-capped"
|
|
1862
|
-
}, bi = ["value"], xi = { value: "auto" }, Si = { value: "custom" }, Ci = {
|
|
1863
|
-
key: 4,
|
|
1864
|
-
class: "tpl:mt-2 tpl:flex tpl:items-stretch"
|
|
1865
|
-
}, wi = ["value"], Ti = { class: "tpl:mb-3.5" }, Ei = { class: "tpl:mb-3.5" }, Di = 350, Oi = 200, ki = /* @__PURE__ */ w({
|
|
1866
|
-
__name: "ImageToolbar",
|
|
1867
|
-
props: { block: {} },
|
|
1868
|
-
emits: ["update"],
|
|
1869
|
-
setup(e, { emit: i }) {
|
|
1870
|
-
let a = e, o = i, { t: c, format: l } = B(), u = n(Te, te.liquid), d = n(Oe, null), C = n(Ce, void 0), w = t(!1), T = t(!1), { start: E } = xe(() => {
|
|
1871
|
-
w.value = !1, T.value = !1;
|
|
1872
|
-
}, 1e3, { immediate: !1 }), D = [
|
|
1873
|
-
300,
|
|
1874
|
-
400,
|
|
1875
|
-
500
|
|
1876
|
-
], k = p(() => {
|
|
1877
|
-
let e = a.block.width;
|
|
1878
|
-
return e === "full" ? "full" : D.includes(e) ? String(e) : "custom";
|
|
1879
|
-
}), j = p(() => typeof a.block.height == "number" ? "custom" : "auto");
|
|
1880
|
-
function M(e, t) {
|
|
1881
|
-
o("update", { [e]: t });
|
|
1882
|
-
}
|
|
1883
|
-
function N(e) {
|
|
1884
|
-
if (e === "custom") {
|
|
1885
|
-
let e = a.block.width;
|
|
1886
|
-
(typeof e != "number" || D.includes(e)) && o("update", R.widthUpdates(Di));
|
|
1887
|
-
} else o("update", R.widthUpdates(e === "full" ? "full" : Number(e)));
|
|
1888
|
-
}
|
|
1889
|
-
function P(e) {
|
|
1890
|
-
M("height", e === "custom" ? Oi : void 0);
|
|
1891
|
-
}
|
|
1892
|
-
function F(e) {
|
|
1893
|
-
let t = Number(e);
|
|
1894
|
-
!Number.isFinite(t) || t <= 0 || M("height", t);
|
|
1895
|
-
}
|
|
1896
|
-
function ee(e) {
|
|
1897
|
-
M("borderRadius", O(e) === null ? void 0 : e);
|
|
1898
|
-
}
|
|
1899
|
-
function ne(e) {
|
|
1900
|
-
let t = Number(e);
|
|
1901
|
-
!Number.isFinite(t) || t <= 0 || o("update", R.widthUpdates(t));
|
|
1902
|
-
}
|
|
1903
|
-
function re(e) {
|
|
1904
|
-
e !== a.block.src && o("update", {
|
|
1905
|
-
src: e,
|
|
1906
|
-
...L(null)
|
|
1907
|
-
});
|
|
1908
|
-
}
|
|
1909
|
-
function I(e) {
|
|
1910
|
-
o("update", {
|
|
1911
|
-
src: e.url,
|
|
1912
|
-
...L(me(e.width, e.height))
|
|
1913
|
-
}), e.alt && (M("alt", e.alt), T.value = !0), w.value = !0, E();
|
|
1914
|
-
}
|
|
1915
|
-
let ie = t(), ae = p(() => A(a.block.src, u)), { canBrowse: oe, isUploading: se, showOverlay: le, openMediaBrowser: ue } = _e({
|
|
1916
|
-
target: ie,
|
|
1917
|
-
blocked: ae,
|
|
1918
|
-
apply: I
|
|
1919
|
-
}), de = ce(() => ae.value || !a.block.src || he(a.block) ? void 0 : a.block.src), pe = bn(() => de.value), ve = p(() => d ? ge(d.content.value, a.block.id, C) : null), R = ti({
|
|
1920
|
-
block: () => a.block,
|
|
1921
|
-
room: () => ve.value,
|
|
1922
|
-
measured: () => pe.value
|
|
1923
|
-
}), { available: ye, locked: z, derivedHeight: be, cappedHeight: Se } = R;
|
|
1924
|
-
function we() {
|
|
1925
|
-
let e = R.setLocked(!z.value);
|
|
1926
|
-
e && o("update", e);
|
|
1927
|
-
}
|
|
1928
|
-
let Ee = t(null);
|
|
1929
|
-
function De(e) {
|
|
1930
|
-
Ee.value = e;
|
|
1931
|
-
let t = R.heightUpdates(Number(e));
|
|
1932
|
-
t && o("update", t);
|
|
1933
|
-
}
|
|
1934
|
-
return (t, n) => (_(), h(b, null, [
|
|
1935
|
-
y("div", ni, [y("label", { class: v(x(U)) }, s(x(c).image.imageUrl), 3), y("div", {
|
|
1936
|
-
ref_key: "dropZoneRef",
|
|
1937
|
-
ref: ie,
|
|
1938
|
-
class: "tpl:relative"
|
|
1939
|
-
}, [
|
|
1940
|
-
x(le) ? (_(), S(fe, {
|
|
1941
|
-
key: 0,
|
|
1942
|
-
uploading: x(se)
|
|
1943
|
-
}, null, 8, ["uploading"])) : m("", !0),
|
|
1944
|
-
f(J, {
|
|
1945
|
-
"model-value": e.block.src,
|
|
1946
|
-
type: "url",
|
|
1947
|
-
placeholder: x(c).image.imageUrlPlaceholder,
|
|
1948
|
-
pulse: w.value,
|
|
1949
|
-
"onUpdate:modelValue": n[0] ||= (e) => re(e)
|
|
1950
|
-
}, null, 8, [
|
|
1951
|
-
"model-value",
|
|
1952
|
-
"placeholder",
|
|
1953
|
-
"pulse"
|
|
1954
|
-
]),
|
|
1955
|
-
x(oe) ? (_(), h("button", {
|
|
1956
|
-
key: 1,
|
|
1957
|
-
class: "tpl:mt-2 tpl:flex tpl:w-full tpl:items-center tpl:justify-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",
|
|
1958
|
-
style: {
|
|
1959
|
-
"border-color": "var(--tpl-border)",
|
|
1960
|
-
color: "var(--tpl-primary)",
|
|
1961
|
-
"background-color": "var(--tpl-bg)"
|
|
1962
|
-
},
|
|
1963
|
-
onClick: n[1] ||= (...e) => x(ue) && x(ue)(...e)
|
|
1964
|
-
}, [f(x(Ve), {
|
|
1965
|
-
size: 14,
|
|
1966
|
-
"stroke-width": 1.5
|
|
1967
|
-
}), g(" " + s(x(c).image.browseMedia), 1)])) : m("", !0)
|
|
1968
|
-
], 512)]),
|
|
1969
|
-
x(A)(e.block.src, x(u)) ? (_(), h("div", ri, [y("label", { class: v(x(U)) }, [g(s(x(c).image.placeholderUrl) + " ", 1), y("span", ii, s(x(c).image.optional), 1)], 2), y("input", {
|
|
1970
|
-
type: "url",
|
|
1971
|
-
class: v(x(K)),
|
|
1972
|
-
value: e.block.placeholderUrl || "",
|
|
1973
|
-
placeholder: x(c).image.placeholderUrlPlaceholder,
|
|
1974
|
-
title: x(c).image.placeholderUrlTooltip,
|
|
1975
|
-
onInput: n[2] ||= (e) => M("placeholderUrl", e.target.value)
|
|
1976
|
-
}, null, 42, ai)])) : m("", !0),
|
|
1977
|
-
y("div", oi, [
|
|
1978
|
-
y("label", { class: v(x(U)) }, s(x(c).image.altText), 3),
|
|
1979
|
-
f(J, {
|
|
1980
|
-
"model-value": e.block.alt,
|
|
1981
|
-
type: "text",
|
|
1982
|
-
placeholder: x(c).image.altTextPlaceholder,
|
|
1983
|
-
pulse: T.value,
|
|
1984
|
-
disabled: e.block.decorative === !0,
|
|
1985
|
-
"onUpdate:modelValue": n[3] ||= (e) => M("alt", e)
|
|
1986
|
-
}, null, 8, [
|
|
1987
|
-
"model-value",
|
|
1988
|
-
"placeholder",
|
|
1989
|
-
"pulse",
|
|
1990
|
-
"disabled"
|
|
1991
|
-
]),
|
|
1992
|
-
f(q, {
|
|
1993
|
-
class: "tpl:mt-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]",
|
|
1994
|
-
"model-value": e.block.decorative === !0,
|
|
1995
|
-
label: x(c).image.decorative,
|
|
1996
|
-
"onUpdate:modelValue": n[4] ||= (e) => M("decorative", e)
|
|
1997
|
-
}, {
|
|
1998
|
-
default: r(() => [y("span", null, [g(s(x(c).image.decorative) + " ", 1), y("span", si, s(x(c).image.decorativeHint), 1)])]),
|
|
1999
|
-
_: 1
|
|
2000
|
-
}, 8, ["model-value", "label"])
|
|
2001
|
-
]),
|
|
2002
|
-
y("div", ci, [
|
|
2003
|
-
y("label", { class: v(x(U)) }, s(x(c).image.width), 3),
|
|
2004
|
-
y("select", {
|
|
2005
|
-
class: v(x(K)),
|
|
2006
|
-
"data-testid": "image-width-mode",
|
|
2007
|
-
value: k.value,
|
|
2008
|
-
onChange: n[5] ||= (e) => N(e.target.value)
|
|
2009
|
-
}, [
|
|
2010
|
-
y("option", ui, s(x(c).image.fullWidth), 1),
|
|
2011
|
-
n[15] ||= y("option", { value: "300" }, "300px", -1),
|
|
2012
|
-
n[16] ||= y("option", { value: "400" }, "400px", -1),
|
|
2013
|
-
n[17] ||= y("option", { value: "500" }, "500px", -1),
|
|
2014
|
-
y("option", di, s(x(c).image.widthCustom), 1)
|
|
2015
|
-
], 42, li),
|
|
2016
|
-
k.value === "custom" ? (_(), h("div", fi, [y("input", {
|
|
2017
|
-
type: "number",
|
|
2018
|
-
"data-testid": "image-width-input",
|
|
2019
|
-
class: v(x(G)),
|
|
2020
|
-
value: typeof e.block.width == "number" ? e.block.width : Di,
|
|
2021
|
-
min: "20",
|
|
2022
|
-
onInput: n[6] ||= (e) => ne(e.target.value)
|
|
2023
|
-
}, null, 42, pi), y("span", { class: v(x(W)) }, "px", 2)])) : m("", !0)
|
|
2024
|
-
]),
|
|
2025
|
-
y("div", mi, [
|
|
2026
|
-
x(ye) ? (_(), h("div", hi, [y("span", gi, s(x(c).image.height), 1), f(ht, {
|
|
2027
|
-
linked: x(z),
|
|
2028
|
-
"link-label": x(c).image.lockAspectRatio,
|
|
2029
|
-
"unlink-label": x(c).image.unlockAspectRatio,
|
|
2030
|
-
testid: "image-aspect-lock",
|
|
2031
|
-
onToggle: we
|
|
2032
|
-
}, null, 8, [
|
|
2033
|
-
"linked",
|
|
2034
|
-
"link-label",
|
|
2035
|
-
"unlink-label"
|
|
2036
|
-
])])) : (_(), h("label", {
|
|
2037
|
-
key: 1,
|
|
2038
|
-
class: v(x(U))
|
|
2039
|
-
}, s(x(c).image.height), 3)),
|
|
2040
|
-
x(z) ? (_(), h(b, { key: 2 }, [y("div", _i, [y("input", {
|
|
2041
|
-
type: "number",
|
|
2042
|
-
"data-testid": "image-locked-height-input",
|
|
2043
|
-
class: v(x(G)),
|
|
2044
|
-
value: Ee.value ?? x(be) ?? "",
|
|
2045
|
-
min: "1",
|
|
2046
|
-
onInput: n[7] ||= (e) => De(e.target.value),
|
|
2047
|
-
onBlur: n[8] ||= (e) => Ee.value = null
|
|
2048
|
-
}, null, 42, vi), y("span", { class: v(x(W)) }, "px", 2)]), x(Se) === null ? m("", !0) : (_(), h("p", yi, s(x(l)(x(c).image.heightCapped, { height: x(Se) })), 1))], 64)) : m("", !0),
|
|
2049
|
-
x(z) ? m("", !0) : (_(), h("select", {
|
|
2050
|
-
key: 3,
|
|
2051
|
-
class: v(x(K)),
|
|
2052
|
-
"data-testid": "image-height-mode",
|
|
2053
|
-
value: j.value,
|
|
2054
|
-
onChange: n[9] ||= (e) => P(e.target.value)
|
|
2055
|
-
}, [y("option", xi, s(x(c).image.heightAuto), 1), y("option", Si, s(x(c).image.heightCustom), 1)], 42, bi)),
|
|
2056
|
-
!x(z) && j.value === "custom" ? (_(), h("div", Ci, [y("input", {
|
|
2057
|
-
type: "number",
|
|
2058
|
-
"data-testid": "image-height-input",
|
|
2059
|
-
class: v(x(G)),
|
|
2060
|
-
value: e.block.height,
|
|
2061
|
-
min: "20",
|
|
2062
|
-
onInput: n[10] ||= (e) => F(e.target.value)
|
|
2063
|
-
}, null, 42, wi), y("span", { class: v(x(W)) }, "px", 2)])) : m("", !0)
|
|
2064
|
-
]),
|
|
2065
|
-
f(Ot, {
|
|
2066
|
-
"model-value": e.block.borderRadius,
|
|
2067
|
-
label: x(c).image.borderRadius,
|
|
2068
|
-
"testid-prefix": "image",
|
|
2069
|
-
"onUpdate:modelValue": ee
|
|
2070
|
-
}, null, 8, ["model-value", "label"]),
|
|
2071
|
-
f(St, {
|
|
2072
|
-
"model-value": e.block.border,
|
|
2073
|
-
"testid-prefix": "image",
|
|
2074
|
-
"onUpdate:modelValue": n[11] ||= (e) => M("border", e)
|
|
2075
|
-
}, null, 8, ["model-value"]),
|
|
2076
|
-
y("div", Ti, [y("label", { class: v(x(U)) }, s(x(c).title.align), 3), f(Y, {
|
|
2077
|
-
options: [
|
|
2078
|
-
{
|
|
2079
|
-
value: "left",
|
|
2080
|
-
label: x(c).title.alignLeft
|
|
2081
|
-
},
|
|
2082
|
-
{
|
|
2083
|
-
value: "center",
|
|
2084
|
-
label: x(c).title.alignCenter
|
|
2085
|
-
},
|
|
2086
|
-
{
|
|
2087
|
-
value: "right",
|
|
2088
|
-
label: x(c).title.alignRight
|
|
2089
|
-
}
|
|
2090
|
-
],
|
|
2091
|
-
"model-value": e.block.align,
|
|
2092
|
-
"onUpdate:modelValue": n[12] ||= (e) => M("align", e)
|
|
2093
|
-
}, null, 8, ["options", "model-value"])]),
|
|
2094
|
-
y("div", Ei, [
|
|
2095
|
-
y("label", { class: v(x(U)) }, s(x(c).image.linkUrl), 3),
|
|
2096
|
-
f(J, {
|
|
2097
|
-
"model-value": e.block.linkUrl || "",
|
|
2098
|
-
type: "url",
|
|
2099
|
-
placeholder: x(c).image.imageUrlPlaceholder,
|
|
2100
|
-
"onUpdate:modelValue": n[13] ||= (e) => M("linkUrl", e)
|
|
2101
|
-
}, null, 8, ["model-value", "placeholder"]),
|
|
2102
|
-
e.block.linkUrl ? (_(), S(q, {
|
|
2103
|
-
key: 0,
|
|
2104
|
-
class: "tpl:mt-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]",
|
|
2105
|
-
"model-value": e.block.linkOpenInNewTab ?? !1,
|
|
2106
|
-
label: x(c).image.openInNewTab,
|
|
2107
|
-
"onUpdate:modelValue": n[14] ||= (e) => M("linkOpenInNewTab", e)
|
|
2108
|
-
}, null, 8, ["model-value", "label"])) : m("", !0)
|
|
2109
|
-
])
|
|
2110
|
-
], 64));
|
|
2111
|
-
}
|
|
2112
|
-
}), Ai = { class: "tpl:mb-3.5" }, $ = /* @__PURE__ */ w({
|
|
2113
|
-
__name: "FieldRow",
|
|
2114
|
-
props: { label: {} },
|
|
2115
|
-
setup(e) {
|
|
2116
|
-
return (t, n) => (_(), h("div", Ai, [e.label ? (_(), h("label", {
|
|
2117
|
-
key: 0,
|
|
2118
|
-
class: v(x(U))
|
|
2119
|
-
}, s(e.label), 3)) : m("", !0), c(t.$slots, "default")]));
|
|
2120
|
-
}
|
|
2121
|
-
}), ji = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, Mi = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ni = [
|
|
2122
|
-
"value",
|
|
2123
|
-
"placeholder",
|
|
2124
|
-
"onInput"
|
|
2125
|
-
], Pi = ["title", "onClick"], Fi = { class: "tpl:flex tpl:flex-wrap tpl:items-center tpl:gap-x-3 tpl:gap-y-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, Ii = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Li = ["value"], Ri = { value: "" }, zi = ["value"], Bi = ["value"], Vi = /* @__PURE__ */ w({
|
|
2126
|
-
__name: "MenuToolbar",
|
|
2127
|
-
props: {
|
|
2128
|
-
block: {},
|
|
2129
|
-
fontFamilies: {}
|
|
2130
|
-
},
|
|
2131
|
-
emits: ["update"],
|
|
2132
|
-
setup(e, { emit: t }) {
|
|
2133
|
-
let n = e, i = t, { t: a } = B(), c = p(() => [
|
|
2134
|
-
{
|
|
2135
|
-
key: "openInNewTab",
|
|
2136
|
-
label: a.menu.openInNewTab
|
|
2137
|
-
},
|
|
2138
|
-
{
|
|
2139
|
-
key: "bold",
|
|
2140
|
-
label: a.menu.bold
|
|
2141
|
-
},
|
|
2142
|
-
{
|
|
2143
|
-
key: "underline",
|
|
2144
|
-
label: a.menu.underline
|
|
2145
|
-
}
|
|
2146
|
-
]), l = p(() => [
|
|
2147
|
-
{
|
|
2148
|
-
value: "left",
|
|
2149
|
-
label: a.title.alignLeft,
|
|
2150
|
-
icon: Ye
|
|
2151
|
-
},
|
|
2152
|
-
{
|
|
2153
|
-
value: "center",
|
|
2154
|
-
label: a.title.alignCenter,
|
|
2155
|
-
icon: Je
|
|
2156
|
-
},
|
|
2157
|
-
{
|
|
2158
|
-
value: "right",
|
|
2159
|
-
label: a.title.alignRight,
|
|
2160
|
-
icon: qe
|
|
2161
|
-
}
|
|
2162
|
-
]);
|
|
2163
|
-
function u(e, t) {
|
|
2164
|
-
i("update", { [e]: t });
|
|
2165
|
-
}
|
|
2166
|
-
function d() {
|
|
2167
|
-
let e = {
|
|
2168
|
-
id: M(),
|
|
2169
|
-
text: "",
|
|
2170
|
-
url: "",
|
|
2171
|
-
openInNewTab: !1,
|
|
2172
|
-
bold: !1,
|
|
2173
|
-
underline: !1
|
|
2174
|
-
};
|
|
2175
|
-
i("update", { items: [...n.block.items, e] });
|
|
2176
|
-
}
|
|
2177
|
-
function m(e, t, r) {
|
|
2178
|
-
let a = n.block.items.map((n) => n.id === e ? {
|
|
2179
|
-
...n,
|
|
2180
|
-
[t]: r
|
|
2181
|
-
} : n);
|
|
2182
|
-
i("update", { items: a });
|
|
2183
|
-
}
|
|
2184
|
-
function C(e) {
|
|
2185
|
-
i("update", { items: n.block.items.filter((t) => t.id !== e) });
|
|
2186
|
-
}
|
|
2187
|
-
return (t, n) => (_(), h(b, null, [
|
|
2188
|
-
f($, { label: x(a).menu.items }, {
|
|
2189
|
-
default: r(() => [y("div", ji, [(_(!0), h(b, null, o(e.block.items, (t) => (_(), h("div", {
|
|
2190
|
-
key: t.id,
|
|
2191
|
-
class: "tpl:flex tpl:flex-col tpl:gap-1.5 tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-2"
|
|
2192
|
-
}, [
|
|
2193
|
-
y("div", Mi, [y("input", {
|
|
2194
|
-
type: "text",
|
|
2195
|
-
class: v([x(K), "tpl:flex-1"]),
|
|
2196
|
-
value: t.text,
|
|
2197
|
-
placeholder: x(a).menu.text,
|
|
2198
|
-
onInput: (e) => m(t.id, "text", e.target.value)
|
|
2199
|
-
}, null, 42, Ni), y("button", {
|
|
2200
|
-
class: v(x(et)),
|
|
2201
|
-
title: x(a).menu.removeItem,
|
|
2202
|
-
onClick: (e) => C(t.id)
|
|
2203
|
-
}, [f(x(Ze), {
|
|
2204
|
-
size: 14,
|
|
2205
|
-
"stroke-width": 2
|
|
2206
|
-
})], 10, Pi)]),
|
|
2207
|
-
f(J, {
|
|
2208
|
-
"model-value": t.url,
|
|
2209
|
-
type: "url",
|
|
2210
|
-
placeholder: x(a).menu.urlPlaceholder,
|
|
2211
|
-
"onUpdate:modelValue": (e) => m(t.id, "url", e)
|
|
2212
|
-
}, null, 8, [
|
|
2213
|
-
"model-value",
|
|
2214
|
-
"placeholder",
|
|
2215
|
-
"onUpdate:modelValue"
|
|
2216
|
-
]),
|
|
2217
|
-
y("div", Fi, [(_(!0), h(b, null, o(c.value, (e) => (_(), S(q, {
|
|
2218
|
-
key: e.key,
|
|
2219
|
-
"model-value": t[e.key],
|
|
2220
|
-
label: e.label,
|
|
2221
|
-
"onUpdate:modelValue": (n) => m(t.id, e.key, n)
|
|
2222
|
-
}, null, 8, [
|
|
2223
|
-
"model-value",
|
|
2224
|
-
"label",
|
|
2225
|
-
"onUpdate:modelValue"
|
|
2226
|
-
]))), 128))]),
|
|
2227
|
-
y("div", Ii, [y("label", { class: v([x(U), "tpl:!mb-0"]) }, s(x(a).menu.color), 3), f(V, {
|
|
2228
|
-
"swatch-only": "",
|
|
2229
|
-
"model-value": t.color || e.block.linkColor || e.block.color || "",
|
|
2230
|
-
"onUpdate:modelValue": (e) => m(t.id, "color", e)
|
|
2231
|
-
}, null, 8, ["model-value", "onUpdate:modelValue"])])
|
|
2232
|
-
]))), 128)), y("button", {
|
|
2233
|
-
class: v(x(tt)),
|
|
2234
|
-
onClick: d
|
|
2235
|
-
}, [f(x(H), {
|
|
2236
|
-
size: 14,
|
|
2237
|
-
"stroke-width": 2
|
|
2238
|
-
}), g(" " + s(x(a).menu.addItem), 1)], 2)])]),
|
|
2239
|
-
_: 1
|
|
2240
|
-
}, 8, ["label"]),
|
|
2241
|
-
f($, { label: x(a).menu.fontFamily }, {
|
|
2242
|
-
default: r(() => [y("select", {
|
|
2243
|
-
class: v(x(K)),
|
|
2244
|
-
value: x(ot)(e.block.fontFamily),
|
|
2245
|
-
onChange: n[0] ||= (e) => u("fontFamily", e.target.value || void 0)
|
|
2246
|
-
}, [y("option", Ri, s(x(a).title.inheritFont), 1), (_(!0), h(b, null, o(e.fontFamilies, (e) => (_(), h("option", {
|
|
2247
|
-
key: e.value,
|
|
2248
|
-
value: e.value
|
|
2249
|
-
}, s(e.label), 9, zi))), 128))], 42, Li)]),
|
|
2250
|
-
_: 1
|
|
2251
|
-
}, 8, ["label"]),
|
|
2252
|
-
f($, { label: x(a).menu.fontSize }, {
|
|
2253
|
-
default: r(() => [f(X, {
|
|
2254
|
-
"model-value": e.block.fontSize,
|
|
2255
|
-
min: 8,
|
|
2256
|
-
max: 48,
|
|
2257
|
-
suffix: "px",
|
|
2258
|
-
"onUpdate:modelValue": n[1] ||= (e) => u("fontSize", e)
|
|
2259
|
-
}, null, 8, ["model-value"])]),
|
|
2260
|
-
_: 1
|
|
2261
|
-
}, 8, ["label"]),
|
|
2262
|
-
f($, { label: x(a).menu.color }, {
|
|
2263
|
-
default: r(() => [f(V, {
|
|
2264
|
-
"model-value": e.block.color ?? "",
|
|
2265
|
-
"onUpdate:modelValue": n[2] ||= (e) => u("color", e || void 0)
|
|
2266
|
-
}, null, 8, ["model-value"])]),
|
|
2267
|
-
_: 1
|
|
2268
|
-
}, 8, ["label"]),
|
|
2269
|
-
f($, { label: x(a).menu.linkColor }, {
|
|
2270
|
-
default: r(() => [f(V, {
|
|
2271
|
-
"model-value": e.block.linkColor || e.block.color || "",
|
|
2272
|
-
"onUpdate:modelValue": n[3] ||= (e) => u("linkColor", e || void 0)
|
|
2273
|
-
}, null, 8, ["model-value"])]),
|
|
2274
|
-
_: 1
|
|
2275
|
-
}, 8, ["label"]),
|
|
2276
|
-
f($, { label: x(a).menu.textAlign }, {
|
|
2277
|
-
default: r(() => [f(Y, {
|
|
2278
|
-
options: l.value,
|
|
2279
|
-
"model-value": e.block.textAlign,
|
|
2280
|
-
"onUpdate:modelValue": n[4] ||= (e) => u("textAlign", e)
|
|
2281
|
-
}, null, 8, ["options", "model-value"])]),
|
|
2282
|
-
_: 1
|
|
2283
|
-
}, 8, ["label"]),
|
|
2284
|
-
f($, { label: x(a).menu.separator }, {
|
|
2285
|
-
default: r(() => [y("input", {
|
|
2286
|
-
type: "text",
|
|
2287
|
-
class: v(x(K)),
|
|
2288
|
-
value: e.block.separator,
|
|
2289
|
-
onInput: n[5] ||= (e) => u("separator", e.target.value)
|
|
2290
|
-
}, null, 42, Bi)]),
|
|
2291
|
-
_: 1
|
|
2292
|
-
}, 8, ["label"]),
|
|
2293
|
-
f($, { label: x(a).menu.separatorColor }, {
|
|
2294
|
-
default: r(() => [f(V, {
|
|
2295
|
-
"model-value": e.block.separatorColor,
|
|
2296
|
-
"onUpdate:modelValue": n[6] ||= (e) => u("separatorColor", e)
|
|
2297
|
-
}, null, 8, ["model-value"])]),
|
|
2298
|
-
_: 1
|
|
2299
|
-
}, 8, ["label"]),
|
|
2300
|
-
f($, { label: x(a).menu.spacing }, {
|
|
2301
|
-
default: r(() => [f(X, {
|
|
2302
|
-
"model-value": e.block.spacing,
|
|
2303
|
-
min: 0,
|
|
2304
|
-
max: 50,
|
|
2305
|
-
suffix: "px",
|
|
2306
|
-
"onUpdate:modelValue": n[7] ||= (e) => u("spacing", e)
|
|
2307
|
-
}, null, 8, ["model-value"])]),
|
|
2308
|
-
_: 1
|
|
2309
|
-
}, 8, ["label"])
|
|
2310
|
-
], 64));
|
|
2311
|
-
}
|
|
2312
|
-
}), Hi = {
|
|
2313
|
-
class: "tpl:mb-3.5",
|
|
2314
|
-
"data-testid": "paragraph-spacing"
|
|
2315
|
-
}, Ui = { class: "tpl:flex tpl:items-stretch" }, Wi = ["value"], Gi = /* @__PURE__ */ w({
|
|
2316
|
-
__name: "ParagraphToolbar",
|
|
2317
|
-
props: { block: {} },
|
|
2318
|
-
emits: ["update"],
|
|
2319
|
-
setup(e, { emit: t }) {
|
|
2320
|
-
let n = t, { t: r } = B();
|
|
2321
|
-
return (t, i) => (_(), h("div", Hi, [y("label", { class: v(x(U)) }, s(x(r).paragraph.paragraphSpacing), 3), y("div", Ui, [y("input", {
|
|
2322
|
-
type: "number",
|
|
2323
|
-
class: v(x(G)),
|
|
2324
|
-
value: e.block.paragraphSpacing ?? x(ae).paragraphGap,
|
|
2325
|
-
min: "0",
|
|
2326
|
-
max: "64",
|
|
2327
|
-
onInput: i[0] ||= (e) => n("update", { paragraphSpacing: Number(e.target.value) })
|
|
2328
|
-
}, null, 42, Wi), y("span", { class: v(x(W)) }, "px", 2)])]));
|
|
2329
|
-
}
|
|
2330
|
-
});
|
|
2331
|
-
// src/utils/rebalanceColumnChildren.ts
|
|
2332
|
-
function Ki(e, t) {
|
|
2333
|
-
let n = j(t);
|
|
2334
|
-
if (e.length === n) return e;
|
|
2335
|
-
if (e.length < n) {
|
|
2336
|
-
let t = Array.from({ length: n - e.length }, () => []);
|
|
2337
|
-
return [...e, ...t];
|
|
2338
|
-
}
|
|
2339
|
-
let r = e.slice(0, n), i = e.slice(n).flat(), a = [...r[n - 1], ...i];
|
|
2340
|
-
return [...r.slice(0, n - 1), a];
|
|
2341
|
-
}
|
|
2342
|
-
// src/components/toolbar/SectionToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
2343
|
-
var qi = { class: "tpl:mb-3.5" }, Ji = ["value"], Yi = ["value"], Xi = {
|
|
2344
|
-
key: 0,
|
|
2345
|
-
class: "tpl:mb-3.5"
|
|
2346
|
-
}, Zi = {
|
|
2347
|
-
key: 2,
|
|
2348
|
-
class: "tpl:mb-3.5"
|
|
2349
|
-
}, Qi = {
|
|
2350
|
-
key: 0,
|
|
2351
|
-
class: "tpl:mt-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
2352
|
-
}, $i = {
|
|
2353
|
-
key: 1,
|
|
2354
|
-
class: "tpl:mt-3 tpl:ml-0.5 tpl:space-y-3 tpl:border-l tpl:border-[var(--tpl-border)] tpl:pl-3"
|
|
2355
|
-
}, ea = /* @__PURE__ */ w({
|
|
2356
|
-
__name: "SectionToolbar",
|
|
2357
|
-
props: { block: {} },
|
|
2358
|
-
emits: ["update"],
|
|
2359
|
-
setup(e, { emit: t }) {
|
|
2360
|
-
let r = e, i = t, { t: a } = B(), c = n(Ce, void 0), l = n(Ee, void 0), u = c !== void 0 && ne(c), d = p(() => l !== !1 || !!r.block.wrapper), g = p(() => u && !r.block.wrapper), C = p(() => u && d.value), w = p(() => oe(r.block)?.applied === !0), T = p(() => [
|
|
2361
|
-
{
|
|
2362
|
-
value: "1",
|
|
2363
|
-
label: a.section.column1
|
|
2364
|
-
},
|
|
2365
|
-
{
|
|
2366
|
-
value: "2",
|
|
2367
|
-
label: a.section.column2
|
|
2368
|
-
},
|
|
2369
|
-
{
|
|
2370
|
-
value: "3",
|
|
2371
|
-
label: a.section.column3
|
|
2372
|
-
},
|
|
2373
|
-
{
|
|
2374
|
-
value: "1-2",
|
|
2375
|
-
label: a.section.ratio12
|
|
2376
|
-
},
|
|
2377
|
-
{
|
|
2378
|
-
value: "2-1",
|
|
2379
|
-
label: a.section.ratio21
|
|
2380
|
-
}
|
|
2381
|
-
]);
|
|
2382
|
-
function E(e) {
|
|
2383
|
-
let t = e.target.value, n = Ki(r.block.children, t);
|
|
2384
|
-
i("update", {
|
|
2385
|
-
columns: t,
|
|
2386
|
-
children: n
|
|
2387
|
-
});
|
|
2388
|
-
}
|
|
2389
|
-
function D(e) {
|
|
2390
|
-
i("update", { stackOnMobile: e });
|
|
2391
|
-
}
|
|
2392
|
-
function O(e) {
|
|
2393
|
-
i("update", { borderRadius: e });
|
|
2394
|
-
}
|
|
2395
|
-
function k(e) {
|
|
2396
|
-
i("update", { wrapper: e ? { padding: {
|
|
2397
|
-
top: 20,
|
|
2398
|
-
right: 20,
|
|
2399
|
-
bottom: 20,
|
|
2400
|
-
left: 20
|
|
2401
|
-
} } : void 0 });
|
|
2402
|
-
}
|
|
2403
|
-
function A(e) {
|
|
2404
|
-
i("update", { wrapper: {
|
|
2405
|
-
...r.block.wrapper,
|
|
2406
|
-
...e
|
|
2407
|
-
} });
|
|
2408
|
-
}
|
|
2409
|
-
function j(e) {
|
|
2410
|
-
A({ padding: e });
|
|
2411
|
-
}
|
|
2412
|
-
function M(e) {
|
|
2413
|
-
A({ borderRadius: e });
|
|
2414
|
-
}
|
|
2415
|
-
return (t, n) => (_(), h(b, null, [
|
|
2416
|
-
y("div", qi, [y("label", { class: v(x(U)) }, s(x(a).section.columns), 3), y("select", {
|
|
2417
|
-
class: v(x(K)),
|
|
2418
|
-
value: e.block.columns,
|
|
2419
|
-
onChange: E
|
|
2420
|
-
}, [(_(!0), h(b, null, o(T.value, (e) => (_(), h("option", {
|
|
2421
|
-
key: e.value,
|
|
2422
|
-
value: e.value
|
|
2423
|
-
}, s(e.label), 9, Yi))), 128))], 42, Ji)]),
|
|
2424
|
-
e.block.columns === "1" ? m("", !0) : (_(), h("div", Xi, [f(q, {
|
|
2425
|
-
class: "tpl:text-xs tpl:text-[var(--tpl-text)]",
|
|
2426
|
-
"model-value": e.block.stackOnMobile !== !1,
|
|
2427
|
-
label: x(a).section.stackOnMobile,
|
|
2428
|
-
"onUpdate:modelValue": n[0] ||= (e) => D(e)
|
|
2429
|
-
}, null, 8, ["model-value", "label"])])),
|
|
2430
|
-
f(Ot, {
|
|
2431
|
-
"model-value": e.block.borderRadius,
|
|
2432
|
-
label: x(a).section.borderRadius,
|
|
2433
|
-
max: 50,
|
|
2434
|
-
"testid-prefix": "section",
|
|
2435
|
-
"onUpdate:modelValue": O
|
|
2436
|
-
}, null, 8, ["model-value", "label"]),
|
|
2437
|
-
w.value ? m("", !0) : (_(), S(St, {
|
|
2438
|
-
key: 1,
|
|
2439
|
-
"model-value": e.block.border,
|
|
2440
|
-
"testid-prefix": "section",
|
|
2441
|
-
"onUpdate:modelValue": n[1] ||= (e) => i("update", { border: e })
|
|
2442
|
-
}, null, 8, ["model-value"])),
|
|
2443
|
-
d.value ? (_(), h("div", Zi, [
|
|
2444
|
-
f(q, {
|
|
2445
|
-
class: "tpl:text-xs tpl:text-[var(--tpl-text)]",
|
|
2446
|
-
"model-value": !!e.block.wrapper,
|
|
2447
|
-
label: x(a).section.wrapperEnable,
|
|
2448
|
-
disabled: g.value,
|
|
2449
|
-
"onUpdate:modelValue": n[2] ||= (e) => k(e)
|
|
2450
|
-
}, null, 8, [
|
|
2451
|
-
"model-value",
|
|
2452
|
-
"label",
|
|
2453
|
-
"disabled"
|
|
2454
|
-
]),
|
|
2455
|
-
C.value ? (_(), h("p", Qi, s(x(a).section.wrapperLayoutConflict), 1)) : m("", !0),
|
|
2456
|
-
e.block.wrapper ? (_(), h("div", $i, [
|
|
2457
|
-
y("div", null, [y("label", { class: v(x(U)) }, s(x(a).blockSettings.color), 3), f(V, {
|
|
2458
|
-
"model-value": e.block.wrapper.backgroundColor ?? "",
|
|
2459
|
-
"allow-transparent": "",
|
|
2460
|
-
"onUpdate:modelValue": n[3] ||= (e) => A({ backgroundColor: e })
|
|
2461
|
-
}, null, 8, ["model-value"])]),
|
|
2462
|
-
f(An, {
|
|
2463
|
-
"model-value": e.block.wrapper.backgroundImage,
|
|
2464
|
-
"testid-prefix": "section-wrapper",
|
|
2465
|
-
"onUpdate:modelValue": n[4] ||= (e) => A({ backgroundImage: e })
|
|
2466
|
-
}, null, 8, ["model-value"]),
|
|
2467
|
-
f(yn, {
|
|
2468
|
-
label: x(a).blockSettings.padding,
|
|
2469
|
-
"model-value": e.block.wrapper.padding ?? {
|
|
2470
|
-
top: 0,
|
|
2471
|
-
right: 0,
|
|
2472
|
-
bottom: 0,
|
|
2473
|
-
left: 0
|
|
2474
|
-
},
|
|
2475
|
-
"onUpdate:modelValue": j
|
|
2476
|
-
}, null, 8, ["label", "model-value"]),
|
|
2477
|
-
f(Ot, {
|
|
2478
|
-
"model-value": e.block.wrapper.borderRadius,
|
|
2479
|
-
label: x(a).section.borderRadius,
|
|
2480
|
-
max: 50,
|
|
2481
|
-
"testid-prefix": "section-wrapper",
|
|
2482
|
-
"onUpdate:modelValue": M
|
|
2483
|
-
}, null, 8, ["model-value", "label"])
|
|
2484
|
-
])) : m("", !0)
|
|
2485
|
-
])) : m("", !0)
|
|
2486
|
-
], 64));
|
|
2487
|
-
}
|
|
2488
|
-
}), ta = { class: "tpl:mb-3.5" }, na = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, ra = { class: "tpl:flex tpl:items-center tpl:gap-2" }, ia = ["value", "onChange"], aa = ["value"], oa = ["title", "onClick"], sa = { class: "tpl:mb-3.5" }, ca = ["value"], la = { value: "solid" }, ua = { value: "outlined" }, da = { value: "rounded" }, fa = { value: "square" }, pa = { value: "circle" }, ma = { value: "plain" }, ha = { class: "tpl:mb-3.5" }, ga = ["value"], _a = { value: "brand" }, va = { value: "dark" }, ya = { value: "light" }, ba = { class: "tpl:mb-3.5" }, xa = { class: "tpl:mb-3.5" }, Sa = { class: "tpl:flex tpl:items-stretch" }, Ca = ["value"], wa = { class: "tpl:mb-3.5" }, Ta = /* @__PURE__ */ w({
|
|
2489
|
-
__name: "SocialToolbar",
|
|
2490
|
-
props: { block: {} },
|
|
2491
|
-
emits: ["update"],
|
|
2492
|
-
setup(e, { emit: t }) {
|
|
2493
|
-
let n = e, r = t, { t: i } = B();
|
|
2494
|
-
function a(e, t) {
|
|
2495
|
-
r("update", { [e]: t });
|
|
2496
|
-
}
|
|
2497
|
-
function c() {
|
|
2498
|
-
let e = {
|
|
2499
|
-
id: M(),
|
|
2500
|
-
platform: "facebook",
|
|
2501
|
-
url: ""
|
|
2502
|
-
};
|
|
2503
|
-
r("update", { icons: [...n.block.icons, e] });
|
|
2504
|
-
}
|
|
2505
|
-
function l(e, t, i) {
|
|
2506
|
-
let a = n.block.icons.map((n) => n.id === e ? {
|
|
2507
|
-
...n,
|
|
2508
|
-
[t]: i
|
|
2509
|
-
} : n);
|
|
2510
|
-
r("update", { icons: a });
|
|
2511
|
-
}
|
|
2512
|
-
function u(e) {
|
|
2513
|
-
r("update", { icons: n.block.icons.filter((t) => t.id !== e) });
|
|
2514
|
-
}
|
|
2515
|
-
return (t, n) => (_(), h(b, null, [
|
|
2516
|
-
y("div", ta, [y("label", { class: v(x(U)) }, s(x(i).social.icons), 3), y("div", na, [(_(!0), h(b, null, o(e.block.icons, (e) => (_(), h("div", {
|
|
2517
|
-
key: e.id,
|
|
2518
|
-
class: "tpl:flex tpl:flex-col tpl:gap-1.5 tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-2"
|
|
2519
|
-
}, [y("div", ra, [y("select", {
|
|
2520
|
-
"data-testid": "social-platform-select",
|
|
2521
|
-
class: v([x(K), "tpl:flex-1"]),
|
|
2522
|
-
value: e.platform,
|
|
2523
|
-
onChange: (t) => l(e.id, "platform", t.target.value)
|
|
2524
|
-
}, [(_(!0), h(b, null, o(x(ye), (e) => (_(), h("option", {
|
|
2525
|
-
key: e,
|
|
2526
|
-
value: e
|
|
2527
|
-
}, s(x(i).social.platforms[e]), 9, aa))), 128))], 42, ia), y("button", {
|
|
2528
|
-
class: v(x(et)),
|
|
2529
|
-
title: x(i).social.removeIcon,
|
|
2530
|
-
onClick: (t) => u(e.id)
|
|
2531
|
-
}, [f(x(Ze), {
|
|
2532
|
-
size: 14,
|
|
2533
|
-
"stroke-width": 2
|
|
2534
|
-
})], 10, oa)]), f(J, {
|
|
2535
|
-
"model-value": e.url,
|
|
2536
|
-
type: "url",
|
|
2537
|
-
placeholder: x(i).social.urlPlaceholder,
|
|
2538
|
-
"onUpdate:modelValue": (t) => l(e.id, "url", t)
|
|
2539
|
-
}, null, 8, [
|
|
2540
|
-
"model-value",
|
|
2541
|
-
"placeholder",
|
|
2542
|
-
"onUpdate:modelValue"
|
|
2543
|
-
])]))), 128)), y("button", {
|
|
2544
|
-
class: v(x(tt)),
|
|
2545
|
-
onClick: c
|
|
2546
|
-
}, [f(x(H), {
|
|
2547
|
-
size: 14,
|
|
2548
|
-
"stroke-width": 2
|
|
2549
|
-
}), g(" " + s(x(i).social.addIcon), 1)], 2)])]),
|
|
2550
|
-
y("div", sa, [y("label", { class: v(x(U)) }, s(x(i).social.style), 3), y("select", {
|
|
2551
|
-
class: v(x(K)),
|
|
2552
|
-
value: e.block.iconStyle,
|
|
2553
|
-
onChange: n[0] ||= (e) => a("iconStyle", e.target.value)
|
|
2554
|
-
}, [
|
|
2555
|
-
y("option", la, s(x(i).social.styleSolid), 1),
|
|
2556
|
-
y("option", ua, s(x(i).social.styleOutlined), 1),
|
|
2557
|
-
y("option", da, s(x(i).social.styleRounded), 1),
|
|
2558
|
-
y("option", fa, s(x(i).social.styleSquare), 1),
|
|
2559
|
-
y("option", pa, s(x(i).social.styleCircle), 1),
|
|
2560
|
-
y("option", ma, s(x(i).social.stylePlain), 1)
|
|
2561
|
-
], 42, ca)]),
|
|
2562
|
-
y("div", ha, [y("label", { class: v(x(U)) }, s(x(i).social.color), 3), y("select", {
|
|
2563
|
-
"data-testid": "social-tone-select",
|
|
2564
|
-
class: v(x(K)),
|
|
2565
|
-
value: e.block.iconTone ?? "brand",
|
|
2566
|
-
onChange: n[1] ||= (e) => a("iconTone", e.target.value)
|
|
2567
|
-
}, [
|
|
2568
|
-
y("option", _a, s(x(i).social.colorBrand), 1),
|
|
2569
|
-
y("option", va, s(x(i).social.colorDark), 1),
|
|
2570
|
-
y("option", ya, s(x(i).social.colorLight), 1)
|
|
2571
|
-
], 42, ga)]),
|
|
2572
|
-
y("div", ba, [y("label", { class: v(x(U)) }, s(x(i).social.size), 3), f(Y, {
|
|
2573
|
-
options: [
|
|
2574
|
-
{
|
|
2575
|
-
value: "small",
|
|
2576
|
-
label: x(i).social.sizeSmall
|
|
2577
|
-
},
|
|
2578
|
-
{
|
|
2579
|
-
value: "medium",
|
|
2580
|
-
label: x(i).social.sizeMedium
|
|
2581
|
-
},
|
|
2582
|
-
{
|
|
2583
|
-
value: "large",
|
|
2584
|
-
label: x(i).social.sizeLarge
|
|
2585
|
-
}
|
|
2586
|
-
],
|
|
2587
|
-
"model-value": e.block.iconSize,
|
|
2588
|
-
"onUpdate:modelValue": n[2] ||= (e) => a("iconSize", e)
|
|
2589
|
-
}, null, 8, ["options", "model-value"])]),
|
|
2590
|
-
y("div", xa, [y("label", { class: v(x(U)) }, s(x(i).social.spacing), 3), y("div", Sa, [y("input", {
|
|
2591
|
-
type: "number",
|
|
2592
|
-
class: v(x(G)),
|
|
2593
|
-
value: e.block.spacing,
|
|
2594
|
-
min: "0",
|
|
2595
|
-
max: "50",
|
|
2596
|
-
onInput: n[3] ||= (e) => a("spacing", Number(e.target.value))
|
|
2597
|
-
}, null, 42, Ca), y("span", { class: v(x(W)) }, "px", 2)])]),
|
|
2598
|
-
y("div", wa, [y("label", { class: v(x(U)) }, s(x(i).social.align), 3), f(Y, {
|
|
2599
|
-
options: [
|
|
2600
|
-
{
|
|
2601
|
-
value: "left",
|
|
2602
|
-
label: x(i).title.alignLeft,
|
|
2603
|
-
icon: x(Ye)
|
|
2604
|
-
},
|
|
2605
|
-
{
|
|
2606
|
-
value: "center",
|
|
2607
|
-
label: x(i).title.alignCenter,
|
|
2608
|
-
icon: x(Je)
|
|
2609
|
-
},
|
|
2610
|
-
{
|
|
2611
|
-
value: "right",
|
|
2612
|
-
label: x(i).title.alignRight,
|
|
2613
|
-
icon: x(qe)
|
|
2614
|
-
}
|
|
2615
|
-
],
|
|
2616
|
-
"model-value": e.block.align,
|
|
2617
|
-
"onUpdate:modelValue": n[4] ||= (e) => a("align", e)
|
|
2618
|
-
}, null, 8, ["options", "model-value"])])
|
|
2619
|
-
], 64));
|
|
2620
|
-
}
|
|
2621
|
-
}), Ea = { class: "tpl:mb-3.5" }, Da = { class: "tpl:flex tpl:items-stretch" }, Oa = ["value"], ka = ["value"], Aa = /* @__PURE__ */ w({
|
|
2622
|
-
__name: "SpacerToolbar",
|
|
2623
|
-
props: { block: {} },
|
|
2624
|
-
emits: ["update"],
|
|
2625
|
-
setup(e, { emit: t }) {
|
|
2626
|
-
let n = t, { t: r } = B();
|
|
2627
|
-
return (t, i) => (_(), h("div", Ea, [
|
|
2628
|
-
y("label", { class: v(x(U)) }, s(x(r).spacer.height), 3),
|
|
2629
|
-
y("div", Da, [y("input", {
|
|
2630
|
-
type: "number",
|
|
2631
|
-
class: v(x(G)),
|
|
2632
|
-
value: e.block.height,
|
|
2633
|
-
min: "10",
|
|
2634
|
-
max: "100",
|
|
2635
|
-
onInput: i[0] ||= (e) => n("update", { height: Number(e.target.value) })
|
|
2636
|
-
}, null, 42, Oa), y("span", { class: v(x(W)) }, "px", 2)]),
|
|
2637
|
-
y("input", {
|
|
2638
|
-
type: "range",
|
|
2639
|
-
class: "tpl:mt-2 tpl:w-full tpl:accent-[var(--tpl-primary)]",
|
|
2640
|
-
value: e.block.height,
|
|
2641
|
-
min: "10",
|
|
2642
|
-
max: "100",
|
|
2643
|
-
onInput: i[1] ||= (e) => n("update", { height: Number(e.target.value) })
|
|
2644
|
-
}, null, 40, ka)
|
|
2645
|
-
]));
|
|
2646
|
-
}
|
|
2647
|
-
}), ja = { class: "tpl:mb-3.5" }, Ma = { class: "tpl:flex tpl:items-center tpl:gap-3" }, Na = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, Pa = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, Fa = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, Ia = ["disabled"], La = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, Ra = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, za = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, Ba = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, Va = ["disabled"], Ha = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, Ua = { class: "tpl:mb-3.5" }, Wa = {
|
|
2648
|
-
key: 0,
|
|
2649
|
-
class: "tpl:mb-3.5"
|
|
2650
|
-
}, Ga = { class: "tpl:mb-3.5" }, Ka = { class: "tpl:mb-3.5" }, qa = { class: "tpl:flex tpl:items-stretch" }, Ja = ["value"], Ya = { class: "tpl:mb-3.5" }, Xa = { class: "tpl:flex tpl:items-stretch" }, Za = ["value"], Qa = { class: "tpl:mb-3.5" }, $a = ["value"], eo = { value: "" }, to = ["value"], no = { class: "tpl:mb-3.5" }, ro = { class: "tpl:flex tpl:items-stretch" }, io = ["value"], ao = { class: "tpl:mb-3.5" }, oo = { class: "tpl:mb-3.5" }, so = /* @__PURE__ */ w({
|
|
2651
|
-
__name: "TableToolbar",
|
|
2652
|
-
props: {
|
|
2653
|
-
block: {},
|
|
2654
|
-
fontFamilies: {}
|
|
2655
|
-
},
|
|
2656
|
-
emits: ["update"],
|
|
2657
|
-
setup(e, { emit: t }) {
|
|
2658
|
-
let n = e, r = t, { t: i } = B(), a = p(() => n.block.rows.length > 0 ? n.block.rows[0].cells.length : 0);
|
|
2659
|
-
function c(e, t) {
|
|
2660
|
-
r("update", { [e]: t });
|
|
2661
|
-
}
|
|
2662
|
-
function l() {
|
|
2663
|
-
let e = n.block.rows.length > 0 ? n.block.rows[0].cells.length : 3, t = {
|
|
2664
|
-
id: M(),
|
|
2665
|
-
cells: Array.from({ length: e }, () => ({
|
|
2666
|
-
id: M(),
|
|
2667
|
-
content: ""
|
|
2668
|
-
}))
|
|
2669
|
-
};
|
|
2670
|
-
r("update", { rows: [...n.block.rows, t] });
|
|
2671
|
-
}
|
|
2672
|
-
function u(e) {
|
|
2673
|
-
r("update", { rows: n.block.rows.filter((t) => t.id !== e) });
|
|
2674
|
-
}
|
|
2675
|
-
function d() {
|
|
2676
|
-
let e = n.block.rows.map((e) => ({
|
|
2677
|
-
...e,
|
|
2678
|
-
cells: [...e.cells, {
|
|
2679
|
-
id: M(),
|
|
2680
|
-
content: ""
|
|
2681
|
-
}]
|
|
2682
|
-
}));
|
|
2683
|
-
r("update", { rows: e });
|
|
2684
|
-
}
|
|
2685
|
-
function g(e) {
|
|
2686
|
-
let t = n.block.rows.map((t) => ({
|
|
2687
|
-
...t,
|
|
2688
|
-
cells: t.cells.filter((t, n) => n !== e)
|
|
2689
|
-
}));
|
|
2690
|
-
r("update", { rows: t });
|
|
2691
|
-
}
|
|
2692
|
-
return (t, n) => (_(), h(b, null, [
|
|
2693
|
-
y("div", ja, [y("label", { class: v(x(U)) }, s(x(i).table.dimensions), 3), y("div", Ma, [y("div", Na, [y("span", Pa, s(x(i).table.rows), 1), y("div", Fa, [
|
|
2694
|
-
y("button", {
|
|
2695
|
-
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:hover:text-[var(--tpl-primary)] tpl:disabled:opacity-30",
|
|
2696
|
-
disabled: e.block.rows.length <= 1,
|
|
2697
|
-
onClick: n[0] ||= (t) => u(e.block.rows[e.block.rows.length - 1].id)
|
|
2698
|
-
}, [f(x(Re), {
|
|
2699
|
-
size: 12,
|
|
2700
|
-
"stroke-width": 2
|
|
2701
|
-
})], 8, Ia),
|
|
2702
|
-
y("span", La, s(e.block.rows.length), 1),
|
|
2703
|
-
y("button", {
|
|
2704
|
-
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:hover:text-[var(--tpl-primary)]",
|
|
2705
|
-
onClick: l
|
|
2706
|
-
}, [f(x(H), {
|
|
2707
|
-
size: 12,
|
|
2708
|
-
"stroke-width": 2
|
|
2709
|
-
})])
|
|
2710
|
-
])]), y("div", Ra, [y("span", za, s(x(i).table.columns), 1), y("div", Ba, [
|
|
2711
|
-
y("button", {
|
|
2712
|
-
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:hover:text-[var(--tpl-primary)] tpl:disabled:opacity-30",
|
|
2713
|
-
disabled: a.value <= 1,
|
|
2714
|
-
onClick: n[1] ||= (e) => g(a.value - 1)
|
|
2715
|
-
}, [f(x(Re), {
|
|
2716
|
-
size: 12,
|
|
2717
|
-
"stroke-width": 2
|
|
2718
|
-
})], 8, Va),
|
|
2719
|
-
y("span", Ha, s(a.value), 1),
|
|
2720
|
-
y("button", {
|
|
2721
|
-
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:hover:text-[var(--tpl-primary)]",
|
|
2722
|
-
onClick: d
|
|
2723
|
-
}, [f(x(H), {
|
|
2724
|
-
size: 12,
|
|
2725
|
-
"stroke-width": 2
|
|
2726
|
-
})])
|
|
2727
|
-
])])])]),
|
|
2728
|
-
y("div", Ua, [f(q, {
|
|
2729
|
-
class: "tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-muted)]",
|
|
2730
|
-
"model-value": e.block.hasHeaderRow,
|
|
2731
|
-
label: x(i).table.hasHeaderRow,
|
|
2732
|
-
"onUpdate:modelValue": n[2] ||= (e) => c("hasHeaderRow", e)
|
|
2733
|
-
}, null, 8, ["model-value", "label"])]),
|
|
2734
|
-
e.block.hasHeaderRow ? (_(), h("div", Wa, [y("label", { class: v(x(U)) }, s(x(i).table.headerBackgroundColor), 3), f(V, {
|
|
2735
|
-
"model-value": e.block.headerBackgroundColor ?? "",
|
|
2736
|
-
"seed-color": x(nt),
|
|
2737
|
-
placeholder: x(i).table.noHeaderBg,
|
|
2738
|
-
"onUpdate:modelValue": n[3] ||= (e) => c("headerBackgroundColor", e || null)
|
|
2739
|
-
}, null, 8, [
|
|
2740
|
-
"model-value",
|
|
2741
|
-
"seed-color",
|
|
2742
|
-
"placeholder"
|
|
2743
|
-
])])) : m("", !0),
|
|
2744
|
-
y("div", Ga, [y("label", { class: v(x(U)) }, s(x(i).table.borderColor), 3), f(V, {
|
|
2745
|
-
"model-value": e.block.borderColor,
|
|
2746
|
-
"onUpdate:modelValue": n[4] ||= (e) => c("borderColor", e)
|
|
2747
|
-
}, null, 8, ["model-value"])]),
|
|
2748
|
-
y("div", Ka, [y("label", { class: v(x(U)) }, s(x(i).table.borderWidth), 3), y("div", qa, [y("input", {
|
|
2749
|
-
type: "number",
|
|
2750
|
-
class: v(x(G)),
|
|
2751
|
-
value: e.block.borderWidth,
|
|
2752
|
-
min: "0",
|
|
2753
|
-
max: "10",
|
|
2754
|
-
onInput: n[5] ||= (e) => c("borderWidth", Number(e.target.value))
|
|
2755
|
-
}, null, 42, Ja), y("span", { class: v(x(W)) }, "px", 2)])]),
|
|
2756
|
-
y("div", Ya, [y("label", { class: v(x(U)) }, s(x(i).table.cellPadding), 3), y("div", Xa, [y("input", {
|
|
2757
|
-
type: "number",
|
|
2758
|
-
class: v(x(G)),
|
|
2759
|
-
value: e.block.cellPadding,
|
|
2760
|
-
min: "0",
|
|
2761
|
-
max: "30",
|
|
2762
|
-
onInput: n[6] ||= (e) => c("cellPadding", Number(e.target.value))
|
|
2763
|
-
}, null, 42, Za), y("span", { class: v(x(W)) }, "px", 2)])]),
|
|
2764
|
-
y("div", Qa, [y("label", { class: v(x(U)) }, s(x(i).table.fontFamily), 3), y("select", {
|
|
2765
|
-
class: v(x(K)),
|
|
2766
|
-
value: x(ot)(e.block.fontFamily),
|
|
2767
|
-
onChange: n[7] ||= (e) => c("fontFamily", e.target.value || void 0)
|
|
2768
|
-
}, [y("option", eo, s(x(i).title.inheritFont), 1), (_(!0), h(b, null, o(e.fontFamilies, (e) => (_(), h("option", {
|
|
2769
|
-
key: e.value,
|
|
2770
|
-
value: e.value
|
|
2771
|
-
}, s(e.label), 9, to))), 128))], 42, $a)]),
|
|
2772
|
-
y("div", no, [y("label", { class: v(x(U)) }, s(x(i).table.fontSize), 3), y("div", ro, [y("input", {
|
|
2773
|
-
type: "number",
|
|
2774
|
-
class: v(x(G)),
|
|
2775
|
-
value: e.block.fontSize,
|
|
2776
|
-
min: "10",
|
|
2777
|
-
max: "32",
|
|
2778
|
-
onInput: n[8] ||= (e) => c("fontSize", Number(e.target.value))
|
|
2779
|
-
}, null, 42, io), y("span", { class: v(x(W)) }, "px", 2)])]),
|
|
2780
|
-
y("div", ao, [y("label", { class: v(x(U)) }, s(x(i).table.color), 3), f(V, {
|
|
2781
|
-
"model-value": e.block.color ?? "",
|
|
2782
|
-
"onUpdate:modelValue": n[9] ||= (e) => c("color", e || void 0)
|
|
2783
|
-
}, null, 8, ["model-value"])]),
|
|
2784
|
-
y("div", oo, [y("label", { class: v(x(U)) }, s(x(i).table.textAlign), 3), f(Y, {
|
|
2785
|
-
options: [
|
|
2786
|
-
{
|
|
2787
|
-
value: "left",
|
|
2788
|
-
label: x(i).title.alignLeft,
|
|
2789
|
-
icon: x(Ye)
|
|
2790
|
-
},
|
|
2791
|
-
{
|
|
2792
|
-
value: "center",
|
|
2793
|
-
label: x(i).title.alignCenter,
|
|
2794
|
-
icon: x(Je)
|
|
2795
|
-
},
|
|
2796
|
-
{
|
|
2797
|
-
value: "right",
|
|
2798
|
-
label: x(i).title.alignRight,
|
|
2799
|
-
icon: x(qe)
|
|
2800
|
-
}
|
|
2801
|
-
],
|
|
2802
|
-
"model-value": e.block.textAlign,
|
|
2803
|
-
"onUpdate:modelValue": n[10] ||= (e) => c("textAlign", e)
|
|
2804
|
-
}, null, 8, ["options", "model-value"])])
|
|
2805
|
-
], 64));
|
|
2806
|
-
}
|
|
2807
|
-
}), co = { class: "tpl:mb-3.5" }, lo = ["value"], uo = { value: 1 }, fo = { value: 2 }, po = { value: 3 }, mo = { value: 4 }, ho = { class: "tpl:mb-3.5" }, go = ["value"], _o = { value: "" }, vo = ["value"], yo = { class: "tpl:mb-3.5" }, bo = { class: "tpl:mb-3.5" }, xo = /* @__PURE__ */ w({
|
|
2808
|
-
__name: "TitleToolbar",
|
|
2809
|
-
props: {
|
|
2810
|
-
block: {},
|
|
2811
|
-
fontFamilies: {}
|
|
2812
|
-
},
|
|
2813
|
-
emits: ["update"],
|
|
2814
|
-
setup(e, { emit: t }) {
|
|
2815
|
-
let n = t, { t: r } = B();
|
|
2816
|
-
function i(e, t) {
|
|
2817
|
-
n("update", { [e]: t });
|
|
2818
|
-
}
|
|
2819
|
-
return (t, n) => (_(), h(b, null, [
|
|
2820
|
-
y("div", co, [y("label", { class: v(x(U)) }, s(x(r).title.level), 3), y("select", {
|
|
2821
|
-
class: v(x(K)),
|
|
2822
|
-
value: e.block.level,
|
|
2823
|
-
onChange: n[0] ||= (e) => i("level", Number(e.target.value))
|
|
2824
|
-
}, [
|
|
2825
|
-
y("option", uo, s(x(r).title.heading1), 1),
|
|
2826
|
-
y("option", fo, s(x(r).title.heading2), 1),
|
|
2827
|
-
y("option", po, s(x(r).title.heading3), 1),
|
|
2828
|
-
y("option", mo, s(x(r).title.heading4), 1)
|
|
2829
|
-
], 42, lo)]),
|
|
2830
|
-
y("div", ho, [y("label", { class: v(x(U)) }, s(x(r).title.fontFamily), 3), y("select", {
|
|
2831
|
-
class: v(x(K)),
|
|
2832
|
-
value: x(ot)(e.block.fontFamily),
|
|
2833
|
-
onChange: n[1] ||= (e) => i("fontFamily", e.target.value || void 0)
|
|
2834
|
-
}, [y("option", _o, s(x(r).title.inheritFont), 1), (_(!0), h(b, null, o(e.fontFamilies, (e) => (_(), h("option", {
|
|
2835
|
-
key: e.value,
|
|
2836
|
-
value: e.value
|
|
2837
|
-
}, s(e.label), 9, vo))), 128))], 42, go)]),
|
|
2838
|
-
y("div", yo, [y("label", { class: v(x(U)) }, s(x(r).title.color), 3), f(V, {
|
|
2839
|
-
"model-value": e.block.color ?? "",
|
|
2840
|
-
"onUpdate:modelValue": n[2] ||= (e) => i("color", e || void 0)
|
|
2841
|
-
}, null, 8, ["model-value"])]),
|
|
2842
|
-
y("div", bo, [y("label", { class: v(x(U)) }, s(x(r).title.align), 3), f(Y, {
|
|
2843
|
-
options: [
|
|
2844
|
-
{
|
|
2845
|
-
value: "left",
|
|
2846
|
-
label: x(r).title.alignLeft,
|
|
2847
|
-
icon: x(Ye)
|
|
2848
|
-
},
|
|
2849
|
-
{
|
|
2850
|
-
value: "center",
|
|
2851
|
-
label: x(r).title.alignCenter,
|
|
2852
|
-
icon: x(Je)
|
|
2853
|
-
},
|
|
2854
|
-
{
|
|
2855
|
-
value: "right",
|
|
2856
|
-
label: x(r).title.alignRight,
|
|
2857
|
-
icon: x(qe)
|
|
2858
|
-
}
|
|
2859
|
-
],
|
|
2860
|
-
"model-value": e.block.textAlign,
|
|
2861
|
-
"onUpdate:modelValue": n[3] ||= (e) => i("textAlign", e)
|
|
2862
|
-
}, null, 8, ["options", "model-value"])])
|
|
2863
|
-
], 64));
|
|
2864
|
-
}
|
|
2865
|
-
}), So = { class: "tpl:mb-3.5" }, Co = {
|
|
2866
|
-
key: 0,
|
|
2867
|
-
class: "tpl:mb-3.5"
|
|
2868
|
-
}, wo = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, To = [
|
|
2869
|
-
"value",
|
|
2870
|
-
"placeholder",
|
|
2871
|
-
"title"
|
|
2872
|
-
], Eo = { class: "tpl:mb-3.5" }, Do = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, Oo = { class: "tpl:mb-3.5" }, ko = { class: "tpl:mb-3.5" }, Ao = ["value"], jo = { value: "full" }, Mo = { value: "custom" }, No = {
|
|
2873
|
-
key: 0,
|
|
2874
|
-
class: "tpl:mt-2 tpl:flex tpl:items-stretch"
|
|
2875
|
-
}, Po = ["value"], Fo = { class: "tpl:mb-3.5" }, Io = ["value"], Lo = { value: "auto" }, Ro = { value: "custom" }, zo = {
|
|
2876
|
-
key: 0,
|
|
2877
|
-
class: "tpl:mt-2 tpl:flex tpl:items-stretch"
|
|
2878
|
-
}, Bo = ["value"], Vo = { class: "tpl:mb-3.5" }, Ho = 350, Uo = 200, Wo = /* @__PURE__ */ w({
|
|
2879
|
-
__name: "VideoToolbar",
|
|
2880
|
-
props: { block: {} },
|
|
2881
|
-
emits: ["update"],
|
|
2882
|
-
setup(e, { emit: r }) {
|
|
2883
|
-
let i = e, a = r, { t: o } = B(), c = n(we, null), l = n(Te, te.liquid), u = z(), d = [
|
|
2884
|
-
300,
|
|
2885
|
-
400,
|
|
2886
|
-
500
|
|
2887
|
-
], C = p(() => !!c), w = p(() => A(i.block.url, l)), T = p(() => {
|
|
2888
|
-
let e = i.block.width;
|
|
2889
|
-
return e === "full" ? "full" : d.includes(e) ? String(e) : "custom";
|
|
2890
|
-
}), E = p(() => typeof i.block.height == "number" ? "custom" : "auto"), D = t(!1), { start: O } = xe(() => {
|
|
2891
|
-
D.value = !1;
|
|
2892
|
-
}, 1e3, { immediate: !1 });
|
|
2893
|
-
function k(e, t) {
|
|
2894
|
-
a("update", { [e]: t });
|
|
2895
|
-
}
|
|
2896
|
-
function j(e) {
|
|
2897
|
-
if (e === "custom") {
|
|
2898
|
-
let e = i.block.width;
|
|
2899
|
-
(typeof e != "number" || d.includes(e)) && k("width", Ho);
|
|
2900
|
-
} else k("width", e === "full" ? "full" : Number(e));
|
|
2901
|
-
}
|
|
2902
|
-
function M(e) {
|
|
2903
|
-
let t = Number(e);
|
|
2904
|
-
!Number.isFinite(t) || t <= 0 || k("width", t);
|
|
2905
|
-
}
|
|
2906
|
-
function N(e) {
|
|
2907
|
-
k("height", e === "custom" ? Uo : void 0);
|
|
2908
|
-
}
|
|
2909
|
-
function P(e) {
|
|
2910
|
-
let t = Number(e);
|
|
2911
|
-
!Number.isFinite(t) || t <= 0 || k("height", t);
|
|
2912
|
-
}
|
|
2913
|
-
async function F() {
|
|
2914
|
-
let e = await c?.({ accept: ["images"] });
|
|
2915
|
-
u.alive && e && (k("thumbnailUrl", e.url), D.value = !0, O());
|
|
2916
|
-
}
|
|
2917
|
-
return (t, n) => (_(), h(b, null, [
|
|
2918
|
-
y("div", So, [
|
|
2919
|
-
y("label", { class: v(x(U)) }, s(x(o).video.videoUrl), 3),
|
|
2920
|
-
f(J, {
|
|
2921
|
-
"model-value": e.block.url,
|
|
2922
|
-
type: "url",
|
|
2923
|
-
placeholder: x(o).video.videoUrlPlaceholder,
|
|
2924
|
-
"onUpdate:modelValue": n[0] ||= (e) => k("url", e)
|
|
2925
|
-
}, null, 8, ["model-value", "placeholder"]),
|
|
2926
|
-
e.block.url ? (_(), S(q, {
|
|
2927
|
-
key: 0,
|
|
2928
|
-
class: "tpl:mt-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]",
|
|
2929
|
-
"model-value": e.block.openInNewTab ?? !1,
|
|
2930
|
-
label: x(o).video.openInNewTab,
|
|
2931
|
-
"onUpdate:modelValue": n[1] ||= (e) => k("openInNewTab", e)
|
|
2932
|
-
}, null, 8, ["model-value", "label"])) : m("", !0)
|
|
2933
|
-
]),
|
|
2934
|
-
w.value ? (_(), h("div", Co, [y("label", { class: v(x(U)) }, [g(s(x(o).video.placeholderUrl) + " ", 1), y("span", wo, s(x(o).video.optional), 1)], 2), y("input", {
|
|
2935
|
-
type: "url",
|
|
2936
|
-
class: v(x(K)),
|
|
2937
|
-
value: e.block.placeholderUrl || "",
|
|
2938
|
-
placeholder: x(o).video.placeholderUrlPlaceholder,
|
|
2939
|
-
title: x(o).video.placeholderUrlTooltip,
|
|
2940
|
-
onInput: n[2] ||= (e) => k("placeholderUrl", e.target.value)
|
|
2941
|
-
}, null, 42, To)])) : m("", !0),
|
|
2942
|
-
y("div", Eo, [
|
|
2943
|
-
y("label", { class: v(x(U)) }, [g(s(x(o).video.customThumbnail) + " ", 1), y("span", Do, s(x(o).video.optional), 1)], 2),
|
|
2944
|
-
f(J, {
|
|
2945
|
-
"model-value": e.block.thumbnailUrl,
|
|
2946
|
-
type: "url",
|
|
2947
|
-
placeholder: x(o).video.thumbnailPlaceholder,
|
|
2948
|
-
pulse: D.value,
|
|
2949
|
-
"onUpdate:modelValue": n[3] ||= (e) => k("thumbnailUrl", e)
|
|
2950
|
-
}, null, 8, [
|
|
2951
|
-
"model-value",
|
|
2952
|
-
"placeholder",
|
|
2953
|
-
"pulse"
|
|
2954
|
-
]),
|
|
2955
|
-
C.value ? (_(), h("button", {
|
|
2956
|
-
key: 0,
|
|
2957
|
-
class: "tpl:mt-2 tpl:flex tpl:w-full tpl:items-center tpl:justify-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",
|
|
2958
|
-
style: {
|
|
2959
|
-
"border-color": "var(--tpl-border)",
|
|
2960
|
-
color: "var(--tpl-primary)",
|
|
2961
|
-
"background-color": "var(--tpl-bg)"
|
|
2962
|
-
},
|
|
2963
|
-
onClick: F
|
|
2964
|
-
}, [f(x(Ve), {
|
|
2965
|
-
size: 14,
|
|
2966
|
-
"stroke-width": 1.5
|
|
2967
|
-
}), g(" " + s(x(o).image.browseMedia), 1)])) : m("", !0)
|
|
2968
|
-
]),
|
|
2969
|
-
y("div", Oo, [y("label", { class: v(x(U)) }, s(x(o).video.altText), 3), f(J, {
|
|
2970
|
-
"model-value": e.block.alt,
|
|
2971
|
-
type: "text",
|
|
2972
|
-
placeholder: x(o).video.altTextPlaceholder,
|
|
2973
|
-
"onUpdate:modelValue": n[4] ||= (e) => k("alt", e)
|
|
2974
|
-
}, null, 8, ["model-value", "placeholder"])]),
|
|
2975
|
-
y("div", ko, [
|
|
2976
|
-
y("label", { class: v(x(U)) }, s(x(o).video.width), 3),
|
|
2977
|
-
y("select", {
|
|
2978
|
-
class: v(x(K)),
|
|
2979
|
-
"data-testid": "video-width-mode",
|
|
2980
|
-
value: T.value,
|
|
2981
|
-
onChange: n[5] ||= (e) => j(e.target.value)
|
|
2982
|
-
}, [
|
|
2983
|
-
y("option", jo, s(x(o).video.fullWidth), 1),
|
|
2984
|
-
n[10] ||= y("option", { value: "300" }, "300px", -1),
|
|
2985
|
-
n[11] ||= y("option", { value: "400" }, "400px", -1),
|
|
2986
|
-
n[12] ||= y("option", { value: "500" }, "500px", -1),
|
|
2987
|
-
y("option", Mo, s(x(o).video.widthCustom), 1)
|
|
2988
|
-
], 42, Ao),
|
|
2989
|
-
T.value === "custom" ? (_(), h("div", No, [y("input", {
|
|
2990
|
-
type: "number",
|
|
2991
|
-
"data-testid": "video-width-input",
|
|
2992
|
-
class: v(x(G)),
|
|
2993
|
-
value: e.block.width,
|
|
2994
|
-
min: "20",
|
|
2995
|
-
onInput: n[6] ||= (e) => M(e.target.value)
|
|
2996
|
-
}, null, 42, Po), y("span", { class: v(x(W)) }, "px", 2)])) : m("", !0)
|
|
2997
|
-
]),
|
|
2998
|
-
y("div", Fo, [
|
|
2999
|
-
y("label", { class: v(x(U)) }, s(x(o).video.height), 3),
|
|
3000
|
-
y("select", {
|
|
3001
|
-
class: v(x(K)),
|
|
3002
|
-
"data-testid": "video-height-mode",
|
|
3003
|
-
value: E.value,
|
|
3004
|
-
onChange: n[7] ||= (e) => N(e.target.value)
|
|
3005
|
-
}, [y("option", Lo, s(x(o).video.heightAuto), 1), y("option", Ro, s(x(o).video.heightCustom), 1)], 42, Io),
|
|
3006
|
-
E.value === "custom" ? (_(), h("div", zo, [y("input", {
|
|
3007
|
-
type: "number",
|
|
3008
|
-
"data-testid": "video-height-input",
|
|
3009
|
-
class: v(x(G)),
|
|
3010
|
-
value: e.block.height,
|
|
3011
|
-
min: "20",
|
|
3012
|
-
onInput: n[8] ||= (e) => P(e.target.value)
|
|
3013
|
-
}, null, 42, Bo), y("span", { class: v(x(W)) }, "px", 2)])) : m("", !0)
|
|
3014
|
-
]),
|
|
3015
|
-
y("div", Vo, [y("label", { class: v(x(U)) }, s(x(o).title.align), 3), f(Y, {
|
|
3016
|
-
options: [
|
|
3017
|
-
{
|
|
3018
|
-
value: "left",
|
|
3019
|
-
label: x(o).title.alignLeft
|
|
3020
|
-
},
|
|
3021
|
-
{
|
|
3022
|
-
value: "center",
|
|
3023
|
-
label: x(o).title.alignCenter
|
|
3024
|
-
},
|
|
3025
|
-
{
|
|
3026
|
-
value: "right",
|
|
3027
|
-
label: x(o).title.alignRight
|
|
3028
|
-
}
|
|
3029
|
-
],
|
|
3030
|
-
"model-value": e.block.align,
|
|
3031
|
-
"onUpdate:modelValue": n[9] ||= (e) => k("align", e)
|
|
3032
|
-
}, null, 8, ["options", "model-value"])])
|
|
3033
|
-
], 64));
|
|
3034
|
-
}
|
|
3035
|
-
}), Go = ["aria-label"], Ko = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-3.5" }, qo = { class: "tpl:flex tpl:items-center tpl:gap-2 tpl:text-[var(--tpl-primary)]" }, Jo = { class: "tpl:m-0 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, Yo = { class: "tpl:flex tpl:gap-1" }, Xo = ["title"], Zo = ["title"], Qo = { class: "tpl:flex-1 tpl:overflow-y-auto tpl:p-4" }, $o = /*@__PURE__*/ w({
|
|
3036
|
-
__name: "Toolbar",
|
|
3037
|
-
props: { block: {} },
|
|
3038
|
-
emits: [
|
|
3039
|
-
"update",
|
|
3040
|
-
"delete",
|
|
3041
|
-
"duplicate"
|
|
3042
|
-
],
|
|
3043
|
-
setup(e, { emit: t }) {
|
|
3044
|
-
let r = C(() => import("./CountdownToolbar-BqoYzf_6.js")), a = e, o = t, { t: c } = B(), l = Se(Me, "Toolbar"), u = n(je, []), d = p(() => a.block.type), g = p(() => N(a.block)), v = p(() => {
|
|
3045
|
-
if (g.value) return u.find((e) => e.type === a.block.customType);
|
|
3046
|
-
}), b = p(() => g.value ? v.value?.name ?? a.block.customType : se(d.value, c)), w = p(() => at(l.fonts.value, "fontFamily" in a.block ? a.block.fontFamily : void 0));
|
|
3047
|
-
function T(e) {
|
|
3048
|
-
o("update", e);
|
|
3049
|
-
}
|
|
3050
|
-
return (t, n) => (_(), h("aside", {
|
|
3051
|
-
"data-testid": "block-toolbar",
|
|
3052
|
-
"aria-label": x(c).landmarks.blockToolbar,
|
|
3053
|
-
class: "tpl:flex tpl:w-full tpl:flex-1 tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)]"
|
|
3054
|
-
}, [y("div", Ko, [y("div", qo, [x(ze)[d.value] ? (_(), S(i(x(ze)[d.value]), {
|
|
3055
|
-
key: 0,
|
|
3056
|
-
size: 16,
|
|
3057
|
-
"stroke-width": 1.5
|
|
3058
|
-
})) : g.value ? (_(), S(x(ue), {
|
|
3059
|
-
key: 1,
|
|
3060
|
-
size: 16,
|
|
3061
|
-
"stroke-width": 1.5
|
|
3062
|
-
})) : m("", !0), y("h3", Jo, s(b.value), 1)]), y("div", Yo, [y("button", {
|
|
3063
|
-
class: "tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:hover:bg-[var(--tpl-bg-active)] tpl:hover:text-[var(--tpl-text)]",
|
|
3064
|
-
title: x(c).toolbar.duplicate,
|
|
3065
|
-
onClick: n[0] ||= (e) => o("duplicate")
|
|
3066
|
-
}, [f(x(Be), {
|
|
3067
|
-
size: 14,
|
|
3068
|
-
"stroke-width": 2
|
|
3069
|
-
})], 8, Xo), y("button", {
|
|
3070
|
-
class: "tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:hover:border-[var(--tpl-danger)] tpl:hover:bg-[var(--tpl-danger-light)] tpl:hover:text-[var(--tpl-danger)]",
|
|
3071
|
-
title: x(c).toolbar.delete,
|
|
3072
|
-
onClick: n[1] ||= (e) => o("delete")
|
|
3073
|
-
}, [f(x(Xe), {
|
|
3074
|
-
size: 14,
|
|
3075
|
-
"stroke-width": 2
|
|
3076
|
-
})], 8, Zo)])]), y("div", Qo, [g.value ? (_(), S(Wr, {
|
|
3077
|
-
key: 0,
|
|
3078
|
-
block: e.block,
|
|
3079
|
-
onUpdateFieldValues: n[2] ||= (e) => o("update", { fieldValues: e }),
|
|
3080
|
-
onUpdateDataSourceFetched: n[3] ||= (e) => o("update", { dataSourceFetched: e })
|
|
3081
|
-
}, null, 8, ["block"])) : d.value === "section" ? (_(), S(ea, {
|
|
3082
|
-
key: 1,
|
|
3083
|
-
block: e.block,
|
|
3084
|
-
onUpdate: T
|
|
3085
|
-
}, null, 8, ["block"])) : d.value === "title" ? (_(), S(xo, {
|
|
3086
|
-
key: 2,
|
|
3087
|
-
block: e.block,
|
|
3088
|
-
"font-families": w.value,
|
|
3089
|
-
onUpdate: T
|
|
3090
|
-
}, null, 8, ["block", "font-families"])) : d.value === "paragraph" ? (_(), S(Gi, {
|
|
3091
|
-
key: 3,
|
|
3092
|
-
block: e.block,
|
|
3093
|
-
onUpdate: T
|
|
3094
|
-
}, null, 8, ["block"])) : d.value === "image" ? (_(), S(ki, {
|
|
3095
|
-
key: 4,
|
|
3096
|
-
block: e.block,
|
|
3097
|
-
onUpdate: T
|
|
3098
|
-
}, null, 8, ["block"])) : d.value === "video" ? (_(), S(Wo, {
|
|
3099
|
-
key: 5,
|
|
3100
|
-
block: e.block,
|
|
3101
|
-
onUpdate: T
|
|
3102
|
-
}, null, 8, ["block"])) : d.value === "button" ? (_(), S(Yt, {
|
|
3103
|
-
key: 6,
|
|
3104
|
-
block: e.block,
|
|
3105
|
-
"font-families": w.value,
|
|
3106
|
-
onUpdate: T
|
|
3107
|
-
}, null, 8, ["block", "font-families"])) : d.value === "divider" ? (_(), S(Xr, {
|
|
3108
|
-
key: 7,
|
|
3109
|
-
block: e.block,
|
|
3110
|
-
onUpdate: T
|
|
3111
|
-
}, null, 8, ["block"])) : d.value === "social" ? (_(), S(Ta, {
|
|
3112
|
-
key: 8,
|
|
3113
|
-
block: e.block,
|
|
3114
|
-
onUpdate: T
|
|
3115
|
-
}, null, 8, ["block"])) : d.value === "menu" ? (_(), S(Vi, {
|
|
3116
|
-
key: 9,
|
|
3117
|
-
block: e.block,
|
|
3118
|
-
"font-families": w.value,
|
|
3119
|
-
onUpdate: T
|
|
3120
|
-
}, null, 8, ["block", "font-families"])) : d.value === "table" ? (_(), S(so, {
|
|
3121
|
-
key: 10,
|
|
3122
|
-
block: e.block,
|
|
3123
|
-
"font-families": w.value,
|
|
3124
|
-
onUpdate: T
|
|
3125
|
-
}, null, 8, ["block", "font-families"])) : d.value === "spacer" ? (_(), S(Aa, {
|
|
3126
|
-
key: 11,
|
|
3127
|
-
block: e.block,
|
|
3128
|
-
onUpdate: T
|
|
3129
|
-
}, null, 8, ["block"])) : d.value === "html" ? (_(), S(ei, {
|
|
3130
|
-
key: 12,
|
|
3131
|
-
block: e.block,
|
|
3132
|
-
onUpdate: T
|
|
3133
|
-
}, null, 8, ["block"])) : d.value === "countdown" ? (_(), S(x(r), {
|
|
3134
|
-
key: 13,
|
|
3135
|
-
block: e.block,
|
|
3136
|
-
"font-families": w.value,
|
|
3137
|
-
onUpdate: T
|
|
3138
|
-
}, null, 8, ["block", "font-families"])) : m("", !0), f(or, {
|
|
3139
|
-
block: e.block,
|
|
3140
|
-
"is-first-section": d.value === "paragraph",
|
|
3141
|
-
onUpdate: T
|
|
3142
|
-
}, null, 8, ["block", "is-first-section"])])], 8, Go));
|
|
3143
|
-
}
|
|
3144
|
-
}), es = /* @__PURE__ */ e({ default: () => ts }), ts = /*#__PURE__*/ Qe($o, [["__scopeId", "data-v-e2d2c22f"]]);
|
|
3145
|
-
export { ts as default, Y as i, $ as n, X as r, es as t };
|