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.
Files changed (631) hide show
  1. package/.github/ISSUE_TEMPLATE/bug_report.yml +67 -0
  2. package/.github/ISSUE_TEMPLATE/config.yml +8 -0
  3. package/.github/PULL_REQUEST_TEMPLATE/pull_request_template.md +8 -0
  4. package/bin/build-site.sh +1 -1
  5. package/boot/boot.js +1 -1
  6. package/contributing.md +1 -1
  7. package/core/language/en-GB/EditTemplate.multids +1 -0
  8. package/core/language/en-GB/Help/default.tid +4 -1
  9. package/core/language/en-GB/Help/render.tid +2 -2
  10. package/core/language/en-GB/SideBar.multids +1 -0
  11. package/core/modules/commands/render.js +1 -1
  12. package/core/modules/commands/rendertiddler.js +1 -0
  13. package/core/modules/commands/rendertiddlers.js +1 -1
  14. package/core/modules/commands/save.js +56 -42
  15. package/core/modules/editor/engines/framed.js +3 -1
  16. package/core/modules/editor/operations/text/prefix-lines.js +2 -2
  17. package/core/modules/editor/operations/text/wrap-lines.js +27 -10
  18. package/core/modules/filterrunprefixes/map.js +10 -2
  19. package/core/modules/filters/insertafter.js +46 -0
  20. package/core/modules/filters/insertbefore.js +6 -1
  21. package/core/modules/filters.js +19 -1
  22. package/core/modules/savers/put.js +11 -7
  23. package/core/modules/savers/upload.js +1 -1
  24. package/core/modules/server/server.js +3 -2
  25. package/core/modules/startup/browser-messaging.js +4 -2
  26. package/core/modules/startup/story.js +3 -1
  27. package/core/modules/utils/dom/dom.js +51 -0
  28. package/core/modules/utils/dom/dragndrop.js +24 -14
  29. package/core/modules/utils/dom/notifier.js +2 -1
  30. package/core/modules/utils/parsetree.js +48 -11
  31. package/core/modules/utils/utils.js +15 -1
  32. package/core/modules/widgets/action-setfield.js +12 -14
  33. package/core/modules/widgets/button.js +6 -1
  34. package/core/modules/widgets/checkbox.js +124 -15
  35. package/core/modules/widgets/draggable.js +37 -14
  36. package/core/modules/widgets/element.js +9 -3
  37. package/core/modules/widgets/eventcatcher.js +1 -27
  38. package/core/modules/widgets/image.js +4 -0
  39. package/core/modules/widgets/let.js +1 -1
  40. package/core/modules/widgets/scrollable.js +2 -0
  41. package/core/modules/widgets/widget.js +8 -1
  42. package/core/modules/wiki.js +1 -1
  43. package/core/palettes/CupertinoDark.tid +3 -3
  44. package/core/palettes/GruvBoxDark.tid +2 -2
  45. package/core/palettes/Nord.tid +2 -2
  46. package/core/templates/save-lazy-all.tid +2 -2
  47. package/core/templates/server/static.sidebar.wikitext.tid +1 -1
  48. package/core/templates/server/static.tiddler.html.tid +2 -2
  49. package/core/ui/Actions/new-image.tid +1 -0
  50. package/core/ui/Actions/new-journal.tid +2 -1
  51. package/core/ui/Actions/new-tiddler.tid +1 -0
  52. package/core/ui/AdvancedSearch/Filter.tid +50 -10
  53. package/core/ui/AdvancedSearch/FilterButtons/clear.tid +1 -0
  54. package/core/ui/AdvancedSearch/FilterButtons/delete.tid +1 -0
  55. package/core/ui/AdvancedSearch/FilterButtons/dropdown.tid +5 -2
  56. package/core/ui/AdvancedSearch/FilterButtons/export.tid +1 -0
  57. package/core/ui/AdvancedSearch/Shadows.tid +54 -12
  58. package/core/ui/AdvancedSearch/Standard.tid +36 -19
  59. package/core/ui/AdvancedSearch/System.tid +54 -12
  60. package/core/ui/AdvancedSearch.tid +1 -0
  61. package/core/ui/AlertTemplate.tid +10 -1
  62. package/core/ui/Components/tag-link.tid +1 -0
  63. package/core/ui/ControlPanel/Advanced.tid +1 -0
  64. package/core/ui/ControlPanel/Appearance.tid +1 -0
  65. package/core/ui/ControlPanel/Basics.tid +3 -0
  66. package/core/ui/ControlPanel/Cascades.tid +1 -0
  67. package/core/ui/ControlPanel/EditorTypes.tid +1 -0
  68. package/core/ui/ControlPanel/Info.tid +1 -0
  69. package/core/ui/ControlPanel/KeyboardShortcuts.tid +18 -7
  70. package/core/ui/ControlPanel/Modals/AddPlugins.tid +26 -9
  71. package/core/ui/ControlPanel/Parsing.tid +3 -0
  72. package/core/ui/ControlPanel/Plugins/Add/Updates.tid +5 -1
  73. package/core/ui/ControlPanel/Plugins/AddPlugins.tid +4 -1
  74. package/core/ui/ControlPanel/Plugins.tid +1 -0
  75. package/core/ui/ControlPanel/Saving/TiddlySpot.tid +2 -1
  76. package/core/ui/ControlPanel/Saving.tid +1 -0
  77. package/core/ui/ControlPanel/Settings/DefaultMoreSidebarTab.tid +1 -0
  78. package/core/ui/ControlPanel/Settings/DefaultSidebarTab.tid +1 -0
  79. package/core/ui/ControlPanel/Settings/LinkToBehaviour.tid +1 -0
  80. package/core/ui/ControlPanel/Settings/ToolbarButtonStyle.tid +1 -0
  81. package/core/ui/ControlPanel/Toolbars/EditorItemTemplate.tid +8 -1
  82. package/core/ui/ControlPanel/Toolbars/ItemTemplate.tid +11 -1
  83. package/core/ui/ControlPanel/Toolbars.tid +1 -0
  84. package/core/ui/ControlPanel.tid +1 -0
  85. package/core/ui/DefaultSearchResultList.tid +1 -0
  86. package/core/ui/EditTemplate/Preview/output.tid +1 -1
  87. package/core/ui/EditTemplate/body/default.tid +8 -5
  88. package/core/ui/EditTemplate/body-editor.tid +2 -0
  89. package/core/ui/EditTemplate/controls.tid +1 -0
  90. package/core/ui/EditTemplate/fieldEditor-default.tid +1 -1
  91. package/core/ui/EditTemplate/fields.tid +17 -10
  92. package/core/ui/EditTemplate/shadow.tid +2 -0
  93. package/core/ui/EditTemplate/title.tid +10 -5
  94. package/core/ui/EditTemplate.tid +28 -4
  95. package/core/ui/EditorToolbar/editor-height.tid +1 -0
  96. package/core/ui/EditorToolbar/excise-dropdown.tid +5 -4
  97. package/core/ui/EditorToolbar/file-import.tid +4 -0
  98. package/core/ui/EditorToolbar/link-dropdown.tid +10 -5
  99. package/core/ui/EditorToolbar/more-dropdown.tid +5 -1
  100. package/core/ui/EditorToolbar/paint.tid +1 -0
  101. package/core/ui/EditorToolbar/preview.tid +1 -0
  102. package/core/ui/EditorToolbar/size-dropdown.tid +6 -1
  103. package/core/ui/ExportTiddlyWikiCore.tid +15 -5
  104. package/core/ui/ImportListing.tid +23 -5
  105. package/core/ui/ImportPreviews/Fields.tid +1 -0
  106. package/core/ui/KeyboardShortcuts/advanced-search.tid +1 -0
  107. package/core/ui/KeyboardShortcuts/change-sidebar-layout.tid +4 -2
  108. package/core/ui/KeyboardShortcuts/new-image.tid +1 -0
  109. package/core/ui/KeyboardShortcuts/new-journal.tid +1 -0
  110. package/core/ui/KeyboardShortcuts/new-tiddler.tid +1 -0
  111. package/core/ui/KeyboardShortcuts/save-wiki.tid +1 -0
  112. package/core/ui/KeyboardShortcuts/toggle-sidebar.tid +4 -3
  113. package/core/ui/LayoutSwitcher.tid +16 -4
  114. package/core/ui/ListItemTemplate.tid +1 -3
  115. package/core/ui/ListTaggedCascade.tid +1 -0
  116. package/core/ui/Manager/ItemMainFields.tid +1 -0
  117. package/core/ui/Manager/ItemSidebarColour.tid +4 -1
  118. package/core/ui/Manager/ItemSidebarIcon.tid +4 -4
  119. package/core/ui/Manager/ItemSidebarTools.tid +7 -2
  120. package/core/ui/Manager.tid +11 -6
  121. package/core/ui/MissingTemplate.tid +1 -0
  122. package/core/ui/MoreSideBar/Types.tid +1 -0
  123. package/core/ui/PageControls/controlpanel.tid +1 -1
  124. package/core/ui/PageStylesheet.tid +1 -0
  125. package/core/ui/PageTemplate/story.tid +1 -1
  126. package/core/ui/PaletteManager.tid +11 -10
  127. package/core/ui/PluginInfo.tid +1 -0
  128. package/core/ui/PluginInfoDefaultContents.tid +1 -0
  129. package/core/ui/SearchResults.tid +8 -6
  130. package/core/ui/SideBar/More.tid +1 -0
  131. package/core/ui/SideBar/Open.tid +2 -2
  132. package/core/ui/SideBarSegments/search.tid +2 -0
  133. package/core/ui/SideBarSegments/tabs.tid +1 -1
  134. package/core/ui/TiddlerFieldTemplate.tid +1 -0
  135. package/core/ui/TiddlerFields.tid +1 -0
  136. package/core/ui/TiddlerInfo/Advanced/PluginInfo.tid +1 -0
  137. package/core/ui/TiddlerInfo/Advanced/ShadowInfo.tid +1 -0
  138. package/core/ui/TiddlerInfo/Advanced.tid +1 -0
  139. package/core/ui/TiddlerInfo.tid +1 -0
  140. package/core/ui/TopRightBar/menu.tid +1 -0
  141. package/core/ui/UntaggedTemplate.tid +1 -0
  142. package/core/ui/ViewTemplate/body/import.tid +6 -1
  143. package/core/ui/ViewTemplate/body/plugin.tid +1 -0
  144. package/core/ui/ViewTemplate/body/rendered-plain-text.tid +7 -0
  145. package/core/ui/ViewTemplate/body.tid +2 -0
  146. package/core/ui/ViewTemplate/classic.tid +1 -0
  147. package/core/ui/ViewTemplate/subtitle/modified.tid +4 -0
  148. package/core/ui/ViewTemplate/subtitle/modifier.tid +4 -0
  149. package/core/ui/ViewTemplate/subtitle.tid +6 -2
  150. package/core/ui/ViewTemplate/tags.tid +1 -0
  151. package/core/ui/ViewTemplate/title.tid +2 -0
  152. package/core/ui/ViewTemplate/unfold.tid +1 -0
  153. package/core/ui/ViewTemplate.tid +1 -1
  154. package/core/ui/ViewToolbar/new-here.tid +1 -0
  155. package/core/wiki/allfields.tid +8 -2
  156. package/core/wiki/config/OfficialPluginLibrary.tid +1 -1
  157. package/core/wiki/config/ViewTemplateBodyFilters.multids +2 -1
  158. package/core/wiki/currpalettepreview.tid +7 -2
  159. package/core/wiki/debugstylesheets.tid +1 -0
  160. package/core/wiki/download-wiki-button.tid +2 -1
  161. package/core/wiki/languageswitcher.tid +2 -0
  162. package/core/wiki/macros/colour-picker.tid +9 -2
  163. package/core/wiki/macros/copy-to-clipboard.tid +5 -2
  164. package/core/wiki/macros/diff.tid +4 -3
  165. package/core/wiki/macros/dumpvariables.tid +1 -0
  166. package/core/wiki/macros/image-picker.tid +5 -4
  167. package/core/wiki/macros/keyboard-driven-input.tid +22 -12
  168. package/core/wiki/macros/list.tid +7 -2
  169. package/core/wiki/macros/tabs.tid +55 -30
  170. package/core/wiki/macros/tag-picker.tid +14 -13
  171. package/core/wiki/macros/tag.tid +10 -5
  172. package/core/wiki/macros/thumbnails.tid +21 -9
  173. package/core/wiki/macros/timeline.tid +1 -0
  174. package/core/wiki/macros/toc.tid +19 -8
  175. package/core/wiki/macros/translink.tid +1 -0
  176. package/core/wiki/macros/tree.tid +8 -3
  177. package/core/wiki/minifocusswitcher.tid +1 -0
  178. package/core/wiki/minilanguageswitcher.tid +1 -0
  179. package/core/wiki/minithemeswitcher.tid +2 -1
  180. package/core/wiki/modules.tid +1 -0
  181. package/core/wiki/palettepreview.tid +1 -0
  182. package/core/wiki/paletteswitcher.tid +13 -2
  183. package/core/wiki/peek-stylesheets.tid +1 -5
  184. package/core/wiki/tags/ViewTemplateBodyFilter.tid +1 -1
  185. package/core/wiki/tags/ViewTemplateSubtitle.tid +2 -0
  186. package/core/wiki/themeswitcher.tid +10 -1
  187. package/core/wiki/title.tid +2 -1
  188. package/core/wiki/viewswitcher.tid +1 -0
  189. package/editions/de-AT/tiddlers/howto/TiddlyWiki und TiddlyDesktop.tid +1 -1
  190. package/editions/dev/tiddlers/_tw_shared/tiddlywiki.files +5 -0
  191. package/editions/dev/tiddlers/system/github-fork-ribbon.tid +1 -1
  192. package/editions/dev/tiddlywiki.info +1 -1
  193. package/editions/es-ES/tiddlers/TiddlyDesktop.tid +2 -2
  194. package/editions/fr-FR/tiddlers/Community Links Aggregator.tid +4 -4
  195. package/editions/fr-FR/tiddlers/Glossaire en-GB -_ fr-FR.tid +2 -1
  196. package/editions/fr-FR/tiddlers/community/editions/_Noteself_ by Danielo Rodr/303/255guez.tid" +34 -0
  197. package/editions/fr-FR/tiddlers/community/resources/TW5-firebase_ TiddlyWiki5 for Google Firebase by Peter Neumark.tid +28 -0
  198. package/editions/fr-FR/tiddlers/community/resources/TiddlyDrive Add-on for Google Drive by Joshua Stubbs.tid +24 -0
  199. package/editions/fr-FR/tiddlers/community/resources/TiddlyServer by Arlen Beiler.tid +35 -0
  200. package/editions/fr-FR/tiddlers/community/resources/Twexe_ Single File Tiddlywiki5 executable.tid +30 -0
  201. package/editions/fr-FR/tiddlers/community/resources/_Timimi_ Extension and executable by Riz.tid +33 -0
  202. package/editions/fr-FR/tiddlers/community/resources/_file-backups_ Extension for Firefox by pmario.tid +19 -0
  203. package/editions/fr-FR/tiddlers/community/resources/_savetiddlers_ Extension for Chrome and Firefox by buggyj.tid +17 -0
  204. package/editions/fr-FR/tiddlers/concepts/Pragma.tid +23 -0
  205. package/editions/fr-FR/tiddlers/{WikiText.tid → concepts/WikiText.tid} +6 -4
  206. package/editions/fr-FR/tiddlers/definitions/TiddlyDesktop.tid +19 -0
  207. package/editions/fr-FR/tiddlers/gettingstarted/GettingStarted - Internet Explorer.tid +11 -0
  208. package/editions/fr-FR/tiddlers/gettingstarted/GettingStarted - Safari.tid +12 -0
  209. package/editions/fr-FR/tiddlers/{A_Gentle_Guide_to_TiddlyWiki.tid → hellothere/A Gentle Guide to TiddlyWiki.tid } +6 -4
  210. package/editions/fr-FR/tiddlers/howtos/How to Customize TiddlyDesktop.tid +33 -0
  211. package/editions/fr-FR/tiddlers/howtos/Windows HTA Hack.tid +17 -0
  212. package/editions/fr-FR/tiddlers/nodejs/Installing TiddlyWiki on Node.js.tid +49 -0
  213. package/editions/fr-FR/tiddlers/nodejs/Serving TW5 from Android.tid +47 -0
  214. package/editions/fr-FR/tiddlers/nodejs/TiddlyWiki on Node.js.tid +18 -0
  215. package/editions/fr-FR/tiddlers/saving/Emergency Tiddler Export.tid +28 -0
  216. package/editions/fr-FR/tiddlers/saving/Example config-tiddlyweb-host for IIS.tid +9 -0
  217. package/editions/fr-FR/tiddlers/saving/Example package.json for IIS.tid +15 -0
  218. package/editions/fr-FR/tiddlers/saving/Example tiddlywiki.info for IIS.tid +18 -0
  219. package/editions/fr-FR/tiddlers/saving/Example web.config for IIS.tid +32 -0
  220. package/editions/fr-FR/tiddlers/saving/Installing TiddlyWiki on Microsoft Internet Information Server.tid +69 -0
  221. package/editions/fr-FR/tiddlers/saving/Saving on Android.tid +36 -0
  222. package/editions/fr-FR/tiddlers/saving/Saving on Beaker Browser.tid +35 -0
  223. package/editions/fr-FR/tiddlers/saving/Saving on Browser with File System Access API.tid +20 -0
  224. package/editions/fr-FR/tiddlers/saving/Saving on TidGi Desktop.tid +28 -0
  225. package/editions/fr-FR/tiddlers/saving/Saving on TiddlyDesktop.tid +20 -0
  226. package/editions/fr-FR/tiddlers/saving/Saving on TiddlyHost.tid +18 -0
  227. package/editions/fr-FR/tiddlers/{Saving on TiddlySpot.tid → saving/Saving on TiddlySpot.tid } +14 -3
  228. package/editions/fr-FR/tiddlers/saving/Saving on a PHP Server.tid +45 -0
  229. package/editions/fr-FR/tiddlers/saving/Saving on iPad_iPhone.tid +30 -0
  230. package/editions/fr-FR/tiddlers/saving/Saving to a Git service.tid +26 -0
  231. package/editions/fr-FR/tiddlers/saving/Saving via WebDAV.tid +88 -0
  232. package/editions/fr-FR/tiddlers/saving/Saving via a Minimal Ruby Server.tid +20 -0
  233. package/editions/fr-FR/tiddlers/saving/Saving with Polly.tid +30 -0
  234. package/editions/fr-FR/tiddlers/saving/Saving with TW Receiver.tid +16 -0
  235. package/editions/fr-FR/tiddlers/{Saving with TiddlyFox on Android.tid → saving/Saving with TiddlyFox on Android.tid } +5 -5
  236. package/editions/fr-FR/tiddlers/saving/Saving with TiddlyFox.tid +31 -0
  237. package/editions/fr-FR/tiddlers/saving/Saving with TiddlyIE.tid +25 -0
  238. package/editions/fr-FR/tiddlers/{Saving with the HTML5 fallback saver.tid → saving/Saving with the HTML5 fallback saver.tid } +11 -6
  239. package/editions/fr-FR/tiddlers/{Saving.tid → saving/Saving.tid} +8 -10
  240. package/editions/fr-FR/tiddlers/saving/TiddlyWiki Cloud.tid +17 -0
  241. package/editions/fr-FR/tiddlers/system/$__core_ui_SideBar_Open.tid +40 -0
  242. package/editions/fr-FR/tiddlers/{$__editions_fr-FR_util-macros.tid → system/$__editions_fr-FR_util-macros.tid} +4 -4
  243. package/editions/fr-FR/tiddlers/{$__editions_tw5.com_wikitext-macros.tid → system/$__editions_tw5.com_wikitext-macros.tid} +24 -3
  244. package/editions/fr-FR/tiddlers/system/tw5.com-card-template.tid +17 -0
  245. package/editions/fr-FR/tiddlers/tiddlydesktop/TiddlyDesktop_Releases.tid +9 -0
  246. package/editions/fr-FR/tiddlers/widgets/TranscludeWidget.tid +72 -0
  247. package/editions/fr-FR/tiddlers/{Block_Quotes_in_WikiText.tid → wikitext/Block Quotes in WikiText.tid } +3 -2
  248. package/editions/fr-FR/tiddlers/{Code Blocks in WikiText.tid → wikitext/Code Blocks in WikiText.tid } +3 -3
  249. package/editions/fr-FR/tiddlers/{Dashes in WikiText.tid → wikitext/Dashes in WikiText.tid } +3 -3
  250. package/editions/fr-FR/tiddlers/{Definitions_in_WikiText.tid → wikitext/Definitions in WikiText.tid } +2 -2
  251. package/editions/fr-FR/tiddlers/{Formatting in WikiText.tid → wikitext/Formatting in WikiText.tid } +5 -6
  252. package/editions/fr-FR/tiddlers/{Hard Linebreaks in WikiText.tid → wikitext/Hard Linebreaks in WikiText.tid } +6 -5
  253. package/editions/fr-FR/tiddlers/{Headings in WikiText.tid → wikitext/Headings in WikiText.tid } +4 -4
  254. package/editions/fr-FR/tiddlers/wikitext/Horizontal Rules in WikiText.tid +17 -0
  255. package/editions/fr-FR/tiddlers/{Lists_in_WikiText.tid → wikitext/Lists in WikiText.tid } +19 -19
  256. package/editions/fr-FR/tiddlers/wikitext/Macro Calls in WikiText.tid +27 -0
  257. package/editions/fr-FR/tiddlers/{Paragraphs in WikiText.tid → wikitext/Paragraphs in WikiText.tid } +8 -7
  258. package/editions/fr-FR/tiddlers/wikitext/Tables in WikiText.tid +69 -0
  259. package/editions/fr-FR/tiddlers/wikitext/Transclusion and Substitution.tid +61 -0
  260. package/editions/fr-FR/tiddlers/{Transclusion_in_WikiText.tid → wikitext/Transclusion in WikiText.tid } +14 -13
  261. package/editions/fr-FR/tiddlers/{Transclusion_with_Templates.tid → wikitext/Transclusion with Templates.tid } +2 -1
  262. package/editions/fr-FR/tiddlers/{Typed_Blocks_in_WikiText.tid → wikitext/Typed Blocks in WikiText.tid } +16 -11
  263. package/editions/fr-FR/tiddlers/{Variables_in_WikiText.tid → wikitext/Variables in WikiText.tid } +7 -8
  264. package/editions/fr-FR/tiddlers/wikitext/Widgets in WikiText.tid +30 -0
  265. package/editions/fr-FR/tiddlers/wikitext/parser/Block Mode WikiText (Examples).tid +52 -0
  266. package/editions/fr-FR/tiddlers/wikitext/parser/Block Mode WikiText.tid +37 -0
  267. package/editions/fr-FR/tiddlers/wikitext/parser/Inline Mode WikiText.tid +28 -0
  268. package/editions/fr-FR/tiddlers/wikitext/parser/Places where the parser ignores WikiText.tid +14 -0
  269. package/editions/fr-FR/tiddlers/wikitext/parser/WikiText Parser Modes.tid +17 -0
  270. package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode HTML examples.tid +73 -0
  271. package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode transitions.tid +59 -0
  272. package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode_ macro examples.tid +56 -0
  273. package/editions/fr-FR/tiddlers/wikitext/parser/WikiText parser mode_ transclusion examples.tid +56 -0
  274. package/editions/fr-FR/tiddlers/wikitext/parser/table-example.tid +8 -0
  275. package/editions/katexdemo/tiddlers/$__DefaultTiddlers.tid +8 -0
  276. package/editions/katexdemo/tiddlers/HelloThere.tid +4 -1
  277. package/editions/katexdemo/tiddlers/LaTeX.tid +8 -0
  278. package/editions/katexdemo/tiddlers/TiddlyWiki.tid +8 -0
  279. package/editions/katexdemo/tiddlers/TiddlyWiki5.tid +6 -0
  280. package/editions/prerelease/tiddlers/{Release 5.2.3.tid → Release 5.2.4.tid } +16 -15
  281. package/editions/prerelease/tiddlers/system/PrereleaseLocalPluginLibrary.tid +1 -1
  282. package/editions/prerelease/tiddlers/system/PrereleaseOfficialPluginLibrary.tid +1 -1
  283. package/editions/prerelease/tiddlers/system/TiddlyWiki Pre-release.tid +4 -1
  284. package/editions/prerelease/tiddlywiki.info +0 -2
  285. package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-horizontal-all.tid +1 -29
  286. package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-horizontal.tid +1 -39
  287. package/editions/test/tiddlers/tests/data/tabs-macro/expected-html-tabs-vertical.tid +1 -39
  288. package/editions/test/tiddlers/tests/test-action-widgets.js +43 -0
  289. package/editions/test/tiddlers/tests/test-checkbox-widget.js +507 -0
  290. package/editions/test/tiddlers/tests/test-filters.js +49 -2
  291. package/editions/test/tiddlers/tests/test-prefixes-filter.js +2 -0
  292. package/editions/test/tiddlers/tests/test-utils.js +6 -0
  293. package/editions/test/tiddlers/tests/test-widget.js +2 -1
  294. package/editions/test/tiddlers/tests/test-wikitext-tabs-macro.js +8 -7
  295. package/editions/test/tiddlers/tests/test-wikitext.js +8 -1
  296. package/editions/translators/tiddlywiki.info +7 -1
  297. package/editions/tw.org/tiddlers/$__config_DefaultSidebarTab.tid +6 -0
  298. package/editions/tw.org/tiddlers/$__core_templates_static.content.tid +18 -0
  299. package/editions/tw.org/tiddlers/Code of Conduct.tid +30 -0
  300. package/editions/tw.org/tiddlers/Fundraising.tid +23 -0
  301. package/editions/tw.org/tiddlers/HelloThere.tid +3 -2
  302. package/editions/tw.org/tiddlers/Table of Contents.tid +2 -1
  303. package/editions/tw.org/tiddlers/_tw_shared/tiddlywiki.files +5 -0
  304. package/editions/tw5.com/tiddlers/$__StoryList.tid +3 -3
  305. package/editions/tw5.com/tiddlers/Brackets.tid +14 -0
  306. package/editions/tw5.com/tiddlers/{images → _tw_shared}/Motovun Jack.svg +0 -0
  307. package/editions/tw5.com/tiddlers/{images → _tw_shared}/Motovun Jack.svg.meta +1 -1
  308. package/editions/tw5.com/tiddlers/_tw_shared/favicons/classic.tiddlywiki.com.ico +0 -0
  309. package/editions/tw5.com/tiddlers/_tw_shared/favicons/classic.tiddlywiki.com.ico.meta +3 -0
  310. package/editions/tw5.com/tiddlers/_tw_shared/favicons/links.tiddlywiki.org.ico +0 -0
  311. package/editions/tw5.com/tiddlers/_tw_shared/favicons/links.tiddlywiki.org.ico.meta +3 -0
  312. package/editions/tw5.com/tiddlers/_tw_shared/favicons/talk.tiddlywiki.org.svg +6 -0
  313. package/editions/tw5.com/tiddlers/_tw_shared/favicons/talk.tiddlywiki.org.svg.meta +3 -0
  314. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.dev.ico +0 -0
  315. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.dev.ico.meta +3 -0
  316. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.ico +0 -0
  317. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.ico.meta +3 -0
  318. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.prerelease.ico +0 -0
  319. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.prerelease.ico.meta +3 -0
  320. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.upgrade.ico +0 -0
  321. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.com.upgrade.ico.meta +3 -0
  322. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.org.ico +0 -0
  323. package/editions/tw5.com/tiddlers/_tw_shared/favicons/tiddlywiki.org.ico.meta +3 -0
  324. package/editions/tw5.com/tiddlers/_tw_shared/sites/classic.tiddlywiki.com.tid +6 -0
  325. package/editions/tw5.com/tiddlers/_tw_shared/sites/links.tiddlywiki.org.tid +6 -0
  326. package/editions/tw5.com/tiddlers/_tw_shared/sites/talk.tiddlywiki.org.tid +6 -0
  327. package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.dev.tid +6 -0
  328. package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.prerelease.tid +6 -0
  329. package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.tid +6 -0
  330. package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.com.upgrade.tid +6 -0
  331. package/editions/tw5.com/tiddlers/_tw_shared/sites/tiddlywiki.org.tid +6 -0
  332. package/editions/tw5.com/tiddlers/_tw_shared/sites.tid +32 -0
  333. package/editions/tw5.com/tiddlers/_tw_shared/styles.tid +48 -0
  334. package/editions/tw5.com/tiddlers/_tw_shared/tags-TiddlyWikiSites.tid +3 -0
  335. package/editions/tw5.com/tiddlers/community/Community Links Aggregator.tid +1 -1
  336. package/editions/tw5.com/tiddlers/community/Contributing.tid +2 -1
  337. package/editions/tw5.com/tiddlers/community/editions/TiddlyMemo by oflg.tid +16 -0
  338. package/editions/tw5.com/tiddlers/community/resources/Projectify by Nicolas Petton.tid +6 -4
  339. package/editions/tw5.com/tiddlers/concepts/Customizing EditTemplate Field Rendering.tid +23 -7
  340. package/editions/tw5.com/tiddlers/concepts/DataTiddlers.tid +4 -21
  341. package/editions/tw5.com/tiddlers/concepts/DictionaryTiddlers.tid +3 -2
  342. package/editions/tw5.com/tiddlers/concepts/JSONTiddlers.tid +4 -3
  343. package/editions/tw5.com/tiddlers/concepts/KeyboardShortcutTiddler.tid +7 -0
  344. package/editions/tw5.com/tiddlers/concepts/Macros.tid +6 -2
  345. package/editions/tw5.com/tiddlers/concepts/Order of Tagged Tiddlers.tid +3 -1
  346. package/editions/tw5.com/tiddlers/concepts/SystemTags.tid +1 -1
  347. package/editions/tw5.com/tiddlers/concepts/TiddlyWiki5.tid +4 -2
  348. package/editions/tw5.com/tiddlers/concepts/Title List.tid +4 -1
  349. package/editions/tw5.com/tiddlers/customising/Customising TiddlyWiki's user interface.tid +2 -2
  350. package/editions/tw5.com/tiddlers/definitions/JavaScript Object Notation.tid +2 -6
  351. package/editions/tw5.com/tiddlers/definitions/Node.js.tid +5 -3
  352. package/editions/tw5.com/tiddlers/definitions/TiddlyDesktop.tid +1 -1
  353. package/editions/tw5.com/tiddlers/definitions/TiddlyWeb.tid +1 -0
  354. package/editions/tw5.com/tiddlers/demonstrations/CustomStoryTiddlerTemplateDemo.tid/Styles.tid +0 -1
  355. package/editions/tw5.com/tiddlers/features/JSON in TiddlyWiki.tid +69 -0
  356. package/editions/tw5.com/tiddlers/filters/Mathematics Operators.tid +23 -3
  357. package/editions/tw5.com/tiddlers/filters/examples/insertafter Operator (Examples).tid +28 -0
  358. package/editions/tw5.com/tiddlers/filters/format.tid +3 -1
  359. package/editions/tw5.com/tiddlers/filters/insertafter Operator.tid +35 -0
  360. package/editions/tw5.com/tiddlers/filters/insertbefore Operator.tid +9 -3
  361. package/editions/tw5.com/tiddlers/filters/syntax/Map Filter Run Prefix (Examples).tid +20 -2
  362. package/editions/tw5.com/tiddlers/filters/syntax/Map Filter Run Prefix.tid +3 -2
  363. package/editions/tw5.com/tiddlers/gettingstarted/GettingStarted.tid +6 -0
  364. package/editions/tw5.com/tiddlers/hellothere/HelloThere.tid +1 -1
  365. package/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid +16 -0
  366. package/editions/tw5.com/tiddlers/howtos/Creating a splash screen.tid +1 -1
  367. package/editions/tw5.com/tiddlers/howtos/How to apply custom styles by tag.tid +2 -2
  368. package/editions/tw5.com/tiddlers/howtos/How to customize TiddlyDesktop.tid +1 -1
  369. package/editions/tw5.com/tiddlers/howtos/How to update TiddlyWiki to the latest version.tid +7 -0
  370. package/editions/tw5.com/tiddlers/howtos/Modifying JSON tiddlers.tid +18 -0
  371. package/editions/tw5.com/tiddlers/howtos/Reading data from JSON tiddlers.tid +25 -0
  372. package/editions/tw5.com/tiddlers/images/New Release Banner.png +0 -0
  373. package/editions/tw5.com/tiddlers/macros/JsonTiddlersMacro.tid +3 -3
  374. package/editions/tw5.com/tiddlers/macros/TagMacro.tid +1 -1
  375. package/editions/tw5.com/tiddlers/macros/jsontiddler Macro.tid +2 -2
  376. package/editions/tw5.com/tiddlers/macros/list-links-draggable Macro.tid +2 -0
  377. package/editions/tw5.com/tiddlers/mechanisms/InfoMechanism.tid +1 -0
  378. package/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid +1 -1
  379. package/editions/tw5.com/tiddlers/messages/WidgetMessage_ tm-close-window.tid +3 -1
  380. package/editions/tw5.com/tiddlers/messages/WidgetMessage_ tm-new-tiddler.tid +11 -2
  381. package/editions/tw5.com/tiddlers/nodejs/Environment Variables on Node.js.tid +5 -5
  382. package/editions/tw5.com/tiddlers/nodejs/Installing TiddlyWiki on Node.js.tid +5 -10
  383. package/editions/tw5.com/tiddlers/nodejs/Installing custom plugins on Node.js.tid +11 -19
  384. package/editions/tw5.com/tiddlers/nodejs/Installing official plugins on Node.js.tid +40 -0
  385. package/editions/tw5.com/tiddlers/nodejs/PluginsCS.tid +9 -0
  386. package/editions/tw5.com/tiddlers/nodejs/TiddlyWiki on Node.js.tid +7 -2
  387. package/editions/tw5.com/tiddlers/nodejs/Uninstalling a plugin with Node.js.tid +31 -0
  388. package/editions/tw5.com/tiddlers/nodejs/Using TiddlyWiki on Node.js.tid +4 -4
  389. package/editions/tw5.com/tiddlers/platforms/TiddlyWiki in the Sky for TiddlyWeb.tid +2 -1
  390. package/editions/tw5.com/tiddlers/plugins/Installing a plugin from the plugin library.tid +22 -35
  391. package/editions/tw5.com/tiddlers/plugins/Manually installing a plugin.tid +19 -4
  392. package/editions/tw5.com/tiddlers/plugins/OfficialPlugins.tid +3 -1
  393. package/editions/tw5.com/tiddlers/plugins/Plugin Ordering.tid +47 -0
  394. package/editions/tw5.com/tiddlers/plugins/PluginFolders.tid +27 -1
  395. package/editions/tw5.com/tiddlers/plugins/Plugins.tid +19 -7
  396. package/editions/tw5.com/tiddlers/plugins/Uninstalling a plugin.tid +15 -25
  397. package/editions/tw5.com/tiddlers/releasenotes/Release 5.1.23.tid +32 -34
  398. package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.0.tid +36 -38
  399. package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.1.tid +16 -18
  400. package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.2.tid +26 -28
  401. package/editions/tw5.com/tiddlers/releasenotes/Release 5.2.3.tid +152 -0
  402. package/editions/tw5.com/tiddlers/releasenotes/Releases.tid +1 -1
  403. package/editions/tw5.com/tiddlers/saving/Saving on Android.tid +1 -1
  404. package/editions/tw5.com/tiddlers/saving/Saving on TidGi.tid +1 -1
  405. package/editions/tw5.com/tiddlers/saving/Saving on TiddlyDesktop.tid +3 -3
  406. package/editions/tw5.com/tiddlers/saving/Saving on iPad_iPhone.tid +1 -1
  407. package/editions/tw5.com/tiddlers/saving/Saving via WebDAV.tid +5 -3
  408. package/editions/tw5.com/tiddlers/saving/Saving.tid +9 -11
  409. package/editions/tw5.com/tiddlers/system/Deprecated.tid +4 -4
  410. package/editions/tw5.com/tiddlers/system/Deprecated_-_What_does_it_mean.tid +2 -6
  411. package/editions/tw5.com/tiddlers/system/doc-macros.tid +11 -1
  412. package/editions/tw5.com/tiddlers/system/doc-styles.tid +34 -4
  413. package/editions/tw5.com/tiddlers/system/download-empty-button.tid +1 -1
  414. package/editions/tw5.com/tiddlers/system/systemtag-template.tid +21 -0
  415. package/editions/tw5.com/tiddlers/system/tw5.com-card-template.tid +12 -8
  416. package/editions/tw5.com/tiddlers/system/tw5.com-styles.tid +5 -6
  417. package/editions/tw5.com/tiddlers/system/version-macros.tid +3 -3
  418. package/editions/tw5.com/tiddlers/system/wikitext-macros.tid +38 -3
  419. package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Macro_View_Body.tid +9 -0
  420. package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_ViewTemplate.tid +2 -2
  421. package/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_ViewTemplateSubtitle.tid +9 -0
  422. package/editions/tw5.com/tiddlers/tiddlydesktop/TiddlyDesktop_Releases.tid +1 -1
  423. package/editions/tw5.com/tiddlers/variables/modifier Variable.tid +2 -2
  424. package/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid +77 -3
  425. package/editions/tw5.com/tiddlers/widgets/DraggableWidget.tid +19 -3
  426. package/editions/tw5.com/tiddlers/widgets/EventCatcherWidget.tid +3 -1
  427. package/editions/tw5.com/tiddlers/widgets/ImageWidget.tid +5 -3
  428. package/editions/tw5.com/tiddlers/widgets/JSONTiddlerWidget.tid +5 -4
  429. package/editions/tw5.com/tiddlers/widgets/ListWidget.tid +2 -2
  430. package/editions/tw5.com/tiddlers/widgets/ScrollableWidget.tid +3 -3
  431. package/editions/tw5.com/tiddlers/widgets/SetWidget.tid +3 -1
  432. package/editions/tw5.com/tiddlers/widgets/TranscludeWidget.tid +2 -5
  433. package/editions/tw5.com/tiddlers/wikitext/Code Blocks in WikiText.tid +4 -7
  434. package/editions/tw5.com/tiddlers/wikitext/Dashes in WikiText.tid +7 -3
  435. package/editions/tw5.com/tiddlers/wikitext/Formatting in WikiText.tid +7 -7
  436. package/editions/tw5.com/tiddlers/wikitext/Headings in WikiText.tid +3 -3
  437. package/editions/tw5.com/tiddlers/wikitext/Horizontal Rules in WikiText.tid +3 -5
  438. package/editions/tw5.com/tiddlers/wikitext/Tables in WikiText.tid +13 -37
  439. package/editions/tw5.com/tiddlers/wikitext/Widgets in WikiText.tid +4 -4
  440. package/editions/tw5.com/tiddlers/wikitext/parser/WikiText Parser Modes.tid +1 -1
  441. package/languages/de-DE/EditTemplate.multids +1 -0
  442. package/languages/de-DE/Help/render.tid +2 -1
  443. package/languages/de-DE/SideBar.multids +1 -0
  444. package/languages/fr-FR/ControlPanel.multids +18 -0
  445. package/languages/fr-FR/EditTemplate.multids +1 -0
  446. package/languages/fr-FR/Fields.multids +4 -2
  447. package/languages/fr-FR/Help/default.tid +4 -1
  448. package/languages/fr-FR/Help/render.tid +2 -1
  449. package/languages/fr-FR/Misc.multids +1 -1
  450. package/languages/fr-FR/SideBar.multids +1 -0
  451. package/languages/ja-JP/Buttons.multids +147 -30
  452. package/languages/ja-JP/ControlPanel.multids +175 -37
  453. package/languages/ja-JP/CoreReadMe.tid +2 -2
  454. package/languages/ja-JP/Dates.multids +24 -24
  455. package/languages/ja-JP/Docs/ModuleTypes.multids +3 -3
  456. package/languages/ja-JP/Docs/PaletteColours.multids +18 -18
  457. package/languages/ja-JP/EditTemplate.multids +23 -7
  458. package/languages/ja-JP/Exporters.multids +1 -1
  459. package/languages/ja-JP/Fields.multids +28 -23
  460. package/languages/ja-JP/Filters.multids +12 -9
  461. package/languages/ja-JP/GettingStarted.tid +6 -6
  462. package/languages/ja-JP/Help/build.tid +2 -2
  463. package/languages/ja-JP/Help/editions.tid +6 -2
  464. package/languages/ja-JP/Help/help.tid +1 -1
  465. package/languages/ja-JP/Help/init.tid +2 -2
  466. package/languages/ja-JP/Help/load.tid +2 -2
  467. package/languages/ja-JP/Help/makelibrary.tid +3 -3
  468. package/languages/ja-JP/Help/output.tid +2 -2
  469. package/languages/ja-JP/Help/rendertiddler.tid +2 -2
  470. package/languages/ja-JP/Help/rendertiddlers.tid +2 -2
  471. package/languages/ja-JP/Help/savetiddler.tid +2 -2
  472. package/languages/ja-JP/Help/savetiddlers.tid +12 -2
  473. package/languages/ja-JP/Help/server.tid +6 -6
  474. package/languages/ja-JP/Help/setfield.tid +7 -7
  475. package/languages/ja-JP/Help/unpackplugin.tid +2 -2
  476. package/languages/ja-JP/Help/verbose.tid +6 -2
  477. package/languages/ja-JP/Help/version.tid +2 -2
  478. package/languages/ja-JP/Import.multids +27 -8
  479. package/languages/ja-JP/Misc.multids +98 -11
  480. package/languages/ja-JP/Modals/Download.tid +2 -2
  481. package/languages/ja-JP/Notifications.multids +2 -2
  482. package/languages/ja-JP/Search.multids +8 -4
  483. package/languages/ja-JP/SideBar.multids +6 -4
  484. package/languages/ja-JP/SiteSubtitle.tid +1 -1
  485. package/languages/ja-JP/SiteTitle.tid +1 -1
  486. package/languages/ja-JP/TiddlerInfo.multids +10 -10
  487. package/languages/ja-JP/Types/application%2Fjavascript.tid +1 -1
  488. package/languages/ja-JP/Types/image%2Fgif.tid +1 -1
  489. package/languages/ja-JP/Types/image%2Fjpeg.tid +1 -1
  490. package/languages/ja-JP/Types/image%2Fpng.tid +1 -1
  491. package/languages/ja-JP/Types/image%2Fsvg%2Bxml.tid +1 -1
  492. package/languages/ja-JP/Types/image%2Fx-icon.tid +1 -1
  493. package/languages/ja-JP/Types/text%2Fcss.tid +1 -1
  494. package/languages/ja-JP/Types/text%2Fvnd.tiddlywiki.tid +1 -1
  495. package/languages/ja-JP/plugin.info +1 -1
  496. package/languages/pl-PL/ControlPanel.multids +3 -1
  497. package/languages/pl-PL/EditTemplate.multids +1 -0
  498. package/languages/pl-PL/Fields.multids +3 -3
  499. package/languages/pl-PL/Help/default.tid +4 -1
  500. package/languages/pl-PL/Import.multids +3 -3
  501. package/languages/pl-PL/SideBar.multids +1 -0
  502. package/languages/zh-Hans/EditTemplate.multids +1 -0
  503. package/languages/zh-Hans/Help/default.tid +4 -1
  504. package/languages/zh-Hans/Help/render.tid +1 -0
  505. package/languages/zh-Hans/SideBar.multids +1 -0
  506. package/languages/zh-Hant/EditTemplate.multids +1 -0
  507. package/languages/zh-Hant/Help/default.tid +4 -1
  508. package/languages/zh-Hant/Help/render.tid +1 -0
  509. package/languages/zh-Hant/SideBar.multids +1 -0
  510. package/licenses/cla-individual.md +10 -0
  511. package/package.json +1 -1
  512. package/plugins/tiddlywiki/browser-sniff/browser.js +5 -1
  513. package/plugins/tiddlywiki/browser-sniff/usage.tid +1 -0
  514. package/plugins/tiddlywiki/browser-storage/rawmarkup.js +18 -1
  515. package/plugins/tiddlywiki/browser-storage/readme.tid +0 -1
  516. package/plugins/tiddlywiki/browser-storage/settings.tid +5 -1
  517. package/plugins/tiddlywiki/browser-storage/startup.js +14 -9
  518. package/plugins/tiddlywiki/dynannotate/docs/readme.tid +72 -8
  519. package/plugins/tiddlywiki/dynannotate/modules/dynannotate.js +10 -1
  520. package/plugins/tiddlywiki/dynannotate/modules/legacy-selection-tracker.js +104 -0
  521. package/plugins/tiddlywiki/dynannotate/modules/selection-tracker.js +144 -89
  522. package/plugins/tiddlywiki/dynannotate/modules/startup.js +40 -0
  523. package/{editions/katexdemo/tiddlers → plugins/tiddlywiki/katex}/ImplementationNotes.tid +3 -3
  524. package/plugins/tiddlywiki/katex/developer.tid +58 -0
  525. package/plugins/tiddlywiki/katex/files/contrib/mhchem.min.js +1 -0
  526. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.woff +0 -0
  527. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
  528. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
  529. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.woff +0 -0
  530. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.woff +0 -0
  531. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.woff +0 -0
  532. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.woff +0 -0
  533. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.woff +0 -0
  534. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.woff +0 -0
  535. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.woff +0 -0
  536. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.woff +0 -0
  537. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.woff +0 -0
  538. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.woff +0 -0
  539. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.woff +0 -0
  540. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.woff +0 -0
  541. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.woff +0 -0
  542. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.woff +0 -0
  543. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.woff +0 -0
  544. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.woff +0 -0
  545. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.woff +0 -0
  546. package/plugins/tiddlywiki/katex/files/katex.min.css +1 -1
  547. package/plugins/tiddlywiki/katex/files/katex.min.js +1 -1
  548. package/plugins/tiddlywiki/katex/files/katex.without-font-face.min.css +1 -1
  549. package/plugins/tiddlywiki/katex/files/tiddlywiki.files +2 -2
  550. package/plugins/tiddlywiki/katex/plugin.info +1 -1
  551. package/plugins/tiddlywiki/katex/readme.tid +1 -1
  552. package/plugins/tiddlywiki/katex/snippets/logo.tid +4 -0
  553. package/plugins/tiddlywiki/katex/snippets/math.tid +8 -0
  554. package/plugins/tiddlywiki/katex/styles.tid +7 -0
  555. package/plugins/tiddlywiki/katex/usage.tid +18 -2
  556. package/plugins/tiddlywiki/markdown/EditorToolbar/link-dropdown.tid +73 -0
  557. package/plugins/tiddlywiki/markdown/EditorToolbar/link.tid +11 -0
  558. package/plugins/tiddlywiki/markdown/EditorToolbar/linkify.tid +15 -0
  559. package/plugins/tiddlywiki/markdown/EditorToolbar/mono-block.tid +17 -0
  560. package/plugins/tiddlywiki/markdown/KeyboardShortcuts/new-markdown-tiddler.tid +8 -0
  561. package/plugins/tiddlywiki/markdown/config.multids +5 -0
  562. package/plugins/tiddlywiki/markdown/editor-operations/make-markdown-link.js +37 -0
  563. package/plugins/tiddlywiki/markdown/images/markdown-linkify.tid +6 -0
  564. package/plugins/tiddlywiki/menubar/items/search.tid +2 -0
  565. package/plugins/tiddlywiki/tiddlyweb/save-wiki-button.tid +1 -1
  566. package/readme.md +5 -3
  567. package/themes/tiddlywiki/vanilla/base.tid +21 -3
  568. package/.github/ISSUE_TEMPLATE/bug_report.md +0 -43
  569. package/editions/fr-FR/tiddlers/$__core_ui_SideBar_Open.tid +0 -15
  570. package/editions/fr-FR/tiddlers/Horizontal Rules in WikiText.tid +0 -17
  571. package/editions/fr-FR/tiddlers/Installing TiddlyWiki on Node.js.tid +0 -23
  572. package/editions/fr-FR/tiddlers/Macro_Calls_in_WikiText.tid +0 -22
  573. package/editions/fr-FR/tiddlers/Pragma.tid +0 -17
  574. package/editions/fr-FR/tiddlers/Saving on Android.tid +0 -10
  575. package/editions/fr-FR/tiddlers/Saving on InternetExplorer.tid +0 -11
  576. package/editions/fr-FR/tiddlers/Saving on Safari.tid +0 -24
  577. package/editions/fr-FR/tiddlers/Saving on iPad_iPhone.tid +0 -23
  578. package/editions/fr-FR/tiddlers/Saving with TiddlyFox.tid +0 -24
  579. package/editions/fr-FR/tiddlers/Saving with TiddlyIE.tid +0 -19
  580. package/editions/fr-FR/tiddlers/Saving_on_a_PHP_Server.tid +0 -30
  581. package/editions/fr-FR/tiddlers/Tables_in_WikiText.tid +0 -102
  582. package/editions/fr-FR/tiddlers/TiddlyDesktop.tid +0 -23
  583. package/editions/fr-FR/tiddlers/TiddlyDesktop_Releases.tid +0 -9
  584. package/editions/fr-FR/tiddlers/TiddlyWiki on Node.js.tid +0 -18
  585. package/editions/fr-FR/tiddlers/TranscludeWidget.tid +0 -73
  586. package/editions/fr-FR/tiddlers/Widgets_in_WikiText.tid +0 -30
  587. package/editions/katexdemo/tiddlers/DefaultTiddlers.tid +0 -5
  588. package/plugins/tiddlywiki/katex/files/README.md +0 -119
  589. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.ttf +0 -0
  590. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_AMS-Regular.woff2 +0 -0
  591. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
  592. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
  593. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
  594. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
  595. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
  596. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
  597. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
  598. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
  599. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.ttf +0 -0
  600. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Bold.woff2 +0 -0
  601. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
  602. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
  603. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.ttf +0 -0
  604. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Italic.woff2 +0 -0
  605. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.ttf +0 -0
  606. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Main-Regular.woff2 +0 -0
  607. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
  608. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
  609. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.ttf +0 -0
  610. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Math-Italic.woff2 +0 -0
  611. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
  612. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
  613. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
  614. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
  615. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
  616. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
  617. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.ttf +0 -0
  618. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Script-Regular.woff2 +0 -0
  619. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.ttf +0 -0
  620. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size1-Regular.woff2 +0 -0
  621. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.ttf +0 -0
  622. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size2-Regular.woff2 +0 -0
  623. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.ttf +0 -0
  624. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size3-Regular.woff2 +0 -0
  625. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.ttf +0 -0
  626. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Size4-Regular.woff2 +0 -0
  627. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
  628. package/plugins/tiddlywiki/katex/files/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
  629. package/plugins/tiddlywiki/katex/files/katex.css +0 -1079
  630. package/plugins/tiddlywiki/katex/files/katex.js +0 -18183
  631. package/plugins/tiddlywiki/katex/files/mhchem.min.js +0 -1
