@esportsplus/ui 0.57.0 → 0.58.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 +123 -39
- package/build/components/accordion/group.d.ts +14 -0
- package/build/components/accordion/group.js +21 -0
- package/build/components/accordion/index.d.ts +9 -0
- package/build/components/accordion/index.js +20 -3
- package/build/components/accordion/scss/index.scss +1 -1
- package/build/components/announcement/scss/index.scss +1 -1
- package/build/components/breadcrumb/scss/index.scss +1 -1
- package/build/components/button/scss/index.scss +1 -1
- package/build/components/button/sidebar.d.ts +3 -0
- package/build/components/button/sidebar.js +40 -10
- package/build/components/capslock/index.js +1 -1
- package/build/components/capslock/scss/index.scss +1 -1
- package/build/components/card/scss/index.scss +1 -1
- package/build/components/cc/scss/index.scss +1 -1
- package/build/components/chat-minimap/scss/index.scss +1 -1
- package/build/components/checkbox/scss/index.scss +1 -1
- package/build/components/color-picker/index.d.ts +1 -0
- package/build/components/color-picker/index.js +166 -136
- package/build/components/color-picker/scss/index.scss +1 -1
- package/build/components/command/index.d.ts +0 -1
- package/build/components/command/index.js +3 -2
- package/build/components/command/scss/index.scss +1 -1
- package/build/components/copy/scss/index.scss +1 -1
- package/build/components/counter/scss/index.scss +1 -1
- package/build/components/datalist/index.js +3 -3
- package/build/components/datalist/scss/index.scss +1 -1
- package/build/components/dock/scss/index.scss +1 -1
- package/build/components/editor/code/index.d.ts +0 -1
- package/build/components/editor/code/index.js +0 -1
- package/build/components/editor/code/minimap.d.ts +2 -1
- package/build/components/editor/code/minimap.js +5 -2
- package/build/components/editor/code/view.d.ts +3 -1
- package/build/components/editor/code/view.js +37 -26
- package/build/components/editor/diffs/index.d.ts +0 -1
- package/build/components/editor/diffs/index.js +0 -1
- package/build/components/editor/diffs/merge.js +7 -3
- package/build/components/editor/diffs/view.js +3 -1
- package/build/components/editor/index.d.ts +4 -1
- package/build/components/editor/index.js +2 -1
- package/build/components/editor/markdown/editing.js +22 -3
- package/build/components/editor/markdown/erase.d.ts +9 -0
- package/build/components/editor/markdown/erase.js +78 -0
- package/build/components/editor/markdown/index.d.ts +0 -1
- package/build/components/editor/markdown/index.js +0 -1
- package/build/components/editor/markdown/layout.d.ts +2 -9
- package/build/components/editor/markdown/layout.js +2 -7
- package/build/components/editor/markdown/render.d.ts +0 -1
- package/build/components/editor/markdown/render.js +287 -235
- package/build/components/editor/markdown/view.js +566 -667
- package/build/components/editor/viewer/index.d.ts +27 -0
- package/build/components/editor/viewer/index.js +250 -0
- package/build/components/editor/viewer/model.d.ts +15 -0
- package/build/components/editor/viewer/model.js +73 -0
- package/build/components/editor/workspace/index.d.ts +6 -2
- package/build/components/editor/workspace/index.js +243 -137
- package/build/components/editor/workspace/keybindings.d.ts +37 -0
- package/build/components/editor/workspace/keybindings.js +288 -0
- package/build/components/editor/workspace/model.d.ts +55 -2
- package/build/components/editor/workspace/model.js +141 -3
- package/build/components/editor/workspace/navigate.d.ts +19 -0
- package/build/components/editor/workspace/navigate.js +118 -0
- package/build/components/editor/workspace/session.d.ts +29 -0
- package/build/components/editor/workspace/session.js +373 -0
- package/build/components/editor/workspace/shortcuts.d.ts +19 -0
- package/build/components/editor/workspace/shortcuts.js +185 -0
- package/build/components/editor/workspace/status.d.ts +34 -0
- package/build/components/editor/workspace/status.js +193 -0
- package/build/components/editor/workspace/statusbar.d.ts +15 -0
- package/build/components/editor/workspace/statusbar.js +190 -0
- package/build/components/editor/workspace/strip.d.ts +27 -0
- package/build/components/editor/workspace/strip.js +239 -0
- package/build/components/editor/workspace/tabs.d.ts +15 -0
- package/build/components/editor/workspace/tabs.js +63 -0
- package/build/components/error/index.js +1 -1
- package/build/components/error/scss/index.scss +1 -1
- package/build/components/filter/index.js +5 -3
- package/build/components/filter/scss/index.scss +1 -1
- package/build/components/frame/scss/index.scss +1 -1
- package/build/components/heatmap/index.js +3 -3
- package/build/components/heatmap/scss/index.scss +1 -1
- package/build/components/highlight/scss/index.scss +1 -1
- package/build/components/icon/scss/index.scss +1 -1
- package/build/components/image/scss/index.scss +1 -1
- package/build/components/index.d.ts +2 -0
- package/build/components/index.js +2 -0
- package/build/components/inline-edit/scss/index.scss +1 -1
- package/build/components/input/scss/index.scss +1 -1
- package/build/components/link/scss/index.scss +1 -1
- package/build/components/loading/scss/index.scss +1 -1
- package/build/components/marquee/scss/index.scss +1 -1
- package/build/components/metric/scss/index.scss +1 -1
- package/build/components/nav/index.d.ts +1 -1
- package/build/components/nav/scss/index.scss +1 -1
- package/build/components/nav/tree.d.ts +3 -1
- package/build/components/nav/tree.js +30 -60
- package/build/components/notification/scss/index.scss +1 -1
- package/build/components/overlay/scss/index.scss +1 -1
- package/build/components/page/scss/index.scss +1 -1
- package/build/components/pagination/arrows.d.ts +15 -0
- package/build/components/pagination/arrows.js +65 -0
- package/build/components/pagination/cards.d.ts +23 -0
- package/build/components/pagination/cards.js +66 -0
- package/build/components/pagination/index.d.ts +5 -0
- package/build/components/pagination/index.js +3 -1
- package/build/components/pagination/scss/index.scss +1 -1
- package/build/components/progress/scss/index.scss +1 -1
- package/build/components/pull-to-refresh/scss/index.scss +1 -1
- package/build/components/range/index.js +1 -1
- package/build/components/range/scss/index.scss +1 -1
- package/build/components/relative-time/scss/index.scss +1 -1
- package/build/components/root/scss/index.scss +1 -1
- package/build/components/section/scss/index.scss +2 -0
- package/build/components/select/index.d.ts +1 -0
- package/build/components/select/index.js +16 -11
- package/build/components/select/scss/index.scss +1 -1
- package/build/components/shortcut-recorder/scss/index.scss +1 -1
- package/build/components/sortable/scss/index.scss +1 -1
- package/build/components/sticky-header/index.js +3 -3
- package/build/components/sticky-header/scss/index.scss +1 -1
- package/build/components/story/scss/index.scss +1 -1
- package/build/components/surface-field/scss/index.scss +1 -1
- package/build/components/tasklist/scss/index.scss +1 -1
- package/build/components/text/scss/index.scss +1 -1
- package/build/components/textarea/scss/index.scss +1 -1
- package/build/{css-utilities → components}/theme/index.d.ts +1 -1
- package/build/{css-utilities → components}/theme/index.js +15 -5
- package/build/components/theme/scss/index.scss +2 -0
- package/build/components/theme-picker/index.d.ts +52 -0
- package/build/components/theme-picker/index.js +167 -0
- package/build/components/theme-picker/scss/index.scss +2 -0
- package/build/components/toast/index.js +3 -5
- package/build/components/toast/scss/index.scss +1 -1
- package/build/components/tooltip/menu.js +3 -1
- package/build/components/tooltip/scss/index.scss +1 -1
- package/build/components/typewriter/scss/index.scss +1 -1
- package/build/components/uptime/scss/index.scss +1 -1
- package/build/components/usage-meter/scss/index.scss +1 -1
- package/build/{css-utilities → modifiers}/glass/index.d.ts +2 -2
- package/build/modifiers/glass/index.js +28 -0
- package/build/modifiers/glass/scss/index.scss +2 -0
- package/build/{css-utilities → modifiers}/index.d.ts +0 -1
- package/build/{css-utilities → modifiers}/index.js +0 -1
- package/build/modifiers/scrollbar/index.d.ts +72 -0
- package/build/{css-utilities → modifiers}/scrollbar/index.js +52 -19
- package/build/modifiers/scrollbar/scss/index.scss +2 -0
- package/build/normalize/scss/index.scss +1 -2
- package/layer.scss +1 -1
- package/package.json +11 -18
- package/scripts/code-editor-markdown.test.mjs +45 -14
- package/scripts/code-viewer.test.mjs +69 -0
- package/scripts/workspace-keybindings.test.mjs +273 -0
- package/scripts/workspace-session.test.mjs +349 -0
- package/scripts/workspace-status.test.mjs +229 -0
- package/scripts/workspace-tabs.test.mjs +142 -0
- package/src/components/accordion/group.ts +39 -0
- package/src/components/accordion/index.ts +32 -6
- package/src/components/accordion/scss/index.scss +12 -21
- package/src/components/accordion/scss/variables.scss +18 -3
- package/src/components/announcement/scss/index.scss +4 -4
- package/src/components/announcement/scss/variables.scss +6 -6
- package/src/components/banner/scss/index.scss +1 -1
- package/src/components/breadcrumb/scss/index.scss +35 -50
- package/src/components/breadcrumb/scss/variables.scss +23 -31
- package/src/components/button/scss/_fan.scss +39 -43
- package/src/components/button/scss/_morph.scss +66 -78
- package/src/components/button/scss/_sidebar.scss +41 -30
- package/src/components/button/scss/_split.scss +9 -9
- package/src/components/button/scss/index.scss +23 -19
- package/src/components/button/scss/variables.scss +94 -90
- package/src/components/button/sidebar.ts +36 -24
- package/src/components/capslock/index.ts +2 -2
- package/src/components/capslock/scss/index.scss +11 -6
- package/src/components/capslock/scss/variables.scss +3 -5
- package/src/components/card/scss/_expand.scss +58 -64
- package/src/components/card/scss/index.scss +40 -21
- package/src/components/card/scss/variables.scss +40 -31
- package/src/components/cc/scss/index.scss +68 -68
- package/src/components/cc/scss/variables.scss +13 -14
- package/src/components/chat-minimap/scss/index.scss +24 -16
- package/src/components/chat-minimap/scss/variables.scss +37 -37
- package/src/components/checkbox/scss/index.scss +54 -52
- package/src/components/checkbox/scss/variables.scss +37 -39
- package/src/components/color-picker/index.ts +157 -120
- package/src/components/color-picker/scss/index.scss +159 -96
- package/src/components/color-picker/scss/variables.scss +33 -15
- package/src/components/command/index.ts +3 -2
- package/src/components/command/scss/index.scss +10 -14
- package/src/components/command/scss/variables.scss +12 -35
- package/src/components/copy/scss/index.scss +6 -6
- package/src/components/copy/scss/variables.scss +12 -15
- package/src/components/counter/scss/index.scss +14 -14
- package/src/components/counter/scss/variables.scss +1 -1
- package/src/components/datalist/index.ts +3 -3
- package/src/components/datalist/scss/index.scss +7 -6
- package/src/components/datalist/scss/variables.scss +7 -3
- package/src/components/dock/scss/index.scss +10 -15
- package/src/components/dock/scss/variables.scss +29 -25
- package/src/components/editor/code/index.ts +0 -1
- package/src/components/editor/code/minimap.ts +13 -5
- package/src/components/editor/code/scss/_editor.scss +83 -81
- package/src/components/editor/code/scss/_features.scss +106 -97
- package/src/components/editor/code/scss/_services.scss +27 -25
- package/src/components/editor/code/scss/index.scss +0 -1
- package/src/components/editor/code/scss/variables.scss +30 -26
- package/src/components/editor/code/view.ts +14 -5
- package/src/components/editor/diffs/index.ts +0 -1
- package/src/components/editor/diffs/merge.ts +2 -1
- package/src/components/editor/diffs/scss/_diffs.scss +67 -57
- package/src/components/editor/diffs/scss/_merge.scss +17 -14
- package/src/components/editor/diffs/scss/index.scss +0 -1
- package/src/components/editor/diffs/scss/variables.scss +25 -18
- package/src/components/editor/diffs/view.ts +2 -1
- package/src/components/editor/index.ts +7 -1
- package/src/components/editor/markdown/editing.ts +38 -3
- package/src/components/editor/markdown/erase.ts +124 -0
- package/src/components/editor/markdown/index.ts +0 -1
- package/src/components/editor/markdown/layout.ts +3 -12
- package/src/components/editor/markdown/render.ts +65 -37
- package/src/components/editor/markdown/scss/index.scss +92 -124
- package/src/components/editor/markdown/scss/variables.scss +39 -19
- package/src/components/editor/markdown/view.ts +737 -786
- package/src/components/editor/tree/scss/index.scss +121 -110
- package/src/components/editor/tree/scss/variables.scss +48 -54
- package/src/components/editor/viewer/index.ts +321 -0
- package/src/components/editor/viewer/model.ts +130 -0
- package/src/components/editor/viewer/scss/_viewer.scss +302 -0
- package/src/components/editor/viewer/scss/index.scss +2 -0
- package/src/components/editor/viewer/scss/variables.scss +69 -0
- package/src/components/editor/workspace/index.ts +159 -31
- package/src/components/editor/workspace/keybindings.ts +447 -0
- package/src/components/editor/workspace/model.ts +233 -3
- package/src/components/editor/workspace/navigate.ts +194 -0
- package/src/components/editor/workspace/scss/index.scss +72 -59
- package/src/components/editor/workspace/scss/keybindings.scss +190 -0
- package/src/components/editor/workspace/scss/status.scss +122 -0
- package/src/components/editor/workspace/scss/tabs.scss +56 -0
- package/src/components/editor/workspace/session.ts +551 -0
- package/src/components/editor/workspace/shortcuts.ts +255 -0
- package/src/components/editor/workspace/status.ts +259 -0
- package/src/components/editor/workspace/statusbar.ts +255 -0
- package/src/components/editor/workspace/strip.ts +273 -0
- package/src/components/editor/workspace/tabs.ts +106 -0
- package/src/components/error/index.ts +1 -1
- package/src/components/error/scss/index.scss +19 -19
- package/src/components/error/scss/variables.scss +2 -2
- package/src/components/filter/index.ts +7 -2
- package/src/components/filter/scss/index.scss +1 -1
- package/src/components/filter/scss/variables.scss +11 -10
- package/src/components/frame/scss/index.scss +12 -12
- package/src/components/frame/scss/variables.scss +8 -8
- package/src/components/heatmap/index.ts +3 -3
- package/src/components/heatmap/scss/index.scss +28 -26
- package/src/components/heatmap/scss/variables.scss +18 -17
- package/src/components/highlight/scss/index.scss +17 -13
- package/src/components/highlight/scss/variables.scss +8 -10
- package/src/components/icon/scss/index.scss +10 -0
- package/src/components/icon/scss/variables.scss +5 -0
- package/src/components/image/scss/index.scss +9 -9
- package/src/components/image/scss/variables.scss +7 -2
- package/src/components/index.ts +2 -0
- package/src/components/inline-edit/scss/index.scss +99 -104
- package/src/components/inline-edit/scss/variables.scss +40 -39
- package/src/components/input/scss/_field.scss +6 -20
- package/src/components/input/scss/_scrub.scss +10 -8
- package/src/components/input/scss/_tag.scss +35 -37
- package/src/components/input/scss/variables.scss +100 -99
- package/src/components/link/scss/index.scss +4 -1
- package/src/components/loading/scss/index.scss +1 -1
- package/src/components/loading/scss/variables.scss +1 -1
- package/src/components/marquee/scss/index.scss +9 -5
- package/src/components/marquee/scss/variables.scss +3 -1
- package/src/components/metric/scss/_flash.scss +3 -1
- package/src/components/metric/scss/index.scss +8 -6
- package/src/components/metric/scss/variables.scss +26 -20
- package/src/components/nav/index.ts +1 -1
- package/src/components/nav/scss/index.scss +12 -40
- package/src/components/nav/scss/variables.scss +30 -11
- package/src/components/nav/tree.ts +19 -62
- package/src/components/notification/scss/index.scss +7 -7
- package/src/components/notification/scss/variables.scss +7 -9
- package/src/components/overlay/scss/index.scss +181 -170
- package/src/components/overlay/scss/variables.scss +26 -57
- package/src/components/page/scss/index.scss +12 -11
- package/src/components/page/scss/variables.scss +5 -0
- package/src/components/pagination/arrows.ts +58 -0
- package/src/components/pagination/cards.ts +57 -0
- package/src/components/pagination/index.ts +4 -1
- package/src/components/pagination/scss/_arrows.scss +69 -0
- package/src/components/pagination/scss/_cards.scss +121 -0
- package/src/components/pagination/scss/_dots.scss +2 -5
- package/src/components/pagination/scss/index.scss +8 -6
- package/src/components/pagination/scss/variables.scss +87 -37
- package/src/components/progress/scss/_text.scss +21 -18
- package/src/components/progress/scss/index.scss +1 -1
- package/src/components/progress/scss/variables.scss +12 -12
- package/src/components/pull-to-refresh/scss/index.scss +2 -1
- package/src/components/pull-to-refresh/scss/variables.scss +11 -6
- package/src/components/range/index.ts +1 -1
- package/src/components/range/scss/_filter.scss +62 -51
- package/src/components/range/scss/_slider.scss +78 -75
- package/src/components/range/scss/_vertical.scss +6 -6
- package/src/components/range/scss/index.scss +3 -2
- package/src/components/range/scss/variables.scss +26 -23
- package/src/components/relative-time/scss/index.scss +27 -27
- package/src/components/relative-time/scss/variables.scss +10 -12
- package/src/components/root/scss/index.scss +71 -43
- package/src/components/root/scss/variables.scss +35 -31
- package/src/components/section/scss/index.scss +31 -0
- package/src/components/section/scss/variables.scss +21 -0
- package/src/components/select/index.ts +11 -6
- package/src/components/select/scss/index.scss +21 -32
- package/src/components/select/scss/variables.scss +25 -18
- package/src/components/shortcut-recorder/scss/index.scss +13 -12
- package/src/components/shortcut-recorder/scss/variables.scss +12 -13
- package/src/components/sortable/scss/index.scss +47 -44
- package/src/components/sortable/scss/variables.scss +4 -5
- package/src/components/sticky-header/index.ts +4 -4
- package/src/components/sticky-header/scss/index.scss +14 -13
- package/src/components/sticky-header/scss/variables.scss +9 -9
- package/src/components/story/scss/index.scss +26 -30
- package/src/components/story/scss/variables.scss +16 -9
- package/src/components/surface-field/scss/index.scss +45 -40
- package/src/components/surface-field/scss/variables.scss +5 -6
- package/src/components/tasklist/scss/index.scss +19 -19
- package/src/components/tasklist/scss/variables.scss +26 -29
- package/src/components/text/scss/index.scss +2 -1
- package/src/components/textarea/scss/variables.scss +1 -1
- package/src/{css-utilities → components}/theme/index.ts +17 -3
- package/src/components/theme/scss/index.scss +1 -0
- package/src/components/theme/scss/variables.scss +78 -0
- package/src/components/theme-picker/index.ts +231 -0
- package/src/components/theme-picker/scss/index.scss +264 -0
- package/src/components/toast/index.ts +28 -30
- package/src/components/toast/scss/index.scss +87 -87
- package/src/components/toast/scss/variables.scss +39 -39
- package/src/components/tooltip/menu.ts +4 -1
- package/src/components/tooltip/scss/_east.scss +10 -10
- package/src/components/tooltip/scss/_menu.scss +284 -269
- package/src/components/tooltip/scss/_north.scss +10 -10
- package/src/components/tooltip/scss/_shared.scss +7 -7
- package/src/components/tooltip/scss/_south.scss +10 -10
- package/src/components/tooltip/scss/_west.scss +10 -10
- package/src/components/tooltip/scss/index.scss +21 -20
- package/src/components/tooltip/scss/variables.scss +104 -96
- package/src/components/typewriter/scss/_retype.scss +12 -11
- package/src/components/typewriter/scss/_rotate.scss +2 -1
- package/src/components/typewriter/scss/variables.scss +41 -39
- package/src/components/uptime/scss/index.scss +15 -15
- package/src/components/uptime/scss/variables.scss +8 -8
- package/src/components/usage-meter/scss/index.scss +3 -1
- package/src/components/usage-meter/scss/variables.scss +5 -5
- package/src/css-utilities/absolute.scss +64 -0
- package/src/css-utilities/background.scss +43 -0
- package/src/css-utilities/border.scss +45 -0
- package/src/css-utilities/box-shadow.scss +29 -0
- package/src/css-utilities/color.scss +41 -0
- package/src/css-utilities/flex.scss +64 -0
- package/src/css-utilities/font/geist/{scss/index.scss → index.scss} +12 -4
- package/src/css-utilities/font/montserrat/Montserrat-Italic-Variable.woff2 +0 -0
- package/src/css-utilities/font/montserrat/Montserrat-Variable.woff2 +0 -0
- package/src/css-utilities/font/montserrat/OFL.txt +93 -0
- package/src/css-utilities/font/montserrat/index.scss +38 -0
- package/src/{shared/scss → css-utilities}/icon.scss +1 -1
- package/src/css-utilities/{inline/scss/index.scss → inline.scss} +1 -1
- package/src/css-utilities/{skeleton/scss/index.scss → skeleton.scss} +11 -11
- package/src/css-utilities/surface.scss +266 -0
- package/src/css-utilities/text.scss +191 -0
- package/src/modifiers/glass/index.ts +44 -0
- package/src/{css-utilities → modifiers}/glass/scss/index.scss +6 -6
- package/src/{css-utilities → modifiers}/glass/scss/variables.scss +1 -1
- package/src/{css-utilities → modifiers}/index.ts +0 -1
- package/src/{css-utilities → modifiers}/scrollbar/index.ts +92 -17
- package/src/{css-utilities → modifiers}/scrollbar/scss/index.scss +178 -177
- package/src/{css-utilities → modifiers}/scrollbar/scss/variables.scss +28 -21
- package/src/normalize/scss/index.scss +4 -2
- package/src/shared/scss/color-weights.scss +19 -0
- package/src/shared/scss/index.scss +1 -12
- package/src/tokens/scss/blur.scss +5 -0
- package/src/tokens/scss/color.scss +74 -50
- package/src/tokens/scss/index.scss +1 -2
- package/src/tokens/scss/size.scss +0 -2
- package/src/tokens/scss/state.scss +3 -2
- package/src/tokens/scss/transition.scss +19 -2
- package/storage/svg/monitor.svg +1 -0
- package/storage/svg/moon.svg +1 -0
- package/storage/svg/pin.svg +1 -0
- package/storage/svg/sun.svg +1 -0
- package/vite.config.ts +33 -8
- package/build/css-utilities/background/scss/index.scss +0 -2
- package/build/css-utilities/border/scss/index.scss +0 -2
- package/build/css-utilities/color/scss/index.scss +0 -2
- package/build/css-utilities/flex/scss/index.scss +0 -2
- package/build/css-utilities/font/geist/index.d.ts +0 -1
- package/build/css-utilities/font/geist/index.js +0 -1
- package/build/css-utilities/font/geist/scss/index.scss +0 -2
- package/build/css-utilities/font/montserrat/index.d.ts +0 -1
- package/build/css-utilities/font/montserrat/index.js +0 -1
- package/build/css-utilities/font/montserrat/scss/Montserrat-Bold.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Bold.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-BoldItalic.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-BoldItalic.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Italic.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Italic.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Medium.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Medium.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-MediumItalic.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-MediumItalic.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Regular.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-Regular.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-SemiBold.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-SemiBold.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-SemiBoldItalic.woff +0 -0
- package/build/css-utilities/font/montserrat/scss/Montserrat-SemiBoldItalic.woff2 +0 -0
- package/build/css-utilities/font/montserrat/scss/index.scss +0 -2
- package/build/css-utilities/glass/index.js +0 -26
- package/build/css-utilities/glass/scss/index.scss +0 -2
- package/build/css-utilities/index.scss +0 -2
- package/build/css-utilities/inline/scss/index.scss +0 -2
- package/build/css-utilities/scrollbar/index.d.ts +0 -42
- package/build/css-utilities/scrollbar/scss/index.scss +0 -2
- package/build/css-utilities/skeleton/scss/index.scss +0 -2
- package/build/css-utilities/text/scss/index.scss +0 -2
- package/build/themes/dark/index.d.ts +0 -3
- package/build/themes/dark/index.js +0 -3
- package/build/themes/dark/input.d.ts +0 -3
- package/build/themes/dark/input.js +0 -12
- package/build/themes/dark/select.d.ts +0 -3
- package/build/themes/dark/select.js +0 -23
- package/build/themes/dark/textarea.d.ts +0 -2186
- package/build/themes/dark/textarea.js +0 -11
- package/src/css-utilities/background/scss/index.scss +0 -1
- package/src/css-utilities/background/scss/variables.scss +0 -18
- package/src/css-utilities/border/scss/index.scss +0 -1
- package/src/css-utilities/border/scss/variables.scss +0 -23
- package/src/css-utilities/color/scss/index.scss +0 -1
- package/src/css-utilities/color/scss/variables.scss +0 -17
- package/src/css-utilities/flex/scss/index.scss +0 -57
- package/src/css-utilities/flex/scss/variables.scss +0 -16
- package/src/css-utilities/font/geist/index.ts +0 -1
- package/src/css-utilities/font/montserrat/index.ts +0 -1
- package/src/css-utilities/font/montserrat/scss/Montserrat-Bold.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Bold.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-BoldItalic.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-BoldItalic.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Italic.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Italic.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Medium.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Medium.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-MediumItalic.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-MediumItalic.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Regular.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-Regular.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-SemiBold.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-SemiBold.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-SemiBoldItalic.woff +0 -0
- package/src/css-utilities/font/montserrat/scss/Montserrat-SemiBoldItalic.woff2 +0 -0
- package/src/css-utilities/font/montserrat/scss/index.scss +0 -94
- package/src/css-utilities/glass/index.ts +0 -42
- package/src/css-utilities/index.scss +0 -13
- package/src/css-utilities/skeleton/scss/variables.scss +0 -3
- package/src/css-utilities/text/scss/index.scss +0 -152
- package/src/css-utilities/text/scss/variables.scss +0 -22
- package/src/shared/scss/absolute.scss +0 -28
- package/src/shared/scss/background.scss +0 -21
- package/src/shared/scss/border.scss +0 -21
- package/src/shared/scss/color.scss +0 -21
- package/src/shared/scss/position.scss +0 -55
- package/src/shared/scss/text.scss +0 -31
- package/src/themes/dark/index.ts +0 -3
- package/src/themes/dark/input.ts +0 -16
- package/src/themes/dark/select.ts +0 -28
- package/src/themes/dark/textarea.ts +0 -13
- package/src/tokens/scss/box-shadow.scss +0 -23
- package/src/tokens/scss/font-family.scss +0 -5
- package/storage/code.md +0 -180
- package/storage/editor-features.md +0 -227
- package/build/css-utilities/font/geist/{scss/Geist-Italic-Variable.woff2 → Geist-Italic-Variable.woff2} +0 -0
- package/build/css-utilities/font/geist/{scss/Geist-Variable.woff2 → Geist-Variable.woff2} +0 -0
- package/build/css-utilities/font/geist/{scss/GeistMono-Italic-Variable.woff2 → GeistMono-Italic-Variable.woff2} +0 -0
- package/build/css-utilities/font/geist/{scss/GeistMono-Variable.woff2 → GeistMono-Variable.woff2} +0 -0
- package/src/{shared/scss → css-utilities}/anchor.scss +6 -6
- package/src/{shared/scss → css-utilities}/drag.scss +0 -0
- package/src/css-utilities/font/geist/{scss/Geist-Italic-Variable.woff2 → Geist-Italic-Variable.woff2} +0 -0
- package/src/css-utilities/font/geist/{scss/Geist-Variable.woff2 → Geist-Variable.woff2} +0 -0
- package/src/css-utilities/font/geist/{scss/GeistMono-Italic-Variable.woff2 → GeistMono-Italic-Variable.woff2} +0 -0
- package/src/css-utilities/font/geist/{scss/GeistMono-Variable.woff2 → GeistMono-Variable.woff2} +0 -0
- package/src/{shared/scss → css-utilities}/hidden.scss +11 -11
- /package/src/{shared/scss → css-utilities}/layer.scss +0 -0
- /package/src/{shared/scss → css-utilities}/reset.scss +0 -0
|
@@ -6,45 +6,63 @@ import icon from '../../icon/index.js';
|
|
|
6
6
|
import { sanitizeHtml } from './html.js';
|
|
7
7
|
import { clipInline } from './inline.js';
|
|
8
8
|
import chevron from '@esportsplus/ui/svg/chevron-down.svg';
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
const
|
|
22
|
-
const
|
|
23
|
-
const
|
|
24
|
-
const
|
|
25
|
-
const
|
|
26
|
-
const
|
|
27
|
-
const template_1szz54a1o = template_u1.template(`<
|
|
28
|
-
const template_1szz54a1r = template_u1.template(`<
|
|
29
|
-
const
|
|
30
|
-
const
|
|
31
|
-
const
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
const
|
|
35
|
-
const
|
|
36
|
-
const
|
|
37
|
-
const
|
|
38
|
-
const
|
|
39
|
-
const
|
|
40
|
-
const
|
|
41
|
-
const
|
|
42
|
-
const
|
|
43
|
-
const
|
|
44
|
-
const template_1szz54a38 = template_u1.template(`<
|
|
45
|
-
const template_1szz54a3b = template_u1.template(`<
|
|
46
|
-
const template_1szz54a3e = template_u1.template(`<
|
|
9
|
+
const template_1szz54a3 = template_u1.template(`<button aria-label='Unfold block' class='markdown-editor-chip' contenteditable='false' type='button'> … <!--$--> lines `);
|
|
10
|
+
const template_1szz54a6 = template_u1.template(`<br>`);
|
|
11
|
+
const template_1szz54a8 = template_u1.template(`<pre class='markdown-editor-pre'><code class='markdown-editor-code markdown-editor-code--block'>`);
|
|
12
|
+
const template_1szz54ab = template_u1.template(`<pre class='markdown-editor-pre'><!--$--><code class='markdown-editor-code markdown-editor-code--block'>`);
|
|
13
|
+
const template_1szz54af = template_u1.template(`<pre class='markdown-editor-pre markdown-editor-frontmatter'><code class='markdown-editor-code markdown-editor-code--block'>`);
|
|
14
|
+
const template_1szz54ai = template_u1.template(`<div contenteditable='false'>`);
|
|
15
|
+
const template_1szz54al = template_u1.template(`<span class='markdown-editor-marker' contenteditable='false'>`);
|
|
16
|
+
const template_1szz54an = template_u1.template(`<hr class='markdown-editor-rule' contenteditable='false'>`);
|
|
17
|
+
const template_1szz54ap = template_u1.template(`<code class='markdown-editor-code'>`);
|
|
18
|
+
const template_1szz54as = template_u1.template(`<em class='markdown-editor-em'>`);
|
|
19
|
+
const template_1szz54av = template_u1.template(`<a class='markdown-editor-link' rel='noopener noreferrer'>`);
|
|
20
|
+
const template_1szz54ay = template_u1.template(`<span class='markdown-editor-link'>`);
|
|
21
|
+
const template_1szz54a11 = template_u1.template(`<s class='markdown-editor-strike'>`);
|
|
22
|
+
const template_1szz54a14 = template_u1.template(`<strong class='markdown-editor-strong'>`);
|
|
23
|
+
const template_1szz54a17 = template_u1.template(`<span class='markdown-editor-info'>`);
|
|
24
|
+
const template_1szz54a1a = template_u1.template(`<span class='markdown-editor-label'>`);
|
|
25
|
+
const template_1szz54a1d = template_u1.template(`<div class='markdown-editor-block '><button class='markdown-editor-fold' contenteditable='false' tabindex='-1' type='button'>`);
|
|
26
|
+
const template_1szz54a1j = template_u1.template(`<blockquote class='markdown-editor-quote'>`);
|
|
27
|
+
const template_1szz54a1o = template_u1.template(`<details>`);
|
|
28
|
+
const template_1szz54a1r = template_u1.template(`<div>`);
|
|
29
|
+
const template_1szz54a1w = template_u1.template(`<h1 class='markdown-editor-heading markdown-editor-heading--h1'>`);
|
|
30
|
+
const template_1szz54a1z = template_u1.template(`<h2 class='markdown-editor-heading markdown-editor-heading--h2'>`);
|
|
31
|
+
const template_1szz54a22 = template_u1.template(`<h3 class='markdown-editor-heading markdown-editor-heading--h3'>`);
|
|
32
|
+
const template_1szz54a25 = template_u1.template(`<h4 class='markdown-editor-heading markdown-editor-heading--h4'>`);
|
|
33
|
+
const template_1szz54a28 = template_u1.template(`<h5 class='markdown-editor-heading markdown-editor-heading--h5'>`);
|
|
34
|
+
const template_1szz54a2b = template_u1.template(`<h6 class='markdown-editor-heading markdown-editor-heading--h6'>`);
|
|
35
|
+
const template_1szz54a2d = template_u1.template(`<hr class='markdown-editor-rule'>`);
|
|
36
|
+
const template_1szz54a2f = template_u1.template(`<img class='markdown-editor-image' loading='lazy'>`);
|
|
37
|
+
const template_1szz54a2i = template_u1.template(`<li>`);
|
|
38
|
+
const template_1szz54a2l = template_u1.template(`<ol class='markdown-editor-list'>`);
|
|
39
|
+
const template_1szz54a2o = template_u1.template(`<p class='markdown-editor-paragraph'>`);
|
|
40
|
+
const template_1szz54a2r = template_u1.template(`<pre class='markdown-editor-pre'>`);
|
|
41
|
+
const template_1szz54a2w = template_u1.template(`<span>`);
|
|
42
|
+
const template_1szz54a31 = template_u1.template(`<sub>`);
|
|
43
|
+
const template_1szz54a34 = template_u1.template(`<summary class='markdown-editor-summary'><!--$-->`);
|
|
44
|
+
const template_1szz54a38 = template_u1.template(`<sup>`);
|
|
45
|
+
const template_1szz54a3b = template_u1.template(`<table class='markdown-editor-table'>`);
|
|
46
|
+
const template_1szz54a3e = template_u1.template(`<tbody>`);
|
|
47
|
+
const template_1szz54a3h = template_u1.template(`<td class='markdown-editor-cell'>`);
|
|
48
|
+
const template_1szz54a3k = template_u1.template(`<th class='markdown-editor-cell markdown-editor-cell--head'>`);
|
|
49
|
+
const template_1szz54a3n = template_u1.template(`<thead>`);
|
|
50
|
+
const template_1szz54a3q = template_u1.template(`<tr>`);
|
|
51
|
+
const template_1szz54a3t = template_u1.template(`<ul class='markdown-editor-list'>`);
|
|
47
52
|
class ReactiveObject_1szz54a0 extends reactivity_u0.ReactiveObject {
|
|
53
|
+
#done;
|
|
54
|
+
constructor(_p0) {
|
|
55
|
+
super(null);
|
|
56
|
+
this.#done = this[reactivity_u0.SIGNAL](_p0);
|
|
57
|
+
}
|
|
58
|
+
get done() {
|
|
59
|
+
return reactivity_u0.read(this.#done);
|
|
60
|
+
}
|
|
61
|
+
set done(_v0) {
|
|
62
|
+
reactivity_u0.write(this.#done, _v0);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
class ReactiveObject_1szz54a1 extends reactivity_u0.ReactiveObject {
|
|
48
66
|
#foldable;
|
|
49
67
|
constructor(_p0) {
|
|
50
68
|
super(null);
|
|
@@ -57,7 +75,8 @@ class ReactiveObject_1szz54a0 extends reactivity_u0.ReactiveObject {
|
|
|
57
75
|
reactivity_u0.write(this.#foldable, _v0);
|
|
58
76
|
}
|
|
59
77
|
}
|
|
60
|
-
const
|
|
78
|
+
const CARRIAGE_RETURN = /\r$/;
|
|
79
|
+
const FENCE_OPEN = /^[ \t>]*(?:`{3,}|~{3,})/;
|
|
61
80
|
const ORDERED = /^\d/;
|
|
62
81
|
let parser;
|
|
63
82
|
function lines(text, from, to, base) {
|
|
@@ -90,249 +109,249 @@ function safe(nodes) {
|
|
|
90
109
|
switch (node.tag) {
|
|
91
110
|
case 'a':
|
|
92
111
|
out.push((() => {
|
|
93
|
-
let
|
|
94
|
-
template_u1.slot(
|
|
95
|
-
template_u1.setProperties(
|
|
96
|
-
return
|
|
112
|
+
let root_1szz54a1g = template_1szz54av(), element_1szz54a1h = root_1szz54a1g.firstChild;
|
|
113
|
+
template_u1.slot(element_1szz54a1h, content, 1);
|
|
114
|
+
template_u1.setProperties(element_1szz54a1h, attributes);
|
|
115
|
+
return root_1szz54a1g;
|
|
97
116
|
})());
|
|
98
117
|
break;
|
|
99
118
|
case 'blockquote':
|
|
100
119
|
out.push((() => {
|
|
101
|
-
let
|
|
102
|
-
template_u1.slot(
|
|
103
|
-
template_u1.setProperties(
|
|
104
|
-
return
|
|
120
|
+
let root_1szz54a1i = template_1szz54a1j(), element_1szz54a1k = root_1szz54a1i.firstChild;
|
|
121
|
+
template_u1.slot(element_1szz54a1k, content, 1);
|
|
122
|
+
template_u1.setProperties(element_1szz54a1k, attributes);
|
|
123
|
+
return root_1szz54a1i;
|
|
105
124
|
})());
|
|
106
125
|
break;
|
|
107
126
|
case 'br':
|
|
108
|
-
out.push(
|
|
127
|
+
out.push(template_1szz54a6());
|
|
109
128
|
break;
|
|
110
129
|
case 'code':
|
|
111
130
|
out.push((() => {
|
|
112
|
-
let
|
|
113
|
-
template_u1.slot(
|
|
114
|
-
template_u1.setProperties(
|
|
115
|
-
return
|
|
131
|
+
let root_1szz54a1l = template_1szz54ap(), element_1szz54a1m = root_1szz54a1l.firstChild;
|
|
132
|
+
template_u1.slot(element_1szz54a1m, content, 1);
|
|
133
|
+
template_u1.setProperties(element_1szz54a1m, attributes);
|
|
134
|
+
return root_1szz54a1l;
|
|
116
135
|
})());
|
|
117
136
|
break;
|
|
118
137
|
case 'details':
|
|
119
138
|
out.push((() => {
|
|
120
|
-
let
|
|
121
|
-
template_u1.slot(
|
|
122
|
-
template_u1.setProperties(
|
|
123
|
-
return
|
|
139
|
+
let root_1szz54a1n = template_1szz54a1o(), element_1szz54a1p = root_1szz54a1n.firstChild;
|
|
140
|
+
template_u1.slot(element_1szz54a1p, content, 1);
|
|
141
|
+
template_u1.setProperties(element_1szz54a1p, attributes);
|
|
142
|
+
return root_1szz54a1n;
|
|
124
143
|
})());
|
|
125
144
|
break;
|
|
126
145
|
case 'div':
|
|
127
146
|
out.push((() => {
|
|
128
|
-
let
|
|
129
|
-
template_u1.slot(
|
|
130
|
-
template_u1.setProperties(
|
|
131
|
-
return
|
|
147
|
+
let root_1szz54a1q = template_1szz54a1r(), element_1szz54a1s = root_1szz54a1q.firstChild;
|
|
148
|
+
template_u1.slot(element_1szz54a1s, content, 1);
|
|
149
|
+
template_u1.setProperties(element_1szz54a1s, attributes);
|
|
150
|
+
return root_1szz54a1q;
|
|
132
151
|
})());
|
|
133
152
|
break;
|
|
134
153
|
case 'em':
|
|
135
154
|
out.push((() => {
|
|
136
|
-
let
|
|
137
|
-
template_u1.slot(
|
|
138
|
-
template_u1.setProperties(
|
|
139
|
-
return
|
|
155
|
+
let root_1szz54a1t = template_1szz54as(), element_1szz54a1u = root_1szz54a1t.firstChild;
|
|
156
|
+
template_u1.slot(element_1szz54a1u, content, 1);
|
|
157
|
+
template_u1.setProperties(element_1szz54a1u, attributes);
|
|
158
|
+
return root_1szz54a1t;
|
|
140
159
|
})());
|
|
141
160
|
break;
|
|
142
161
|
case 'h1':
|
|
143
162
|
out.push((() => {
|
|
144
|
-
let
|
|
145
|
-
template_u1.slot(
|
|
146
|
-
template_u1.setProperties(
|
|
147
|
-
return
|
|
163
|
+
let root_1szz54a1v = template_1szz54a1w(), element_1szz54a1x = root_1szz54a1v.firstChild;
|
|
164
|
+
template_u1.slot(element_1szz54a1x, content, 1);
|
|
165
|
+
template_u1.setProperties(element_1szz54a1x, attributes);
|
|
166
|
+
return root_1szz54a1v;
|
|
148
167
|
})());
|
|
149
168
|
break;
|
|
150
169
|
case 'h2':
|
|
151
170
|
out.push((() => {
|
|
152
|
-
let
|
|
153
|
-
template_u1.slot(
|
|
154
|
-
template_u1.setProperties(
|
|
155
|
-
return
|
|
171
|
+
let root_1szz54a1y = template_1szz54a1z(), element_1szz54a20 = root_1szz54a1y.firstChild;
|
|
172
|
+
template_u1.slot(element_1szz54a20, content, 1);
|
|
173
|
+
template_u1.setProperties(element_1szz54a20, attributes);
|
|
174
|
+
return root_1szz54a1y;
|
|
156
175
|
})());
|
|
157
176
|
break;
|
|
158
177
|
case 'h3':
|
|
159
178
|
out.push((() => {
|
|
160
|
-
let
|
|
161
|
-
template_u1.slot(
|
|
162
|
-
template_u1.setProperties(
|
|
163
|
-
return
|
|
179
|
+
let root_1szz54a21 = template_1szz54a22(), element_1szz54a23 = root_1szz54a21.firstChild;
|
|
180
|
+
template_u1.slot(element_1szz54a23, content, 1);
|
|
181
|
+
template_u1.setProperties(element_1szz54a23, attributes);
|
|
182
|
+
return root_1szz54a21;
|
|
164
183
|
})());
|
|
165
184
|
break;
|
|
166
185
|
case 'h4':
|
|
167
186
|
out.push((() => {
|
|
168
|
-
let
|
|
169
|
-
template_u1.slot(
|
|
170
|
-
template_u1.setProperties(
|
|
171
|
-
return
|
|
187
|
+
let root_1szz54a24 = template_1szz54a25(), element_1szz54a26 = root_1szz54a24.firstChild;
|
|
188
|
+
template_u1.slot(element_1szz54a26, content, 1);
|
|
189
|
+
template_u1.setProperties(element_1szz54a26, attributes);
|
|
190
|
+
return root_1szz54a24;
|
|
172
191
|
})());
|
|
173
192
|
break;
|
|
174
193
|
case 'h5':
|
|
175
194
|
out.push((() => {
|
|
176
|
-
let
|
|
177
|
-
template_u1.slot(
|
|
178
|
-
template_u1.setProperties(
|
|
179
|
-
return
|
|
195
|
+
let root_1szz54a27 = template_1szz54a28(), element_1szz54a29 = root_1szz54a27.firstChild;
|
|
196
|
+
template_u1.slot(element_1szz54a29, content, 1);
|
|
197
|
+
template_u1.setProperties(element_1szz54a29, attributes);
|
|
198
|
+
return root_1szz54a27;
|
|
180
199
|
})());
|
|
181
200
|
break;
|
|
182
201
|
case 'h6':
|
|
183
202
|
out.push((() => {
|
|
184
|
-
let
|
|
185
|
-
template_u1.slot(
|
|
186
|
-
template_u1.setProperties(
|
|
187
|
-
return
|
|
203
|
+
let root_1szz54a2a = template_1szz54a2b(), element_1szz54a2c = root_1szz54a2a.firstChild;
|
|
204
|
+
template_u1.slot(element_1szz54a2c, content, 1);
|
|
205
|
+
template_u1.setProperties(element_1szz54a2c, attributes);
|
|
206
|
+
return root_1szz54a2a;
|
|
188
207
|
})());
|
|
189
208
|
break;
|
|
190
209
|
case 'hr':
|
|
191
|
-
out.push(
|
|
210
|
+
out.push(template_1szz54a2d());
|
|
192
211
|
break;
|
|
193
212
|
case 'img':
|
|
194
213
|
out.push((() => {
|
|
195
|
-
let
|
|
196
|
-
template_u1.setProperties(
|
|
197
|
-
return
|
|
214
|
+
let root_1szz54a2e = template_1szz54a2f(), element_1szz54a2g = root_1szz54a2e.firstChild;
|
|
215
|
+
template_u1.setProperties(element_1szz54a2g, attributes);
|
|
216
|
+
return root_1szz54a2e;
|
|
198
217
|
})());
|
|
199
218
|
break;
|
|
200
219
|
case 'li':
|
|
201
220
|
out.push((() => {
|
|
202
|
-
let
|
|
203
|
-
template_u1.slot(
|
|
204
|
-
template_u1.setProperties(
|
|
205
|
-
return
|
|
221
|
+
let root_1szz54a2h = template_1szz54a2i(), element_1szz54a2j = root_1szz54a2h.firstChild;
|
|
222
|
+
template_u1.slot(element_1szz54a2j, content, 1);
|
|
223
|
+
template_u1.setProperties(element_1szz54a2j, attributes);
|
|
224
|
+
return root_1szz54a2h;
|
|
206
225
|
})());
|
|
207
226
|
break;
|
|
208
227
|
case 'ol':
|
|
209
228
|
out.push((() => {
|
|
210
|
-
let
|
|
211
|
-
template_u1.slot(
|
|
212
|
-
template_u1.setProperties(
|
|
213
|
-
return
|
|
229
|
+
let root_1szz54a2k = template_1szz54a2l(), element_1szz54a2m = root_1szz54a2k.firstChild;
|
|
230
|
+
template_u1.slot(element_1szz54a2m, content, 1);
|
|
231
|
+
template_u1.setProperties(element_1szz54a2m, attributes);
|
|
232
|
+
return root_1szz54a2k;
|
|
214
233
|
})());
|
|
215
234
|
break;
|
|
216
235
|
case 'p':
|
|
217
236
|
out.push((() => {
|
|
218
|
-
let
|
|
219
|
-
template_u1.slot(
|
|
220
|
-
template_u1.setProperties(
|
|
221
|
-
return
|
|
237
|
+
let root_1szz54a2n = template_1szz54a2o(), element_1szz54a2p = root_1szz54a2n.firstChild;
|
|
238
|
+
template_u1.slot(element_1szz54a2p, content, 1);
|
|
239
|
+
template_u1.setProperties(element_1szz54a2p, attributes);
|
|
240
|
+
return root_1szz54a2n;
|
|
222
241
|
})());
|
|
223
242
|
break;
|
|
224
243
|
case 'pre':
|
|
225
244
|
out.push((() => {
|
|
226
|
-
let
|
|
227
|
-
template_u1.slot(
|
|
228
|
-
template_u1.setProperties(
|
|
229
|
-
return
|
|
245
|
+
let root_1szz54a2q = template_1szz54a2r(), element_1szz54a2s = root_1szz54a2q.firstChild;
|
|
246
|
+
template_u1.slot(element_1szz54a2s, content, 1);
|
|
247
|
+
template_u1.setProperties(element_1szz54a2s, attributes);
|
|
248
|
+
return root_1szz54a2q;
|
|
230
249
|
})());
|
|
231
250
|
break;
|
|
232
251
|
case 's':
|
|
233
252
|
out.push((() => {
|
|
234
|
-
let
|
|
235
|
-
template_u1.slot(
|
|
236
|
-
template_u1.setProperties(
|
|
237
|
-
return
|
|
253
|
+
let root_1szz54a2t = template_1szz54a11(), element_1szz54a2u = root_1szz54a2t.firstChild;
|
|
254
|
+
template_u1.slot(element_1szz54a2u, content, 1);
|
|
255
|
+
template_u1.setProperties(element_1szz54a2u, attributes);
|
|
256
|
+
return root_1szz54a2t;
|
|
238
257
|
})());
|
|
239
258
|
break;
|
|
240
259
|
case 'span':
|
|
241
260
|
out.push((() => {
|
|
242
|
-
let
|
|
243
|
-
template_u1.slot(
|
|
244
|
-
template_u1.setProperties(
|
|
245
|
-
return
|
|
261
|
+
let root_1szz54a2v = template_1szz54a2w(), element_1szz54a2x = root_1szz54a2v.firstChild;
|
|
262
|
+
template_u1.slot(element_1szz54a2x, content, 1);
|
|
263
|
+
template_u1.setProperties(element_1szz54a2x, attributes);
|
|
264
|
+
return root_1szz54a2v;
|
|
246
265
|
})());
|
|
247
266
|
break;
|
|
248
267
|
case 'strong':
|
|
249
268
|
out.push((() => {
|
|
250
|
-
let
|
|
251
|
-
template_u1.slot(
|
|
252
|
-
template_u1.setProperties(
|
|
253
|
-
return
|
|
269
|
+
let root_1szz54a2y = template_1szz54a14(), element_1szz54a2z = root_1szz54a2y.firstChild;
|
|
270
|
+
template_u1.slot(element_1szz54a2z, content, 1);
|
|
271
|
+
template_u1.setProperties(element_1szz54a2z, attributes);
|
|
272
|
+
return root_1szz54a2y;
|
|
254
273
|
})());
|
|
255
274
|
break;
|
|
256
275
|
case 'sub':
|
|
257
276
|
out.push((() => {
|
|
258
|
-
let
|
|
259
|
-
template_u1.slot(
|
|
260
|
-
template_u1.setProperties(
|
|
261
|
-
return
|
|
277
|
+
let root_1szz54a30 = template_1szz54a31(), element_1szz54a32 = root_1szz54a30.firstChild;
|
|
278
|
+
template_u1.slot(element_1szz54a32, content, 1);
|
|
279
|
+
template_u1.setProperties(element_1szz54a32, attributes);
|
|
280
|
+
return root_1szz54a30;
|
|
262
281
|
})());
|
|
263
282
|
break;
|
|
264
283
|
case 'summary':
|
|
265
284
|
out.push((() => {
|
|
266
|
-
let
|
|
267
|
-
template_u1.slot(
|
|
268
|
-
template_u1.slot(
|
|
269
|
-
template_u1.setProperties(
|
|
270
|
-
template_u1.delegate(
|
|
271
|
-
return
|
|
285
|
+
let root_1szz54a33 = template_1szz54a34(), element_1szz54a35 = root_1szz54a33.firstChild, element_1szz54a36 = element_1szz54a35.firstChild;
|
|
286
|
+
template_u1.slot(element_1szz54a36, icon({ 'aria-hidden': 'true', class: 'markdown-editor-summary-icon' }, chevron));
|
|
287
|
+
template_u1.slot(element_1szz54a35, content, 2);
|
|
288
|
+
template_u1.setProperties(element_1szz54a35, attributes);
|
|
289
|
+
template_u1.delegate(element_1szz54a35, 'mousedown', prevent);
|
|
290
|
+
return root_1szz54a33;
|
|
272
291
|
})());
|
|
273
292
|
break;
|
|
274
293
|
case 'sup':
|
|
275
294
|
out.push((() => {
|
|
276
|
-
let
|
|
277
|
-
template_u1.slot(
|
|
278
|
-
template_u1.setProperties(
|
|
279
|
-
return
|
|
295
|
+
let root_1szz54a37 = template_1szz54a38(), element_1szz54a39 = root_1szz54a37.firstChild;
|
|
296
|
+
template_u1.slot(element_1szz54a39, content, 1);
|
|
297
|
+
template_u1.setProperties(element_1szz54a39, attributes);
|
|
298
|
+
return root_1szz54a37;
|
|
280
299
|
})());
|
|
281
300
|
break;
|
|
282
301
|
case 'table':
|
|
283
302
|
out.push((() => {
|
|
284
|
-
let
|
|
285
|
-
template_u1.slot(
|
|
286
|
-
template_u1.setProperties(
|
|
287
|
-
return
|
|
303
|
+
let root_1szz54a3a = template_1szz54a3b(), element_1szz54a3c = root_1szz54a3a.firstChild;
|
|
304
|
+
template_u1.slot(element_1szz54a3c, content, 1);
|
|
305
|
+
template_u1.setProperties(element_1szz54a3c, attributes);
|
|
306
|
+
return root_1szz54a3a;
|
|
288
307
|
})());
|
|
289
308
|
break;
|
|
290
309
|
case 'tbody':
|
|
291
310
|
out.push((() => {
|
|
292
|
-
let
|
|
293
|
-
template_u1.slot(
|
|
294
|
-
template_u1.setProperties(
|
|
295
|
-
return
|
|
311
|
+
let root_1szz54a3d = template_1szz54a3e(), element_1szz54a3f = root_1szz54a3d.firstChild;
|
|
312
|
+
template_u1.slot(element_1szz54a3f, content, 1);
|
|
313
|
+
template_u1.setProperties(element_1szz54a3f, attributes);
|
|
314
|
+
return root_1szz54a3d;
|
|
296
315
|
})());
|
|
297
316
|
break;
|
|
298
317
|
case 'td':
|
|
299
318
|
out.push((() => {
|
|
300
|
-
let
|
|
301
|
-
template_u1.slot(
|
|
302
|
-
template_u1.setProperties(
|
|
303
|
-
return
|
|
319
|
+
let root_1szz54a3g = template_1szz54a3h(), element_1szz54a3i = root_1szz54a3g.firstChild;
|
|
320
|
+
template_u1.slot(element_1szz54a3i, content, 1);
|
|
321
|
+
template_u1.setProperties(element_1szz54a3i, attributes);
|
|
322
|
+
return root_1szz54a3g;
|
|
304
323
|
})());
|
|
305
324
|
break;
|
|
306
325
|
case 'th':
|
|
307
326
|
out.push((() => {
|
|
308
|
-
let
|
|
309
|
-
template_u1.slot(
|
|
310
|
-
template_u1.setProperties(
|
|
311
|
-
return
|
|
327
|
+
let root_1szz54a3j = template_1szz54a3k(), element_1szz54a3l = root_1szz54a3j.firstChild;
|
|
328
|
+
template_u1.slot(element_1szz54a3l, content, 1);
|
|
329
|
+
template_u1.setProperties(element_1szz54a3l, attributes);
|
|
330
|
+
return root_1szz54a3j;
|
|
312
331
|
})());
|
|
313
332
|
break;
|
|
314
333
|
case 'thead':
|
|
315
334
|
out.push((() => {
|
|
316
|
-
let
|
|
317
|
-
template_u1.slot(
|
|
318
|
-
template_u1.setProperties(
|
|
319
|
-
return
|
|
335
|
+
let root_1szz54a3m = template_1szz54a3n(), element_1szz54a3o = root_1szz54a3m.firstChild;
|
|
336
|
+
template_u1.slot(element_1szz54a3o, content, 1);
|
|
337
|
+
template_u1.setProperties(element_1szz54a3o, attributes);
|
|
338
|
+
return root_1szz54a3m;
|
|
320
339
|
})());
|
|
321
340
|
break;
|
|
322
341
|
case 'tr':
|
|
323
342
|
out.push((() => {
|
|
324
|
-
let
|
|
325
|
-
template_u1.slot(
|
|
326
|
-
template_u1.setProperties(
|
|
327
|
-
return
|
|
343
|
+
let root_1szz54a3p = template_1szz54a3q(), element_1szz54a3r = root_1szz54a3p.firstChild;
|
|
344
|
+
template_u1.slot(element_1szz54a3r, content, 1);
|
|
345
|
+
template_u1.setProperties(element_1szz54a3r, attributes);
|
|
346
|
+
return root_1szz54a3p;
|
|
328
347
|
})());
|
|
329
348
|
break;
|
|
330
349
|
case 'ul':
|
|
331
350
|
out.push((() => {
|
|
332
|
-
let
|
|
333
|
-
template_u1.slot(
|
|
334
|
-
template_u1.setProperties(
|
|
335
|
-
return
|
|
351
|
+
let root_1szz54a3s = template_1szz54a3t(), element_1szz54a3u = root_1szz54a3s.firstChild;
|
|
352
|
+
template_u1.slot(element_1szz54a3u, content, 1);
|
|
353
|
+
template_u1.setProperties(element_1szz54a3u, attributes);
|
|
354
|
+
return root_1szz54a3s;
|
|
336
355
|
})());
|
|
337
356
|
break;
|
|
338
357
|
}
|
|
@@ -348,50 +367,62 @@ const renderer = (host) => {
|
|
|
348
367
|
}
|
|
349
368
|
if (unit.fold) {
|
|
350
369
|
let first = lines(source, block.from, block.contentTo, block.from).slice(0, 1), chip = (() => {
|
|
351
|
-
let
|
|
352
|
-
template_u1.slot(
|
|
353
|
-
template_u1.delegate(
|
|
354
|
-
template_u1.delegate(
|
|
355
|
-
return
|
|
370
|
+
let root_1szz54a2 = template_1szz54a3(), element_1szz54a4 = root_1szz54a2.firstChild, element_1szz54a5 = element_1szz54a4.firstChild.nextSibling;
|
|
371
|
+
template_u1.slot(element_1szz54a5, unit.fold.endLine - unit.fold.line);
|
|
372
|
+
template_u1.delegate(element_1szz54a4, 'click', () => host.unfold(unit));
|
|
373
|
+
template_u1.delegate(element_1szz54a4, 'mousedown', prevent);
|
|
374
|
+
return root_1szz54a2;
|
|
356
375
|
})();
|
|
357
376
|
return [block.kind === 'heading' ? marked(block, undefined, view) : plain(block, first, view), chip];
|
|
358
377
|
}
|
|
359
378
|
switch (block.kind) {
|
|
360
379
|
case 'blank':
|
|
361
|
-
return
|
|
380
|
+
return template_1szz54a6();
|
|
362
381
|
case 'code':
|
|
382
|
+
return (() => {
|
|
383
|
+
let root_1szz54a7 = template_1szz54a8(), element_1szz54a9 = root_1szz54a7.firstChild.firstElementChild;
|
|
384
|
+
template_u1.slot(element_1szz54a9, plain(block, unit.rows ?? relative(block), view, true), 1);
|
|
385
|
+
return root_1szz54a7;
|
|
386
|
+
})();
|
|
363
387
|
case 'fence':
|
|
364
388
|
return (() => {
|
|
365
|
-
let
|
|
366
|
-
template_u1.slot(
|
|
367
|
-
|
|
389
|
+
let root_1szz54aa = template_1szz54ab(), element_1szz54ac = root_1szz54aa.firstChild.firstChild, element_1szz54ad = root_1szz54aa.firstChild.firstElementChild;
|
|
390
|
+
template_u1.slot(element_1szz54ac, unit.continuation ? '' : info(block, view));
|
|
391
|
+
template_u1.slot(element_1szz54ad, plain(block, unit.rows ?? relative(block), view, true), 1);
|
|
392
|
+
return root_1szz54aa;
|
|
368
393
|
})();
|
|
369
394
|
case 'frontmatter':
|
|
370
395
|
return (() => {
|
|
371
|
-
let
|
|
372
|
-
template_u1.slot(
|
|
373
|
-
return
|
|
396
|
+
let root_1szz54ae = template_1szz54af(), element_1szz54ag = root_1szz54ae.firstChild.firstElementChild;
|
|
397
|
+
template_u1.slot(element_1szz54ag, plain(block, lines(source, block.contentFrom, block.contentTo, block.from), view, true), 1);
|
|
398
|
+
return root_1szz54ae;
|
|
374
399
|
})();
|
|
375
400
|
case 'html':
|
|
376
401
|
parser ??= new DOMParser();
|
|
377
|
-
return
|
|
402
|
+
return (() => {
|
|
403
|
+
let root_1szz54ah = template_1szz54ai(), element_1szz54aj = root_1szz54ah.firstChild;
|
|
404
|
+
template_u1.slot(element_1szz54aj, safe(sanitizeHtml(source.slice(block.contentFrom, block.contentTo), parser)), 1);
|
|
405
|
+
return root_1szz54ah;
|
|
406
|
+
})();
|
|
378
407
|
case 'list': {
|
|
379
408
|
let content = marked(block, unit.rows ?? block.lines?.map((row) => relativeRow(block, row)), view);
|
|
380
409
|
if (unit.continuation) {
|
|
381
410
|
return content;
|
|
382
411
|
}
|
|
412
|
+
if (block.task) {
|
|
413
|
+
return task(block, block.task.checked, content);
|
|
414
|
+
}
|
|
383
415
|
return [
|
|
384
416
|
(() => {
|
|
385
|
-
let
|
|
386
|
-
template_u1.slot(
|
|
387
|
-
return
|
|
417
|
+
let root_1szz54ak = template_1szz54al(), element_1szz54am = root_1szz54ak.firstChild;
|
|
418
|
+
template_u1.slot(element_1szz54am, ORDERED.test(block.marker ?? '') ? block.marker : '•', 1);
|
|
419
|
+
return root_1szz54ak;
|
|
388
420
|
})(),
|
|
389
|
-
block.task ? task(block, block.task.checked) : '',
|
|
390
421
|
content
|
|
391
422
|
];
|
|
392
423
|
}
|
|
393
424
|
case 'rule':
|
|
394
|
-
return
|
|
425
|
+
return template_1szz54an();
|
|
395
426
|
default:
|
|
396
427
|
return marked(block, unit.rows ?? block.lines?.map((row) => relativeRow(block, row)), view);
|
|
397
428
|
}
|
|
@@ -403,44 +434,44 @@ const renderer = (host) => {
|
|
|
403
434
|
switch (token.kind) {
|
|
404
435
|
case 'code':
|
|
405
436
|
out.push((() => {
|
|
406
|
-
let
|
|
407
|
-
template_u1.slot(
|
|
408
|
-
return
|
|
437
|
+
let root_1szz54ao = template_1szz54ap(), element_1szz54aq = root_1szz54ao.firstChild;
|
|
438
|
+
template_u1.slot(element_1szz54aq, content, 1);
|
|
439
|
+
return root_1szz54ao;
|
|
409
440
|
})());
|
|
410
441
|
break;
|
|
411
442
|
case 'em':
|
|
412
443
|
out.push((() => {
|
|
413
|
-
let
|
|
414
|
-
template_u1.slot(
|
|
415
|
-
return
|
|
444
|
+
let root_1szz54ar = template_1szz54as(), element_1szz54at = root_1szz54ar.firstChild;
|
|
445
|
+
template_u1.slot(element_1szz54at, content, 1);
|
|
446
|
+
return root_1szz54ar;
|
|
416
447
|
})());
|
|
417
448
|
break;
|
|
418
449
|
case 'link':
|
|
419
450
|
out.push(token.href
|
|
420
451
|
? (() => {
|
|
421
|
-
let
|
|
422
|
-
template_u1.slot(
|
|
423
|
-
template_u1.setProperty(
|
|
424
|
-
return
|
|
452
|
+
let root_1szz54au = template_1szz54av(), element_1szz54aw = root_1szz54au.firstChild;
|
|
453
|
+
template_u1.slot(element_1szz54aw, content, 1);
|
|
454
|
+
template_u1.setProperty(element_1szz54aw, 'href', token.href);
|
|
455
|
+
return root_1szz54au;
|
|
425
456
|
})()
|
|
426
457
|
: (() => {
|
|
427
|
-
let
|
|
428
|
-
template_u1.slot(
|
|
429
|
-
return
|
|
458
|
+
let root_1szz54ax = template_1szz54ay(), element_1szz54az = root_1szz54ax.firstChild;
|
|
459
|
+
template_u1.slot(element_1szz54az, content, 1);
|
|
460
|
+
return root_1szz54ax;
|
|
430
461
|
})());
|
|
431
462
|
break;
|
|
432
463
|
case 'strike':
|
|
433
464
|
out.push((() => {
|
|
434
|
-
let
|
|
435
|
-
template_u1.slot(
|
|
436
|
-
return
|
|
465
|
+
let root_1szz54a10 = template_1szz54a11(), element_1szz54a12 = root_1szz54a10.firstChild;
|
|
466
|
+
template_u1.slot(element_1szz54a12, content, 1);
|
|
467
|
+
return root_1szz54a10;
|
|
437
468
|
})());
|
|
438
469
|
break;
|
|
439
470
|
case 'strong':
|
|
440
471
|
out.push((() => {
|
|
441
|
-
let
|
|
442
|
-
template_u1.slot(
|
|
443
|
-
return
|
|
472
|
+
let root_1szz54a13 = template_1szz54a14(), element_1szz54a15 = root_1szz54a13.firstChild;
|
|
473
|
+
template_u1.slot(element_1szz54a15, content, 1);
|
|
474
|
+
return root_1szz54a13;
|
|
444
475
|
})());
|
|
445
476
|
break;
|
|
446
477
|
default:
|
|
@@ -449,8 +480,19 @@ const renderer = (host) => {
|
|
|
449
480
|
}
|
|
450
481
|
return out;
|
|
451
482
|
}
|
|
483
|
+
function info(block, view) {
|
|
484
|
+
let source = host.text(), end = source.indexOf('\n', block.from), line = source.slice(block.from, end < 0 ? source.length : end).replace(CARRIAGE_RETURN, ''), from = FENCE_OPEN.exec(line)?.[0].length ?? line.length;
|
|
485
|
+
return (() => {
|
|
486
|
+
let root_1szz54a16 = template_1szz54a17(), element_1szz54a18 = root_1szz54a16.firstChild;
|
|
487
|
+
template_u1.slot(element_1szz54a18, piece(line.slice(from), block, from, view), 1);
|
|
488
|
+
return root_1szz54a16;
|
|
489
|
+
})();
|
|
490
|
+
}
|
|
452
491
|
function marked(block, rows, view) {
|
|
453
492
|
let tokens = host.inline(block);
|
|
493
|
+
if (!tokens.length) {
|
|
494
|
+
return template_1szz54a6();
|
|
495
|
+
}
|
|
454
496
|
if (!rows) {
|
|
455
497
|
return inline(tokens, block, view);
|
|
456
498
|
}
|
|
@@ -491,29 +533,39 @@ const renderer = (host) => {
|
|
|
491
533
|
let base = block.from;
|
|
492
534
|
return { contentFrom: row.contentFrom - base, contentTo: row.contentTo - base, from: row.from - base, to: row.to - base };
|
|
493
535
|
}
|
|
494
|
-
function task(block, checked) {
|
|
495
|
-
let previous = flips.get(block.from), animate = previous !== undefined && previous !== checked;
|
|
536
|
+
function task(block, checked, content) {
|
|
537
|
+
let previous = flips.get(block.from), animate = previous !== undefined && previous !== checked, state = new ReactiveObject_1szz54a0(animate ? !!previous : checked);
|
|
496
538
|
flips.delete(block.from);
|
|
497
|
-
return
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
input
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
checked: animate ? previous : checked,
|
|
508
|
-
disabled: () => host.readonly(),
|
|
509
|
-
onclick: (e) => {
|
|
510
|
-
e.preventDefault();
|
|
511
|
-
flips.set(block.from, checked);
|
|
512
|
-
host.task(block);
|
|
539
|
+
return [
|
|
540
|
+
checkbox({
|
|
541
|
+
class: 'markdown-editor-task',
|
|
542
|
+
contenteditable: 'false',
|
|
543
|
+
onfirstpaint: (element) => {
|
|
544
|
+
let input = element.querySelector('input');
|
|
545
|
+
if (animate && input) {
|
|
546
|
+
input.checked = checked;
|
|
547
|
+
state.done = checked;
|
|
548
|
+
}
|
|
513
549
|
},
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
550
|
+
[checkbox.input]: {
|
|
551
|
+
'aria-label': 'Toggle task',
|
|
552
|
+
checked: animate ? previous : checked,
|
|
553
|
+
disabled: () => host.readonly(),
|
|
554
|
+
onclick: (e) => {
|
|
555
|
+
e.preventDefault();
|
|
556
|
+
flips.set(block.from, checked);
|
|
557
|
+
host.task(block);
|
|
558
|
+
},
|
|
559
|
+
onmousedown: prevent
|
|
560
|
+
}
|
|
561
|
+
}),
|
|
562
|
+
(() => {
|
|
563
|
+
let root_1szz54a19 = template_1szz54a1a(), element_1szz54a1b = root_1szz54a19.firstChild;
|
|
564
|
+
template_u1.slot(element_1szz54a1b, content, 1);
|
|
565
|
+
template_u1.setList(element_1szz54a1b, 'class', () => state.done && 'markdown-editor-label--done');
|
|
566
|
+
return root_1szz54a19;
|
|
567
|
+
})()
|
|
568
|
+
];
|
|
517
569
|
}
|
|
518
570
|
return {
|
|
519
571
|
offset: (node, offset) => {
|
|
@@ -526,34 +578,34 @@ const renderer = (host) => {
|
|
|
526
578
|
segments: (unit) => views.get(unit)?.segments ?? null,
|
|
527
579
|
state: (unit) => views.get(unit)?.state ?? null,
|
|
528
580
|
template: (unit) => {
|
|
529
|
-
let block = unit.block, view = { segments: [], state: new
|
|
581
|
+
let block = unit.block, view = { segments: [], state: new ReactiveObject_1szz54a1(host.foldable(unit)) }, content = body(unit, view);
|
|
530
582
|
views.set(unit, view);
|
|
531
583
|
return (() => {
|
|
532
|
-
let
|
|
533
|
-
template_u1.slot(
|
|
534
|
-
template_u1.slot(
|
|
535
|
-
template_u1.setProperty(
|
|
536
|
-
template_u1.setList(
|
|
537
|
-
template_u1.delegate(
|
|
538
|
-
template_u1.delegate(
|
|
539
|
-
template_u1.setList(
|
|
540
|
-
template_u1.setList(
|
|
584
|
+
let root_1szz54a1c = template_1szz54a1d(), element_1szz54a1e = root_1szz54a1c.firstChild, element_1szz54a1f = element_1szz54a1e.firstElementChild;
|
|
585
|
+
template_u1.slot(element_1szz54a1f, icon({ 'aria-hidden': 'true', class: 'markdown-editor-fold-icon' }, chevron), 1);
|
|
586
|
+
template_u1.slot(element_1szz54a1e, content, 2);
|
|
587
|
+
template_u1.setProperty(element_1szz54a1f, 'aria-label', unit.fold ? 'Unfold block' : 'Fold block');
|
|
588
|
+
template_u1.setList(element_1szz54a1f, 'class', [() => !view.state.foldable && !unit.fold && 'markdown-editor-fold--none', unit.fold ? '--active' : '']);
|
|
589
|
+
template_u1.delegate(element_1szz54a1f, 'click', () => unit.fold ? host.unfold(unit) : host.fold(unit));
|
|
590
|
+
template_u1.delegate(element_1szz54a1f, 'mousedown', prevent);
|
|
591
|
+
template_u1.setList(element_1szz54a1e, 'class', template_u1.interpolate(["markdown-editor-block--", (block.kind)]));
|
|
592
|
+
template_u1.setList(element_1szz54a1e, 'class', [
|
|
541
593
|
block.level ? `markdown-editor-block--h${block.level}` : '',
|
|
542
594
|
block.quoteDepth ? 'markdown-editor-block--quoted' : '',
|
|
543
595
|
unit.continuation ? 'markdown-editor-block--continuation' : '',
|
|
544
596
|
unit.continues ? 'markdown-editor-block--continues' : '',
|
|
597
|
+
block.task && !unit.continuation ? 'markdown-editor-block--task' : '',
|
|
545
598
|
unit.raw || unit.fold ? 'markdown-editor-block--raw' : ''
|
|
546
599
|
]);
|
|
547
|
-
template_u1.onconnect(
|
|
548
|
-
template_u1.ondisconnect(
|
|
600
|
+
template_u1.onconnect(element_1szz54a1e, (element) => host.shown(element, unit));
|
|
601
|
+
template_u1.ondisconnect(element_1szz54a1e, (element) => {
|
|
549
602
|
if (views.get(unit) === view) {
|
|
550
603
|
views.delete(unit);
|
|
551
604
|
}
|
|
552
605
|
host.shown(element, null);
|
|
553
606
|
});
|
|
554
|
-
template_u1.
|
|
555
|
-
|
|
556
|
-
return root_1szz54ay;
|
|
607
|
+
template_u1.setList(element_1szz54a1e, 'style', `--depth: ${block.quoteDepth}; --indent: ${unit.raw ? 0 : block.indent};`);
|
|
608
|
+
return root_1szz54a1c;
|
|
557
609
|
})();
|
|
558
610
|
}
|
|
559
611
|
};
|