Astroport.ONE/templates/qoopwiki.html

3377 lines
4.3 MiB
HTML
Raw Normal View History

<!doctype html>
<!-- The following comment is called a MOTW comment and is necessary for the TiddlyIE Internet Explorer extension -->
<!-- saved from url=(0021)https://tiddlywiki.com -->
<html lang="fr-FR">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<!--~~ Raw markup for the top of the head section ~~-->
<meta http-equiv="X-UA-Compatible" content="IE=Edge"/>
<meta name="application-name" content="TiddlyWiki" />
<meta name="generator" content="TiddlyWiki" />
<meta name="tiddlywiki-version" content="5.2.3-prerelease" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<meta name="mobile-web-app-capable" content="yes"/>
<meta name="format-detection" content="telephone=no" />
<meta name="copyright" content="TiddlyWiki created by Jeremy Ruston, (jeremy [at] jermolene [dot] com)
Copyright (c) 2004-2007, Jeremy Ruston
Copyright (c) 2007-2022, UnaMesa Association
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." />
<link id="faviconLink" rel="shortcut icon" href="favicon.ico">
<title>qo-op _PSEUDO_ — Espace Public</title>
<!--~~ This is a Tiddlywiki file. The points of interest in the file are marked with this pattern ~~-->
<!--~~ Raw markup ~~-->
</head>
<body class="tc-body">
<!--~~ Raw markup for the top of the body section ~~-->
<!--~~ Static styles ~~-->
<div id="styleArea">
<style data-tiddler-bag="default" data-tiddler-revision="0" data-tiddler-title="$:/boot/boot.css" data-tiddler-type="text/css" type="text/css">/*
Basic styles used before we boot up the parsing engine
*/
/*
Error message and password prompt
*/
.tc-error-form {
font-family: sans-serif;
color: #fff;
z-index: 20000;
position: fixed;
background-color: rgb(255, 75, 75);
border: 8px solid rgb(255, 0, 0);
border-radius: 8px;
width: 50%;
margin-left: 25%;
margin-top: 4em;
padding: 0 2em 1em 2em;
}
.tc-error-form h1 {
text-align: center;
}
.tc-error-prompt {
text-align: center;
color: #000;
}
.tc-error-message {
overflow: auto;
max-height: 40em;
padding-right: 1em;
margin: 1em 0;
white-space: pre-line;
}
.tc-password-wrapper {
font-family: sans-serif;
z-index: 20000;
position: fixed;
text-align: center;
width: 200px;
top: 4em;
left: 50%;
margin-left: -144px; /* - width/2 - paddingHorz/2 - border */
padding: 16px 16px 16px 16px;
border-radius: 8px;
}
.tc-password-wrapper {
color: #000;
text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
background-color: rgb(197, 235, 183);
border: 8px solid rgb(164, 197, 152);
}
.tc-password-wrapper form {
text-align: left;
}
.tc-password-wrapper h1 {
font-size: 16px;
line-height: 20px;
padding-bottom: 16px;
}
.tc-password-wrapper input {
width: 100%;
}
</style>
</div>
<!--~~ Static content for Google and browsers without JavaScript ~~-->
<noscript>
<div id="splashArea">
<p>This <a class="tc-tiddlylink-external" href="https://tiddlywiki.com" rel="noopener noreferrer" target="_blank">TiddlyWiki</a> contains the following tiddlers:</p><p><ul>
<li>$:/_demostyles</li>
<li>$:/_streams-sidebar-demo</li>
<li>$:/ColumnHistoryList</li>
<li>$:/columns</li>
<li>$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/encryption</li>
<li>$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/home</li>
<li>$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/import</li>
<li>$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/ipfs/console/mobile</li>
<li>$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/ipns/publish</li>
<li>$:/config/PageControlButtons/Visibility/$:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/panorama-page-controls</li>
<li>$:/config/PageControlButtons/Visibility/$:/themes/nico/notebook/ui/Buttons/SwitchPalette</li>
<li>$:/config/panel/disable</li>
<li>$:/config/panel/position</li>
<li>$:/config/panel/river-obscured</li>
<li>$:/config/panel/show-numbers</li>
<li>$:/config/Plugins/Disabled/$:/plugins/sq/streams</li>
<li>$:/config/PreferredSaver</li>
<li>$:/config/RelinkOnRename</li>
<li>$:/config/scroll-snap-type</li>
<li>$:/config/scroll-snap-x</li>
<li>$:/config/scroll-x-duration</li>
<li>$:/config/story-river/bottom-right-panel</li>
<li>$:/config/story-river/dragging-enable</li>
<li>$:/config/story-river/dragging-enabled</li>
<li>$:/config/story-river/follow-active-column</li>
<li>$:/config/story-river/hide-scrollbars</li>
<li>$:/config/story-river/hide-scrollbars-y</li>
<li>$:/config/story-river/horizontal/columns</li>
<li>$:/config/story-river/padding</li>
<li>$:/config/story-river/scroll-snap-type</li>
<li>$:/config/story-river/scroll-snap-x</li>
<li>$:/config/story-river/search-panel</li>
<li>$:/config/story-river/style-focused-tiddlers</li>
<li>$:/config/story-river/tiddler-border</li>
<li>$:/config/story-river/tiddler-margin</li>
<li>$:/config/story-view/search-panel</li>
<li>$:/config/ViewToolbarButtons/Visibility/$:/core/ui/Buttons/delete</li>
<li>$:/config/ViewToolbarButtons/Visibility/$:/core/ui/Buttons/open-window</li>
<li>$:/core</li>
<li>$:/DefaultTiddlers</li>
<li>$:/Import</li>
<li>$:/Import-1</li>
<li>$:/Import-2</li>
<li>$:/ipfs/saver/api</li>
<li>$:/ipfs/saver/gateway</li>
<li>$:/ipfs/saver/ipns/key</li>
<li>$:/ipfs/saver/ipns/name</li>
<li>$:/ipfs/saver/unpin</li>
<li>$:/ipfs/saver/verbose</li>
<li>$:/isEncrypted</li>
<li>$:/language</li>
<li>$:/language/DefaultNewTiddlerTitle</li>
<li>$:/languages/fr-FR</li>
<li>$:/layout</li>
<li>$:/palette</li>
<li>$:/plugins/bimlas/locator</li>
<li>$:/plugins/BTC/tiddlywiki-multi-columns</li>
<li>$:/plugins/danielo515/encryptTiddler</li>
<li>$:/plugins/ipfs</li>
<li>$:/plugins/sq/streams</li>
<li>$:/plugins/sq/streams/breadcrumbs-view-template</li>
<li>$:/plugins/sq/streams/stream-view-template</li>
<li>$:/plugins/sycom/leaflet</li>
<li>$:/plugins/tiddlywiki/highlight</li>
<li>$:/plugins/tiddlywiki/markdown</li>
<li>$:/plugins/tiddlywiki/qrcode</li>
<li>$:/SidebarStreams/RootTiddler</li>
<li>$:/SiteSubtitle</li>
<li>$:/SiteTitle</li>
<li>$:/state/notebook-sidebar</li>
<li>$:/state/notebook-sidebar-section</li>
<li>$:/state/panel/visibility</li>
<li>$:/state/tab--1963855381</li>
<li>$:/state/tab-1749438307</li>
<li>$:/state/tab-2065006209</li>
<li>$:/state/tab/moresidebar-1850697562</li>
<li>$:/state/tab/sidebar--595412856</li>
<li>$:/state/user-panel/visibility</li>
<li>$:/status/RequireReloadDueToPluginChange</li>
<li>$:/Story/Default</li>
<li>$:/StoryList</li>
<li>$:/StoryList-2</li>
<li>$:/StoryList-24</li>
<li>$:/StoryList-3</li>
<li>$:/StoryList-4</li>
<li>$:/StoryList-5</li>
<li>$:/StoryList-6</li>
<li>$:/StoryList-7</li>
<li>$:/StoryList-8</li>
<li>$:/StoryList-9</li>
<li>$:/StoryList3</li>
<li>$:/tags/PageControls</li>
<li>$:/theme</li>
<li>$:/themes/nico/notebook</li>
<li>$:/themes/tiddlywiki/snowwhite</li>
<li>$:/themes/tiddlywiki/vanilla</li>
<li>$:/themes/tiddlywiki/vanilla/options/stickytitles</li>
<li>$:/themes/tiddlywiki/vanilla/settings/editorfontfamily</li>
<li>$:/UserPanelSubtitle</li>
<li>$:/UserPanelTitle</li>
<li>$:/view</li>
<li>Astroport</li>
<li>Astroport 20:12</li>
<li>Astroport_Final.mp4</li>
<li>Astroport.ONE</li>
<li>Carte</li>
<li>Ceci nest pas une pipe.</li>
<li>Configuration Options</li>
<li>Dessin de Moa</li>
<li>Film</li>
<li>Horse Galloping (Loop)</li>
<li>Info</li>
<li>Keyboard Shortcuts</li>
<li>NoGafamNetwork.png</li>
<li>qo-op</li>
</ul>
</p>
<style>
.tc-remove-when-wiki-loaded {display: none;}
</style>
</div>
</noscript>
<!--~~ Ordinary tiddlers ~~-->
<script class="tiddlywiki-tiddler-store" type="application/json">[
{"title":"$:/_demostyles","created":"20220403181300247","modified":"20220426042440947","tags":"$:/tags/Stylesheet","type":"text/vnd.tiddlywiki","text":".youtube-outer , .tc-tiddler-frame.flex .tc-tiddler-body .tc-tiddler-body-flex {\n\tz-index: 0;\n\twidth: 100%;\n height: 100%;\n position: relative;\n}\n\n.youtube-inner , .tc-tiddler-body-before-flex {\n height: 0px;\n padding-bottom: 56.25%;\n}\n\n.youtube-inner iframe , .youtube-inner img , .tc-tiddler-body-after-flex {\n width: 100%;\n height: 100%;\n position: absolute;\n}\n\n.youtube-text {\n\toverflow-y: -webkit-paged-x;\n}\n\n.tc-red-icon svg {\nfill: red;\n}\n\n.big-icon, .big-icon svg {\n\tfont-size:10rem !important;\n}\n\n.green-icon {\n\tcolor: \u003C\u003Ccolour download-background>>;\n}\n\n.green-icon svg {\n\tfill: \u003C\u003Ccolour download-background>>;\n}\n\n.small-svg svg {\nwidth: 30px;\nheight: 30px;\n}\n\n.tc-user-panel-container .stream-node-block input.tc-edit-texteditor,\n.tc-user-panel-container .stream-node-block textarea.tc-edit-texteditor,\n.tc-user-panel-container .stream-node-block iframe.tc-edit-texteditor {\n\tbackground: \u003C\u003Ccolor page-background>> !important;\n\tmargin-top:0;\n\tmargin-bottom: -2em;\n}","revision":"0","bag":"default"},
{"title":"$:/_streams-sidebar-demo","created":"20220424075455451","modified":"20220426061602260","tags":"$:/tags/SideBarSegment/User","type":"text/vnd.tiddlywiki","text":"\\define transclude-root-tiddler()\n{{$(rootTiddler)$||$:/plugins/sq/streams/stream-view-template}}\n{{$(rootTiddler)$||$:/plugins/sq/streams/breadcrumbs-view-template}}\n\\end\n\nStreams Root Tiddler: \u003C$edit-text tiddler=\"$:/SidebarStreams/RootTiddler\" tag=\"input\" default=\"\" placeholder=\"title of root tiddler\"/>\n\n\u003C$set name=\"rootTiddler\" value={{{ [[$:/SidebarStreams/RootTiddler]get[text]] }}}>\n\u003C\u003Ctransclude-root-tiddler>>\n\u003C/$set>","revision":"0","bag":"default"},
{"text":"[\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Ceci nest pas une pipe.\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n },\n {\n \"title\": \"Keyboard Shortcuts\"\n },\n {\n \"title\": \"The Great Wave off the Coast of Kanagawa\"\n }\n]","type":"application/json","created":"20220403170334039","current-tiddler":"The Great Wave off the Coast of Kanagawa","modified":"20220403170653421","title":"$:/ColumnHistoryList","revision":"0","bag":"default"},
{"created":"20220420032054311","title":"$:/columns","active-column":"1","list":"1","modified":"20220504183330746","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220504003553035","text":"hide","title":"$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/encryption","modified":"20220504003553035","tags":"$:/ipfs/core"},
{"title":"$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/home","created":"20220425152240985","modified":"20220425152243125","type":"text/vnd.tiddlywiki","text":"hide","revision":"0","bag":"default"},
{"created":"20220504003535076","text":"show","title":"$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/import","modified":"20220504003535076"},
{"created":"20220504003758495","text":"hide","title":"$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/ipfs/console/mobile","modified":"20220504003758495","tags":"$:/ipfs/core"},
{"created":"20220504003608927","text":"show","title":"$:/config/PageControlButtons/Visibility/$:/core/ui/Buttons/ipns/publish","modified":"20220504003608927","tags":"$:/ipfs/core"},
{"created":"20220504003806341","text":"hide","title":"$:/config/PageControlButtons/Visibility/$:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/panorama-page-controls","modified":"20220504003806341"},
{"created":"20220504003747436","text":"hide","title":"$:/config/PageControlButtons/Visibility/$:/themes/nico/notebook/ui/Buttons/SwitchPalette","modified":"20220504003747436"},
{"title":"$:/config/panel/disable","created":"20220425095059594","modified":"20220425095359708","type":"text/vnd.tiddlywiki","text":"no","revision":"0","bag":"default"},
{"created":"20220416062059264","title":"$:/config/panel/position","modified":"20220504185705295","type":"text/vnd.tiddlywiki","text":"right","revision":"0","bag":"default"},
{"created":"20220417070206148","title":"$:/config/panel/river-obscured","modified":"20220504185533892","type":"text/vnd.tiddlywiki","text":"yes","revision":"0","bag":"default"},
{"created":"20220418155057871","title":"$:/config/panel/show-numbers","modified":"20220504185519298","type":"text/vnd.tiddlywiki","text":"yes","revision":"0","bag":"default"},
{"created":"20220504184444060","title":"$:/config/Plugins/Disabled/$:/plugins/sq/streams","text":"no","modified":"20220504184515979"},
{"created":"20220504003913970","title":"$:/config/PreferredSaver","modified":"20220504004036189","tags":"$:/ipfs/core","text":"$:/plugins/ipfs/ipfs-saver.js"},
{"created":"20220504005435123","text":"yes","title":"$:/config/RelinkOnRename","modified":"20220504005435123"},
{"title":"$:/config/scroll-snap-type","created":"20220403192959868","modified":"20220403193117561","type":"text/vnd.tiddlywiki","text":"none","revision":"0","bag":"default"},
{"title":"$:/config/scroll-snap-x","created":"20220416071536196","modified":"20220425093747763","type":"text/vnd.tiddlywiki","text":"yes","revision":"0","bag":"default"},
{"title":"$:/config/scroll-x-duration","created":"20220403193008167","modified":"20220411211937170","type":"text/vnd.tiddlywiki","text":"800","revision":"0","bag":"default"},
{"created":"20220421184632774","text":"yes","title":"$:/config/story-river/bottom-right-panel","modified":"20220504185548393","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220504184021050","title":"$:/config/story-river/dragging-enable","text":"no","modified":"20220505172703232"},
{"title":"$:/config/story-river/dragging-enabled","created":"20220416140144769","modified":"20220416140144769","type":"text/vnd.tiddlywiki","text":"no","revision":"0","bag":"default"},
{"created":"20220504185647722","title":"$:/config/story-river/follow-active-column","text":"no","modified":"20220504185650273"},
{"title":"$:/config/story-river/hide-scrollbars","created":"20220423053107345","modified":"20220423072822748","type":"text/vnd.tiddlywiki","text":"no","revision":"0","bag":"default"},
{"title":"$:/config/story-river/hide-scrollbars-y","created":"20220423071837031","modified":"20220423071933043","type":"text/vnd.tiddlywiki","text":"no","revision":"0","bag":"default"},
{"title":"$:/config/story-river/horizontal/columns","created":"20220419040543409","modified":"20220426104204494","type":"text/vnd.tiddlywiki","text":"2","revision":"0","bag":"default"},
{"title":"$:/config/story-river/padding","created":"20220417062419838","modified":"20220421184722472","type":"text/vnd.tiddlywiki","text":"15","revision":"0","bag":"default"},
{"title":"$:/config/story-river/scroll-snap-type","created":"20220426135200474","modified":"20220426135238047","type":"text/vnd.tiddlywiki","text":"none","revision":"0","bag":"default"},
{"created":"20220425093916283","title":"$:/config/story-river/scroll-snap-x","modified":"20220504011124508","type":"text/vnd.tiddlywiki","text":"no","revision":"0","bag":"default"},
{"created":"20220414162310338","title":"$:/config/story-river/search-panel","modified":"20220504003109364","type":"text/vnd.tiddlywiki","text":"bottom","revision":"0","bag":"default"},
{"title":"$:/config/story-river/style-focused-tiddlers","created":"20220423082137271","modified":"20220423082140709","type":"text/vnd.tiddlywiki","text":"yes","revision":"0","bag":"default"},
{"title":"$:/config/story-river/tiddler-border","created":"20220410114120018","modified":"20220417060724352","type":"text/vnd.tiddlywiki","text":"1","revision":"0","bag":"default"},
{"title":"$:/config/story-river/tiddler-margin","created":"20220410112929474","modified":"20220417051438672","type":"text/vnd.tiddlywiki","text":"10","revision":"0","bag":"default"},
{"title":"$:/config/story-view/search-panel","created":"20220414162232251","modified":"20220414162232251","type":"text/vnd.tiddlywiki","text":"top","revision":"0","bag":"default"},
{"title":"$:/config/ViewToolbarButtons/Visibility/$:/core/ui/Buttons/delete","created":"20220403101708741","modified":"20220403101708741","type":"text/vnd.tiddlywiki","text":"show","revision":"0","bag":"default"},
{"title":"$:/config/ViewToolbarButtons/Visibility/$:/core/ui/Buttons/open-window","created":"20220424152049507","modified":"20220425155629379","type":"text/vnd.tiddlywiki","text":"hide","revision":"0","bag":"default"},
{"title":"$:/core","name":"Core","description":"TiddlyWiki5 core","author":"JeremyRuston","core-version":">=5.0.0","plugin-priority":"0","list":"readme","version":"5.2.3-prerelease","plugin-type":"plugin","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/Acknowledgements\":{\"title\":\"$:/Acknowledgements\",\"text\":\"TiddlyWiki incorporates code from these fine OpenSource projects:\\n\\n* [[The Stanford Javascript Crypto Library|http://bitwiseshiftleft.github.io/sjcl/]]\\n* [[The Jasmine JavaScript Test Framework|http://pivotal.github.io/jasmine/]]\\n* [[Normalize.css by Nicolas Gallagher|http://necolas.github.io/normalize.css/]]\\n\\nAnd media from these projects:\\n\\n* World flag icons from [[Wikipedia|http://commons.wikimedia.org/wiki/Category:SVG_flags_by_country]]\\n\"},\"$:/core/copyright.txt\":{\"title\":\"$:/core/copyright.txt\",\"type\":\"text/plain\",\"text\":\"TiddlyWiki created by Jeremy Ruston, (jeremy [at] jermolene [dot] com)\\n\\nCopyright (c) 2004-2007, Jeremy Ruston\\nCopyright (c) 2007-2022, UnaMesa Association\\nAll rights reserved.\\n\\nRedistribution and use in source and binary forms, with or without\\nmodification, are permitted provided that the following conditions are met:\\n\\n* Redistributions of source code must retain the above copyright notice, this\\n list of conditions and the following disclaimer.\\n\\n* Redistributions in binary form must reproduce the above copyright notice,\\n this list of conditions and the following disclaimer in the documentation\\n and/or other materials provided with the distribution.\\n\\n* Neither the name of the copyright holder nor the names of its\\n contributors may be used to endorse or promote products derived from\\n this software without specific prior written permission.\\n\\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'\\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\"},\"$:/core/icon\":{\"title\":\"$:/core/icon\",\"tags\":\"$:/tags/Image\",\"text\":\"\u003Csvg width=\\\"22pt\\\" height=\\\"22pt\\\" viewBox=\\\"0 0 128 128\\\">\u003Cpath d=\\\"M64 0l54.56 32v64L64 128 9.44 96V32L64 0zm21.127 95.408c-3.578-.103-5.15-.094-6.974-3.152l-1.42.042c-1.653-.075-.964-.04-2.067-.097-1.844-.07-1.548-1.86-1.873-2.8-.52-3.202.687-6.43.65-9.632-.014-1.14-1.593-5.17-2.157-6.61-1.768.34-3.546.406-5.34.497-4.134-.01-8.24-.527-12.317-1.183-.8 3.35-3.16 8.036-1.21 11.44 2.37 3.52 4.03 4.495 6.61 4.707 2.572.212 3.16 3.18 2.53 4.242-.55.73-1.52.864-2.346 1.04l-1.65.08c-1.296-.046-2.455-.404-3.61-.955-1.93-1.097-3.925-3.383-5.406-5.024.345.658.55 1.938.24 2.53-.878 1.27-4.665 1.26-6.4.47-1.97-.89-6.73-7.162-7.468-11.86 1.96-3.78 4.812-7.07 6.255-11.186-3.146-2.05-4.83-5.384-4.61-9.16l.08-.44c-3.097.59-1.49.37-4.82.628-10.608-.032-19.935-7.37-14.68-18.774.34-.673.664-1.287 1.243-.994.466.237.4 1.18.166 2.227-3.005 13.627 11.67 13.732 20.69 11.21.89-.25 2.67-1.936 3.905-2.495 2.016-.91 4.205-1.282 6.376-1.55 5.4-.63 11.893 2.276 15.19 2.37 3.3.096 7.99-.805 10.87-.615 2.09.098 4.143.483 6.16 1.03 1.306-6.49 1.4-11.27 4.492-12.38 1.814.293 3.213 2.818 4.25 4.167 2.112-.086 4.12.46 6.115 1.066 3.61-.522 6.642-2.593 9.833-4.203-3.234 2.69-3.673 7.075-3.303 11.127.138 2.103-.444 4.386-1.164 6.54-1.348 3.507-3.95 7.204-6.97 7.014-1.14-.036-1.805-.695-2.653-1.4-.164 1.427-.81 2.7-1.434 3.96-1.44 2.797-5.203 4.03-8.687 7.016-3.484 2.985 1.114 13.65 2.23 15.594 1.114 1.94 4.226 2.652 3.
{"title":"$:/DefaultTiddlers","created":"20220415162121697","modified":"20220415162121697","type":"text/vnd.tiddlywiki","text":"[list[$:/StoryList]]","revision":"0","bag":"default"},
{"title":"$:/Import","text":"Les tiddlers suivants ont été importés :\n\n# [[NoGafamNetwork.png]]","status":"complete"},
{"title":"$:/Import-1","text":"Les tiddlers suivants ont été importés :\n\n# [[qo-op]]","status":"complete"},
{"title":"$:/Import-2","text":"The following tiddlers were imported:\n\n# [[$:/plugins/danielo515/encryptTiddler]]","status":"complete"},
{"created":"20220504002111585","title":"$:/ipfs/saver/api","modified":"20220504002111585","tags":"$:/ipfs/core","text":"$:/ipfs/saver/api/http/localhost/5001"},
{"created":"20220504002114786","title":"$:/ipfs/saver/gateway","modified":"20220504002114786","tags":"$:/ipfs/core","text":"$:/ipfs/saver/gateway/http/localhost"},
{"title":"$:/ipfs/saver/ipns/key","modified":"20220504010219785","tags":"$:/ipfs/core","text":"k2k4r8opmmyeuee0xufn6txkxlf3qva4le2jlbw6da7zynhw46egxwp2"},
{"created":"20220504002122946","title":"$:/ipfs/saver/ipns/name","modified":"20220504002122946","tags":"$:/ipfs/core","text":"_MOAKEY_"},
{"created":"20220504002017358","text":"yes","title":"$:/ipfs/saver/unpin","modified":"20220504002017358","tags":"bluelightav.eth"},
{"created":"20220504002017817","text":"no","title":"$:/ipfs/saver/verbose","modified":"20220504002017817","tags":"bluelightav.eth"},
{"title":"$:/isEncrypted","text":"no","revision":"0","bag":"default"},
{"created":"20220504002326345","title":"$:/language","text":"$:/languages/fr-FR","modified":"20220504002326345"},
{"created":"20220504002540998","title":"$:/language/DefaultNewTiddlerTitle","text":"Nouvelle capsule","modified":"20220504002545111"},
{"title":"$:/languages/fr-FR","name":"fr-FR","plugin-type":"language","description":"Français (France)","author":"xcazin","core-version":">=5.0.0","version":"5.2.2","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/language/Buttons/AdvancedSearch/Caption\":{\"title\":\"$:/language/Buttons/AdvancedSearch/Caption\",\"text\":\"recherche avancée\"},\"$:/language/Buttons/AdvancedSearch/Hint\":{\"title\":\"$:/language/Buttons/AdvancedSearch/Hint\",\"text\":\"Recherche avancée\"},\"$:/language/Buttons/Cancel/Caption\":{\"title\":\"$:/language/Buttons/Cancel/Caption\",\"text\":\"annuler\"},\"$:/language/Buttons/Cancel/Hint\":{\"title\":\"$:/language/Buttons/Cancel/Hint\",\"text\":\"Annule l'édition de ce tiddler\"},\"$:/language/Buttons/Clone/Caption\":{\"title\":\"$:/language/Buttons/Clone/Caption\",\"text\":\"cloner\"},\"$:/language/Buttons/Clone/Hint\":{\"title\":\"$:/language/Buttons/Clone/Hint\",\"text\":\"Clone ce tiddler\"},\"$:/language/Buttons/Close/Caption\":{\"title\":\"$:/language/Buttons/Close/Caption\",\"text\":\"fermer\"},\"$:/language/Buttons/Close/Hint\":{\"title\":\"$:/language/Buttons/Close/Hint\",\"text\":\"Ferme ce tiddler\"},\"$:/language/Buttons/CloseAll/Caption\":{\"title\":\"$:/language/Buttons/CloseAll/Caption\",\"text\":\"fermer tout\"},\"$:/language/Buttons/CloseAll/Hint\":{\"title\":\"$:/language/Buttons/CloseAll/Hint\",\"text\":\"Ferme tous les tiddlers\"},\"$:/language/Buttons/CloseOthers/Caption\":{\"title\":\"$:/language/Buttons/CloseOthers/Caption\",\"text\":\"fermer les autres tiddlers\"},\"$:/language/Buttons/CloseOthers/Hint\":{\"title\":\"$:/language/Buttons/CloseOthers/Hint\",\"text\":\"Ferme les autres tiddlers\"},\"$:/language/Buttons/ControlPanel/Caption\":{\"title\":\"$:/language/Buttons/ControlPanel/Caption\",\"text\":\"panneau de contrôle\"},\"$:/language/Buttons/ControlPanel/Hint\":{\"title\":\"$:/language/Buttons/ControlPanel/Hint\",\"text\":\"Ouvre le panneau de contrôle\"},\"$:/language/Buttons/CopyToClipboard/Caption\":{\"title\":\"$:/language/Buttons/CopyToClipboard/Caption\",\"text\":\"copier dans le presse-papier\"},\"$:/language/Buttons/CopyToClipboard/Hint\":{\"title\":\"$:/language/Buttons/CopyToClipboard/Hint\",\"text\":\"Copie ce texte dans le presse-papier\"},\"$:/language/Buttons/Delete/Caption\":{\"title\":\"$:/language/Buttons/Delete/Caption\",\"text\":\"supprimer\"},\"$:/language/Buttons/Delete/Hint\":{\"title\":\"$:/language/Buttons/Delete/Hint\",\"text\":\"Supprime ce tiddler\"},\"$:/language/Buttons/Edit/Caption\":{\"title\":\"$:/language/Buttons/Edit/Caption\",\"text\":\"éditer\"},\"$:/language/Buttons/Edit/Hint\":{\"title\":\"$:/language/Buttons/Edit/Hint\",\"text\":\"Édite ce tiddler\"},\"$:/language/Buttons/Encryption/Caption\":{\"title\":\"$:/language/Buttons/Encryption/Caption\",\"text\":\"chiffrement\"},\"$:/language/Buttons/Encryption/Hint\":{\"title\":\"$:/language/Buttons/Encryption/Hint\",\"text\":\"Affecte ou résilie le mot de passe pour la sauvegarde de ce wiki\"},\"$:/language/Buttons/Encryption/ClearPassword/Caption\":{\"title\":\"$:/language/Buttons/Encryption/ClearPassword/Caption\",\"text\":\"résilier le mot de passe\"},\"$:/language/Buttons/Encryption/ClearPassword/Hint\":{\"title\":\"$:/language/Buttons/Encryption/ClearPassword/Hint\",\"text\":\"Résilie le mot de passe et sauvegarde ce wiki sans chiffrement\"},\"$:/language/Buttons/Encryption/SetPassword/Caption\":{\"title\":\"$:/language/Buttons/Encryption/SetPassword/Caption\",\"text\":\"affecter un mot de passe\"},\"$:/language/Buttons/Encryption/SetPassword/Hint\":{\"title\":\"$:/language/Buttons/Encryption/SetPassword/Hint\",\"text\":\"Affecte un mot de passe pour sauvegarde une version chiffrée de ce wiki\"},\"$:/language/Buttons/ExportPage/Caption\":{\"title\":\"$:/language/Buttons/ExportPage/Caption\",\"text\":\"exporter tout\"},\"$:/language/Buttons/ExportPage/Hint\":{\"title\":\"$:/language/Buttons/ExportPage/Hint\",\"text\":\"Exporte tous les tiddlers\"},\"$:/language/Buttons/ExportTiddler/Caption\":{\"title\":\"$:/language/Buttons/ExportTiddler/Capti
{"created":"20220402075135098","title":"$:/layout","modified":"20220504003351802","type":"text/vnd.tiddlywiki","text":"$:/plugins/BTC/tiddlywiki-multi-columns/ui/Layout","revision":"0","bag":"default"},
{"created":"20220408181551741","title":"$:/palette","modified":"20220504184250684","type":"text/vnd.tiddlywiki","text":"$:/palettes/Vanilla","revision":"0","bag":"default"},
{"title":"$:/plugins/bimlas/locator","type":"application/json","text":"{\n \"tiddlers\": {\n \"$:/plugins/bimlas/locator/README/CHANGELOG\": {\n \"title\": \"$:/plugins/bimlas/locator/README/CHANGELOG\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"!! 2.0.1\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v2.0.0...v2.0.1]]\\n\\n* Add MIT license\\n\\n!! 2.0.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.5.0...v2.0.0]]\\n\\n''ALMOST COMPLETE REWRITING, BACKWARDS INCOMPATIBLE CHANGES ARE INTRODUCED''\\n\\n* ''It does not require the `kin` filter operator at all''\\n* ''You can filter to any field besides the tags''\\n* You can use the standard search from any `locator-view`\\n* You can use any field to link tiddlers (as \\\"tags\\\")\\n* You can also navigate through tiddler links\\n* You can use arbitrary templates to display context items and field values\\n* ''INCOMPATIBLE CHANGES''\u003Cbr />//Before upgrading to the new version, make a backup (as before upgrading any plugin) and make the following changes.//\\n** Renamed `locator-tags` to `locator-fields`\u003Cbr />//Change the macro call in your tiddlers//\\n** `locator-view` does not supporting `finalFilter` and `tagFilter`\u003Cbr />//Remove them from your macrocalls//\\n** Removed `filter-grandchildren` filter\u003Cbr />//Because it can no longer be passed through parameters.//\\n** The \\\"Open in Locator sidebar\\\" toolbar button is moved from `$:/plugins/bimlas/locator/viewtemplate/open-in-sidebar` to `$:/plugins/bimlas/locator/viewtemplate/open-in-sidebar` and its code is changed as well\u003Cbr />//Compare the old tiddler with the shadow and note the changes if any. Transfer them to the new tiddler and delete the old tiddler.//\\n\\n!! 1.5.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.4.0...v1.5.0]]\\n\\n* Move tiddler from current context to higher- or subtopic by drag-n-dropping in the Locator sidebar\\n* Assign any tiddler to any of the titles in the Locator sidebar by drag-n-dropping\\n* Show the (top-level) base tag to be able to move the tiddler titles there\\n* Add button to open search results in advanced search\\n* Show buttons using the Kin filter only when the filter operator is available\\n* Fix related tag issue (not all of them were listed)\\n* Fix whitespace issue\\n* Refactor the code\\n* Add tutorial to the demo\\n\\n!! 1.4.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.3.1...v1.4.0]]\\n\\n* When there was a space in the search string and \\\"new tiddler\\\" button is used from search, the tiddler title was encapsulated (`[[title with spaces]]`)\\n* When there was a space in any of the breadcrumbs in sidebar and \\\"new tiddler\\\" button is used from it, the tiddler got all of the breadcrumb tags, the title with spaces was encapsulated (literally `[[title with spaces]]` tag)\\n* Add more tips to [[$:/plugins/bimlas/locator/README/TIPS]]\\n* Add descriptive tooltip to buttons\\n\\n!! 1.3.1\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.3.0...v1.3.1]]\\n\\n* Add base tag if there is no breadcrumbs when creating new tiddler in current context\\n* Reword documentation\\n\\n!! 1.3.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.2.0...v1.3.0]]\\n\\n* Create new tiddler from search text\\n\\n!! 1.2.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.1.0...v1.2.0]]\\n\\n* Add button to create new tiddler in current context\\n* Ability to use additional filter on tags\\n\\n!! 1.1.0\\n\\n[[See GitLab for detailed change history of this release|https://gitlab.com/bimlas/tw5-locator/compare/v1.0.0...v1.1.0]]\\n\\n* ''I realized that mo
{"title":"$:/plugins/BTC/tiddlywiki-multi-columns","description":"A multi-column Layout","author":"Simon Huber","version":"0.36.0","list":"readme license","plugin-type":"plugin","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/config/ShortcutInfo/cancel-close-tiddler\":{\"title\":\"$:/config/ShortcutInfo/cancel-close-tiddler\",\"text\":\"Cancel or close the focused Tiddler\"},\"$:/config/ShortcutInfo/dragging-toggle\":{\"title\":\"$:/config/ShortcutInfo/dragging-toggle\",\"text\":\"Toggle dragging on or off\"},\"$:/config/ShortcutInfo/edit-tiddler\":{\"title\":\"$:/config/ShortcutInfo/edit-tiddler\",\"text\":\"Edit the focused tiddler\"},\"$:/config/ShortcutInfo/move-down\":{\"title\":\"$:/config/ShortcutInfo/move-down\",\"text\":\"Move the focused Tiddler one position down\"},\"$:/config/ShortcutInfo/move-left\":{\"title\":\"$:/config/ShortcutInfo/move-left\",\"text\":\"Move the focused tiddler to the previous column\"},\"$:/config/ShortcutInfo/move-right\":{\"title\":\"$:/config/ShortcutInfo/move-right\",\"text\":\"Move the focused tiddler to the next column\"},\"$:/config/ShortcutInfo/move-up\":{\"title\":\"$:/config/ShortcutInfo/move-up\",\"text\":\"Move the focused Tiddler one position up\"},\"$:/config/ShortcutInfo/navigate-down\":{\"title\":\"$:/config/ShortcutInfo/navigate-down\",\"text\":\"Navigate to the next Tiddler after the focused one\"},\"$:/config/ShortcutInfo/navigate-first\":{\"title\":\"$:/config/ShortcutInfo/navigate-first\",\"text\":\"Navigate to the first Tiddler in the current Story River\"},\"$:/config/ShortcutInfo/navigate-last\":{\"title\":\"$:/config/ShortcutInfo/navigate-last\",\"text\":\"Navigate to the last Tiddler in the current Story River\"},\"$:/config/ShortcutInfo/navigate-up\":{\"title\":\"$:/config/ShortcutInfo/navigate-up\",\"text\":\"Navigate to the previous Tiddler before the focused one\"},\"$:/config/ShortcutInfo/new-column\":{\"title\":\"$:/config/ShortcutInfo/new-column\",\"text\":\"Create a new column at the right\"},\"$:/config/ShortcutInfo/next-column\":{\"title\":\"$:/config/ShortcutInfo/next-column\",\"text\":\"Select the next column after the currently selected one\"},\"$:/config/ShortcutInfo/previous-column\":{\"title\":\"$:/config/ShortcutInfo/previous-column\",\"text\":\"Select the previous column before the currently selected one\"},\"$:/config/ShortcutInfo/remove-column\":{\"title\":\"$:/config/ShortcutInfo/remove-column\",\"text\":\"Remove a column from the right\"},\"$:/config/ShortcutInfo/scroll-snap-x-toggle\":{\"title\":\"$:/config/ShortcutInfo/scroll-snap-x-toggle\",\"text\":\"Toggle scroll-snap-x view\"},\"$:/config/ShortcutInfo/search-panel\":{\"title\":\"$:/config/ShortcutInfo/search-panel\",\"text\":\"Toggle the visibility of the top search panel\"},\"$:/config/ShortcutInfo/toggle-user-sidebar\":{\"title\":\"$:/config/ShortcutInfo/toggle-user-sidebar\",\"text\":\"Toggle the visibility of the user panel on/off\"},\"$:/config/StoryViewAnimations\":{\"title\":\"$:/config/StoryViewAnimations\",\"text\":\"\\\\define insert-keyframes()\\n\\n@keyframes slide-in-$(insertTiddlerCSSEscaped)$ {\\n\\tfrom {\\n\\t\\ttransform: translateX($(percentage)$%);\\n\\t\\tmargin-bottom: calc(-$(insertTiddlerHeight)$px - {{$:/config/story-river/tiddler-margin}}px);\\n\\t} to {\\n\\t\\ttransform: translateX(0%);\\n\\t\\tmargin-bottom: 0px;\\n\\t}\\n}\\n\\n[data-tiddler-title=\\\"$(insertTiddlerCSSEscaped)$\\\"].tc-inserting {\\n\\tanimation: slide-in-$(insertTiddlerCSSEscaped)$ {{$:/config/AnimationDuration}}ms;\\n\\tanimation-timing-function: cubic-bezier(0.645, 0.045, 0.355, 1);\\n\\tvisibility: visible;\\n}\\n\\n\\\\end\\n\\n\\\\define remove-keyframes()\\n\\n@keyframes slide-out-$(removeTiddlerCSSEscaped)$ {\\n\\tfrom {\\n\\t\\ttransform: translateX(0%);\\n\\t\\tmargin-bottom: 0px;\\n\\t} to {\\n\\t\\ttransform: translateX($(percentage)$%);\\n\\t\\tmargin-bottom: calc(-$(removeTiddlerHeight)$px - {{$:/config/story-river/tiddler-margin}}px);\\n\\t}\\n}\\n\\n[data-tiddler-title=\\\"$(removeTiddlerCSSEscaped)$\\\"].tc-removing {\\n\\tanimation: slide-out-$(r
{"text":"{\n \"tiddlers\": {\n \"$:/plugins/danielo515/encryptTiddler/Encrypt-Tiddler\": {\n \"title\": \"$:/plugins/danielo515/encryptTiddler/Encrypt-Tiddler\",\n \"created\": \"20140406153742691\",\n \"creator\": \"Danielo515\",\n \"description\": \"add the hability to encrypt individual tiddlers\",\n \"modified\": \"20141029152631265\",\n \"modifier\": \"Danielo Rodriguez\",\n \"tags\": \"index plugins\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"caption\": \"readme\",\n \"text\": \"This plugin adds the ability to encrypt your tiddlers individually. This have several advantages:\\n\\n* You can specify a different password for each tiddler if you want.\\n* You don't have to encrypt your whole wiky.\\n* If you forget your password, you only lose a tiddler.\\n* It's possible to edit the tiddler content , tags and fields ''except the encrypt field'' after encryption. Decrypting your tiddler will restore it to its original state when you encrypted it. This way you can hide the encrypted tiddlers as a \\\"different\\\" thing.\\n* You can even encrypt images.\\n* You can have sensible data in a day to day wiky.\\n* I didn't try this, but theoretically you can apply double encryption by encrypting your wiki too.\"\n },\n \"$:/plugins/danielo515/encryptTiddler/Changelog\": {\n \"title\": \"$:/plugins/danielo515/encryptTiddler/Changelog\",\n \"text\": \"!! V2.5\\n* Added settings tab under ControlPanel\\n* Added the ability to customize the enctypted tiddler text body\\n!! V2.4\\n* Added caption and description to the encrypt button\\n!! V2.3\\n* No need to double type password for decrypt tiddlers\\n* Fix bug with batch encryption\\n* Code simplified\\n!! V2.2\\n* Added the need to type the password twice\\n* Tested on tw 5.1.22\\n!! V2.1\\n* Added control panel.\\n* Added ability to batch encrypt and decrypt tiddlers.\\n* Added some documentation an language strings.\\n\\n\"\n },\n \"$:/plugins/danielo515/encryptTiddler/control-panel/batch-encrypt\": {\n \"title\": \"$:/plugins/danielo515/encryptTiddler/control-panel/batch-encrypt\",\n \"caption\": \"Batch Encryption\",\n \"text\": \"\\\\define lingo-base() $:/language/Search/\\n\u003C\u003Clingo Filter/Hint>>\\n{{$:/plugins/danielo515/encryptTiddler/language/batch}}\\n\\n\u003C$linkcatcher to=\\\"$:/temp/encrypt/filter\\\">\\n\\n\u003Cdiv class=\\\"tc-search tc-advanced-search\\\">\\n\u003C$edit-text tiddler=\\\"$:/temp/encrypt/filter\\\" type=\\\"search\\\" tag=\\\"input\\\" default=\\\"\\\" placeholder=\\\"filter tiddlers\\\"/>\\n\u003C$button popup=\u003C\u003Cqualify \\\"$:/state/filterDropdown\\\">> class=\\\"tc-btn-invisible\\\">\\n{{$:/core/images/down-arrow}}\\n\u003C/$button>\\n\u003C$reveal state=\\\"$:/temp/encrypt/filter\\\" type=\\\"nomatch\\\" text=\\\"\\\">\\n\u003C$button class=\\\"tc-btn-invisible\\\">\\n\u003C$action-setfield $tiddler=\\\"$:/temp/encrypt/filter\\\" $field=\\\"text\\\" $value=\\\"\\\"/>\\n{{$:/core/images/close-button}}\\n\u003C/$button>\\n\\n\\n\u003C$edit-text tag=\\\"input\\\" tiddler=\\\"$:/temp/password1\\\" placeholder=\\\"password\\\" type=\\\"password\\\" default=\\\"\\\" col=\\\"4\\\"/>\\n\u003C$edit-text tag=\\\"input\\\" tiddler=\\\"$:/temp/password2\\\" placeholder=\\\"confirm password\\\" type=\\\"password\\\" default=\\\"\\\" col=\\\"4\\\"/>\\n\u003C$encryptTiddler passwordTiddler1=\\\"$:/temp/password1\\\" passwordTiddler2=\\\"$:/temp/password2\\\" filter={{$:/temp/encrypt/filter}}>\\n\u003C$button message=\\\"tw-encrypt-tiddler\\\">\\nEncrypt\\n\u003C/$button>\\n\u003C$button message=\\\"tw-decrypt-tiddler\\\">\\nDecrypt\\n\u003C/$button>\\n\u003C/$encryptTiddler>\\n\u003C/$reveal>\\n\u003C/div>\\n\\n\u003Cdiv class=\\\"tc-block-dropdown-wrapper\\\">\\n\u003C$reveal state=\u003C\u003Cqualify \\\"$:/state/filterDropdown\\\">> type=\\\"nomatch\\\" text=\\\"\\\" default=\\\"\\\">\\n\u003Cdiv class=\\\"tc-block-dropdown tc-edit-ty
{"title":"$:/plugins/ipfs","type":"application/json","text":"{\n \"tiddlers\": {\n \"$:/ipfs/image/bluelight\": {\n \"title\": \"$:/ipfs/image/bluelight\",\n \"_canonical_uri\": \"/ipfs/bafybeibi5ldguonidlwomjxwjehodpmypgex5qd2fe6f6yuka4dqvbzvpq\",\n \"_import_uri\": \"/ipfs/bafybeiejplubmcgpkaqwjc23ebo6vorv2p4cwlr7kkhm4cakgtneefjuc4\",\n \"modified\": \"20200526065100279\",\n \"tags\": \"$:/ipfs/documentation $:/isAttachment $:/isIpfs\",\n \"type\": \"image/jpg\",\n \"text\": \"\"\n },\n \"$:/core/images/ens\": {\n \"title\": \"$:/core/images/ens\",\n \"modified\": \"20200528044634920\",\n \"source\": \"https://github.com/ensdomains/ens-app/blob/dev/public/safari-pinned-tab.svg\",\n \"license\": \"https://github.com/ensdomains/ens-app/blob/dev/LICENSE\",\n \"tags\": \"$:/tags/Image $:/ipfs/core $:/isAttachment $:/isEmbedded\",\n \"type\": \"image/svg+xml\",\n \"text\": \"\u003C?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\"?>\\n\u003Csvg\\n xmlns:dc=\\\"http://purl.org/dc/elements/1.1/\\\"\\n xmlns:cc=\\\"http://creativecommons.org/ns#\\\"\\n xmlns:rdf=\\\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\\\"\\n xmlns:svg=\\\"http://www.w3.org/2000/svg\\\"\\n xmlns=\\\"http://www.w3.org/2000/svg\\\"\\n xmlns:sodipodi=\\\"http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd\\\"\\n xmlns:inkscape=\\\"http://www.inkscape.org/namespaces/inkscape\\\"\\n version=\\\"1.0\\\"\\n width=\\\"18\\\"\\n height=\\\"18\\\"\\n viewBox=\\\"0 0 128 128\\\"\\n class=\\\"tc-image-button\\\"\\n preserveAspectRatio=\\\"xMidYMid meet\\\"\\n id=\\\"svg14\\\"\\n sodipodi:docname=\\\"ens-small.svg\\\"\\n inkscape:version=\\\"0.92.4 (5da689c313, 2019-01-14)\\\"\\n>\\n \u003Cdefs\\n id=\\\"defs18\\\" />\\n \u003Csodipodi:namedview\\n pagecolor=\\\"#ffffff\\\"\\n bordercolor=\\\"#666666\\\"\\n borderopacity=\\\"1\\\"\\n objecttolerance=\\\"10\\\"\\n gridtolerance=\\\"10\\\"\\n guidetolerance=\\\"10\\\"\\n inkscape:pageopacity=\\\"0\\\"\\n inkscape:pageshadow=\\\"2\\\"\\n inkscape:window-width=\\\"1920\\\"\\n inkscape:window-height=\\\"1020\\\"\\n id=\\\"namedview16\\\"\\n showgrid=\\\"false\\\"\\n inkscape:zoom=\\\"12.361274\\\"\\n inkscape:cx=\\\"41.295086\\\"\\n inkscape:cy=\\\"21.734019\\\"\\n inkscape:window-x=\\\"0\\\"\\n inkscape:window-y=\\\"31\\\"\\n inkscape:window-maximized=\\\"1\\\"\\n inkscape:current-layer=\\\"svg14\\\" />\\n \u003Cmetadata\\n id=\\\"metadata2\\\">\\nCreated by potrace 1.11, written by Peter Selinger 2001-2013\\n\u003Crdf:RDF>\\n \u003Ccc:Work\\n rdf:about=\\\"\\\">\\n \u003Cdc:format>image/svg+xml\u003C/dc:format>\\n \u003Cdc:type\\n rdf:resource=\\\"http://purl.org/dc/dcmitype/StillImage\\\" />\\n \u003Cdc:title>\u003C/dc:title>\\n \u003C/cc:Work>\\n\u003C/rdf:RDF>\\n\u003C/metadata>\\n \u003Cg\\n transform=\\\"matrix(0.08837363,0,0,-0.07925696,-8.0787259,127.6037)\\\"\\n id=\\\"g12\\\"\\n style=\\\"fill:#000000;stroke:none\\\">\\n \u003Cpath\\n d=\\\"m 640,1519 c -69,-48 -173,-122 -231,-163 -94,-65 -110,-82 -134,-129 -30,-63 -37,-155 -15,-222 15,-49 61,-135 71,-135 6,0 437,704 447,731 7,19 -17,4 -138,-82 z\\\"\\n id=\\\"path4\\\"\\n inkscape:connector-curvature=\\\"0\\\" />\\n \u003Cpath\\n d=\\\"m 856,1598 c 4,-7 44,-67 89,-133 118,-175 286,-437 393,-615 93,-154 122,-224 125,-300 2,-55 17,-35 52,75 26,80 28,92 22,217 -7,185 -45,284 -149,387 -35,36 -520,381 -534,381 -3,0 -2,-6 2,-12 z\\\"\\n id=\\\"path6\\\"\\n inkscape:connector-curvature=\\\"0\\\" />\\n \u003Cpath\\n d=\\\"M 141,1068 C 97,969 87,913 93,776 98,649 106,607 146,523 163,485 224,403 254,378 291,346 772,9 776,12 c 2,2 -57,95 -131,206 -132,199 -320,496 -404,639 -48,81 -70,145 -73,210 -1,23 -3,43 -4,43 -2,0 -12,-19 -23,-42 z\\\"\\n id=\\\"path8\\\"\\n in
{"title":"$:/plugins/sq/streams","name":"Streams","description":"Rapid data entry with a keyboard driven workflow. Divide content into smaller tiddlers as you write.","plugin-type":"plugin","plugin-priority":"1","author":"Saq Imtiaz","version":"1.2.24","core-version":">=5.1.23","list":"Settings CHANGELOG","source":"https://saqimtiaz.github.io/streams/","dependents":"$:/plugins/flibbles/relink","type":"application/json","text":"{\"tiddlers\":{\"$:/plugins/sq/streams/CHANGELOG\":{\"title\":\"$:/plugins/sq/streams/CHANGELOG\",\"text\":\"Release notes for the current release:\\n\\n{{$:/plugins/sq/streams/releasenotes}}\\n\\n[[Full changelog|https://saqimtiaz.github.io/streams/#CHANGELOG]] for Streams\\n\"},\"$:/plugins/sq/streams/Settings/config\":{\"title\":\"$:/plugins/sq/streams/Settings/config\",\"caption\":\"Configuration\",\"text\":\"\\\\define sortBySettingsGroupFilter()\\n[get[settings-group]!is[blank]else[!general]] [get[settings-group-header]!is[blank]else[99]] +[join[]]\\n\\\\end\\n\\n\u003C$edit-text tiddler=\\\"$:/state/sq/streams/settings/search\\\" class=\\\"sq-search-input\\\" default=\\\"\\\" tag=\\\"input\\\" type=\\\"search\\\" placeholder=\\\"search...\\\"/>\\n\\n\u003Cdiv class=\\\"sq-list-group sq-list-group-box-shadow sq-list-stream-settings\\\">\\n\u003C$list filter=\\\"[all[shadows+tiddlers]prefix[$:/config/sq/streams]has[settings-template]] +[search:title,caption,description{$:/state/sq/streams/settings/search}] +[sortsub\u003CsortBySettingsGroupFilter>]\\\">\\n\u003C$list filter={{{[{!!condition}!is[blank]] :else[{!!title}]}}} variable=\\\"list-condition\\\">\\n\u003Cdiv class=\\\"sq-list-group-item\\\">\\n\u003C$transclude tiddler={{!!settings-template}}/>\\n\u003C/div>\\n\u003C/$list>\\n\u003C/$list>\\n\u003C/div>\"},\"$:/plugins/sq/streams/Settings/shortcuts\":{\"title\":\"$:/plugins/sq/streams/Settings/shortcuts\",\"caption\":\"Shortcuts\",\"text\":\"\\\\import $:/core/ui/ControlPanel/KeyboardShortcuts\\n\\n\u003Ctable>\\n\u003Ctbody>\\n\u003C$list filter=\\\"[all[shadows+tiddlers]prefix[$:/config/ShortcutInfo/streams-]removeprefix[$:/config/ShortcutInfo/]]\\\" variable=\\\"shortcutName\\\">\\n\u003C\u003Cshortcut-item>>\\n\u003C/$list>\\n\u003C/tbody>\\n\u003C/table>\"},\"$:/plugins/sq/streams/Settings\":{\"title\":\"$:/plugins/sq/streams/Settings\",\"tags\":\"$:/tags/ControlPanel\",\"caption\":\"Streams settings\",\"text\":\"\u003C\u003Ctabs \\\"$:/plugins/sq/streams/Settings/config $:/plugins/sq/streams/Settings/shortcuts\\\" \\\"$:/plugins/sq/streams/Settings/config\\\" \\\"$:/state/streams/settings/tabs\\\">>\\n\"},\"$:/plugins/sq/streams/action-macros\":{\"title\":\"$:/plugins/sq/streams/action-macros\",\"text\":\"\\\\whitespace trim\\n\\n\\\\define swiped-right-actions()\\n\u003C$list filter=\\\"[{$:/config/sq/streams/swipe-behaviour}match[contextmenu]]\\\" variable=\\\"_NULL\\\">\\n\u003C$action-setfield $tiddler=\u003C\u003Ccontextmenu-state>> $field=\\\"current\\\" $value=\u003C\u003Cdom-data-node-title>>/>\\n\u003C$action-setfield $tiddler=\u003C\u003Ccontextmenu-state>> $field=\\\"position\\\" $value={{$:/config/sq/streams/swipe-contextmenu-position}}/>\\n\u003C$action-popup $coords=\u003C\u003Ctv-popup-coords>> $state=\u003C\u003Ccontextmenu-state>>/>\\n\u003C/$list>\\n\u003C$list filter=\\\"[{$:/config/sq/streams/swipe-behaviour}match[indent]]\\\" variable=\\\"_NULL\\\">\\n\u003C$vars currentTiddler=\u003C\u003Cdom-data-node-title>>>\\n\u003C\u003Cindent-node-actions>>\\n\u003C/$vars>\\n\u003C/$list>\\n\\\\end\\n\\n\\\\define swiped-left-actions()\\n\u003C$list filter=\\\"[{$:/config/sq/streams/swipe-behaviour}match[indent]]\\\" variable=\\\"_NULL\\\">\\n\u003C$vars currentTiddler=\u003C\u003Cdom-data-node-title>>>\\n\u003C\u003Cunindent-node-actions>>\\n\u003C/$vars>\\n\u003C/$list>\\n\\\\end\\n\\n\\n\\\\define oncontext-menu-actions()\\n\u003C$action-setfield $tiddler=\u003C\u003Ccontextmenu-state>> $field=\\\"current\\\" $value=\u003C\u003Cdom-data-node-title>>/>\\n\u003C$action-setfield $tiddler=\u003C\u003Ccontextmenu-state>> $field=\\\"position\\\" $value=\\\"left\\\"/>\\n
{"title":"$:/plugins/sq/streams/breadcrumbs-view-template","created":"20200529205858594","list-before":"$:/core/ui/ViewTemplate/body","modified":"20220424075449216","tags":"","type":"text/vnd.tiddlywiki","text":"\\whitespace trim\n\\define stream-show-breadcrumbs()\n\u003C$list filter=\"[\u003CcurrentTiddler>has[stream-type]]\">\n\t\u003C$list filter=\"[\u003CcurrentTiddler>has[parent]]\">\n\t\t\u003C$set name=\"currentTiddler\" filter=\"[{!!parent}]\" select=\"0\">\n\t\t\t\u003C\u003Cstream-show-breadcrumbs>>\n\t\t\u003C/$set>\n\t\u003C/$list>\t\n\t\u003C$list filter=\"[\u003CcurrentTiddler>!match\u003CstoryTiddler>]\">\n\t\t\u003C$wikify name=\"display-title\" text={{{ [\u003CcurrentTiddler>!is[binary]get[text]!is[blank]] ~[{!!title}] }}}>\n\t\t\t\u003Cspan class=\"sq-breadcrumbs-fragment\">\n\t\t\t\u003C$link to=\u003C\u003CcurrentTiddler>>>\n\t\t\t\t\u003C$text text={{{ [\u003Cdisplay-title>split[]first[50]join[]] }}}/>\n\t\t\t\u003C/$link>>\n\t\t\t\u003C/span>\n\t\t\u003C/$wikify>\n\t\u003C/$list>\n\u003C/$list>\n\\end\n\u003C$list filter=\"\"\"[\u003Cfolded-state>get[text]!is[blank]else[show]!match[hide]]\"\"\" variable=\"_NULL\">\n\u003C$list filter=\"[{$:/config/sq/streams/enable-breadcrumbs}match[yes]]\" variable=\"_NULL\">\n\u003C\u003Cstream-show-breadcrumbs>>\n\u003C/$list>\n\u003C/$list>\n\n","revision":"0","bag":"default"},
{"title":"$:/plugins/sq/streams/stream-view-template","created":"20170922203553093","list-after":"$:/core/ui/ViewTemplate/body","modified":"20220424075419948","tags":"","type":"text/vnd.tiddlywiki","text":"\u003C$list filter=\"\"\"[\u003Cfolded-state>get[text]!is[blank]else[show]!match[hide]]\"\"\" variable=\"_NULL\">\n\u003C$list filter=\"\"\"[all[current]subfilter{$:/config/sq/streams/stream-enable-filter}]\"\"\">\n{{||$:/plugins/sq/streams/nodes-list-template}}\n\u003C/$list>\n\u003C/$list>","revision":"0","bag":"default"},
{"text":"{\n \"tiddlers\": {\n \"GeoTiddler\": {\n \"title\": \"GeoTiddler\",\n \"created\": \"20151130173416239\",\n \"modified\": \"20170115153450584\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"[[GeoTiddler]]s are tiddlers containing geographical data. [[geoSyntax|$:/plugins/sycom/leaflet/geoSyntax]] lists the available objects. [[geoJson|https://en.wikipedia.org/wiki/GeoJSON]] data are also accepted. You may specify a color for all objects displayed through `color` field.\\n\\n!! tiddler with geo TiddlerFields\\nYou can upgrade your tiddler by putting some geo metadata ([[wgs 84 coordinates|https://en.wikipedia.org/wiki/World_Geodetic_System#WGS84]]) in it's TiddlerFields. See [[geoSyntax|$:/plugins/sycom/leaflet/geoSyntax]] for the list of object types you can draw. Popup will show the first part of the tiddler. If the tiddler contains a leafmap widget, it will be rendered as `text/plain` in order to avoid crash...\\n\\n!! geoJSON tiddler\\nYou can define a geoJson tiddler like [[tiddlyWikiFrCommunity|$:/plugins/sycom/leaflet/example/tiddlyWikiFrCommunity]] and then display the data by calling it. Just put your geoJson data in the body and declare the tiddler as application/json. Any `application/json` tiddler called will be considered as geoJson. The popups will show\\n\\n* a title\\n** the `name` or the `title` attribute in properties if exists,\\n** if not, the firsts attributes of properties until they are 8 characters long\\n* a description\\n** the `description` attribute in properties if exists,\\n** if not, the data stored in each feature as a bulleted list.\\n\\n!! tiddler grouping [[GeoTiddler]]s\\nYou can use `tiddlers` or `filter` as TiddlerFields to make a group of tiddlers. You can apply some styling options to all the group using `style`, `color` or `marker` TiddlerFields and then call the tiddler in your map to render all those tiddler at the same time. This will be a good way to make thematic maps indeed...\\n\"\n },\n \"$:/plugins/sycom/leaflet/devDiary\": {\n \"title\": \"$:/plugins/sycom/leaflet/devDiary\",\n \"created\": \"20151110173416000\",\n \"modified\": \"20180531171500000\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"Some notes about coding this plugin. Might be useful to others...\\n\\n* 20180602\\n** added a template that will display a map of embeded object for tiddlers containing one of the geoTiddlers fiels.\\n** updtated leaflet and marker-cluster to 1.3.1 - the easy way. Just replaced with new version and no deprecation at all \\\\o/ !\\n* 20180531\\n** converting all `.svg.tid` files to `.svg` + `.svg.meta` pairs. Will allow git client to make svg viewable in web interface. Also compressed SVG as much as possible with great https://jakearchibald.github.io/svgomg/ tool.\\n** tweak : for svg embedding local TiddlyWiki colors (eg `$primary$`), forced type to `text/vnd.tiddlywiki` to preserve them.\\n* 20170317\\n** lot of work around cluster size, cluster color when using filter. Cluster size depends on point % for the cluster, clusterRadius and zoom.\\n* 20170311\\n** added styling options and also the grouping tiddler capabilities. Discovered that direct styling in SVG ''does not always'' [[overwrite css styling|http://stackoverflow.com/questions/24293880/svg-why-does-external-css-override-inline-style-for-text]].\\n* 20170129\\n** adding some markers. And it's possible to create yours.\\n* 20170115\\n** darling birthday edit. Clustering by tiddler is on track. Will have to look for clustering direct passing object through widget.\\n* 20161111\\n** armistice edit! can now disable clustering or set clustering distance. Bug #9 fixed. may be cluster size will be too big for big databases\\n* 20161106\\n** color parameter is partially implemented. Note that direct styling like `fill` in svg element wont take on class styling through css...\\n* 20161104\\n** after many attemps, managed to include tiddler excerpt in popups for mapping ge
{"title":"$:/plugins/tiddlywiki/highlight","name":"Highlight","description":"Highlight.js syntax highlighting","author":"Joao Bolila","list":"readme usage license","version":"5.2.3-prerelease","plugin-type":"plugin","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/config/HighlightPlugin/TypeMappings/application/javascript\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/application/javascript\",\"text\":\"javascript\"},\"$:/config/HighlightPlugin/TypeMappings/application/json\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/application/json\",\"text\":\"json\"},\"$:/config/HighlightPlugin/TypeMappings/text/css\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/text/css\",\"text\":\"css\"},\"$:/config/HighlightPlugin/TypeMappings/text/html\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/text/html\",\"text\":\"html\"},\"$:/config/HighlightPlugin/TypeMappings/image/svg+xml\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/image/svg+xml\",\"text\":\"xml\"},\"$:/config/HighlightPlugin/TypeMappings/text/x-markdown\":{\"title\":\"$:/config/HighlightPlugin/TypeMappings/text/x-markdown\",\"text\":\"markdown\"},\"$:/plugins/tiddlywiki/highlight/highlight.js\":{\"text\":\"var hljs = require(\\\"$:/plugins/tiddlywiki/highlight/highlight.js\\\");\\n/*!\\n Highlight.js v11.4.0 (git: 2d0e7c1094)\\n (c) 2006-2022 Ivan Sagalaev and other contributors\\n License: BSD-3-Clause\\n */\\nvar hljs=function(){\\\"use strict\\\";var e={exports:{}};function t(e){\\nreturn e instanceof Map?e.clear=e.delete=e.set=()=>{\\nthrow Error(\\\"map is read-only\\\")}:e instanceof Set&&(e.add=e.clear=e.delete=()=>{\\nthrow Error(\\\"set is read-only\\\")\\n}),Object.freeze(e),Object.getOwnPropertyNames(e).forEach((n=>{var i=e[n]\\n;\\\"object\\\"!=typeof i||Object.isFrozen(i)||t(i)})),e}\\ne.exports=t,e.exports.default=t;var n=e.exports;class i{constructor(e){\\nvoid 0===e.data&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}\\nignoreMatch(){this.isMatchIgnored=!0}}function r(e){\\nreturn e.replace(/&/g,\\\"&amp;\\\").replace(/\u003C/g,\\\"&lt;\\\").replace(/>/g,\\\"&gt;\\\").replace(/\\\"/g,\\\"&quot;\\\").replace(/'/g,\\\"&#x27;\\\")\\n}function s(e,...t){const n=Object.create(null);for(const t in e)n[t]=e[t]\\n;return t.forEach((e=>{for(const t in e)n[t]=e[t]})),n}const o=e=>!!e.kind\\n;class a{constructor(e,t){\\nthis.buffer=\\\"\\\",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){\\nthis.buffer+=r(e)}openNode(e){if(!o(e))return;let t=e.kind\\n;t=e.sublanguage?\\\"language-\\\"+t:((e,{prefix:t})=>{if(e.includes(\\\".\\\")){\\nconst n=e.split(\\\".\\\")\\n;return[`${t}${n.shift()}`,...n.map(((e,t)=>`${e}${\\\"_\\\".repeat(t+1)}`))].join(\\\" \\\")\\n}return`${t}${e}`})(t,{prefix:this.classPrefix}),this.span(t)}closeNode(e){\\no(e)&&(this.buffer+=\\\"\u003C/span>\\\")}value(){return this.buffer}span(e){\\nthis.buffer+=`\u003Cspan class=\\\"${e}\\\">`}}class c{constructor(){this.rootNode={\\nchildren:[]},this.stack=[this.rootNode]}get top(){\\nreturn this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){\\nthis.top.children.push(e)}openNode(e){const t={kind:e,children:[]}\\n;this.add(t),this.stack.push(t)}closeNode(){\\nif(this.stack.length>1)return this.stack.pop()}closeAllNodes(){\\nfor(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}\\nwalk(e){return this.constructor._walk(e,this.rootNode)}static _walk(e,t){\\nreturn\\\"string\\\"==typeof t?e.addText(t):t.children&&(e.openNode(t),\\nt.children.forEach((t=>this._walk(e,t))),e.closeNode(t)),e}static _collapse(e){\\n\\\"string\\\"!=typeof e&&e.children&&(e.children.every((e=>\\\"string\\\"==typeof e))?e.children=[e.children.join(\\\"\\\")]:e.children.forEach((e=>{\\nc._collapse(e)})))}}class l extends c{constructor(e){super(),this.options=e}\\naddKeyword(e,t){\\\"\\\"!==e&&(this.openNode(t),this.addText(e),this.closeNode())}\\naddText(e){\\\"\\\"!==e&&this.add(e)}addSublanguage(e,t){const n=e.root\\n;n.kind=t,n.sublanguage=!0,this.add(n)}toHTML(){\\nreturn new a(this,this.options).value()}finalize(){retur
{"title":"$:/plugins/tiddlywiki/markdown","name":"Markdown","description":"Markdown parser based on remarkable by Jon Schlinkert and remarkable-katex by Brad Howes","list":"readme usage remarkable-license remarkable-katex-license","version":"5.2.2","plugin-type":"plugin","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/plugins/tiddlywiki/markdown/EditorToolbar/bold\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/bold\",\"list-after\":\"$:/core/ui/EditorToolbar/bold\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/bold\",\"caption\":\"{{$:/language/Buttons/Bold/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Bold/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((bold))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-operation\\\"\\n\\t$param=\\\"wrap-selection\\\"\\n\\tprefix=\\\"**\\\"\\n\\tsuffix=\\\"**\\\"\\n/>\\n\"},\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-1\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-1\",\"list-after\":\"$:/core/ui/EditorToolbar/heading-1\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/heading-1\",\"caption\":\"{{$:/language/Buttons/Heading1/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Heading1/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((heading-1))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-operation\\\"\\n\\t$param=\\\"prefix-lines\\\"\\n\\tcharacter=\\\"#\\\"\\n\\tcount=\\\"1\\\"\\n/>\\n\"},\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-2\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-2\",\"list-after\":\"$:/core/ui/EditorToolbar/heading-2\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/heading-2\",\"caption\":\"{{$:/language/Buttons/Heading2/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Heading2/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((heading-2))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-operation\\\"\\n\\t$param=\\\"prefix-lines\\\"\\n\\tcharacter=\\\"#\\\"\\n\\tcount=\\\"2\\\"\\n/>\\n\"},\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-3\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-3\",\"list-after\":\"$:/core/ui/EditorToolbar/heading-3\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/heading-3\",\"caption\":\"{{$:/language/Buttons/Heading3/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Heading3/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((heading-3))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-operation\\\"\\n\\t$param=\\\"prefix-lines\\\"\\n\\tcharacter=\\\"#\\\"\\n\\tcount=\\\"3\\\"\\n/>\\n\"},\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-4\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-4\",\"list-after\":\"$:/core/ui/EditorToolbar/heading-4\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/heading-4\",\"caption\":\"{{$:/language/Buttons/Heading4/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Heading4/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((heading-4))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-operation\\\"\\n\\t$param=\\\"prefix-lines\\\"\\n\\tcharacter=\\\"#\\\"\\n\\tcount=\\\"4\\\"\\n/>\\n\"},\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-5\":{\"title\":\"$:/plugins/tiddlywiki/markdown/EditorToolbar/heading-5\",\"list-after\":\"$:/core/ui/EditorToolbar/heading-5\",\"tags\":\"$:/tags/EditorToolbar\",\"icon\":\"$:/core/images/heading-5\",\"caption\":\"{{$:/language/Buttons/Heading5/Caption}} (Markdown)\",\"description\":\"{{$:/language/Buttons/Heading5/Hint}}\",\"condition\":\"[\u003CtargetTiddler>type[text/x-markdown]]\",\"shortcuts\":\"((heading-5))\",\"text\":\"\u003C$action-sendmessage\\n\\t$message=\\\"tm-edit-text-opera
{"title":"$:/plugins/tiddlywiki/qrcode","name":"QR Code","description":"QR Code generator","author":"Zeno Zeng","list":"readme usage examples license","version":"5.2.2","plugin-type":"plugin","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/plugins/tiddlywiki/qrcode/MakeContactQR\":{\"title\":\"$:/plugins/tiddlywiki/qrcode/MakeContactQR\",\"tags\":\"$:/tags/MakeQR\",\"caption\":\"Contact\",\"text\":\"\\\\define wifi-url()\\nWIFI:wifi name;T:WPA;S:SSID;P:password;\\n\\\\end\\n\\n\\\\define image(firstname,lastname,address,tel,email)\\n\u003Cimg src=\u003C\u003Cmakeqr text:\\\"\\\"\\\"MECARD:N:$lastname$,$firstname$;ADR:$address$;TEL:$tel$;EMAIL:$email$;;\\\"\\\"\\\" size:\\\"350\\\">>/>\\n\\\\end\\n\\n! Enter the contact details\\n\\nFirst name: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/contact/firstname\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\nLast name: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/contact/lastname\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\nAddress: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/contact/address\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\nTelephone: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/contact/tel\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\nEmail: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/contact/email\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\n! Here is your QR code\\n\\n\u003C$macrocall $name=\\\"image\\\" firstname={{$:/config/plugins/tiddlywiki/qrcode/contact/firstname}} lastname={{$:/config/plugins/tiddlywiki/qrcode/contact/lastname}} address={{$:/config/plugins/tiddlywiki/qrcode/contact/address}} tel={{$:/config/plugins/tiddlywiki/qrcode/contact/tel}} email={{$:/config/plugins/tiddlywiki/qrcode/contact/email}}/>\\n\"},\"$:/plugins/tiddlywiki/qrcode/MakeGenericQR\":{\"title\":\"$:/plugins/tiddlywiki/qrcode/MakeGenericQR\",\"tags\":\"$:/tags/MakeQR\",\"caption\":\"Generic\",\"text\":\"\\\\define image(content)\\n\u003Cimg src=\u003C\u003Cmakeqr text:\\\"\\\"\\\"$content$\\\"\\\"\\\" size:\\\"350\\\">>/>\\n\\\\end\\n\\n! Enter the details\\n\\nYou can also use this form to encode URLs.\\n\\n\u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/generic\\\" default=\\\"\\\" class=\\\"tc-edit-texteditor\\\"/>\\n\\n! Here is your QR code\\n\\n\u003C$macrocall $name=\\\"image\\\" content={{$:/config/plugins/tiddlywiki/qrcode/generic}}/>\\n\"},\"$:/plugins/tiddlywiki/qrcode/MakeWifiQR\":{\"title\":\"$:/plugins/tiddlywiki/qrcode/MakeWifiQR\",\"tags\":\"$:/tags/MakeQR\",\"caption\":\"Wifi\",\"text\":\"\\\\define wifi-url()\\nWIFI:T:WPA;S:SSID;P:password;;\\n\\\\end\\n\\n\\\\define image(network,encryption,ssid,password)\\n\u003Cimg src=\u003C\u003Cmakeqr text:\\\"\\\"\\\"WIFI:T:$encryption$;S:$ssid$;P:$password$;;\\\"\\\"\\\" size:\\\"350\\\">>/>\\n\\\\end\\n\\n! Enter the details of your wifi network\\n\\nEncryption: \u003C$select tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/wifi/encryption\\\" default=\\\"none\\\">\\n\u003Coption value=\\\"none\\\">None\u003C/option>\\n\u003Coption value=\\\"WEP\\\">WEP\u003C/option>\\n\u003Coption value=\\\"WPA\\\">WPA\u003C/option>\\n\u003Coption value=\\\"WPA2\\\">WPA2\u003C/option>\\n\u003C/$select>\\n\\nSSID: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/wifi/ssid\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\nPassword: \u003C$edit-text tiddler=\\\"$:/config/plugins/tiddlywiki/qrcode/wifi/password\\\" tag=\\\"input\\\" default=\\\"\\\"/>\\n\\n! Here is your QR code\\n\\n\u003C$macrocall $name=\\\"image\\\" network={{$:/config/plugins/tiddlywiki/qrcode/wifi/network}} encryption={{$:/config/plugins/tiddlywiki/qrcode/wifi/encryption}} ssid={{$:/config/plugins/tiddlywiki/qrcode/wifi/ssid}} password={{$:/config/plugins/tiddlywiki/qrcode/wifi/password}}/>\\n\"},\"$:/plugins/tiddlywiki/qrcode/ViewToolbarButton\":{\"title\":\"$:/plugins/tiddlywiki/qrcode/ViewToolbarButton\",\"tags\":\"$:/tags/ViewToolbar\",\"list-before\":\"$:/core/ui/Buttons/close\",\"caption\":\"{{$:/plugins/tiddly
{"title":"$:/SidebarStreams/RootTiddler","created":"20220424080142542","modified":"20220425083143181","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220504002459026","title":"$:/SiteSubtitle","text":"Espace Public","modified":"20220504184648331"},
{"created":"20220409192509107","title":"$:/SiteTitle","modified":"20220504184110805","type":"text/vnd.tiddlywiki","text":"qo-op ''{{qo-op!!pseudo}}''","revision":"0","bag":"default"},
{"created":"20220504003706614","title":"$:/state/notebook-sidebar","text":"no","modified":"20220504183340584"},
{"created":"20220504005028935","title":"$:/state/notebook-sidebar-section","text":"$:/core/ui/SideBar/Recent","modified":"20220504005031781"},
{"created":"20220504001141679","title":"$:/state/panel/visibility","text":"no","modified":"20220504185711957"},
{"created":"20220504002254925","title":"$:/state/tab--1963855381","text":"$:/core/ui/ControlPanel/Theme","modified":"20220504184740203"},
{"created":"20220504001402061","title":"$:/state/tab-1749438307","text":"$:/core/ui/ControlPanel/Saving","modified":"20220505172446103"},
{"created":"20220504002015133","title":"$:/state/tab-2065006209","text":"$:/core/ui/ControlPanel/Saving/Ipfs","modified":"20220504005954202"},
{"created":"20220504003502994","title":"$:/state/tab/moresidebar-1850697562","text":"$:/core/ui/MoreSideBar/Recent","modified":"20220504003524859"},
{"created":"20220504003457433","title":"$:/state/tab/sidebar--595412856","text":"$:/core/ui/SideBar/Recent","modified":"20220504185413926"},
{"created":"20220504002003357","title":"$:/state/user-panel/visibility","text":"no","modified":"20220504184512304"},
{"title":"$:/status/RequireReloadDueToPluginChange","text":"no"},
{"title":"$:/Story/Default","bottom-right-panel":"yes","columns":"1 2 3","created":"20220428183227840","dragging-enable":"yes","follow-active-column":"no","hide-scrollbars":"no","horizontal-columns":"2","modified":"20220428183227841","no-tiddler-box-shadows":"no","palette":"$:/palettes/Vanilla","panel-position":"right","panel-show-numbers":"no","panel-width-above-1170px":"35%","panel-width-below-1170px":"50%","panel-width-below-768px":"90%","river-obscured":"yes","scroll-snap-type":"none","show-edit-preview-per-tiddler":"yes","story-1":"Palettes Tips [[Ceci nest pas une pipe.]] [[Configuration Options]]","story-2":"[[The plugin]] [[Keyboard Shortcuts]] [[The Birth of Venus]] [[Star me on GitHub]]","story-3":"[[Responsive Video]] [[Differences between FireFox and Chromium]] [[The Great Wave off the Coast of Kanagawa]]","story-river-padding":"15","tiddler-border":"1","tiddler-margin":"10","type":"text/vnd.tiddlywiki","view":"vertical","revision":"0","bag":"default"},
{"title":"$:/StoryList","created":"20220505172442745","text":"","list":"qo-op","modified":"20220505172853705"},
{"created":"20220409124735965","title":"$:/StoryList-2","list":"$:/ControlPanel moa","modified":"20220504183321052","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-24","list":"","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-3","created":"20220402104129655","list":"[[Responsive Video]] [[Differences between FireFox and Chromium]] [[The Great Wave off the Coast of Kanagawa]]","modified":"20220501113142260","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-4","created":"20220410070906948","list":"","modified":"20220419230323165","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-5","created":"20220410070906948","list":"","modified":"20220418173307919","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-6","created":"20220410070906948","list":"","modified":"20220418173305910","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-7","created":"20220410070906948","list":"","modified":"20220418173303905","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-8","created":"20220418173252923","list":"","modified":"20220418173301958","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList-9","created":"20220418173254766","list":"","modified":"20220418173258534","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/StoryList3","created":"20220416152902388","list":"[[Filter error: Missing [ in filter expression]]","modified":"20220416152941928","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"title":"$:/tags/PageControls","created":"20220425081658421","list":"$:/core/ui/Buttons/home $:/core/ui/Buttons/close-all $:/core/ui/Buttons/fold-all $:/core/ui/Buttons/unfold-all $:/core/ui/Buttons/permaview $:/core/ui/Buttons/new-tiddler $:/core/ui/Buttons/new-journal $:/core/ui/Buttons/new-image $:/core/ui/Buttons/import $:/core/ui/Buttons/export-page $:/core/ui/Buttons/control-panel $:/core/ui/Buttons/advanced-search $:/core/ui/Buttons/manager $:/core/ui/Buttons/tag-manager $:/core/ui/Buttons/language $:/core/ui/Buttons/palette $:/core/ui/Buttons/theme $:/core/ui/Buttons/storyview $:/core/ui/Buttons/encryption $:/core/ui/Buttons/timestamp $:/core/ui/Buttons/full-screen $:/core/ui/Buttons/print $:/core/ui/Buttons/save-wiki $:/core/ui/Buttons/refresh $:/core/ui/Buttons/more-page-actions $:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/dragging-toggle $:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/new-column $:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/remove-column $:/plugins/BTC/tiddlywiki-multi-columns/ui/Buttons/panorama-page-controls","modified":"20220425081658421","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220504003657152","title":"$:/theme","text":"$:/themes/nico/notebook","modified":"20220504184741728"},
{"text":"{\n \"tiddlers\": {\n \"$:/themes/nico/notebook/LICENSE\": {\n \"title\": \"$:/themes/nico/notebook/LICENSE\",\n \"created\": \"20200419141443144\",\n \"modified\": \"20210118213330307\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\nMIT License Copyright (c) 2020 [[Nicolas Petton|https://nicolas.petton.fr]] nicolas@petton.fr\\n\\nPermission is hereby granted, free of charge, to any person obtaining a copy\\nof this software and associated documentation files (the \\\"Software\\\"), to deal\\nin the Software without restriction, including without limitation the rights\\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\\ncopies of the Software, and to permit persons to whom the Software is furnished\\nto do so, subject to the following conditions:\\n\\nThe above copyright notice and this permission notice (including the next\\nparagraph) shall be included in all copies or substantial portions of the\\nSoftware.\\n\\nTHE SOFTWARE IS PROVIDED \\\"AS IS\\\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS\\nFOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS\\nOR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\\nWHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF\\nOR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\\n\"\n },\n \"$:/themes/nico/notebook/themetweaks\": {\n \"title\": \"$:/themes/nico/notebook/themetweaks\",\n \"created\": \"20201217172915960\",\n \"modified\": \"20210123211851680\",\n \"tags\": \"$:/tags/ControlPanel/Appearance\",\n \"caption\": \"{{$:/language/ThemeTweaks/ThemeTweaks}}\",\n \"text\": \"\\\\define lingo-base() $:/language/ThemeTweaks/\\n\\nYou can tweak certain aspects of the ''Notebook'' theme.\\n\\n! \u003C\u003Clingo Options>>\\n\\n|\u003C$link to=\\\"$:/themes/nico/notebook/options/stickytitles\\\">\u003C\u003Clingo Options/StickyTitles>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Options/StickyTitles/Hint>>// |\u003C$select tiddler=\\\"$:/themes/nico/notebook/options/stickytitles\\\">\u003Coption value=\\\"no\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"yes\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003C\u003Clingo Options/CodeWrapping>>\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003Coption value=\\\"pre\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"pre-wrap\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\\\">Reveal tiddler controls on mouseover\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\\\">\u003Coption value=\\\"no\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"yes\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n\\n! \u003C\u003Clingo Settings>>\\n\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/fontfamily\\\">\u003C\u003Clingo Settings/FontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/fontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/codefontfamily\\\">\u003C\u003Clingo Settings/CodeFontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/codefontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/editorfontfamily\\\">\u003C\u003Clingo Settings/EditorFontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/editorfontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n\\n! \u003C\u003Clingo Metrics>>\\n\\n|\u003C$link to=\\\"$:/themes/tiddl
{"title":"$:/themes/tiddlywiki/snowwhite","name":"Snow White","author":"JeremyRuston","core-version":">=5.0.0","plugin-type":"theme","description":"Emphasises individual tiddlers","dependents":"$:/themes/tiddlywiki/vanilla","plugin-priority":"0","version":"5.2.3-prerelease","type":"application/json","text":"{\"tiddlers\":{\"$:/themes/tiddlywiki/snowwhite/base\":{\"title\":\"$:/themes/tiddlywiki/snowwhite/base\",\"tags\":\"[[$:/tags/Stylesheet]]\",\"text\":\"\\\\define sidebarbreakpoint-minus-one()\\n\u003C$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}] }}}/>\\n\\\\end\\n\\n\\\\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline\\n\\n.tc-sidebar-header {\\n\\ttext-shadow: 0 1px 0 \u003C\u003Ccolour sidebar-foreground-shadow>>;\\n}\\n\\n.tc-tiddler-info {\\n\\t\u003C\u003Cbox-shadow \\\"inset 1px 2px 3px rgba(0,0,0,0.1)\\\">>\\n}\\n\\n@media screen {\\n\\t.tc-tiddler-frame {\\n\\t\\t\u003C\u003Cbox-shadow \\\"1px 1px 5px rgba(0, 0, 0, 0.3)\\\">>\\n\\t}\\n}\\n\\n@media (max-width: \u003C\u003Csidebarbreakpoint-minus-one>>) {\\n\\t.tc-tiddler-frame {\\n\\t\\t\u003C\u003Cbox-shadow none>>\\n\\t}\\n}\\n\\n.tc-page-controls button svg, .tc-tiddler-controls button svg, .tc-topbar button svg {\\n\\t\u003C\u003Ctransition \\\"fill 150ms ease-in-out\\\">>\\n}\\n\\n.tc-tiddler-controls button.tc-selected,\\n.tc-page-controls button.tc-selected {\\n\\t\u003C\u003Cfilter \\\"drop-shadow(0px -1px 2px rgba(0,0,0,0.25))\\\">>\\n}\\n\\n.tc-tiddler-frame input.tc-edit-texteditor,\\n.tc-tiddler-frame select.tc-edit-texteditor {\\n\\t\u003C\u003Cbox-shadow \\\"inset 0 1px 8px rgba(0, 0, 0, 0.15)\\\">>\\n}\\n\\n.tc-edit-tags {\\n\\t\u003C\u003Cbox-shadow \\\"inset 0 1px 8px rgba(0, 0, 0, 0.15)\\\">>\\n}\\n\\n.tc-tiddler-frame .tc-edit-tags input.tc-edit-texteditor {\\n\\t\u003C\u003Cbox-shadow \\\"none\\\">>\\n\\tborder: none;\\n\\toutline: none;\\n}\\n\\ntextarea.tc-edit-texteditor {\\n\\tfont-family: {{$:/themes/tiddlywiki/vanilla/settings/editorfontfamily}};\\n}\\n\\ncanvas.tc-edit-bitmapeditor {\\n\\t\u003C\u003Cbox-shadow \\\"2px 2px 5px rgba(0, 0, 0, 0.5)\\\">>\\n}\\n\\n.tc-drop-down {\\n\\tborder-radius: 4px;\\n\\t\u003C\u003Cbox-shadow \\\"2px 2px 10px rgba(0, 0, 0, 0.5)\\\">>\\n}\\n\\n.tc-block-dropdown {\\n\\tborder-radius: 4px;\\n\\t\u003C\u003Cbox-shadow \\\"2px 2px 10px rgba(0, 0, 0, 0.5)\\\">>\\n}\\n\\n.tc-modal {\\n\\tborder-radius: 6px;\\n\\t\u003C\u003Cbox-shadow \\\"0 3px 7px rgba(0,0,0,0.3)\\\">>\\n}\\n\\n.tc-modal-footer {\\n\\tborder-radius: 0 0 6px 6px;\\n\\t\u003C\u003Cbox-shadow \\\"inset 0 1px 0 #fff\\\">>;\\n}\\n\\n\\n.tc-alert {\\n\\tborder-radius: 6px;\\n\\t\u003C\u003Cbox-shadow \\\"0 3px 7px rgba(0,0,0,0.6)\\\">>\\n}\\n\\n.tc-notification {\\n\\tborder-radius: 6px;\\n\\t\u003C\u003Cbox-shadow \\\"0 3px 7px rgba(0,0,0,0.3)\\\">>\\n\\ttext-shadow: 0 1px 0 rgba(255,255,255, 0.8);\\n}\\n\\n.tc-sidebar-lists .tc-tab-set .tc-tab-divider {\\n\\tborder-top: none;\\n\\theight: 1px;\\n\\t\u003C\u003Cbackground-linear-gradient \\\"left, rgba(0,0,0,0.15) 0%, rgba(0,0,0,0.0) 100%\\\">>\\n}\\n\\n.tc-more-sidebar > .tc-tab-set > .tc-tab-buttons > button {\\n\\t\u003C\u003Cbackground-linear-gradient \\\"left, rgba(0,0,0,0.01) 0%, rgba(0,0,0,0.1) 100%\\\">>\\n}\\n\\n.tc-more-sidebar > .tc-tab-set > .tc-tab-buttons > button.tc-tab-selected {\\n\\t\u003C\u003Cbackground-linear-gradient \\\"left, rgba(0,0,0,0.05) 0%, rgba(255,255,255,0.05) 100%\\\">>\\n}\\n\\n.tc-message-box img {\\n\\t\u003C\u003Cbox-shadow \\\"1px 1px 3px rgba(0,0,0,0.5)\\\">>\\n}\\n\\n.tc-plugin-info {\\n\\t\u003C\u003Cbox-shadow \\\"1px 1px 3px rgba(0,0,0,0.5)\\\">>\\n}\\n\"}}}","revision":"0","bag":"default"},
{"title":"$:/themes/tiddlywiki/vanilla","name":"Vanilla","author":"JeremyRuston","core-version":">=5.0.0","plugin-type":"theme","description":"Basic theme","plugin-priority":"0","version":"5.2.3-prerelease","dependents":"","type":"application/json","text":"{\"tiddlers\":{\"$:/themes/tiddlywiki/vanilla/themetweaks\":{\"title\":\"$:/themes/tiddlywiki/vanilla/themetweaks\",\"tags\":\"$:/tags/ControlPanel/Appearance\",\"caption\":\"{{$:/language/ThemeTweaks/ThemeTweaks}}\",\"text\":\"\\\\define lingo-base() $:/language/ThemeTweaks/\\n\\n\\\\define replacement-text()\\n[img[$(imageTitle)$]]\\n\\\\end\\n\\n\\\\define backgroundimage-dropdown()\\n\u003Cdiv class=\\\"tc-drop-down-wrapper\\\">\\n\u003C$set name=\\\"state\\\" value=\u003C\u003Cqualify \\\"$:/state/popup/themetweaks/backgroundimage\\\">>>\\n\u003C$button popup=\u003C\u003Cstate>> class=\\\"tc-btn-invisible tc-btn-dropdown\\\">{{$:/core/images/down-arrow}}\u003C/$button>\\n\u003C$reveal state=\u003C\u003Cstate>> type=\\\"popup\\\" position=\\\"belowleft\\\" text=\\\"\\\" default=\\\"\\\" class=\\\"tc-popup-keep\\\">\\n\u003Cdiv class=\\\"tc-drop-down\\\" style=\\\"text-align:center;\\\">\\n\u003C$macrocall $name=\\\"image-picker\\\" actions=\\\"\\\"\\\"\\n\\n\u003C$action-setfield\\n\\t$tiddler=\\\"$:/themes/tiddlywiki/vanilla/settings/backgroundimage\\\"\\n\\t$value=\u003C\u003CimageTitle>>\\n/>\\n\\n\u003C$action-deletetiddler $tiddler=\u003C\u003Cstate>>/>\\n\\n\\\"\\\"\\\"/>\\n\u003C/div>\\n\u003C/$reveal>\\n\u003C/$set>\\n\u003C/div>\\n\\\\end\\n\\n\\\\define backgroundimageattachment-dropdown()\\n\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/settings/backgroundimageattachment\\\" default=\\\"scroll\\\">\\n\u003Coption value=\\\"scroll\\\">\u003C\u003Clingo Settings/BackgroundImageAttachment/Scroll>>\u003C/option>\\n\u003Coption value=\\\"fixed\\\">\u003C\u003Clingo Settings/BackgroundImageAttachment/Fixed>>\u003C/option>\\n\u003C/$select>\\n\\\\end\\n\\n\\\\define backgroundimagesize-dropdown()\\n\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/settings/backgroundimagesize\\\" default=\\\"scroll\\\">\\n\u003Coption value=\\\"auto\\\">\u003C\u003Clingo Settings/BackgroundImageSize/Auto>>\u003C/option>\\n\u003Coption value=\\\"cover\\\">\u003C\u003Clingo Settings/BackgroundImageSize/Cover>>\u003C/option>\\n\u003Coption value=\\\"contain\\\">\u003C\u003Clingo Settings/BackgroundImageSize/Contain>>\u003C/option>\\n\u003C/$select>\\n\\\\end\\n\\n\u003C\u003Clingo ThemeTweaks/Hint>>\\n\\n! \u003C\u003Clingo Options>>\\n\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/options/sidebarlayout\\\">\u003C\u003Clingo Options/SidebarLayout>>\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/options/sidebarlayout\\\">\u003Coption value=\\\"fixed-fluid\\\">\u003C\u003Clingo Options/SidebarLayout/Fixed-Fluid>>\u003C/option>\u003Coption value=\\\"fluid-fixed\\\">\u003C\u003Clingo Options/SidebarLayout/Fluid-Fixed>>\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/options/stickytitles\\\">\u003C\u003Clingo Options/StickyTitles>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Options/StickyTitles/Hint>>// |\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/options/stickytitles\\\">\u003Coption value=\\\"no\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"yes\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003C\u003Clingo Options/CodeWrapping>>\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003Coption value=\\\"pre\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"pre-wrap\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n\\n! \u003C\u003Clingo Settings>>\\n\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/settings/fontfamily\\\">\u003C\u003Clingo Settings/FontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/tiddlywiki/vanilla/settings/fontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/
{"title":"$:/themes/tiddlywiki/vanilla/options/stickytitles","created":"20220402180716390","modified":"20220402180716390","type":"text/vnd.tiddlywiki","text":"yes","revision":"0","bag":"default"},
{"title":"$:/themes/tiddlywiki/vanilla/settings/editorfontfamily","created":"20220418163439176","modified":"20220423080510132","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220424042245382","title":"$:/UserPanelSubtitle","modified":"20220504003026882","type":"text/vnd.tiddlywiki","text":"MadeInZion","revision":"0","bag":"default"},
{"created":"20220424042238781","title":"$:/UserPanelTitle","modified":"20220504003019519","type":"text/vnd.tiddlywiki","text":"Astroport.ONE","revision":"0","bag":"default"},
{"title":"$:/view","created":"20220403091112476","modified":"20220428183149011","type":"text/vnd.tiddlywiki","text":"multi-column","revision":"0","bag":"default"},
{"title":"Astroport","text":"''Astroport est un réseau hébergé entre amis.''\n\nC'est une couche logicielle qui une fois installée sur votre machine Linux permet à votre ordinateur de partager des données dans un disque IPFS avec ses amis selon le niveau de confiance établi sur Gchange.\n\nhttps://astroport.com\n","created":"20210804081616558","modified":"20220504010547346","tags":"astroport $:/isAttachment $:/isEmbedded"},
{"created":"20220418235920180","text":"\u003Ciframe width=\"560\" height=\"315\" src=\"https://www.youtube.com/embed/7oVxT5sioIE\" title=\"YouTube video player\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen>\u003C/iframe>\n\nAjoutez le tag '''madeinzion''' à vos publications pour transmettre des savoirs qui ont pour référence la performance de terraformation forêt jardin 'Astroport ONE'\n\n","tags":"astroport madeinzion teaser youtube fun $:/isAttachment $:/isEmbedded","title":"Astroport 20:12","modified":"20220504010547347"},
{"created":"20220419000149722","text":"","title":"Astroport_Final.mp4","type":"video/mp4","modified":"20220504010547345","tags":"$:/isAttachment $:/isIpfs $:/isEmbedded","_canonical_uri":"/ipfs/bafybeigxyafff5krojrfix75eq7cw5p5itpr465nurdnbl3pfx65tmzxxi"},
{"created":"20201219182728557","text":"! git.p2p.legal\n\n\u003Ca href=\"https://git.p2p.legal/qo-op/Astroport.ONE\" target=\"_blank\" class=\"tc-red-icon\">\u003Csvg enable-background=\"new 0 0 24 24\" viewBox=\"0 0 24 24\" width=\"240pt\" height=\"240pt\">\u003Cg>\u003Crect fill=\"none\" height=\"24\" width=\"24\" x=\"0\"/>\u003Cpolygon points=\"14.43,10 12,2 9.57,10 2,10 8.18,14.41 5.83,22 12,17.31 18.18,22 15.83,14.41 22,10\"/>\u003C/g>\u003C/svg>\u003C/a>\n","title":"Astroport.ONE","modified":"20220504005503871","tags":"","type":"text/vnd.tiddlywiki","revision":"0","bag":"default"},
{"created":"20220418235829684","text":"\u003C$leafmap\ntileControl\ntile='sat'\nzoom='14'\nplaces='{\"point\":\"43.60,1.43\"}'\n/>\n\nExemple de localisation sur une carte","tags":"$:/isAttachment $:/isEmbedded","title":"Carte","modified":"20220504010547346"},
{"created":"20220504005648767","text":"","title":"Ceci nest pas une pipe.","type":"image/jpeg","modified":"20220504005712630","tags":"$:/isAttachment $:/isIpfs","_canonical_uri":"/ipfs/bafybeidhghlcx3zdzdah2pzddhoicywmydintj4mosgtygr6f2dlfwmg7a"},
{"title":"Configuration Options","created":"20220403175032310","modified":"20220425140237359","tags":"Info","type":"text/vnd.tiddlywiki","text":"\u003Cdiv>\n\n!!! user-panel header title\n\u003C$link to=\"$:/UserPanelTitle\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/UserPanelTitle\" default=\"\" placeholder=\"user-panel title\"/>\u003Cbr>\n\u003Chr>\n\n!!! user-panel header subtitle\n\u003C$link to=\"$:/UserPanelSubtitle\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/UserPanelSubtitle\" default=\"\" placeholder=\"user-panel subtitle\"/>\u003Cbr>\n\u003Chr>\n\n!!! dragging enabled\n\u003C$link to=\"$:/config/story-river/dragging-enable\"/>\u003Cbr>\n\u003C$select tiddler=\"$:/config/story-river/dragging-enable\" default=\"yes\">\n\u003Coption value=\"yes\">yes\u003C/option>\n\u003Coption value=\"no\">no\u003C/option>\n\u003C/$select>\n\u003Chr>\n\n!!! ''scroll-snap-type'' in wide view (is \"x mandatory\" in narrow view)\n\u003C$link to=\"$:/config/story-river/scroll-snap-type\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/scroll-snap-type\" default=\"\" placeholder=\"scroll-snap-type\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''scroll duration'' in x-direction\n\u003C$link to=\"$:/config/story-river/scroll-x-duration\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/scroll-x-duration\" default=\"\" placeholder=\"scroll-x-duration\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''tiddler margin-bottom''\n\u003C$link to=\"$:/config/story-river/tiddler-margin\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/tiddler-margin\" default=\"\" placeholder=\"tiddler margin-bottom\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''story-river padding''\n\u003C$link to=\"$:/config/story-river/padding\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/padding\" default=\"\" placeholder=\"story-river padding\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''tiddler border-thickness''\n\u003C$link to=\"$:/config/story-river/tiddler-border\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/tiddler-border\" default=\"\" placeholder=\"tiddler border-thickness\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''amount of columns in horizontal view''\n\u003C$link to=\"$:/config/story-river/horizontal/columns\"/>\u003Cbr>\n\u003C$edit-text tag=\"input\" tiddler=\"$:/config/story-river/horizontal/columns\" default=\"\" placeholder=\"amount of columns\"/>\u003Cbr>\n\u003Chr>\n\n!!! ''show the search panel on top or bottom''\n\u003C$link to=\"$:/config/story-river/search-panel\"/>\u003Cbr>\n\u003C$select tiddler=\"$:/config/story-river/search-panel\" default=\"bottom\">\n\u003Coption value=\"bottom\">bottom\u003C/option>\n\u003Coption value=\"top\">top\u003C/option>\n\u003C/$select>\n\u003Chr>\n\n!!! ''show the bottom right panel''\n\u003C$link to=\"$:/config/story-river/bottom-right-panel\"/>\u003Cbr>\n\u003C$checkbox tiddler=\"$:/config/story-river/bottom-right-panel\" field=\"text\" checked=\"yes\" unchecked=\"no\" default=\"yes\"> show or hide\u003C/$checkbox>\n\u003Chr>\n\n!!! show the ''side panel'' on the ''right'' or the ''left''\n\u003C$link to=\"$:/config/panel/position\"/>\u003Cbr>\n\u003C$select tiddler=\"$:/config/panel/position\" default=\"right\">\n\u003Coption value=\"right\">right\u003C/option>\n\u003Coption value=\"left\">left\u003C/option>\n\u003C/$select>\n\u003Chr>\n\n!!! obscure the ''story river'' when the ''panel'' is shown\n\u003C$link to=\"$:/config/panel/river-obscured\"/>\u003Cbr>\n\u003C$select tiddler=\"$:/config/panel/river-obscured\" default=\"yes\">\n\u003Coption value=\"yes\">yes\u003C/option>\n\u003Coption value=\"no\">no\u003C/option>\n\u003C/$select>\n\u003Chr>\n\n!!! show the ''numbers'' in the panel's column-buttons\n\u003C$link to=\"$:/config/panel/show-numbers\"/>\u003Cbr>\n\u003C$select tiddler=\"$:/config/panel/show-numbers\" default=\"no\">\n\u003Coption value=\"yes\">yes\u003C/option>\n\u003Coption value=\"no\">no\u003C/option>\n\u003C/$select>\n\u003Chr>\n\n!!! make the ''move-to'' column the active column\n\u003C$link to=
{"created":"20220418133105726","text":"/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAMCAgICAgMCAgIDAwMDBAYEBAQEBAgGBgUGCQgKCgkICQkKDA8MCgsOCwkJDRENDg8QEBEQCgwSExIQEw8QEBD/2wBDAQMDAwQDBAgEBAgQCwkLEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBD/wAARCAFyAlgDAREAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwD9U6ACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKAOY8bfErwB8N7H+0fHnjHSdChZSyfbbpY3lx/wA80J3OfZQTQB4fr3/BQr9mfRoZJLDxBrGuOnIjsNImVn47G4EQ9uSPy5oA5of8FIPABAI+Evj4g8gi1g/+OUAafgX9tPxN48+I3hzwnZ/s9+KNN0XX7s2o1e+Z02fKSXCeTsIXGW/edOe2CAfVNABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUAFABQAUANJCgkkADkk0AfInxM/ad+IPxY8ZXPwW/ZIskv76A+Xq3i19rWdkucExOQy7eo80g5IPlqxw1AGt4E/YD+HNref8JR8Zte1f4i+JbnEl1Nf3UiWxk9lDeY+OnzuQQPujpQB754f+Fvw08KNE3hj4e+G9JaHBR7LSoIWXrzuVQc8nn3NAHV0AFABQAUAFABQAUAFAHivx/wDgJ4u+NGoaFceHvjTr/gi00qO4W5t9MEmLtn27HJSWPBXaR827g8becgHjOpeDP2z/ANmZH1vwb44Pxc8JW2ZbrTNTR3vo4xyxUMzS8DOPKkbnkx4FAH0T8Cvjb4W+PXgG38b+GVkt23m2v7CVg0llcqAWjJGNwwwKsANykHAOQAD0egAoAKACgAoAKACgAoAKACgAoAKACgAoAKAKl1qWnWTKl7f21uzDKiWVUJHtk0AY3iD4i+APCmnnVfE3jfQ9Ls1ODNd6hFEpPoCzcn2HNAHifxB/b1+Afg9jp/h7VL3xnqrN5cVpoduXRnPQGZ9qEE8fIXPtQBxsXx9/bg+IIN98NP2adP0PS5cCOTxFMUm2npIPNlt8jGDxGwx0zQBI3xU/4KG+Fx9r8QfATwprljD80v8AZtwpuHB7KEumbj/rkaALWif8FBvC2k6kmgfG34XeLPh7qTfe+0WzTwqB1YgrHLj/AHY2+tAH0b4H+JPgL4laZ/a/gLxbpmuWq4DtaTh2iPo6feQ+zAGgDp6ACgAoAKACgAoAKACgAoAKACgBpIUEkgAckmgD5U8aftafEbxf44v/AAH+yj8N7PxzJoIzq2r3cmLENkjZE3mRqeQwDl/mIbarAbiAY7/tv/FD4cSrD8fv2bdf0O2DAPqemlmg+iiQeWx+k1AHvvwl/aB+FHxstGm8AeK7e7uok3z6fMDDeQjuWibBKgkDcuVz3oA9IoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKACgAoAKAPmP9u/x/4h0L4e6H8MvB1y0GufEjVU0WNkYq/2bKiVVI5+ZpIUP+y7etAHrnwW+DnhH4H+BbLwT4Ws41MSK99eFAJr65x880h6nJzgdFXCjgUAegUAFABQAUAFABQAUAFABQAUAFABQB8WaPF/wy9+2s2gWii28D/GKMSQxD5Yra/LNtVR0yJiVAGAEul/u0AfadABQAUAFABQAUAFABQAUAFABQAUAFABQAUAeG/GT9j74R/HLxWnjTxm+uRailolmTY3qxo0aFiuVZGwRuPTFAHJ6J/wTs/Zv0q9S8u9P1/V0Q5+z32qERE+/kqjH/vqgD2bwJ8FPhP8Mvn8CfD7RNHnxtNzDaqbgj0MzZkI9i1AHcUAFAGXr/hrw94q02TR/FGh6fq9hMMSW19bJPE3GOVcEUAfMfxF/YY0qw1L/hPf2bfFF78PfFdsGeKCG5k+xXBJBMZOS8SkjkDemONmKANf9nb9qLWvEfia4+CPx40lPDXxJ0tvKUOFjh1QAZymPlEhXDYUlXHzJx8oAPpmgAoAKACgAoAKACgAoAKACgD5G/af+Lni34k+NIf2TvgXcFtb1YFPE+qRk+Xp1oQPMiLj7vynMhHYrGMs5AAPfvg58H/CXwQ8DWfgfwfabYYR5l1d
{"modified":"20220504010547344","created":"20220419002338448","tags":"$:/isAttachment $:/isEmbedded","title":"Film","text":"!!This is an encrypted Tiddler","encrypted":"{\"iv\":\"VUNVD1K4E8OWkUHW4lCWxw==\",\"v\":1,\"iter\":10000,\"ks\":128,\"ts\":64,\"mode\":\"ccm\",\"adata\":\"\",\"cipher\":\"aes\",\"salt\":\"h77szPMvQQs=\",\"ct\":\"ImO/XCVDnjuMhGHF4PJc8o7hzERoHRSavWg8QpB+uYGUCRU3PKmcBTFCI4Jp+KoX4b/NaaK3aMhJ5hWZZq0JwZzO7ljCKxntjb67+kkfB9vmjOB/6qD9fs3HGXdJewQiKQhBcqZfNA1Ywo5hsOi5878IbWFVrc6baHuRF1HTleAkOYNvY8oukQWP9Q3byjRGn9/zBZFo2APe4l/OccGA0xLmgdblRG0lEAHlUW3rK0dAhmabKSrU+U+iZK6euR2kaV2bD/TC4z+fty8aBr2JMGCSML+jpvP30u9lkPpHMed3RB0dlgWhIRx4dejmW2vogTXQxfF2723Uqoq1mD8eDArWCd9TA8uCmvJpSZBwug5IcOrNw3XNRZbyzSZ879b4D49Z8Tm7Axy94Qn/1VjFYrc4aDiandChryPmv/AZnAiK0hTRAwzZO8mz6pIiX5YnmQs0sETSY+/K/2mTxf7ph+gGYXZy67G+AxpG8fuKnJzzbv46iwQeXVOej0ggukCXCB+WH6dAKJ4ZqD1/AKFw1eJGQfzTIzz44h8y+oX53Qo/O45CI9N0Au7vmdy37kqCmo6V+z1rrIScrJoab0xdc0AsND39gHQiLW5QbdT/GrTB7C8KAq1TDqiAkj3eyKxV35IX8F6dZgRqf0vl7huiXn0arUsatlSxKkN5oOTPoDnfHanouHfwFjCTm9k4kg4RTBU3d2I7lkeAeFGyVSwlx09k2Pw3q8JUQ8cERJTpwUkpjwz77RfzRN4JdsVEe5TKNyhNF7ESgS/D1A==\"}"},
{"title":"Horse Galloping (Loop)","created":"20180412012043642","modified":"20220504010547347","type":"audio/ogg","text":"","tags":"$:/isAttachment $:/isIpfs $:/isEmbedded","_canonical_uri":"/ipfs/bafybeiabqsvx55vupvrizpdn23rjxn6pcrixzopsi7hs5gppn73yt75ore"},
{"title":"Info","created":"20220418141937235","list":"[[Configuration Options]] [[Keyboard Shortcuts]] Tips","modified":"20220418144031517","type":"text/vnd.tiddlywiki","text":"\u003C\u003Clist-links \"[tag[Info]]\">>","revision":"0","bag":"default"},
{"title":"Keyboard Shortcuts","created":"20220328115216253","modified":"20220428180225785","tags":"Info","type":"text/vnd.tiddlywiki","text":"\u003Ckbd>Alt-Right\u003C/kbd>: next column\u003Cbr>\n\u003Ckbd>Alt-Left\u003C/kbd>: previous column\u003Cbr>\n\u003Ckbd>Alt-Shift-S\u003C/kbd>: sidebar / panel\u003Cbr>\n\u003Ckbd>Alt-Shift-U\u003C/kbd>: user sidebar / panel\u003Cbr>\n\u003Ckbd>Alt-D\u003C/kbd>: dragging toggle\u003Cbr>\n\u003Ckbd>Ctrl-Alt-N\u003C/kbd>: new column\u003Cbr>\n\u003Ckbd>Ctrl-Alt-B\u003C/kbd>: remove column\u003Cbr>\n\u003Ckbd>Alt-S\u003C/kbd>: scroll-snap-type x toggle\u003Cbr>\n\u003Ckbd>Alt-F\u003C/kbd>: search panel\u003Cbr>\n\u003Ckbd>Alt-Down\u003C/kbd>: navigate down\u003Cbr>\n\u003Ckbd>Alt-Up\u003C/kbd>: navigate up\u003Cbr>\n\u003Ckbd>Alt-C\u003C/kbd>: cancel or close tiddler\u003Cbr>\n\u003Ckbd>Alt-E\u003C/kbd>: edit tiddler\u003Cbr>\n\u003Ckbd>Alt-Home\u003C/kbd>: navigate to the first tiddler\u003Cbr>\n\u003Ckbd>Alt-End\u003C/kbd>: navigate to the last tiddler\u003Cbr>\n\u003Ckbd>Alt-Shift-Down\u003C/kbd>: move tiddler down\u003Cbr>\n\u003Ckbd>Alt-Shift-Up\u003C/kbd>: move tiddler up\u003Cbr>\n\u003Ckbd>Alt-Shift-Right\u003C/kbd>: move tiddler right\u003Cbr>\n\u003Ckbd>Alt-Shift-Left\u003C/kbd>: move tiddler left\u003Cbr>\n\n\u003Chr>","revision":"0","bag":"default"},
{"title":"NoGafamNetwork.png","text":"iVBORw0KGgoAAAANSUhEUgAAAPIAAABCCAIAAADiwByGAAAAA3NCSVQICAjb4U/gAAAAGXRFWHRTb2Z0d2FyZQBnbm9tZS1zY3JlZW5zaG907wO/PgAAIABJREFUeJztXXlcU1f2Py8JICAkeQgCZmEJAZdQ0bogwa3WBbB2WqcL2ulqq4zdRp3W6XSm085PbG0702krU52Z+rOV1nHcWsFpR6wVrIOtVaQIBNkCuMDjJQEJZHn3/v54yUtIQgiL1Prj+/Hj5+Vy77nnvHveueeeuxEYYxjFKG4t8H5sBkYxiuHHqFqP4hbEqFqP4hbEqFqP4hbEqFqP4hbEqFqP4hbEqFqP4haE4EZX0Nraeu3atdbW1qtXr7a2tvr7+0dGRo63IzQ09EYz8OPi/7P4NTWX0lNTH3rk0Te2vY4xJgiCTd+4YeMnH39cfPp0fHzcDaqauBHTMXq9/tixY5999llzc0tNVdXqX/xiS+4WhBCPZ+scNm369d49e2ITEjo6DEuXLs3IyJg7d+6ws/FjgRP/2LFjyzIyCj8/Eh8fv2jxYqUy4eq11i8KC2s0mtxt2556ck1MTMytJ/7SxUuOfvFv9rnzodWWolPg5w+cmhEEMFa/jHkhH/wNCB7GeMG8+V8XnxxeHoZZrT/66KN9+/adPfNt85XLbErHPcus39UBjweIceTDmD8nXrjXJrxsgoTv75eZmbl69erU1NRh5GeEwYovFIq2bXtj/PjxAADIrJ8xG9PdgDHGmG1dgUoeWvAftkhxyam/5uV9882pn7r4kqjopsstANAePoEIDGYTQ/L/0pn9DACQWg0tU7L/g9lESCPxNZ2tJGEkG5sBYFJiUqWmeni4wcOEbdu2PbV2rclkQgh1/vpXlETB/jN9faJdpaIkCoQQ9//1ba9yGSiJovM3mxBCXUZjamrqvHnziouLh4urEcO2bdvkcvm9965ECCGrhZImsKK1T5xMSRTI3ENJFPSUZMbYSU2QIcbsLD5CCCE0e+YsoVD4UxR/5oyZCCHGbGTFMV88x0pESRSMyejc7mw6nbagLUxKyWw/u977E1uQsVoQQgvmLxg6S8Og1vX19fPmzbNJIkukJAo6eSonGD1nhkOwCfEIIWtrI5vS+fxaZDUhhPQrf0ZJFJRMyZYKDw9/+eWXzWbz0HkbAdTX16enpz/zzLMIofZ4JSVRtCdPZaxmekYKK7X1ckPns8+1yxI7Nz/t3sbsMyVR0JOTEUKZyzKFQuFPSHyzxcKJQEkUVGQcY2ilJIqOxx66/trmnv/9GyVN4MRkHxhjOyVRWKrL6KlTnb9t7oFhmCFyNVS1PnToUMptUzmeOp/LsWuw1PYgS9TdscghmMXoLKRu+SKbYNHxiLFSEgUlVSKEkpSJ6enpTU1NQ2TvRuPQoUNpqXMQQu1xSkcLdXc4665x+1tUZGxnQpKl+gdKorCUn3Uod6SMa0v2M6CnTEYILV289OYXPzpiPEKI7ZcQQu2Jk83nz1DR8Uwn7dBUWRwlj6NiEm0iM5Ze/bY0wWpooyQK3dI7u7bnUhJFW5SckigoSQJCSC6RDpq3Ian1xo0bEULm8m8picJSX+XiaXAP5vJSllFKorDq6d6CKa3NTdSEWE7Xzd+XUhKFpeYHi8UikUgKCwuHwuENxcaNG2vr6lm2O36xsj0pofvv71ER0q63tlASRbs8ybj9XXtDMkzbFa5prS2XTP850i5PpMbHUNKE9gRlx8MPUhKFtanBsDKLfTPHj391M4v/0cd7WHEMj2a7NDdCqC082kpd1d93NyVR6ObOcfa4KIlCp55ns9xWCxUZx1lxSqo0lR43nztto8ZY3333vcGxN8gho06nW7Nmzb59+2hZEgAitRpamgAEwY+P4t82KWDV/X4z5iO6FRuNhjmLsdlC+Pv1Ks8g4BOktgaQmU5QgckS+MqzqKE2+I9/AQBapgQAAILUVkdHR2/cuHHDhg1DH0UMI3Q63f3333/06NGOtHmo5Rqp1eiSpmCjmRsY6WIniesu0PJJY9bc27Nzv2t5BGTdOfAPBgA2PwDop04LWLWy+087QeAHAH7pKSF79orF4pdffvlmE7/HZPI3d+smzQAAggwQfvWV8dfPmb844xfkF1R0xJC6hAgPwW2dbGbE58+Tr2w5/y77c8LUZ07WfUKALdhHiEXCo5/qps8Na2kAngAAaJmSr4oRFnxJy5TimrIeBEFBQQPlcDBqbTQan3nm2Z07d9BSBTDAnyhnappsg1z7mNeRG5sXmK1ac5czhUTZ3EJdJfeT1Gp0k5NFP5R1LF8KXV3MpWtkU037OCkRFEhqNW+99TbDWF944YWB8nmDYDQa58+fX1payn7JpFZjmDcv9PA+XbIaMCYbq+mYJP9l6eajxWz+1yfevePMTmcK6ycvfV77Hdiblp8wQVhU1P2nLYHP/5bTcu5lisXizZs33zzi95hMcDC/a9MWceUZ3cSZgDDwCEejWxEIeAJklV2nfaFWFxIOAOxrNG75vfnwv9FlHdnkCJuMzdtiTLtTLBYNiMnBqPWWLbmbN79Iy5TBb/2Gr5zYsfwhAAAGkU2VdMxkVk4jn6fSX/OFWrUoSsBYgWGAx3fII08KLdiDOzo6H3iK1GpkMtmOHTuWLVs2UFZvBO6+++6DBw/S8kSwWoAvAMAABKnV6GImYsQAZoDg+2HGx3atDR4HPIIYOyZk97sdP3tCXFFKhJKOWBhBkI3VYrH4k08+uRnE//a771JC/Qx3rAQA9vMDcxetSAEA/rR45vvaHv/ASVTjQMk2iSIsCPD1bmJsIKnVGNRpwpJTnHEUfV90tLQ8KyvTd4IDVus33nhj06ZNbJWBz63ufns32XzJ9M+/dm18W3jyiGFuVqd/0NT2AQtWTsqCLN3AYLKlhpYnkg1VtCQBEAY/PgCQWk10dPSpU6fi4m7UvJSPcBbf1q6IoWMmgr2b8kNWWZfOOxF3XBKOJxDiiYJFF845dBoA/ICwEGJt9c0gfrw85lJDPS1TCo8fMCy8h9RqdCm3ic+Vgb1vietoHQr9uuBw4LOGPxEQBh4QYWPF575nX0iMVNbY3OQjqYGpdWlp6cyZM2l5Ei9yLF8WYym9YPMLF8xDtVcA4fguajAC2VEbEg4YWJsNAH6MJaSlnpYpAYOwsUqdlvb1118HBAQMpYqhoLS0tPP69dmH/mU6eAwIAJMpcMPjgb/+HQDQUiUQEN/ZNhT6tSHhYDGTVxocnw220vJJfEUUtfPD1atX/bjiY4ztn1wiAAaCR9ZeoOOmsH8dok6zOBCXOpWqZb9qcd1Fgs/DXZ2sE09qNdz0e78YgFp3dXUtnDe/ePubnfc+wZkTcf1FXewkWw7MxPvW83pBfTCJeHyePCL4jVf9ZqUDz4+tSHjis8lLV9z3wP2vvfbaEKsYHLq6upZnZhV9ddzZmjoPJEx8v0n6y0OspVYUDgwAnyDrqzvuyrCev8QNQ9NS59xx56IfS3yEkE6eOPZ//9y16Xfi777jxhXO4yiFBaPuNpVKlZaWJhKJVCqVUCj0QtNgMJSXl+v1+lOnTpWXl7OJYwOEFwICSK2GlsSRl87TyttJrUY3bTqmOsWN1dz6C+8YgFpv2rTpjTfesDVqzESyobL30BADQQAM1WIBgCZExAc//7tSzUdPE0GB4vIyWqoAgkdqNREREUVFRcnJyUOsYhBwFh8AADO0fCJYuwn/sdi+LsAfWaUD90BcoA0dZ8EE2J0c/fRpqO06+zMsLOzEiRMjL740Klp7ucW5uUmtxlJa3LnyMehtQS/m/yM9PX0QVRQXF2/evJlV7hC/oLLAsWB/A1y9vrsivqp1fX19TEyMrfexg4vruWT2qNkCgWDmzJkPPfSQVCrlEisrKzdt2uShumAS8fhkYyUQfFaq0KN7OzKzRXUVWVlZR48e9YXnYUR9ff3qB7O/UCeb9h5nx4jgj8lLNb0+bAAA4PnhWHpInhgA1IaOB4xIrUYnV2IMgBEIMBEc+M69K898e2bkxefcD8xYbZ0zNgHh5g5hC2BB5WfH1dNlAFBSU
{"created":"20210224201642486","text":"! ''{{qo-op!!pseudo}}''\n\n```\nBienvenue sur votre journal de bord pubié dans le réseau des ambassades/passerelles 'Astroport One' zones 'publiques' niveau 0 et 1\nL'équivalent en plus sécurisé, plus écologique de cet Internet 2.0\n\n```\n\n\u003C\u003C\u003C\n!! Dans cet Univers, par défaut nous utilisons la [[monnaie libre|https://monnaie-libre.fr]]\n\u003C\u003C\u003C\n\nCe journal est publié automatiquement par l'Ambassade Astroport.ONE à laquelle votre 'Astronaute' est relié. ''Il s'agit d'un canal public''. La partie de vous-même que vous êtes prêt à dévoiler à tous, votre Youtuibe, votre Facebook, votre Twitter, votre Internet entre amis, sans les algorithmes entre vous et eux.\n\n[img[NoGafamNetwork.png]]\n\nModifier à loisir le contenu de ce journal... C'est le votre.\n\n''Sa mise à jour est publiée au travers du canal 'qo-op' de la station Astroport ONE la plus proche (sous la responsabilité de son Capitaine)''\n\n* Adaptez le [[Dessin de Moa]], ajoutez du son [[Horse Galloping (Loop)]]\n* Insérez des vidéos externes (depuis Youtube par exemple) [[Astroport 20:12]] \n* Gravez vos NFT dans IPFS [[Astroport_Final.mp4]] ! \n* Gardez le contrôle sur leur partage avec un simple mot de passe [[Film]] (1234)\n* Placez un contrat plus élaboré (challenge, distribution, vente, ...) votre imagination est la limite.\n\nDans ce nouveau réseau des réseaux, vos données et l'étendue de leur partage ne vous sera jamais inconnu... A part sur ce journal qui se partage avec toutes les clefs de niveau \"1\" de confiance et sur le niveau \"0\" confiance de cet Internet 2.0 (encore en service?)\n\nIci, vous êtes le maître de votre avatar numérique. Vous gardez le contrôle sur chacune de vos publications!\nAjoutez des mots de passe, activez de nouveau contrats astrXbian lors de l'ajout de vos médias, faites du commerce de vos biens numériques. Tout vous est permis.\n\n!!! Bonne découverte du modèle https://astroport.com\n\nQuestions par email à support@qo-op.com","title":"qo-op","type":"","modified":"20220505173523702","tags":"qo-op astroport","pseudo":"_PSEUDO_","birthdate":"_BIRTHDATE_","g1pub":"_G1PUB_","ipfsnodeid":"_IPFSNODEID_","qo-op":"_QOOP_","player":"_PLAYER_","moans":"_MOANS_","qoopns":"_QOOPNS_","moakey":"_MOAKEY_"}
]</script><div id="storeArea" style="display:none;"></div>
<!--~~ Library modules ~~-->
<div id="libraryModules" style="display:none;">
<script data-tiddler-bag="default" data-tiddler-library="yes" data-tiddler-revision="0" data-tiddler-title="$:/library/sjcl.js" data-tiddler-type="application/javascript" type="text/javascript">"use strict";var sjcl={cipher:{},hash:{},keyexchange:{},mode:{},misc:{},codec:{},exception:{corrupt:function(a){this.toString=function(){return"CORRUPT: "+this.message};this.message=a},invalid:function(a){this.toString=function(){return"INVALID: "+this.message};this.message=a},bug:function(a){this.toString=function(){return"BUG: "+this.message};this.message=a},notReady:function(a){this.toString=function(){return"NOT READY: "+this.message};this.message=a}}};
sjcl.cipher.aes=function(a){this.s[0][0][0]||this.O();var b,c,d,e,f=this.s[0][4],g=this.s[1];b=a.length;var h=1;if(4!==b&&6!==b&&8!==b)throw new sjcl.exception.invalid("invalid aes key size");this.b=[d=a.slice(0),e=[]];for(a=b;a<4*b+28;a++){c=d[a-1];if(0===a%b||8===b&&4===a%b)c=f[c>>>24]<<24^f[c>>16&255]<<16^f[c>>8&255]<<8^f[c&255],0===a%b&&(c=c<<8^c>>>24^h<<24,h=h<<1^283*(h>>7));d[a]=d[a-b]^c}for(b=0;a;b++,a--)c=d[b&3?a:a-4],e[b]=4>=a||4>b?c:g[0][f[c>>>24]]^g[1][f[c>>16&255]]^g[2][f[c>>8&255]]^g[3][f[c&
255]]};
sjcl.cipher.aes.prototype={encrypt:function(a){return t(this,a,0)},decrypt:function(a){return t(this,a,1)},s:[[[],[],[],[],[]],[[],[],[],[],[]]],O:function(){var a=this.s[0],b=this.s[1],c=a[4],d=b[4],e,f,g,h=[],k=[],l,n,m,p;for(e=0;0x100>e;e++)k[(h[e]=e<<1^283*(e>>7))^e]=e;for(f=g=0;!c[f];f^=l||1,g=k[g]||1)for(m=g^g<<1^g<<2^g<<3^g<<4,m=m>>8^m&255^99,c[f]=m,d[m]=f,n=h[e=h[l=h[f]]],p=0x1010101*n^0x10001*e^0x101*l^0x1010100*f,n=0x101*h[m]^0x1010100*m,e=0;4>e;e++)a[e][f]=n=n<<24^n>>>8,b[e][m]=p=p<<24^p>>>8;for(e=
0;5>e;e++)a[e]=a[e].slice(0),b[e]=b[e].slice(0)}};
function t(a,b,c){if(4!==b.length)throw new sjcl.exception.invalid("invalid aes block size");var d=a.b[c],e=b[0]^d[0],f=b[c?3:1]^d[1],g=b[2]^d[2];b=b[c?1:3]^d[3];var h,k,l,n=d.length/4-2,m,p=4,r=[0,0,0,0];h=a.s[c];a=h[0];var q=h[1],v=h[2],w=h[3],x=h[4];for(m=0;m<n;m++)h=a[e>>>24]^q[f>>16&255]^v[g>>8&255]^w[b&255]^d[p],k=a[f>>>24]^q[g>>16&255]^v[b>>8&255]^w[e&255]^d[p+1],l=a[g>>>24]^q[b>>16&255]^v[e>>8&255]^w[f&255]^d[p+2],b=a[b>>>24]^q[e>>16&255]^v[f>>8&255]^w[g&255]^d[p+3],p+=4,e=h,f=k,g=l;for(m=
0;4>m;m++)r[c?3&-m:m]=x[e>>>24]<<24^x[f>>16&255]<<16^x[g>>8&255]<<8^x[b&255]^d[p++],h=e,e=f,f=g,g=b,b=h;return r}
sjcl.bitArray={bitSlice:function(a,b,c){a=sjcl.bitArray.$(a.slice(b/32),32-(b&31)).slice(1);return void 0===c?a:sjcl.bitArray.clamp(a,c-b)},extract:function(a,b,c){var d=Math.floor(-b-c&31);return((b+c-1^b)&-32?a[b/32|0]<<32-d^a[b/32+1|0]>>>d:a[b/32|0]>>>d)&(1<<c)-1},concat:function(a,b){if(0===a.length||0===b.length)return a.concat(b);var c=a[a.length-1],d=sjcl.bitArray.getPartial(c);return 32===d?a.concat(b):sjcl.bitArray.$(b,d,c|0,a.slice(0,a.length-1))},bitLength:function(a){var b=a.length;return 0===
b?0:32*(b-1)+sjcl.bitArray.getPartial(a[b-1])},clamp:function(a,b){if(32*a.length<b)return a;a=a.slice(0,Math.ceil(b/32));var c=a.length;b=b&31;0<c&&b&&(a[c-1]=sjcl.bitArray.partial(b,a[c-1]&2147483648>>b-1,1));return a},partial:function(a,b,c){return 32===a?b:(c?b|0:b<<32-a)+0x10000000000*a},getPartial:function(a){return Math.round(a/0x10000000000)||32},equal:function(a,b){if(sjcl.bitArray.bitLength(a)!==sjcl.bitArray.bitLength(b))return!1;var c=0,d;for(d=0;d<a.length;d++)c|=a[d]^b[d];return 0===
c},$:function(a,b,c,d){var e;e=0;for(void 0===d&&(d=[]);32<=b;b-=32)d.push(c),c=0;if(0===b)return d.concat(a);for(e=0;e<a.length;e++)d.push(c|a[e]>>>b),c=a[e]<<32-b;e=a.length?a[a.length-1]:0;a=sjcl.bitArray.getPartial(e);d.push(sjcl.bitArray.partial(b+a&31,32<b+a?c:d.pop(),1));return d},i:function(a,b){return[a[0]^b[0],a[1]^b[1],a[2]^b[2],a[3]^b[3]]},byteswapM:function(a){var b,c;for(b=0;b<a.length;++b)c=a[b],a[b]=c>>>24|c>>>8&0xff00|(c&0xff00)<<8|c<<24;return a}};
sjcl.codec.utf8String={fromBits:function(a){var b="",c=sjcl.bitArray.bitLength(a),d,e;for(d=0;d<c/8;d++)0===(d&3)&&(e=a[d/4]),b+=String.fromCharCode(e>>>8>>>8>>>8),e<<=8;return decodeURIComponent(escape(b))},toBits:function(a){a=unescape(encodeURIComponent(a));var b=[],c,d=0;for(c=0;c<a.length;c++)d=d<<8|a.charCodeAt(c),3===(c&3)&&(b.push(d),d=0);c&3&&b.push(sjcl.bitArray.partial(8*(c&3),d));return b}};
sjcl.codec.hex={fromBits:function(a){var b="",c;for(c=0;c<a.length;c++)b+=((a[c]|0)+0xf00000000000).toString(16).substr(4);return b.substr(0,sjcl.bitArray.bitLength(a)/4)},toBits:function(a){var b,c=[],d;a=a.replace(/\s|0x/g,"");d=a.length;a=a+"00000000";for(b=0;b<a.length;b+=8)c.push(parseInt(a.substr(b,8),16)^0);return sjcl.bitArray.clamp(c,4*d)}};
sjcl.codec.base32={B:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",X:"0123456789ABCDEFGHIJKLMNOPQRSTUV",BITS:32,BASE:5,REMAINING:27,fromBits:function(a,b,c){var d=sjcl.codec.base32.BASE,e=sjcl.codec.base32.REMAINING,f="",g=0,h=sjcl.codec.base32.B,k=0,l=sjcl.bitArray.bitLength(a);c&&(h=sjcl.codec.base32.X);for(c=0;f.length*d<l;)f+=h.charAt((k^a[c]>>>g)>>>e),g<d?(k=a[c]<<d-g,g+=e,c++):(k<<=d,g-=d);for(;f.length&7&&!b;)f+="=";return f},toBits:function(a,b){a=a.replace(/\s|=/g,"").toUpperCase();var c=sjcl.codec.base32.BITS,
d=sjcl.codec.base32.BASE,e=sjcl.codec.base32.REMAINING,f=[],g,h=0,k=sjcl.codec.base32.B,l=0,n,m="base32";b&&(k=sjcl.codec.base32.X,m="base32hex");for(g=0;g<a.length;g++){n=k.indexOf(a.charAt(g));if(0>n){if(!b)try{return sjcl.codec.base32hex.toBits(a)}catch(p){}throw new sjcl.exception.invalid("this isn't "+m+"!");}h>e?(h-=e,f.push(l^n>>>h),l=n<<c-h):(h+=d,l^=n<<c-h)}h&56&&f.push(sjcl.bitArray.partial(h&56,l,1));return f}};
sjcl.codec.base32hex={fromBits:function(a,b){return sjcl.codec.base32.fromBits(a,b,1)},toBits:function(a){return sjcl.codec.base32.toBits(a,1)}};
sjcl.codec.base64={B:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",fromBits:function(a,b,c){var d="",e=0,f=sjcl.codec.base64.B,g=0,h=sjcl.bitArray.bitLength(a);c&&(f=f.substr(0,62)+"-_");for(c=0;6*d.length<h;)d+=f.charAt((g^a[c]>>>e)>>>26),6>e?(g=a[c]<<6-e,e+=26,c++):(g<<=6,e-=6);for(;d.length&3&&!b;)d+="=";return d},toBits:function(a,b){a=a.replace(/\s|=/g,"");var c=[],d,e=0,f=sjcl.codec.base64.B,g=0,h;b&&(f=f.substr(0,62)+"-_");for(d=0;d<a.length;d++){h=f.indexOf(a.charAt(d));
if(0>h)throw new sjcl.exception.invalid("this isn't base64!");26<e?(e-=26,c.push(g^h>>>e),g=h<<32-e):(e+=6,g^=h<<32-e)}e&56&&c.push(sjcl.bitArray.partial(e&56,g,1));return c}};sjcl.codec.base64url={fromBits:function(a){return sjcl.codec.base64.fromBits(a,1,1)},toBits:function(a){return sjcl.codec.base64.toBits(a,1)}};sjcl.hash.sha256=function(a){this.b[0]||this.O();a?(this.F=a.F.slice(0),this.A=a.A.slice(0),this.l=a.l):this.reset()};sjcl.hash.sha256.hash=function(a){return(new sjcl.hash.sha256).update(a).finalize()};
sjcl.hash.sha256.prototype={blockSize:512,reset:function(){this.F=this.Y.slice(0);this.A=[];this.l=0;return this},update:function(a){"string"===typeof a&&(a=sjcl.codec.utf8String.toBits(a));var b,c=this.A=sjcl.bitArray.concat(this.A,a);b=this.l;a=this.l=b+sjcl.bitArray.bitLength(a);if(0x1fffffffffffff<a)throw new sjcl.exception.invalid("Cannot hash more than 2^53 - 1 bits");if("undefined"!==typeof Uint32Array){var d=new Uint32Array(c),e=0;for(b=512+b-(512+b&0x1ff);b<=a;b+=512)u(this,d.subarray(16*e,
16*(e+1))),e+=1;c.splice(0,16*e)}else for(b=512+b-(512+b&0x1ff);b<=a;b+=512)u(this,c.splice(0,16));return this},finalize:function(){var a,b=this.A,c=this.F,b=sjcl.bitArray.concat(b,[sjcl.bitArray.partial(1,1)]);for(a=b.length+2;a&15;a++)b.push(0);b.push(Math.floor(this.l/0x100000000));for(b.push(this.l|0);b.length;)u(this,b.splice(0,16));this.reset();return c},Y:[],b:[],O:function(){function a(a){return 0x100000000*(a-Math.floor(a))|0}for(var b=0,c=2,d,e;64>b;c++){e=!0;for(d=2;d*d<=c;d++)if(0===c%d){e=
!1;break}e&&(8>b&&(this.Y[b]=a(Math.pow(c,.5))),this.b[b]=a(Math.pow(c,1/3)),b++)}}};
function u(a,b){var c,d,e,f=a.F,g=a.b,h=f[0],k=f[1],l=f[2],n=f[3],m=f[4],p=f[5],r=f[6],q=f[7];for(c=0;64>c;c++)16>c?d=b[c]:(d=b[c+1&15],e=b[c+14&15],d=b[c&15]=(d>>>7^d>>>18^d>>>3^d<<25^d<<14)+(e>>>17^e>>>19^e>>>10^e<<15^e<<13)+b[c&15]+b[c+9&15]|0),d=d+q+(m>>>6^m>>>11^m>>>25^m<<26^m<<21^m<<7)+(r^m&(p^r))+g[c],q=r,r=p,p=m,m=n+d|0,n=l,l=k,k=h,h=d+(k&l^n&(k^l))+(k>>>2^k>>>13^k>>>22^k<<30^k<<19^k<<10)|0;f[0]=f[0]+h|0;f[1]=f[1]+k|0;f[2]=f[2]+l|0;f[3]=f[3]+n|0;f[4]=f[4]+m|0;f[5]=f[5]+p|0;f[6]=f[6]+r|0;f[7]=
f[7]+q|0}
sjcl.mode.ccm={name:"ccm",G:[],listenProgress:function(a){sjcl.mode.ccm.G.push(a)},unListenProgress:function(a){a=sjcl.mode.ccm.G.indexOf(a);-1<a&&sjcl.mode.ccm.G.splice(a,1)},fa:function(a){var b=sjcl.mode.ccm.G.slice(),c;for(c=0;c<b.length;c+=1)b[c](a)},encrypt:function(a,b,c,d,e){var f,g=b.slice(0),h=sjcl.bitArray,k=h.bitLength(c)/8,l=h.bitLength(g)/8;e=e||64;d=d||[];if(7>k)throw new sjcl.exception.invalid("ccm: iv must be at least 7 bytes");for(f=2;4>f&&l>>>8*f;f++);f<15-k&&(f=15-k);c=h.clamp(c,
8*(15-f));b=sjcl.mode.ccm.V(a,b,c,d,e,f);g=sjcl.mode.ccm.C(a,g,c,b,e,f);return h.concat(g.data,g.tag)},decrypt:function(a,b,c,d,e){e=e||64;d=d||[];var f=sjcl.bitArray,g=f.bitLength(c)/8,h=f.bitLength(b),k=f.clamp(b,h-e),l=f.bitSlice(b,h-e),h=(h-e)/8;if(7>g)throw new sjcl.exception.invalid("ccm: iv must be at least 7 bytes");for(b=2;4>b&&h>>>8*b;b++);b<15-g&&(b=15-g);c=f.clamp(c,8*(15-b));k=sjcl.mode.ccm.C(a,k,c,l,e,b);a=sjcl.mode.ccm.V(a,k.data,c,d,e,b);if(!f.equal(k.tag,a))throw new sjcl.exception.corrupt("ccm: tag doesn't match");
return k.data},na:function(a,b,c,d,e,f){var g=[],h=sjcl.bitArray,k=h.i;d=[h.partial(8,(b.length?64:0)|d-2<<2|f-1)];d=h.concat(d,c);d[3]|=e;d=a.encrypt(d);if(b.length)for(c=h.bitLength(b)/8,65279>=c?g=[h.partial(16,c)]:0xffffffff>=c&&(g=h.concat([h.partial(16,65534)],[c])),g=h.concat(g,b),b=0;b<g.length;b+=4)d=a.encrypt(k(d,g.slice(b,b+4).concat([0,0,0])));return d},V:function(a,b,c,d,e,f){var g=sjcl.bitArray,h=g.i;e/=8;if(e%2||4>e||16<e)throw new sjcl.exception.invalid("ccm: invalid tag length");
if(0xffffffff<d.length||0xffffffff<b.length)throw new sjcl.exception.bug("ccm: can't deal with 4GiB or more data");c=sjcl.mode.ccm.na(a,d,c,e,g.bitLength(b)/8,f);for(d=0;d<b.length;d+=4)c=a.encrypt(h(c,b.slice(d,d+4).concat([0,0,0])));return g.clamp(c,8*e)},C:function(a,b,c,d,e,f){var g,h=sjcl.bitArray;g=h.i;var k=b.length,l=h.bitLength(b),n=k/50,m=n;c=h.concat([h.partial(8,f-1)],c).concat([0,0,0]).slice(0,4);d=h.bitSlice(g(d,a.encrypt(c)),0,e);if(!k)return{tag:d,data:[]};for(g=0;g<k;g+=4)g>n&&(sjcl.mode.ccm.fa(g/
k),n+=m),c[3]++,e=a.encrypt(c),b[g]^=e[0],b[g+1]^=e[1],b[g+2]^=e[2],b[g+3]^=e[3];return{tag:d,data:h.clamp(b,l)}}};
sjcl.mode.ocb2={name:"ocb2",encrypt:function(a,b,c,d,e,f){if(128!==sjcl.bitArray.bitLength(c))throw new sjcl.exception.invalid("ocb iv must be 128 bits");var g,h=sjcl.mode.ocb2.S,k=sjcl.bitArray,l=k.i,n=[0,0,0,0];c=h(a.encrypt(c));var m,p=[];d=d||[];e=e||64;for(g=0;g+4<b.length;g+=4)m=b.slice(g,g+4),n=l(n,m),p=p.concat(l(c,a.encrypt(l(c,m)))),c=h(c);m=b.slice(g);b=k.bitLength(m);g=a.encrypt(l(c,[0,0,0,b]));m=k.clamp(l(m.concat([0,0,0]),g),b);n=l(n,l(m.concat([0,0,0]),g));n=a.encrypt(l(n,l(c,h(c))));
d.length&&(n=l(n,f?d:sjcl.mode.ocb2.pmac(a,d)));return p.concat(k.concat(m,k.clamp(n,e)))},decrypt:function(a,b,c,d,e,f){if(128!==sjcl.bitArray.bitLength(c))throw new sjcl.exception.invalid("ocb iv must be 128 bits");e=e||64;var g=sjcl.mode.ocb2.S,h=sjcl.bitArray,k=h.i,l=[0,0,0,0],n=g(a.encrypt(c)),m,p,r=sjcl.bitArray.bitLength(b)-e,q=[];d=d||[];for(c=0;c+4<r/32;c+=4)m=k(n,a.decrypt(k(n,b.slice(c,c+4)))),l=k(l,m),q=q.concat(m),n=g(n);p=r-32*c;m=a.encrypt(k(n,[0,0,0,p]));m=k(m,h.clamp(b.slice(c),p).concat([0,
0,0]));l=k(l,m);l=a.encrypt(k(l,k(n,g(n))));d.length&&(l=k(l,f?d:sjcl.mode.ocb2.pmac(a,d)));if(!h.equal(h.clamp(l,e),h.bitSlice(b,r)))throw new sjcl.exception.corrupt("ocb: tag doesn't match");return q.concat(h.clamp(m,p))},pmac:function(a,b){var c,d=sjcl.mode.ocb2.S,e=sjcl.bitArray,f=e.i,g=[0,0,0,0],h=a.encrypt([0,0,0,0]),h=f(h,d(d(h)));for(c=0;c+4<b.length;c+=4)h=d(h),g=f(g,a.encrypt(f(h,b.slice(c,c+4))));c=b.slice(c);128>e.bitLength(c)&&(h=f(h,d(h)),c=e.concat(c,[-2147483648,0,0,0]));g=f(g,c);
return a.encrypt(f(d(f(h,d(h))),g))},S:function(a){return[a[0]<<1^a[1]>>>31,a[1]<<1^a[2]>>>31,a[2]<<1^a[3]>>>31,a[3]<<1^135*(a[0]>>>31)]}};
sjcl.mode.gcm={name:"gcm",encrypt:function(a,b,c,d,e){var f=b.slice(0);b=sjcl.bitArray;d=d||[];a=sjcl.mode.gcm.C(!0,a,f,d,c,e||128);return b.concat(a.data,a.tag)},decrypt:function(a,b,c,d,e){var f=b.slice(0),g=sjcl.bitArray,h=g.bitLength(f);e=e||128;d=d||[];e<=h?(b=g.bitSlice(f,h-e),f=g.bitSlice(f,0,h-e)):(b=f,f=[]);a=sjcl.mode.gcm.C(!1,a,f,d,c,e);if(!g.equal(a.tag,b))throw new sjcl.exception.corrupt("gcm: tag doesn't match");return a.data},ka:function(a,b){var c,d,e,f,g,h=sjcl.bitArray.i;e=[0,0,
0,0];f=b.slice(0);for(c=0;128>c;c++){(d=0!==(a[Math.floor(c/32)]&1<<31-c%32))&&(e=h(e,f));g=0!==(f[3]&1);for(d=3;0<d;d--)f[d]=f[d]>>>1|(f[d-1]&1)<<31;f[0]>>>=1;g&&(f[0]^=-0x1f000000)}return e},j:function(a,b,c){var d,e=c.length;b=b.slice(0);for(d=0;d<e;d+=4)b[0]^=0xffffffff&c[d],b[1]^=0xffffffff&c[d+1],b[2]^=0xffffffff&c[d+2],b[3]^=0xffffffff&c[d+3],b=sjcl.mode.gcm.ka(b,a);return b},C:function(a,b,c,d,e,f){var g,h,k,l,n,m,p,r,q=sjcl.bitArray;m=c.length;p=q.bitLength(c);r=q.bitLength(d);h=q.bitLength(e);
g=b.encrypt([0,0,0,0]);96===h?(e=e.slice(0),e=q.concat(e,[1])):(e=sjcl.mode.gcm.j(g,[0,0,0,0],e),e=sjcl.mode.gcm.j(g,e,[0,0,Math.floor(h/0x100000000),h&0xffffffff]));h=sjcl.mode.gcm.j(g,[0,0,0,0],d);n=e.slice(0);d=h.slice(0);a||(d=sjcl.mode.gcm.j(g,h,c));for(l=0;l<m;l+=4)n[3]++,k=b.encrypt(n),c[l]^=k[0],c[l+1]^=k[1],c[l+2]^=k[2],c[l+3]^=k[3];c=q.clamp(c,p);a&&(d=sjcl.mode.gcm.j(g,h,c));a=[Math.floor(r/0x100000000),r&0xffffffff,Math.floor(p/0x100000000),p&0xffffffff];d=sjcl.mode.gcm.j(g,d,a);k=b.encrypt(e);
d[0]^=k[0];d[1]^=k[1];d[2]^=k[2];d[3]^=k[3];return{tag:q.bitSlice(d,0,f),data:c}}};sjcl.misc.hmac=function(a,b){this.W=b=b||sjcl.hash.sha256;var c=[[],[]],d,e=b.prototype.blockSize/32;this.w=[new b,new b];a.length>e&&(a=b.hash(a));for(d=0;d<e;d++)c[0][d]=a[d]^909522486,c[1][d]=a[d]^1549556828;this.w[0].update(c[0]);this.w[1].update(c[1]);this.R=new b(this.w[0])};
sjcl.misc.hmac.prototype.encrypt=sjcl.misc.hmac.prototype.mac=function(a){if(this.aa)throw new sjcl.exception.invalid("encrypt on already updated hmac called!");this.update(a);return this.digest(a)};sjcl.misc.hmac.prototype.reset=function(){this.R=new this.W(this.w[0]);this.aa=!1};sjcl.misc.hmac.prototype.update=function(a){this.aa=!0;this.R.update(a)};sjcl.misc.hmac.prototype.digest=function(){var a=this.R.finalize(),a=(new this.W(this.w[1])).update(a).finalize();this.reset();return a};
sjcl.misc.pbkdf2=function(a,b,c,d,e){c=c||1E4;if(0>d||0>c)throw new sjcl.exception.invalid("invalid params to pbkdf2");"string"===typeof a&&(a=sjcl.codec.utf8String.toBits(a));"string"===typeof b&&(b=sjcl.codec.utf8String.toBits(b));e=e||sjcl.misc.hmac;a=new e(a);var f,g,h,k,l=[],n=sjcl.bitArray;for(k=1;32*l.length<(d||1);k++){e=f=a.encrypt(n.concat(b,[k]));for(g=1;g<c;g++)for(f=a.encrypt(f),h=0;h<f.length;h++)e[h]^=f[h];l=l.concat(e)}d&&(l=n.clamp(l,d));return l};
sjcl.prng=function(a){this.c=[new sjcl.hash.sha256];this.m=[0];this.P=0;this.H={};this.N=0;this.U={};this.Z=this.f=this.o=this.ha=0;this.b=[0,0,0,0,0,0,0,0];this.h=[0,0,0,0];this.L=void 0;this.M=a;this.D=!1;this.K={progress:{},seeded:{}};this.u=this.ga=0;this.I=1;this.J=2;this.ca=0x10000;this.T=[0,48,64,96,128,192,0x100,384,512,768,1024];this.da=3E4;this.ba=80};
sjcl.prng.prototype={randomWords:function(a,b){var c=[],d;d=this.isReady(b);var e;if(d===this.u)throw new sjcl.exception.notReady("generator isn't seeded");if(d&this.J){d=!(d&this.I);e=[];var f=0,g;this.Z=e[0]=(new Date).valueOf()+this.da;for(g=0;16>g;g++)e.push(0x100000000*Math.random()|0);for(g=0;g<this.c.length&&(e=e.concat(this.c[g].finalize()),f+=this.m[g],this.m[g]=0,d||!(this.P&1<<g));g++);this.P>=1<<this.c.length&&(this.c.push(new sjcl.hash.sha256),this.m.push(0));this.f-=f;f>this.o&&(this.o=
f);this.P++;this.b=sjcl.hash.sha256.hash(this.b.concat(e));this.L=new sjcl.cipher.aes(this.b);for(d=0;4>d&&(this.h[d]=this.h[d]+1|0,!this.h[d]);d++);}for(d=0;d<a;d+=4)0===(d+1)%this.ca&&y(this),e=z(this),c.push(e[0],e[1],e[2],e[3]);y(this);return c.slice(0,a)},setDefaultParanoia:function(a,b){if(0===a&&"Setting paranoia=0 will ruin your security; use it only for testing"!==b)throw new sjcl.exception.invalid("Setting paranoia=0 will ruin your security; use it only for testing");this.M=a},addEntropy:function(a,
b,c){c=c||"user";var d,e,f=(new Date).valueOf(),g=this.H[c],h=this.isReady(),k=0;d=this.U[c];void 0===d&&(d=this.U[c]=this.ha++);void 0===g&&(g=this.H[c]=0);this.H[c]=(this.H[c]+1)%this.c.length;switch(typeof a){case "number":void 0===b&&(b=1);this.c[g].update([d,this.N++,1,b,f,1,a|0]);break;case "object":c=Object.prototype.toString.call(a);if("[object Uint32Array]"===c){e=[];for(c=0;c<a.length;c++)e.push(a[c]);a=e}else for("[object Array]"!==c&&(k=1),c=0;c<a.length&&!k;c++)"number"!==typeof a[c]&&
(k=1);if(!k){if(void 0===b)for(c=b=0;c<a.length;c++)for(e=a[c];0<e;)b++,e=e>>>1;this.c[g].update([d,this.N++,2,b,f,a.length].concat(a))}break;case "string":void 0===b&&(b=a.length);this.c[g].update([d,this.N++,3,b,f,a.length]);this.c[g].update(a);break;default:k=1}if(k)throw new sjcl.exception.bug("random: addEntropy only supports number, array of numbers or string");this.m[g]+=b;this.f+=b;h===this.u&&(this.isReady()!==this.u&&A("seeded",Math.max(this.o,this.f)),A("progress",this.getProgress()))},
isReady:function(a){a=this.T[void 0!==a?a:this.M];return this.o&&this.o>=a?this.m[0]>this.ba&&(new Date).valueOf()>this.Z?this.J|this.I:this.I:this.f>=a?this.J|this.u:this.u},getProgress:function(a){a=this.T[a?a:this.M];return this.o>=a?1:this.f>a?1:this.f/a},startCollectors:function(){if(!this.D){this.a={loadTimeCollector:B(this,this.ma),mouseCollector:B(this,this.oa),keyboardCollector:B(this,this.la),accelerometerCollector:B(this,this.ea),touchCollector:B(this,this.qa)};if(window.addEventListener)window.addEventListener("load",
this.a.loadTimeCollector,!1),window.addEventListener("mousemove",this.a.mouseCollector,!1),window.addEventListener("keypress",this.a.keyboardCollector,!1),window.addEventListener("devicemotion",this.a.accelerometerCollector,!1),window.addEventListener("touchmove",this.a.touchCollector,!1);else if(document.attachEvent)document.attachEvent("onload",this.a.loadTimeCollector),document.attachEvent("onmousemove",this.a.mouseCollector),document.attachEvent("keypress",this.a.keyboardCollector);else throw new sjcl.exception.bug("can't attach event");
this.D=!0}},stopCollectors:function(){this.D&&(window.removeEventListener?(window.removeEventListener("load",this.a.loadTimeCollector,!1),window.removeEventListener("mousemove",this.a.mouseCollector,!1),window.removeEventListener("keypress",this.a.keyboardCollector,!1),window.removeEventListener("devicemotion",this.a.accelerometerCollector,!1),window.removeEventListener("touchmove",this.a.touchCollector,!1)):document.detachEvent&&(document.detachEvent("onload",this.a.loadTimeCollector),document.detachEvent("onmousemove",
this.a.mouseCollector),document.detachEvent("keypress",this.a.keyboardCollector)),this.D=!1)},addEventListener:function(a,b){this.K[a][this.ga++]=b},removeEventListener:function(a,b){var c,d,e=this.K[a],f=[];for(d in e)e.hasOwnProperty(d)&&e[d]===b&&f.push(d);for(c=0;c<f.length;c++)d=f[c],delete e[d]},la:function(){C(this,1)},oa:function(a){var b,c;try{b=a.x||a.clientX||a.offsetX||0,c=a.y||a.clientY||a.offsetY||0}catch(d){c=b=0}0!=b&&0!=c&&this.addEntropy([b,c],2,"mouse");C(this,0)},qa:function(a){a=
a.touches[0]||a.changedTouches[0];this.addEntropy([a.pageX||a.clientX,a.pageY||a.clientY],1,"touch");C(this,0)},ma:function(){C(this,2)},ea:function(a){a=a.accelerationIncludingGravity.x||a.accelerationIncludingGravity.y||a.accelerationIncludingGravity.z;if(window.orientation){var b=window.orientation;"number"===typeof b&&this.addEntropy(b,1,"accelerometer")}a&&this.addEntropy(a,2,"accelerometer");C(this,0)}};
function A(a,b){var c,d=sjcl.random.K[a],e=[];for(c in d)d.hasOwnProperty(c)&&e.push(d[c]);for(c=0;c<e.length;c++)e[c](b)}function C(a,b){"undefined"!==typeof window&&window.performance&&"function"===typeof window.performance.now?a.addEntropy(window.performance.now(),b,"loadtime"):a.addEntropy((new Date).valueOf(),b,"loadtime")}function y(a){a.b=z(a).concat(z(a));a.L=new sjcl.cipher.aes(a.b)}function z(a){for(var b=0;4>b&&(a.h[b]=a.h[b]+1|0,!a.h[b]);b++);return a.L.encrypt(a.h)}
function B(a,b){return function(){b.apply(a,arguments)}}sjcl.random=new sjcl.prng(6);
a:try{var D,E,F,G;if(G="undefined"!==typeof module&&module.exports){var H;try{H=require("crypto")}catch(a){H=null}G=E=H}if(G&&E.randomBytes)D=E.randomBytes(128),D=new Uint32Array((new Uint8Array(D)).buffer),sjcl.random.addEntropy(D,1024,"crypto['randomBytes']");else if("undefined"!==typeof window&&"undefined"!==typeof Uint32Array){F=new Uint32Array(32);if(window.crypto&&window.crypto.getRandomValues)window.crypto.getRandomValues(F);else if(window.msCrypto&&window.msCrypto.getRandomValues)window.msCrypto.getRandomValues(F);
else break a;sjcl.random.addEntropy(F,1024,"crypto['getRandomValues']")}}catch(a){"undefined"!==typeof window&&window.console&&(console.log("There was an error collecting entropy from the browser:"),console.log(a))}
sjcl.json={defaults:{v:1,iter:1E4,ks:128,ts:64,mode:"ccm",adata:"",cipher:"aes"},ja:function(a,b,c,d){c=c||{};d=d||{};var e=sjcl.json,f=e.g({iv:sjcl.random.randomWords(4,0)},e.defaults),g;e.g(f,c);c=f.adata;"string"===typeof f.salt&&(f.salt=sjcl.codec.base64.toBits(f.salt));"string"===typeof f.iv&&(f.iv=sjcl.codec.base64.toBits(f.iv));if(!sjcl.mode[f.mode]||!sjcl.cipher[f.cipher]||"string"===typeof a&&100>=f.iter||64!==f.ts&&96!==f.ts&&128!==f.ts||128!==f.ks&&192!==f.ks&&0x100!==f.ks||2>f.iv.length||
4<f.iv.length)throw new sjcl.exception.invalid("json encrypt: invalid parameters");"string"===typeof a?(g=sjcl.misc.cachedPbkdf2(a,f),a=g.key.slice(0,f.ks/32),f.salt=g.salt):sjcl.ecc&&a instanceof sjcl.ecc.elGamal.publicKey&&(g=a.kem(),f.kemtag=g.tag,a=g.key.slice(0,f.ks/32));"string"===typeof b&&(b=sjcl.codec.utf8String.toBits(b));"string"===typeof c&&(f.adata=c=sjcl.codec.utf8String.toBits(c));g=new sjcl.cipher[f.cipher](a);e.g(d,f);d.key=a;f.ct="ccm"===f.mode&&sjcl.arrayBuffer&&sjcl.arrayBuffer.ccm&&
b instanceof ArrayBuffer?sjcl.arrayBuffer.ccm.encrypt(g,b,f.iv,c,f.ts):sjcl.mode[f.mode].encrypt(g,b,f.iv,c,f.ts);return f},encrypt:function(a,b,c,d){var e=sjcl.json,f=e.ja.apply(e,arguments);return e.encode(f)},ia:function(a,b,c,d){c=c||{};d=d||{};var e=sjcl.json;b=e.g(e.g(e.g({},e.defaults),b),c,!0);var f,g;f=b.adata;"string"===typeof b.salt&&(b.salt=sjcl.codec.base64.toBits(b.salt));"string"===typeof b.iv&&(b.iv=sjcl.codec.base64.toBits(b.iv));if(!sjcl.mode[b.mode]||!sjcl.cipher[b.cipher]||"string"===
typeof a&&100>=b.iter||64!==b.ts&&96!==b.ts&&128!==b.ts||128!==b.ks&&192!==b.ks&&0x100!==b.ks||!b.iv||2>b.iv.length||4<b.iv.length)throw new sjcl.exception.invalid("json decrypt: invalid parameters");"string"===typeof a?(g=sjcl.misc.cachedPbkdf2(a,b),a=g.key.slice(0,b.ks/32),b.salt=g.salt):sjcl.ecc&&a instanceof sjcl.ecc.elGamal.secretKey&&(a=a.unkem(sjcl.codec.base64.toBits(b.kemtag)).slice(0,b.ks/32));"string"===typeof f&&(f=sjcl.codec.utf8String.toBits(f));g=new sjcl.cipher[b.cipher](a);f="ccm"===
b.mode&&sjcl.arrayBuffer&&sjcl.arrayBuffer.ccm&&b.ct instanceof ArrayBuffer?sjcl.arrayBuffer.ccm.decrypt(g,b.ct,b.iv,b.tag,f,b.ts):sjcl.mode[b.mode].decrypt(g,b.ct,b.iv,f,b.ts);e.g(d,b);d.key=a;return 1===c.raw?f:sjcl.codec.utf8String.fromBits(f)},decrypt:function(a,b,c,d){var e=sjcl.json;return e.ia(a,e.decode(b),c,d)},encode:function(a){var b,c="{",d="";for(b in a)if(a.hasOwnProperty(b)){if(!b.match(/^[a-z0-9]+$/i))throw new sjcl.exception.invalid("json encode: invalid property name");c+=d+'"'+
b+'":';d=",";switch(typeof a[b]){case "number":case "boolean":c+=a[b];break;case "string":c+='"'+escape(a[b])+'"';break;case "object":c+='"'+sjcl.codec.base64.fromBits(a[b],0)+'"';break;default:throw new sjcl.exception.bug("json encode: unsupported type");}}return c+"}"},decode:function(a){a=a.replace(/\s/g,"");if(!a.match(/^\{.*\}$/))throw new sjcl.exception.invalid("json decode: this isn't json!");a=a.replace(/^\{|\}$/g,"").split(/,/);var b={},c,d;for(c=0;c<a.length;c++){if(!(d=a[c].match(/^\s*(?:(["']?)([a-z][a-z0-9]*)\1)\s*:\s*(?:(-?\d+)|"([a-z0-9+\/%*_.@=\-]*)"|(true|false))$/i)))throw new sjcl.exception.invalid("json decode: this isn't json!");
null!=d[3]?b[d[2]]=parseInt(d[3],10):null!=d[4]?b[d[2]]=d[2].match(/^(ct|adata|salt|iv)$/)?sjcl.codec.base64.toBits(d[4]):unescape(d[4]):null!=d[5]&&(b[d[2]]="true"===d[5])}return b},g:function(a,b,c){void 0===a&&(a={});if(void 0===b)return a;for(var d in b)if(b.hasOwnProperty(d)){if(c&&void 0!==a[d]&&a[d]!==b[d])throw new sjcl.exception.invalid("required parameter overridden");a[d]=b[d]}return a},sa:function(a,b){var c={},d;for(d in a)a.hasOwnProperty(d)&&a[d]!==b[d]&&(c[d]=a[d]);return c},ra:function(a,
b){var c={},d;for(d=0;d<b.length;d++)void 0!==a[b[d]]&&(c[b[d]]=a[b[d]]);return c}};sjcl.encrypt=sjcl.json.encrypt;sjcl.decrypt=sjcl.json.decrypt;sjcl.misc.pa={};sjcl.misc.cachedPbkdf2=function(a,b){var c=sjcl.misc.pa,d;b=b||{};d=b.iter||1E3;c=c[a]=c[a]||{};d=c[d]=c[d]||{firstSalt:b.salt&&b.salt.length?b.salt.slice(0):sjcl.random.randomWords(2,0)};c=void 0===b.salt?d.firstSalt:b.salt;d[c]=d[c]||sjcl.misc.pbkdf2(a,c,b.iter);return{key:d[c].slice(0),salt:c.slice(0)}};
"undefined"!==typeof module&&module.exports&&(module.exports=sjcl);"function"===typeof define&&define([],function(){return sjcl});
</script>
</div>
<!--~~ Boot kernel prologue ~~-->
<div id="bootKernelPrefix" style="display:none;">
<script data-tiddler-bag="default" data-tiddler-revision="0" data-tiddler-title="$:/boot/bootprefix.js" data-tiddler-type="application/javascript" type="text/javascript">/*\
title: $:/boot/bootprefix.js
type: application/javascript
This file sets up the globals that need to be available when JavaScript modules are executed in the browser. The overall sequence is:
# BootPrefix.js
# <module definitions>
# Boot.js
See Boot.js for further details of the boot process.
\*/
var _bootprefix = (function($tw) {
"use strict";
$tw = $tw || Object.create(null);
$tw.boot = $tw.boot || Object.create(null);
// Detect platforms
if(!("browser" in $tw)) {
$tw.browser = typeof(window) !== "undefined" ? {} : null;
}
if(!("node" in $tw)) {
$tw.node = typeof(process) === "object" ? {} : null;
}
if(!("nodeWebKit" in $tw)) {
$tw.nodeWebKit = $tw.node && global.window && global.window.nwDispatcher ? {} : null;
}
// Set default boot tasks
$tw.boot.tasks = {
trapErrors: !!($tw.browser && !$tw.node),
readBrowserTiddlers: !!($tw.browser && !$tw.node)
};
/*
Information about each module is kept in an object with these members:
moduleType: type of module
definition: object, function or string defining the module; see below
exports: exports of the module, filled in after execution
The `definition` can be of several types:
* An object can be used to directly specify the exports of the module
* A function with the arguments `module,require,exports` that returns `exports`
* A string function body with the same arguments
Each moduleInfo object is stored in two hashmaps: $tw.modules.titles and $tw.modules.types. The first is indexed by title and the second is indexed by type and then title
*/
$tw.modules = {
titles: {}, // hashmap by module name of moduleInfo
types: {} // hashmap by module type and then name of moduleInfo
};
/*
Define a JavaScript tiddler module for later execution
moduleName: name of module being defined
moduleType: type of module
definition: module definition; see discussion above
*/
$tw.modules.define = function(moduleName,moduleType,definition) {
// Create the moduleInfo
var moduleInfo = {
moduleType: moduleType,
definition: definition,
exports: undefined
};
// If the definition is already an object we can use it as the exports
if(typeof moduleInfo.definition === "object") {
moduleInfo.exports = definition;
}
// Store the module in the titles hashmap
if(Object.prototype.hasOwnProperty.call($tw.modules.titles,moduleName)) {
console.log("Warning: Redefined module - " + moduleName);
}
$tw.modules.titles[moduleName] = moduleInfo;
// Store the module in the types hashmap
if(!Object.prototype.hasOwnProperty.call($tw.modules.types,moduleType)) {
$tw.modules.types[moduleType] = {};
}
if(Object.prototype.hasOwnProperty.call($tw.modules.types[moduleType],moduleName)) {
console.log("Warning: Redefined module - " + moduleName);
}
$tw.modules.types[moduleType][moduleName] = moduleInfo;
};
/*
External JavaScript can populate this array before calling boot.js in order to preload tiddlers
*/
$tw.preloadTiddlers = $tw.preloadTiddlers || [];
/*
Convenience function for pushing a tiddler onto the preloading array
*/
$tw.preloadTiddler = function(fields) {
$tw.preloadTiddlers.push(fields);
};
/*
Convenience function for pushing an array of tiddlers onto the preloading array
*/
$tw.preloadTiddlerArray = function(fieldsArray) {
$tw.preloadTiddlers.push.apply($tw.preloadTiddlers,fieldsArray);
};
return $tw;
});
if(typeof(exports) === "undefined") {
// Set up $tw global for the browser
window.$tw = _bootprefix(window.$tw);
} else {
// Export functionality as a module
exports.bootprefix = _bootprefix;
}
//# sourceURL=$:/boot/bootprefix.js
</script>
</div>
<!--~~ Boot kernel ~~-->
<div id="bootKernel" style="display:none;">
<script data-tiddler-bag="default" data-tiddler-revision="0" data-tiddler-title="$:/boot/boot.js" data-tiddler-type="application/javascript" type="text/javascript">/*\
title: $:/boot/boot.js
type: application/javascript
The main boot kernel for TiddlyWiki. This single file creates a barebones TW environment that is just sufficient to bootstrap the modules containing the main logic of the application.
On the server this file is executed directly to boot TiddlyWiki. In the browser, this file is packed into a single HTML file.
\*/
var _boot = (function($tw) {
/*jslint node: true, browser: true */
/*global modules: false, $tw: false */
"use strict";
// Include bootprefix if we're not given module data
if(!$tw) {
$tw = require("./bootprefix.js").bootprefix();
}
$tw.utils = $tw.utils || Object.create(null);
/////////////////////////// Standard node.js libraries
var fs, path, vm;
if($tw.node) {
fs = require("fs");
path = require("path");
vm = require("vm");
}
/////////////////////////// Utility functions
$tw.boot.log = function(str) {
$tw.boot.logMessages = $tw.boot.logMessages || [];
$tw.boot.logMessages.push(str);
}
/*
Check if an object has a property
*/
$tw.utils.hop = function(object,property) {
return object ? Object.prototype.hasOwnProperty.call(object,property) : false;
};
/*
Determine if a value is an array
*/
$tw.utils.isArray = function(value) {
return Object.prototype.toString.call(value) == "[object Array]";
};
/*
Check if an array is equal by value and by reference.
*/
$tw.utils.isArrayEqual = function(array1,array2) {
if(array1 === array2) {
return true;
}
array1 = array1 || [];
array2 = array2 || [];
if(array1.length !== array2.length) {
return false;
}
return array1.every(function(value,index) {
return value === array2[index];
});
};
/*
Add an entry to a sorted array if it doesn't already exist, while maintaining the sort order
*/
$tw.utils.insertSortedArray = function(array,value) {
var low = 0, high = array.length - 1, mid, cmp;
while(low <= high) {
mid = (low + high) >> 1;
cmp = value.localeCompare(array[mid]);
if(cmp > 0) {
low = mid + 1;
} else if(cmp < 0) {
high = mid - 1;
} else {
return array;
}
}
array.splice(low,0,value);
return array;
};
/*
Push entries onto an array, removing them first if they already exist in the array
array: array to modify (assumed to be free of duplicates)
value: a single value to push or an array of values to push
*/
$tw.utils.pushTop = function(array,value) {
var t,p;
if($tw.utils.isArray(value)) {
// Remove any array entries that are duplicated in the new values
if(value.length !== 0) {
if(array.length !== 0) {
if(value.length < array.length) {
for(t=0; t<value.length; t++) {
p = array.indexOf(value[t]);
if(p !== -1) {
array.splice(p,1);
}
}
} else {
for(t=array.length-1; t>=0; t--) {
p = value.indexOf(array[t]);
if(p !== -1) {
array.splice(t,1);
}
}
}
}
// Push the values on top of the main array
array.push.apply(array,value);
}
} else {
p = array.indexOf(value);
if(p !== -1) {
array.splice(p,1);
}
array.push(value);
}
return array;
};
/*
Determine if a value is a date
*/
$tw.utils.isDate = function(value) {
return Object.prototype.toString.call(value) === "[object Date]";
};
/*
Iterate through all the own properties of an object or array. Callback is invoked with (element,title,object)
*/
$tw.utils.each = function(object,callback) {
var next,f,length;
if(object) {
if(Object.prototype.toString.call(object) == "[object Array]") {
for (f=0, length=object.length; f<length; f++) {
next = callback(object[f],f,object);
if(next === false) {
break;
}
}
} else {
var keys = Object.keys(object);
for (f=0, length=keys.length; f<length; f++) {
var key = keys[f];
next = callback(object[key],key,object);
if(next === false) {
break;
}
}
}
}
};
/*
Helper for making DOM elements
tag: tag name
options: see below
Options include:
namespace: defaults to http://www.w3.org/1999/xhtml
attributes: hashmap of attribute values
style: hashmap of styles
text: text to add as a child node
children: array of further child nodes
innerHTML: optional HTML for element
class: class name(s)
document: defaults to current document
eventListeners: array of event listeners (this option won't work until $tw.utils.addEventListeners() has been loaded)
*/
$tw.utils.domMaker = function(tag,options) {
var doc = options.document || document;
var element = doc.createElementNS(options.namespace || "http://www.w3.org/1999/xhtml",tag);
if(options["class"]) {
element.className = options["class"];
}
if(options.text) {
element.appendChild(doc.createTextNode(options.text));
}
$tw.utils.each(options.children,function(child) {
element.appendChild(child);
});
if(options.innerHTML) {
element.innerHTML = options.innerHTML;
}
$tw.utils.each(options.attributes,function(attribute,name) {
element.setAttribute(name,attribute);
});
$tw.utils.each(options.style,function(value,name) {
element.style[name] = value;
});
if(options.eventListeners) {
$tw.utils.addEventListeners(element,options.eventListeners);
}
return element;
};
/*
Display an error and exit
*/
$tw.utils.error = function(err) {
// Prepare the error message
var errHeading = ( $tw.language == undefined ? "Internal JavaScript Error" : $tw.language.getString("InternalJavaScriptError/Title") ),
promptMsg = ( $tw.language == undefined ? "Well, this is embarrassing. It is recommended that you restart TiddlyWiki by refreshing your browser" : $tw.language.getString("InternalJavaScriptError/Hint") );
// Log the error to the console
console.error($tw.node ? "\x1b[1;31m" + err + "\x1b[0m" : err);
if($tw.browser && !$tw.node) {
// Display an error message to the user
var dm = $tw.utils.domMaker,
heading = dm("h1",{text: errHeading}),
prompt = dm("div",{text: promptMsg, "class": "tc-error-prompt"}),
message = dm("div",{text: err, "class":"tc-error-message"}),
button = dm("div",{children: [dm("button",{text: ( $tw.language == undefined ? "close" : $tw.language.getString("Buttons/Close/Caption") )})], "class": "tc-error-prompt"}),
form = dm("form",{children: [heading,prompt,message,button], "class": "tc-error-form"});
document.body.insertBefore(form,document.body.firstChild);
form.addEventListener("submit",function(event) {
document.body.removeChild(form);
event.preventDefault();
return false;
},true);
return null;
} else if(!$tw.browser) {
// Exit if we're under node.js
process.exit(1);
}
};
/*
Use our custom error handler if we're in the browser
*/
if($tw.boot.tasks.trapErrors) {
window.onerror = function(errorMsg,url,lineNumber) {
$tw.utils.error(errorMsg);
return false;
};
}
/*
Extend an object with the properties from a list of source objects
*/
$tw.utils.extend = function(object /*, sourceObjectList */) {
$tw.utils.each(Array.prototype.slice.call(arguments,1),function(source) {
if(source) {
for (var p in source) {
object[p] = source[p];
}
}
});
return object;
};
/*
Fill in any null or undefined properties of an object with the properties from a list of source objects. Each property that is an object is called recursively
*/
$tw.utils.deepDefaults = function(object /*, sourceObjectList */) {
$tw.utils.each(Array.prototype.slice.call(arguments,1),function(source) {
if(source) {
for (var p in source) {
if(object[p] === null || object[p] === undefined) {
object[p] = source[p];
}
if(typeof object[p] === "object" && typeof source[p] === "object") {
$tw.utils.deepDefaults(object[p],source[p]);
}
}
}
});
return object;
};
/*
Convert a URIComponent encoded string to a string safely
*/
$tw.utils.decodeURIComponentSafe = function(s) {
var v = s;
try {
v = decodeURIComponent(s);
} catch(e) {}
return v;
};
/*
Convert a URI encoded string to a string safely
*/
$tw.utils.decodeURISafe = function(s) {
var v = s;
try {
v = decodeURI(s);
} catch(e) {}
return v;
};
/*
Convert "&amp;" to &, "&nbsp;" to nbsp, "&lt;" to <, "&gt;" to > and "&quot;" to "
*/
$tw.utils.htmlDecode = function(s) {
return s.toString().replace(/&lt;/mg,"<").replace(/&nbsp;/mg,"\xA0").replace(/&gt;/mg,">").replace(/&quot;/mg,"\"").replace(/&amp;/mg,"&");
};
/*
Get the browser location.hash. We don't use location.hash because of the way that Firefox auto-urldecodes it (see http://stackoverflow.com/questions/1703552/encoding-of-window-location-hash)
*/
$tw.utils.getLocationHash = function() {
var href = window.location.href;
var idx = href.indexOf('#');
if(idx === -1) {
return "#";
} else if(idx < href.length-1 && href[idx+1] === '#') {
// Special case: ignore location hash if it itself starts with a #
return "#";
} else {
return href.substring(idx);
}
};
/*
Pad a string to a given length with "0"s. Length defaults to 2
*/
$tw.utils.pad = function(value,length) {
length = length || 2;
var s = value.toString();
if(s.length < length) {
s = "000000000000000000000000000".substr(0,length - s.length) + s;
}
return s;
};
// Convert a date into UTC YYYYMMDDHHMMSSmmm format
$tw.utils.stringifyDate = function(value) {
return value.getUTCFullYear() +
$tw.utils.pad(value.getUTCMonth() + 1) +
$tw.utils.pad(value.getUTCDate()) +
$tw.utils.pad(value.getUTCHours()) +
$tw.utils.pad(value.getUTCMinutes()) +
$tw.utils.pad(value.getUTCSeconds()) +
$tw.utils.pad(value.getUTCMilliseconds(),3);
};
// Parse a date from a UTC YYYYMMDDHHMMSSmmm format string
$tw.utils.parseDate = function(value) {
if(typeof value === "string") {
var negative = 1;
if(value.charAt(0) === "-") {
negative = -1;
value = value.substr(1);
}
var year = parseInt(value.substr(0,4),10) * negative,
d = new Date(Date.UTC(year,
parseInt(value.substr(4,2),10)-1,
parseInt(value.substr(6,2),10),
parseInt(value.substr(8,2)||"00",10),
parseInt(value.substr(10,2)||"00",10),
parseInt(value.substr(12,2)||"00",10),
parseInt(value.substr(14,3)||"000",10)));
d.setUTCFullYear(year); // See https://stackoverflow.com/a/5870822
return d;
} else if($tw.utils.isDate(value)) {
return value;
} else {
return null;
}
};
// Stringify an array of tiddler titles into a list string
$tw.utils.stringifyList = function(value) {
if($tw.utils.isArray(value)) {
var result = new Array(value.length);
for(var t=0, l=value.length; t<l; t++) {
var entry = value[t] || "";
if(entry.indexOf(" ") !== -1) {
result[t] = "[[" + entry + "]]";
} else {
result[t] = entry;
}
}
return result.join(" ");
} else {
return value || "";
}
};
// Parse a string array from a bracketted list. For example "OneTiddler [[Another Tiddler]] LastOne"
$tw.utils.parseStringArray = function(value, allowDuplicate) {
if(typeof value === "string") {
var memberRegExp = /(?:^|[^\S\xA0])(?:\[\[(.*?)\]\])(?=[^\S\xA0]|$)|([\S\xA0]+)/mg,
results = [], names = {},
match;
do {
match = memberRegExp.exec(value);
if(match) {
var item = match[1] || match[2];
if(item !== undefined && (!$tw.utils.hop(names,item) || allowDuplicate)) {
results.push(item);
names[item] = true;
}
}
} while(match);
return results;
} else if($tw.utils.isArray(value)) {
return value;
} else {
return null;
}
};
// Parse a block of name:value fields. The `fields` object is used as the basis for the return value
$tw.utils.parseFields = function(text,fields) {
fields = fields || Object.create(null);
text.split(/\r?\n/mg).forEach(function(line) {
if(line.charAt(0) !== "#") {
var p = line.indexOf(":");
if(p !== -1) {
var field = line.substr(0, p).trim(),
value = line.substr(p+1).trim();
if(field) {
fields[field] = value;
}
}
}
});
return fields;
};
// Safely parse a string as JSON
$tw.utils.parseJSONSafe = function(text,defaultJSON) {
try {
return JSON.parse(text);
} catch(e) {
if(typeof defaultJSON === "function") {
return defaultJSON(e);
} else {
return defaultJSON || {};
}
}
};
/*
Resolves a source filepath delimited with `/` relative to a specified absolute root filepath.
In relative paths, the special folder name `..` refers to immediate parent directory, and the
name `.` refers to the current directory
*/
$tw.utils.resolvePath = function(sourcepath,rootpath) {
// If the source path starts with ./ or ../ then it is relative to the root
if(sourcepath.substr(0,2) === "./" || sourcepath.substr(0,3) === "../" ) {
var src = sourcepath.split("/"),
root = rootpath.split("/");
// Remove the filename part of the root
root.splice(root.length-1,1);
// Process the source path bit by bit onto the end of the root path
while(src.length > 0) {
var c = src.shift();
if(c === "..") { // Slice off the last root entry for a double dot
if(root.length > 0) {
root.splice(root.length-1,1);
}
} else if(c !== ".") { // Ignore dots
root.push(c); // Copy other elements across
}
}
return root.join("/");
} else {
// If it isn't relative, just return the path
if(rootpath) {
var root = rootpath.split("/");
// Remove the filename part of the root
root.splice(root.length - 1, 1);
return root.join("/") + "/" + sourcepath;
} else {
return sourcepath;
}
}
};
/*
Parse a semantic version string into its constituent parts -- see https://semver.org
*/
$tw.utils.parseVersion = function(version) {
var match = /^v?((\d+)\.(\d+)\.(\d+))(?:-([\dA-Za-z\-]+(?:\.[\dA-Za-z\-]+)*))?(?:\+([\dA-Za-z\-]+(?:\.[\dA-Za-z\-]+)*))?$/.exec(version);
if(match) {
return {
version: match[1],
major: parseInt(match[2],10),
minor: parseInt(match[3],10),
patch: parseInt(match[4],10),
prerelease: match[5],
build: match[6]
};
} else {
return null;
}
};
/*
Returns +1 if the version string A is greater than the version string B, 0 if they are the same, and +1 if B is greater than A.
Missing or malformed version strings are parsed as 0.0.0
*/
$tw.utils.compareVersions = function(versionStringA,versionStringB) {
var defaultVersion = {
major: 0,
minor: 0,
patch: 0
},
versionA = $tw.utils.parseVersion(versionStringA) || defaultVersion,
versionB = $tw.utils.parseVersion(versionStringB) || defaultVersion,
diff = [
versionA.major - versionB.major,
versionA.minor - versionB.minor,
versionA.patch - versionB.patch
];
if((diff[0] > 0) || (diff[0] === 0 && diff[1] > 0) || (diff[0] === 0 & diff[1] === 0 & diff[2] > 0)) {
return +1;
} else if((diff[0] < 0) || (diff[0] === 0 && diff[1] < 0) || (diff[0] === 0 & diff[1] === 0 & diff[2] < 0)) {
return -1;
} else {
return 0;
}
};
/*
Returns true if the version string A is greater than the version string B. Returns true if the versions are the same
*/
$tw.utils.checkVersions = function(versionStringA,versionStringB) {
return $tw.utils.compareVersions(versionStringA,versionStringB) !== -1;
};
/*
Register file type information
options: {flags: flags,deserializerType: deserializerType}
flags:"image" for image types
deserializerType: defaults to type if not specified
*/
$tw.utils.registerFileType = function(type,encoding,extension,options) {
options = options || {};
if($tw.utils.isArray(extension)) {
$tw.utils.each(extension,function(extension) {
$tw.config.fileExtensionInfo[extension] = {type: type};
});
extension = extension[0];
} else {
$tw.config.fileExtensionInfo[extension] = {type: type};
}
$tw.config.contentTypeInfo[type] = {encoding: encoding, extension: extension, flags: options.flags || [], deserializerType: options.deserializerType || type};
};
/*
Given an extension, always access the $tw.config.fileExtensionInfo
using a lowercase extension only.
*/
$tw.utils.getFileExtensionInfo = function(ext) {
return ext ? $tw.config.fileExtensionInfo[ext.toLowerCase()] : null;
}
/*
Given an extension, get the correct encoding for that file.
defaults to utf8
*/
$tw.utils.getTypeEncoding = function(ext) {
var extensionInfo = $tw.utils.getFileExtensionInfo(ext),
type = extensionInfo ? extensionInfo.type : null,
typeInfo = type ? $tw.config.contentTypeInfo[type] : null;
return typeInfo ? typeInfo.encoding : "utf8";
};
/*
Run code globally with specified context variables in scope
*/
$tw.utils.evalGlobal = function(code,context,filename) {
var contextCopy = $tw.utils.extend(Object.create(null),context);
// Get the context variables as a pair of arrays of names and values
var contextNames = [], contextValues = [];
$tw.utils.each(contextCopy,function(value,name) {
contextNames.push(name);
contextValues.push(value);
});
// Add the code prologue and epilogue
code = "(function(" + contextNames.join(",") + ") {(function(){\n" + code + "\n;})();\nreturn exports;\n})\n";
// Compile the code into a function
var fn;
if($tw.browser) {
fn = window["eval"](code + "\n\n//# sourceURL=" + filename);
} else {
fn = vm.runInThisContext(code,filename);
}
// Call the function and return the exports
return fn.apply(null,contextValues);
};
/*
Run code in a sandbox with only the specified context variables in scope
*/
$tw.utils.evalSandboxed = $tw.browser ? $tw.utils.evalGlobal : function(code,context,filename) {
var sandbox = $tw.utils.extend(Object.create(null),context);
vm.runInNewContext(code,sandbox,filename);
return sandbox.exports;
};
/*
Creates a PasswordPrompt object
*/
$tw.utils.PasswordPrompt = function() {
// Store of pending password prompts
this.passwordPrompts = [];
// Create the wrapper
this.promptWrapper = $tw.utils.domMaker("div",{"class":"tc-password-wrapper"});
document.body.appendChild(this.promptWrapper);
// Hide the empty wrapper
this.setWrapperDisplay();
};
/*
Hides or shows the wrapper depending on whether there are any outstanding prompts
*/
$tw.utils.PasswordPrompt.prototype.setWrapperDisplay = function() {
if(this.passwordPrompts.length) {
this.promptWrapper.style.display = "block";
} else {
this.promptWrapper.style.display = "none";
}
};
/*
Adds a new password prompt. Options are:
submitText: text to use for submit button (defaults to "Login")
serviceName: text of the human readable service name
noUserName: set true to disable username prompt
canCancel: set true to enable a cancel button (callback called with null)
repeatPassword: set true to prompt for the password twice
callback: function to be called on submission with parameter of object {username:,password:}. Callback must return `true` to remove the password prompt
*/
$tw.utils.PasswordPrompt.prototype.createPrompt = function(options) {
// Create and add the prompt to the DOM
var self = this,
submitText = options.submitText || "Login",
dm = $tw.utils.domMaker,
children = [dm("h1",{text: options.serviceName})];
if(!options.noUserName) {
children.push(dm("input",{
attributes: {type: "text", name: "username", placeholder: $tw.language.getString("Encryption/Username")}
}));
}
children.push(dm("input",{
attributes: {
type: "password",
name: "password",
placeholder: ( $tw.language == undefined ? "Password" : $tw.language.getString("Encryption/Password") )
}
}));
if(options.repeatPassword) {
children.push(dm("input",{
attributes: {
type: "password",
name: "password2",
placeholder: $tw.language.getString("Encryption/RepeatPassword")
}
}));
}
if(options.canCancel) {
children.push(dm("button",{
text: $tw.language.getString("Encryption/Cancel"),
attributes: {
type: "button"
},
eventListeners: [{
name: "click",
handlerFunction: function(event) {
self.removePrompt(promptInfo);
options.callback(null);
}
}]
}));
}
children.push(dm("button",{
attributes: {type: "submit"},
text: submitText
}));
var form = dm("form",{
attributes: {autocomplete: "off"},
children: children
});
this.promptWrapper.appendChild(form);
window.setTimeout(function() {
form.elements[0].focus();
},10);
// Add a submit event handler
var self = this;
form.addEventListener("submit",function(event) {
// Collect the form data
var data = {},t;
$tw.utils.each(form.elements,function(element) {
if(element.name && element.value) {
data[element.name] = element.value;
}
});
// Check that the passwords match
if(options.repeatPassword && data.password !== data.password2) {
alert($tw.language.getString("Encryption/PasswordNoMatch"));
} else {
// Call the callback
if(options.callback(data)) {
// Remove the prompt if the callback returned true
self.removePrompt(promptInfo);
} else {
// Clear the password if the callback returned false
$tw.utils.each(form.elements,function(element) {
if(element.name === "password" || element.name === "password2") {
element.value = "";
}
});
}
}
event.preventDefault();
return false;
},true);
// Add the prompt to the list
var promptInfo = {
serviceName: options.serviceName,
callback: options.callback,
form: form,
owner: this
};
this.passwordPrompts.push(promptInfo);
// Make sure the wrapper is displayed
this.setWrapperDisplay();
return promptInfo;
};
$tw.utils.PasswordPrompt.prototype.removePrompt = function(promptInfo) {
var i = this.passwordPrompts.indexOf(promptInfo);
if(i !== -1) {
this.passwordPrompts.splice(i,1);
promptInfo.form.parentNode.removeChild(promptInfo.form);
this.setWrapperDisplay();
}
}
/*
Crypto helper object for encrypted content. It maintains the password text in a closure, and provides methods to change
the password, and to encrypt/decrypt a block of text
*/
$tw.utils.Crypto = function() {
var sjcl = $tw.node ? (global.sjcl || require("./sjcl.js")) : window.sjcl,
currentPassword = null,
callSjcl = function(method,inputText,password) {
password = password || currentPassword;
var outputText;
try {
if(password) {
outputText = sjcl[method](password,inputText);
}
} catch(ex) {
console.log("Crypto error:" + ex);
outputText = null;
}
return outputText;
};
this.setPassword = function(newPassword) {
currentPassword = newPassword;
this.updateCryptoStateTiddler();
};
this.updateCryptoStateTiddler = function() {
if($tw.wiki) {
var state = currentPassword ? "yes" : "no",
tiddler = $tw.wiki.getTiddler("$:/isEncrypted");
if(!tiddler || tiddler.fields.text !== state) {
$tw.wiki.addTiddler(new $tw.Tiddler({title: "$:/isEncrypted", text: state}));
}
}
};
this.hasPassword = function() {
return !!currentPassword;
}
this.encrypt = function(text,password) {
return callSjcl("encrypt",text,password);
};
this.decrypt = function(text,password) {
return callSjcl("decrypt",text,password);
};
};
/////////////////////////// Module mechanism
/*
Execute the module named 'moduleName'. The name can optionally be relative to the module named 'moduleRoot'
*/
$tw.modules.execute = function(moduleName,moduleRoot) {
var name = moduleName;
if(moduleName.charAt(0) === ".") {
name = $tw.utils.resolvePath(moduleName,moduleRoot)
}
if(!$tw.modules.titles[name]) {
if($tw.modules.titles[name + ".js"]) {
name = name + ".js";
} else if($tw.modules.titles[name + "/index.js"]) {
name = name + "/index.js";
} else if($tw.modules.titles[moduleName]) {
name = moduleName;
} else if($tw.modules.titles[moduleName + ".js"]) {
name = moduleName + ".js";
} else if($tw.modules.titles[moduleName + "/index.js"]) {
name = moduleName + "/index.js";
}
}
var moduleInfo = $tw.modules.titles[name],
tiddler = $tw.wiki.getTiddler(name),
_exports = {},
sandbox = {
module: {exports: _exports},
//moduleInfo: moduleInfo,
exports: _exports,
console: console,
setInterval: setInterval,
clearInterval: clearInterval,
setTimeout: setTimeout,
clearTimeout: clearTimeout,
Buffer: $tw.browser ? undefined : Buffer,
$tw: $tw,
require: function(title) {
return $tw.modules.execute(title, name);
}
};
Object.defineProperty(sandbox.module, "id", {
value: name,
writable: false,
enumerable: true,
configurable: false
});
if(!$tw.browser) {
$tw.utils.extend(sandbox,{
process: process
});
} else {
/*
CommonJS optional require.main property:
In a browser we offer a fake main module which points back to the boot function
(Theoretically, this may allow TW to eventually load itself as a module in the browser)
*/
Object.defineProperty(sandbox.require, "main", {
value: (typeof(require) !== "undefined") ? require.main : {TiddlyWiki: _boot},
writable: false,
enumerable: true,
configurable: false
});
}
if(!moduleInfo) {
// We could not find the module on this path
// Try to defer to browserify etc, or node
var deferredModule;
if($tw.browser) {
if(window.require) {
try {
return window.require(moduleName);
} catch(e) {}
}
throw "Cannot find module named '" + moduleName + "' required by module '" + moduleRoot + "', resolved to " + name;
} else {
// If we don't have a module with that name, let node.js try to find it
return require(moduleName);
}
}
// Execute the module if we haven't already done so
if(!moduleInfo.exports) {
try {
// Check the type of the definition
if(typeof moduleInfo.definition === "function") { // Function
moduleInfo.exports = _exports;
moduleInfo.definition(moduleInfo,moduleInfo.exports,sandbox.require);
} else if(typeof moduleInfo.definition === "string") { // String
moduleInfo.exports = _exports;
$tw.utils.evalSandboxed(moduleInfo.definition,sandbox,tiddler.fields.title);
if(sandbox.module.exports) {
moduleInfo.exports = sandbox.module.exports; //more codemirror workaround
}
} else { // Object
moduleInfo.exports = moduleInfo.definition;
}
} catch(e) {
if (e instanceof SyntaxError) {
var line = e.lineNumber || e.line; // Firefox || Safari
if (typeof(line) != "undefined" && line !== null) {
$tw.utils.error("Syntax error in boot module " + name + ":" + line + ":\n" + e.stack);
} else if(!$tw.browser) {
// this is the only way to get node.js to display the line at which the syntax error appeared,
// and $tw.utils.error would exit anyway
// cf. https://bugs.chromium.org/p/v8/issues/detail?id=2589
throw e;
} else {
// Opera: line number is included in e.message
// Chrome/IE: there's currently no way to get the line number
$tw.utils.error("Syntax error in boot module " + name + ": " + e.message + "\n" + e.stack);
}
} else {
// line number should be included in e.stack for runtime errors
$tw.utils.error("Error executing boot module " + name + ": " + JSON.stringify(e) + "\n\n" + e.stack);
}
}
}
// Return the exports of the module
return moduleInfo.exports;
};
/*
Apply a callback to each module of a particular type
moduleType: type of modules to enumerate
callback: function called as callback(title,moduleExports) for each module
*/
$tw.modules.forEachModuleOfType = function(moduleType,callback) {
var modules = $tw.modules.types[moduleType];
$tw.utils.each(modules,function(element,title) {
callback(title,$tw.modules.execute(title));
});
};
/*
Get all the modules of a particular type in a hashmap by their `name` field
*/
$tw.modules.getModulesByTypeAsHashmap = function(moduleType,nameField) {
nameField = nameField || "name";
var results = Object.create(null);
$tw.modules.forEachModuleOfType(moduleType,function(title,module) {
results[module[nameField]] = module;
});
return results;
};
/*
Apply the exports of the modules of a particular type to a target object
*/
$tw.modules.applyMethods = function(moduleType,targetObject) {
if(!targetObject) {
targetObject = Object.create(null);
}
$tw.modules.forEachModuleOfType(moduleType,function(title,module) {
$tw.utils.each(module,function(element,title,object) {
targetObject[title] = module[title];
});
});
return targetObject;
};
/*
Return a class created from a modules. The module should export the properties to be added to those of the optional base class
*/
$tw.modules.createClassFromModule = function(moduleExports,baseClass) {
var newClass = function() {};
if(baseClass) {
newClass.prototype = new baseClass();
newClass.prototype.constructor = baseClass;
}
$tw.utils.extend(newClass.prototype,moduleExports);
return newClass;
};
/*
Return an array of classes created from the modules of a specified type. Each module should export the properties to be added to those of the optional base class
*/
$tw.modules.createClassesFromModules = function(moduleType,subType,baseClass) {
var classes = Object.create(null);
$tw.modules.forEachModuleOfType(moduleType,function(title,moduleExports) {
if(!subType || moduleExports.types[subType]) {
classes[moduleExports.name] = $tw.modules.createClassFromModule(moduleExports,baseClass);
}
});
return classes;
};
/////////////////////////// Barebones tiddler object
/*
Construct a tiddler object from a hashmap of tiddler fields. If multiple hasmaps are provided they are merged,
taking precedence to the right
*/
$tw.Tiddler = function(/* [fields,] fields */) {
this.fields = Object.create(null);
this.cache = Object.create(null);
for(var c=0; c<arguments.length; c++) {
var arg = arguments[c],
src = (arg instanceof $tw.Tiddler) ? arg.fields : arg;
for(var t in src) {
if(src[t] === undefined || src[t] === null) {
if(t in this.fields) {
delete this.fields[t]; // If we get a field that's undefined, delete any previous field value
}
} else {
// Parse the field with the associated field module (if any)
var fieldModule = $tw.Tiddler.fieldModules[t],
value;
if(fieldModule && fieldModule.parse) {
value = fieldModule.parse.call(this,src[t]);
} else {
value = src[t];
}
// Freeze the field to keep it immutable
if(value != null && typeof value === "object") {
Object.freeze(value);
}
this.fields[t] = value;
}
}
}
// Freeze the tiddler against modification
Object.freeze(this.fields);
Object.freeze(this);
};
$tw.Tiddler.prototype.hasField = function(field) {
return $tw.utils.hop(this.fields,field);
};
/*
Compare two tiddlers for equality
tiddler: the tiddler to compare
excludeFields: array of field names to exclude from the comparison
*/
$tw.Tiddler.prototype.isEqual = function(tiddler,excludeFields) {
if(!(tiddler instanceof $tw.Tiddler)) {
return false;
}
excludeFields = excludeFields || [];
var self = this,
differences = []; // Fields that have differences
// Add to the differences array
function addDifference(fieldName) {
// Check for this field being excluded
if(excludeFields.indexOf(fieldName) === -1) {
// Save the field as a difference
$tw.utils.pushTop(differences,fieldName);
}
}
// Returns true if the two values of this field are equal
function isFieldValueEqual(fieldName) {
var valueA = self.fields[fieldName],
valueB = tiddler.fields[fieldName];
// Check for identical string values
if(typeof(valueA) === "string" && typeof(valueB) === "string" && valueA === valueB) {
return true;
}
// Check for identical array values
if($tw.utils.isArray(valueA) && $tw.utils.isArray(valueB) && $tw.utils.isArrayEqual(valueA,valueB)) {
return true;
}
// Check for identical date values
if($tw.utils.isDate(valueA) && $tw.utils.isDate(valueB) && valueA.getTime() === valueB.getTime()) {
return true;
}
// Otherwise the fields must be different
return false;
}
// Compare our fields
for(var fieldName in this.fields) {
if(!isFieldValueEqual(fieldName)) {
addDifference(fieldName);
}
}
// There's a difference for every field in the other tiddler that we don't have
for(fieldName in tiddler.fields) {
if(!(fieldName in this.fields)) {
addDifference(fieldName);
}
}
// Return whether there were any differences
return differences.length === 0;
};
/*
Register and install the built in tiddler field modules
*/
$tw.modules.define("$:/boot/tiddlerfields/modified","tiddlerfield",{
name: "modified",
parse: $tw.utils.parseDate,
stringify: $tw.utils.stringifyDate
});
$tw.modules.define("$:/boot/tiddlerfields/created","tiddlerfield",{
name: "created",
parse: $tw.utils.parseDate,
stringify: $tw.utils.stringifyDate
});
$tw.modules.define("$:/boot/tiddlerfields/color","tiddlerfield",{
name: "color",
editTag: "input",
editType: "color"
});
$tw.modules.define("$:/boot/tiddlerfields/tags","tiddlerfield",{
name: "tags",
parse: $tw.utils.parseStringArray,
stringify: $tw.utils.stringifyList
});
$tw.modules.define("$:/boot/tiddlerfields/list","tiddlerfield",{
name: "list",
parse: $tw.utils.parseStringArray,
stringify: $tw.utils.stringifyList
});
/////////////////////////// Barebones wiki store
/*
Wiki constructor. State is stored in private members that only a small number of privileged accessor methods have direct access. Methods added via the prototype have to use these accessors and cannot access the state data directly.
options include:
enableIndexers - Array of indexer names to enable, or null to use all available indexers
*/
$tw.Wiki = function(options) {
options = options || {};
var self = this,
tiddlers = Object.create(null), // Hashmap of tiddlers
tiddlerTitles = null, // Array of tiddler titles
getTiddlerTitles = function() {
if(!tiddlerTitles) {
tiddlerTitles = Object.keys(tiddlers).sort(function(a,b) {return a.localeCompare(b);});
}
return tiddlerTitles;
},
pluginTiddlers = [], // Array of tiddlers containing registered plugins, ordered by priority
pluginInfo = Object.create(null), // Hashmap of parsed plugin content
shadowTiddlers = Object.create(null), // Hashmap by title of {source:, tiddler:}
shadowTiddlerTitles = null,
getShadowTiddlerTitles = function() {
if(!shadowTiddlerTitles) {
shadowTiddlerTitles = Object.keys(shadowTiddlers);
}
return shadowTiddlerTitles;
},
enableIndexers = options.enableIndexers || null,
indexers = [],
indexersByName = Object.create(null);
this.addIndexer = function(indexer,name) {
// Bail if this indexer is not enabled
if(enableIndexers && enableIndexers.indexOf(name) === -1) {
return;
}
indexers.push(indexer);
indexersByName[name] = indexer;
indexer.init();
};
this.getIndexer = function(name) {
return indexersByName[name] || null;
};
// Add a tiddler to the store
this.addTiddler = function(tiddler) {
if(!(tiddler instanceof $tw.Tiddler)) {
tiddler = new $tw.Tiddler(tiddler);
}
// Save the tiddler
if(tiddler) {
var title = tiddler.fields.title;
if(title) {
// Uncomment the following line for detailed logs of all tiddler writes
// console.log("Adding",title,tiddler)
// Record the old tiddler state
var updateDescriptor = {
old: {
tiddler: this.getTiddler(title),
shadow: this.isShadowTiddler(title),
exists: this.tiddlerExists(title)
}
}
// Save the new tiddler
tiddlers[title] = tiddler;
// Check we've got the title
tiddlerTitles = $tw.utils.insertSortedArray(tiddlerTitles || [],title);
// Record the new tiddler state
updateDescriptor["new"] = {
tiddler: tiddler,
shadow: this.isShadowTiddler(title),
exists: this.tiddlerExists(title)
}
// Update indexes
this.clearCache(title);
this.clearGlobalCache();
$tw.utils.each(indexers,function(indexer) {
indexer.update(updateDescriptor);
});
// Queue a change event
this.enqueueTiddlerEvent(title);
}
}
};
// Delete a tiddler
this.deleteTiddler = function(title) {
// Uncomment the following line for detailed logs of all tiddler deletions
// console.log("Deleting",title)
if($tw.utils.hop(tiddlers,title)) {
// Record the old tiddler state
var updateDescriptor = {
old: {
tiddler: this.getTiddler(title),
shadow: this.isShadowTiddler(title),
exists: this.tiddlerExists(title)
}
}
// Delete the tiddler
delete tiddlers[title];
// Delete it from the list of titles
if(tiddlerTitles) {
var index = tiddlerTitles.indexOf(title);
if(index !== -1) {
tiddlerTitles.splice(index,1);
}
}
// Record the new tiddler state
updateDescriptor["new"] = {
tiddler: this.getTiddler(title),
shadow: this.isShadowTiddler(title),
exists: this.tiddlerExists(title)
}
// Update indexes
this.clearCache(title);
this.clearGlobalCache();
$tw.utils.each(indexers,function(indexer) {
indexer.update(updateDescriptor);
});
// Queue a change event
this.enqueueTiddlerEvent(title,true);
}
};
// Get a tiddler from the store
this.getTiddler = function(title) {
if(title) {
var t = tiddlers[title];
if(t instanceof $tw.Tiddler) {
return t;
} else if(title !== undefined && shadowTiddlers[title]) {
return shadowTiddlers[title].tiddler;
}
return undefined;
}
};
// Get an array of all tiddler titles
this.allTitles = function() {
return getTiddlerTitles().slice(0);
};
// Iterate through all tiddler titles
this.each = function(callback) {
var titles = getTiddlerTitles(),
index,titlesLength,title;
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
callback(tiddlers[title],title);
}
};
// Get an array of all shadow tiddler titles
this.allShadowTitles = function() {
return getShadowTiddlerTitles().slice(0);
};
// Iterate through all shadow tiddler titles
this.eachShadow = function(callback) {
var titles = getShadowTiddlerTitles(),
index,titlesLength,title;
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
if(tiddlers[title]) {
callback(tiddlers[title],title);
} else {
var shadowInfo = shadowTiddlers[title];
callback(shadowInfo.tiddler,title);
}
}
};
// Iterate through all tiddlers and then the shadows
this.eachTiddlerPlusShadows = function(callback) {
var index,titlesLength,title,
titles = getTiddlerTitles();
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
callback(tiddlers[title],title);
}
titles = getShadowTiddlerTitles();
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
if(!tiddlers[title]) {
var shadowInfo = shadowTiddlers[title];
callback(shadowInfo.tiddler,title);
}
}
};
// Iterate through all the shadows and then the tiddlers
this.eachShadowPlusTiddlers = function(callback) {
var index,titlesLength,title,
titles = getShadowTiddlerTitles();
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
if(tiddlers[title]) {
callback(tiddlers[title],title);
} else {
var shadowInfo = shadowTiddlers[title];
callback(shadowInfo.tiddler,title);
}
}
titles = getTiddlerTitles();
for(index = 0, titlesLength = titles.length; index < titlesLength; index++) {
title = titles[index];
if(!shadowTiddlers[title]) {
callback(tiddlers[title],title);
}
}
};
// Test for the existence of a tiddler (excludes shadow tiddlers)
this.tiddlerExists = function(title) {
return !!$tw.utils.hop(tiddlers,title);
};
// Determines if a tiddler is a shadow tiddler, regardless of whether it has been overridden by a real tiddler
this.isShadowTiddler = function(title) {
return $tw.utils.hop(shadowTiddlers,title);
};
this.getShadowSource = function(title) {
if($tw.utils.hop(shadowTiddlers,title)) {
return shadowTiddlers[title].source;
}
return null;
};
// Get an array of all the currently recognised plugin types
this.getPluginTypes = function() {
var types = [];
$tw.utils.each(pluginTiddlers,function(pluginTiddler) {
var pluginType = pluginTiddler.fields["plugin-type"];
if(pluginType && types.indexOf(pluginType) === -1) {
types.push(pluginType);
}
});
return types;
};
// Read plugin info for all plugins, or just an array of titles. Returns the number of plugins updated or deleted
this.readPluginInfo = function(titles) {
var results = {
modifiedPlugins: [],
deletedPlugins: []
};
$tw.utils.each(titles || getTiddlerTitles(),function(title) {
var tiddler = tiddlers[title];
if(tiddler) {
if(tiddler.fields.type === "application/json" && tiddler.hasField("plugin-type") && tiddler.fields.text) {
pluginInfo[tiddler.fields.title] = $tw.utils.parseJSONSafe(tiddler.fields.text);
results.modifiedPlugins.push(tiddler.fields.title);
}
} else {
if(pluginInfo[title]) {
delete pluginInfo[title];
results.deletedPlugins.push(title);
}
}
});
return results;
};
// Get plugin info for a plugin
this.getPluginInfo = function(title) {
return pluginInfo[title];
};
// Register the plugin tiddlers of a particular type, or null/undefined for any type, optionally restricting registration to an array of tiddler titles. Return the array of titles affected
this.registerPluginTiddlers = function(pluginType,titles) {
var self = this,
registeredTitles = [],
checkTiddler = function(tiddler,title) {
if(tiddler && tiddler.fields.type === "application/json" && tiddler.fields["plugin-type"] && (!pluginType || tiddler.fields["plugin-type"] === pluginType)) {
var disablingTiddler = self.getTiddler("$:/config/Plugins/Disabled/" + title);
if(title === "$:/core" || !disablingTiddler || (disablingTiddler.fields.text || "").trim() !== "yes") {
self.unregisterPluginTiddlers(null,[title]); // Unregister the plugin if it's already registered
pluginTiddlers.push(tiddler);
registeredTitles.push(tiddler.fields.title);
}
}
};
if(titles) {
$tw.utils.each(titles,function(title) {
checkTiddler(self.getTiddler(title),title);
});
} else {
this.each(function(tiddler,title) {
checkTiddler(tiddler,title);
});
}
return registeredTitles;
};
// Unregister the plugin tiddlers of a particular type, or null/undefined for any type, optionally restricting unregistering to an array of tiddler titles. Returns an array of the titles affected
this.unregisterPluginTiddlers = function(pluginType,titles) {
var self = this,
unregisteredTitles = [];
// Remove any previous registered plugins of this type
for(var t=pluginTiddlers.length-1; t>=0; t--) {
var tiddler = pluginTiddlers[t];
if(tiddler.fields["plugin-type"] && (!pluginType || tiddler.fields["plugin-type"] === pluginType) && (!titles || titles.indexOf(tiddler.fields.title) !== -1)) {
unregisteredTitles.push(tiddler.fields.title);
pluginTiddlers.splice(t,1);
}
}
return unregisteredTitles;
};
// Unpack the currently registered plugins, creating shadow tiddlers for their constituent tiddlers
this.unpackPluginTiddlers = function() {
var self = this;
// Sort the plugin titles by the `plugin-priority` field
pluginTiddlers.sort(function(a,b) {
if("plugin-priority" in a.fields && "plugin-priority" in b.fields) {
return a.fields["plugin-priority"] - b.fields["plugin-priority"];
} else if("plugin-priority" in a.fields) {
return -1;
} else if("plugin-priority" in b.fields) {
return +1;
} else if(a.fields.title < b.fields.title) {
return -1;
} else if(a.fields.title === b.fields.title) {
return 0;
} else {
return +1;
}
});
// Now go through the plugins in ascending order and assign the shadows
shadowTiddlers = Object.create(null);
$tw.utils.each(pluginTiddlers,function(tiddler) {
// Extract the constituent tiddlers
if($tw.utils.hop(pluginInfo,tiddler.fields.title)) {
$tw.utils.each(pluginInfo[tiddler.fields.title].tiddlers,function(constituentTiddler,constituentTitle) {
// Save the tiddler object
if(constituentTitle) {
shadowTiddlers[constituentTitle] = {
source: tiddler.fields.title,
tiddler: new $tw.Tiddler(constituentTiddler,{title: constituentTitle})
};
}
});
}
});
shadowTiddlerTitles = null;
this.clearCache(null);
this.clearGlobalCache();
$tw.utils.each(indexers,function(indexer) {
indexer.rebuild();
});
};
if(this.addIndexersToWiki) {
this.addIndexersToWiki();
}
};
// Dummy methods that will be filled in after boot
$tw.Wiki.prototype.clearCache =
$tw.Wiki.prototype.clearGlobalCache =
$tw.Wiki.prototype.enqueueTiddlerEvent = function() {};
// Add an array of tiddlers
$tw.Wiki.prototype.addTiddlers = function(tiddlers) {
for(var t=0; t<tiddlers.length; t++) {
this.addTiddler(tiddlers[t]);
}
};
/*
Define all modules stored in ordinary tiddlers
*/
$tw.Wiki.prototype.defineTiddlerModules = function() {
this.each(function(tiddler,title) {
if(tiddler.hasField("module-type")) {
switch (tiddler.fields.type) {
case "application/javascript":
// We only define modules that haven't already been defined, because in the browser modules in system tiddlers are defined in inline script
if(!$tw.utils.hop($tw.modules.titles,tiddler.fields.title)) {
$tw.modules.define(tiddler.fields.title,tiddler.fields["module-type"],tiddler.fields.text);
}
break;
case "application/json":
$tw.modules.define(tiddler.fields.title,tiddler.fields["module-type"],$tw.utils.parseJSONSafe(tiddler.fields.text));
break;
case "application/x-tiddler-dictionary":
$tw.modules.define(tiddler.fields.title,tiddler.fields["module-type"],$tw.utils.parseFields(tiddler.fields.text));
break;
}
}
});
};
/*
Register all the module tiddlers that have a module type
*/
$tw.Wiki.prototype.defineShadowModules = function() {
var self = this;
this.eachShadow(function(tiddler,title) {
// Don't define the module if it is overidden by an ordinary tiddler
if(!self.tiddlerExists(title) && tiddler.hasField("module-type")) {
// Define the module
$tw.modules.define(tiddler.fields.title,tiddler.fields["module-type"],tiddler.fields.text);
}
});
};
/*
Enable safe mode by deleting any tiddlers that override a shadow tiddler
*/
$tw.Wiki.prototype.processSafeMode = function() {
var self = this,
overrides = [];
// Find the overriding tiddlers
this.each(function(tiddler,title) {
if(self.isShadowTiddler(title)) {
console.log(title);
overrides.push(title);
}
});
// Assemble a report tiddler
var titleReportTiddler = "TiddlyWiki Safe Mode",
report = [];
report.push("TiddlyWiki has been started in [[safe mode|https://tiddlywiki.com/static/SafeMode.html]]. All plugins are temporarily disabled. Most customisations have been disabled by renaming the following tiddlers:")
// Delete the overrides
overrides.forEach(function(title) {
var tiddler = self.getTiddler(title),
newTitle = "SAFE: " + title;
self.deleteTiddler(title);
self.addTiddler(new $tw.Tiddler(tiddler, {title: newTitle}));
report.push("* [[" + title + "|" + newTitle + "]]");
});
report.push()
this.addTiddler(new $tw.Tiddler({title: titleReportTiddler, text: report.join("\n\n")}));
// Set $:/DefaultTiddlers to point to our report
this.addTiddler(new $tw.Tiddler({title: "$:/DefaultTiddlers", text: "[[" + titleReportTiddler + "]]"}));
};
/*
Extracts tiddlers from a typed block of text, specifying default field values
*/
$tw.Wiki.prototype.deserializeTiddlers = function(type,text,srcFields,options) {
srcFields = srcFields || Object.create(null);
options = options || {};
var deserializer = $tw.Wiki.tiddlerDeserializerModules[options.deserializer],
fields = Object.create(null);
if(!deserializer) {
deserializer = $tw.Wiki.tiddlerDeserializerModules[type];
}
if(!deserializer && $tw.utils.getFileExtensionInfo(type)) {
// If we didn't find the serializer, try converting it from an extension to a content type
type = $tw.utils.getFileExtensionInfo(type).type;
deserializer = $tw.Wiki.tiddlerDeserializerModules[type];
}
if(!deserializer && $tw.config.contentTypeInfo[type]) {
// see if this type has a different deserializer registered with it
type = $tw.config.contentTypeInfo[type].deserializerType;
deserializer = $tw.Wiki.tiddlerDeserializerModules[type];
}
if(!deserializer) {
// If we still don't have a deserializer, treat it as plain text
deserializer = $tw.Wiki.tiddlerDeserializerModules["text/plain"];
}
for(var f in srcFields) {
fields[f] = srcFields[f];
}
if(deserializer) {
return deserializer.call(this,text,fields,type);
} else {
// Return a raw tiddler for unknown types
fields.text = text;
return [fields];
}
};
/*
Register the built in tiddler deserializer modules
*/
var deserializeHeaderComment = function(text,fields) {
var headerCommentRegExp = new RegExp($tw.config.jsModuleHeaderRegExpString,"mg"),
match = headerCommentRegExp.exec(text);
fields.text = text;
if(match) {
fields = $tw.utils.parseFields(match[1].split(/\r?\n\r?\n/mg)[0],fields);
}
return [fields];
};
$tw.modules.define("$:/boot/tiddlerdeserializer/js","tiddlerdeserializer",{
"application/javascript": deserializeHeaderComment
});
$tw.modules.define("$:/boot/tiddlerdeserializer/css","tiddlerdeserializer",{
"text/css": deserializeHeaderComment
});
$tw.modules.define("$:/boot/tiddlerdeserializer/tid","tiddlerdeserializer",{
"application/x-tiddler": function(text,fields) {
var split = text.split(/\r?\n\r?\n/mg);
if(split.length >= 1) {
fields = $tw.utils.parseFields(split[0],fields);
}
if(split.length >= 2) {
fields.text = split.slice(1).join("\n\n");
}
return [fields];
}
});
$tw.modules.define("$:/boot/tiddlerdeserializer/tids","tiddlerdeserializer",{
"application/x-tiddlers": function(text,fields) {
var titles = [],
tiddlers = [],
match = /\r?\n\r?\n/mg.exec(text);
if(match) {
fields = $tw.utils.parseFields(text.substr(0,match.index),fields);
var lines = text.substr(match.index + match[0].length).split(/\r?\n/mg);
for(var t=0; t<lines.length; t++) {
var line = lines[t];
if(line.charAt(0) !== "#") {
var colonPos= line.indexOf(":");
if(colonPos !== -1) {
var tiddler = $tw.utils.extend(Object.create(null),fields);
tiddler.title = (tiddler.title || "") + line.substr(0,colonPos).trim();
if(titles.indexOf(tiddler.title) !== -1) {
console.log("Warning: .multids file contains multiple definitions for " + tiddler.title);
}
titles.push(tiddler.title);
tiddler.text = line.substr(colonPos + 2).trim();
tiddlers.push(tiddler);
}
}
}
}
return tiddlers;
}
});
$tw.modules.define("$:/boot/tiddlerdeserializer/txt","tiddlerdeserializer",{
"text/plain": function(text,fields,type) {
fields.text = text;
fields.type = type || "text/plain";
return [fields];
}
});
$tw.modules.define("$:/boot/tiddlerdeserializer/html","tiddlerdeserializer",{
"text/html": function(text,fields) {
fields.text = text;
fields.type = "text/html";
return [fields];
}
});
$tw.modules.define("$:/boot/tiddlerdeserializer/json","tiddlerdeserializer",{
"application/json": function(text,fields) {
var isTiddlerValid = function(data) {
// Not valid if it's not an object with a title property
if(typeof(data) !== "object" || !$tw.utils.hop(data,"title")) {
return false;
}
for(var f in data) {
if($tw.utils.hop(data,f)) {
// Check field name doesn't contain control characters
if(typeof(data[f]) !== "string" || /[\x00-\x1F]/.test(f)) {
return false;
}
}
}
return true;
},
isTiddlerArrayValid = function(data) {
for(var t=0; t<data.length; t++) {
if(!isTiddlerValid(data[t])) {
return false;
}
}
return true;
},
data = $tw.utils.parseJSONSafe(text);
if($tw.utils.isArray(data) && isTiddlerArrayValid(data)) {
return data;
} else if(isTiddlerValid(data)) {
return [data];
} else {
// Plain JSON file
fields.text = text;
fields.type = "application/json";
return [fields];
}
}
});
/////////////////////////// Browser definitions
if($tw.browser && !$tw.node) {
/*
Decrypt any tiddlers stored within the element with the ID "encryptedArea". The function is asynchronous to allow the user to be prompted for a password
callback: function to be called the decryption is complete
*/
$tw.boot.decryptEncryptedTiddlers = function(callback) {
var encryptedArea = document.getElementById("encryptedStoreArea");
if(encryptedArea) {
var encryptedText = encryptedArea.innerHTML,
prompt = "Enter a password to decrypt this TiddlyWiki";
// Prompt for the password
if($tw.utils.hop($tw.boot,"encryptionPrompts")) {
prompt = $tw.boot.encryptionPrompts.decrypt;
}
$tw.passwordPrompt.createPrompt({
serviceName: prompt,
noUserName: true,
submitText: "Decrypt",
callback: function(data) {
// Attempt to decrypt the tiddlers
$tw.crypto.setPassword(data.password);
var decryptedText = $tw.crypto.decrypt(encryptedText);
if(decryptedText) {
var json = $tw.utils.parseJSONSafe(decryptedText);
for(var title in json) {
$tw.preloadTiddler(json[title]);
}
// Call the callback
callback();
// Exit and remove the password prompt
return true;
} else {
// We didn't decrypt everything, so continue to prompt for password
return false;
}
}
});
} else {
// Just invoke the callback straight away if there weren't any encrypted tiddlers
callback();
}
};
/*
Register a deserializer that can extract tiddlers from the DOM
*/
$tw.modules.define("$:/boot/tiddlerdeserializer/dom","tiddlerdeserializer",{
"(DOM)": function(node) {
var extractTextTiddlers = function(node) {
var e = node.firstChild;
while(e && e.nodeName.toLowerCase() !== "pre") {
e = e.nextSibling;
}
var title = node.getAttribute ? node.getAttribute("title") : null;
if(e && title) {
var attrs = node.attributes,
tiddler = {
text: $tw.utils.htmlDecode(e.innerHTML)
};
for(var i=attrs.length-1; i >= 0; i--) {
tiddler[attrs[i].name] = attrs[i].value;
}
return [tiddler];
} else {
return null;
}
},
extractModuleTiddlers = function(node) {
if(node.hasAttribute && node.hasAttribute("data-tiddler-title")) {
var text = node.innerHTML,
s = text.indexOf("{"),
e = text.lastIndexOf("}");
if(node.hasAttribute("data-module") && s !== -1 && e !== -1) {
text = text.substring(s+1,e);
}
var fields = {text: text},
attributes = node.attributes;
for(var a=0; a<attributes.length; a++) {
if(attributes[a].nodeName.substr(0,13) === "data-tiddler-") {
fields[attributes[a].nodeName.substr(13)] = attributes[a].value;
}
}
return [fields];
} else {
return null;
}
},
t,result = [];
if(node) {
var type = (node.getAttribute && node.getAttribute("type")) || null;
if(type) {
// A new-style container with an explicit deserialization type
result = $tw.wiki.deserializeTiddlers(type,node.textContent);
} else {
// An old-style container of classic DIV-based tiddlers
for(t = 0; t < node.childNodes.length; t++) {
var childNode = node.childNodes[t],
tiddlers = extractTextTiddlers(childNode);
tiddlers = tiddlers || extractModuleTiddlers(childNode);
if(tiddlers) {
result.push.apply(result,tiddlers);
}
}
}
}
return result;
}
});
$tw.loadTiddlersBrowser = function() {
// In the browser, we load tiddlers from certain elements
var containerSelectors = [
// IDs for old-style v5.1.x tiddler stores
"#libraryModules",
"#modules",
"#bootKernelPrefix",
"#bootKernel",
"#styleArea",
"#storeArea",
"#systemArea",
// Classes for new-style v5.2.x JSON tiddler stores
"script.tiddlywiki-tiddler-store"
];
for(var t=0; t<containerSelectors.length; t++) {
var nodes = document.querySelectorAll(containerSelectors[t]);
for(var n=0; n<nodes.length; n++) {
$tw.wiki.addTiddlers($tw.wiki.deserializeTiddlers("(DOM)",nodes[n]));
}
}
};
} else {
/////////////////////////// Server definitions
/*
Get any encrypted tiddlers
*/
$tw.boot.decryptEncryptedTiddlers = function(callback) {
// Storing encrypted tiddlers on the server isn't supported yet
callback();
};
} // End of if($tw.browser && !$tw.node)
/////////////////////////// Node definitions
if($tw.node) {
/*
Load the tiddlers contained in a particular file (and optionally extract fields from the accompanying .meta file) returned as {filepath:,type:,tiddlers:[],hasMetaFile:}
*/
$tw.loadTiddlersFromFile = function(filepath,fields) {
var ext = path.extname(filepath),
extensionInfo = $tw.utils.getFileExtensionInfo(ext),
type = extensionInfo ? extensionInfo.type : null,
typeInfo = type ? $tw.config.contentTypeInfo[type] : null,
data = fs.readFileSync(filepath,typeInfo ? typeInfo.encoding : "utf8"),
tiddlers = $tw.wiki.deserializeTiddlers(ext,data,fields),
metadata = $tw.loadMetadataForFile(filepath);
if(metadata) {
if(type === "application/json") {
tiddlers = [{text: data, type: "application/json"}];
}
tiddlers = [$tw.utils.extend({},tiddlers[0],metadata)];
}
return {filepath: filepath, type: type, tiddlers: tiddlers, hasMetaFile: !!metadata};
};
/*
Load the metadata fields in the .meta file corresponding to a particular file
*/
$tw.loadMetadataForFile = function(filepath) {
var metafilename = filepath + ".meta";
if(fs.existsSync(metafilename)) {
return $tw.utils.parseFields(fs.readFileSync(metafilename,"utf8") || "");
} else {
return null;
}
};
/*
A default set of files for TiddlyWiki to ignore during load.
This matches what NPM ignores, and adds "*.meta" to ignore tiddler
metadata files.
*/
$tw.boot.excludeRegExp = /^\.DS_Store$|^.*\.meta$|^\..*\.swp$|^\._.*$|^\.git$|^\.hg$|^\.lock-wscript$|^\.svn$|^\.wafpickle-.*$|^CVS$|^npm-debug\.log$/;
/*
Load all the tiddlers recursively from a directory, including honouring `tiddlywiki.files` files for drawing in external files. Returns an array of {filepath:,type:,tiddlers: [{..fields...}],hasMetaFile:}. Note that no file information is returned for externally loaded tiddlers, just the `tiddlers` property.
*/
$tw.loadTiddlersFromPath = function(filepath,excludeRegExp) {
excludeRegExp = excludeRegExp || $tw.boot.excludeRegExp;
var tiddlers = [];
if(fs.existsSync(filepath)) {
var stat = fs.statSync(filepath);
if(stat.isDirectory()) {
var files = fs.readdirSync(filepath);
// Look for a tiddlywiki.files file
if(files.indexOf("tiddlywiki.files") !== -1) {
Array.prototype.push.apply(tiddlers,$tw.loadTiddlersFromSpecification(filepath,excludeRegExp));
} else {
// If not, read all the files in the directory
$tw.utils.each(files,function(file) {
if(!excludeRegExp.test(file) && file !== "plugin.info") {
tiddlers.push.apply(tiddlers,$tw.loadTiddlersFromPath(filepath + path.sep + file,excludeRegExp));
}
});
}
} else if(stat.isFile()) {
tiddlers.push($tw.loadTiddlersFromFile(filepath,{title: filepath}));
}
}
return tiddlers;
};
/*
Load all the tiddlers defined by a `tiddlywiki.files` specification file
filepath: pathname of the directory containing the specification file
*/
$tw.loadTiddlersFromSpecification = function(filepath,excludeRegExp) {
var tiddlers = [];
// Read the specification
var filesInfo = $tw.utils.parseJSONSafe(fs.readFileSync(filepath + path.sep + "tiddlywiki.files","utf8"));
// Helper to process a file
var processFile = function(filename,isTiddlerFile,fields,isEditableFile) {
var extInfo = $tw.config.fileExtensionInfo[path.extname(filename)],
type = (extInfo || {}).type || fields.type || "text/plain",
typeInfo = $tw.config.contentTypeInfo[type] || {},
pathname = path.resolve(filepath,filename),
text = fs.readFileSync(pathname,typeInfo.encoding || "utf8"),
metadata = $tw.loadMetadataForFile(pathname) || {},
fileTiddlers;
if(isTiddlerFile) {
fileTiddlers = $tw.wiki.deserializeTiddlers(path.extname(pathname),text,metadata) || [];
} else {
fileTiddlers = [$tw.utils.extend({text: text},metadata)];
}
var combinedFields = $tw.utils.extend({},fields,metadata);
$tw.utils.each(fileTiddlers,function(tiddler) {
$tw.utils.each(combinedFields,function(fieldInfo,name) {
if(typeof fieldInfo === "string" || $tw.utils.isArray(fieldInfo)) {
tiddler[name] = fieldInfo;
} else {
var value = tiddler[name];
switch(fieldInfo.source) {
case "filename":
value = path.basename(filename);
break;
case "filename-uri-decoded":
value = $tw.utils.decodeURIComponentSafe(path.basename(filename));
break;
case "basename":
value = path.basename(filename,path.extname(filename));
break;
case "basename-uri-decoded":
value = $tw.utils.decodeURIComponentSafe(path.basename(filename,path.extname(filename)));
break;
case "extname":
value = path.extname(filename);
break;
case "created":
value = new Date(fs.statSync(pathname).birthtime);
break;
case "modified":
value = new Date(fs.statSync(pathname).mtime);
break;
}
if(fieldInfo.prefix) {
value = fieldInfo.prefix + value;
}
if(fieldInfo.suffix) {
value = value + fieldInfo.suffix;
}
tiddler[name] = value;
}
});
});
if(isEditableFile) {
tiddlers.push({filepath: pathname, hasMetaFile: !!metadata && !isTiddlerFile, isEditableFile: true, tiddlers: fileTiddlers});
} else {
tiddlers.push({tiddlers: fileTiddlers});
}
};
// Helper to recursively search subdirectories
var getAllFiles = function(dirPath, recurse, arrayOfFiles) {
recurse = recurse || false;
arrayOfFiles = arrayOfFiles || [];
var files = fs.readdirSync(dirPath);
files.forEach(function(file) {
if (recurse && fs.statSync(dirPath + path.sep + file).isDirectory()) {
arrayOfFiles = getAllFiles(dirPath + path.sep + file, recurse, arrayOfFiles);
} else if(fs.statSync(dirPath + path.sep + file).isFile()){
arrayOfFiles.push(path.join(dirPath, path.sep, file));
}
});
return arrayOfFiles;
}
// Process the listed tiddlers
$tw.utils.each(filesInfo.tiddlers,function(tidInfo) {
if(tidInfo.prefix && tidInfo.suffix) {
tidInfo.fields.text = {prefix: tidInfo.prefix,suffix: tidInfo.suffix};
} else if(tidInfo.prefix) {
tidInfo.fields.text = {prefix: tidInfo.prefix};
} else if(tidInfo.suffix) {
tidInfo.fields.text = {suffix: tidInfo.suffix};
}
processFile(tidInfo.file,tidInfo.isTiddlerFile,tidInfo.fields);
});
// Process any listed directories
$tw.utils.each(filesInfo.directories,function(dirSpec) {
// Read literal directories directly
if(typeof dirSpec === "string") {
var pathname = path.resolve(filepath,dirSpec);
if(fs.existsSync(pathname) && fs.statSync(pathname).isDirectory()) {
tiddlers.push.apply(tiddlers,$tw.loadTiddlersFromPath(pathname,excludeRegExp));
}
} else {
// Process directory specifier
var dirPath = path.resolve(filepath,dirSpec.path);
if(fs.existsSync(dirPath) && fs.statSync(dirPath).isDirectory()) {
var files = getAllFiles(dirPath, dirSpec.searchSubdirectories),
fileRegExp = new RegExp(dirSpec.filesRegExp || "^.*$"),
metaRegExp = /^.*\.meta$/;
for(var t=0; t<files.length; t++) {
var thisPath = path.relative(filepath, files[t]),
filename = path.basename(thisPath);
if(filename !== "tiddlywiki.files" && !metaRegExp.test(filename) && fileRegExp.test(filename)) {
processFile(thisPath,dirSpec.isTiddlerFile,dirSpec.fields,dirSpec.isEditableFile);
}
}
} else {
console.log("Warning: a directory in a tiddlywiki.files file does not exist.");
console.log("dirPath: " + dirPath);
console.log("tiddlywiki.files location: " + filepath);
}
}
});
return tiddlers;
};
/*
Load the tiddlers from a plugin folder, and package them up into a proper JSON plugin tiddler
*/
$tw.loadPluginFolder = function(filepath,excludeRegExp) {
excludeRegExp = excludeRegExp || $tw.boot.excludeRegExp;
var infoPath = filepath + path.sep + "plugin.info";
if(fs.existsSync(filepath) && fs.statSync(filepath).isDirectory()) {
// Read the plugin information
if(!fs.existsSync(infoPath) || !fs.statSync(infoPath).isFile()) {
console.log("Warning: missing plugin.info file in " + filepath);
return null;
}
var pluginInfo = $tw.utils.parseJSONSafe(fs.readFileSync(infoPath,"utf8"));
// Read the plugin files
var pluginFiles = $tw.loadTiddlersFromPath(filepath,excludeRegExp);
// Save the plugin tiddlers into the plugin info
pluginInfo.tiddlers = pluginInfo.tiddlers || Object.create(null);
for(var f=0; f<pluginFiles.length; f++) {
var tiddlers = pluginFiles[f].tiddlers;
for(var t=0; t<tiddlers.length; t++) {
var tiddler= tiddlers[t];
if(tiddler.title) {
pluginInfo.tiddlers[tiddler.title] = tiddler;
}
}
}
// Give the plugin the same version number as the core if it doesn't have one
if(!("version" in pluginInfo)) {
pluginInfo.version = $tw.packageInfo.version;
}
// Use "plugin" as the plugin-type if we don't have one
if(!("plugin-type" in pluginInfo)) {
pluginInfo["plugin-type"] = "plugin";
}
pluginInfo.dependents = pluginInfo.dependents || [];
pluginInfo.type = "application/json";
// Set plugin text
pluginInfo.text = JSON.stringify({tiddlers: pluginInfo.tiddlers});
delete pluginInfo.tiddlers;
// Deserialise array fields (currently required for the dependents field)
for(var field in pluginInfo) {
if($tw.utils.isArray(pluginInfo[field])) {
pluginInfo[field] = $tw.utils.stringifyList(pluginInfo[field]);
}
}
return pluginInfo;
} else {
return null;
}
};
/*
name: Name of the plugin to find
paths: array of file paths to search for it
Returns the path of the plugin folder
*/
$tw.findLibraryItem = function(name,paths) {
var pathIndex = 0;
do {
var pluginPath = path.resolve(paths[pathIndex],"./" + name)
if(fs.existsSync(pluginPath) && fs.statSync(pluginPath).isDirectory()) {
return pluginPath;
}
} while(++pathIndex < paths.length);
return null;
};
/*
name: Name of the plugin to load
paths: array of file paths to search for it
*/
$tw.loadPlugin = function(name,paths) {
var pluginPath = $tw.findLibraryItem(name,paths);
if(pluginPath) {
var pluginFields = $tw.loadPluginFolder(pluginPath);
if(pluginFields) {
$tw.wiki.addTiddler(pluginFields);
return;
}
}
console.log("Warning: Cannot find plugin '" + name + "'");
};
/*
libraryPath: Path of library folder for these plugins (relative to core path)
envVar: Environment variable name for these plugins
Returns an array of search paths
*/
$tw.getLibraryItemSearchPaths = function(libraryPath,envVar) {
var pluginPaths = [path.resolve($tw.boot.corePath,libraryPath)],
env = process.env[envVar];
if(env) {
env.split(path.delimiter).map(function(item) {
if(item) {
pluginPaths.push(item);
}
});
}
return pluginPaths;
};
/*
plugins: Array of names of plugins (eg, "tiddlywiki/filesystemadaptor")
libraryPath: Path of library folder for these plugins (relative to core path)
envVar: Environment variable name for these plugins
*/
$tw.loadPlugins = function(plugins,libraryPath,envVar) {
if(plugins) {
var pluginPaths = $tw.getLibraryItemSearchPaths(libraryPath,envVar);
for(var t=0; t<plugins.length; t++) {
$tw.loadPlugin(plugins[t],pluginPaths);
}
}
};
/*
path: path of wiki directory
options:
parentPaths: array of parent paths that we mustn't recurse into
readOnly: true if the tiddler file paths should not be retained
*/
$tw.loadWikiTiddlers = function(wikiPath,options) {
options = options || {};
var parentPaths = options.parentPaths || [],
wikiInfoPath = path.resolve(wikiPath,$tw.config.wikiInfo),
wikiInfo,
pluginFields;
// Bail if we don't have a wiki info file
if(fs.existsSync(wikiInfoPath)) {
wikiInfo = $tw.utils.parseJSONSafe(fs.readFileSync(wikiInfoPath,"utf8"));
} else {
return null;
}
// Save the path to the tiddlers folder for the filesystemadaptor
var config = wikiInfo.config || {};
if($tw.boot.wikiPath == wikiPath) {
$tw.boot.wikiTiddlersPath = path.resolve($tw.boot.wikiPath,config["default-tiddler-location"] || $tw.config.wikiTiddlersSubDir);
}
// Load any parent wikis
if(wikiInfo.includeWikis) {
parentPaths = parentPaths.slice(0);
parentPaths.push(wikiPath);
$tw.utils.each(wikiInfo.includeWikis,function(info) {
if(typeof info === "string") {
info = {path: info};
}
var resolvedIncludedWikiPath = path.resolve(wikiPath,info.path);
if(parentPaths.indexOf(resolvedIncludedWikiPath) === -1) {
var subWikiInfo = $tw.loadWikiTiddlers(resolvedIncludedWikiPath,{
parentPaths: parentPaths,
readOnly: info["read-only"]
});
// Merge the build targets
wikiInfo.build = $tw.utils.extend([],subWikiInfo.build,wikiInfo.build);
} else {
$tw.utils.error("Cannot recursively include wiki " + resolvedIncludedWikiPath);
}
});
}
// Load any plugins, themes and languages listed in the wiki info file
$tw.loadPlugins(wikiInfo.plugins,$tw.config.pluginsPath,$tw.config.pluginsEnvVar);
$tw.loadPlugins(wikiInfo.themes,$tw.config.themesPath,$tw.config.themesEnvVar);
$tw.loadPlugins(wikiInfo.languages,$tw.config.languagesPath,$tw.config.languagesEnvVar);
// Load the wiki files, registering them as writable
var resolvedWikiPath = path.resolve(wikiPath,$tw.config.wikiTiddlersSubDir);
$tw.utils.each($tw.loadTiddlersFromPath(resolvedWikiPath),function(tiddlerFile) {
if(!options.readOnly && tiddlerFile.filepath) {
$tw.utils.each(tiddlerFile.tiddlers,function(tiddler) {
$tw.boot.files[tiddler.title] = {
filepath: tiddlerFile.filepath,
type: tiddlerFile.type,
hasMetaFile: tiddlerFile.hasMetaFile,
isEditableFile: config["retain-original-tiddler-path"] || tiddlerFile.isEditableFile || tiddlerFile.filepath.indexOf($tw.boot.wikiTiddlersPath) !== 0
};
});
}
$tw.wiki.addTiddlers(tiddlerFile.tiddlers);
});
if ($tw.boot.wikiPath == wikiPath) {
// Save the original tiddler file locations if requested
var output = {}, relativePath, fileInfo;
for(var title in $tw.boot.files) {
fileInfo = $tw.boot.files[title];
if(fileInfo.isEditableFile) {
relativePath = path.relative($tw.boot.wikiTiddlersPath,fileInfo.filepath);
fileInfo.originalpath = relativePath;
output[title] =
path.sep === "/" ?
relativePath :
relativePath.split(path.sep).join("/");
}
}
if(Object.keys(output).length > 0){
$tw.wiki.addTiddler({title: "$:/config/OriginalTiddlerPaths", type: "application/json", text: JSON.stringify(output)});
}
}
// Load any plugins within the wiki folder
var wikiPluginsPath = path.resolve(wikiPath,$tw.config.wikiPluginsSubDir);
if(fs.existsSync(wikiPluginsPath)) {
var pluginFolders = fs.readdirSync(wikiPluginsPath);
for(var t=0; t<pluginFolders.length; t++) {
pluginFields = $tw.loadPluginFolder(path.resolve(wikiPluginsPath,"./" + pluginFolders[t]));
if(pluginFields) {
$tw.wiki.addTiddler(pluginFields);
}
}
}
// Load any themes within the wiki folder
var wikiThemesPath = path.resolve(wikiPath,$tw.config.wikiThemesSubDir);
if(fs.existsSync(wikiThemesPath)) {
var themeFolders = fs.readdirSync(wikiThemesPath);
for(var t=0; t<themeFolders.length; t++) {
pluginFields = $tw.loadPluginFolder(path.resolve(wikiThemesPath,"./" + themeFolders[t]));
if(pluginFields) {
$tw.wiki.addTiddler(pluginFields);
}
}
}
// Load any languages within the wiki folder
var wikiLanguagesPath = path.resolve(wikiPath,$tw.config.wikiLanguagesSubDir);
if(fs.existsSync(wikiLanguagesPath)) {
var languageFolders = fs.readdirSync(wikiLanguagesPath);
for(var t=0; t<languageFolders.length; t++) {
pluginFields = $tw.loadPluginFolder(path.resolve(wikiLanguagesPath,"./" + languageFolders[t]));
if(pluginFields) {
$tw.wiki.addTiddler(pluginFields);
}
}
}
return wikiInfo;
};
$tw.loadTiddlersNode = function() {
// Load the boot tiddlers
$tw.utils.each($tw.loadTiddlersFromPath($tw.boot.bootPath),function(tiddlerFile) {
$tw.wiki.addTiddlers(tiddlerFile.tiddlers);
});
// Load the core tiddlers
$tw.wiki.addTiddler($tw.loadPluginFolder($tw.boot.corePath));
// Load any extra plugins
$tw.utils.each($tw.boot.extraPlugins,function(name) {
if(name.charAt(0) === "+") { // Relative path to plugin
var pluginFields = $tw.loadPluginFolder(name.substring(1));
if(pluginFields) {
$tw.wiki.addTiddler(pluginFields);
}
} else {
var parts = name.split("/"),
type = parts[0];
if(parts.length === 3 && ["plugins","themes","languages"].indexOf(type) !== -1) {
$tw.loadPlugins([parts[1] + "/" + parts[2]],$tw.config[type + "Path"],$tw.config[type + "EnvVar"]);
}
}
});
// Load the tiddlers from the wiki directory
if($tw.boot.wikiPath) {
$tw.boot.wikiInfo = $tw.loadWikiTiddlers($tw.boot.wikiPath);
}
};
// End of if($tw.node)
}
/////////////////////////// Main startup function called once tiddlers have been decrypted
/*
Startup TiddlyWiki
*/
$tw.boot.initStartup = function(options) {
// Get the URL hash and check for safe mode
$tw.locationHash = "#";
if($tw.browser && !$tw.node) {
if(location.hash === "#:safe") {
$tw.safeMode = true;
} else {
$tw.locationHash = $tw.utils.getLocationHash();
}
}
// Initialise some more $tw properties
$tw.utils.deepDefaults($tw,{
modules: { // Information about each module
titles: Object.create(null), // hashmap by module title of {fn:, exports:, moduleType:}
types: {} // hashmap by module type of hashmap of exports
},
config: { // Configuration overridables
pluginsPath: "../plugins/",
themesPath: "../themes/",
languagesPath: "../languages/",
editionsPath: "../editions/",
wikiInfo: "./tiddlywiki.info",
wikiPluginsSubDir: "./plugins",
wikiThemesSubDir: "./themes",
wikiLanguagesSubDir: "./languages",
wikiTiddlersSubDir: "./tiddlers",
wikiOutputSubDir: "./output",
jsModuleHeaderRegExpString: "^\\/\\*\\\\(?:\\r?\\n)((?:^[^\\r\\n]*(?:\\r?\\n))+?)(^\\\\\\*\\/$(?:\\r?\\n)?)",
fileExtensionInfo: Object.create(null), // Map file extension to {type:}
contentTypeInfo: Object.create(null), // Map type to {encoding:,extension:}
pluginsEnvVar: "TIDDLYWIKI_PLUGIN_PATH",
themesEnvVar: "TIDDLYWIKI_THEME_PATH",
languagesEnvVar: "TIDDLYWIKI_LANGUAGE_PATH",
editionsEnvVar: "TIDDLYWIKI_EDITION_PATH"
},
log: {}, // Log flags
unloadTasks: []
});
if(!$tw.boot.tasks.readBrowserTiddlers) {
// For writable tiddler files, a hashmap of title to {filepath:,type:,hasMetaFile:}
$tw.boot.files = Object.create(null);
// System paths and filenames
$tw.boot.bootPath = options.bootPath || path.dirname(module.filename);
$tw.boot.corePath = path.resolve($tw.boot.bootPath,"../core");
// If there's no arguments then default to `--help`
if($tw.boot.argv.length === 0) {
$tw.boot.argv = ["--help"];
}
// Parse any extra plugin references
$tw.boot.extraPlugins = $tw.boot.extraPlugins || [];
while($tw.boot.argv[0] && $tw.boot.argv[0].indexOf("+") === 0) {
$tw.boot.extraPlugins.push($tw.boot.argv[0].substring(1));
$tw.boot.argv.splice(0,1);
}
// If the first command line argument doesn't start with `--` then we
// interpret it as the path to the wiki folder, which will otherwise default
// to the current folder
if($tw.boot.argv[0] && $tw.boot.argv[0].indexOf("--") !== 0) {
$tw.boot.wikiPath = $tw.boot.argv[0];
$tw.boot.argv = $tw.boot.argv.slice(1);
} else {
$tw.boot.wikiPath = process.cwd();
}
// Read package info
$tw.packageInfo = $tw.packageInfo || require("../package.json");
// Check node version number
if(!$tw.utils.checkVersions(process.version.substr(1),$tw.packageInfo.engines.node.substr(2))) {
$tw.utils.error("TiddlyWiki5 requires node.js version " + $tw.packageInfo.engines.node);
}
}
// Add file extension information
$tw.utils.registerFileType("text/vnd.tiddlywiki","utf8",".tid");
$tw.utils.registerFileType("application/x-tiddler","utf8",".tid");
$tw.utils.registerFileType("application/x-tiddlers","utf8",".multids");
$tw.utils.registerFileType("application/x-tiddler-html-div","utf8",".tiddler");
$tw.utils.registerFileType("text/vnd.tiddlywiki2-recipe","utf8",".recipe");
$tw.utils.registerFileType("text/plain","utf8",".txt");
$tw.utils.registerFileType("text/css","utf8",".css");
$tw.utils.registerFileType("text/html","utf8",[".html",".htm"]);
$tw.utils.registerFileType("application/hta","utf16le",".hta",{deserializerType:"text/html"});
$tw.utils.registerFileType("application/javascript","utf8",".js");
$tw.utils.registerFileType("application/json","utf8",".json");
$tw.utils.registerFileType("application/pdf","base64",".pdf",{flags:["image"]});
$tw.utils.registerFileType("application/zip","base64",".zip");
$tw.utils.registerFileType("application/x-zip-compressed","base64",".zip");
$tw.utils.registerFileType("image/jpeg","base64",[".jpg",".jpeg"],{flags:["image"]});
$tw.utils.registerFileType("image/jpg","base64",[".jpg",".jpeg"],{flags:["image"]});
$tw.utils.registerFileType("image/png","base64",".png",{flags:["image"]});
$tw.utils.registerFileType("image/gif","base64",".gif",{flags:["image"]});
$tw.utils.registerFileType("image/webp","base64",".webp",{flags:["image"]});
$tw.utils.registerFileType("image/heic","base64",".heic",{flags:["image"]});
$tw.utils.registerFileType("image/heif","base64",".heif",{flags:["image"]});
$tw.utils.registerFileType("image/svg+xml","utf8",".svg",{flags:["image"]});
$tw.utils.registerFileType("image/vnd.microsoft.icon","base64",".ico",{flags:["image"]});
$tw.utils.registerFileType("image/x-icon","base64",".ico",{flags:["image"]});
$tw.utils.registerFileType("application/font-woff","base64",".woff");
$tw.utils.registerFileType("application/x-font-ttf","base64",".woff");
$tw.utils.registerFileType("application/font-woff2","base64",".woff2");
$tw.utils.registerFileType("audio/ogg","base64",".ogg");
$tw.utils.registerFileType("video/ogg","base64",[".ogm",".ogv",".ogg"]);
$tw.utils.registerFileType("video/webm","base64",".webm");
$tw.utils.registerFileType("video/mp4","base64",".mp4");
$tw.utils.registerFileType("audio/mp3","base64",".mp3");
$tw.utils.registerFileType("audio/mp4","base64",[".mp4",".m4a"]);
$tw.utils.registerFileType("text/markdown","utf8",[".md",".markdown"],{deserializerType:"text/x-markdown"});
$tw.utils.registerFileType("text/x-markdown","utf8",[".md",".markdown"]);
$tw.utils.registerFileType("application/enex+xml","utf8",".enex");
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.wordprocessingml.document","base64",".docx");
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","base64",".xlsx");
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.presentationml.presentation","base64",".pptx");
$tw.utils.registerFileType("text/x-bibtex","utf8",".bib",{deserializerType:"application/x-bibtex"});
$tw.utils.registerFileType("application/x-bibtex","utf8",".bib");
$tw.utils.registerFileType("application/epub+zip","base64",".epub");
$tw.utils.registerFileType("application/octet-stream","base64",".octet-stream");
// Create the wiki store for the app
$tw.wiki = new $tw.Wiki();
// Install built in tiddler fields modules
$tw.Tiddler.fieldModules = $tw.modules.getModulesByTypeAsHashmap("tiddlerfield");
// Install the tiddler deserializer modules
$tw.Wiki.tiddlerDeserializerModules = Object.create(null);
$tw.modules.applyMethods("tiddlerdeserializer",$tw.Wiki.tiddlerDeserializerModules);
// Call unload handlers in the browser
if($tw.browser) {
window.onbeforeunload = function(event) {
event = event || {};
var result;
$tw.utils.each($tw.unloadTasks,function(task) {
var r = task(event);
if(r) {
result = r;
}
});
return result;
}
}
};
$tw.boot.loadStartup = function(options){
// Load tiddlers
if($tw.boot.tasks.readBrowserTiddlers) {
$tw.loadTiddlersBrowser();
} else {
$tw.loadTiddlersNode();
}
// Load any preloaded tiddlers
if($tw.preloadTiddlers) {
$tw.wiki.addTiddlers($tw.preloadTiddlers);
}
// Give hooks a chance to modify the store
$tw.hooks.invokeHook("th-boot-tiddlers-loaded");
}
$tw.boot.execStartup = function(options){
// Unpack plugin tiddlers
$tw.wiki.readPluginInfo();
$tw.wiki.registerPluginTiddlers("plugin",$tw.safeMode ? ["$:/core"] : undefined);
$tw.wiki.unpackPluginTiddlers();
// Process "safe mode"
if($tw.safeMode) {
$tw.wiki.processSafeMode();
}
// Register typed modules from the tiddlers we've just loaded
$tw.wiki.defineTiddlerModules();
// And any modules within plugins
$tw.wiki.defineShadowModules();
// Make sure the crypto state tiddler is up to date
if($tw.crypto) {
$tw.crypto.updateCryptoStateTiddler();
}
// Gather up any startup modules
$tw.boot.remainingStartupModules = []; // Array of startup modules
$tw.modules.forEachModuleOfType("startup",function(title,module) {
if(module.startup) {
$tw.boot.remainingStartupModules.push(module);
}
});
// Keep track of the startup tasks that have been executed
$tw.boot.executedStartupModules = Object.create(null);
$tw.boot.disabledStartupModules = $tw.boot.disabledStartupModules || [];
// Repeatedly execute the next eligible task
$tw.boot.executeNextStartupTask(options.callback);
}
/*
Startup TiddlyWiki
*/
$tw.boot.startup = function(options) {
options = options || {};
// Get the URL hash and check for safe mode
$tw.boot.initStartup(options);
$tw.boot.loadStartup(options);
$tw.boot.execStartup(options);
};
/*
Add another unload task
*/
$tw.addUnloadTask = function(task) {
if($tw.unloadTasks.indexOf(task) === -1) {
$tw.unloadTasks.push(task);
}
}
/*
Execute the remaining eligible startup tasks
*/
$tw.boot.executeNextStartupTask = function(callback) {
// Find the next eligible task
var taskIndex = 0, task,
asyncTaskCallback = function() {
if(task.name) {
$tw.boot.executedStartupModules[task.name] = true;
}
return $tw.boot.executeNextStartupTask(callback);
};
while(taskIndex < $tw.boot.remainingStartupModules.length) {
task = $tw.boot.remainingStartupModules[taskIndex];
if($tw.boot.isStartupTaskEligible(task)) {
// Remove this task from the list
$tw.boot.remainingStartupModules.splice(taskIndex,1);
// Assemble log message
var s = ["Startup task:",task.name];
if(task.platforms) {
s.push("platforms:",task.platforms.join(","));
}
if(task.after) {
s.push("after:",task.after.join(","));
}
if(task.before) {
s.push("before:",task.before.join(","));
}
$tw.boot.log(s.join(" "));
// Execute task
if(!$tw.utils.hop(task,"synchronous") || task.synchronous) {
task.startup();
if(task.name) {
$tw.boot.executedStartupModules[task.name] = true;
}
return $tw.boot.executeNextStartupTask(callback);
} else {
task.startup(asyncTaskCallback);
return true;
}
}
taskIndex++;
}
if(typeof callback === 'function') {
callback();
}
return false;
};
/*
Returns true if we are running on one of the platforms specified in taskModule's
`platforms` array; or if `platforms` property is not defined.
*/
$tw.boot.doesTaskMatchPlatform = function(taskModule) {
var platforms = taskModule.platforms;
if(platforms) {
for(var t=0; t<platforms.length; t++) {
switch (platforms[t]) {
case "browser":
if ($tw.browser) {
return true;
}
break;
case "node":
if ($tw.node) {
return true;
}
break;
default:
$tw.utils.error("Module " + taskModule.name + ": '" + platforms[t] + "' in export.platforms invalid");
}
}
return false;
}
return true;
};
$tw.boot.isStartupTaskEligible = function(taskModule) {
var t;
// Check that the platform is correct
if(!$tw.boot.doesTaskMatchPlatform(taskModule)) {
return false;
}
var name = taskModule.name,
remaining = $tw.boot.remainingStartupModules;
if(name) {
// Fail if this module is disabled
if($tw.boot.disabledStartupModules.indexOf(name) !== -1) {
return false;
}
// Check that no other outstanding tasks must be executed before this one
for(t=0; t<remaining.length; t++) {
var task = remaining[t];
if(task.before && task.before.indexOf(name) !== -1) {
if($tw.boot.doesTaskMatchPlatform(task) && (!task.name || $tw.boot.disabledStartupModules.indexOf(task.name) === -1)) {
return false;
}
}
}
}
// Check that all of the tasks that we must be performed after has been done
var after = taskModule.after;
if(after) {
for(t=0; t<after.length; t++) {
if(!$tw.boot.executedStartupModules[after[t]]) {
return false;
}
}
}
return true;
};
/*
Global Hooks mechanism which allows plugins to modify default functionality
*/
$tw.hooks = $tw.hooks || { names: {}};
/*
Add hooks to the hashmap
*/
$tw.hooks.addHook = function(hookName,definition) {
if($tw.utils.hop($tw.hooks.names,hookName)) {
$tw.hooks.names[hookName].push(definition);
}
else {
$tw.hooks.names[hookName] = [definition];
}
};
/*
Invoke the hook by key
*/
$tw.hooks.invokeHook = function(hookName /*, value,... */) {
var args = Array.prototype.slice.call(arguments,1);
if($tw.utils.hop($tw.hooks.names,hookName)) {
for (var i = 0; i < $tw.hooks.names[hookName].length; i++) {
args[0] = $tw.hooks.names[hookName][i].apply(null,args);
}
}
return args[0];
};
/////////////////////////// Main boot function to decrypt tiddlers and then startup
$tw.boot.boot = function(callback) {
// Initialise crypto object
$tw.crypto = new $tw.utils.Crypto();
// Initialise password prompter
if($tw.browser && !$tw.node) {
$tw.passwordPrompt = new $tw.utils.PasswordPrompt();
}
// Preload any encrypted tiddlers
$tw.boot.decryptEncryptedTiddlers(function() {
// Startup
$tw.boot.startup({callback: callback});
});
};
/////////////////////////// Autoboot in the browser
if($tw.browser && !$tw.boot.suppressBoot) {
$tw.boot.boot();
}
return $tw;
});
if(typeof(exports) !== "undefined") {
exports.TiddlyWiki = _boot;
} else {
_boot(window.$tw);
}
//# sourceURL=$:/boot/boot.js
</script>
</div>
<!--~~ Raw markup for the bottom of the body section ~~-->
</body>
</html>