@mdsvex/parse 1.0.0-next.0 → 1.0.0-next.1
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/CHANGELOG.md +213 -0
- package/WIRE_FORMAT.md +5 -1
- package/dist/buf-utils.js +23 -23
- package/dist/buf_utils.d.ts +1 -1
- package/dist/cursor.d.ts +17 -13
- package/dist/cursor.js +118 -31
- package/dist/main.d.ts +362 -26
- package/dist/main.js +5841 -3420
- package/dist/node_view-bvM0i0-p.js +407 -0
- package/dist/node_view.d.ts +11 -12
- package/dist/opcodes.d.ts +23 -6
- package/dist/plugin_dispatch.d.ts +22 -8
- package/dist/tree-builder.js +185 -66
- package/dist/tree_builder.d.ts +42 -11
- package/dist/undo_log.d.ts +11 -1
- package/dist/utils.d.ts +77 -51
- package/dist/utils.js +687 -209
- package/dist/wire-tree-builder.js +69 -71
- package/dist/wire_tree_builder.d.ts +4 -7
- package/package.json +1 -1
- package/src/buf_utils.ts +10 -14
- package/src/cursor.ts +74 -57
- package/src/main.ts +9898 -5593
- package/src/node_view.ts +159 -140
- package/src/opcodes.ts +39 -7
- package/src/plugin_dispatch.ts +328 -219
- package/src/tree_builder.ts +278 -98
- package/src/undo_log.ts +58 -24
- package/src/utils.spec.ts +86 -9
- package/src/utils.ts +769 -392
- package/src/wire_emitter.ts +6 -0
- package/src/wire_tree_builder.ts +39 -52
- package/test/block_quotes.spec.ts +78 -7
- package/test/code_spans.spec.ts +158 -6
- package/test/crlf.spec.ts +49 -1
- package/test/directives.spec.ts +530 -1
- package/test/emphasis.spec.ts +10 -4
- package/test/fixtures/pfm/block_quotes/pfm_fence_close.md +4 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_compact.md +4 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_end_quote.md +5 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_info.md +5 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_longer.md +4 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_nested.md +3 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_close_twice.md +6 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_info_eof.md +1 -0
- package/test/fixtures/pfm/block_quotes/pfm_fence_unclosed.md +2 -0
- package/test/fixtures/pfm/code_spans/pfm_328_5.md +1 -0
- package/test/fixtures/pfm/code_spans/pfm_328_6.md +1 -0
- package/test/fixtures/pfm/code_spans/pfm_328_7.md +1 -0
- package/test/fixtures/pfm/code_spans/pfm_328_8.md +1 -0
- package/test/fixtures/pfm/code_spans/pfm_328_9.md +2 -0
- package/test/fixtures/pfm/fenced_code_blocks/pfm_info_eof.md +1 -0
- package/test/fixtures/pfm/fenced_code_blocks/pfm_info_eof_no_lf.md +1 -0
- package/test/fixtures/pfm/generic_directives/106.md +1 -0
- package/test/fixtures/pfm/generic_directives/107.md +3 -0
- package/test/fixtures/pfm/generic_directives/108.md +1 -0
- package/test/fixtures/pfm/generic_directives/109.md +1 -0
- package/test/fixtures/pfm/generic_directives/110.md +1 -0
- package/test/fixtures/pfm/generic_directives/111.md +1 -0
- package/test/fixtures/pfm/generic_directives/112.md +1 -0
- package/test/fixtures/pfm/generic_directives/113.md +1 -0
- package/test/fixtures/pfm/generic_directives/114.md +2 -0
- package/test/fixtures/pfm/generic_directives/115.md +1 -0
- package/test/fixtures/pfm/generic_directives/116.md +6 -0
- package/test/fixtures/pfm/generic_directives/117.md +3 -0
- package/test/fixtures/pfm/generic_directives/118.md +6 -0
- package/test/fixtures/pfm/generic_directives/119.md +3 -0
- package/test/fixtures/pfm/generic_directives/120.md +5 -0
- package/test/fixtures/pfm/generic_directives/121.md +3 -0
- package/test/fixtures/pfm/generic_directives/122.md +4 -0
- package/test/fixtures/pfm/generic_directives/123.md +2 -0
- package/test/html.spec.ts +44 -1
- package/test/html_block_containers.spec.ts +445 -0
- package/test/incremental.spec.ts +271 -0
- package/test/lists.spec.ts +107 -1
- package/test/parser_reuse.spec.ts +40 -0
- package/test/plugins.spec.ts +196 -226
- package/test/print.ts +2 -3
- package/test/run_bytecode.spec.ts +36 -0
- package/test/snapshots/hybrid/component-children.snap.ast +9 -16
- package/test/snapshots/hybrid/component-simple-00.snap.ast +1 -2
- package/test/snapshots/hybrid/component-simple-01.snap.ast +1 -2
- package/test/snapshots/hybrid/component-simple-03.snap.ast +13 -13
- package/test/snapshots/hybrid/component-simple-04.snap.ast +1 -2
- package/test/snapshots/hybrid/error.snap.ast +1 -2
- package/test/snapshots/markdown/blockquote-nested-markdown.snap.ast +2 -1
- package/test/snapshots/markdown/emphasis.snap.ast +2 -2
- package/test/snapshots/markdown/encodeHTMLCodeTags.snap.ast +1 -2
- package/test/snapshots/markdown/github-style-codeblock-inside-quote.snap.ast +8 -1
- package/test/snapshots/markdown/html-comments.snap.ast +11 -13
- package/test/snapshots/markdown/html5-strutural-tags.snap.ast +16 -31
- package/test/snapshots/markdown/line-starts-with-html.snap.ast +5 -6
- package/test/snapshots/markdown/literal-html-tags.snap.ast +11 -14
- package/test/snapshots/markdown/nested-blockquote.snap.ast +3 -3
- package/test/snapshots/markdown/pre-code-tags.snap.ast +5 -8
- package/test/snapshots/pfm/block_quotes/237.snap.ast +1 -2
- package/test/snapshots/pfm/block_quotes/251.snap.ast +5 -5
- package/test/snapshots/pfm/block_quotes/pfm_fence_close.snap.ast +6 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_compact.snap.ast +6 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_end_quote.snap.ast +8 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_info.snap.ast +4 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_longer.snap.ast +6 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_nested.snap.ast +5 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_close_twice.snap.ast +5 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_info_eof.snap.ast +3 -0
- package/test/snapshots/pfm/block_quotes/pfm_fence_unclosed.snap.ast +3 -0
- package/test/snapshots/pfm/code_spans/344.snap.ast +1 -1
- package/test/snapshots/pfm/code_spans/347.snap.ast +1 -2
- package/test/snapshots/pfm/code_spans/pfm_328_5.snap.ast +6 -0
- package/test/snapshots/pfm/code_spans/pfm_328_6.snap.ast +6 -0
- package/test/snapshots/pfm/code_spans/pfm_328_7.snap.ast +6 -0
- package/test/snapshots/pfm/code_spans/pfm_328_8.snap.ast +8 -0
- package/test/snapshots/pfm/code_spans/pfm_328_9.snap.ast +10 -0
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/417.snap.ast +2 -2
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/438.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/441.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/444.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/445.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/450.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/453.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/456.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/457.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/473.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/475.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/476.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/477.snap.ast +1 -1
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/478.snap.ast +3 -4
- package/test/snapshots/pfm/emphasis_and_strong_emphasis/479.snap.ast +3 -4
- package/test/snapshots/pfm/fenced_code_blocks/126.snap.ast +1 -2
- package/test/snapshots/pfm/fenced_code_blocks/pfm_info_eof.snap.ast +2 -0
- package/test/snapshots/pfm/fenced_code_blocks/pfm_info_eof_no_lf.snap.ast +2 -0
- package/test/snapshots/pfm/generic_directives/011.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/015.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/016.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/017.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/019.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/020.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/030.snap.ast +4 -6
- package/test/snapshots/pfm/generic_directives/034.snap.ast +6 -2
- package/test/snapshots/pfm/generic_directives/036.snap.ast +5 -1
- package/test/snapshots/pfm/generic_directives/038.snap.ast +6 -2
- package/test/snapshots/pfm/generic_directives/039.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/040.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/044.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/046.snap.ast +3 -1
- package/test/snapshots/pfm/generic_directives/089.snap.ast +1 -1
- package/test/snapshots/pfm/generic_directives/103.snap.ast +6 -2
- package/test/snapshots/pfm/generic_directives/106.snap.ast +9 -0
- package/test/snapshots/pfm/generic_directives/107.snap.ast +9 -0
- package/test/snapshots/pfm/generic_directives/108.snap.ast +5 -0
- package/test/snapshots/pfm/generic_directives/109.snap.ast +4 -0
- package/test/snapshots/pfm/generic_directives/110.snap.ast +10 -0
- package/test/snapshots/pfm/generic_directives/111.snap.ast +7 -0
- package/test/snapshots/pfm/generic_directives/112.snap.ast +18 -0
- package/test/snapshots/pfm/generic_directives/113.snap.ast +7 -0
- package/test/snapshots/pfm/generic_directives/114.snap.ast +12 -0
- package/test/snapshots/pfm/generic_directives/115.snap.ast +10 -0
- package/test/snapshots/pfm/generic_directives/116.snap.ast +13 -0
- package/test/snapshots/pfm/generic_directives/117.snap.ast +9 -0
- package/test/snapshots/pfm/generic_directives/118.snap.ast +10 -0
- package/test/snapshots/pfm/generic_directives/119.snap.ast +9 -0
- package/test/snapshots/pfm/generic_directives/120.snap.ast +12 -0
- package/test/snapshots/pfm/generic_directives/121.snap.ast +3 -0
- package/test/snapshots/pfm/generic_directives/122.snap.ast +3 -0
- package/test/snapshots/pfm/generic_directives/123.snap.ast +3 -0
- package/test/snapshots/pfm/hard_line_breaks/642.snap.ast +1 -1
- package/test/snapshots/pfm/hard_line_breaks/643.snap.ast +1 -1
- package/test/snapshots/pfm/html/148.snap.ast +1 -1
- package/test/snapshots/pfm/html/150.snap.ast +1 -1
- package/test/snapshots/pfm/html/159.snap.ast +2 -3
- package/test/snapshots/pfm/html/162.snap.ast +3 -4
- package/test/snapshots/pfm/html/163.snap.ast +1 -1
- package/test/snapshots/pfm/html/164.snap.ast +3 -4
- package/test/snapshots/pfm/html/166.snap.ast +1 -1
- package/test/snapshots/pfm/html/168.snap.ast +2 -3
- package/test/snapshots/pfm/html/169.snap.ast +5 -7
- package/test/snapshots/pfm/html/174.snap.ast +3 -3
- package/test/snapshots/pfm/html/182.snap.ast +1 -1
- package/test/snapshots/pfm/html/613.snap.ast +2 -2
- package/test/snapshots/pfm/html/615.snap.ast +2 -2
- package/test/snapshots/pfm/images/585.snap.ast +1 -1
- package/test/snapshots/pfm/images/589.snap.ast +1 -1
- package/test/snapshots/pfm/link_reference_definitions/201.snap.ast +1 -1
- package/test/snapshots/pfm/link_reference_definitions/208.snap.ast +1 -1
- package/test/snapshots/pfm/links/491.snap.ast +1 -1
- package/test/snapshots/pfm/links/494.snap.ast +2 -2
- package/test/snapshots/pfm/links/516.snap.ast +8 -9
- package/test/snapshots/pfm/links/521.snap.ast +1 -1
- package/test/snapshots/pfm/links/530.snap.ast +8 -12
- package/test/snapshots/pfm/links/534.snap.ast +1 -1
- package/test/snapshots/pfm/links/552.snap.ast +2 -2
- package/test/snapshots/pfm/links/559.snap.ast +1 -1
- package/test/snapshots/pfm/links/564.snap.ast +1 -1
- package/test/snapshots/pfm/list_items/260.snap.ast +3 -4
- package/test/snapshots/pfm/list_items/293.snap.ast +2 -2
- package/test/snapshots/pfm/tabs/16.snap.ast +2 -3
- package/test/snapshots/pfm/tabs/4.snap.ast +6 -5
- package/test/snapshots/svelte/00-introduction/00-hello-world/App.snap.ast +3 -4
- package/test/snapshots/svelte/00-introduction/02-styling/App.snap.ast +2 -3
- package/test/snapshots/svelte/00-introduction/03-nested-components/App.snap.ast +2 -3
- package/test/snapshots/svelte/00-introduction/03-nested-components/Nested.snap.ast +1 -2
- package/test/snapshots/svelte/00-introduction/04-html-tags/App.snap.ast +1 -2
- package/test/snapshots/svelte/01-reactivity/00-reactive-assignments/App.snap.ast +5 -6
- package/test/snapshots/svelte/01-reactivity/01-reactive-declarations/App.snap.ast +11 -14
- package/test/snapshots/svelte/01-reactivity/02-reactive-statements/App.snap.ast +5 -6
- package/test/snapshots/svelte/02-props/00-declaring-props/Nested.snap.ast +2 -3
- package/test/snapshots/svelte/02-props/01-default-values/App.snap.ast +1 -1
- package/test/snapshots/svelte/02-props/01-default-values/Nested.snap.ast +2 -3
- package/test/snapshots/svelte/02-props/02-spread-props/Info.snap.ast +16 -17
- package/test/snapshots/svelte/03-logic/00-if-blocks/App.snap.ast +4 -8
- package/test/snapshots/svelte/03-logic/01-else-blocks/App.snap.ast +4 -8
- package/test/snapshots/svelte/03-logic/02-else-if-blocks/App.snap.ast +6 -9
- package/test/snapshots/svelte/03-logic/03-each-blocks/App.snap.ast +5 -8
- package/test/snapshots/svelte/03-logic/04-keyed-each-blocks/App.snap.ast +4 -7
- package/test/snapshots/svelte/03-logic/04-keyed-each-blocks/Thing.snap.ast +4 -5
- package/test/snapshots/svelte/04-events/02-event-modifiers/App.snap.ast +2 -3
- package/test/snapshots/svelte/04-events/03-component-events/Inner.snap.ast +2 -3
- package/test/snapshots/svelte/04-events/04-event-forwarding/Inner.snap.ast +2 -3
- package/test/snapshots/svelte/04-events/05-dom-event-forwarding/FancyButton.snap.ast +2 -3
- package/test/snapshots/svelte/05-bindings/00-text-inputs/App.snap.ast +3 -4
- package/test/snapshots/svelte/05-bindings/01-numeric-inputs/App.snap.ast +9 -8
- package/test/snapshots/svelte/05-bindings/02-checkbox-inputs/App.snap.ast +7 -11
- package/test/snapshots/svelte/05-bindings/03-group-inputs/App.snap.ast +21 -30
- package/test/snapshots/svelte/05-bindings/04-textarea-inputs/App.snap.ast +1 -2
- package/test/snapshots/svelte/05-bindings/05-select-bindings/App.snap.ast +5 -9
- package/test/snapshots/svelte/05-bindings/06-multiple-select-bindings/App.snap.ast +18 -26
- package/test/snapshots/svelte/05-bindings/07-each-block-bindings/App.snap.ast +7 -11
- package/test/snapshots/svelte/05-bindings/08-media-elements/App.snap.ast +15 -19
- package/test/snapshots/svelte/05-bindings/09-dimensions/App.snap.ast +7 -9
- package/test/snapshots/svelte/05-bindings/11-component-bindings/App.snap.ast +1 -2
- package/test/snapshots/svelte/05-bindings/11-component-bindings/Keypad.snap.ast +32 -34
- package/test/snapshots/svelte/06-lifecycle/00-onmount/App.snap.ast +3 -6
- package/test/snapshots/svelte/06-lifecycle/01-ondestroy/App.snap.ast +6 -7
- package/test/snapshots/svelte/06-lifecycle/02-update/App.snap.ast +2 -4
- package/test/snapshots/svelte/07-stores/00-writable-stores/App.snap.ast +4 -5
- package/test/snapshots/svelte/07-stores/00-writable-stores/Decrementer.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/00-writable-stores/Incrementer.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/00-writable-stores/Resetter.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/01-auto-subscriptions/App.snap.ast +4 -5
- package/test/snapshots/svelte/07-stores/01-auto-subscriptions/Decrementer.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/01-auto-subscriptions/Incrementer.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/01-auto-subscriptions/Resetter.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/02-readable-stores/App.snap.ast +2 -3
- package/test/snapshots/svelte/07-stores/03-derived-stores/App.snap.ast +8 -10
- package/test/snapshots/svelte/07-stores/04-custom-stores/App.snap.ast +7 -11
- package/test/snapshots/svelte/08-motion/00-tweened/App.snap.ast +10 -15
- package/test/snapshots/svelte/08-motion/01-spring/App.snap.ast +10 -10
- package/test/snapshots/svelte/09-transitions/00-transition/App.snap.ast +3 -5
- package/test/snapshots/svelte/09-transitions/01-adding-parameters-to-transitions/App.snap.ast +3 -5
- package/test/snapshots/svelte/09-transitions/02-in-and-out/App.snap.ast +3 -5
- package/test/snapshots/svelte/09-transitions/03-custom-css-transitions/App.snap.ast +4 -6
- package/test/snapshots/svelte/09-transitions/04-custom-js-transitions/App.snap.ast +3 -5
- package/test/snapshots/svelte/09-transitions/05-transition-events/App.snap.ast +5 -8
- package/test/snapshots/svelte/10-animations/00-animate/App.snap.ast +16 -20
- package/test/snapshots/svelte/11-easing/00-easing/App.snap.ast +16 -11
- package/test/snapshots/svelte/11-easing/00-easing/Controls.snap.ast +11 -16
- package/test/snapshots/svelte/11-easing/00-easing/Grid.snap.ast +2 -2
- package/test/snapshots/svelte/12-svg/01-clock/App.snap.ast +2 -1
- package/test/snapshots/svelte/12-svg/02-bar-chart/App.snap.ast +7 -9
- package/test/snapshots/svelte/12-svg/03-area-chart/App.snap.ast +14 -15
- package/test/snapshots/svelte/12-svg/04-scatterplot/App.snap.ast +7 -5
- package/test/snapshots/svelte/12-svg/04-scatterplot/Scatterplot.snap.ast +6 -6
- package/test/snapshots/svelte/12-svg/05-svg-transitions/App.snap.ast +5 -6
- package/test/snapshots/svelte/13-actions/01-adding-parameters-to-actions/App.snap.ast +2 -3
- package/test/snapshots/svelte/14-classes/00-classes/App.snap.ast +3 -6
- package/test/snapshots/svelte/14-classes/01-class-shorthand/App.snap.ast +2 -3
- package/test/snapshots/svelte/15-composition/00-slots/App.snap.ast +3 -5
- package/test/snapshots/svelte/15-composition/01-slot-fallbacks/App.snap.ast +3 -5
- package/test/snapshots/svelte/15-composition/01-slot-fallbacks/Box.snap.ast +1 -2
- package/test/snapshots/svelte/15-composition/02-named-slots/App.snap.ast +7 -11
- package/test/snapshots/svelte/15-composition/02-named-slots/ContactCard.snap.ast +3 -6
- package/test/snapshots/svelte/15-composition/03-slot-props/App.snap.ast +9 -15
- package/test/snapshots/svelte/15-composition/04-modal/App.snap.ast +17 -26
- package/test/snapshots/svelte/15-composition/04-modal/Modal.snap.ast +3 -3
- package/test/snapshots/svelte/16-context/00-context-api/App.snap.ast +10 -5
- package/test/snapshots/svelte/17-special-elements/00-svelte-self/File.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/00-svelte-self/Folder.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/01-svelte-component/App.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/01-svelte-component/BlueThing.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/01-svelte-component/GreenThing.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/01-svelte-component/RedThing.snap.ast +1 -2
- package/test/snapshots/svelte/17-special-elements/02-svelte-window/App.snap.ast +3 -6
- package/test/snapshots/svelte/17-special-elements/03-svelte-window-bindings/App.snap.ast +2 -4
- package/test/snapshots/svelte/17-special-elements/05-svelte-head/App.snap.ast +6 -12
- package/test/snapshots/svelte/18-module-context/01-module-exports/App.snap.ast +2 -3
- package/test/snapshots/svelte/18-module-context/01-module-exports/AudioPlayer.snap.ast +4 -7
- package/test/snapshots/svelte/19-debugging/00-debug/App.snap.ast +5 -7
- package/test/snapshots/svelte/19-debugging/00-debug/Test.snap.ast +7 -11
- package/test/snapshots/svelte/20-7guis/01-7guis-counter/App.snap.ast +2 -3
- package/test/snapshots/svelte/20-7guis/02-7guis-temperature/App.snap.ast +2 -2
- package/test/snapshots/svelte/20-7guis/03-7guis-flight-booker/App.snap.ast +4 -7
- package/test/snapshots/svelte/20-7guis/04-7guis-timer/App.snap.ast +13 -17
- package/test/snapshots/svelte/20-7guis/05-7guis-crud/App.snap.ast +11 -13
- package/test/snapshots/svelte/20-7guis/06-7guis-circles/App.snap.ast +10 -11
- package/test/snapshots/svelte/21-miscellaneous/01-hacker-news/Comment.snap.ast +4 -6
- package/test/snapshots/svelte/21-miscellaneous/01-hacker-news/Item.snap.ast +9 -13
- package/test/snapshots/svelte/21-miscellaneous/01-hacker-news/List.snap.ast +3 -5
- package/test/snapshots/svelte/21-miscellaneous/01-hacker-news/Summary.snap.ast +7 -11
- package/test/snapshots/svelte/21-miscellaneous/02-immutable-data/App.snap.ast +2 -4
- package/test/snapshots/svelte/99-embeds/20181225-blog-svelte-css-in-js/App.snap.ast +6 -7
- package/test/snapshots/svelte/99-embeds/20181225-blog-svelte-css-in-js/Hero.snap.ast +3 -5
- package/test/snapshots/svelte/99-embeds/20190420-blog-write-less-code/App.snap.ast +6 -7
- package/test/svelte_expressions.spec.ts +93 -4
- package/test/svelte_tags.spec.ts +27 -12
- package/test/tables.spec.ts +347 -0
- package/test/tree_builder.spec.ts +286 -1
- package/test/unclosed_delimiters.spec.ts +529 -0
- package/tsc/buf_utils.d.ts +1 -1
- package/tsc/buf_utils.js +9 -9
- package/tsc/cursor.d.ts +17 -13
- package/tsc/cursor.js +60 -43
- package/tsc/main.d.ts +362 -26
- package/tsc/main.js +8955 -4891
- package/tsc/node_view.d.ts +11 -12
- package/tsc/node_view.js +134 -102
- package/tsc/opcodes.d.ts +23 -6
- package/tsc/plugin_dispatch.d.ts +22 -8
- package/tsc/plugin_dispatch.js +292 -170
- package/tsc/tree_builder.d.ts +42 -11
- package/tsc/tree_builder.js +237 -82
- package/tsc/undo_log.d.ts +11 -1
- package/tsc/undo_log.js +54 -19
- package/tsc/utils.d.ts +77 -51
- package/tsc/utils.js +687 -344
- package/tsc/utils.spec.js +83 -9
- package/tsc/wire_emitter.js +6 -0
- package/tsc/wire_tree_builder.d.ts +4 -7
- package/tsc/wire_tree_builder.js +34 -37
- package/dist/node_view-BEh2-H86.js +0 -373
|
@@ -3,18 +3,16 @@ root
|
|
|
3
3
|
line_break
|
|
4
4
|
line_break
|
|
5
5
|
html tag="h1"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
mustache "formatter.format($time)"
|
|
6
|
+
text "The time is "
|
|
7
|
+
mustache "formatter.format($time)"
|
|
9
8
|
line_break
|
|
10
9
|
line_break
|
|
11
10
|
html tag="p"
|
|
12
11
|
line_break
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
mustache "$elapsed === 1 ? 'second' : 'seconds'"
|
|
12
|
+
text "This page has been open for"
|
|
13
|
+
soft_break
|
|
14
|
+
text " "
|
|
15
|
+
mustache "$elapsed"
|
|
16
|
+
text " "
|
|
17
|
+
mustache "$elapsed === 1 ? 'second' : 'seconds'"
|
|
20
18
|
line_break
|
|
@@ -3,19 +3,15 @@ root
|
|
|
3
3
|
line_break
|
|
4
4
|
line_break
|
|
5
5
|
html tag="h1"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
mustache "$count"
|
|
6
|
+
text "The count is "
|
|
7
|
+
mustache "$count"
|
|
9
8
|
line_break
|
|
10
9
|
line_break
|
|
11
10
|
html tag="button" on:click=[object Object]
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
line_break
|
|
11
|
+
text "+"
|
|
12
|
+
soft_break
|
|
15
13
|
html tag="button" on:click=[object Object]
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
line_break
|
|
14
|
+
text "-"
|
|
15
|
+
soft_break
|
|
19
16
|
html tag="button" on:click=[object Object]
|
|
20
|
-
|
|
21
|
-
text "reset"
|
|
17
|
+
text "reset"
|
|
@@ -10,34 +10,29 @@ root
|
|
|
10
10
|
line_break
|
|
11
11
|
html tag="button" on:click="{() => progress.set(0)}"
|
|
12
12
|
line_break
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
soft_break
|
|
13
|
+
text "0%"
|
|
14
|
+
line_break
|
|
16
15
|
line_break
|
|
17
16
|
line_break
|
|
18
17
|
html tag="button" on:click="{() => progress.set(0.25)}"
|
|
19
18
|
line_break
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
soft_break
|
|
19
|
+
text "25%"
|
|
20
|
+
line_break
|
|
23
21
|
line_break
|
|
24
22
|
line_break
|
|
25
23
|
html tag="button" on:click="{() => progress.set(0.5)}"
|
|
26
24
|
line_break
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
soft_break
|
|
25
|
+
text "50%"
|
|
26
|
+
line_break
|
|
30
27
|
line_break
|
|
31
28
|
line_break
|
|
32
29
|
html tag="button" on:click="{() => progress.set(0.75)}"
|
|
33
30
|
line_break
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
soft_break
|
|
31
|
+
text "75%"
|
|
32
|
+
line_break
|
|
37
33
|
line_break
|
|
38
34
|
line_break
|
|
39
35
|
html tag="button" on:click="{() => progress.set(1)}"
|
|
40
36
|
line_break
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
soft_break
|
|
37
|
+
text "100%"
|
|
38
|
+
line_break
|
|
@@ -10,11 +10,11 @@ root
|
|
|
10
10
|
html tag="label"
|
|
11
11
|
line_break
|
|
12
12
|
html tag="h3"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
text "stiffness ("
|
|
14
|
+
mustache "coords.stiffness"
|
|
15
|
+
text ")"
|
|
16
|
+
soft_break
|
|
17
|
+
text " "
|
|
18
18
|
html tag="input" bind:value=[object Object] type="range" min="0" max="1" step="0.01" self_closing=true
|
|
19
19
|
line_break
|
|
20
20
|
line_break
|
|
@@ -22,11 +22,11 @@ root
|
|
|
22
22
|
html tag="label"
|
|
23
23
|
line_break
|
|
24
24
|
html tag="h3"
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
25
|
+
text "damping ("
|
|
26
|
+
mustache "coords.damping"
|
|
27
|
+
text ")"
|
|
28
|
+
soft_break
|
|
29
|
+
text " "
|
|
30
30
|
html tag="input" bind:value=[object Object] type="range" min="0" max="1" step="0.01" self_closing=true
|
|
31
31
|
line_break
|
|
32
32
|
line_break
|
|
@@ -5,10 +5,9 @@ root
|
|
|
5
5
|
html tag="label"
|
|
6
6
|
line_break
|
|
7
7
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
8
|
+
soft_break
|
|
9
|
+
text " visible"
|
|
8
10
|
line_break
|
|
9
|
-
paragraph
|
|
10
|
-
text "visible"
|
|
11
|
-
soft_break
|
|
12
11
|
line_break
|
|
13
12
|
line_break
|
|
14
13
|
svelte_block tag="if"
|
|
@@ -16,7 +15,6 @@ root
|
|
|
16
15
|
line_break
|
|
17
16
|
html tag="p" transition:fade=true
|
|
18
17
|
line_break
|
|
19
|
-
|
|
20
|
-
text "Fades in and out"
|
|
18
|
+
text "Fades in and out"
|
|
21
19
|
line_break
|
|
22
20
|
line_break
|
package/test/snapshots/svelte/09-transitions/01-adding-parameters-to-transitions/App.snap.ast
CHANGED
|
@@ -5,10 +5,9 @@ root
|
|
|
5
5
|
html tag="label"
|
|
6
6
|
line_break
|
|
7
7
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
8
|
+
soft_break
|
|
9
|
+
text " visible"
|
|
8
10
|
line_break
|
|
9
|
-
paragraph
|
|
10
|
-
text "visible"
|
|
11
|
-
soft_break
|
|
12
11
|
line_break
|
|
13
12
|
line_break
|
|
14
13
|
svelte_block tag="if"
|
|
@@ -16,7 +15,6 @@ root
|
|
|
16
15
|
line_break
|
|
17
16
|
html tag="p" transition:fly="{{ y: 200, duration: 2000 }}"
|
|
18
17
|
line_break
|
|
19
|
-
|
|
20
|
-
text "Flies in and out"
|
|
18
|
+
text "Flies in and out"
|
|
21
19
|
line_break
|
|
22
20
|
line_break
|
|
@@ -5,10 +5,9 @@ root
|
|
|
5
5
|
html tag="label"
|
|
6
6
|
line_break
|
|
7
7
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
8
|
+
soft_break
|
|
9
|
+
text " visible"
|
|
8
10
|
line_break
|
|
9
|
-
paragraph
|
|
10
|
-
text "visible"
|
|
11
|
-
soft_break
|
|
12
11
|
line_break
|
|
13
12
|
line_break
|
|
14
13
|
svelte_block tag="if"
|
|
@@ -16,7 +15,6 @@ root
|
|
|
16
15
|
line_break
|
|
17
16
|
html tag="p" in:fly="{{ y: 200, duration: 2000 }}" out:fade=true
|
|
18
17
|
line_break
|
|
19
|
-
|
|
20
|
-
text "Flies in, fades out"
|
|
18
|
+
text "Flies in, fades out"
|
|
21
19
|
line_break
|
|
22
20
|
line_break
|
|
@@ -8,10 +8,9 @@ root
|
|
|
8
8
|
html tag="label"
|
|
9
9
|
line_break
|
|
10
10
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
11
|
+
soft_break
|
|
12
|
+
text " visible"
|
|
11
13
|
line_break
|
|
12
|
-
paragraph
|
|
13
|
-
text "visible"
|
|
14
|
-
soft_break
|
|
15
14
|
line_break
|
|
16
15
|
line_break
|
|
17
16
|
svelte_block tag="if"
|
|
@@ -20,8 +19,7 @@ root
|
|
|
20
19
|
html tag="div" class="centered" in:spin="{{duration: 8000}}" out:fade=true
|
|
21
20
|
line_break
|
|
22
21
|
html tag="span"
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
text "!"
|
|
22
|
+
text "transitions"
|
|
23
|
+
text "!"
|
|
26
24
|
line_break
|
|
27
25
|
line_break
|
|
@@ -5,10 +5,9 @@ root
|
|
|
5
5
|
html tag="label"
|
|
6
6
|
line_break
|
|
7
7
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
8
|
+
soft_break
|
|
9
|
+
text " visible"
|
|
8
10
|
line_break
|
|
9
|
-
paragraph
|
|
10
|
-
text "visible"
|
|
11
|
-
soft_break
|
|
12
11
|
line_break
|
|
13
12
|
line_break
|
|
14
13
|
svelte_block tag="if"
|
|
@@ -16,7 +15,6 @@ root
|
|
|
16
15
|
line_break
|
|
17
16
|
html tag="p" in:typewriter=true
|
|
18
17
|
line_break
|
|
19
|
-
|
|
20
|
-
text "The quick brown fox jumps over the lazy dog"
|
|
18
|
+
text "The quick brown fox jumps over the lazy dog"
|
|
21
19
|
line_break
|
|
22
20
|
line_break
|
|
@@ -3,18 +3,16 @@ root
|
|
|
3
3
|
line_break
|
|
4
4
|
line_break
|
|
5
5
|
html tag="p"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
mustache "status"
|
|
6
|
+
text "status: "
|
|
7
|
+
mustache "status"
|
|
9
8
|
line_break
|
|
10
9
|
line_break
|
|
11
10
|
html tag="label"
|
|
12
11
|
line_break
|
|
13
12
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
13
|
+
soft_break
|
|
14
|
+
text " visible"
|
|
14
15
|
line_break
|
|
15
|
-
paragraph
|
|
16
|
-
text "visible"
|
|
17
|
-
soft_break
|
|
18
16
|
line_break
|
|
19
17
|
line_break
|
|
20
18
|
svelte_block tag="if"
|
|
@@ -22,7 +20,6 @@ root
|
|
|
22
20
|
line_break
|
|
23
21
|
html tag="p" transition:fly="{{ y: 200, duration: 2000 }}" on:introstart="{() => status = 'intro started'}" on:outrostart="{() => status = 'outro started'}" on:introend="{() => status = 'intro ended'}" on:outroend="{() => status = 'outro ended'}"
|
|
24
22
|
line_break
|
|
25
|
-
|
|
26
|
-
text "Flies in and out"
|
|
23
|
+
text "Flies in and out"
|
|
27
24
|
line_break
|
|
28
25
|
line_break
|
|
@@ -13,8 +13,7 @@ root
|
|
|
13
13
|
html tag="div" class="left"
|
|
14
14
|
line_break
|
|
15
15
|
html tag="h2"
|
|
16
|
-
|
|
17
|
-
text "todo"
|
|
16
|
+
text "todo"
|
|
18
17
|
line_break
|
|
19
18
|
svelte_block tag="each"
|
|
20
19
|
svelte_branch tag="each" "todos.filter(t => !t.done) as todo (todo.id)"
|
|
@@ -22,15 +21,14 @@ root
|
|
|
22
21
|
html tag="label" in:receive="{{key: todo.id}}" out:send="{{key: todo.id}}" animate:flip=true
|
|
23
22
|
line_break
|
|
24
23
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
24
|
+
soft_break
|
|
25
|
+
text " "
|
|
26
|
+
mustache "todo.description"
|
|
27
|
+
soft_break
|
|
28
|
+
text " "
|
|
29
|
+
html tag="button" on:click="{() => remove(todo)}"
|
|
30
|
+
text "x"
|
|
25
31
|
line_break
|
|
26
|
-
paragraph
|
|
27
|
-
mustache "todo.description"
|
|
28
|
-
soft_break
|
|
29
|
-
text " "
|
|
30
|
-
html tag="button" on:click="{() => remove(todo)}"
|
|
31
|
-
text "x"
|
|
32
|
-
soft_break
|
|
33
|
-
text " "
|
|
34
32
|
line_break
|
|
35
33
|
line_break
|
|
36
34
|
line_break
|
|
@@ -38,8 +36,7 @@ root
|
|
|
38
36
|
html tag="div" class="right"
|
|
39
37
|
line_break
|
|
40
38
|
html tag="h2"
|
|
41
|
-
|
|
42
|
-
text "done"
|
|
39
|
+
text "done"
|
|
43
40
|
line_break
|
|
44
41
|
svelte_block tag="each"
|
|
45
42
|
svelte_branch tag="each" "todos.filter(t => t.done) as todo (todo.id)"
|
|
@@ -47,15 +44,14 @@ root
|
|
|
47
44
|
html tag="label" in:receive="{{key: todo.id}}" out:send="{{key: todo.id}}" animate:flip=true
|
|
48
45
|
line_break
|
|
49
46
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
47
|
+
soft_break
|
|
48
|
+
text " "
|
|
49
|
+
mustache "todo.description"
|
|
50
|
+
soft_break
|
|
51
|
+
text " "
|
|
52
|
+
html tag="button" on:click="{() => remove(todo)}"
|
|
53
|
+
text "x"
|
|
50
54
|
line_break
|
|
51
|
-
paragraph
|
|
52
|
-
mustache "todo.description"
|
|
53
|
-
soft_break
|
|
54
|
-
text " "
|
|
55
|
-
html tag="button" on:click="{() => remove(todo)}"
|
|
56
|
-
text "x"
|
|
57
|
-
soft_break
|
|
58
|
-
text " "
|
|
59
55
|
line_break
|
|
60
56
|
line_break
|
|
61
57
|
line_break
|
|
@@ -11,19 +11,24 @@ root
|
|
|
11
11
|
line_break
|
|
12
12
|
html tag="g" class="canvas"
|
|
13
13
|
line_break
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
paragraph
|
|
15
|
+
html tag="Grid" x=[object Object] y=[object Object] self_closing=true
|
|
16
|
+
soft_break
|
|
17
|
+
text " "
|
|
18
|
+
text tag="g" class="graph" "<g class=\"graph\">"
|
|
19
|
+
soft_break
|
|
20
|
+
text " "
|
|
18
21
|
html tag="path" d=[object Object] stroke="#333" stroke-width="2" fill="none" self_closing=true
|
|
19
|
-
line_break
|
|
20
|
-
line_break
|
|
21
|
-
html tag="path" d="M0,23.647C0,22.41 27.014,0.407 28.496,0.025C29.978,-0.357 69.188,3.744 70.104,4.744C71.02,5.745 71.02,41.499 70.104,42.5C69.188,43.501 29.978,47.601 28.496,47.219C27.014,46.837 0,24.884 0,23.647Z" fill="#ff3e00" style="transform: translate(1060px, {($value - 24)}px)" self_closing=true
|
|
22
|
-
line_break
|
|
23
|
-
line_break
|
|
24
|
-
html tag="circle" cx="{$time}" cy="{$value}" r="15" fill="#ff3e00" self_closing=true
|
|
25
|
-
line_break
|
|
26
22
|
line_break
|
|
23
|
+
line_break
|
|
24
|
+
html tag="path" d="M0,23.647C0,22.41 27.014,0.407 28.496,0.025C29.978,-0.357 69.188,3.744 70.104,4.744C71.02,5.745 71.02,41.499 70.104,42.5C69.188,43.501 29.978,47.601 28.496,47.219C27.014,46.837 0,24.884 0,23.647Z" fill="#ff3e00" style="transform: translate(1060px, {($value - 24)}px)" self_closing=true
|
|
25
|
+
line_break
|
|
26
|
+
line_break
|
|
27
|
+
html tag="circle" cx="{$time}" cy="{$value}" r="15" fill="#ff3e00" self_closing=true
|
|
28
|
+
line_break
|
|
29
|
+
line_break
|
|
30
|
+
paragraph
|
|
31
|
+
text "</g>"
|
|
27
32
|
line_break
|
|
28
33
|
line_break
|
|
29
34
|
line_break
|
|
@@ -10,8 +10,7 @@ root
|
|
|
10
10
|
html tag="div" class="easing-types"
|
|
11
11
|
line_break
|
|
12
12
|
html tag="h3"
|
|
13
|
-
|
|
14
|
-
text "Ease"
|
|
13
|
+
text "Ease"
|
|
15
14
|
line_break
|
|
16
15
|
svelte_block tag="if"
|
|
17
16
|
svelte_branch tag="if" "mobile"
|
|
@@ -46,8 +45,7 @@ root
|
|
|
46
45
|
line_break
|
|
47
46
|
line_break
|
|
48
47
|
html tag="h3"
|
|
49
|
-
|
|
50
|
-
text "Type"
|
|
48
|
+
text "Type"
|
|
51
49
|
line_break
|
|
52
50
|
svelte_block tag="if"
|
|
53
51
|
svelte_branch tag="if" "mobile "
|
|
@@ -84,8 +82,7 @@ root
|
|
|
84
82
|
line_break
|
|
85
83
|
html tag="h4"
|
|
86
84
|
line_break
|
|
87
|
-
|
|
88
|
-
text "Duration"
|
|
85
|
+
text "Duration"
|
|
89
86
|
line_break
|
|
90
87
|
line_break
|
|
91
88
|
html tag="div" class="duration"
|
|
@@ -93,21 +90,19 @@ root
|
|
|
93
90
|
html tag="span"
|
|
94
91
|
line_break
|
|
95
92
|
html tag="input" type="number" bind:value=[object Object] min="0" step="100" self_closing=true
|
|
96
|
-
|
|
93
|
+
soft_break
|
|
94
|
+
text " "
|
|
97
95
|
html tag="button" class="number" on:click=[object Object]
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
96
|
+
text "-"
|
|
97
|
+
soft_break
|
|
98
|
+
text " "
|
|
101
99
|
html tag="button" class="number" on:click=[object Object]
|
|
102
|
-
|
|
103
|
-
text "+"
|
|
100
|
+
text "+"
|
|
104
101
|
line_break
|
|
105
102
|
line_break
|
|
106
103
|
html tag="button" class="play" on:click=[object Object]
|
|
107
104
|
line_break
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
soft_break
|
|
111
|
-
text " "
|
|
105
|
+
mustache "playing ? 'Restart' : 'Play'"
|
|
106
|
+
line_break
|
|
112
107
|
line_break
|
|
113
108
|
line_break
|
|
@@ -25,7 +25,7 @@ root
|
|
|
25
25
|
line_break
|
|
26
26
|
line_break
|
|
27
27
|
html tag="path" style="transform: translateX({x+200}px)" d="M0 0 L0 1800" class="grid-line-xy" self_closing=true
|
|
28
|
-
|
|
28
|
+
soft_break
|
|
29
29
|
html tag="path" style="transform: translateY({y}px)" d="M0 400 L1400 400" class="grid-line-xy" self_closing=true
|
|
30
|
-
|
|
30
|
+
soft_break
|
|
31
31
|
html tag="rect" x="200" y="400" width="1000" height="1000" stroke="#999" fill="none" stroke-width="2" self_closing=true
|
|
@@ -41,7 +41,8 @@ root
|
|
|
41
41
|
html tag="g" transform="rotate({6 * seconds})"
|
|
42
42
|
line_break
|
|
43
43
|
html tag="line" class="second" y1="10" y2="-38" self_closing=true
|
|
44
|
-
|
|
44
|
+
soft_break
|
|
45
|
+
text " "
|
|
45
46
|
html tag="line" class="second-counterweight" y1="10" y2="2" self_closing=true
|
|
46
47
|
line_break
|
|
47
48
|
line_break
|
|
@@ -6,8 +6,7 @@ root
|
|
|
6
6
|
line_break
|
|
7
7
|
line_break
|
|
8
8
|
html tag="h2"
|
|
9
|
-
|
|
10
|
-
text "US birthrate by year"
|
|
9
|
+
text "US birthrate by year"
|
|
11
10
|
line_break
|
|
12
11
|
line_break
|
|
13
12
|
html tag="div" class="chart" bind:clientWidth=[object Object] bind:clientHeight=[object Object]
|
|
@@ -24,12 +23,12 @@ root
|
|
|
24
23
|
html tag="g" class="tick tick-{tick}" transform="translate(0, {yScale(tick) - padding.bottom})"
|
|
25
24
|
line_break
|
|
26
25
|
html tag="line" x2="100%"
|
|
27
|
-
|
|
26
|
+
soft_break
|
|
27
|
+
text " "
|
|
28
28
|
html tag="text" y="-4"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
mustache "tick === 20 ? ' per 1,000 population' : ''"
|
|
29
|
+
mustache "tick"
|
|
30
|
+
text " "
|
|
31
|
+
mustache "tick === 20 ? ' per 1,000 population' : ''"
|
|
33
32
|
line_break
|
|
34
33
|
line_break
|
|
35
34
|
line_break
|
|
@@ -45,8 +44,7 @@ root
|
|
|
45
44
|
html tag="g" class="tick" transform="translate({xScale(i)},{height})"
|
|
46
45
|
line_break
|
|
47
46
|
html tag="text" x="{barWidth/2}" y="-4"
|
|
48
|
-
|
|
49
|
-
mustache "width > 380 ? point.year : formatMobile(point.year)"
|
|
47
|
+
mustache "width > 380 ? point.year : formatMobile(point.year)"
|
|
50
48
|
line_break
|
|
51
49
|
line_break
|
|
52
50
|
line_break
|
|
@@ -3,8 +3,7 @@ root
|
|
|
3
3
|
line_break
|
|
4
4
|
line_break
|
|
5
5
|
html tag="h2"
|
|
6
|
-
|
|
7
|
-
text "Arctic sea ice minimum"
|
|
6
|
+
text "Arctic sea ice minimum"
|
|
8
7
|
line_break
|
|
9
8
|
line_break
|
|
10
9
|
html tag="div" class="chart" bind:clientWidth=[object Object] bind:clientHeight=[object Object]
|
|
@@ -21,12 +20,12 @@ root
|
|
|
21
20
|
html tag="g" class="tick tick-{tick}" transform="translate(0, {yScale(tick) - padding.bottom})"
|
|
22
21
|
line_break
|
|
23
22
|
html tag="line" x2="100%"
|
|
24
|
-
|
|
23
|
+
soft_break
|
|
24
|
+
text " "
|
|
25
25
|
html tag="text" y="-4"
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
mustache "tick === 8 ? ' million sq km' : ''"
|
|
26
|
+
mustache "tick"
|
|
27
|
+
text " "
|
|
28
|
+
mustache "tick === 8 ? ' million sq km' : ''"
|
|
30
29
|
line_break
|
|
31
30
|
line_break
|
|
32
31
|
line_break
|
|
@@ -42,10 +41,10 @@ root
|
|
|
42
41
|
html tag="g" class="tick tick-{ tick }" transform="translate({xScale(tick)},{height})"
|
|
43
42
|
line_break
|
|
44
43
|
html tag="line" y1="-{height}" y2="-{padding.bottom}" x1="0" x2="0"
|
|
45
|
-
|
|
44
|
+
soft_break
|
|
45
|
+
text " "
|
|
46
46
|
html tag="text" y="-2"
|
|
47
|
-
|
|
48
|
-
mustache "width > 380 ? tick : formatMobile(tick)"
|
|
47
|
+
mustache "width > 380 ? tick : formatMobile(tick)"
|
|
49
48
|
line_break
|
|
50
49
|
line_break
|
|
51
50
|
line_break
|
|
@@ -54,17 +53,17 @@ root
|
|
|
54
53
|
html_comment " data "
|
|
55
54
|
line_break
|
|
56
55
|
html tag="path" class="path-area" d=[object Object]
|
|
57
|
-
|
|
56
|
+
soft_break
|
|
57
|
+
text " "
|
|
58
58
|
html tag="path" class="path-line" d=[object Object]
|
|
59
59
|
line_break
|
|
60
60
|
line_break
|
|
61
61
|
line_break
|
|
62
62
|
line_break
|
|
63
63
|
html tag="p"
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
text "NSIDC/NASA"
|
|
64
|
+
text "Average September extent. Source: "
|
|
65
|
+
html tag="a" href="https://climate.nasa.gov/vital-signs/arctic-sea-ice/"
|
|
66
|
+
text "NSIDC/NASA"
|
|
68
67
|
line_break
|
|
69
68
|
line_break
|
|
70
69
|
html tag="style"
|
|
@@ -8,15 +8,17 @@ root
|
|
|
8
8
|
html tag="div" class="chart"
|
|
9
9
|
line_break
|
|
10
10
|
html tag="h2"
|
|
11
|
-
|
|
12
|
-
text "Anscombe's quartet"
|
|
11
|
+
text "Anscombe's quartet"
|
|
13
12
|
line_break
|
|
14
13
|
line_break
|
|
15
14
|
html tag="Scatterplot" points=[object Object] self_closing=true
|
|
16
|
-
|
|
15
|
+
soft_break
|
|
16
|
+
text " "
|
|
17
17
|
html tag="Scatterplot" points=[object Object] self_closing=true
|
|
18
|
-
|
|
18
|
+
soft_break
|
|
19
|
+
text " "
|
|
19
20
|
html tag="Scatterplot" points=[object Object] self_closing=true
|
|
20
|
-
|
|
21
|
+
soft_break
|
|
22
|
+
text " "
|
|
21
23
|
html tag="Scatterplot" points=[object Object] self_closing=true
|
|
22
24
|
line_break
|
|
@@ -17,10 +17,10 @@ root
|
|
|
17
17
|
html tag="g" class="tick tick-{tick}" transform="translate(0, {yScale(tick)})"
|
|
18
18
|
line_break
|
|
19
19
|
html tag="line" x1="{padding.left}" x2="{xScale(22)}" self_closing=true
|
|
20
|
-
|
|
20
|
+
soft_break
|
|
21
|
+
text " "
|
|
21
22
|
html tag="text" x="{padding.left - 8}" y="+4"
|
|
22
|
-
|
|
23
|
-
mustache "tick"
|
|
23
|
+
mustache "tick"
|
|
24
24
|
line_break
|
|
25
25
|
line_break
|
|
26
26
|
line_break
|
|
@@ -36,10 +36,10 @@ root
|
|
|
36
36
|
html tag="g" class="tick" transform="translate({xScale(tick)},0)"
|
|
37
37
|
line_break
|
|
38
38
|
html tag="line" y1="{yScale(0)}" y2="{yScale(13)}" self_closing=true
|
|
39
|
-
|
|
39
|
+
soft_break
|
|
40
|
+
text " "
|
|
40
41
|
html tag="text" y="{height - padding.bottom + 16}"
|
|
41
|
-
|
|
42
|
-
mustache "tick"
|
|
42
|
+
mustache "tick"
|
|
43
43
|
line_break
|
|
44
44
|
line_break
|
|
45
45
|
line_break
|
|
@@ -13,7 +13,8 @@ root
|
|
|
13
13
|
html tag="g" out:fade="{{duration: 200}}" opacity="0.2"
|
|
14
14
|
line_break
|
|
15
15
|
html tag="path" in:expand="{{duration: 400, delay: 1000, easing: quintOut}}" style="stroke: #ff3e00; fill: #ff3e00; stroke-width: 50;" d=[object Object] self_closing=true
|
|
16
|
-
|
|
16
|
+
soft_break
|
|
17
|
+
text " "
|
|
17
18
|
html tag="path" in:draw="{{duration: 1000}}" style="stroke:#ff3e00; stroke-width: 1.5" d=[object Object] self_closing=true
|
|
18
19
|
line_break
|
|
19
20
|
line_break
|
|
@@ -25,8 +26,7 @@ root
|
|
|
25
26
|
svelte_branch tag="each" "'SVELTE' as char, i"
|
|
26
27
|
line_break
|
|
27
28
|
html tag="span" in:fade="{{delay: 1000 + i * 150, duration: 800}}"
|
|
28
|
-
|
|
29
|
-
mustache "char"
|
|
29
|
+
mustache "char"
|
|
30
30
|
line_break
|
|
31
31
|
line_break
|
|
32
32
|
line_break
|
|
@@ -35,10 +35,9 @@ root
|
|
|
35
35
|
html tag="label"
|
|
36
36
|
line_break
|
|
37
37
|
html tag="input" type="checkbox" bind:checked=[object Object] self_closing=true
|
|
38
|
+
soft_break
|
|
39
|
+
text " toggle me"
|
|
38
40
|
line_break
|
|
39
|
-
paragraph
|
|
40
|
-
text "toggle me"
|
|
41
|
-
soft_break
|
|
42
41
|
line_break
|
|
43
42
|
line_break
|
|
44
43
|
html tag="link" href="https://fonts.googleapis.com/css?family=Overpass:100" rel="stylesheet" self_closing=true
|