tiddlywiki 5.2.2 → 5.2.3
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/.github/ISSUE_TEMPLATE/bug_report.yml +67 -0
- package/.github/ISSUE_TEMPLATE/config.yml +8 -0
- package/.github/PULL_REQUEST_TEMPLATE/pull_request_template.md +8 -0
- package/bin/build-site.sh +1 -1
- package/boot/boot.js +1 -1
- package/contributing.md +1 -1
- package/core/language/en-GB/EditTemplate.multids +1 -0
- package/core/language/en-GB/Help/default.tid +4 -1
- package/core/language/en-GB/Help/render.tid +2 -2
- package/core/language/en-GB/SideBar.multids +1 -0
- package/core/modules/commands/render.js +1 -1
- package/core/modules/commands/rendertiddler.js +1 -0
- package/core/modules/commands/rendertiddlers.js +1 -1
- package/core/modules/commands/save.js +56 -42
- package/core/modules/editor/engines/framed.js +3 -1
- package/core/modules/editor/operations/text/prefix-lines.js +2 -2
- package/core/modules/editor/operations/text/wrap-lines.js +27 -10
- package/core/modules/filterrunprefixes/map.js +10 -2
- package/core/modules/filters/insertafter.js +46 -0
- package/core/modules/filters/insertbefore.js +6 -1
- package/core/modules/filters.js +19 -1
- package/core/modules/savers/put.js +11 -7
- package/core/modules/savers/upload.js +1 -1
- package/core/modules/server/server.js +3 -2
- package/core/modules/startup/browser-messaging.js +4 -2
- package/core/modules/startup/story.js +3 -1
- package/core/modules/utils/dom/dom.js +51 -0
- package/core/modules/utils/dom/dragndrop.js +24 -14
- package/core/modules/utils/dom/notifier.js +2 -1
- package/core/modules/utils/parsetree.js +48 -11
- package/core/modules/utils/utils.js +15 -1
- package/core/modules/widgets/action-setfield.js +12 -14
- package/core/modules/widgets/button.js +6 -1
- package/core/modules/widgets/checkbox.js +124 -15
- package/core/modules/widgets/draggable.js +37 -14
- package/core/modules/widgets/element.js +9 -3
- package/core/modules/widgets/eventcatcher.js +1 -27
- package/core/modules/widgets/image.js +4 -0
- package/core/modules/widgets/let.js +1 -1
- package/core/modules/widgets/scrollable.js +2 -0
- package/core/modules/widgets/widget.js +8 -1
- package/core/modules/wiki.js +1 -1
- package/core/palettes/CupertinoDark.tid +3 -3
- package/core/palettes/GruvBoxDark.tid +2 -2
- package/core/palettes/Nord.tid +2 -2
- package/core/templates/save-lazy-all.tid +2 -2
- package/core/templates/server/static.sidebar.wikitext.tid +1 -1
- package/core/templates/server/static.tiddler.html.tid +2 -2
- package/core/ui/Actions/new-image.tid +1 -0
- package/core/ui/Actions/new-journal.tid +2 -1
- package/core/ui/Actions/new-tiddler.tid +1 -0
- package/core/ui/AdvancedSearch/Filter.tid +50 -10
- package/core/ui/AdvancedSearch/FilterButtons/clear.tid +1 -0
- package/core/ui/AdvancedSearch/FilterButtons/delete.tid +1 -0
- package/core/ui/AdvancedSearch/FilterButtons/dropdown.tid +5 -2
- package/core/ui/AdvancedSearch/FilterButtons/export.tid +1 -0
- package/core/ui/AdvancedSearch/Shadows.tid +54 -12
- package/core/ui/AdvancedSearch/Standard.tid +36 -19
- package/core/ui/AdvancedSearch/System.tid +54 -12
- package/core/ui/AdvancedSearch.tid +1 -0
- package/core/ui/AlertTemplate.tid +10 -1
- package/core/ui/Components/tag-link.tid +1 -0
- package/core/ui/ControlPanel/Advanced.tid +1 -0
- package/core/ui/ControlPanel/Appearance.tid +1 -0
- package/core/ui/ControlPanel/Basics.tid +3 -0
- package/core/ui/ControlPanel/Cascades.tid +1 -0
- package/core/ui/ControlPanel/EditorTypes.tid +1 -0
- package/core/ui/ControlPanel/Info.tid +1 -0
- package/core/ui/ControlPanel/KeyboardShortcuts.tid +18 -7
- package/core/ui/ControlPanel/Modals/AddPlugins.tid +26 -9
- package/core/ui/ControlPanel/Parsing.tid +3 -0
- package/core/ui/ControlPanel/Plugins/Add/Updates.tid +5 -1
- package/core/ui/ControlPanel/Plugins/AddPlugins.tid +4 -1
- package/core/ui/ControlPanel/Plugins.tid +1 -0
- package/core/ui/ControlPanel/Saving/TiddlySpot.tid +2 -1
- package/core/ui/ControlPanel/Saving.tid +1 -0
- package/core/ui/ControlPanel/Settings/DefaultMoreSidebarTab.tid +1 -0
- package/core/ui/ControlPanel/Settings/DefaultSidebarTab.tid +1 -0
- package/core/ui/ControlPanel/Settings/LinkToBehaviour.tid +1 -0
- package/core/ui/ControlPanel/Settings/ToolbarButtonStyle.tid +1 -0
- package/core/ui/ControlPanel/Toolbars/EditorItemTemplate.tid +8 -1
- package/core/ui/ControlPanel/Toolbars/ItemTemplate.tid +11 -1
- package/core/ui/ControlPanel/Toolbars.tid +1 -0
- package/core/ui/ControlPanel.tid +1 -0
- package/core/ui/DefaultSearchResultList.tid +1 -0
- package/core/ui/EditTemplate/Preview/output.tid +1 -1
- package/core/ui/EditTemplate/body/default.tid +8 -5
- package/core/ui/EditTemplate/body-editor.tid +2 -0
- package/core/ui/EditTemplate/controls.tid +1 -0
- package/core/ui/EditTemplate/fieldEditor-default.tid +1 -1
- package/core/ui/EditTemplate/fields.tid +17 -10
- package/core/ui/EditTemplate/shadow.tid +2 -0
- package/core/ui/EditTemplate/title.tid +10 -5
- package/core/ui/EditTemplate.tid +28 -4
- package/core/ui/EditorToolbar/editor-height.tid +1 -0
- package/core/ui/EditorToolbar/excise-dropdown.tid +5 -4
- package/core/ui/EditorToolbar/file-import.tid +4 -0
- package/core/ui/EditorToolbar/link-dropdown.tid +10 -5
- package/core/ui/EditorToolbar/more-dropdown.tid +5 -1
- package/core/ui/EditorToolbar/paint.tid +1 -0
- package/core/ui/EditorToolbar/preview.tid +1 -0
- package/core/ui/EditorToolbar/size-dropdown.tid +6 -1
- package/core/ui/ExportTiddlyWikiCore.tid +15 -5
- package/core/ui/ImportListing.tid +23 -5
- package/core/ui/ImportPreviews/Fields.tid +1 -0
- package/core/ui/KeyboardShortcuts/advanced-search.tid +1 -0
- package/core/ui/KeyboardShortcuts/change-sidebar-layout.tid +4 -2
- package/core/ui/KeyboardShortcuts/new-image.tid +1 -0
- package/core/ui/KeyboardShortcuts/new-journal.tid +1 -0
- package/core/ui/KeyboardShortcuts/new-tiddler.tid +1 -0
- package/core/ui/KeyboardShortcuts/save-wiki.tid +1 -0
- package/core/ui/KeyboardShortcuts/toggle-sidebar.tid +4 -3
- package/core/ui/LayoutSwitcher.tid +16 -4
- package/core/ui/ListItemTemplate.tid +1 -3
- package/core/ui/ListTaggedCascade.tid +1 -0
- package/core/ui/Manager/ItemMainFields.tid +1 -0
- package/core/ui/Manager/ItemSidebarColour.tid +4 -1
- package/core/ui/Manager/ItemSidebarIcon.tid +4 -4
- package/core/ui/Manager/ItemSidebarTools.tid +7 -2
- package/core/ui/Manager.tid +11 -6
- package/core/ui/MissingTemplate.tid +1 -0
- package/core/ui/MoreSideBar/Types.tid +1 -0
- package/core/ui/PageControls/controlpanel.tid +1 -1
- package/core/ui/PageStylesheet.tid +1 -0
- package/core/ui/PageTemplate/story.tid +1 -1
- package/core/ui/PaletteManager.tid +11 -10
- package/core/ui/PluginInfo.tid +1 -0
- package/core/ui/PluginInfoDefaultContents.tid +1 -0
- package/core/ui/SearchResults.tid +8 -6
- package/core/ui/SideBar/More.tid +1 -0
- package/core/ui/SideBar/Open.tid +2 -2
- package/core/ui/SideBarSegments/search.tid +2 -0
- package/core/ui/SideBarSegments/tabs.tid +1 -1
- package/core/ui/TiddlerFieldTemplate.tid +1 -0
- package/core/ui/TiddlerFields.tid +1 -0
- package/core/ui/TiddlerInfo/Advanced/PluginInfo.tid +1 -0
- package/core/ui/TiddlerInfo/Advanced/ShadowInfo.tid +1 -0
- package/core/ui/TiddlerInfo/Advanced.tid +1 -0
- package/core/ui/TiddlerInfo.tid +1 -0
- package/core/ui/TopRightBar/menu.tid +1 -0
- package/core/ui/UntaggedTemplate.tid +1 -0
- package/core/ui/ViewTemplate/body/import.tid +6 -1
- package/core/ui/ViewTemplate/body/plugin.tid +1 -0
- package/core/ui/ViewTemplate/body/rendered-plain-text.tid +7 -0
- package/core/ui/ViewTemplate/body.tid +2 -0
- package/core/ui/ViewTemplate/classic.tid +1 -0
- package/core/ui/ViewTemplate/subtitle/modified.tid +4 -0
- package/core/ui/ViewTemplate/subtitle/modifier.tid +4 -0
- package/core/ui/ViewTemplate/subtitle.tid +6 -2
- package/core/ui/ViewTemplate/tags.tid +1 -0
- package/core/ui/ViewTemplate/title.tid +2 -0
- package/core/ui/ViewTemplate/unfold.tid +1 -0
- package/core/ui/ViewTemplate.tid +1 -1
- package/core/ui/ViewToolbar/new-here.tid +1 -0
- package/core/wiki/allfields.tid +8 -2
- package/core/wiki/config/OfficialPluginLibrary.tid +1 -1
- package/core/wiki/config/ViewTemplateBodyFilters.multids +2 -1
- package/core/wiki/currpalettepreview.tid +7 -2
- package/core/wiki/debugstylesheets.tid +1 -0
- package/core/wiki/download-wiki-button.tid +2 -1
- package/core/wiki/languageswitcher.tid +2 -0
- package/core/wiki/macros/colour-picker.tid +9 -2
- package/core/wiki/macros/copy-to-clipboard.tid +5 -2
- package/core/wiki/macros/diff.tid +4 -3
- package/core/wiki/macros/dumpvariables.tid +1 -0
- package/core/wiki/macros/image-picker.tid +5 -4
- package/core/wiki/macros/keyboard-driven-input.tid +22 -12
- package/core/wiki/macros/list.tid +7 -2
- package/core/wiki/macros/tabs.tid +55 -30
- package/core/wiki/macros/tag-picker.tid +14 -13
- package/core/wiki/macros/tag.tid +10 -5
- package/core/wiki/macros/thumbnails.tid +21 -9
- package/core/wiki/macros/timeline.tid +1 -0
- package/core/wiki/macros/toc.tid +19 -8
- package/core/wiki/macros/translink.tid +1 -0
- package/core/wiki/macros/tree.tid +8 -3
- package/core/wiki/minifocusswitcher.tid +1 -0
- package/core/wiki/minilanguageswitcher.tid +1 -0
- package/core/wiki/minithemeswitcher.tid +2 -1
- package/core/wiki/modules.tid +1 -0
- package/core/wiki/palettepreview.tid +1 -0
- package/core/wiki/paletteswitcher.tid +13 -2
- package/core/wiki/peek-stylesheets.tid +1 -5
- package/core/wiki/tags/ViewTemplateBodyFilter.tid +1 -1
- package/core/wiki/tags/ViewTemplateSubtitle.tid +2 -0
- package/core/wiki/themeswitcher.tid +10 -1
- package/core/wiki/title.tid +2 -1
- package/core/wiki/viewswitcher.tid +1 -0
- package/editions/de-AT/tiddlers/howto/TiddlyWiki und TiddlyDesktop.tid +1 -1
- package/editions/dev/tiddlers/_tw_shared/tiddlywiki.files +5 -0
- package/editions/dev/tiddlers/system/github-fork-ribbon.tid +1 -1
- package/editions/dev/tiddlywiki.info +1 -1
- package/editions/es-ES/tiddlers/TiddlyDesktop.tid +2 -2
- package/editions/fr-FR/tiddlers/Community Links Aggregator.tid +4 -4
- package/editions/fr-FR/tiddlers/Glossaire en-GB -_ fr-FR.tid +2 -1
- package/editions/fr-FR/tiddlers/community/editions/_Noteself_ by Danielo Rodr/303/255guez.tid" +34 -0
- package/editions/fr-FR/tiddlers/community/resources/TW5-firebase_ TiddlyWiki5 for Google Firebase by Peter Neumark.tid +28 -0
- package/editions/fr-FR/tiddlers/community/resources/TiddlyDrive Add-on for Google Drive by Joshua Stubbs.tid +24 -0
- package/editions/fr-FR/tiddlers/community/resources/TiddlyServer by Arlen Beiler.tid +35 -0
- package/editions/fr-FR/tiddlers/community/resources/Twexe_ Single File Tiddlywiki5 executable.tid +30 -0
- package/editions/fr-FR/tiddlers/community/resources/_Timimi_ Extension and executable by Riz.tid +33 -0
- package/editions/fr-FR/tiddlers/community/resources/_file-backups_ Extension for Firefox by pmario.tid +19 -0
- package/editions/fr-FR/tiddlers/community/resources/_savetiddlers_ Extension for Chrome and Firefox by buggyj.tid +17 -0
- package/editions/fr-FR/tiddlers/concepts/Pragma.tid +23 -0
- package/editions/fr-FR/tiddlers/{WikiText.tid → concepts/WikiText.tid} +6 -4
- package/editions/fr-FR/tiddlers/definitions/TiddlyDesktop.tid +19 -0
- package/editions/fr-FR/tiddlers/gettingstarted/GettingStarted - Internet Explorer.tid +11 -0
- package/editions/fr-FR/tiddlers/gettingstarted/GettingStarted - Safari.tid +12 -0
- package/editions/fr-FR/tiddlers/{A_Gentle_Guide_to_TiddlyWiki.tid → hellothere/A Gentle Guide to TiddlyWiki.tid } +6 -4
- package/editions/fr-FR/tiddlers/howtos/How to Customize TiddlyDesktop.tid +33 -0
- package/editions/fr-FR/tiddlers/howtos/Windows HTA Hack.tid +17 -0
- package/editions/fr-FR/tiddlers/nodejs/Installing TiddlyWiki on Node.js.tid +49 -0
- package/editions/fr-FR/tiddlers/nodejs/Serving TW5 from Android.tid +47 -0
- package/editions/fr-FR/tiddlers/nodejs/TiddlyWiki on Node.js.tid +18 -0
- package/editions/fr-FR/tiddlers/saving/Emergency Tiddler Export.tid +28 -0
- package/editions/fr-FR/tiddlers/saving/Example config-tiddlyweb-host for IIS.tid +9 -0
- package/editions/fr-FR/tiddlers/saving/Example package.json for IIS.tid +15 -0
- package/editions/fr-FR/tiddlers/saving/Example tiddlywiki.info for IIS.tid +18 -0
- package/editions/fr-FR/tiddlers/saving/Example web.config for IIS.tid +32 -0
- package/editions/fr-FR/tiddlers/saving/Installing TiddlyWiki on Microsoft Internet Information Server.tid +69 -0
- package/editions/fr-FR/tiddlers/saving/Saving on Android.tid +36 -0
- package/editions/fr-FR/tiddlers/saving/Saving on Beaker Browser.tid +35 -0
- package/editions/fr-FR/tiddlers/saving/Saving on Browser with File System Access API.tid +20 -0
- package/editions/fr-FR/tiddlers/saving/Saving on TidGi Desktop.tid +28 -0
- package/editions/fr-FR/tiddlers/saving/Saving on TiddlyDesktop.tid +20 -0
- package/editions/fr-FR/tiddlers/saving/Saving on TiddlyHost.tid +18 -0
- package/editions/fr-FR/tiddlers/{Saving on TiddlySpot.tid → saving/Saving on TiddlySpot.tid } +14 -3
- package/editions/fr-FR/tiddlers/saving/Saving on a PHP Server.tid +45 -0
- package/editions/fr-FR/tiddlers/saving/Saving on iPad_iPhone.tid +30 -0
- package/editions/fr-FR/tiddlers/saving/Saving to a Git service.tid +26 -0
- package/editions/fr-FR/tiddlers/saving/Saving via WebDAV.tid +88 -0
- package/editions/fr-FR/tiddlers/saving/Saving via a Minimal Ruby Server.tid +20 -0
- package/editions/fr-FR/tiddlers/saving/Saving with Polly.tid +30 -0
- package/editions/fr-FR/tiddlers/saving/Saving with TW Receiver.tid +16 -0
- package/editions/fr-FR/tiddlers/{Saving with TiddlyFox on Android.tid → saving/Saving with TiddlyFox on Android.tid } +5 -5
- package/editions/fr-FR/tiddlers/saving/Saving with TiddlyFox.tid +31 -0
- package/editions/fr-FR/tiddlers/saving/Saving with TiddlyIE.tid +25 -0
- package/editions/fr-FR/tiddlers/{Saving with the HTML5 fallback saver.tid → saving/Saving with the HTML5 fallback saver.tid } +11 -6
- package/editions/fr-FR/tiddlers/{Saving.tid → saving/Saving.tid} +8 -10
- package/editions/fr-FR/tiddlers/saving/TiddlyWiki Cloud.tid +17 -0
- package/editions/fr-FR/tiddlers/system/$__core_ui_SideBar_Open.tid +40 -0
- package/editions/fr-FR/tiddlers/{$__editions_fr-FR_util-macros.tid → system/$__editions_fr-FR_util-macros.tid} +4 -4
- package/editions/fr-FR/tiddlers/{$__editions_tw5.com_wikitext-macros.tid → system/$__editions_tw5.com_wikitext-macros.tid} +24 -3
- package/editions/fr-FR/tiddlers/system/tw5.com-card-template.tid +17 -0
- package/editions/fr-FR/tiddlers/tiddlydesktop/TiddlyDesktop_Releases.tid +9 -0
- package/editions/fr-FR/tiddlers/widgets/TranscludeWidget.tid +72 -0
- package/editions/fr-FR/tiddlers/{Block_Quotes_in_WikiText.tid → wikitext/Block Quotes in WikiText.tid } +3 -2
- package/editions/fr-FR/tiddlers/{Code Blocks in WikiText.tid → wikitext/Code Blocks in WikiText.tid } +3 -3
- package/editions/fr-FR/tiddlers/{Dashes in WikiText.tid → wikitext/Dashes in WikiText.tid } +3 -3
- package/editions/fr-FR/tiddlers/{Definitions_in_WikiText.tid → wikitext/Definitions in WikiText.tid } +2 -2
- package/editions/fr-FR/tiddlers/{Formatting in WikiText.tid → wikitext/Formatting in WikiText.tid } +5 -6
- package/editions/fr-FR/tiddlers/{Hard Linebreaks in WikiText.tid → wikitext/Hard Linebreaks in WikiText.tid } +6 -5
- package/editions/fr-FR/tiddlers/{Headings in WikiText.tid → wikitext/Headings in WikiText.tid } +4 -4
- package/editions/fr-FR/tiddlers/wikitext/Horizontal Rules in WikiText.tid +17 -0
- package/editions/fr-FR/tiddlers/{Lists_in_WikiText.tid → wikitext/Lists in WikiText.tid } +19 -19
- package/editions/fr-FR/tiddlers/wikitext/Macro Calls in WikiText.tid +27 -0
- package/editions/fr-FR/tiddlers/{Paragraphs in WikiText.tid → wikitext/Paragraphs in WikiText.tid } +8 -7
- package/editions/fr-FR/tiddlers/wikitext/Tables in WikiText.tid +69 -0
- package/editions/fr-FR/tiddlers/wikitext/Transclusion and Substitution.tid +61 -0
- package/editions/fr-FR/tiddlers/{Transclusion_in_WikiText.tid → wikitext/Transclusion in WikiText.tid } +14 -13
- package/editions/fr-FR/tiddlers/{Transclusion_with_Templates.tid → wikitext/Transclusion with Templates.tid } +2 -1
- package/editions/fr-FR/tiddlers/{Typed_Blocks_in_WikiText.tid → wikitext/Typed Blocks in WikiText.tid } +16 -11
- package/editions/fr-FR/tiddlers/{Variables_in_WikiText.tid → wikitext/Variables in WikiText.tid } +7 -8
- package/editions/fr-FR/tiddlers/wikitext/Widgets in WikiText.tid +30 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/Block Mode WikiText (Examples).tid +52 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/Block Mode WikiText.tid +37 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/Inline Mode WikiText.tid +28 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/Places where the parser ignores WikiText.tid +14 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/WikiText Parser Modes.tid +17 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode HTML examples.tid +73 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode transitions.tid +59 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode_ macro examples.tid +56 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode_ transclusion examples.tid +56 -0
- package/editions/fr-FR/tiddlers/wikitext/parser/table-example.tid +8 -0
- package/editions/katexdemo/tiddlers/$__DefaultTiddlers.tid +8 -0
- package/editions/katexdemo/tiddlers/HelloThere.tid +4 -1
- package/editions/katexdemo/tiddlers/LaTeX.tid +8 -0
- package/editions/katexdemo/tiddlers/TiddlyWiki.tid +8 -0
- package/editions/katexdemo/tiddlers/TiddlyWiki5.tid +6 -0
- package/editions/prerelease/tiddlers/{Release 5.2.3.tid → Release 5.2.4.tid } +16 -15
- package/editions/prerelease/tiddlers/system/PrereleaseLocalPluginLibrary.tid +1 -1
- package/editions/prerelease/tiddlers/system/PrereleaseOfficialPluginLibrary.tid +1 -1
- package/editions/prerelease/tiddlers/system/TiddlyWiki Pre-release.tid +4 -1
- package/editions/prerelease/tiddlywiki.info +0 -2
- package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-horizontal-all.tid +1 -29
- package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-horizontal.tid +1 -39
- package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-vertical.tid +1 -39
- package/editions/test/tiddlers/tests/test-action-widgets.js +43 -0
- package/editions/test/tiddlers/tests/test-checkbox-widget.js +507 -0
- package/editions/test/tiddlers/tests/test-filters.js +49 -2
- package/editions/test/tiddlers/tests/test-prefixes-filter.js +2 -0
- package/editions/test/tiddlers/tests/test-utils.js +6 -0
- package/editions/test/tiddlers/tests/test-widget.js +2 -1
- package/editions/test/tiddlers/tests/test-wikitext-tabs-macro.js +8 -7
- package/editions/test/tiddlers/tests/test-wikitext.js +8 -1
- package/editions/translators/tiddlywiki.info +7 -1
- package/editions/tw.org/tiddlers/$__config_DefaultSidebarTab.tid +6 -0
- package/editions/tw.org/tiddlers/$__core_templates_static.content.tid +18 -0
- package/editions/tw.org/tiddlers/Code of Conduct.tid +30 -0
- package/editions/tw.org/tiddlers/Fundraising.tid +23 -0
- package/editions/tw.org/tiddlers/HelloThere.tid +3 -2
- package/editions/tw.org/tiddlers/Table of Contents.tid +2 -1
- package/editions/tw.org/tiddlers/_tw_shared/tiddlywiki.files +5 -0
- package/editions/tw5.com/tiddlers/$__StoryList.tid +3 -3
- package/editions/tw5.com/tiddlers/Brackets.tid +14 -0
- package/editions/tw5.com/tiddlers/{images → _tw_shared}/Motovun Jack.svg +0 -0
- package/editions/tw5.com/tiddlers/{images → _tw_shared}/Motovun Jack.svg.meta +1 -1
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/classic.tiddlywiki.com.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/classic.tiddlywiki.com.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/links.tiddlywiki.org.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/links.tiddlywiki.org.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/talk.tiddlywiki.org.svg +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/talk.tiddlywiki.org.svg.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.dev.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.dev.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.prerelease.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.prerelease.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.upgrade.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.upgrade.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.org.ico +0 -0
- package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.org.ico.meta +3 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/classic.tiddlywiki.com.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/links.tiddlywiki.org.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/talk.tiddlywiki.org.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.dev.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.prerelease.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.upgrade.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.org.tid +6 -0
- package/editions/tw5.com/tiddlers/_tw_shared/sites.tid +32 -0
- package/editions/tw5.com/tiddlers/_tw_shared/styles.tid +48 -0
- package/editions/tw5.com/tiddlers/_tw_shared/tags-TiddlyWikiSites.tid +3 -0
- package/editions/tw5.com/tiddlers/community/Community Links Aggregator.tid +1 -1
- package/editions/tw5.com/tiddlers/community/Contributing.tid +2 -1
- package/editions/tw5.com/tiddlers/community/editions/TiddlyMemo by oflg.tid +16 -0
- package/editions/tw5.com/tiddlers/community/resources/Projectify by Nicolas Petton.tid +6 -4
- package/editions/tw5.com/tiddlers/concepts/Customizing EditTemplate Field Rendering.tid +23 -7
- package/editions/tw5.com/tiddlers/concepts/DataTiddlers.tid +4 -21
- package/editions/tw5.com/tiddlers/concepts/DictionaryTiddlers.tid +3 -2
- package/editions/tw5.com/tiddlers/concepts/JSONTiddlers.tid +4 -3
- package/editions/tw5.com/tiddlers/concepts/KeyboardShortcutTiddler.tid +7 -0
- package/editions/tw5.com/tiddlers/concepts/Macros.tid +6 -2
- package/editions/tw5.com/tiddlers/concepts/Order of Tagged Tiddlers.tid +3 -1
- package/editions/tw5.com/tiddlers/concepts/SystemTags.tid +1 -1
- package/editions/tw5.com/tiddlers/concepts/TiddlyWiki5.tid +4 -2
- package/editions/tw5.com/tiddlers/concepts/Title List.tid +4 -1
- package/editions/tw5.com/tiddlers/customising/Customising TiddlyWiki's user interface.tid +2 -2
- package/editions/tw5.com/tiddlers/definitions/JavaScript Object Notation.tid +2 -6
- package/editions/tw5.com/tiddlers/definitions/Node.js.tid +5 -3
- package/editions/tw5.com/tiddlers/definitions/TiddlyDesktop.tid +1 -1
- package/editions/tw5.com/tiddlers/definitions/TiddlyWeb.tid +1 -0
- package/editions/tw5.com/tiddlers/demonstrations/CustomStoryTiddlerTemplateDemo.tid/Styles.tid +0 -1
- package/editions/tw5.com/tiddlers/features/JSON in TiddlyWiki.tid +69 -0
- package/editions/tw5.com/tiddlers/filters/Mathematics Operators.tid +23 -3
- package/editions/tw5.com/tiddlers/filters/examples/insertafter Operator (Examples).tid +28 -0
- package/editions/tw5.com/tiddlers/filters/format.tid +3 -1
- package/editions/tw5.com/tiddlers/filters/insertafter Operator.tid +35 -0
- package/editions/tw5.com/tiddlers/filters/insertbefore Operator.tid +9 -3
- package/editions/tw5.com/tiddlers/filters/syntax/Map Filter Run Prefix (Examples).tid +20 -2
- package/editions/tw5.com/tiddlers/filters/syntax/Map Filter Run Prefix.tid +3 -2
- package/editions/tw5.com/tiddlers/gettingstarted/GettingStarted.tid +6 -0
- package/editions/tw5.com/tiddlers/hellothere/HelloThere.tid +1 -1
- package/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid +16 -0
- package/editions/tw5.com/tiddlers/howtos/Creating a splash screen.tid +1 -1
- package/editions/tw5.com/tiddlers/howtos/How to apply custom styles by tag.tid +2 -2
- package/editions/tw5.com/tiddlers/howtos/How to customize TiddlyDesktop.tid +1 -1
- package/editions/tw5.com/tiddlers/howtos/How to update TiddlyWiki to the latest version.tid +7 -0
- package/editions/tw5.com/tiddlers/howtos/Modifying JSON tiddlers.tid +18 -0
- package/editions/tw5.com/tiddlers/howtos/Reading data from JSON tiddlers.tid +25 -0
- package/editions/tw5.com/tiddlers/images/New Release Banner.png +0 -0
- package/editions/tw5.com/tiddlers/macros/JsonTiddlersMacro.tid +3 -3
- package/editions/tw5.com/tiddlers/macros/TagMacro.tid +1 -1
- package/editions/tw5.com/tiddlers/macros/jsontiddler Macro.tid +2 -2
- package/editions/tw5.com/tiddlers/macros/list-links-draggable Macro.tid +2 -0
- package/editions/tw5.com/tiddlers/mechanisms/InfoMechanism.tid +1 -0
- package/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid +1 -1
- package/editions/tw5.com/tiddlers/messages/WidgetMessage_ tm-close-window.tid +3 -1
- package/editions/tw5.com/tiddlers/messages/WidgetMessage_ tm-new-tiddler.tid +11 -2
- package/editions/tw5.com/tiddlers/nodejs/Environment Variables on Node.js.tid +5 -5
- package/editions/tw5.com/tiddlers/nodejs/Installing TiddlyWiki on Node.js.tid +5 -10
- package/editions/tw5.com/tiddlers/nodejs/Installing custom plugins on Node.js.tid +11 -19
- package/editions/tw5.com/tiddlers/nodejs/Installing official plugins on Node.js.tid +40 -0
- package/editions/tw5.com/tiddlers/nodejs/PluginsCS.tid +9 -0
- package/editions/tw5.com/tiddlers/nodejs/TiddlyWiki on Node.js.tid +7 -2
- package/editions/tw5.com/tiddlers/nodejs/Uninstalling a plugin with Node.js.tid +31 -0
- package/editions/tw5.com/tiddlers/nodejs/Using TiddlyWiki on Node.js.tid +4 -4
- package/editions/tw5.com/tiddlers/platforms/TiddlyWiki in the Sky for TiddlyWeb.tid +2 -1
- package/editions/tw5.com/tiddlers/plugins/Installing a plugin from the plugin library.tid +22 -35
- package/editions/tw5.com/tiddlers/plugins/Manually installing a plugin.tid +19 -4
- package/editions/tw5.com/tiddlers/plugins/OfficialPlugins.tid +3 -1
- package/editions/tw5.com/tiddlers/plugins/Plugin Ordering.tid +47 -0
- package/editions/tw5.com/tiddlers/plugins/PluginFolders.tid +27 -1
- package/editions/tw5.com/tiddlers/plugins/Plugins.tid +19 -7
- package/editions/tw5.com/tiddlers/plugins/Uninstalling a plugin.tid +15 -25
- package/editions/tw5.com/tiddlers/releasenotes/Release 5.1.23.tid +32 -34
- package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.0.tid +36 -38
- package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.1.tid +16 -18
- package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.2.tid +26 -28
- package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.3.tid +152 -0
- package/editions/tw5.com/tiddlers/releasenotes/Releases.tid +1 -1
- package/editions/tw5.com/tiddlers/saving/Saving on Android.tid +1 -1
- package/editions/tw5.com/tiddlers/saving/Saving on TidGi.tid +1 -1
- package/editions/tw5.com/tiddlers/saving/Saving on TiddlyDesktop.tid +3 -3
- package/editions/tw5.com/tiddlers/saving/Saving on iPad_iPhone.tid +1 -1
- package/editions/tw5.com/tiddlers/saving/Saving via WebDAV.tid +5 -3
- package/editions/tw5.com/tiddlers/saving/Saving.tid +9 -11
- package/editions/tw5.com/tiddlers/system/Deprecated.tid +4 -4
- package/editions/tw5.com/tiddlers/system/Deprecated_-_What_does_it_mean.tid +2 -6
- package/editions/tw5.com/tiddlers/system/doc-macros.tid +11 -1
- package/editions/tw5.com/tiddlers/system/doc-styles.tid +34 -4
- package/editions/tw5.com/tiddlers/system/download-empty-button.tid +1 -1
- package/editions/tw5.com/tiddlers/system/systemtag-template.tid +21 -0
- package/editions/tw5.com/tiddlers/system/tw5.com-card-template.tid +12 -8
- package/editions/tw5.com/tiddlers/system/tw5.com-styles.tid +5 -6
- package/editions/tw5.com/tiddlers/system/version-macros.tid +3 -3
- package/editions/tw5.com/tiddlers/system/wikitext-macros.tid +38 -3
- package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Macro_View_Body.tid +9 -0
- package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_ViewTemplate.tid +2 -2
- package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_ViewTemplateSubtitle.tid +9 -0
- package/editions/tw5.com/tiddlers/tiddlydesktop/TiddlyDesktop_Releases.tid +1 -1
- package/editions/tw5.com/tiddlers/variables/modifier Variable.tid +2 -2
- package/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid +77 -3
- package/editions/tw5.com/tiddlers/widgets/DraggableWidget.tid +19 -3
- package/editions/tw5.com/tiddlers/widgets/EventCatcherWidget.tid +3 -1
- package/editions/tw5.com/tiddlers/widgets/ImageWidget.tid +5 -3
- package/editions/tw5.com/tiddlers/widgets/JSONTiddlerWidget.tid +5 -4
- package/editions/tw5.com/tiddlers/widgets/ListWidget.tid +2 -2
- package/editions/tw5.com/tiddlers/widgets/ScrollableWidget.tid +3 -3
- package/editions/tw5.com/tiddlers/widgets/SetWidget.tid +3 -1
- package/editions/tw5.com/tiddlers/widgets/TranscludeWidget.tid +2 -5
- package/editions/tw5.com/tiddlers/wikitext/Code Blocks in WikiText.tid +4 -7
- package/editions/tw5.com/tiddlers/wikitext/Dashes in WikiText.tid +7 -3
- package/editions/tw5.com/tiddlers/wikitext/Formatting in WikiText.tid +7 -7
- package/editions/tw5.com/tiddlers/wikitext/Headings in WikiText.tid +3 -3
- package/editions/tw5.com/tiddlers/wikitext/Horizontal Rules in WikiText.tid +3 -5
- package/editions/tw5.com/tiddlers/wikitext/Tables in WikiText.tid +13 -37
- package/editions/tw5.com/tiddlers/wikitext/Widgets in WikiText.tid +4 -4
- package/editions/tw5.com/tiddlers/wikitext/parser/WikiText Parser Modes.tid +1 -1
- package/languages/de-DE/EditTemplate.multids +1 -0
- package/languages/de-DE/Help/render.tid +2 -1
- package/languages/de-DE/SideBar.multids +1 -0
- package/languages/fr-FR/ControlPanel.multids +18 -0
- package/languages/fr-FR/EditTemplate.multids +1 -0
- package/languages/fr-FR/Fields.multids +4 -2
- package/languages/fr-FR/Help/default.tid +4 -1
- package/languages/fr-FR/Help/render.tid +2 -1
- package/languages/fr-FR/Misc.multids +1 -1
- package/languages/fr-FR/SideBar.multids +1 -0
- package/languages/ja-JP/Buttons.multids +147 -30
- package/languages/ja-JP/ControlPanel.multids +175 -37
- package/languages/ja-JP/CoreReadMe.tid +2 -2
- package/languages/ja-JP/Dates.multids +24 -24
- package/languages/ja-JP/Docs/ModuleTypes.multids +3 -3
- package/languages/ja-JP/Docs/PaletteColours.multids +18 -18
- package/languages/ja-JP/EditTemplate.multids +23 -7
- package/languages/ja-JP/Exporters.multids +1 -1
- package/languages/ja-JP/Fields.multids +28 -23
- package/languages/ja-JP/Filters.multids +12 -9
- package/languages/ja-JP/GettingStarted.tid +6 -6
- package/languages/ja-JP/Help/build.tid +2 -2
- package/languages/ja-JP/Help/editions.tid +6 -2
- package/languages/ja-JP/Help/help.tid +1 -1
- package/languages/ja-JP/Help/init.tid +2 -2
- package/languages/ja-JP/Help/load.tid +2 -2
- package/languages/ja-JP/Help/makelibrary.tid +3 -3
- package/languages/ja-JP/Help/output.tid +2 -2
- package/languages/ja-JP/Help/rendertiddler.tid +2 -2
- package/languages/ja-JP/Help/rendertiddlers.tid +2 -2
- package/languages/ja-JP/Help/savetiddler.tid +2 -2
- package/languages/ja-JP/Help/savetiddlers.tid +12 -2
- package/languages/ja-JP/Help/server.tid +6 -6
- package/languages/ja-JP/Help/setfield.tid +7 -7
- package/languages/ja-JP/Help/unpackplugin.tid +2 -2
- package/languages/ja-JP/Help/verbose.tid +6 -2
- package/languages/ja-JP/Help/version.tid +2 -2
- package/languages/ja-JP/Import.multids +27 -8
- package/languages/ja-JP/Misc.multids +98 -11
- package/languages/ja-JP/Modals/Download.tid +2 -2
- package/languages/ja-JP/Notifications.multids +2 -2
- package/languages/ja-JP/Search.multids +8 -4
- package/languages/ja-JP/SideBar.multids +6 -4
- package/languages/ja-JP/SiteSubtitle.tid +1 -1
- package/languages/ja-JP/SiteTitle.tid +1 -1
- package/languages/ja-JP/TiddlerInfo.multids +10 -10
- package/languages/ja-JP/Types/application%2Fjavascript.tid +1 -1
- package/languages/ja-JP/Types/image%2Fgif.tid +1 -1
- package/languages/ja-JP/Types/image%2Fjpeg.tid +1 -1
- package/languages/ja-JP/Types/image%2Fpng.tid +1 -1
- package/languages/ja-JP/Types/image%2Fsvg%2Bxml.tid +1 -1
- package/languages/ja-JP/Types/image%2Fx-icon.tid +1 -1
- package/languages/ja-JP/Types/text%2Fcss.tid +1 -1
- package/languages/ja-JP/Types/text%2Fvnd.tiddlywiki.tid +1 -1
- package/languages/ja-JP/plugin.info +1 -1
- package/languages/pl-PL/ControlPanel.multids +3 -1
- package/languages/pl-PL/EditTemplate.multids +1 -0
- package/languages/pl-PL/Fields.multids +3 -3
- package/languages/pl-PL/Help/default.tid +4 -1
- package/languages/pl-PL/Import.multids +3 -3
- package/languages/pl-PL/SideBar.multids +1 -0
- package/languages/zh-Hans/EditTemplate.multids +1 -0
- package/languages/zh-Hans/Help/default.tid +4 -1
- package/languages/zh-Hans/Help/render.tid +1 -0
- package/languages/zh-Hans/SideBar.multids +1 -0
- package/languages/zh-Hant/EditTemplate.multids +1 -0
- package/languages/zh-Hant/Help/default.tid +4 -1
- package/languages/zh-Hant/Help/render.tid +1 -0
- package/languages/zh-Hant/SideBar.multids +1 -0
- package/licenses/cla-individual.md +10 -0
- package/package.json +1 -1
- package/plugins/tiddlywiki/browser-sniff/browser.js +5 -1
- package/plugins/tiddlywiki/browser-sniff/usage.tid +1 -0
- package/plugins/tiddlywiki/browser-storage/rawmarkup.js +18 -1
- package/plugins/tiddlywiki/browser-storage/readme.tid +0 -1
- package/plugins/tiddlywiki/browser-storage/settings.tid +5 -1
- package/plugins/tiddlywiki/browser-storage/startup.js +14 -9
- package/plugins/tiddlywiki/dynannotate/docs/readme.tid +72 -8
- package/plugins/tiddlywiki/dynannotate/modules/dynannotate.js +10 -1
- package/plugins/tiddlywiki/dynannotate/modules/legacy-selection-tracker.js +104 -0
- package/plugins/tiddlywiki/dynannotate/modules/selection-tracker.js +144 -89
- package/plugins/tiddlywiki/dynannotate/modules/startup.js +40 -0
- package/{editions/katexdemo/tiddlers → plugins/tiddlywiki/katex}/ImplementationNotes.tid +3 -3
- package/plugins/tiddlywiki/katex/developer.tid +58 -0
- package/plugins/tiddlywiki/katex/files/contrib/mhchem.min.js +1 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.woff +0 -0
- package/plugins/tiddlywiki/katex/files/katex.min.css +1 -1
- package/plugins/tiddlywiki/katex/files/katex.min.js +1 -1
- package/plugins/tiddlywiki/katex/files/katex.without-font-face.min.css +1 -1
- package/plugins/tiddlywiki/katex/files/tiddlywiki.files +2 -2
- package/plugins/tiddlywiki/katex/plugin.info +1 -1
- package/plugins/tiddlywiki/katex/readme.tid +1 -1
- package/plugins/tiddlywiki/katex/snippets/logo.tid +4 -0
- package/plugins/tiddlywiki/katex/snippets/math.tid +8 -0
- package/plugins/tiddlywiki/katex/styles.tid +7 -0
- package/plugins/tiddlywiki/katex/usage.tid +18 -2
- package/plugins/tiddlywiki/markdown/EditorToolbar/link-dropdown.tid +73 -0
- package/plugins/tiddlywiki/markdown/EditorToolbar/link.tid +11 -0
- package/plugins/tiddlywiki/markdown/EditorToolbar/linkify.tid +15 -0
- package/plugins/tiddlywiki/markdown/EditorToolbar/mono-block.tid +17 -0
- package/plugins/tiddlywiki/markdown/KeyboardShortcuts/new-markdown-tiddler.tid +8 -0
- package/plugins/tiddlywiki/markdown/config.multids +5 -0
- package/plugins/tiddlywiki/markdown/editor-operations/make-markdown-link.js +37 -0
- package/plugins/tiddlywiki/markdown/images/markdown-linkify.tid +6 -0
- package/plugins/tiddlywiki/menubar/items/search.tid +2 -0
- package/plugins/tiddlywiki/tiddlyweb/save-wiki-button.tid +1 -1
- package/readme.md +5 -3
- package/themes/tiddlywiki/vanilla/base.tid +21 -3
- package/.github/ISSUE_TEMPLATE/bug_report.md +0 -43
- package/editions/fr-FR/tiddlers/$__core_ui_SideBar_Open.tid +0 -15
- package/editions/fr-FR/tiddlers/Horizontal Rules in WikiText.tid +0 -17
- package/editions/fr-FR/tiddlers/Installing TiddlyWiki on Node.js.tid +0 -23
- package/editions/fr-FR/tiddlers/Macro_Calls_in_WikiText.tid +0 -22
- package/editions/fr-FR/tiddlers/Pragma.tid +0 -17
- package/editions/fr-FR/tiddlers/Saving on Android.tid +0 -10
- package/editions/fr-FR/tiddlers/Saving on InternetExplorer.tid +0 -11
- package/editions/fr-FR/tiddlers/Saving on Safari.tid +0 -24
- package/editions/fr-FR/tiddlers/Saving on iPad_iPhone.tid +0 -23
- package/editions/fr-FR/tiddlers/Saving with TiddlyFox.tid +0 -24
- package/editions/fr-FR/tiddlers/Saving with TiddlyIE.tid +0 -19
- package/editions/fr-FR/tiddlers/Saving_on_a_PHP_Server.tid +0 -30
- package/editions/fr-FR/tiddlers/Tables_in_WikiText.tid +0 -102
- package/editions/fr-FR/tiddlers/TiddlyDesktop.tid +0 -23
- package/editions/fr-FR/tiddlers/TiddlyDesktop_Releases.tid +0 -9
- package/editions/fr-FR/tiddlers/TiddlyWiki on Node.js.tid +0 -18
- package/editions/fr-FR/tiddlers/TranscludeWidget.tid +0 -73
- package/editions/fr-FR/tiddlers/Widgets_in_WikiText.tid +0 -30
- package/editions/katexdemo/tiddlers/DefaultTiddlers.tid +0 -5
- package/plugins/tiddlywiki/katex/files/README.md +0 -119
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
- package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
- package/plugins/tiddlywiki/katex/files/katex.css +0 -1079
- package/plugins/tiddlywiki/katex/files/katex.js +0 -18183
- package/plugins/tiddlywiki/katex/files/mhchem.min.js +0 -1
@@ -0,0 +1,507 @@
|
|
1
|
+
/*\
|
2
|
+
title: testcheckbox-widget.js
|
3
|
+
type: application/javascript
|
4
|
+
tags: [[$:/tags/test-spec]]
|
5
|
+
|
6
|
+
Tests the checkbox widget thoroughly.
|
7
|
+
|
8
|
+
\*/
|
9
|
+
(function(){
|
10
|
+
|
11
|
+
/*jslint node: true, browser: true */
|
12
|
+
/*global $tw: false */
|
13
|
+
"use strict";
|
14
|
+
|
15
|
+
describe("Checkbox widget", function() {
|
16
|
+
|
17
|
+
var widget = require("$:/core/modules/widgets/widget.js");
|
18
|
+
|
19
|
+
function createWidgetNode(parseTreeNode,wiki) {
|
20
|
+
return new widget.widget(parseTreeNode,{
|
21
|
+
wiki: wiki,
|
22
|
+
document: $tw.fakeDocument
|
23
|
+
});
|
24
|
+
}
|
25
|
+
|
26
|
+
function parseText(text,wiki,options) {
|
27
|
+
var parser = wiki.parseText("text/vnd.tiddlywiki",text,options);
|
28
|
+
return parser ? {type: "widget", children: parser.tree} : undefined;
|
29
|
+
}
|
30
|
+
|
31
|
+
function renderWidgetNode(widgetNode) {
|
32
|
+
$tw.fakeDocument.setSequenceNumber(0);
|
33
|
+
var wrapper = $tw.fakeDocument.createElement("div");
|
34
|
+
widgetNode.render(wrapper,null);
|
35
|
+
return wrapper;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Find a particular type of node from inside the widget tree
|
39
|
+
// Less brittle than wrapper.children[0].children[0] if the parse
|
40
|
+
// tree ever changes in the future
|
41
|
+
function findNodeOfType(targetType, currentNode) {
|
42
|
+
if(currentNode.parseTreeNode && currentNode.parseTreeNode.type === targetType) {
|
43
|
+
return currentNode;
|
44
|
+
} else if(currentNode.children && currentNode.children.length) {
|
45
|
+
var child, result, i;
|
46
|
+
for (i = 0; i < currentNode.children.length; i++) {
|
47
|
+
child = currentNode.children[i];
|
48
|
+
result = findNodeOfType(targetType, child);
|
49
|
+
if(result) return result;
|
50
|
+
}
|
51
|
+
}
|
52
|
+
return undefined;
|
53
|
+
}
|
54
|
+
|
55
|
+
/*
|
56
|
+
* Test data for checkbox widget tests
|
57
|
+
*/
|
58
|
+
|
59
|
+
const fieldModeTests = [
|
60
|
+
{
|
61
|
+
testName: "field mode checked",
|
62
|
+
tiddlers: [{title: "TiddlerOne", text: "Jolly Old World", expand: "yes"}],
|
63
|
+
widgetText: "<$checkbox tiddler='TiddlerOne' field='expand' checked='yes' />",
|
64
|
+
startsOutChecked: true,
|
65
|
+
expectedChange: { "TiddlerOne": { expand: undefined } }
|
66
|
+
},
|
67
|
+
{
|
68
|
+
testName: "field mode unchecked",
|
69
|
+
tiddlers: [{title: "TiddlerOne", text: "Jolly Old World", expand: "no"}],
|
70
|
+
widgetText: "<$checkbox tiddler='TiddlerOne' field='expand' unchecked='no' />",
|
71
|
+
startsOutChecked: false,
|
72
|
+
expectedChange: { "TiddlerOne": { expand: undefined } }
|
73
|
+
},
|
74
|
+
{
|
75
|
+
testName: "field mode toggle",
|
76
|
+
tiddlers: [{title: "TiddlerOne", text: "Jolly Old World", expand: "no"}],
|
77
|
+
widgetText: "<$checkbox tiddler='TiddlerOne' field='expand' checked='yes' unchecked='no' />",
|
78
|
+
startsOutChecked: false,
|
79
|
+
expectedChange: { "TiddlerOne": { expand: "yes" } }
|
80
|
+
},
|
81
|
+
{
|
82
|
+
testName: "field mode indeterminate -> true",
|
83
|
+
tiddlers: [{title: "TiddlerOne", text: "Jolly Old World", expand: "some other value"}],
|
84
|
+
widgetText: "<$checkbox tiddler='TiddlerOne' field='expand' indeterminate='yes' checked='yes' unchecked='no' />",
|
85
|
+
startsOutChecked: undefined,
|
86
|
+
expectedChange: { "TiddlerOne": { expand: "yes" } }
|
87
|
+
},
|
88
|
+
// true -> indeterminate cannot happen in field mode
|
89
|
+
{
|
90
|
+
testName: "field mode not indeterminate",
|
91
|
+
tiddlers: [{title: "TiddlerOne", text: "Jolly Old World", expand: "some other value"}],
|
92
|
+
widgetText: "<$checkbox tiddler='TiddlerOne' field='expand' indeterminate='' checked='yes' unchecked='no' />",
|
93
|
+
startsOutChecked: false,
|
94
|
+
expectedChange: { "TiddlerOne": { expand: "yes" } }
|
95
|
+
},
|
96
|
+
];
|
97
|
+
|
98
|
+
const indexModeTests = fieldModeTests.map(data => {
|
99
|
+
const newData = {...data};
|
100
|
+
const newName = data.testName.replace('field mode', 'index mode');
|
101
|
+
const newTiddlers = data.tiddlers.map(tiddler => {
|
102
|
+
return {title: tiddler.title, type: "application/x-tiddler-dictionary", text: `one: a\nexpand: ${tiddler.expand}\ntwo: b`}
|
103
|
+
});
|
104
|
+
const newWidgetText = data.widgetText.replace("field='expand'", "index='expand'");
|
105
|
+
const newChange = {};
|
106
|
+
for (const key of Object.keys(data.expectedChange)) {
|
107
|
+
const oldChange = data.expectedChange[key];
|
108
|
+
if (oldChange.expand) {
|
109
|
+
newChange[key] = { text: `one: a\nexpand: ${oldChange.expand}\ntwo: b` }
|
110
|
+
} else {
|
111
|
+
// In index tiddlers, the "expand" field gets completely removed, not turned into "expand: (undefined)"
|
112
|
+
newChange[key] = { text: `one: a\ntwo: b` }
|
113
|
+
}
|
114
|
+
}
|
115
|
+
newData.testName = newName;
|
116
|
+
newData.tiddlers = newTiddlers;
|
117
|
+
newData.widgetText = newWidgetText;
|
118
|
+
newData.expectedChange = newChange;
|
119
|
+
return newData;
|
120
|
+
});
|
121
|
+
|
122
|
+
const listModeTests = [
|
123
|
+
{
|
124
|
+
testName: "list mode add",
|
125
|
+
tiddlers: [{title: "Colors", colors: "orange yellow"}],
|
126
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' checked='green' />",
|
127
|
+
startsOutChecked: false,
|
128
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
129
|
+
},
|
130
|
+
{
|
131
|
+
testName: "list mode remove",
|
132
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
133
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' checked='green' />",
|
134
|
+
startsOutChecked: true,
|
135
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
136
|
+
},
|
137
|
+
{
|
138
|
+
testName: "list mode remove inverted",
|
139
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
140
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' />",
|
141
|
+
startsOutChecked: false,
|
142
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
143
|
+
},
|
144
|
+
{
|
145
|
+
testName: "list mode remove in middle position",
|
146
|
+
tiddlers: [{title: "Colors", colors: "orange green yellow"}],
|
147
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' checked='green' />",
|
148
|
+
startsOutChecked: true,
|
149
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
150
|
+
},
|
151
|
+
{
|
152
|
+
testName: "list mode remove in middle position inverted",
|
153
|
+
tiddlers: [{title: "Colors", colors: "orange red yellow"}],
|
154
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' />",
|
155
|
+
startsOutChecked: false,
|
156
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
157
|
+
},
|
158
|
+
{
|
159
|
+
testName: "list mode remove in final position",
|
160
|
+
tiddlers: [{title: "Colors", colors: "orange yellow green"}],
|
161
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' checked='green' />",
|
162
|
+
startsOutChecked: true,
|
163
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
164
|
+
},
|
165
|
+
{
|
166
|
+
testName: "list mode remove in final position inverted",
|
167
|
+
tiddlers: [{title: "Colors", colors: "orange yellow red"}],
|
168
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' />",
|
169
|
+
startsOutChecked: false,
|
170
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
171
|
+
},
|
172
|
+
{
|
173
|
+
testName: "list mode toggle",
|
174
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
175
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' checked='green' />",
|
176
|
+
startsOutChecked: false,
|
177
|
+
expectedChange: { "Colors": { colors: "green orange yellow" } }
|
178
|
+
},
|
179
|
+
{
|
180
|
+
testName: "list mode toggle in middle position",
|
181
|
+
tiddlers: [{title: "Colors", colors: "orange red yellow"}],
|
182
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' checked='green' />",
|
183
|
+
startsOutChecked: false,
|
184
|
+
expectedChange: { "Colors": { colors: "orange green yellow" } }
|
185
|
+
},
|
186
|
+
{
|
187
|
+
testName: "list mode remove in final position",
|
188
|
+
tiddlers: [{title: "Colors", colors: "orange yellow red"}],
|
189
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' checked='green' />",
|
190
|
+
startsOutChecked: false,
|
191
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
192
|
+
},
|
193
|
+
{
|
194
|
+
testName: "list mode neither checked nor unchecked specified: field value remains unchanged",
|
195
|
+
tiddlers: [{title: "Colors", colors: "orange yellow red"}],
|
196
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' />",
|
197
|
+
startsOutChecked: true,
|
198
|
+
finalValue: true,
|
199
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
200
|
+
},
|
201
|
+
{
|
202
|
+
testName: "list mode neither checked nor unchecked specified, but actions specified to change field value",
|
203
|
+
tiddlers: [{title: "ExampleTiddler", someField: "yes"}],
|
204
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='ExampleTiddler' $field='someField' $filter='yes'/>\n" +
|
205
|
+
"\\define uncheckActions() <$action-listops $tiddler='ExampleTiddler' $field='someField' $filter='-yes'/>\n" +
|
206
|
+
"<$checkbox tiddler='ExampleTiddler' listField='someField' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
207
|
+
startsOutChecked: true,
|
208
|
+
expectedChange: { "ExampleTiddler": { someField: "" } }
|
209
|
+
},
|
210
|
+
{
|
211
|
+
testName: "list mode neither checked nor unchecked specified, means field value is treated as empty=false, nonempty=true",
|
212
|
+
tiddlers: [{title: "ExampleTiddler", someField: "yes"}],
|
213
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='ExampleTiddler' $field='someField' $filter='yes -no'/>\n" +
|
214
|
+
"\\define uncheckActions() <$action-listops $tiddler='ExampleTiddler' $field='someField' $filter='-yes no'/>\n" +
|
215
|
+
"<$checkbox tiddler='ExampleTiddler' listField='someField' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
216
|
+
startsOutChecked: true,
|
217
|
+
finalValue: true, // "no" is considered true when neither `checked` nor `unchecked` is specified
|
218
|
+
expectedChange: { "ExampleTiddler": { someField: "no" } }
|
219
|
+
},
|
220
|
+
{
|
221
|
+
testName: "list mode indeterminate -> true",
|
222
|
+
tiddlers: [{title: "Colors", colors: "orange"}],
|
223
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' indeterminate='yes' unchecked='red' checked='green' />",
|
224
|
+
startsOutChecked: undefined,
|
225
|
+
expectedChange: { "Colors": { colors: "orange green" } }
|
226
|
+
},
|
227
|
+
// true -> indeterminate cannot happen in list mode
|
228
|
+
{
|
229
|
+
testName: "list mode not indeterminate",
|
230
|
+
tiddlers: [{title: "Colors", colors: "orange"}],
|
231
|
+
widgetText: "<$checkbox tiddler='Colors' listField='colors' unchecked='red' checked='green' />",
|
232
|
+
startsOutChecked: false,
|
233
|
+
expectedChange: { "Colors": { colors: "orange green" } }
|
234
|
+
},
|
235
|
+
];
|
236
|
+
|
237
|
+
const indexListModeTests = listModeTests.map(data => {
|
238
|
+
const newData = {...data};
|
239
|
+
const newName = data.testName.replace('list mode', 'index list mode');
|
240
|
+
const newTiddlers = data.tiddlers.map(tiddler => {
|
241
|
+
if (tiddler.hasOwnProperty('colors')) {
|
242
|
+
return {title: tiddler.title, type: "application/x-tiddler-dictionary", text: `one: a\ncolors: ${tiddler.colors}\ntwo: b`}
|
243
|
+
} else if (tiddler.hasOwnProperty('someField')) {
|
244
|
+
return {title: tiddler.title, type: "application/x-tiddler-dictionary", text: `one: a\nsomeField: ${tiddler.someField}\ntwo: b`}
|
245
|
+
}
|
246
|
+
});
|
247
|
+
const newWidgetText = data.widgetText.replace("listField='colors'", "listIndex='colors'").replace(/\$field/g, '$index').replace("listField='someField'", "listIndex='someField'");
|
248
|
+
const newChange = {};
|
249
|
+
for (const key of Object.keys(data.expectedChange)) {
|
250
|
+
const oldChange = data.expectedChange[key];
|
251
|
+
if (oldChange.colors) {
|
252
|
+
newChange[key] = { text: `one: a\ncolors: ${oldChange.colors}\ntwo: b` }
|
253
|
+
} else if (oldChange.someField !== undefined) {
|
254
|
+
newChange[key] = { text: `one: a\nsomeField: ${oldChange.someField}\ntwo: b` }
|
255
|
+
} else {
|
256
|
+
// In index tiddlers, fields with value undefined get completely removed
|
257
|
+
newChange[key] = { text: `one: a\ntwo: b` }
|
258
|
+
}
|
259
|
+
}
|
260
|
+
newData.testName = newName;
|
261
|
+
newData.tiddlers = newTiddlers;
|
262
|
+
newData.widgetText = newWidgetText;
|
263
|
+
newData.expectedChange = newChange;
|
264
|
+
return newData;
|
265
|
+
});
|
266
|
+
|
267
|
+
const filterModeTests = [
|
268
|
+
{
|
269
|
+
testName: "filter mode false -> true",
|
270
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
271
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
272
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
273
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
274
|
+
startsOutChecked: false,
|
275
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
276
|
+
},
|
277
|
+
{
|
278
|
+
testName: "filter mode true -> false",
|
279
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
280
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
281
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
282
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
283
|
+
startsOutChecked: true,
|
284
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
285
|
+
},
|
286
|
+
{
|
287
|
+
testName: "filter mode no default false -> true",
|
288
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
289
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
290
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
291
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
292
|
+
startsOutChecked: false,
|
293
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
294
|
+
},
|
295
|
+
{
|
296
|
+
testName: "filter mode no default true -> false",
|
297
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
298
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
299
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
300
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
301
|
+
startsOutChecked: true,
|
302
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
303
|
+
},
|
304
|
+
{
|
305
|
+
testName: "filter mode only checked specified false -> true",
|
306
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
307
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
308
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
309
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
310
|
+
startsOutChecked: false,
|
311
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
312
|
+
},
|
313
|
+
{
|
314
|
+
testName: "filter mode only checked specified true -> false",
|
315
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
316
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
317
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
318
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
319
|
+
startsOutChecked: true,
|
320
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
321
|
+
},
|
322
|
+
{
|
323
|
+
testName: "filter mode only checked specified no default false -> true",
|
324
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
325
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
326
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
327
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
328
|
+
startsOutChecked: false,
|
329
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
330
|
+
},
|
331
|
+
{
|
332
|
+
testName: "filter mode only checked specified no default true -> false",
|
333
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
334
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
335
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
336
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
337
|
+
startsOutChecked: true,
|
338
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
339
|
+
},
|
340
|
+
{
|
341
|
+
testName: "filter mode only unchecked specified false -> true",
|
342
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
343
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
344
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
345
|
+
"<$checkbox filter='[list[Colors!!colors]]' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
346
|
+
startsOutChecked: false,
|
347
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
348
|
+
},
|
349
|
+
{
|
350
|
+
testName: "filter mode only unchecked specified true -> false",
|
351
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
352
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
353
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
354
|
+
"<$checkbox filter='[list[Colors!!colors]]' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
355
|
+
startsOutChecked: true,
|
356
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
357
|
+
},
|
358
|
+
{
|
359
|
+
testName: "filter mode only unchecked specified no default false -> true",
|
360
|
+
tiddlers: [{title: "Colors", colors: "red orange yellow"}],
|
361
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
362
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
363
|
+
"<$checkbox filter='[list[Colors!!colors]]' unchecked='red' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
364
|
+
startsOutChecked: false,
|
365
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
366
|
+
},
|
367
|
+
{
|
368
|
+
testName: "filter mode only unchecked specified no default true -> false",
|
369
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
370
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-red green'/>\n" +
|
371
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='red -green'/>\n" +
|
372
|
+
"<$checkbox filter='[list[Colors!!colors]]' unchecked='red' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
373
|
+
startsOutChecked: true,
|
374
|
+
expectedChange: { "Colors": { colors: "orange yellow red" } }
|
375
|
+
},
|
376
|
+
{
|
377
|
+
testName: "filter mode neither checked nor unchecked specified false -> true",
|
378
|
+
tiddlers: [{title: "Colors"}],
|
379
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
380
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
381
|
+
"<$checkbox filter='[list[Colors!!colors]]' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
382
|
+
startsOutChecked: false,
|
383
|
+
expectedChange: { "Colors": { colors: "green" } }
|
384
|
+
},
|
385
|
+
{
|
386
|
+
testName: "filter mode neither checked nor unchecked specified true -> false",
|
387
|
+
tiddlers: [{title: "Colors", colors: "green"}],
|
388
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
389
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
390
|
+
"<$checkbox filter='[list[Colors!!colors]]' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
391
|
+
startsOutChecked: true,
|
392
|
+
expectedChange: { "Colors": { colors: "" } }
|
393
|
+
},
|
394
|
+
{
|
395
|
+
testName: "filter mode neither checked nor unchecked no default specified false -> true",
|
396
|
+
tiddlers: [{title: "Colors", colors: ""}],
|
397
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
398
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
399
|
+
"<$checkbox filter='[list[Colors!!colors]]' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
400
|
+
startsOutChecked: false,
|
401
|
+
expectedChange: { "Colors": { colors: "green" } }
|
402
|
+
},
|
403
|
+
{
|
404
|
+
testName: "filter mode neither checked nor unchecked no default specified true -> false",
|
405
|
+
tiddlers: [{title: "Colors", colors: "green"}],
|
406
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
407
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
408
|
+
"<$checkbox filter='[list[Colors!!colors]]' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
409
|
+
startsOutChecked: true,
|
410
|
+
expectedChange: { "Colors": { colors: "" } }
|
411
|
+
},
|
412
|
+
|
413
|
+
{
|
414
|
+
testName: "filter mode indeterminate -> true",
|
415
|
+
tiddlers: [{title: "Colors", colors: "orange yellow"}],
|
416
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
417
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
418
|
+
"<$checkbox filter='[list[Colors!!colors]]' indeterminate='yes' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
419
|
+
startsOutChecked: undefined,
|
420
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
421
|
+
},
|
422
|
+
{
|
423
|
+
testName: "filter mode true -> indeterminate",
|
424
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
425
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
426
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
427
|
+
"<$checkbox filter='[list[Colors!!colors]]' indeterminate='yes' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
428
|
+
startsOutChecked: true,
|
429
|
+
finalValue: undefined,
|
430
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
431
|
+
},
|
432
|
+
{
|
433
|
+
testName: "filter mode not indeterminate -> true",
|
434
|
+
tiddlers: [{title: "Colors", colors: "orange yellow"}],
|
435
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
436
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
437
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
438
|
+
startsOutChecked: false,
|
439
|
+
expectedChange: { "Colors": { colors: "orange yellow green" } }
|
440
|
+
},
|
441
|
+
{
|
442
|
+
testName: "filter mode true -> not indeterminate",
|
443
|
+
tiddlers: [{title: "Colors", colors: "green orange yellow"}],
|
444
|
+
widgetText: "\\define checkActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='green'/>\n" +
|
445
|
+
"\\define uncheckActions() <$action-listops $tiddler='Colors' $field='colors' $subfilter='-green'/>\n" +
|
446
|
+
"<$checkbox filter='[list[Colors!!colors]]' checked='green' unchecked='red' default='green' checkactions=<<checkActions>> uncheckactions=<<uncheckActions>> />",
|
447
|
+
startsOutChecked: true,
|
448
|
+
finalValue: false,
|
449
|
+
expectedChange: { "Colors": { colors: "orange yellow" } }
|
450
|
+
},
|
451
|
+
];
|
452
|
+
|
453
|
+
const checkboxTestData = fieldModeTests.concat(
|
454
|
+
indexModeTests,
|
455
|
+
listModeTests,
|
456
|
+
indexListModeTests,
|
457
|
+
filterModeTests,
|
458
|
+
);
|
459
|
+
|
460
|
+
/*
|
461
|
+
* Checkbox widget tests using the test data above
|
462
|
+
*/
|
463
|
+
for (const data of checkboxTestData) {
|
464
|
+
it('checkbox widget test: ' + data.testName, function() {
|
465
|
+
// Setup
|
466
|
+
|
467
|
+
var wiki = new $tw.Wiki();
|
468
|
+
wiki.addTiddlers(data.tiddlers);
|
469
|
+
var widgetNode = createWidgetNode(parseText(data.widgetText,wiki),wiki);
|
470
|
+
var wrapper = renderWidgetNode(widgetNode);
|
471
|
+
|
472
|
+
// Check initial state
|
473
|
+
|
474
|
+
const widget = findNodeOfType('checkbox', widgetNode);
|
475
|
+
// Verify that the widget is or is not checked as expected
|
476
|
+
expect(widget.getValue()).toBe(data.startsOutChecked);
|
477
|
+
|
478
|
+
// Fake an event that toggles the checkbox
|
479
|
+
|
480
|
+
// fakedom elmenets don't have a "checked" property. so we fake it because
|
481
|
+
// Checkbox.prototype.handleChangeEvent looks at the "checked" DOM property
|
482
|
+
widget.inputDomNode.checked = !!widget.inputDomNode.attributes.checked;
|
483
|
+
// Now simulate checking the box
|
484
|
+
widget.inputDomNode.checked = !widget.inputDomNode.checked;
|
485
|
+
widget.handleChangeEvent(null);
|
486
|
+
|
487
|
+
// Check state again: in most tests, checkbox should be inverse of what it was
|
488
|
+
const finalValue = data.hasOwnProperty('finalValue') ? data.finalValue : !data.startsOutChecked;
|
489
|
+
expect(widget.getValue()).toBe(finalValue);
|
490
|
+
|
491
|
+
// Check that tiddler(s) has/have gone through expected change(s)
|
492
|
+
for (const key of Object.keys(data.expectedChange)) {
|
493
|
+
const tiddler = wiki.getTiddler(key);
|
494
|
+
const change = data.expectedChange[key];
|
495
|
+
for (const fieldName of Object.keys(change)) {
|
496
|
+
const expectedValue = change[fieldName];
|
497
|
+
const fieldValue = tiddler.fields[fieldName];
|
498
|
+
expect(fieldValue).toBe(expectedValue);
|
499
|
+
}
|
500
|
+
}
|
501
|
+
})
|
502
|
+
}
|
503
|
+
|
504
|
+
});
|
505
|
+
|
506
|
+
})();
|
507
|
+
|
@@ -621,6 +621,8 @@ Tests the filtering mechanism.
|
|
621
621
|
});
|
622
622
|
|
623
623
|
it("should handle indirect operands", function() {
|
624
|
+
expect(wiki.filterTiddlers("[{!!missing}]").join(",")).toBe("");
|
625
|
+
expect(wiki.filterTiddlers("[{!!title}]").join(",")).toBe("");
|
624
626
|
expect(wiki.filterTiddlers("[prefix{Tiddler8}] +[sort[title]]").join(",")).toBe("Tiddler Three,TiddlerOne");
|
625
627
|
expect(wiki.filterTiddlers("[modifier{Tiddler8!!test-field}] +[sort[title]]").join(",")).toBe("TiddlerOne");
|
626
628
|
var fakeWidget = {wiki: wiki, getVariable: function() {return "Tiddler Three";}};
|
@@ -745,7 +747,46 @@ Tests the filtering mechanism.
|
|
745
747
|
|
746
748
|
expect(wiki.filterTiddlers("a [[b c]] +[append{TiddlerSix!!filter}]").join(",")).toBe("a,b c,one,a a,[subfilter{hasList!!list}]");
|
747
749
|
});
|
748
|
-
|
750
|
+
|
751
|
+
it("should handle the insertafter operator", function() {
|
752
|
+
var widget = require("$:/core/modules/widgets/widget.js");
|
753
|
+
var rootWidget = new widget.widget({ type:"widget", children:[ {type:"widget", children:[]} ] },
|
754
|
+
{ wiki:wiki, document:$tw.document});
|
755
|
+
rootWidget.makeChildWidgets();
|
756
|
+
var anchorWidget = rootWidget.children[0];
|
757
|
+
rootWidget.setVariable("myVar","c");
|
758
|
+
rootWidget.setVariable("tidTitle","e");
|
759
|
+
rootWidget.setVariable("tidList","one tid with spaces");
|
760
|
+
|
761
|
+
// Position title specified as suffix.
|
762
|
+
expect(wiki.filterTiddlers("a b c d e f +[insertafter:myVar[f]]",anchorWidget).join(",")).toBe("a,b,c,f,d,e");
|
763
|
+
expect(wiki.filterTiddlers("a b c d e f +[insertafter:myVar<tidTitle>]",anchorWidget).join(",")).toBe("a,b,c,e,d,f");
|
764
|
+
expect(wiki.filterTiddlers("a b c d e f +[insertafter:myVar[gg gg]]",anchorWidget).join(",")).toBe("a,b,c,gg gg,d,e,f");
|
765
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:myVar<tidList>]",anchorWidget).join(",")).toBe("a,b,c,one tid with spaces,d,e");
|
766
|
+
expect(wiki.filterTiddlers("a b c d e f +[insertafter:tidTitle{TiddlerOne!!tags}]",anchorWidget).join(",")).toBe("a,b,c,d,e,one,f");
|
767
|
+
|
768
|
+
// Position title specified as parameter.
|
769
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter[f],[a]]",anchorWidget).join(",")).toBe("a,f,b,c,d,e");
|
770
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter[f],<myVar>]",anchorWidget).join(",")).toBe("a,b,c,f,d,e");
|
771
|
+
|
772
|
+
// Parameter takes precedence over suffix.
|
773
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:myVar[f],[a]]",anchorWidget).join(",")).toBe("a,f,b,c,d,e");
|
774
|
+
|
775
|
+
// No position title.
|
776
|
+
expect(wiki.filterTiddlers("a b c [[with space]] +[insertafter[b]]").join(",")).toBe("a,c,with space,b");
|
777
|
+
|
778
|
+
// Position title does not exist, and no suffix given.
|
779
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:foo[b]]").join(",")).toBe("a,c,d,e,b");
|
780
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter[b],[foo]]").join(",")).toBe("a,c,d,e,b");
|
781
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter[b],<foo>]").join(",")).toBe("a,c,d,e,b");
|
782
|
+
|
783
|
+
// Position title does not exist, but "start" or "end" given as suffix
|
784
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:start[b],[foo]]").join(",")).toBe("b,a,c,d,e");
|
785
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:start[b],<foo>]").join(",")).toBe("b,a,c,d,e");
|
786
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:end[b],[foo]]").join(",")).toBe("a,c,d,e,b");
|
787
|
+
expect(wiki.filterTiddlers("a b c d e +[insertafter:end[b],<foo>]").join(",")).toBe("a,c,d,e,b");
|
788
|
+
});
|
789
|
+
|
749
790
|
it("should handle the insertbefore operator", function() {
|
750
791
|
var widget = require("$:/core/modules/widgets/widget.js");
|
751
792
|
var rootWidget = new widget.widget({ type:"widget", children:[ {type:"widget", children:[]} ] },
|
@@ -773,10 +814,16 @@ Tests the filtering mechanism.
|
|
773
814
|
// No position title.
|
774
815
|
expect(wiki.filterTiddlers("a b c [[with space]] +[insertbefore[b]]").join(",")).toBe("a,c,with space,b");
|
775
816
|
|
776
|
-
// Position title does not exist.
|
817
|
+
// Position title does not exist, and no suffix given.
|
777
818
|
expect(wiki.filterTiddlers("a b c d e +[insertbefore:foo[b]]").join(",")).toBe("a,c,d,e,b");
|
778
819
|
expect(wiki.filterTiddlers("a b c d e +[insertbefore[b],[foo]]").join(",")).toBe("a,c,d,e,b");
|
779
820
|
expect(wiki.filterTiddlers("a b c d e +[insertbefore[b],<foo>]").join(",")).toBe("a,c,d,e,b");
|
821
|
+
|
822
|
+
// Position title does not exist, but "start" or "end" given as suffix
|
823
|
+
expect(wiki.filterTiddlers("a b c d e +[insertbefore:start[b],[foo]]").join(",")).toBe("b,a,c,d,e");
|
824
|
+
expect(wiki.filterTiddlers("a b c d e +[insertbefore:start[b],<foo>]").join(",")).toBe("b,a,c,d,e");
|
825
|
+
expect(wiki.filterTiddlers("a b c d e +[insertbefore:end[b],[foo]]").join(",")).toBe("a,c,d,e,b");
|
826
|
+
expect(wiki.filterTiddlers("a b c d e +[insertbefore:end[b],<foo>]").join(",")).toBe("a,c,d,e,b");
|
780
827
|
});
|
781
828
|
|
782
829
|
it("should handle the move operator", function() {
|
@@ -416,6 +416,8 @@ describe("'reduce' and 'intersection' filter prefix tests", function() {
|
|
416
416
|
expect(wiki.filterTiddlers("[tag[shopping]] :map[get[description]else{!!title}]").join(",")).toBe("A square of rich chocolate cake,a round yellow seed,Milk,Rice Pudding");
|
417
417
|
// Return the first title from :map if the filter returns more than one result
|
418
418
|
expect(wiki.filterTiddlers("[tag[shopping]] :map[tags[]]").join(",")).toBe("shopping,shopping,shopping,shopping");
|
419
|
+
// Return all titles from :map if the flat suffix is used
|
420
|
+
expect(wiki.filterTiddlers("[tag[shopping]] :map:flat[tags[]]").join(",")).toBe("shopping,food,shopping,food,shopping,dairy,drinks,shopping,dairy");
|
419
421
|
// Prepend the position in the list using the index and length variables
|
420
422
|
expect(wiki.filterTiddlers("[tag[shopping]] :map[get[title]addprefix[-]addprefix<length>addprefix[of]addprefix<index>]").join(",")).toBe("0of4-Brownies,1of4-Chick Peas,2of4-Milk,3of4-Rice Pudding");
|
421
423
|
});
|
@@ -78,6 +78,12 @@ describe("Utility tests", function() {
|
|
78
78
|
expect(fds(d,"ddd hh mm ssss")).toBe("Sun 17 41 2828");
|
79
79
|
expect(fds(d,"MM0DD")).toBe("1109");
|
80
80
|
expect(fds(d,"MM0\\D\\D")).toBe("110DD");
|
81
|
+
const day = d.getUTCDate();
|
82
|
+
const dayStr = ("" + day).padStart(2, '0');
|
83
|
+
const hours = d.getUTCHours();
|
84
|
+
const hoursStr = ("" + hours).padStart(2, '0');
|
85
|
+
const expectedUtcStr = `201411${dayStr}${hoursStr}4128542`;
|
86
|
+
expect(fds(d,"[UTC]YYYY0MM0DD0hh0mm0ssXXX")).toBe(expectedUtcStr);
|
81
87
|
|
82
88
|
// test some edge cases found at: https://en.wikipedia.org/wiki/ISO_week_date
|
83
89
|
// 2016-11-13 is Week 45 and it's a Sunday (month nr: 10)
|
@@ -143,7 +143,8 @@ describe("Widget module", function() {
|
|
143
143
|
var wiki = new $tw.Wiki();
|
144
144
|
// Add a tiddler
|
145
145
|
wiki.addTiddlers([
|
146
|
-
{title: "TiddlerOne", text: "<$transclude tiddler='
|
146
|
+
{title: "TiddlerOne", text: "<$transclude tiddler='TiddlerTwo'/>\n"},
|
147
|
+
{title: "TiddlerTwo", text: "<$transclude tiddler='TiddlerOne'/>"}
|
147
148
|
]);
|
148
149
|
// Test parse tree
|
149
150
|
var parseTreeNode = {type: "widget", children: [
|