@@ -1,9 +1,9 @@
1
1
  /*\
2
2
  title: $:/plugins/tiddlywiki/dynannotate/selection-tracker.js
3
3
  type: application/javascript
4
- module-type: startup
4
+ module-type: library
5
5
 
6
- Dyannotate background daemon to track the selection
6
+ Background daemon to track the selection
7
7
 
8
8
  \*/
9
9
  (function(){
@@ -12,105 +12,160 @@ Dyannotate background daemon to track the selection
12
12
  /*global $tw: false */
13
13
  "use strict";
14
14
 
15
- // Export name and synchronous status
16
- exports.name = "dyannotate-startup";
17
- exports.platforms = ["browser"];
18
- exports.after = ["render"];
19
- exports.synchronous = true;
20
-
21
- var TextMap = require("$:/plugins/tiddlywiki/dynannotate/textmap.js").TextMap;
22
-
23
- exports.startup = function() {
24
- $tw.dynannotate = {
25
- selectionTracker: new SelectionTracker($tw.wiki,{
26
- allowBlankSelectionPopup: true
27
- })
28
- };
29
- };
30
-
31
15
  function SelectionTracker(wiki,options) {
32
16
  options = options || {};
33
17
  var self = this;
34
18
  this.wiki = wiki;
35
- this.allowBlankSelectionPopup = options.allowBlankSelectionPopup;
36
- this.selectionPopupTitle = null;
19
+ var timerId = null;
37
20
  document.addEventListener("selectionchange",function(event) {
38
- var selection = document.getSelection();
39
- if(selection && (selection.type === "Range" || (self.allowBlankSelectionPopup && !self.selectionPopupTitle))) {
40
- // Look for the selection containers for each of the two ends of the selection
41
- var anchorContainer = self.findSelectionContainer(selection.anchorNode),
42
- focusContainer = self.findSelectionContainer(selection.focusNode);
43
- // If either end of the selection then we ignore it
44
- if(!!anchorContainer || !!focusContainer) {
45
- var selectionRange = selection.getRangeAt(0);
46
- // Check for the selection spilling outside the starting container
47
- if((anchorContainer !== focusContainer) || (selectionRange.startContainer.nodeType !== Node.TEXT_NODE && selectionRange.endContainer.nodeType !== Node.TEXT_NODE)) {
48
- if(self.selectionPopupTitle) {
49
- self.wiki.deleteTiddler(self.selectionPopupTitle);
50
- self.selectionPopupTitle = null;
51
- }
52
- } else {
53
- self.selectionSaveTitle = anchorContainer.getAttribute("data-annotation-selection-save");
54
- self.selectionPrefixSaveTitle = anchorContainer.getAttribute("data-annotation-selection-prefix-save");
55
- self.selectionSuffixSaveTitle = anchorContainer.getAttribute("data-annotation-selection-suffix-save");
56
- self.selectionPopupTitle = anchorContainer.getAttribute("data-annotation-selection-popup");
57
- // The selection is a range so we trigger the popup
58
- if(self.selectionPopupTitle) {
59
- var selectionRectangle = selectionRange.getBoundingClientRect(),
60
- trackingRectangle = anchorContainer.getBoundingClientRect();
61
- $tw.popup.triggerPopup({
62
- domNode: null,
63
- domNodeRect: {
64
- left: selectionRectangle.left - trackingRectangle.left,
65
- top: selectionRectangle.top - trackingRectangle.top,
66
- width: selectionRectangle.width,
67
- height: selectionRectangle.height
68
- },
69
- force: true,
70
- floating: true,
71
- title: self.selectionPopupTitle,
72
- wiki: self.wiki
73
- });
74
- }
75
- // Write the selection text to the specified tiddler
76
- if(self.selectionSaveTitle) {
77
- // Note that selection.toString() normalizes whitespace but selection.getRangeAt(0).toString() does not
78
- var text = selectionRange.toString();
79
- self.wiki.addTiddler(new $tw.Tiddler({title: self.selectionSaveTitle, text: text}));
80
- // Build a textmap of the container so that we can find the prefix and suffix
81
- var textMap = new TextMap(anchorContainer);
82
- // Find the selection start in the text map and hence extract the prefix and suffix
83
- var context = textMap.extractContext(selectionRange.startContainer,selectionRange.startOffset,text);
84
- // Save the prefix and suffix
85
- if(context) {
86
- if(self.selectionPrefixSaveTitle) {
87
- self.wiki.addTiddler(new $tw.Tiddler({title: self.selectionPrefixSaveTitle, text: context.prefix}));
88
- }
89
- if(self.selectionSuffixSaveTitle) {
90
- self.wiki.addTiddler(new $tw.Tiddler({title: self.selectionSuffixSaveTitle, text: context.suffix}));
91
- }
21
+ if(timerId) {
22
+ clearTimeout(timerId);
23
+ }
24
+ timerId = setTimeout(function() {
25
+ timerId = null;
26
+ self.handleSelectionChange();
27
+ },500);
28
+ });
29
+ }
30
+
31
+ SelectionTracker.prototype.handleSelectionChange = function() {
32
+ var selection = document.getSelection();
33
+ if(selection && selection.type === "Range") {
34
+ // Helper to get the tiddler title corresponding to a chunk container
35
+ var getIdOfContainer = function(domNode) {
36
+ return domNode.id;
37
+ }
38
+ // Get information about the selection anchor and focus
39
+ var getSelectionInfo = function(targetDomNode,targetOffset) {
40
+ // Find the chunk container node
41
+ var domNode = targetDomNode;
42
+ if(domNode.nodeType === Node.TEXT_NODE) {
43
+ domNode = domNode.parentNode;
44
+ }
45
+ var container = domNode.closest(".dynannotate-chunk");
46
+ if(!container) {
47
+ return null;
48
+ }
49
+ // Find the index of the container within the child nodes of its parent
50
+ var childNodeIndex = Array.prototype.indexOf.call(container.parentNode.childNodes,container);
51
+ // Walk through the chunk collecting the text before and after the specified domNode and offset
52
+ var beforeText = null, afterText = [];
53
+ var splitTextResult = function() {
54
+ beforeText = afterText;
55
+ afterText = [];
56
+ },
57
+ processNode = function(domNode) {
58
+ // Check for a text node
59
+ if(domNode.nodeType === Node.TEXT_NODE) {
60
+ // If this is the target node then perform the split
61
+ if(domNode === targetDomNode) {
62
+ afterText.push(domNode.textContent.substring(0,targetOffset));
63
+ splitTextResult();
64
+ afterText.push(domNode.textContent.substring(targetOffset));
65
+ } else {
66
+ afterText.push(domNode.textContent);
92
67
  }
68
+ } else {
69
+ // Process the child nodes
70
+ $tw.utils.each(domNode.childNodes,function(childNode,childNodeIndex) {
71
+ // Check whether we need to split on this child node
72
+ if(domNode === targetDomNode && childNodeIndex === targetOffset) {
73
+ splitTextResult();
74
+ }
75
+ processNode(childNode);
76
+ });
93
77
  }
94
- }
78
+ };
79
+ processNode(container);
80
+ if(beforeText === null) {
81
+ splitTextResult();
95
82
  }
96
- } else {
97
- // If the selection is a caret we clear any active popup
98
- if(self.selectionPopupTitle) {
99
- self.wiki.deleteTiddler(self.selectionPopupTitle);
100
- self.selectionPopupTitle = null;
83
+ // Return results
84
+ return {
85
+ container: container,
86
+ childNodeIndex: childNodeIndex,
87
+ beforeText: beforeText.join(""),
88
+ afterText: afterText.join("")
101
89
  }
102
- }
103
- });
104
- }
105
90
 
106
- SelectionTracker.prototype.findSelectionContainer = function findSelectionContainer(domNode) {
107
- if(domNode && domNode.nodeType === Node.ELEMENT_NODE && domNode.classList.contains("tc-dynannotation-selection-container")) {
108
- return domNode;
91
+ }
92
+ var anchor = getSelectionInfo(selection.anchorNode,selection.anchorOffset),
93
+ focus = getSelectionInfo(selection.focusNode,selection.focusOffset);
94
+ // Check that the containers share a parent
95
+ if(anchor && focus && anchor.container.parentNode === focus.container.parentNode) {
96
+ // Make sure that the anchor is before the focus
97
+ if((anchor.childNodeIndex > focus.childNodeIndex) || (anchor.container === focus.container && anchor.beforeText.length > focus.beforeText.length)) {
98
+ var temp = anchor;
99
+ anchor = focus;
100
+ focus = temp;
101
+ }
102
+ var chunks = [];
103
+ // Check for the selection being all in one chunk
104
+ if(anchor.container === focus.container) {
105
+ chunks.push({
106
+ id: getIdOfContainer(anchor.container),
107
+ prefix: anchor.beforeText,
108
+ text: anchor.afterText.substring(0,anchor.afterText.length - focus.afterText.length),
109
+ suffix: focus.afterText
110
+ });
111
+ } else {
112
+ // We span two or more chunks
113
+ chunks.push({
114
+ id: getIdOfContainer(anchor.container),
115
+ prefix: anchor.beforeText,
116
+ text: anchor.afterText
117
+ });
118
+ // Get the titles and text of the intervening tiddlers
119
+ var domNode;
120
+ if(anchor.container !== focus.container) {
121
+ domNode = anchor.container.nextElementSibling;
122
+ while(domNode && domNode !== focus.container) {
123
+ chunks.push({
124
+ id: getIdOfContainer(domNode),
125
+ text: domNode.textContent
126
+ });
127
+ domNode = domNode.nextElementSibling;
128
+ }
129
+ }
130
+ chunks.push({
131
+ id: getIdOfContainer(focus.container),
132
+ text: focus.beforeText,
133
+ suffix: focus.afterText
134
+ });
135
+ }
136
+ // Get the title of the tiddler containing the actions to be executed
137
+ var actionsTiddler = anchor.container.parentNode.getAttribute("data-selection-actions-title");
138
+ // Assemble the variables to be passed to the action
139
+ var variables = {};
140
+ // Get the bounds of the container and the selection
141
+ var selectionRectangle = selection.getRangeAt(0).getBoundingClientRect(),
142
+ offsetParentRectangle = anchor.container.offsetParent.getBoundingClientRect();
143
+ variables["tv-selection-posx"] = (selectionRectangle.left - offsetParentRectangle.left).toString();
144
+ variables["tv-selection-posy"] = (selectionRectangle.top - offsetParentRectangle.top).toString();
145
+ variables["tv-selection-width"] = (selectionRectangle.width).toString();
146
+ variables["tv-selection-height"] = (selectionRectangle.height).toString();
147
+ variables["tv-selection-coords"] = "(" + variables["tv-selection-posx"] + "," + variables["tv-selection-posy"] + "," + variables["tv-selection-width"] + "," + variables["tv-selection-height"] + ")";
148
+ // Collect the attributes from the container
149
+ $tw.utils.each(anchor.container.parentNode.attributes,function(attribute) {
150
+ variables["dom-" + attribute.name] = attribute.value.toString();
151
+ });
152
+ // Action the selection
153
+ this.performSelectionActions(chunks,variables,actionsTiddler);
154
+ }
109
155
  }
110
- if(domNode && domNode.parentNode) {
111
- return findSelectionContainer(domNode.parentNode);
156
+ };
157
+
158
+ SelectionTracker.prototype.performSelectionActions = function(chunks,variables,actionsTiddler) {
159
+ // Invoke the actions, passing the extract tiddler title as a variable
160
+ if(actionsTiddler) {
161
+ var actions = $tw.wiki.getTiddlerText(actionsTiddler)
162
+ if(actions) {
163
+ var selection = JSON.stringify({chunks: chunks,variables: variables});
164
+ $tw.rootWidget.invokeActionString(actions,undefined,undefined,$tw.utils.extend({},variables,{selection: selection}));
165
+ }
112
166
  }
113
- return null;
114
167
  };
115
168
 
169
+ exports.SelectionTracker = SelectionTracker;
170
+
116
171
  })();
@@ -0,0 +1,40 @@
1
+ /*\
2
+ title: $:/plugins/tiddlywiki/dynannotate/startup.js
3
+ type: application/javascript
4
+ module-type: startup
5
+
6
+ Startup the dyannotate background daemon to track the selection
7
+
8
+ \*/
9
+ (function(){
10
+
11
+ /*jslint node: true, browser: true */
12
+ /*global $tw: false */
13
+ "use strict";
14
+
15
+ // Export name and synchronous status
16
+ exports.name = "dyannotate-startup";
17
+ exports.platforms = ["browser"];
18
+ exports.after = ["render"];
19
+ exports.synchronous = true;
20
+
21
+ var CONFIG_SELECTION_TRACKER_TITLE = "$:/config/Dynannotate/SelectionTracker/Enable",
22
+ CONFIG_LEGACY_SELECTION_TRACKER_TITLE = "$:/config/Dynannotate/LegacySelectionTracker/Enable";
23
+
24
+ var SelectionTracker = require("$:/plugins/tiddlywiki/dynannotate/selection-tracker.js").SelectionTracker,
25
+ LegacySelectionTracker = require("$:/plugins/tiddlywiki/dynannotate/legacy-selection-tracker.js").LegacySelectionTracker;
26
+
27
+ exports.startup = function() {
28
+ $tw.dynannotate = {};
29
+ if($tw.wiki.getTiddlerText(CONFIG_SELECTION_TRACKER_TITLE,"yes") === "yes") {
30
+ $tw.dynannotate.selectionTracker = new SelectionTracker($tw.wiki);
31
+ }
32
+ if($tw.wiki.getTiddlerText(CONFIG_LEGACY_SELECTION_TRACKER_TITLE,"yes") === "yes") {
33
+ $tw.dynannotate.legacySelectionTracker = new LegacySelectionTracker($tw.wiki,{
34
+ allowBlankSelectionPopup: true
35
+ });
36
+ }
37
+ };
38
+
39
+ })();
40
+
@@ -1,8 +1,8 @@
1
- title: ImplementationNotes
1
+ title: $:/plugins/tiddlywiki/katex/ImplementationNotes
2
2
 
3
3
  ! CSS Handling
4
4
 
5
- The [[original CSS from KaTeX|https://github.com/Khan/KaTeX/blob/master/static%2Ffonts.css]] includes a number of font definitions in this format:
5
+ The ''original CSS from KaTeX'' includes a number of font definitions in this format:
6
6
 
7
7
  ```
8
8
  @font-face {
@@ -16,7 +16,7 @@ The [[original CSS from KaTeX|https://github.com/Khan/KaTeX/blob/master/static%2
16
16
  }
17
17
  ```
18
18
 
19
- These definitions are currently removed manually from [[$:/plugins/tiddlywiki/katex/katex.min.css]] so that they can be redefined as data URIs using TiddlyWiki's macro notation:
19
+ These definitions are currently ''removed manually'' from [[$:/plugins/tiddlywiki/katex/katex.min.css]] so that they can be redefined as data URIs using TiddlyWiki's macro notation in $:/plugins/tiddlywiki/katex/styles
20
20
 
21
21
  ```
22
22
  @font-face {
@@ -0,0 +1,58 @@
1
+ title: $:/plugins/tiddlywiki/katex/developer
2
+
3
+ !! How to upgrade
4
+
5
+ # Download latest release zip file from [[Github release|https://github.com/KaTeX/KaTeX/releases]]
6
+ # Backup existing files
7
+ #* `plugins/tiddlywiki/katex/files/tiddlywiki.files` file and
8
+ #* `katex.without-font-face.min.css` file
9
+ #* Learn more at: $:/plugins/tiddlywiki/katex/ImplementationNotes
10
+ # Rename extracted folder to "files" and
11
+ #* copy it to `plugins/tiddlywiki/katex/files`
12
+ #* (maybe delete the old folder first, to make a full overwrite)
13
+ #* delete unused files in it, like `*.mjs` files and `*.md` files
14
+ # Create `plugins/tiddlywiki/katex/files/tiddlywiki.files`
15
+ #* (or use the old one) and
16
+ #* register all needed files
17
+ # Register in `files/tiddlywiki.files`
18
+ #* `katex.without-font-face.min.css` ''as''
19
+ #* `$:/plugins/tiddlywiki/katex/katex.min.css`
20
+ #* so fonts are loaded properly in tw environment
21
+
22
+
23
+ !! How to test
24
+
25
+ To create a new "test edition" type the following command in a console window:
26
+
27
+ <<<
28
+ ```
29
+ node tiddlywiki test-katex --init katexdemo
30
+ ```
31
+ <<<
32
+
33
+ >It will create a new directory //test-katex// and clones the //katexdemo// edition.<br>The output should be:
34
+
35
+ <<<
36
+ `Copied edition 'katexdemo' to test-katex`
37
+ <<<
38
+
39
+ Type:
40
+
41
+ <<<
42
+ ```
43
+ node tiddlywiki test-katex --listen
44
+ ```
45
+ <<<
46
+
47
+ >It should output
48
+
49
+ <<<
50
+ `syncer-server-filesystem: Dispatching 'save' task: $:/StoryList
51
+ Serving on http://127.0.0.1:8080
52
+ (press ctrl-C to exit)
53
+ `
54
+ <<<
55
+
56
+ Test the new version in the browser at: [[http://127.0.0.1:8080]]
57
+
58
+ Make sure all equations of math and chemistry are rendered properly.
@@ -0,0 +1 @@
1
+ !function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("katex"));else if("function"==typeof define&&define.amd)define(["katex"],e);else{var n="object"==typeof exports?e(require("katex")):e(t.katex);for(var o in n)("object"==typeof exports?exports:t)[o]=n[o]}}("undefined"!=typeof self?self:this,(function(t){return function(){"use strict";var e={771:function(e){e.exports=t}},n={};function o(t){var a=n[t];if(void 0!==a)return a.exports;var r=n[t]={exports:{}};return e[t](r,r.exports,o),r.exports}o.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return o.d(e,{a:e}),e},o.d=function(t,e){for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};var a={};return function(){var t=o(771),e=o.n(t);e().__defineMacro("\\ce",(function(t){return n(t.consumeArgs(1)[0],"ce")})),e().__defineMacro("\\pu",(function(t){return n(t.consumeArgs(1)[0],"pu")})),e().__defineMacro("\\tripledash","{\\vphantom{-}\\raisebox{2.56mu}{$\\mkern2mu\\tiny\\text{-}\\mkern1mu\\text{-}\\mkern1mu\\text{-}\\mkern2mu$}}");var n=function(t,e){for(var n="",o=t.length&&t[t.length-1].loc.start,i=t.length-1;i>=0;i--)t[i].loc.start>o&&(n+=" ",o=t[i].loc.start),n+=t[i].text,o+=t[i].text.length;return r.go(a.go(n,e))},a={go:function(t,e){if(!t)return[];void 0===e&&(e="ce");var n,o="0",r={};r.parenthesisLevel=0,t=(t=(t=t.replace(/\n/g," ")).replace(/[\u2212\u2013\u2014\u2010]/g,"-")).replace(/[\u2026]/g,"...");for(var i=10,c=[];;){n!==t?(i=10,n=t):i--;var u=a.stateMachines[e],p=u.transitions[o]||u.transitions["*"];t:for(var s=0;s<p.length;s++){var _=a.patterns.match_(p[s].pattern,t);if(_){for(var d=p[s].task,m=0;m<d.action_.length;m++){var l;if(u.actions[d.action_[m].type_])l=u.actions[d.action_[m].type_](r,_.match_,d.action_[m].option);else{if(!a.actions[d.action_[m].type_])throw["MhchemBugA","mhchem bug A. Please report. ("+d.action_[m].type_+")"];l=a.actions[d.action_[m].type_](r,_.match_,d.action_[m].option)}a.concatArray(c,l)}if(o=d.nextState||o,!(t.length>0))return c;if(d.revisit||(t=_.remainder),!d.toContinue)break t}}if(i<=0)throw["MhchemBugU","mhchem bug U. Please report."]}},concatArray:function(t,e){if(e)if(Array.isArray(e))for(var n=0;n<e.length;n++)t.push(e[n]);else t.push(e)},patterns:{patterns:{empty:/^$/,else:/^./,else2:/^./,space:/^\s/,"space A":/^\s(?=[A-Z\\$])/,space$:/^\s$/,"a-z":/^[a-z]/,x:/^x/,x$:/^x$/,i$:/^i$/,letters:/^(?:[a-zA-Z\u03B1-\u03C9\u0391-\u03A9?@]|(?:\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega|Gamma|Delta|Theta|Lambda|Xi|Pi|Sigma|Upsilon|Phi|Psi|Omega)(?:\s+|\{\}|(?![a-zA-Z]))))+/,"\\greek":/^\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega|Gamma|Delta|Theta|Lambda|Xi|Pi|Sigma|Upsilon|Phi|Psi|Omega)(?:\s+|\{\}|(?![a-zA-Z]))/,"one lowercase latin letter $":/^(?:([a-z])(?:$|[^a-zA-Z]))$/,"$one lowercase latin letter$ $":/^\$(?:([a-z])(?:$|[^a-zA-Z]))\$$/,"one lowercase greek letter $":/^(?:\$?[\u03B1-\u03C9]\$?|\$?\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega)\s*\$?)(?:\s+|\{\}|(?![a-zA-Z]))$/,digits:/^[0-9]+/,"-9.,9":/^[+\-]?(?:[0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))/,"-9.,9 no missing 0":/^[+\-]?[0-9]+(?:[.,][0-9]+)?/,"(-)(9.,9)(e)(99)":function(t){var e=t.match(/^(\+\-|\+\/\-|\+|\-|\\pm\s?)?([0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))?(\((?:[0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))\))?(?:([eE]|\s*(\*|x|\\times|\u00D7)\s*10\^)([+\-]?[0-9]+|\{[+\-]?[0-9]+\}))?/);return e&&e[0]?{match_:e.splice(1),remainder:t.substr(e[0].length)}:null},"(-)(9)^(-9)":function(t){var e=t.match(/^(\+\-|\+\/\-|\+|\-|\\pm\s?)?([0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+)?)\^([+\-]?[0-9]+|\{[+\-]?[0-9]+\})/);return e&&e[0]?{match_:e.splice(1),remainder:t.substr(e[0].length)}:null},"state of aggregation $":function(t){var e=a.patterns.findObserveGroups(t,"",/^\([a-z]{1,3}(?=[\),])/,")","");if(e&&e.remainder.match(/^($|[\s,;\)\]\}])/))return e;var n=t.match(/^(?:\((?:\\ca\s?)?\$[amothc]\$\))/);return n?{match_:n[0],remainder:t.substr(n[0].length)}:null},"_{(state of aggregation)}$":/^_\{(\([a-z]{1,3}\))\}/,"{[(":/^(?:\\\{|\[|\()/,")]}":/^(?:\)|\]|\\\})/,", ":/^[,;]\s*/,",":/^[,;]/,".":/^[.]/,". ":/^([.\u22C5\u00B7\u2022])\s*/,"...":/^\.\.\.(?=$|[^.])/,"* ":/^([*])\s*/,"^{(...)}":function(t){return a.patterns.findObserveGroups(t,"^{","","","}")},"^($...$)":function(t){return a.patterns.findObserveGroups(t,"^","$","$","")},"^a":/^\^([0-9]+|[^\\_])/,"^\\x{}{}":function(t){return a.patterns.findObserveGroups(t,"^",/^\\[a-zA-Z]+\{/,"}","","","{","}","",!0)},"^\\x{}":function(t){return a.patterns.findObserveGroups(t,"^",/^\\[a-zA-Z]+\{/,"}","")},"^\\x":/^\^(\\[a-zA-Z]+)\s*/,"^(-1)":/^\^(-?\d+)/,"'":/^'/,"_{(...)}":function(t){return a.patterns.findObserveGroups(t,"_{","","","}")},"_($...$)":function(t){return a.patterns.findObserveGroups(t,"_","$","$","")},_9:/^_([+\-]?[0-9]+|[^\\])/,"_\\x{}{}":function(t){return a.patterns.findObserveGroups(t,"_",/^\\[a-zA-Z]+\{/,"}","","","{","}","",!0)},"_\\x{}":function(t){return a.patterns.findObserveGroups(t,"_",/^\\[a-zA-Z]+\{/,"}","")},"_\\x":/^_(\\[a-zA-Z]+)\s*/,"^_":/^(?:\^(?=_)|\_(?=\^)|[\^_]$)/,"{}":/^\{\}/,"{...}":function(t){return a.patterns.findObserveGroups(t,"","{","}","")},"{(...)}":function(t){return a.patterns.findObserveGroups(t,"{","","","}")},"$...$":function(t){return a.patterns.findObserveGroups(t,"","$","$","")},"${(...)}$":function(t){return a.patterns.findObserveGroups(t,"${","","","}$")},"$(...)$":function(t){return a.patterns.findObserveGroups(t,"$","","","$")},"=<>":/^[=<>]/,"#":/^[#\u2261]/,"+":/^\+/,"-$":/^-(?=[\s_},;\]/]|$|\([a-z]+\))/,"-9":/^-(?=[0-9])/,"- orbital overlap":/^-(?=(?:[spd]|sp)(?:$|[\s,;\)\]\}]))/,"-":/^-/,"pm-operator":/^(?:\\pm|\$\\pm\$|\+-|\+\/-)/,operator:/^(?:\+|(?:[\-=<>]|<<|>>|\\approx|\$\\approx\$)(?=\s|$|-?[0-9]))/,arrowUpDown:/^(?:v|\(v\)|\^|\(\^\))(?=$|[\s,;\)\]\}])/,"\\bond{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\bond{","","","}")},"->":/^(?:<->|<-->|->|<-|<=>>|<<=>|<=>|[\u2192\u27F6\u21CC])/,CMT:/^[CMT](?=\[)/,"[(...)]":function(t){return a.patterns.findObserveGroups(t,"[","","","]")},"1st-level escape":/^(&|\\\\|\\hline)\s*/,"\\,":/^(?:\\[,\ ;:])/,"\\x{}{}":function(t){return a.patterns.findObserveGroups(t,"",/^\\[a-zA-Z]+\{/,"}","","","{","}","",!0)},"\\x{}":function(t){return a.patterns.findObserveGroups(t,"",/^\\[a-zA-Z]+\{/,"}","")},"\\ca":/^\\ca(?:\s+|(?![a-zA-Z]))/,"\\x":/^(?:\\[a-zA-Z]+\s*|\\[_&{}%])/,orbital:/^(?:[0-9]{1,2}[spdfgh]|[0-9]{0,2}sp)(?=$|[^a-zA-Z])/,others:/^[\/~|]/,"\\frac{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\frac{","","","}","{","","","}")},"\\overset{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\overset{","","","}","{","","","}")},"\\underset{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\underset{","","","}","{","","","}")},"\\underbrace{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\underbrace{","","","}_","{","","","}")},"\\color{(...)}0":function(t){return a.patterns.findObserveGroups(t,"\\color{","","","}")},"\\color{(...)}{(...)}1":function(t){return a.patterns.findObserveGroups(t,"\\color{","","","}","{","","","}")},"\\color(...){(...)}2":function(t){return a.patterns.findObserveGroups(t,"\\color","\\","",/^(?=\{)/,"{","","","}")},"\\ce{(...)}":function(t){return a.patterns.findObserveGroups(t,"\\ce{","","","}")},oxidation$:/^(?:[+-][IVX]+|\\pm\s*0|\$\\pm\$\s*0)$/,"d-oxidation$":/^(?:[+-]?\s?[IVX]+|\\pm\s*0|\$\\pm\$\s*0)$/,"roman numeral":/^[IVX]+/,"1/2$":/^[+\-]?(?:[0-9]+|\$[a-z]\$|[a-z])\/[0-9]+(?:\$[a-z]\$|[a-z])?$/,amount:function(t){var e;if(e=t.match(/^(?:(?:(?:\([+\-]?[0-9]+\/[0-9]+\)|[+\-]?(?:[0-9]+|\$[a-z]\$|[a-z])\/[0-9]+|[+\-]?[0-9]+[.,][0-9]+|[+\-]?\.[0-9]+|[+\-]?[0-9]+)(?:[a-z](?=\s*[A-Z]))?)|[+\-]?[a-z](?=\s*[A-Z])|\+(?!\s))/))return{match_:e[0],remainder:t.substr(e[0].length)};var n=a.patterns.findObserveGroups(t,"","$","$","");return n&&(e=n.match_.match(/^\$(?:\(?[+\-]?(?:[0-9]*[a-z]?[+\-])?[0-9]*[a-z](?:[+\-][0-9]*[a-z]?)?\)?|\+|-)\$$/))?{match_:e[0],remainder:t.substr(e[0].length)}:null},amount2:function(t){return this.amount(t)},"(KV letters),":/^(?:[A-Z][a-z]{0,2}|i)(?=,)/,formula$:function(t){if(t.match(/^\([a-z]+\)$/))return null;var e=t.match(/^(?:[a-z]|(?:[0-9\ \+\-\,\.\(\)]+[a-z])+[0-9\ \+\-\,\.\(\)]*|(?:[a-z][0-9\ \+\-\,\.\(\)]+)+[a-z]?)$/);return e?{match_:e[0],remainder:t.substr(e[0].length)}:null},uprightEntities:/^(?:pH|pOH|pC|pK|iPr|iBu)(?=$|[^a-zA-Z])/,"/":/^\s*(\/)\s*/,"//":/^\s*(\/\/)\s*/,"*":/^\s*[*.]\s*/},findObserveGroups:function(t,e,n,o,a,r,i,c,u,p){var s=function(t,e){if("string"==typeof e)return 0!==t.indexOf(e)?null:e;var n=t.match(e);return n?n[0]:null},_=s(t,e);if(null===_)return null;if(t=t.substr(_.length),null===(_=s(t,n)))return null;var d=function(t,e,n){for(var o=0;e<t.length;){var a=t.charAt(e),r=s(t.substr(e),n);if(null!==r&&0===o)return{endMatchBegin:e,endMatchEnd:e+r.length};if("{"===a)o++;else if("}"===a){if(0===o)throw["ExtraCloseMissingOpen","Extra close brace or missing open brace"];o--}e++}return null}(t,_.length,o||a);if(null===d)return null;var m=t.substring(0,o?d.endMatchEnd:d.endMatchBegin);if(r||i){var l=this.findObserveGroups(t.substr(d.endMatchEnd),r,i,c,u);if(null===l)return null;var f=[m,l.match_];return{match_:p?f.join(""):f,remainder:l.remainder}}return{match_:m,remainder:t.substr(d.endMatchEnd)}},match_:function(t,e){var n=a.patterns.patterns[t];if(void 0===n)throw["MhchemBugP","mhchem bug P. Please report. ("+t+")"];if("function"==typeof n)return a.patterns.patterns[t](e);var o=e.match(n);return o?{match_:o[2]?[o[1],o[2]]:o[1]?o[1]:o[0],remainder:e.substr(o[0].length)}:null}},actions:{"a=":function(t,e){t.a=(t.a||"")+e},"b=":function(t,e){t.b=(t.b||"")+e},"p=":function(t,e){t.p=(t.p||"")+e},"o=":function(t,e){t.o=(t.o||"")+e},"q=":function(t,e){t.q=(t.q||"")+e},"d=":function(t,e){t.d=(t.d||"")+e},"rm=":function(t,e){t.rm=(t.rm||"")+e},"text=":function(t,e){t.text_=(t.text_||"")+e},insert:function(t,e,n){return{type_:n}},"insert+p1":function(t,e,n){return{type_:n,p1:e}},"insert+p1+p2":function(t,e,n){return{type_:n,p1:e[0],p2:e[1]}},copy:function(t,e){return e},rm:function(t,e){return{type_:"rm",p1:e||""}},text:function(t,e){return a.go(e,"text")},"{text}":function(t,e){var n=["{"];return a.concatArray(n,a.go(e,"text")),n.push("}"),n},"tex-math":function(t,e){return a.go(e,"tex-math")},"tex-math tight":function(t,e){return a.go(e,"tex-math tight")},bond:function(t,e,n){return{type_:"bond",kind_:n||e}},"color0-output":function(t,e){return{type_:"color0",color:e[0]}},ce:function(t,e){return a.go(e)},"1/2":function(t,e){var n=[];e.match(/^[+\-]/)&&(n.push(e.substr(0,1)),e=e.substr(1));var o=e.match(/^([0-9]+|\$[a-z]\$|[a-z])\/([0-9]+)(\$[a-z]\$|[a-z])?$/);return o[1]=o[1].replace(/\$/g,""),n.push({type_:"frac",p1:o[1],p2:o[2]}),o[3]&&(o[3]=o[3].replace(/\$/g,""),n.push({type_:"tex-math",p1:o[3]})),n},"9,9":function(t,e){return a.go(e,"9,9")}},createTransitions:function(t){var e,n,o,a,r={};for(e in t)for(n in t[e])for(o=n.split("|"),t[e][n].stateArray=o,a=0;a<o.length;a++)r[o[a]]=[];for(e in t)for(n in t[e])for(o=t[e][n].stateArray||[],a=0;a<o.length;a++){var i=t[e][n];if(i.action_){i.action_=[].concat(i.action_);for(var c=0;c<i.action_.length;c++)"string"==typeof i.action_[c]&&(i.action_[c]={type_:i.action_[c]})}else i.action_=[];for(var u=e.split("|"),p=0;p<u.length;p++)if("*"===o[a])for(var s in r)r[s].push({pattern:u[p],task:i});else r[o[a]].push({pattern:u[p],task:i})}return r},stateMachines:{}};a.stateMachines={ce:{transitions:a.createTransitions({empty:{"*":{action_:"output"}},else:{"0|1|2":{action_:"beginsWithBond=false",revisit:!0,toContinue:!0}},oxidation$:{0:{action_:"oxidation-output"}},CMT:{r:{action_:"rdt=",nextState:"rt"},rd:{action_:"rqt=",nextState:"rdt"}},arrowUpDown:{"0|1|2|as":{action_:["sb=false","output","operator"],nextState:"1"}},uprightEntities:{"0|1|2":{action_:["o=","output"],nextState:"1"}},orbital:{"0|1|2|3":{action_:"o=",nextState:"o"}},"->":{"0|1|2|3":{action_:"r=",nextState:"r"},"a|as":{action_:["output","r="],nextState:"r"},"*":{action_:["output","r="],nextState:"r"}},"+":{o:{action_:"d= kv",nextState:"d"},"d|D":{action_:"d=",nextState:"d"},q:{action_:"d=",nextState:"qd"},"qd|qD":{action_:"d=",nextState:"qd"},dq:{action_:["output","d="],nextState:"d"},3:{action_:["sb=false","output","operator"],nextState:"0"}},amount:{"0|2":{action_:"a=",nextState:"a"}},"pm-operator":{"0|1|2|a|as":{action_:["sb=false","output",{type_:"operator",option:"\\pm"}],nextState:"0"}},operator:{"0|1|2|a|as":{action_:["sb=false","output","operator"],nextState:"0"}},"-$":{"o|q":{action_:["charge or bond","output"],nextState:"qd"},d:{action_:"d=",nextState:"d"},D:{action_:["output",{type_:"bond",option:"-"}],nextState:"3"},q:{action_:"d=",nextState:"qd"},qd:{action_:"d=",nextState:"qd"},"qD|dq":{action_:["output",{type_:"bond",option:"-"}],nextState:"3"}},"-9":{"3|o":{action_:["output",{type_:"insert",option:"hyphen"}],nextState:"3"}},"- orbital overlap":{o:{action_:["output",{type_:"insert",option:"hyphen"}],nextState:"2"},d:{action_:["output",{type_:"insert",option:"hyphen"}],nextState:"2"}},"-":{"0|1|2":{action_:[{type_:"output",option:1},"beginsWithBond=true",{type_:"bond",option:"-"}],nextState:"3"},3:{action_:{type_:"bond",option:"-"}},a:{action_:["output",{type_:"insert",option:"hyphen"}],nextState:"2"},as:{action_:[{type_:"output",option:2},{type_:"bond",option:"-"}],nextState:"3"},b:{action_:"b="},o:{action_:{type_:"- after o/d",option:!1},nextState:"2"},q:{action_:{type_:"- after o/d",option:!1},nextState:"2"},"d|qd|dq":{action_:{type_:"- after o/d",option:!0},nextState:"2"},"D|qD|p":{action_:["output",{type_:"bond",option:"-"}],nextState:"3"}},amount2:{"1|3":{action_:"a=",nextState:"a"}},letters:{"0|1|2|3|a|as|b|p|bp|o":{action_:"o=",nextState:"o"},"q|dq":{action_:["output","o="],nextState:"o"},"d|D|qd|qD":{action_:"o after d",nextState:"o"}},digits:{o:{action_:"q=",nextState:"q"},"d|D":{action_:"q=",nextState:"dq"},q:{action_:["output","o="],nextState:"o"},a:{action_:"o=",nextState:"o"}},"space A":{"b|p|bp":{}},space:{a:{nextState:"as"},0:{action_:"sb=false"},"1|2":{action_:"sb=true"},"r|rt|rd|rdt|rdq":{action_:"output",nextState:"0"},"*":{action_:["output","sb=true"],nextState:"1"}},"1st-level escape":{"1|2":{action_:["output",{type_:"insert+p1",option:"1st-level escape"}]},"*":{action_:["output",{type_:"insert+p1",option:"1st-level escape"}],nextState:"0"}},"[(...)]":{"r|rt":{action_:"rd=",nextState:"rd"},"rd|rdt":{action_:"rq=",nextState:"rdq"}},"...":{"o|d|D|dq|qd|qD":{action_:["output",{type_:"bond",option:"..."}],nextState:"3"},"*":{action_:[{type_:"output",option:1},{type_:"insert",option:"ellipsis"}],nextState:"1"}},". |* ":{"*":{action_:["output",{type_:"insert",option:"addition compound"}],nextState:"1"}},"state of aggregation $":{"*":{action_:["output","state of aggregation"],nextState:"1"}},"{[(":{"a|as|o":{action_:["o=","output","parenthesisLevel++"],nextState:"2"},"0|1|2|3":{action_:["o=","output","parenthesisLevel++"],nextState:"2"},"*":{action_:["output","o=","output","parenthesisLevel++"],nextState:"2"}},")]}":{"0|1|2|3|b|p|bp|o":{action_:["o=","parenthesisLevel--"],nextState:"o"},"a|as|d|D|q|qd|qD|dq":{action_:["output","o=","parenthesisLevel--"],nextState:"o"}},", ":{"*":{action_:["output","comma"],nextState:"0"}},"^_":{"*":{}},"^{(...)}|^($...$)":{"0|1|2|as":{action_:"b=",nextState:"b"},p:{action_:"b=",nextState:"bp"},"3|o":{action_:"d= kv",nextState:"D"},q:{action_:"d=",nextState:"qD"},"d|D|qd|qD|dq":{action_:["output","d="],nextState:"D"}},"^a|^\\x{}{}|^\\x{}|^\\x|'":{"0|1|2|as":{action_:"b=",nextState:"b"},p:{action_:"b=",nextState:"bp"},"3|o":{action_:"d= kv",nextState:"d"},q:{action_:"d=",nextState:"qd"},"d|qd|D|qD":{action_:"d="},dq:{action_:["output","d="],nextState:"d"}},"_{(state of aggregation)}$":{"d|D|q|qd|qD|dq":{action_:["output","q="],nextState:"q"}},"_{(...)}|_($...$)|_9|_\\x{}{}|_\\x{}|_\\x":{"0|1|2|as":{action_:"p=",nextState:"p"},b:{action_:"p=",nextState:"bp"},"3|o":{action_:"q=",nextState:"q"},"d|D":{action_:"q=",nextState:"dq"},"q|qd|qD|dq":{action_:["output","q="],nextState:"q"}},"=<>":{"0|1|2|3|a|as|o|q|d|D|qd|qD|dq":{action_:[{type_:"output",option:2},"bond"],nextState:"3"}},"#":{"0|1|2|3|a|as|o":{action_:[{type_:"output",option:2},{type_:"bond",option:"#"}],nextState:"3"}},"{}":{"*":{action_:{type_:"output",option:1},nextState:"1"}},"{...}":{"0|1|2|3|a|as|b|p|bp":{action_:"o=",nextState:"o"},"o|d|D|q|qd|qD|dq":{action_:["output","o="],nextState:"o"}},"$...$":{a:{action_:"a="},"0|1|2|3|as|b|p|bp|o":{action_:"o=",nextState:"o"},"as|o":{action_:"o="},"q|d|D|qd|qD|dq":{action_:["output","o="],nextState:"o"}},"\\bond{(...)}":{"*":{action_:[{type_:"output",option:2},"bond"],nextState:"3"}},"\\frac{(...)}":{"*":{action_:[{type_:"output",option:1},"frac-output"],nextState:"3"}},"\\overset{(...)}":{"*":{action_:[{type_:"output",option:2},"overset-output"],nextState:"3"}},"\\underset{(...)}":{"*":{action_:[{type_:"output",option:2},"underset-output"],nextState:"3"}},"\\underbrace{(...)}":{"*":{action_:[{type_:"output",option:2},"underbrace-output"],nextState:"3"}},"\\color{(...)}{(...)}1|\\color(...){(...)}2":{"*":{action_:[{type_:"output",option:2},"color-output"],nextState:"3"}},"\\color{(...)}0":{"*":{action_:[{type_:"output",option:2},"color0-output"]}},"\\ce{(...)}":{"*":{action_:[{type_:"output",option:2},"ce"],nextState:"3"}},"\\,":{"*":{action_:[{type_:"output",option:1},"copy"],nextState:"1"}},"\\x{}{}|\\x{}|\\x":{"0|1|2|3|a|as|b|p|bp|o|c0":{action_:["o=","output"],nextState:"3"},"*":{action_:["output","o=","output"],nextState:"3"}},others:{"*":{action_:[{type_:"output",option:1},"copy"],nextState:"3"}},else2:{a:{action_:"a to o",nextState:"o",revisit:!0},as:{action_:["output","sb=true"],nextState:"1",revisit:!0},"r|rt|rd|rdt|rdq":{action_:["output"],nextState:"0",revisit:!0},"*":{action_:["output","copy"],nextState:"3"}}}),actions:{"o after d":function(t,e){var n;if((t.d||"").match(/^[0-9]+$/)){var o=t.d;t.d=void 0,n=this.output(t),t.b=o}else n=this.output(t);return a.actions["o="](t,e),n},"d= kv":function(t,e){t.d=e,t.dType="kv"},"charge or bond":function(t,e){if(t.beginsWithBond){var n=[];return a.concatArray(n,this.output(t)),a.concatArray(n,a.actions.bond(t,e,"-")),n}t.d=e},"- after o/d":function(t,e,n){var o=a.patterns.match_("orbital",t.o||""),r=a.patterns.match_("one lowercase greek letter $",t.o||""),i=a.patterns.match_("one lowercase latin letter $",t.o||""),c=a.patterns.match_("$one lowercase latin letter$ $",t.o||""),u="-"===e&&(o&&""===o.remainder||r||i||c);!u||t.a||t.b||t.p||t.d||t.q||o||!i||(t.o="$"+t.o+"$");var p=[];return u?(a.concatArray(p,this.output(t)),p.push({type_:"hyphen"})):(o=a.patterns.match_("digits",t.d||""),n&&o&&""===o.remainder?(a.concatArray(p,a.actions["d="](t,e)),a.concatArray(p,this.output(t))):(a.concatArray(p,this.output(t)),a.concatArray(p,a.actions.bond(t,e,"-")))),p},"a to o":function(t){t.o=t.a,t.a=void 0},"sb=true":function(t){t.sb=!0},"sb=false":function(t){t.sb=!1},"beginsWithBond=true":function(t){t.beginsWithBond=!0},"beginsWithBond=false":function(t){t.beginsWithBond=!1},"parenthesisLevel++":function(t){t.parenthesisLevel++},"parenthesisLevel--":function(t){t.parenthesisLevel--},"state of aggregation":function(t,e){return{type_:"state of aggregation",p1:a.go(e,"o")}},comma:function(t,e){var n=e.replace(/\s*$/,"");return n!==e&&0===t.parenthesisLevel?{type_:"comma enumeration L",p1:n}:{type_:"comma enumeration M",p1:n}},output:function(t,e,n){var o,r,i;t.r?(r="M"===t.rdt?a.go(t.rd,"tex-math"):"T"===t.rdt?[{type_:"text",p1:t.rd||""}]:a.go(t.rd),i="M"===t.rqt?a.go(t.rq,"tex-math"):"T"===t.rqt?[{type_:"text",p1:t.rq||""}]:a.go(t.rq),o={type_:"arrow",r:t.r,rd:r,rq:i}):(o=[],(t.a||t.b||t.p||t.o||t.q||t.d||n)&&(t.sb&&o.push({type_:"entitySkip"}),t.o||t.q||t.d||t.b||t.p||2===n?t.o||t.q||t.d||!t.b&&!t.p?t.o&&"kv"===t.dType&&a.patterns.match_("d-oxidation$",t.d||"")?t.dType="oxidation":t.o&&"kv"===t.dType&&!t.q&&(t.dType=void 0):(t.o=t.a,t.d=t.b,t.q=t.p,t.a=t.b=t.p=void 0):(t.o=t.a,t.a=void 0),o.push({type_:"chemfive",a:a.go(t.a,"a"),b:a.go(t.b,"bd"),p:a.go(t.p,"pq"),o:a.go(t.o,"o"),q:a.go(t.q,"pq"),d:a.go(t.d,"oxidation"===t.dType?"oxidation":"bd"),dType:t.dType})));for(var c in t)"parenthesisLevel"!==c&&"beginsWithBond"!==c&&delete t[c];return o},"oxidation-output":function(t,e){var n=["{"];return a.concatArray(n,a.go(e,"oxidation")),n.push("}"),n},"frac-output":function(t,e){return{type_:"frac-ce",p1:a.go(e[0]),p2:a.go(e[1])}},"overset-output":function(t,e){return{type_:"overset",p1:a.go(e[0]),p2:a.go(e[1])}},"underset-output":function(t,e){return{type_:"underset",p1:a.go(e[0]),p2:a.go(e[1])}},"underbrace-output":function(t,e){return{type_:"underbrace",p1:a.go(e[0]),p2:a.go(e[1])}},"color-output":function(t,e){return{type_:"color",color1:e[0],color2:a.go(e[1])}},"r=":function(t,e){t.r=e},"rdt=":function(t,e){t.rdt=e},"rd=":function(t,e){t.rd=e},"rqt=":function(t,e){t.rqt=e},"rq=":function(t,e){t.rq=e},operator:function(t,e,n){return{type_:"operator",kind_:n||e}}}},a:{transitions:a.createTransitions({empty:{"*":{}},"1/2$":{0:{action_:"1/2"}},else:{0:{nextState:"1",revisit:!0}},"$(...)$":{"*":{action_:"tex-math tight",nextState:"1"}},",":{"*":{action_:{type_:"insert",option:"commaDecimal"}}},else2:{"*":{action_:"copy"}}}),actions:{}},o:{transitions:a.createTransitions({empty:{"*":{}},"1/2$":{0:{action_:"1/2"}},else:{0:{nextState:"1",revisit:!0}},letters:{"*":{action_:"rm"}},"\\ca":{"*":{action_:{type_:"insert",option:"circa"}}},"\\x{}{}|\\x{}|\\x":{"*":{action_:"copy"}},"${(...)}$|$(...)$":{"*":{action_:"tex-math"}},"{(...)}":{"*":{action_:"{text}"}},else2:{"*":{action_:"copy"}}}),actions:{}},text:{transitions:a.createTransitions({empty:{"*":{action_:"output"}},"{...}":{"*":{action_:"text="}},"${(...)}$|$(...)$":{"*":{action_:"tex-math"}},"\\greek":{"*":{action_:["output","rm"]}},"\\,|\\x{}{}|\\x{}|\\x":{"*":{action_:["output","copy"]}},else:{"*":{action_:"text="}}}),actions:{output:function(t){if(t.text_){var e={type_:"text",p1:t.text_};for(var n in t)delete t[n];return e}}}},pq:{transitions:a.createTransitions({empty:{"*":{}},"state of aggregation $":{"*":{action_:"state of aggregation"}},i$:{0:{nextState:"!f",revisit:!0}},"(KV letters),":{0:{action_:"rm",nextState:"0"}},formula$:{0:{nextState:"f",revisit:!0}},"1/2$":{0:{action_:"1/2"}},else:{0:{nextState:"!f",revisit:!0}},"${(...)}$|$(...)$":{"*":{action_:"tex-math"}},"{(...)}":{"*":{action_:"text"}},"a-z":{f:{action_:"tex-math"}},letters:{"*":{action_:"rm"}},"-9.,9":{"*":{action_:"9,9"}},",":{"*":{action_:{type_:"insert+p1",option:"comma enumeration S"}}},"\\color{(...)}{(...)}1|\\color(...){(...)}2":{"*":{action_:"color-output"}},"\\color{(...)}0":{"*":{action_:"color0-output"}},"\\ce{(...)}":{"*":{action_:"ce"}},"\\,|\\x{}{}|\\x{}|\\x":{"*":{action_:"copy"}},else2:{"*":{action_:"copy"}}}),actions:{"state of aggregation":function(t,e){return{type_:"state of aggregation subscript",p1:a.go(e,"o")}},"color-output":function(t,e){return{type_:"color",color1:e[0],color2:a.go(e[1],"pq")}}}},bd:{transitions:a.createTransitions({empty:{"*":{}},x$:{0:{nextState:"!f",revisit:!0}},formula$:{0:{nextState:"f",revisit:!0}},else:{0:{nextState:"!f",revisit:!0}},"-9.,9 no missing 0":{"*":{action_:"9,9"}},".":{"*":{action_:{type_:"insert",option:"electron dot"}}},"a-z":{f:{action_:"tex-math"}},x:{"*":{action_:{type_:"insert",option:"KV x"}}},letters:{"*":{action_:"rm"}},"'":{"*":{action_:{type_:"insert",option:"prime"}}},"${(...)}$|$(...)$":{"*":{action_:"tex-math"}},"{(...)}":{"*":{action_:"text"}},"\\color{(...)}{(...)}1|\\color(...){(...)}2":{"*":{action_:"color-output"}},"\\color{(...)}0":{"*":{action_:"color0-output"}},"\\ce{(...)}":{"*":{action_:"ce"}},"\\,|\\x{}{}|\\x{}|\\x":{"*":{action_:"copy"}},else2:{"*":{action_:"copy"}}}),actions:{"color-output":function(t,e){return{type_:"color",color1:e[0],color2:a.go(e[1],"bd")}}}},oxidation:{transitions:a.createTransitions({empty:{"*":{}},"roman numeral":{"*":{action_:"roman-numeral"}},"${(...)}$|$(...)$":{"*":{action_:"tex-math"}},else:{"*":{action_:"copy"}}}),actions:{"roman-numeral":function(t,e){return{type_:"roman numeral",p1:e||""}}}},"tex-math":{transitions:a.createTransitions({empty:{"*":{action_:"output"}},"\\ce{(...)}":{"*":{action_:["output","ce"]}},"{...}|\\,|\\x{}{}|\\x{}|\\x":{"*":{action_:"o="}},else:{"*":{action_:"o="}}}),actions:{output:function(t){if(t.o){var e={type_:"tex-math",p1:t.o};for(var n in t)delete t[n];return e}}}},"tex-math tight":{transitions:a.createTransitions({empty:{"*":{action_:"output"}},"\\ce{(...)}":{"*":{action_:["output","ce"]}},"{...}|\\,|\\x{}{}|\\x{}|\\x":{"*":{action_:"o="}},"-|+":{"*":{action_:"tight operator"}},else:{"*":{action_:"o="}}}),actions:{"tight operator":function(t,e){t.o=(t.o||"")+"{"+e+"}"},output:function(t){if(t.o){var e={type_:"tex-math",p1:t.o};for(var n in t)delete t[n];return e}}}},"9,9":{transitions:a.createTransitions({empty:{"*":{}},",":{"*":{action_:"comma"}},else:{"*":{action_:"copy"}}}),actions:{comma:function(){return{type_:"commaDecimal"}}}},pu:{transitions:a.createTransitions({empty:{"*":{action_:"output"}},space$:{"*":{action_:["output","space"]}},"{[(|)]}":{"0|a":{action_:"copy"}},"(-)(9)^(-9)":{0:{action_:"number^",nextState:"a"}},"(-)(9.,9)(e)(99)":{0:{action_:"enumber",nextState:"a"}},space:{"0|a":{}},"pm-operator":{"0|a":{action_:{type_:"operator",option:"\\pm"},nextState:"0"}},operator:{"0|a":{action_:"copy",nextState:"0"}},"//":{d:{action_:"o=",nextState:"/"}},"/":{d:{action_:"o=",nextState:"/"}},"{...}|else":{"0|d":{action_:"d=",nextState:"d"},a:{action_:["space","d="],nextState:"d"},"/|q":{action_:"q=",nextState:"q"}}}),actions:{enumber:function(t,e){var n=[];return"+-"===e[0]||"+/-"===e[0]?n.push("\\pm "):e[0]&&n.push(e[0]),e[1]&&(a.concatArray(n,a.go(e[1],"pu-9,9")),e[2]&&(e[2].match(/[,.]/)?a.concatArray(n,a.go(e[2],"pu-9,9")):n.push(e[2])),e[3]=e[4]||e[3],e[3]&&(e[3]=e[3].trim(),"e"===e[3]||"*"===e[3].substr(0,1)?n.push({type_:"cdot"}):n.push({type_:"times"}))),e[3]&&n.push("10^{"+e[5]+"}"),n},"number^":function(t,e){var n=[];return"+-"===e[0]||"+/-"===e[0]?n.push("\\pm "):e[0]&&n.push(e[0]),a.concatArray(n,a.go(e[1],"pu-9,9")),n.push("^{"+e[2]+"}"),n},operator:function(t,e,n){return{type_:"operator",kind_:n||e}},space:function(){return{type_:"pu-space-1"}},output:function(t){var e,n=a.patterns.match_("{(...)}",t.d||"");n&&""===n.remainder&&(t.d=n.match_);var o=a.patterns.match_("{(...)}",t.q||"");if(o&&""===o.remainder&&(t.q=o.match_),t.d&&(t.d=t.d.replace(/\u00B0C|\^oC|\^{o}C/g,"{}^{\\circ}C"),t.d=t.d.replace(/\u00B0F|\^oF|\^{o}F/g,"{}^{\\circ}F")),t.q){t.q=t.q.replace(/\u00B0C|\^oC|\^{o}C/g,"{}^{\\circ}C"),t.q=t.q.replace(/\u00B0F|\^oF|\^{o}F/g,"{}^{\\circ}F");var r={d:a.go(t.d,"pu"),q:a.go(t.q,"pu")};"//"===t.o?e={type_:"pu-frac",p1:r.d,p2:r.q}:(e=r.d,r.d.length>1||r.q.length>1?e.push({type_:" / "}):e.push({type_:"/"}),a.concatArray(e,r.q))}else e=a.go(t.d,"pu-2");for(var i in t)delete t[i];return e}}},"pu-2":{transitions:a.createTransitions({empty:{"*":{action_:"output"}},"*":{"*":{action_:["output","cdot"],nextState:"0"}},"\\x":{"*":{action_:"rm="}},space:{"*":{action_:["output","space"],nextState:"0"}},"^{(...)}|^(-1)":{1:{action_:"^(-1)"}},"-9.,9":{0:{action_:"rm=",nextState:"0"},1:{action_:"^(-1)",nextState:"0"}},"{...}|else":{"*":{action_:"rm=",nextState:"1"}}}),actions:{cdot:function(){return{type_:"tight cdot"}},"^(-1)":function(t,e){t.rm+="^{"+e+"}"},space:function(){return{type_:"pu-space-2"}},output:function(t){var e=[];if(t.rm){var n=a.patterns.match_("{(...)}",t.rm||"");e=n&&""===n.remainder?a.go(n.match_,"pu"):{type_:"rm",p1:t.rm}}for(var o in t)delete t[o];return e}}},"pu-9,9":{transitions:a.createTransitions({empty:{0:{action_:"output-0"},o:{action_:"output-o"}},",":{0:{action_:["output-0","comma"],nextState:"o"}},".":{0:{action_:["output-0","copy"],nextState:"o"}},else:{"*":{action_:"text="}}}),actions:{comma:function(){return{type_:"commaDecimal"}},"output-0":function(t){var e=[];if(t.text_=t.text_||"",t.text_.length>4){var n=t.text_.length%3;0===n&&(n=3);for(var o=t.text_.length-3;o>0;o-=3)e.push(t.text_.substr(o,3)),e.push({type_:"1000 separator"});e.push(t.text_.substr(0,n)),e.reverse()}else e.push(t.text_);for(var a in t)delete t[a];return e},"output-o":function(t){var e=[];if(t.text_=t.text_||"",t.text_.length>4){for(var n=t.text_.length-3,o=0;o<n;o+=3)e.push(t.text_.substr(o,3)),e.push({type_:"1000 separator"});e.push(t.text_.substr(o))}else e.push(t.text_);for(var a in t)delete t[a];return e}}}};var r={go:function(t,e){if(!t)return"";for(var n="",o=!1,a=0;a<t.length;a++){var i=t[a];"string"==typeof i?n+=i:(n+=r._go2(i),"1st-level escape"===i.type_&&(o=!0))}return e||o||!n||(n="{"+n+"}"),n},_goInner:function(t){return t?r.go(t,!0):t},_go2:function(t){var e;switch(t.type_){case"chemfive":e="";var n={a:r._goInner(t.a),b:r._goInner(t.b),p:r._goInner(t.p),o:r._goInner(t.o),q:r._goInner(t.q),d:r._goInner(t.d)};n.a&&(n.a.match(/^[+\-]/)&&(n.a="{"+n.a+"}"),e+=n.a+"\\,"),(n.b||n.p)&&(e+="{\\vphantom{X}}",e+="^{\\hphantom{"+(n.b||"")+"}}_{\\hphantom{"+(n.p||"")+"}}",e+="{\\vphantom{X}}",e+="^{\\smash[t]{\\vphantom{2}}\\mathllap{"+(n.b||"")+"}}",e+="_{\\vphantom{2}\\mathllap{\\smash[t]{"+(n.p||"")+"}}}"),n.o&&(n.o.match(/^[+\-]/)&&(n.o="{"+n.o+"}"),e+=n.o),"kv"===t.dType?((n.d||n.q)&&(e+="{\\vphantom{X}}"),n.d&&(e+="^{"+n.d+"}"),n.q&&(e+="_{\\smash[t]{"+n.q+"}}")):"oxidation"===t.dType?(n.d&&(e+="{\\vphantom{X}}",e+="^{"+n.d+"}"),n.q&&(e+="{\\vphantom{X}}",e+="_{\\smash[t]{"+n.q+"}}")):(n.q&&(e+="{\\vphantom{X}}",e+="_{\\smash[t]{"+n.q+"}}"),n.d&&(e+="{\\vphantom{X}}",e+="^{"+n.d+"}"));break;case"rm":e="\\mathrm{"+t.p1+"}";break;case"text":t.p1.match(/[\^_]/)?(t.p1=t.p1.replace(" ","~").replace("-","\\text{-}"),e="\\mathrm{"+t.p1+"}"):e="\\text{"+t.p1+"}";break;case"roman numeral":e="\\mathrm{"+t.p1+"}";break;case"state of aggregation":e="\\mskip2mu "+r._goInner(t.p1);break;case"state of aggregation subscript":e="\\mskip1mu "+r._goInner(t.p1);break;case"bond":if(!(e=r._getBond(t.kind_)))throw["MhchemErrorBond","mhchem Error. Unknown bond type ("+t.kind_+")"];break;case"frac":var o="\\frac{"+t.p1+"}{"+t.p2+"}";e="\\mathchoice{\\textstyle"+o+"}{"+o+"}{"+o+"}{"+o+"}";break;case"pu-frac":var a="\\frac{"+r._goInner(t.p1)+"}{"+r._goInner(t.p2)+"}";e="\\mathchoice{\\textstyle"+a+"}{"+a+"}{"+a+"}{"+a+"}";break;case"tex-math":e=t.p1+" ";break;case"frac-ce":e="\\frac{"+r._goInner(t.p1)+"}{"+r._goInner(t.p2)+"}";break;case"overset":e="\\overset{"+r._goInner(t.p1)+"}{"+r._goInner(t.p2)+"}";break;case"underset":e="\\underset{"+r._goInner(t.p1)+"}{"+r._goInner(t.p2)+"}";break;case"underbrace":e="\\underbrace{"+r._goInner(t.p1)+"}_{"+r._goInner(t.p2)+"}";break;case"color":e="{\\color{"+t.color1+"}{"+r._goInner(t.color2)+"}}";break;case"color0":e="\\color{"+t.color+"}";break;case"arrow":var i={rd:r._goInner(t.rd),rq:r._goInner(t.rq)},c="\\x"+r._getArrow(t.r);i.rq&&(c+="[{"+i.rq+"}]"),e=c+=i.rd?"{"+i.rd+"}":"{}";break;case"operator":e=r._getOperator(t.kind_);break;case"1st-level escape":e=t.p1+" ";break;case"space":e=" ";break;case"entitySkip":case"pu-space-1":e="~";break;case"pu-space-2":e="\\mkern3mu ";break;case"1000 separator":e="\\mkern2mu ";break;case"commaDecimal":e="{,}";break;case"comma enumeration L":e="{"+t.p1+"}\\mkern6mu ";break;case"comma enumeration M":e="{"+t.p1+"}\\mkern3mu ";break;case"comma enumeration S":e="{"+t.p1+"}\\mkern1mu ";break;case"hyphen":e="\\text{-}";break;case"addition compound":e="\\,{\\cdot}\\,";break;case"electron dot":e="\\mkern1mu \\bullet\\mkern1mu ";break;case"KV x":e="{\\times}";break;case"prime":e="\\prime ";break;case"cdot":e="\\cdot ";break;case"tight cdot":e="\\mkern1mu{\\cdot}\\mkern1mu ";break;case"times":e="\\times ";break;case"circa":e="{\\sim}";break;case"^":e="uparrow";break;case"v":e="downarrow";break;case"ellipsis":e="\\ldots ";break;case"/":e="/";break;case" / ":e="\\,/\\,";break;default:throw["MhchemBugT","mhchem bug T. Please report."]}return e},_getArrow:function(t){switch(t){case"->":case"\u2192":case"\u27f6":return"rightarrow";case"<-":return"leftarrow";case"<->":return"leftrightarrow";case"<--\x3e":return"rightleftarrows";case"<=>":case"\u21cc":return"rightleftharpoons";case"<=>>":return"rightequilibrium";case"<<=>":return"leftequilibrium";default:throw["MhchemBugT","mhchem bug T. Please report."]}},_getBond:function(t){switch(t){case"-":case"1":return"{-}";case"=":case"2":return"{=}";case"#":case"3":return"{\\equiv}";case"~":return"{\\tripledash}";case"~-":return"{\\mathrlap{\\raisebox{-.1em}{$-$}}\\raisebox{.1em}{$\\tripledash$}}";case"~=":case"~--":return"{\\mathrlap{\\raisebox{-.2em}{$-$}}\\mathrlap{\\raisebox{.2em}{$\\tripledash$}}-}";case"-~-":return"{\\mathrlap{\\raisebox{-.2em}{$-$}}\\mathrlap{\\raisebox{.2em}{$-$}}\\tripledash}";case"...":return"{{\\cdot}{\\cdot}{\\cdot}}";case"....":return"{{\\cdot}{\\cdot}{\\cdot}{\\cdot}}";case"->":return"{\\rightarrow}";case"<-":return"{\\leftarrow}";case"<":return"{<}";case">":return"{>}";default:throw["MhchemBugT","mhchem bug T. Please report."]}},_getOperator:function(t){switch(t){case"+":return" {}+{} ";case"-":return" {}-{} ";case"=":return" {}={} ";case"<":return" {}<{} ";case">":return" {}>{} ";case"<<":return" {}\\ll{} ";case">>":return" {}\\gg{} ";case"\\pm":return" {}\\pm{} ";case"\\approx":case"$\\approx$":return" {}\\approx{} ";case"v":case"(v)":return" \\downarrow{} ";case"^":case"(^)":return" \\uparrow{} ";default:throw["MhchemBugT","mhchem bug T. Please report."]}}}}(),a=a.default}()}));