mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-01-24 20:04:40 +00:00
Compare commits
232 Commits
v5.0.0-alp
...
v5.0.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
559f9da9b4 | ||
|
|
8f6e3c641d | ||
|
|
aae8587660 | ||
|
|
5bb7ee2f88 | ||
|
|
0a93edb1b6 | ||
|
|
b0ff8bee6a | ||
|
|
48f8046cf5 | ||
|
|
d4e6516a61 | ||
|
|
1fddcf075f | ||
|
|
d64c37c3b7 | ||
|
|
ffcf2bfaac | ||
|
|
4d4a0e01b4 | ||
|
|
b37a139aa7 | ||
|
|
17277cf8fd | ||
|
|
374743883d | ||
|
|
49ade66540 | ||
|
|
09e14dd8ad | ||
|
|
c30392c0c5 | ||
|
|
fa8cc1c512 | ||
|
|
21f795b542 | ||
|
|
1363d24e86 | ||
|
|
4cffa58df3 | ||
|
|
7d0b930335 | ||
|
|
f3954d374d | ||
|
|
16170ce504 | ||
|
|
9dcbdb5297 | ||
|
|
ecdfce1985 | ||
|
|
88e0bd3251 | ||
|
|
5ccd4988aa | ||
|
|
1e99f6cb67 | ||
|
|
41fc06ab4d | ||
|
|
b149ab47f4 | ||
|
|
1b99dbb677 | ||
|
|
c4814cec91 | ||
|
|
698efb66bb | ||
|
|
7a4abba9fd | ||
|
|
026a27c1ab | ||
|
|
34ae1387a5 | ||
|
|
62b9fb336b | ||
|
|
8ed364ed72 | ||
|
|
b1aadc7e94 | ||
|
|
eb41ca578d | ||
|
|
2ec58f7fa2 | ||
|
|
6be7e2c30e | ||
|
|
7ebb8702b2 | ||
|
|
eac07fb6c3 | ||
|
|
3a07cd4c55 | ||
|
|
a12310f225 | ||
|
|
593503fe09 | ||
|
|
7f4dffca77 | ||
|
|
f9f9c96ca1 | ||
|
|
28d6627632 | ||
|
|
91f10af53f | ||
|
|
ba796c3f23 | ||
|
|
64ff422c80 | ||
|
|
6c6f53a69f | ||
|
|
7fcf52543f | ||
|
|
933c61e611 | ||
|
|
da613f7dee | ||
|
|
2db3043d6e | ||
|
|
208c64aa9d | ||
|
|
2c9152fa56 | ||
|
|
3da17c8e04 | ||
|
|
fe19909034 | ||
|
|
6ee0e07036 | ||
|
|
8a2b3bc831 | ||
|
|
7baf8431a4 | ||
|
|
4352e81b98 | ||
|
|
a651c2cb72 | ||
|
|
2261fd4b84 | ||
|
|
717f959c04 | ||
|
|
3e1899ee17 | ||
|
|
7d12d89a0a | ||
|
|
c0a6e94b21 | ||
|
|
1e14ba48f9 | ||
|
|
b8f15feca4 | ||
|
|
b77aa3908f | ||
|
|
2c1ed36a91 | ||
|
|
5b89eca5e9 | ||
|
|
0956ae10a0 | ||
|
|
7175f1cbf1 | ||
|
|
384ab80c42 | ||
|
|
f534d98e8b | ||
|
|
3a9dc1a36d | ||
|
|
f9ef7b783b | ||
|
|
65a2ae8428 | ||
|
|
5ce112d431 | ||
|
|
9d60cb50ed | ||
|
|
584043deee | ||
|
|
c4a85e3b82 | ||
|
|
1b54313615 | ||
|
|
42fce1929c | ||
|
|
d96f85ac83 | ||
|
|
e3c770ca4a | ||
|
|
d7454b100a | ||
|
|
ee9cf60aa2 | ||
|
|
3a446dc240 | ||
|
|
8cf2b06e53 | ||
|
|
0184375ad1 | ||
|
|
b805633dc9 | ||
|
|
638a774fc9 | ||
|
|
b33a3293fe | ||
|
|
802fe9beae | ||
|
|
78f56ba875 | ||
|
|
c29975f6b3 | ||
|
|
ce03690989 | ||
|
|
b1c6f2d1c3 | ||
|
|
f380d4b27d | ||
|
|
f19da7af8c | ||
|
|
0013f3a31c | ||
|
|
a45f64e738 | ||
|
|
a29c0dfce9 | ||
|
|
c4e6c91986 | ||
|
|
03a81bd8b1 | ||
|
|
6945283fec | ||
|
|
113b48d046 | ||
|
|
cc9c6e4f42 | ||
|
|
97feef8909 | ||
|
|
db4f38c75b | ||
|
|
99852c3cab | ||
|
|
b6cb879ad1 | ||
|
|
f9fbbc12a6 | ||
|
|
59bb3c66d6 | ||
|
|
dc9ec22156 | ||
|
|
b8875e126f | ||
|
|
26ed978cf9 | ||
|
|
bd511cb9f3 | ||
|
|
20ea6433e6 | ||
|
|
16444e023a | ||
|
|
9c579e3596 | ||
|
|
4710431e6b | ||
|
|
f1e909278c | ||
|
|
8d3613e8b4 | ||
|
|
3fd3e408fc | ||
|
|
a2fcc59648 | ||
|
|
223e9c4747 | ||
|
|
b63f7a7416 | ||
|
|
905d3e6e1e | ||
|
|
90a0eca2f5 | ||
|
|
7658789971 | ||
|
|
9257c8205f | ||
|
|
b117f74666 | ||
|
|
3b35d7dfe4 | ||
|
|
29c0f7156b | ||
|
|
0d2ed8f112 | ||
|
|
99a6b1bcc0 | ||
|
|
da4cdf2d3b | ||
|
|
26cc62cff7 | ||
|
|
b1992714ed | ||
|
|
ecca7a3ea9 | ||
|
|
4b84d9bfe5 | ||
|
|
92b1932fcf | ||
|
|
9a6e404215 | ||
|
|
939ad11eae | ||
|
|
6785c49734 | ||
|
|
45c51481de | ||
|
|
874bd7b2b8 | ||
|
|
fc6dd83f2f | ||
|
|
a8129874fb | ||
|
|
c7d5905242 | ||
|
|
02d3620d93 | ||
|
|
b304e3fe40 | ||
|
|
06a66cf24e | ||
|
|
145e3ece78 | ||
|
|
24e361da77 | ||
|
|
1b9614eb9d | ||
|
|
791033d751 | ||
|
|
9748709759 | ||
|
|
b885743efe | ||
|
|
8ec92405fd | ||
|
|
e68ab95ecb | ||
|
|
d2dbc73448 | ||
|
|
4a5a8dd773 | ||
|
|
439dfcb172 | ||
|
|
f6a4ea6b0f | ||
|
|
8681e0228d | ||
|
|
c1123cb3e9 | ||
|
|
d64590a12b | ||
|
|
e274a0c7d1 | ||
|
|
51fe1e20e8 | ||
|
|
9c4ffae1b3 | ||
|
|
3d0c6cf41e | ||
|
|
3800d3b2b1 | ||
|
|
da54236f5a | ||
|
|
c930d84d01 | ||
|
|
2317f779e9 | ||
|
|
c501e70512 | ||
|
|
8357d90e59 | ||
|
|
efef6261b8 | ||
|
|
95b7a5d4fe | ||
|
|
2c55c7ca82 | ||
|
|
02dda51269 | ||
|
|
083cb848f2 | ||
|
|
254da0b170 | ||
|
|
8b0b9eafb8 | ||
|
|
04e2f18ff1 | ||
|
|
a4783a2c19 | ||
|
|
8fb6f26729 | ||
|
|
0e7ffa677a | ||
|
|
a668f09522 | ||
|
|
2598e22422 | ||
|
|
dc6a9c6348 | ||
|
|
b1667259f0 | ||
|
|
c77b451863 | ||
|
|
9e48460940 | ||
|
|
3972e9150e | ||
|
|
0c8ba71edd | ||
|
|
a7bb331412 | ||
|
|
6f1c9d88cc | ||
|
|
e2d7c7aea5 | ||
|
|
dc0645725e | ||
|
|
06e0bdbfbb | ||
|
|
14db418519 | ||
|
|
d5e1a9d7d0 | ||
|
|
ccb7fac25e | ||
|
|
bbe9a9c191 | ||
|
|
4ee67986a5 | ||
|
|
0a657acbd8 | ||
|
|
d41feb63e3 | ||
|
|
b745e304a2 | ||
|
|
2a7f577366 | ||
|
|
73d301e63f | ||
|
|
fbfdd80f9b | ||
|
|
2d0ff5f8a2 | ||
|
|
ba7bd21cd7 | ||
|
|
16230549b7 | ||
|
|
03c6263e58 | ||
|
|
e54148033b | ||
|
|
f75cddfe53 | ||
|
|
ee63db8811 | ||
|
|
620eebd754 | ||
|
|
ec481415f9 |
32
2bld.cmd
Normal file
32
2bld.cmd
Normal file
@@ -0,0 +1,32 @@
|
||||
@echo off
|
||||
|
||||
rem build TiddlyWiki 2.x
|
||||
|
||||
rem create a temporary directory if it doesn't already exist
|
||||
setlocal enableextensions
|
||||
mkdir tmp\tw2
|
||||
setlocal disableextensions
|
||||
|
||||
rem Delete any existing content
|
||||
|
||||
del /q /s tmp\tw2
|
||||
echo.
|
||||
|
||||
rem Prepare the readme file from the revelant content in the tw5.com wiki
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
editions\tw5.com ^
|
||||
--verbose ^
|
||||
--rendertiddler TiddlyWiki2ReadMe editions\tw2\readme.md text/html ^
|
||||
|| exit 1
|
||||
|
||||
rem cook the TiddlyWiki 2.x.x index file
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
editions\tw2 ^
|
||||
--verbose ^
|
||||
--load editions\tw2\source\tiddlywiki.com\index.html.recipe ^
|
||||
--rendertiddler $:/core/templates/tiddlywiki2.template.html .\tmp\tw2\index.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
fc tmp\tw2\index.html editions\tw2\target\prebuilt.html
|
||||
94
bld.cmd
Normal file
94
bld.cmd
Normal file
@@ -0,0 +1,94 @@
|
||||
@echo off
|
||||
|
||||
rem build TiddlyWiki5 for five.tiddlywiki.com
|
||||
|
||||
rem Set up the build output directory
|
||||
|
||||
if "x%TW5_BUILD_OUTPUT%" == "x" (
|
||||
set TW5_BUILD_OUTPUT=..\jermolene.github.com
|
||||
)
|
||||
|
||||
if not exist %TW5_BUILD_OUTPUT%\nul (
|
||||
echo A valid TW5_BUILD_OUTPUT environment variable must be set
|
||||
exit 1
|
||||
)
|
||||
|
||||
echo Using TW5_BUILD_OUTPUT as %TW5_BUILD_OUTPUT%
|
||||
echo.
|
||||
|
||||
rem Create the `static` directories if necessary
|
||||
|
||||
setlocal enableextensions
|
||||
mkdir %TW5_BUILD_OUTPUT%\static
|
||||
setlocal disableextensions
|
||||
|
||||
rem Delete any existing content
|
||||
|
||||
del /q /s %TW5_BUILD_OUTPUT%\static
|
||||
|
||||
rem The tw5.com wiki
|
||||
rem index.html: the main file, including content
|
||||
rem empty.html: the main file, excluding content
|
||||
rem static.html: the static version of the default tiddlers
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\tw5.com ^
|
||||
--verbose ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\index.html text/plain ^
|
||||
--rendertiddler ReadMe .\readme.md text/html ^
|
||||
--rendertiddler ContributingTemplate .\contributing.md text/html ^
|
||||
--rendertiddler $:/editions/tw5.com/download-empty %TW5_BUILD_OUTPUT%\empty.html text/plain ^
|
||||
--rendertiddler $:/core/templates/static.template.html %TW5_BUILD_OUTPUT%\static.html text/plain ^
|
||||
--rendertiddler $:/core/templates/static.template.css %TW5_BUILD_OUTPUT%\static\static.css text/plain ^
|
||||
--rendertiddlers [!is[system]] $:/core/templates/static.tiddler.html %TW5_BUILD_OUTPUT%\static text/plain ^
|
||||
|| exit 1
|
||||
|
||||
rem encrypted.html: a version of the main file encrypted with the password "password"
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\tw5.com ^
|
||||
--verbose ^
|
||||
--password password ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\encrypted.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
rem tahoelafs.html: empty wiki with plugin for Tahoe-LAFS
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\tahoelafs ^
|
||||
--verbose ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\tahoelafs.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
rem d3demo.html: wiki to demo d3 plugin
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\d3demo ^
|
||||
--verbose ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\d3demo.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
rem codemirrordemo.html: wiki to demo codemirror plugin
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\codemirrordemo ^
|
||||
--verbose ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\codemirrordemo.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
rem markdowndemo.html: wiki to demo markdown plugin
|
||||
|
||||
node .\tiddlywiki.js ^
|
||||
.\editions\markdowndemo ^
|
||||
--verbose ^
|
||||
--rendertiddler $:/core/save/all %TW5_BUILD_OUTPUT%\markdowndemo.html text/plain ^
|
||||
|| exit 1
|
||||
|
||||
|
||||
rem Make the CNAME file that GitHub Pages requires
|
||||
|
||||
echo five.tiddlywiki.com > %TW5_BUILD_OUTPUT%\CNAME
|
||||
|
||||
rem Run the test edition to run the Node.js tests and to generate test.html for tests in the browser
|
||||
|
||||
.\test.cmd
|
||||
39
bld.sh
39
bld.sh
@@ -19,7 +19,7 @@ echo "Using TW5_BUILD_OUTPUT as [$TW5_BUILD_OUTPUT]"
|
||||
|
||||
echo "five.tiddlywiki.com" > $TW5_BUILD_OUTPUT/CNAME
|
||||
|
||||
# Create the `static` directory if necessary
|
||||
# Create the `static` directories if necessary
|
||||
|
||||
mkdir -p $TW5_BUILD_OUTPUT/static
|
||||
|
||||
@@ -27,71 +27,64 @@ mkdir -p $TW5_BUILD_OUTPUT/static
|
||||
|
||||
rm $TW5_BUILD_OUTPUT/static/*
|
||||
|
||||
# First,
|
||||
# readme.md: the readme file for GitHub
|
||||
# The tw5.com wiki
|
||||
# index.html: the main file, including content
|
||||
# empty.html: the main file, excluding content
|
||||
# static.html: the static version of the default tiddlers
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/tw5.com \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/index.html text/plain \
|
||||
--rendertiddler ReadMe ./readme.md text/html \
|
||||
--rendertiddler ContributingTemplate ./contributing.md text/html \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/index.html text/plain \
|
||||
--rendertiddler $:/editions/tw5.com/download-empty $TW5_BUILD_OUTPUT/empty.html text/plain \
|
||||
--rendertiddler $:/core/templates/static.template.html $TW5_BUILD_OUTPUT/static.html text/plain \
|
||||
--rendertiddler $:/core/templates/static.template.css $TW5_BUILD_OUTPUT/static/static.css text/plain \
|
||||
--rendertiddlers [!is[system]] $:/core/templates/static.tiddler.html $TW5_BUILD_OUTPUT/static text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Second, encrypted.html: a version of the main file encrypted with the password "password"
|
||||
# encrypted.html: a version of the main file encrypted with the password "password"
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/tw5.com \
|
||||
--verbose \
|
||||
--password password \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/encrypted.html text/plain \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/encrypted.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Third, empty.html: empty wiki for reuse
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/empty \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/empty.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Fourth, tahoelafs.html: empty wiki with plugin for Tahoe-LAFS
|
||||
# tahoelafs.html: empty wiki with plugin for Tahoe-LAFS
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/tahoelafs \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/tahoelafs.html text/plain \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/tahoelafs.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Fifth, d3demo.html: wiki to demo d3 plugin
|
||||
# d3demo.html: wiki to demo d3 plugin
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/d3demo \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/d3demo.html text/plain \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/d3demo.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Sixth, codemirrordemo.html: wiki to demo codemirror plugin
|
||||
# codemirrordemo.html: wiki to demo codemirror plugin
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/codemirrordemo \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/codemirrordemo.html text/plain \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/codemirrordemo.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Seventh, codemirrordemo.html: wiki to demo codemirror plugin
|
||||
# markdowndemo.html: wiki to demo markdown plugin
|
||||
|
||||
node ./tiddlywiki.js \
|
||||
./editions/markdowndemo \
|
||||
--verbose \
|
||||
--rendertiddler $:/core/templates/tiddlywiki5.template.html $TW5_BUILD_OUTPUT/markdowndemo.html text/plain \
|
||||
--rendertiddler $:/core/save/all $TW5_BUILD_OUTPUT/markdowndemo.html text/plain \
|
||||
|| exit 1
|
||||
|
||||
# Eighth, run the test edition to run the node.js tests and to generate test.html for tests in the browser
|
||||
# Run the test edition to run the Node.js tests and to generate test.html for tests in the browser
|
||||
|
||||
./test.sh
|
||||
|
||||
41
boot/boot.js
41
boot/boot.js
@@ -225,17 +225,18 @@ $tw.utils.pad = function(value,length) {
|
||||
return s;
|
||||
};
|
||||
|
||||
// Convert a date into UTC YYYYMMDDHHMM format
|
||||
// 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
|
||||
// Parse a date from a UTC YYYYMMDDHHMMSSmmm format string
|
||||
$tw.utils.parseDate = function(value) {
|
||||
if(typeof value === "string") {
|
||||
return new Date(Date.UTC(parseInt(value.substr(0,4),10),
|
||||
@@ -343,14 +344,35 @@ $tw.utils.resolvePath = function(sourcepath,rootpath) {
|
||||
};
|
||||
|
||||
/*
|
||||
Returns true if the `actual` version is greater than or equal to the `required` version. Both are in `x.y.z` format.
|
||||
Parse a semantic version string into its constituent parts
|
||||
*/
|
||||
$tw.utils.checkVersions = function(required,actual) {
|
||||
var targetVersion = required.split("."),
|
||||
currVersion = actual.split("."),
|
||||
diff = [parseInt(targetVersion[0],10) - parseInt(currVersion[0],10),
|
||||
parseInt(targetVersion[1],10) - parseInt(currVersion[1],10),
|
||||
parseInt(targetVersion[2],10) - parseInt(currVersion[2],10)];
|
||||
$tw.utils.parseVersion = function(version) {
|
||||
var match = /^((\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 true if the version string A is greater than the version string B
|
||||
*/
|
||||
$tw.utils.checkVersions = function(versionStringA,versionStringB) {
|
||||
var versionA = $tw.utils.parseVersion(versionStringA),
|
||||
versionB = $tw.utils.parseVersion(versionStringB),
|
||||
diff = [
|
||||
versionA.major - versionB.major,
|
||||
versionA.minor - versionB.minor,
|
||||
versionA.patch - versionB.patch
|
||||
];
|
||||
return (diff[0] > 0) ||
|
||||
(diff[0] === 0 && diff[1] > 0) ||
|
||||
(diff[0] === 0 && diff[1] === 0 && diff[2] > 0);
|
||||
@@ -554,6 +576,7 @@ $tw.modules.execute = function(moduleName,moduleRoot) {
|
||||
clearInterval: clearInterval,
|
||||
setTimeout: setTimeout,
|
||||
clearTimeout: clearTimeout,
|
||||
Buffer: $tw.browser ? {} : Buffer,
|
||||
$tw: $tw,
|
||||
require: function(title) {
|
||||
return $tw.modules.execute(title, name);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<h1 class=''>Contributing to <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a></h1><p><a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a> welcomes contributions to its code and documentation via <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5' target='_blank'>GitHub</a>. Please take a moment to read these notes to help make the process as smooth as possible.</p><h2 class=''>Bug Reports</h2><p>From the perspective of the developers, a bug report that says little more than "it doesn't work" can be frustrating. For effective debugging, we need as much information as possible. At a minimum, please try to include:</p><ul><li>A descriptive title</li><li>A summary</li><li>Steps to reproduce</li><li>Expected behaviour</li><li>Context (OS, browser etc.)</li></ul><p>There's a lot of good material on the web about bug reports:</p><ul><li><a class='tw-tiddlylink-external' href='http://mhay68.tumblr.com/post/1648223018/what-makes-a-good-bug-report' target='_blank'>http://mhay68.tumblr.com/post/1648223018/what-makes-a-good-bug-report</a></li><li><a class='tw-tiddlylink-external' href='http://www.chiark.greenend.org.uk/~sgtatham/bugs.html' target='_blank'>http://www.chiark.greenend.org.uk/~sgtatham/bugs.html</a></li></ul><h2 class=''>Pull Requests</h2><p>Like other <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/OpenSource.html'>OpenSource</a> projects, <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a> needs a signed contributor license agreement from individual contributors before contributions of code can be accepted. This is a legal agreement that allows contributors to assert that they own the copyright of their contribution, and that they agree to license it to the <a class=' tw-tiddlylink tw-tiddlylink-missing' href='http://five.tiddlywiki.com/static/UnaMesa.html'>UnaMesa</a> Association (the legal entity that owns <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki.html'>TiddlyWiki</a> on behalf of the community).</p><ul><li>For individuals use: <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5/tree/master/licenses/cla-individual.md' target='_blank'>CLA-individual</a></li><li>For entities use: <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5/tree/master/licenses/cla-entity.md' target='_blank'>CLA-entity</a></li></ul><p><em>This is a first pass at a CLA for <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki.html'>TiddlyWiki</a>. Please let us know if we missed something important. If we do have to make essential changes to the CLA, there is a possibility that all contributors will need to sign it again</em></p><h3 class=''>How to sign the CLA</h3><pre>git clone https://github.com/Jermolene/TiddlyWiki5.git TiddlyWiki5
|
||||
<h1 class=''>Contributing to <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a></h1><p><a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a> welcomes contributions to its code and documentation via <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5' target='_blank'>GitHub</a>. Please take a moment to read these notes to help make the process as smooth as possible.</p><h2 class=''>Bug Reports</h2><p>From the perspective of the developers, a bug report that says little more than "it doesn't work" can be frustrating. For effective debugging, we need as much information as possible. At a minimum, please try to include:</p><ul><li>A descriptive title</li><li>A summary</li><li>Steps to reproduce</li><li>Expected behaviour</li><li>Context (OS, browser etc.)</li></ul><p>There's a lot of good material on the web about bug reports:</p><ul><li><a class='tw-tiddlylink-external' href='http://mhay68.tumblr.com/post/1648223018/what-makes-a-good-bug-report' target='_blank'>http://mhay68.tumblr.com/post/1648223018/what-makes-a-good-bug-report</a></li><li><a class='tw-tiddlylink-external' href='http://www.chiark.greenend.org.uk/~sgtatham/bugs.html' target='_blank'>http://www.chiark.greenend.org.uk/~sgtatham/bugs.html</a></li></ul><h2 class=''>Pull Requests</h2><p>Like other <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/OpenSource.html'>OpenSource</a> projects, <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki5.html'>TiddlyWiki5</a> needs a signed contributor license agreement from individual contributors before contributions of code can be accepted. This is a legal agreement that allows contributors to assert that they own the copyright of their contribution, and that they agree to license it to the <a class=' tw-tiddlylink tw-tiddlylink-missing' href='http://five.tiddlywiki.com/static/UnaMesa.html'>UnaMesa</a> Association (the legal entity that owns <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki.html'>TiddlyWiki</a> on behalf of the community).</p><ul><li>For individuals use: <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5/tree/master/licenses/cla-individual.md' target='_blank'>licenses/CLA-individual</a></li><li>For entities use: <a class='tw-tiddlylink-external' href='https://github.com/Jermolene/TiddlyWiki5/tree/master/licenses/cla-entity.md' target='_blank'>licenses/CLA-entity</a></li></ul><p><em>This is a first pass at a CLA for <a class=' tw-tiddlylink tw-tiddlylink-resolves' href='http://five.tiddlywiki.com/static/TiddlyWiki.html'>TiddlyWiki</a>. Please let us know if we missed something important. If we do have to make essential changes to the CLA, there is a possibility that all contributors will need to sign it again</em></p><h3 class=''>How to sign the CLA</h3><pre>git clone https://github.com/Jermolene/TiddlyWiki5.git TiddlyWiki5
|
||||
cd TiddlyWiki5
|
||||
git checkout -b sign-cla</pre><p><strong>Add your name and the date to cla-individual.md or cla-entity.md</strong>. Date format (YYYY/MM/DD)
|
||||
eg: <code>Jeremy Ruston, @Jermolene, 2011/11/22</code></p><pre>git add .
|
||||
|
||||
3
core/docs/types/application_json.tid
Normal file
3
core/docs/types/application_json.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/application/json
|
||||
description: JSON data
|
||||
name: application/json
|
||||
3
core/docs/types/application_x_tiddler_dictionary.tid
Normal file
3
core/docs/types/application_x_tiddler_dictionary.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/application/x-tiddler-dictionary
|
||||
description: Data dictionary
|
||||
name: application/x-tiddler-dictionary
|
||||
3
core/docs/types/image_gif.tid
Normal file
3
core/docs/types/image_gif.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/image/gif
|
||||
description: GIF image
|
||||
name: image/gif
|
||||
3
core/docs/types/image_jpeg.tid
Normal file
3
core/docs/types/image_jpeg.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/image/jpeg
|
||||
description: JPEG image
|
||||
name: image/jpeg
|
||||
3
core/docs/types/image_png.tid
Normal file
3
core/docs/types/image_png.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/image/png
|
||||
description: PNG image
|
||||
name: image/png
|
||||
3
core/docs/types/image_svg_xml.tid
Normal file
3
core/docs/types/image_svg_xml.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/image/svg+xml
|
||||
description: Structured Vector Graphics image
|
||||
name: image/svg+xml
|
||||
3
core/docs/types/text_plain.tid
Normal file
3
core/docs/types/text_plain.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/text/plain
|
||||
description: Plain text
|
||||
name: text/plain
|
||||
3
core/docs/types/text_vnd.tiddlywiki.tid
Normal file
3
core/docs/types/text_vnd.tiddlywiki.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/docs/types/text/vnd.tiddlywiki
|
||||
description: TW5 wikitext
|
||||
name: text/vnd.tiddlywiki
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/cancel-button
|
||||
|
||||
<svg class="tw-image-cancel-button" viewBox="366 150 58 58" width="22pt" height="22pt"><path d="M 414.76236 158.98764 C 403.77887 148.0041 385.97113 148.0041 374.98764 158.98764 C 364.0041 169.97113 364.0041 187.77887 374.98764 198.76236 C 385.97113 209.7459 403.77887 209.7459 414.76236 198.76236 C 425.7459 187.77887 425.7459 169.97113 414.76236 158.98764 M 385.3967 165.32954 L 385.3967 165.32954 L 394.77674 174.7096 L 404.3533 165.13303 C 405.53068 163.95566 407.4396 163.95566 408.61697 165.13303 C 409.79434 166.31041 409.79434 168.21932 408.61697 169.39669 L 399.0404 178.97325 L 408.42046 188.35331 C 409.59783 189.53068 409.59783 191.43959 408.42046 192.61697 L 408.42046 192.61697 C 407.24308 193.79434 405.33417 193.79434 404.1568 192.61697 L 394.77675 183.23692 L 385.5932 192.42046 C 384.41583 193.59783 382.50692 193.59783 381.32954 192.42046 L 381.32954 192.42046 C 380.15217 191.24308 380.15217 189.33417 381.32954 188.1568 C 381.32954 188.1568 381.32954 188.1568 381.32954 188.1568 L 381.32954 188.1568 L 381.32954 188.1568 L 390.51309 178.97326 L 381.13303 169.5932 C 379.95566 168.41583 379.95566 166.50692 381.13303 165.32954 L 381.13303 165.32954 C 382.3104 164.15217 384.21932 164.15217 385.3967 165.32954 C 385.3967 165.32954 385.3967 165.32954 385.3967 165.32954 Z"/></svg>
|
||||
<svg class="tw-image-cancel-button tw-image-button" viewBox="366 150 58 58" width="22pt" height="22pt"><path d="M 414.76236 158.98764 C 403.77887 148.0041 385.97113 148.0041 374.98764 158.98764 C 364.0041 169.97113 364.0041 187.77887 374.98764 198.76236 C 385.97113 209.7459 403.77887 209.7459 414.76236 198.76236 C 425.7459 187.77887 425.7459 169.97113 414.76236 158.98764 M 385.3967 165.32954 L 385.3967 165.32954 L 394.77674 174.7096 L 404.3533 165.13303 C 405.53068 163.95566 407.4396 163.95566 408.61697 165.13303 C 409.79434 166.31041 409.79434 168.21932 408.61697 169.39669 L 399.0404 178.97325 L 408.42046 188.35331 C 409.59783 189.53068 409.59783 191.43959 408.42046 192.61697 L 408.42046 192.61697 C 407.24308 193.79434 405.33417 193.79434 404.1568 192.61697 L 394.77675 183.23692 L 385.5932 192.42046 C 384.41583 193.59783 382.50692 193.59783 381.32954 192.42046 L 381.32954 192.42046 C 380.15217 191.24308 380.15217 189.33417 381.32954 188.1568 C 381.32954 188.1568 381.32954 188.1568 381.32954 188.1568 L 381.32954 188.1568 L 381.32954 188.1568 L 390.51309 178.97326 L 381.13303 169.5932 C 379.95566 168.41583 379.95566 166.50692 381.13303 165.32954 L 381.13303 165.32954 C 382.3104 164.15217 384.21932 164.15217 385.3967 165.32954 C 385.3967 165.32954 385.3967 165.32954 385.3967 165.32954 Z"/></svg>
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/close-button
|
||||
|
||||
<svg class="tw-image-close-button" viewBox="222 150 56 56" width="22pt" height="22pt"><path d="M 249.56668 185.88827 L 267.06757 203.38916 C 269.26427 205.58586 272.82582 205.58586 275.02252 203.38916 L 275.02252 203.38916 C 277.21922 201.19246 277.21922 197.63091 275.02252 195.43421 L 257.52163 177.93332 L 275.38916 160.06579 C 277.58586 157.86909 277.58586 154.30754 275.38916 152.11084 C 273.19246 149.91414 269.63091 149.91414 267.43421 152.11084 L 249.56668 169.97837 L 232.06579 152.47748 L 232.06579 152.47748 C 232.06579 152.47748 232.06579 152.47748 232.06579 152.47748 C 229.86909 150.28078 226.30754 150.28078 224.11084 152.47748 L 224.11084 152.47748 C 221.91414 154.674175 221.91414 158.23573 224.11084 160.43243 L 241.61173 177.93332 L 224.47748 195.06757 L 224.47748 195.06757 L 224.47748 195.06757 C 224.47748 195.06757 224.47748 195.06757 224.47748 195.06757 C 222.28078 197.26427 222.28078 200.82583 224.47748 203.02252 L 224.47748 203.02252 C 226.67418 205.21922 230.23573 205.21922 232.43243 203.02252 Z"/></svg>
|
||||
<svg class="tw-image-close-button tw-image-button" viewBox="222 150 56 56" width="22pt" height="22pt"><path d="M 249.56668 185.88827 L 267.06757 203.38916 C 269.26427 205.58586 272.82582 205.58586 275.02252 203.38916 L 275.02252 203.38916 C 277.21922 201.19246 277.21922 197.63091 275.02252 195.43421 L 257.52163 177.93332 L 275.38916 160.06579 C 277.58586 157.86909 277.58586 154.30754 275.38916 152.11084 C 273.19246 149.91414 269.63091 149.91414 267.43421 152.11084 L 249.56668 169.97837 L 232.06579 152.47748 L 232.06579 152.47748 C 232.06579 152.47748 232.06579 152.47748 232.06579 152.47748 C 229.86909 150.28078 226.30754 150.28078 224.11084 152.47748 L 224.11084 152.47748 C 221.91414 154.674175 221.91414 158.23573 224.11084 160.43243 L 241.61173 177.93332 L 224.47748 195.06757 L 224.47748 195.06757 L 224.47748 195.06757 C 224.47748 195.06757 224.47748 195.06757 224.47748 195.06757 C 222.28078 197.26427 222.28078 200.82583 224.47748 203.02252 L 224.47748 203.02252 C 226.67418 205.21922 230.23573 205.21922 232.43243 203.02252 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/delete-button
|
||||
|
||||
<svg class="tw-image-delete-button" viewBox="303 155 39 50" width="17pt" height="22pt"><path d="M 333 164.25 L 333 157.25 C 333 156.14543 332.10457 155.25 331 155.25 L 314.75 155.25 C 314.75 155.25 314.75 155.25 314.75 155.25 C 313.64543 155.25 312.75 156.14543 312.75 157.25 L 312.75 164.25 L 303.75 164.25 L 303.75 168.75 L 306 168.75 L 306 201.75 L 306 201.75 L 306 201.75 C 306 203.40685 307.34315 204.75 309 204.75 L 336.75 204.75 C 338.40685 204.75 339.75 203.40685 339.75 201.75 L 339.75 168.75 L 342 168.75 L 342 164.25 Z M 317.25 160.75 L 317.25 160.75 C 317.25 160.19772 317.69772 159.75 318.25 159.75 C 318.25 159.75 318.25 159.75 318.25 159.75 L 327.5 159.75 C 328.05228 159.75 328.5 160.19772 328.5 160.75 L 328.5 164.25 L 317.25 164.25 L 317.25 160.75 Z M 310.5 168.75 L 312.75 168.75 L 312.75 200.25 L 310.5 200.25 Z M 317.25 168.75 L 319.5 168.75 L 319.5 200.25 L 317.25 200.25 Z M 324 168.75 L 326.25 168.75 L 326.25 200.25 L 324 200.25 Z M 330.75 168.75 L 333 168.75 L 333 200.25 L 330.75 200.25 Z"/></svg>
|
||||
<svg class="tw-image-delete-button tw-image-button" viewBox="303 155 39 50" width="17pt" height="22pt"><path d="M 333 164.25 L 333 157.25 C 333 156.14543 332.10457 155.25 331 155.25 L 314.75 155.25 C 314.75 155.25 314.75 155.25 314.75 155.25 C 313.64543 155.25 312.75 156.14543 312.75 157.25 L 312.75 164.25 L 303.75 164.25 L 303.75 168.75 L 306 168.75 L 306 201.75 L 306 201.75 L 306 201.75 C 306 203.40685 307.34315 204.75 309 204.75 L 336.75 204.75 C 338.40685 204.75 339.75 203.40685 339.75 201.75 L 339.75 168.75 L 342 168.75 L 342 164.25 Z M 317.25 160.75 L 317.25 160.75 C 317.25 160.19772 317.69772 159.75 318.25 159.75 C 318.25 159.75 318.25 159.75 318.25 159.75 L 327.5 159.75 C 328.05228 159.75 328.5 160.19772 328.5 160.75 L 328.5 164.25 L 317.25 164.25 L 317.25 160.75 Z M 310.5 168.75 L 312.75 168.75 L 312.75 200.25 L 310.5 200.25 Z M 317.25 168.75 L 319.5 168.75 L 319.5 200.25 L 317.25 200.25 Z M 324 168.75 L 326.25 168.75 L 326.25 200.25 L 324 200.25 Z M 330.75 168.75 L 333 168.75 L 333 200.25 L 330.75 200.25 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/done-button
|
||||
|
||||
<svg class="tw-image-done-button" viewBox="434 150 68 55" width="22pt" height="18pt"><path d="M 438.49266 178.00797 L 439.00744 177.49319 C 441.35054 175.15008 445.14946 175.15004 447.49262 177.49309 L 452.50734 182.50757 C 454.8505 184.85063 458.6494 184.85058 460.99252 182.50748 L 488.50747 154.99255 C 490.85058 152.64944 494.6495 152.6494 496.99266 154.99246 L 497.50722 155.506995 C 499.8504 157.85009 499.8505 161.64908 497.5074 163.99228 C 497.50738 163.99229 497.50736 163.99231 497.50734 163.99233 L 460.9926 200.5077 C 458.64947 202.85087 454.85048 202.8509 452.50732 200.50778 C 452.5073 200.50777 452.5073 200.50777 452.5073 200.50776 L 438.49268 186.49327 C 436.14952 184.15013 436.1495 180.35114 438.49264 178.00799 C 438.49265 178.00798 438.49265 178.00797 438.49266 178.00797 Z"/></svg>
|
||||
<svg class="tw-image-done-button tw-image-button" viewBox="434 150 68 55" width="22pt" height="18pt"><path d="M 438.49266 178.00797 L 439.00744 177.49319 C 441.35054 175.15008 445.14946 175.15004 447.49262 177.49309 L 452.50734 182.50757 C 454.8505 184.85063 458.6494 184.85058 460.99252 182.50748 L 488.50747 154.99255 C 490.85058 152.64944 494.6495 152.6494 496.99266 154.99246 L 497.50722 155.506995 C 499.8504 157.85009 499.8505 161.64908 497.5074 163.99228 C 497.50738 163.99229 497.50736 163.99231 497.50734 163.99233 L 460.9926 200.5077 C 458.64947 202.85087 454.85048 202.8509 452.50732 200.50778 C 452.5073 200.50777 452.5073 200.50777 452.5073 200.50776 L 438.49268 186.49327 C 436.14952 184.15013 436.1495 180.35114 438.49264 178.00799 C 438.49265 178.00798 438.49265 178.00797 438.49266 178.00797 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/down-arrow
|
||||
|
||||
<svg class="tw-image-down-arrow" viewBox="441 306 59 45" width="24pt" height="22pt"><path d="M 441 306 L 470.25 351 L 499.5 306 Z"/></svg>
|
||||
<svg class="tw-image-down-arrow tw-image-button" viewBox="441 306 59 45" width="24pt" height="22pt"><path d="M 441 306 L 470.25 351 L 499.5 306 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/edit-button
|
||||
|
||||
<svg class="tw-image-edit-button" viewBox="244 193 20 22" width="20pt" height="22pt"><path d="M 257.33334 196.80951 L 245.90476 207.2857 L 244 212.0476 L 248.7619 210.14284 L 260.19048 199.66665 Z M 259.2381 194.90475 L 258.28566 195.85716 L 261.14284 198.71428 L 262.09522 197.76187 Z M 261.14286 193 L 260.19042 193.95241 L 263.04762 196.80953 L 264 195.85714 Z M 244 213.72882 C 244 213.72882 247.4281 215.43353 250.8572 213.7288 C 254.28599 212.02405 261.14284 214.86531 261.14284 214.86531 L 261.14284 213.72884 C 261.14284 213.72884 254.28577 210.88755 250.8572 212.5923 C 247.42858 214.29712 244 212.59228 244 212.59228 Z"/></svg>
|
||||
<svg class="tw-image-edit-button tw-image-button" viewBox="244 193 20 22" width="20pt" height="22pt"><path d="M 257.33334 196.80951 L 245.90476 207.2857 L 244 212.0476 L 248.7619 210.14284 L 260.19048 199.66665 Z M 259.2381 194.90475 L 258.28566 195.85716 L 261.14284 198.71428 L 262.09522 197.76187 Z M 261.14286 193 L 260.19042 193.95241 L 263.04762 196.80953 L 264 195.85714 Z M 244 213.72882 C 244 213.72882 247.4281 215.43353 250.8572 213.7288 C 254.28599 212.02405 261.14284 214.86531 261.14284 214.86531 L 261.14284 213.72884 C 261.14284 213.72884 254.28577 210.88755 250.8572 212.5923 C 247.42858 214.29712 244 212.59228 244 212.59228 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/info-button
|
||||
|
||||
<svg class="tw-image-info-button" viewBox="294 150 58 58" width="22pt" height="22pt"><path d="M 342.76236 158.98764 C 331.77887 148.0041 313.97113 148.0041 302.98764 158.98764 C 292.0041 169.97113 292.0041 187.77887 302.98764 198.76236 C 313.97113 209.7459 331.77887 209.7459 342.76236 198.76236 C 353.7459 187.77887 353.7459 169.97113 342.76236 158.98764 M 326.5425 157.5 L 326.5425 157.5 C 327.72545 157.5 328.72201 157.91022 329.5337 158.73088 C 330.34465 159.55157 330.75 160.54402 330.75 161.7075 C 330.75 162.87172 330.33979 163.86316 329.51911 164.68385 C 328.69842 165.5045 327.70674 165.91501 326.5425 165.91501 C 325.39801 165.91501 324.4153 165.5045 323.5946 164.68385 C 322.77393 163.86316 322.36372 162.87172 322.36372 161.7075 C 322.36372 160.54402 322.76906 159.55157 323.58 158.73088 C 324.39171 157.91022 325.3793 157.5 326.5425 157.5 Z M 327.80211 190.47259 C 324.91945 195.49132 321.85778 198 318.61462 198 C 317.37452 198 316.38691 197.65158 315.65186 196.9555 C 314.9176 196.25866 314.54943 195.37617 314.54943 194.30782 C 314.54943 193.60202 314.71223 192.70572 315.03629 191.61813 L 319.0151 177.93651 C 319.39685 176.61922 319.58735 175.62754 319.58735 174.95991 C 319.58735 174.53996 319.40582 174.16692 319.04356 173.84286 C 318.68052 173.51905 318.18469 173.35701 317.55527 173.35701 C 317.26861 173.35701 316.92506 173.36677 316.5246 173.38548 L 316.89661 172.2407 L 326.59967 170.66627 L 328.31744 170.66627 L 322.44986 191.01638 C 322.12503 192.18064 321.963 192.94337 321.963 193.30666 C 321.963 193.51588 322.04862 193.71121 322.2204 193.89273 C 322.39218 194.07425 322.5737 194.16554 322.7642 194.16477 C 323.08903 194.16554 323.4131 194.02221 323.73792 193.73559 C 324.59605 193.02976 325.6267 191.75142 326.82838 189.90008 Z"/></svg>
|
||||
<svg class="tw-image-info-button tw-image-button" viewBox="294 150 58 58" width="22pt" height="22pt"><path d="M 342.76236 158.98764 C 331.77887 148.0041 313.97113 148.0041 302.98764 158.98764 C 292.0041 169.97113 292.0041 187.77887 302.98764 198.76236 C 313.97113 209.7459 331.77887 209.7459 342.76236 198.76236 C 353.7459 187.77887 353.7459 169.97113 342.76236 158.98764 M 326.5425 157.5 L 326.5425 157.5 C 327.72545 157.5 328.72201 157.91022 329.5337 158.73088 C 330.34465 159.55157 330.75 160.54402 330.75 161.7075 C 330.75 162.87172 330.33979 163.86316 329.51911 164.68385 C 328.69842 165.5045 327.70674 165.91501 326.5425 165.91501 C 325.39801 165.91501 324.4153 165.5045 323.5946 164.68385 C 322.77393 163.86316 322.36372 162.87172 322.36372 161.7075 C 322.36372 160.54402 322.76906 159.55157 323.58 158.73088 C 324.39171 157.91022 325.3793 157.5 326.5425 157.5 Z M 327.80211 190.47259 C 324.91945 195.49132 321.85778 198 318.61462 198 C 317.37452 198 316.38691 197.65158 315.65186 196.9555 C 314.9176 196.25866 314.54943 195.37617 314.54943 194.30782 C 314.54943 193.60202 314.71223 192.70572 315.03629 191.61813 L 319.0151 177.93651 C 319.39685 176.61922 319.58735 175.62754 319.58735 174.95991 C 319.58735 174.53996 319.40582 174.16692 319.04356 173.84286 C 318.68052 173.51905 318.18469 173.35701 317.55527 173.35701 C 317.26861 173.35701 316.92506 173.36677 316.5246 173.38548 L 316.89661 172.2407 L 326.59967 170.66627 L 328.31744 170.66627 L 322.44986 191.01638 C 322.12503 192.18064 321.963 192.94337 321.963 193.30666 C 321.963 193.51588 322.04862 193.71121 322.2204 193.89273 C 322.39218 194.07425 322.5737 194.16554 322.7642 194.16477 C 323.08903 194.16554 323.4131 194.02221 323.73792 193.73559 C 324.59605 193.02976 325.6267 191.75142 326.82838 189.90008 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/new-button
|
||||
|
||||
<svg class="tw-image-new-button" viewBox="83 81 50 50" width="22pt" height="22pt"><path d="M 101.25 112.5 L 101.25 127.5 C 101.25 127.5 101.25 127.5 101.25 127.5 L 101.25 127.5 C 101.25 129.156855 102.593146 130.5 104.25 130.5 L 111.75 130.5 C 113.406854 130.5 114.75 129.156854 114.75 127.5 L 114.75 112.5 L 129.75 112.5 C 131.406854 112.5 132.75 111.156854 132.75 109.5 L 132.75 102 C 132.75 100.343146 131.406854 99 129.75 99 L 114.75 99 L 114.75 84 C 114.75 82.343146 113.406854 81 111.75 81 L 104.25 81 C 104.25 81 104.25 81 104.25 81 C 102.593146 81 101.25 82.343146 101.25 84 L 101.25 99 L 86.25 99 C 86.25 99 86.25 99 86.25 99 C 84.593146 99 83.25 100.343146 83.25 102 L 83.25 109.5 C 83.25 109.5 83.25 109.5 83.25 109.5 L 83.25 109.5 C 83.25 111.156855 84.593146 112.5 86.25 112.5 Z"/></svg>
|
||||
<svg class="tw-image-new-button tw-image-button" viewBox="83 81 50 50" width="22pt" height="22pt"><path d="M 101.25 112.5 L 101.25 127.5 C 101.25 127.5 101.25 127.5 101.25 127.5 L 101.25 127.5 C 101.25 129.156855 102.593146 130.5 104.25 130.5 L 111.75 130.5 C 113.406854 130.5 114.75 129.156854 114.75 127.5 L 114.75 112.5 L 129.75 112.5 C 131.406854 112.5 132.75 111.156854 132.75 109.5 L 132.75 102 C 132.75 100.343146 131.406854 99 129.75 99 L 114.75 99 L 114.75 84 C 114.75 82.343146 113.406854 81 111.75 81 L 104.25 81 C 104.25 81 104.25 81 104.25 81 C 102.593146 81 101.25 82.343146 101.25 84 L 101.25 99 L 86.25 99 C 86.25 99 86.25 99 86.25 99 C 84.593146 99 83.25 100.343146 83.25 102 L 83.25 109.5 C 83.25 109.5 83.25 109.5 83.25 109.5 L 83.25 109.5 C 83.25 111.156855 84.593146 112.5 86.25 112.5 Z"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/options-button
|
||||
|
||||
<svg class="tw-image-options-button" viewBox="434 218 68 68" width="22pt" height="22pt"><path d="M 478.39696 232.53705 L 478.39696 232.53705 C 477.11453 231.85132 475.77877 231.30146 474.4106 230.88735 L 474.4106 218.24993 L 461.58944 218.24993 L 461.58944 230.88735 C 460.22126 231.30146 458.8855 231.85132 457.60308 232.53705 L 448.66825 223.60214 L 439.6022 232.66814 L 448.53716 241.60304 C 447.8515 242.88541 447.30158 244.22116 446.88747 245.58935 L 434.25 245.58935 L 434.25 258.41052 L 446.88747 258.41052 C 447.30158 259.7787 447.8515 261.11446 448.53716 262.39689 L 439.6022 271.33173 L 448.66825 280.39779 L 457.60308 271.46281 C 458.8855 272.14862 460.22126 272.69847 461.58944 273.11251 L 461.58944 285.74986 L 474.4106 285.74986 L 474.4106 273.11251 C 475.77877 272.69847 477.11453 272.14862 478.39696 271.46281 L 487.3318 280.39779 L 496.3977 271.33173 L 487.46287 262.39689 C 488.14854 261.11446 488.6984 259.7787 489.11257 258.41052 L 501.7499 258.41052 L 501.7499 245.58935 L 489.11257 245.58935 C 488.6984 244.22116 488.14854 242.88541 487.46287 241.60304 L 496.3977 232.66814 L 487.3318 223.60214 Z M 475.3328 244.66714 C 479.38253 248.71698 479.38253 255.2829 475.3328 259.33273 C 471.28297 263.3826 464.71706 263.3826 460.66723 259.33273 C 456.61737 255.2829 456.61737 248.71698 460.66723 244.66714 C 464.71706 240.61734 471.28297 240.61734 475.3328 244.66714"/></svg>
|
||||
<svg class="tw-image-options-button tw-image-button" viewBox="434 218 68 68" width="22pt" height="22pt"><path d="M 478.39696 232.53705 L 478.39696 232.53705 C 477.11453 231.85132 475.77877 231.30146 474.4106 230.88735 L 474.4106 218.24993 L 461.58944 218.24993 L 461.58944 230.88735 C 460.22126 231.30146 458.8855 231.85132 457.60308 232.53705 L 448.66825 223.60214 L 439.6022 232.66814 L 448.53716 241.60304 C 447.8515 242.88541 447.30158 244.22116 446.88747 245.58935 L 434.25 245.58935 L 434.25 258.41052 L 446.88747 258.41052 C 447.30158 259.7787 447.8515 261.11446 448.53716 262.39689 L 439.6022 271.33173 L 448.66825 280.39779 L 457.60308 271.46281 C 458.8855 272.14862 460.22126 272.69847 461.58944 273.11251 L 461.58944 285.74986 L 474.4106 285.74986 L 474.4106 273.11251 C 475.77877 272.69847 477.11453 272.14862 478.39696 271.46281 L 487.3318 280.39779 L 496.3977 271.33173 L 487.46287 262.39689 C 488.14854 261.11446 488.6984 259.7787 489.11257 258.41052 L 501.7499 258.41052 L 501.7499 245.58935 L 489.11257 245.58935 C 488.6984 244.22116 488.14854 242.88541 487.46287 241.60304 L 496.3977 232.66814 L 487.3318 223.60214 Z M 475.3328 244.66714 C 479.38253 248.71698 479.38253 255.2829 475.3328 259.33273 C 471.28297 263.3826 464.71706 263.3826 460.66723 259.33273 C 456.61737 255.2829 456.61737 248.71698 460.66723 244.66714 C 464.71706 240.61734 471.28297 240.61734 475.3328 244.66714"/></svg>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/images/save-button
|
||||
|
||||
<svg class="tw-image-save-button" viewBox="4 512 64 60" width="22pt" height="21pt"><path d="M 13.5 537.75 L 11.5 537.75 C 11.5 537.75 11.5 537.75 11.5 537.75 C 7.6340064 537.75 4.4999994 540.884 4.5 544.75 L 4.5 564.5 L 4.5 564.5 C 4.5 564.5 4.5 564.5 4.5 564.5 L 4.5 564.5 C 4.5000006 568.366 7.634007 571.5 11.5 571.5 L 60.5 571.5 C 64.365993 571.5 67.5 568.366 67.5 564.5 L 67.5 544.75 C 67.5 540.884 64.365993 537.75 60.5 537.75 L 58.5 537.75 L 49.5 546.75 L 50 546.75 C 52.20914 546.75 54 548.54086 54 550.75 L 54 556.25 C 54 558.45914 52.20914 560.25 50 560.25 L 36 560.25 L 22 560.25 C 19.790861 560.25 18 558.45914 18 556.25 L 18 556.25 C 18 556.25 18 556.25 18 556.25 L 18 550.75 C 18 548.54086 19.790861 546.75 22 546.75 C 22 546.75 22 546.75 22 546.75 L 22.5 546.75 Z"/><path d="M 16.37132 533.87132 L 33.87868 551.37868 C 35.050253 552.55025 36.949747 552.55025 38.12132 551.37868 L 55.62868 533.87132 C 56.800252 532.69975 56.800252 530.80025 55.62868 529.62868 C 55.06607 529.06607 54.30301 528.75 53.50736 528.75 L 48 528.75 C 46.343146 528.75 45 527.40685 45 525.75 L 45 516 C 45 514.34315 43.656854 513 42 513 L 30 513 C 28.343146 513 27 514.34315 27 516 L 27 525.75 C 27 527.40685 25.656854 528.75 24 528.75 L 18.492641 528.75 C 16.835786 528.75 15.492641 530.09315 15.492641 531.75 C 15.492641 532.54565 15.808711 533.3087 16.37132 533.87132 Z"/></svg>
|
||||
<svg class="tw-image-save-button tw-image-button" viewBox="4 512 64 60" width="22pt" height="21pt"><path d="M 13.5 537.75 L 11.5 537.75 C 11.5 537.75 11.5 537.75 11.5 537.75 C 7.6340064 537.75 4.4999994 540.884 4.5 544.75 L 4.5 564.5 L 4.5 564.5 C 4.5 564.5 4.5 564.5 4.5 564.5 L 4.5 564.5 C 4.5000006 568.366 7.634007 571.5 11.5 571.5 L 60.5 571.5 C 64.365993 571.5 67.5 568.366 67.5 564.5 L 67.5 544.75 C 67.5 540.884 64.365993 537.75 60.5 537.75 L 58.5 537.75 L 49.5 546.75 L 50 546.75 C 52.20914 546.75 54 548.54086 54 550.75 L 54 556.25 C 54 558.45914 52.20914 560.25 50 560.25 L 36 560.25 L 22 560.25 C 19.790861 560.25 18 558.45914 18 556.25 L 18 556.25 C 18 556.25 18 556.25 18 556.25 L 18 550.75 C 18 548.54086 19.790861 546.75 22 546.75 C 22 546.75 22 546.75 22 546.75 L 22.5 546.75 Z"/><path d="M 16.37132 533.87132 L 33.87868 551.37868 C 35.050253 552.55025 36.949747 552.55025 38.12132 551.37868 L 55.62868 533.87132 C 56.800252 532.69975 56.800252 530.80025 55.62868 529.62868 C 55.06607 529.06607 54.30301 528.75 53.50736 528.75 L 48 528.75 C 46.343146 528.75 45 527.40685 45 525.75 L 45 516 C 45 514.34315 43.656854 513 42 513 L 30 513 C 28.343146 513 27 514.34315 27 516 L 27 525.75 C 27 527.40685 25.656854 528.75 24 528.75 L 18.492641 528.75 C 16.835786 528.75 15.492641 530.09315 15.492641 531.75 C 15.492641 532.54565 15.808711 533.3087 16.37132 533.87132 Z"/></svg>
|
||||
|
||||
3
core/messages/StartingSave.tid
Normal file
3
core/messages/StartingSave.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/messages/StartingSave
|
||||
|
||||
Starting to save wiki
|
||||
@@ -49,27 +49,58 @@ SimpleServer.prototype.addRoute = function(route) {
|
||||
this.routes.push(route);
|
||||
};
|
||||
|
||||
SimpleServer.prototype.findMatchingRoute = function(request,state) {
|
||||
for(var t=0; t<this.routes.length; t++) {
|
||||
var potentialRoute = this.routes[t],
|
||||
pathRegExp = potentialRoute.path,
|
||||
match = potentialRoute.path.exec(state.urlInfo.pathname);
|
||||
if(match && request.method === potentialRoute.method) {
|
||||
state.params = [];
|
||||
for(var p=1; p<match.length; p++) {
|
||||
state.params.push(match[p]);
|
||||
}
|
||||
return potentialRoute;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
};
|
||||
|
||||
SimpleServer.prototype.checkCredentials = function(request,incomingUsername,incomingPassword) {
|
||||
var header = request.headers["authorization"] || "",
|
||||
token = header.split(/\s+/).pop() || "",
|
||||
auth = $tw.utils.base64Decode(token),
|
||||
parts = auth.split(/:/),
|
||||
username = parts[0],
|
||||
password = parts[1];
|
||||
if(incomingUsername === username && incomingPassword === password) {
|
||||
return "ALLOWED";
|
||||
} else {
|
||||
return "DENIED";
|
||||
}
|
||||
}
|
||||
|
||||
SimpleServer.prototype.listen = function(port) {
|
||||
var self = this;
|
||||
http.createServer(function(request, response) {
|
||||
http.createServer(function(request,response) {
|
||||
// Compose the state object
|
||||
var state = {};
|
||||
state.wiki = self.wiki;
|
||||
state.server = self;
|
||||
state.urlInfo = url.parse(request.url);
|
||||
// Find the route that matches this path
|
||||
var route;
|
||||
for(var t=0; t<self.routes.length; t++) {
|
||||
var potentialRoute = self.routes[t],
|
||||
pathRegExp = potentialRoute.path,
|
||||
match = potentialRoute.path.exec(state.urlInfo.pathname);
|
||||
if(request.method === potentialRoute.method && match) {
|
||||
state.params = [];
|
||||
for(var p=1; p<match.length; p++) {
|
||||
state.params.push(match[p]);
|
||||
}
|
||||
route = potentialRoute;
|
||||
break;
|
||||
var route = self.findMatchingRoute(request,state);
|
||||
// Check for the username and password if we've got one
|
||||
var username = self.get("username"),
|
||||
password = self.get("password");
|
||||
if(username && password) {
|
||||
// Check they match
|
||||
if(self.checkCredentials(request,username,password) !== "ALLOWED") {
|
||||
response.setHeader("WWW-Authenticate", 'Basic realm="Admin Area"');
|
||||
response.writeHead(401,"Authentication required",{
|
||||
"WWW-Authenticate": 'Basic realm="TiddlyWiki5"'
|
||||
});
|
||||
response.end();
|
||||
return;
|
||||
}
|
||||
}
|
||||
// Return a 404 if we didn't find a route
|
||||
@@ -180,6 +211,7 @@ var Command = function(params,commander,callback) {
|
||||
}
|
||||
});
|
||||
tiddlerFields["revision"] = state.wiki.getChangeCount(title);
|
||||
tiddlerFields.type = tiddlerFields.type || "text/vnd.tiddlywiki";
|
||||
tiddlers.push(tiddlerFields);
|
||||
});
|
||||
var text = JSON.stringify(tiddlers);
|
||||
@@ -207,6 +239,7 @@ var Command = function(params,commander,callback) {
|
||||
}
|
||||
});
|
||||
tiddlerFields["revision"] = state.wiki.getChangeCount(title);
|
||||
tiddlerFields.type = tiddlerFields.type || "text/vnd.tiddlywiki";
|
||||
response.writeHead(200, {"Content-Type": "application/json"});
|
||||
response.end(JSON.stringify(tiddlerFields),"utf8");
|
||||
} else {
|
||||
@@ -219,15 +252,17 @@ var Command = function(params,commander,callback) {
|
||||
|
||||
Command.prototype.execute = function() {
|
||||
var port = this.params[0] || "8080",
|
||||
rootTiddler = this.params[1] || "$:/core/templates/tiddlywiki5.template.html",
|
||||
rootTiddler = this.params[1] || "$:/core/save/all",
|
||||
renderType = this.params[2] || "text/plain",
|
||||
serveType = this.params[3] || "text/html",
|
||||
username = this.params[4] || "ANONYMOUS";
|
||||
username = this.params[4] || "ANONYMOUS",
|
||||
password = this.params[5];
|
||||
this.server.set({
|
||||
rootTiddler: rootTiddler,
|
||||
renderType: renderType,
|
||||
serveType: serveType,
|
||||
username: username
|
||||
username: username,
|
||||
password: password
|
||||
});
|
||||
this.server.listen(port);
|
||||
if(this.commander.verbose) {
|
||||
|
||||
@@ -96,7 +96,15 @@ exports["text/html"] = function(text,fields) {
|
||||
match = storeAreaMarkerRegExp.exec(text);
|
||||
if(match) {
|
||||
// If so, it's either a classic TiddlyWiki file or a TW5 file
|
||||
return deserializeTiddlyWikiFile(text,storeAreaMarkerRegExp.lastIndex,!!match[1],fields);
|
||||
// First read the normal tiddlers
|
||||
var results = deserializeTiddlyWikiFile(text,storeAreaMarkerRegExp.lastIndex,!!match[1],fields);
|
||||
// Then any system tiddlers
|
||||
var systemAreaMarkerRegExp = /<div id=["']?systemArea['"]?( style=["']?display:none;["']?)?>/gi,
|
||||
sysMatch = systemAreaMarkerRegExp.exec(text);
|
||||
if(sysMatch) {
|
||||
results.push.apply(results,deserializeTiddlyWikiFile(text,systemAreaMarkerRegExp.lastIndex,!!sysMatch[1],fields));
|
||||
}
|
||||
return results
|
||||
} else {
|
||||
// It's not a TiddlyWiki so we'll return the entire HTML file as a tiddler
|
||||
return deserializeHtmlFile(text,fields);
|
||||
|
||||
@@ -131,7 +131,14 @@ exports.filterTiddlers = function(filterString,currTiddlerTitle,tiddlerList) {
|
||||
};
|
||||
|
||||
exports.compileFilter = function(filterString) {
|
||||
var filterParseTree = this.parseFilter(filterString);
|
||||
var filterParseTree;
|
||||
try {
|
||||
filterParseTree = this.parseFilter(filterString);
|
||||
} catch(e) {
|
||||
return function(source,currTiddlerTitle) {
|
||||
return ["Filter error: " + e];
|
||||
};
|
||||
}
|
||||
// Get the hashmap of filter operator functions
|
||||
var filterOperators = this.getFilterOperators();
|
||||
// Assemble array of functions, one for each operation
|
||||
|
||||
43
core/modules/filters/is/tiddler.js
Normal file
43
core/modules/filters/is/tiddler.js
Normal file
@@ -0,0 +1,43 @@
|
||||
/*\
|
||||
title: $:/core/modules/filters/is/tiddler.js
|
||||
type: application/javascript
|
||||
module-type: isfilteroperator
|
||||
|
||||
Filter function for [is[tiddler]]
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
Export our filter function
|
||||
*/
|
||||
exports.tiddler = function(source,prefix,options) {
|
||||
var results = [];
|
||||
// Function to check a tiddler
|
||||
function checkTiddler(title) {
|
||||
var match = options.wiki.tiddlerExists(title);
|
||||
if(prefix === "!") {
|
||||
match = !match;
|
||||
}
|
||||
if(match) {
|
||||
results.push(title);
|
||||
}
|
||||
};
|
||||
// Iterate through the source tiddlers
|
||||
if($tw.utils.isArray(source)) {
|
||||
$tw.utils.each(source,function(title) {
|
||||
checkTiddler(title);
|
||||
});
|
||||
} else {
|
||||
$tw.utils.each(source,function(element,title) {
|
||||
checkTiddler(title);
|
||||
});
|
||||
}
|
||||
return results;
|
||||
};
|
||||
|
||||
})();
|
||||
@@ -52,14 +52,15 @@ exports.types = {block: true};
|
||||
exports.init = function(parser) {
|
||||
this.parser = parser;
|
||||
// Regexp to match
|
||||
this.matchRegExp = /([\*#;:]+)/mg;
|
||||
this.matchRegExp = /([\*#;:>]+)/mg;
|
||||
};
|
||||
|
||||
var listTypes = {
|
||||
"*": {listTag: "ul", itemTag: "li"},
|
||||
"#": {listTag: "ol", itemTag: "li"},
|
||||
";": {listTag: "dl", itemTag: "dt"},
|
||||
":": {listTag: "dl", itemTag: "dd"}
|
||||
":": {listTag: "dl", itemTag: "dd"},
|
||||
">": {listTag: "blockquote", itemTag: "p"}
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -71,7 +72,7 @@ exports.parse = function() {
|
||||
// Cycle through the items in the list
|
||||
while(true) {
|
||||
// Match the list marker
|
||||
var reMatch = /([\*#;:]+)/mg;
|
||||
var reMatch = /([\*#;:>]+)/mg;
|
||||
reMatch.lastIndex = this.parser.pos;
|
||||
var match = reMatch.exec(this.parser.source);
|
||||
if(!match || match.index !== this.parser.pos) {
|
||||
|
||||
@@ -22,7 +22,7 @@ exports.types = {block: true};
|
||||
exports.init = function(parser) {
|
||||
this.parser = parser;
|
||||
// Regexp to match
|
||||
this.matchRegExp = /<<([^\s>]+)\s*([\s\S]*?)>>(?:\r?\n|$)/mg;
|
||||
this.matchRegExp = /<<([^>\s]+)(?:\s*)((?:[^>]|(?:>(?!>)))*?)>>(?:\r?\n|$)/mg;
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
93
core/modules/parsers/wikiparser/rules/quoteblock.js
Normal file
93
core/modules/parsers/wikiparser/rules/quoteblock.js
Normal file
@@ -0,0 +1,93 @@
|
||||
/*\
|
||||
title: $:/core/modules/parsers/wikiparser/rules/quoteblock.js
|
||||
type: application/javascript
|
||||
module-type: wikirule
|
||||
|
||||
Wiki text rule for quote blocks. For example:
|
||||
|
||||
```
|
||||
<<<.optionalClass(es) optional cited from
|
||||
a quote
|
||||
<<<
|
||||
|
||||
<<<.optionalClass(es)
|
||||
a quote
|
||||
<<< optional cited from
|
||||
```
|
||||
|
||||
Quotes can be quoted by putting more <s
|
||||
|
||||
```
|
||||
<<<
|
||||
Quote Level 1
|
||||
|
||||
<<<<
|
||||
QuoteLevel 2
|
||||
<<<<
|
||||
|
||||
<<<
|
||||
```
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
exports.name = "quoteblock";
|
||||
exports.types = {block: true};
|
||||
|
||||
exports.init = function(parser) {
|
||||
this.parser = parser;
|
||||
// Regexp to match
|
||||
this.matchRegExp = /(<<<+)/mg;
|
||||
};
|
||||
|
||||
exports.parse = function() {
|
||||
var classes = ["tw-quote"];
|
||||
// Get all the details of the match
|
||||
var reEndString = "^" + this.match[1] + "(?!<)";
|
||||
// Move past the <s
|
||||
this.parser.pos = this.matchRegExp.lastIndex;
|
||||
|
||||
// Parse any classes, whitespace and then the optional cite itself
|
||||
classes.push.apply(classes, this.parser.parseClasses());
|
||||
this.parser.skipWhitespace({treatNewlinesAsNonWhitespace: true});
|
||||
var cite = this.parser.parseInlineRun(/(\r?\n)/mg);
|
||||
|
||||
// before handling the cite, parse the body of the quote
|
||||
var tree= this.parser.parseBlocks(reEndString);
|
||||
// If we got a cite, put it before the text
|
||||
if ( cite.length > 0 ) {
|
||||
tree.unshift({
|
||||
type: "element",
|
||||
tag: "cite",
|
||||
children: cite
|
||||
});
|
||||
}
|
||||
|
||||
// Parse any optional cite
|
||||
this.parser.skipWhitespace({treatNewlinesAsNonWhitespace: true});
|
||||
var cite = this.parser.parseInlineRun(/(\r?\n)/mg);
|
||||
// If we got a cite, push it
|
||||
if ( cite.length > 0 ) {
|
||||
tree.push({
|
||||
type: "element",
|
||||
tag: "cite",
|
||||
children: cite
|
||||
});
|
||||
}
|
||||
|
||||
// Return the blockquote element
|
||||
return [{
|
||||
type: "element",
|
||||
tag: "blockquote",
|
||||
attributes: {
|
||||
class: { type: "string", value: classes.join(" ") },
|
||||
},
|
||||
children: tree
|
||||
}];
|
||||
};
|
||||
|
||||
})();
|
||||
@@ -7,10 +7,7 @@ Wiki text rule for block-level transclusion. For example:
|
||||
|
||||
```
|
||||
{{MyTiddler}}
|
||||
{{MyTiddler|tooltip}}
|
||||
{{MyTiddler||TemplateTitle}}
|
||||
{{MyTiddler|tooltip||TemplateTitle}}
|
||||
{{MyTiddler}width:40;height:50;}.class.class
|
||||
```
|
||||
|
||||
\*/
|
||||
@@ -26,7 +23,7 @@ exports.types = {block: true};
|
||||
exports.init = function(parser) {
|
||||
this.parser = parser;
|
||||
// Regexp to match
|
||||
this.matchRegExp = /\{\{([^\{\}\|]+)(?:\|([^\|\{\}]+))?(?:\|\|([^\|\{\}]+))?\}([^\}]*)\}(?:\.(\S+))?(?:\r?\n|$)/mg;
|
||||
this.matchRegExp = /\{\{([^\{\}\|]+)(?:\|\|([^\|\{\}]+))?\}\}(?:\r?\n|$)/mg;
|
||||
};
|
||||
|
||||
exports.parse = function() {
|
||||
@@ -38,17 +35,12 @@ exports.parse = function() {
|
||||
targetTitle = tr.title,
|
||||
targetField = tr.field,
|
||||
targetIndex = tr.index,
|
||||
tooltip = this.match[2],
|
||||
template = $tw.utils.trim(this.match[3]),
|
||||
style = this.match[4],
|
||||
classes = this.match[5];
|
||||
template = $tw.utils.trim(this.match[2]);
|
||||
// Prepare the transclude widget
|
||||
var transcludeNode = {
|
||||
type: "element",
|
||||
tag: "$transclude",
|
||||
attributes: {
|
||||
tiddler: {type: "string", value: template || targetTitle}
|
||||
},
|
||||
attributes: {},
|
||||
isBlock: true
|
||||
};
|
||||
var tiddlerNode = {
|
||||
@@ -60,20 +52,16 @@ exports.parse = function() {
|
||||
isBlock: true,
|
||||
children: [transcludeNode]
|
||||
};
|
||||
if(targetField) {
|
||||
transcludeNode.attributes.field = {type: "string", value: targetField};
|
||||
}
|
||||
if(targetIndex) {
|
||||
transcludeNode.attributes.index = {type: "string", value: targetIndex};
|
||||
}
|
||||
if(tooltip) {
|
||||
transcludeNode.attributes.tooltip = {type: "string", value: tooltip};
|
||||
}
|
||||
if(style) {
|
||||
transcludeNode.attributes.style = {type: "string", value: style};
|
||||
}
|
||||
if(classes) {
|
||||
transcludeNode.attributes["class"] = {type: "string", value: classes.split(".").join(" ")};
|
||||
if(template) {
|
||||
transcludeNode.attributes.tiddler = {type: "string", value: template};
|
||||
} else {
|
||||
transcludeNode.attributes.tiddler = {type: "string", value: targetTitle};
|
||||
if(targetField) {
|
||||
transcludeNode.attributes.field = {type: "string", value: targetField};
|
||||
}
|
||||
if(targetIndex) {
|
||||
transcludeNode.attributes.index = {type: "string", value: targetIndex};
|
||||
}
|
||||
}
|
||||
return [tiddlerNode];
|
||||
};
|
||||
|
||||
@@ -7,10 +7,7 @@ Wiki text rule for inline-level transclusion. For example:
|
||||
|
||||
```
|
||||
{{MyTiddler}}
|
||||
{{MyTiddler|tooltip}}
|
||||
{{MyTiddler||TemplateTitle}}
|
||||
{{MyTiddler|tooltip||TemplateTitle}}
|
||||
{{MyTiddler}width:40;height:50;}.class.class
|
||||
```
|
||||
|
||||
\*/
|
||||
@@ -26,7 +23,7 @@ exports.types = {inline: true};
|
||||
exports.init = function(parser) {
|
||||
this.parser = parser;
|
||||
// Regexp to match
|
||||
this.matchRegExp = /\{\{([^\{\}\|]+)(?:\|([^\|\{\}]+))?(?:\|\|([^\|\{\}]+))?\}([^\}]*)\}(?:\.(\S+))?/mg;
|
||||
this.matchRegExp = /\{\{([^\{\}\|]+)(?:\|\|([^\|\{\}]+))?\}\}/mg;
|
||||
};
|
||||
|
||||
exports.parse = function() {
|
||||
@@ -38,17 +35,12 @@ exports.parse = function() {
|
||||
targetTitle = tr.title,
|
||||
targetField = tr.field,
|
||||
targetIndex = tr.index,
|
||||
tooltip = this.match[2],
|
||||
template = $tw.utils.trim(this.match[3]),
|
||||
style = this.match[4],
|
||||
classes = this.match[5];
|
||||
template = $tw.utils.trim(this.match[2]);
|
||||
// Prepare the transclude widget
|
||||
var transcludeNode = {
|
||||
type: "element",
|
||||
tag: "$transclude",
|
||||
attributes: {
|
||||
tiddler: {type: "string", value: template || targetTitle}
|
||||
}
|
||||
attributes: {}
|
||||
};
|
||||
var tiddlerNode = {
|
||||
type: "element",
|
||||
@@ -58,20 +50,16 @@ exports.parse = function() {
|
||||
},
|
||||
children: [transcludeNode]
|
||||
};
|
||||
if(targetField) {
|
||||
transcludeNode.attributes.field = {type: "string", value: targetField};
|
||||
}
|
||||
if(targetIndex) {
|
||||
transcludeNode.attributes.index = {type: "string", value: targetIndex};
|
||||
}
|
||||
if(tooltip) {
|
||||
transcludeNode.attributes.tooltip = {type: "string", value: tooltip};
|
||||
}
|
||||
if(style) {
|
||||
transcludeNode.attributes.style = {type: "string", value: style};
|
||||
}
|
||||
if(classes) {
|
||||
transcludeNode.attributes["class"] = {type: "string", value: classes.split(".").join(" ")};
|
||||
if(template) {
|
||||
transcludeNode.attributes.tiddler = {type: "string", value: template};
|
||||
} else {
|
||||
transcludeNode.attributes.tiddler = {type: "string", value: targetTitle};
|
||||
if(targetField) {
|
||||
transcludeNode.attributes.field = {type: "string", value: targetField};
|
||||
}
|
||||
if(targetIndex) {
|
||||
transcludeNode.attributes.index = {type: "string", value: targetIndex};
|
||||
}
|
||||
}
|
||||
return [tiddlerNode];
|
||||
};
|
||||
|
||||
@@ -15,7 +15,11 @@ Handles saving changes via the AndTidWiki Android app
|
||||
var AndTidWiki = function(wiki) {
|
||||
};
|
||||
|
||||
AndTidWiki.prototype.save = function(text,callback) {
|
||||
AndTidWiki.prototype.save = function(text,method,callback) {
|
||||
// Bail out unless this is a save (rather than a download)
|
||||
if(method !== "save") {
|
||||
return false;
|
||||
}
|
||||
// Get the pathname of this document
|
||||
var pathname = decodeURIComponent(document.location.toString());
|
||||
// Strip the file://
|
||||
|
||||
@@ -18,7 +18,7 @@ Select the appropriate saver module and set it up
|
||||
var DownloadSaver = function(wiki) {
|
||||
};
|
||||
|
||||
DownloadSaver.prototype.save = function(text) {
|
||||
DownloadSaver.prototype.save = function(text,method,callback) {
|
||||
// Get the current filename
|
||||
var filename = "tiddlywiki.html",
|
||||
p = document.location.pathname.lastIndexOf("/");
|
||||
|
||||
@@ -21,7 +21,7 @@ Select the appropriate saver module and set it up
|
||||
var ManualDownloadSaver = function(wiki) {
|
||||
};
|
||||
|
||||
ManualDownloadSaver.prototype.save = function(text) {
|
||||
ManualDownloadSaver.prototype.save = function(text,method,callback) {
|
||||
$tw.modal.display(downloadInstructionsTitle,{
|
||||
downloadLink: "data:text/html," + encodeURIComponent(text)
|
||||
});
|
||||
|
||||
56
core/modules/savers/msdownload.js
Normal file
56
core/modules/savers/msdownload.js
Normal file
@@ -0,0 +1,56 @@
|
||||
/*\
|
||||
title: $:/core/modules/savers/msdownload.js
|
||||
type: application/javascript
|
||||
module-type: saver
|
||||
|
||||
Handles saving changes via window.navigator.msSaveBlob()
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
Select the appropriate saver module and set it up
|
||||
*/
|
||||
var MsDownloadSaver = function(wiki) {
|
||||
};
|
||||
|
||||
MsDownloadSaver.prototype.save = function(text,method,callback) {
|
||||
// Get the current filename
|
||||
var filename = "tiddlywiki.html",
|
||||
p = document.location.pathname.lastIndexOf("/");
|
||||
if(p !== -1) {
|
||||
filename = document.location.pathname.substr(p+1);
|
||||
}
|
||||
// Set up the link
|
||||
var blob = new Blob([text], {type: "text/html"});
|
||||
window.navigator.msSaveBlob(blob,filename);
|
||||
return true;
|
||||
};
|
||||
|
||||
/*
|
||||
Information about this saver
|
||||
*/
|
||||
MsDownloadSaver.prototype.info = {
|
||||
name: "msdownload",
|
||||
priority: 110
|
||||
};
|
||||
|
||||
/*
|
||||
Static method that returns true if this saver is capable of working
|
||||
*/
|
||||
exports.canSave = function(wiki) {
|
||||
return !!window.navigator.msSaveBlob;
|
||||
};
|
||||
|
||||
/*
|
||||
Create an instance of this saver
|
||||
*/
|
||||
exports.create = function(wiki) {
|
||||
return new MsDownloadSaver(wiki);
|
||||
};
|
||||
|
||||
})();
|
||||
@@ -15,7 +15,11 @@ Handles saving changes via the TiddlyFox file extension
|
||||
var TiddlyFoxSaver = function(wiki) {
|
||||
};
|
||||
|
||||
TiddlyFoxSaver.prototype.save = function(text,callback) {
|
||||
TiddlyFoxSaver.prototype.save = function(text,method,callback) {
|
||||
// Bail out unless this is a save (rather than a download)
|
||||
if(method !== "save") {
|
||||
return false;
|
||||
}
|
||||
var messageBox = document.getElementById("tiddlyfox-message-box");
|
||||
if(messageBox) {
|
||||
// Get the pathname of this document
|
||||
|
||||
@@ -15,7 +15,11 @@ Handles saving changes via the TWEdit iOS app
|
||||
var TWEditSaver = function(wiki) {
|
||||
};
|
||||
|
||||
TWEditSaver.prototype.save = function(text,callback) {
|
||||
TWEditSaver.prototype.save = function(text,method,callback) {
|
||||
// Bail out unless this is a save (rather than a download)
|
||||
if(method !== "save") {
|
||||
return false;
|
||||
}
|
||||
// Bail if we're not running under TWEdit
|
||||
if(typeof DeviceInfo !== "object") {
|
||||
return false;
|
||||
|
||||
@@ -21,7 +21,11 @@ var UploadSaver = function(wiki) {
|
||||
this.wiki = wiki;
|
||||
};
|
||||
|
||||
UploadSaver.prototype.save = function(text) {
|
||||
UploadSaver.prototype.save = function(text,method,callback) {
|
||||
// Bail out unless this is a save (rather than a download)
|
||||
if(method !== "save") {
|
||||
return false;
|
||||
}
|
||||
// Get the various parameters we need
|
||||
var backupDir = ".",
|
||||
username = this.wiki.getTextReference("$:/UploadName"),
|
||||
@@ -56,10 +60,15 @@ UploadSaver.prototype.save = function(text) {
|
||||
http.setRequestHeader("Content-Type","multipart/form-data; ;charset=UTF-8; boundary=" + boundary);
|
||||
http.onreadystatechange = function() {
|
||||
if(http.readyState == 4 && http.status == 200) {
|
||||
window.alert(http.responseText);
|
||||
if(http.responseText.trim() === "0 - Fileindex.html") {
|
||||
callback(null);
|
||||
} else {
|
||||
callback(http.responseText);
|
||||
}
|
||||
}
|
||||
};
|
||||
http.send(data);
|
||||
$tw.notifier.display("$:/messages/StartingSave");
|
||||
return true;
|
||||
};
|
||||
|
||||
|
||||
@@ -89,6 +89,13 @@ exports.startup = function() {
|
||||
downloadType: "text/plain"
|
||||
});
|
||||
});
|
||||
$tw.rootWidget.addEventListener("tw-download-file",function(event) {
|
||||
$tw.wiki.saveWiki({
|
||||
method: "download",
|
||||
template: event.param,
|
||||
downloadType: "text/plain"
|
||||
});
|
||||
});
|
||||
// Install the crypto event handlers
|
||||
$tw.rootWidget.addEventListener("tw-set-password",function(event) {
|
||||
$tw.passwordPrompt.createPrompt({
|
||||
|
||||
@@ -181,7 +181,7 @@ Syncer.prototype.syncFromServer = function() {
|
||||
for(var t=0; t<tiddlers.length; t++) {
|
||||
// Get the incoming tiddler fields, and the existing tiddler
|
||||
var tiddlerFields = tiddlers[t],
|
||||
incomingRevision = tiddlerFields.revision,
|
||||
incomingRevision = tiddlerFields.revision + "",
|
||||
tiddler = self.wiki.getTiddler(tiddlerFields.title),
|
||||
tiddlerInfo = self.tiddlerInfo[tiddlerFields.title],
|
||||
currRevision = tiddlerInfo ? tiddlerInfo.revision : null;
|
||||
@@ -385,6 +385,9 @@ Syncer.prototype.processTaskQueue = function() {
|
||||
this.taskInProgress[task.title] = task;
|
||||
// Dispatch the task
|
||||
this.dispatchTask(task,function(err) {
|
||||
if(err) {
|
||||
console.log("Sync error while processing '" + task.title + "':\n" + err);
|
||||
}
|
||||
// Mark that this task is no longer in progress
|
||||
delete self.taskInProgress[task.title];
|
||||
// Process the next task
|
||||
|
||||
@@ -13,7 +13,10 @@ Manages themes and styling.
|
||||
"use strict";
|
||||
|
||||
var THEME_PLUGIN_TITLE = "$:/theme", // This tiddler contains the title of the current theme plugin
|
||||
DEFAULT_THEME_PLUGIN = "$:/themes/tiddlywiki/snowwhite";
|
||||
DEFAULT_THEME_PLUGINS = [
|
||||
"$:/themes/tiddlywiki/snowwhite",
|
||||
"$:/themes/tiddlywiki/vanilla"
|
||||
];
|
||||
|
||||
function ThemeManager(wiki) {
|
||||
this.wiki = wiki;
|
||||
@@ -32,7 +35,12 @@ function ThemeManager(wiki) {
|
||||
|
||||
ThemeManager.prototype.switchTheme = function() {
|
||||
// Get the name of the current theme
|
||||
var themePluginTitle = this.wiki.getTiddlerText(THEME_PLUGIN_TITLE,DEFAULT_THEME_PLUGIN);
|
||||
var themePluginTitle = this.wiki.getTiddlerText(THEME_PLUGIN_TITLE);
|
||||
// If it doesn't exist, then fallback to one of the default themes
|
||||
var index = 0;
|
||||
while(!this.wiki.getTiddler(themePluginTitle) && index < DEFAULT_THEME_PLUGINS.length) {
|
||||
themePluginTitle = DEFAULT_THEME_PLUGINS[index++];
|
||||
}
|
||||
// Accumulate the titles of the plugins that we need to load
|
||||
var themePlugins = [],
|
||||
self = this,
|
||||
|
||||
@@ -29,7 +29,7 @@ exports.removeChildren = function(node) {
|
||||
};
|
||||
|
||||
exports.hasClass = function(el,className) {
|
||||
return el.className.split(" ").indexOf(className) !== -1;
|
||||
return el && el.className && el.className.split(" ").indexOf(className) !== -1;
|
||||
};
|
||||
|
||||
exports.addClass = function(el,className) {
|
||||
|
||||
@@ -26,16 +26,28 @@ Popup.prototype.show = function(options) {
|
||||
this.title = options.title;
|
||||
this.wiki = options.wiki;
|
||||
this.anchorDomNode = options.domNode;
|
||||
$tw.utils.addClass(this.anchorDomNode,"tw-popup");
|
||||
this.rootElement.addEventListener("click",this,false);
|
||||
};
|
||||
|
||||
Popup.prototype.handleEvent = function(event) {
|
||||
if(event.type === "click" && this.anchorDomNode !== event.target && !$tw.utils.domContains(this.anchorDomNode,event.target)) {
|
||||
this.cancel();
|
||||
// Dismiss the popup if we get a click on an element that doesn't have .tw-popup class
|
||||
if(event.type === "click") {
|
||||
var node = event.target;
|
||||
while(node && !$tw.utils.hasClass(node,"tw-popup")) {
|
||||
node = node.parentNode;
|
||||
}
|
||||
if(!node) {
|
||||
this.cancel();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Popup.prototype.cancel = function() {
|
||||
if(this.anchorDomNode) {
|
||||
$tw.utils.removeClass(this.anchorDomNode,"tw-popup");
|
||||
this.anchorDomNode = null;
|
||||
}
|
||||
this.rootElement.removeEventListener("click",this,false);
|
||||
if(this.title) {
|
||||
this.wiki.deleteTiddler(this.title);
|
||||
|
||||
@@ -402,4 +402,27 @@ exports.getAnimationDuration = function() {
|
||||
return parseInt($tw.wiki.getTiddlerText("$:/config/AnimationDuration","400"),10);
|
||||
};
|
||||
|
||||
/*
|
||||
Hash a string to a number
|
||||
Derived from http://stackoverflow.com/a/15710692
|
||||
*/
|
||||
exports.hashString = function(str) {
|
||||
return str.split("").reduce(function(a,b) {
|
||||
a = ((a << 5) - a) + b.charCodeAt(0);
|
||||
return a & a;
|
||||
},0);
|
||||
};
|
||||
|
||||
/*
|
||||
Decode a base64 string
|
||||
*/
|
||||
exports.base64Decode = function(string64) {
|
||||
if($tw.browser) {
|
||||
// TODO
|
||||
throw "$tw.utils.base64Decode() doesn't work in the browser";
|
||||
} else {
|
||||
return (new Buffer(string64,"base64")).toString();
|
||||
}
|
||||
};
|
||||
|
||||
})();
|
||||
|
||||
@@ -63,16 +63,6 @@ BrowseWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return false;
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
BrowseWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.browse = BrowseWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -136,16 +136,6 @@ ButtonWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return this.refreshChildren(changedTiddlers);
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
ButtonWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.button = ButtonWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -62,7 +62,7 @@ CheckboxWidget.prototype.handleChangeEvent = function(event) {
|
||||
var checked = this.inputDomNode.checked,
|
||||
tiddler = this.wiki.getTiddler(this.checkboxTitle);
|
||||
if(tiddler && tiddler.hasTag(this.checkboxTag) !== checked) {
|
||||
var newTags = tiddler.fields.tags.slice(0),
|
||||
var newTags = (tiddler.fields.tags || []).slice(0),
|
||||
pos = newTags.indexOf(this.checkboxTag);
|
||||
if(pos !== -1) {
|
||||
newTags.splice(pos,1);
|
||||
@@ -103,16 +103,6 @@ CheckboxWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
CheckboxWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.checkbox = CheckboxWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -66,16 +66,6 @@ CountWidget.prototype.refresh = function(changedTiddlers) {
|
||||
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
CountWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.count = CountWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -106,7 +106,7 @@ DropZoneWidget.prototype.importData = function(dataTransfer) {
|
||||
if(data !== "") {
|
||||
var tiddlerFields = dataType.convertToFields(data);
|
||||
if(!tiddlerFields.title) {
|
||||
tiddlerFields.title = this.generateTitle("Untitled");
|
||||
tiddlerFields.title = this.wiki.generateNewTitle("Untitled");
|
||||
}
|
||||
this.dispatchEvent({type: "tw-import-tiddlers", param: JSON.stringify([tiddlerFields])});
|
||||
return;
|
||||
@@ -175,16 +175,6 @@ DropZoneWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return this.refreshChildren(changedTiddlers);
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
DropZoneWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.dropzone = DropZoneWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -94,16 +94,6 @@ EditBitmapWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return false;
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
EditBitmapWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
EditBitmapWidget.prototype.loadCanvas = function() {
|
||||
var tiddler = this.wiki.getTiddler(this.editTitle),
|
||||
currImage = new Image();
|
||||
|
||||
@@ -73,12 +73,21 @@ Get the tiddler being edited and current value
|
||||
*/
|
||||
EditTextWidget.prototype.getEditInfo = function() {
|
||||
// Get the edit value
|
||||
var tiddler = this.wiki.getTiddler(this.editTitle),
|
||||
value;
|
||||
var self = this,
|
||||
value,
|
||||
update;
|
||||
if(this.editIndex) {
|
||||
value = this.wiki.extractTiddlerDataItem(this.editTitle,this.editIndex,this.editDefault);
|
||||
update = function(value) {
|
||||
var data = self.wiki.getTiddlerData(self.editTitle,{});
|
||||
if(data[self.editIndex] !== value) {
|
||||
data[self.editIndex] = value;
|
||||
self.wiki.setTiddlerData(self.editTitle,data);
|
||||
}
|
||||
};
|
||||
} else {
|
||||
// Get the current tiddler and the field name
|
||||
var tiddler = this.wiki.getTiddler(this.editTitle);
|
||||
if(tiddler) {
|
||||
// If we've got a tiddler, the value to display is the field string value
|
||||
value = tiddler.getFieldString(this.editField);
|
||||
@@ -99,8 +108,16 @@ EditTextWidget.prototype.getEditInfo = function() {
|
||||
value = this.editDefault;
|
||||
}
|
||||
}
|
||||
update = function(value) {
|
||||
var tiddler = self.wiki.getTiddler(self.editTitle),
|
||||
updateFields = {
|
||||
title: self.editTitle
|
||||
};
|
||||
updateFields[self.editField] = value;
|
||||
self.wiki.addTiddler(new $tw.Tiddler(self.wiki.getCreationFields(),tiddler,updateFields,self.wiki.getModificationFields()));
|
||||
};
|
||||
}
|
||||
return {tiddler: tiddler, value: value};
|
||||
return {value: value, update: update};
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -224,36 +241,12 @@ EditTextWidget.prototype.handleFocusEvent = function(event) {
|
||||
};
|
||||
|
||||
EditTextWidget.prototype.saveChanges = function(text) {
|
||||
if(this.editField) {
|
||||
var tiddler = this.wiki.getTiddler(this.editTitle);
|
||||
if(!tiddler) {
|
||||
tiddler = new $tw.Tiddler({title: this.editTitle});
|
||||
}
|
||||
var oldValue = tiddler.getFieldString(this.editField);
|
||||
if(text !== oldValue) {
|
||||
var update = {};
|
||||
update[this.editField] = text;
|
||||
this.wiki.addTiddler(new $tw.Tiddler(tiddler,update));
|
||||
}
|
||||
} else {
|
||||
var data = this.wiki.getTiddlerData(this.editTitle,{});
|
||||
if(data[this.editIndex] !== text) {
|
||||
data[this.editIndex] = text;
|
||||
this.wiki.setTiddlerData(this.editTitle,data);
|
||||
}
|
||||
var editInfo = this.getEditInfo();
|
||||
if(text !== editInfo.value) {
|
||||
editInfo.update(text);
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
EditTextWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports["edit-text"] = EditTextWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -68,7 +68,7 @@ EditWidget.prototype.execute = function() {
|
||||
this.makeChildWidgets([{
|
||||
type: "edit-" + editorType,
|
||||
attributes: {
|
||||
title: {type: "string", value: this.editTitle},
|
||||
tiddler: {type: "string", value: this.editTitle},
|
||||
field: {type: "string", value: this.editField},
|
||||
index: {type: "string", value: this.editIndex},
|
||||
"class": {type: "string", value: this.editClass}
|
||||
|
||||
@@ -70,16 +70,6 @@ ElementWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return this.refreshChildren(changedTiddlers) || hasChangedAttributes;
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
ElementWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.element = ElementWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -70,16 +70,6 @@ EncryptWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
EncryptWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.encrypt = EncryptWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -47,16 +47,6 @@ EntityWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return false;
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
EntityWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.entity = EntityWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -72,10 +72,13 @@ FieldManglerWidget.prototype.handleRemoveFieldEvent = function(event) {
|
||||
|
||||
FieldManglerWidget.prototype.handleAddFieldEvent = function(event) {
|
||||
var tiddler = this.wiki.getTiddler(this.mangleTitle);
|
||||
if(tiddler && typeof event.param === "string" && event.param !== "" && !$tw.utils.hop(tiddler.fields,event.param)) {
|
||||
var addition = {};
|
||||
addition[event.param] = "";
|
||||
this.wiki.addTiddler(new $tw.Tiddler(tiddler,addition));
|
||||
if(tiddler && typeof event.param === "string") {
|
||||
var name = event.param.toLowerCase();
|
||||
if(name !== "" && !$tw.utils.hop(tiddler.fields,name)) {
|
||||
var addition = {};
|
||||
addition[name] = "";
|
||||
this.wiki.addTiddler(new $tw.Tiddler(tiddler,addition));
|
||||
}
|
||||
}
|
||||
return true;
|
||||
};
|
||||
|
||||
@@ -98,16 +98,6 @@ FieldsWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
FieldsWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.fields = FieldsWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -169,16 +169,6 @@ LinkWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return this.refreshChildren(changedTiddlers);
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
LinkWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.link = LinkWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -24,6 +24,7 @@ var NavigatorWidget = function(parseTreeNode,options) {
|
||||
{type: "tw-cancel-tiddler", handler: "handleCancelTiddlerEvent"},
|
||||
{type: "tw-close-tiddler", handler: "handleCloseTiddlerEvent"},
|
||||
{type: "tw-close-all-tiddlers", handler: "handleCloseAllTiddlersEvent"},
|
||||
{type: "tw-close-other-tiddlers", handler: "handleCloseOtherTiddlersEvent"},
|
||||
{type: "tw-new-tiddler", handler: "handleNewTiddlerEvent"},
|
||||
{type: "tw-import-tiddlers", handler: "handleImportTiddlersEvent"},
|
||||
]);
|
||||
@@ -134,16 +135,23 @@ NavigatorWidget.prototype.handleCloseAllTiddlersEvent = function(event) {
|
||||
this.saveStoryList();
|
||||
return false;
|
||||
};
|
||||
// Close other tiddlers
|
||||
NavigatorWidget.prototype.handleCloseOtherTiddlersEvent = function(event) {
|
||||
this.storyList = [event.tiddlerTitle];
|
||||
this.saveStoryList();
|
||||
return false;
|
||||
};
|
||||
|
||||
// Place a tiddler in edit mode
|
||||
NavigatorWidget.prototype.handleEditTiddlerEvent = function(event) {
|
||||
this.getStoryList();
|
||||
// Replace the specified tiddler with a draft in edit mode
|
||||
var draftTiddler = this.getDraftTiddler(event.tiddlerTitle),
|
||||
var title = event.param || event.tiddlerTitle,
|
||||
draftTiddler = this.getDraftTiddler(title),
|
||||
gotOne = false;
|
||||
for(var t=this.storyList.length-1; t>=0; t--) {
|
||||
// Replace the first story instance of the original tiddler name with the draft title
|
||||
if(this.storyList[t] === event.tiddlerTitle) {
|
||||
if(this.storyList[t] === title) {
|
||||
if(!gotOne) {
|
||||
this.storyList[t] = draftTiddler.fields.title;
|
||||
gotOne = true;
|
||||
@@ -162,18 +170,19 @@ NavigatorWidget.prototype.handleEditTiddlerEvent = function(event) {
|
||||
// Delete a tiddler
|
||||
NavigatorWidget.prototype.handleDeleteTiddlerEvent = function(event) {
|
||||
// Get the tiddler we're deleting
|
||||
var tiddler = this.wiki.getTiddler(event.tiddlerTitle);
|
||||
var title = event.param || event.tiddlerTitle,
|
||||
tiddler = this.wiki.getTiddler(title);
|
||||
// Check if the tiddler we're deleting is in draft mode
|
||||
if(tiddler.hasField("draft.title")) {
|
||||
// Delete the original tiddler
|
||||
this.wiki.deleteTiddler(tiddler.fields["draft.of"]);
|
||||
}
|
||||
// Delete this tiddler
|
||||
this.wiki.deleteTiddler(event.tiddlerTitle);
|
||||
this.wiki.deleteTiddler(title);
|
||||
// Remove the closed tiddler from the story
|
||||
this.getStoryList();
|
||||
// Look for tiddler with this title to close
|
||||
var slot = this.findTitleInStory(event.tiddlerTitle,-1);
|
||||
var slot = this.findTitleInStory(title,-1);
|
||||
if(slot !== -1) {
|
||||
this.storyList.splice(slot,1);
|
||||
this.saveStoryList();
|
||||
@@ -228,13 +237,14 @@ NavigatorWidget.prototype.generateDraftTitle = function(title) {
|
||||
// Take a tiddler out of edit mode, saving the changes
|
||||
NavigatorWidget.prototype.handleSaveTiddlerEvent = function(event) {
|
||||
this.getStoryList();
|
||||
var storyTiddlerModified = false; // We have to special case saving the story tiddler itself
|
||||
var title = event.param || event.tiddlerTitle,
|
||||
storyTiddlerModified = false; // We have to special case saving the story tiddler itself
|
||||
for(var t=0; t<this.storyList.length; t++) {
|
||||
if(this.storyList[t] === event.tiddlerTitle) {
|
||||
var tiddler = this.wiki.getTiddler(event.tiddlerTitle);
|
||||
if(this.storyList[t] === title) {
|
||||
var tiddler = this.wiki.getTiddler(title);
|
||||
if(tiddler) {
|
||||
var draftTitle = tiddler.fields["draft.title"],
|
||||
draftOf = tiddler.fields["draft.of"];
|
||||
var draftTitle = (tiddler.fields["draft.title"] || "").trim(),
|
||||
draftOf = (tiddler.fields["draft.of"] || "").trim();
|
||||
if(draftTitle) {
|
||||
var isRename = draftOf !== draftTitle,
|
||||
isConfirmed = true;
|
||||
@@ -249,7 +259,7 @@ NavigatorWidget.prototype.handleSaveTiddlerEvent = function(event) {
|
||||
"draft.of": undefined
|
||||
},this.wiki.getModificationFields()));
|
||||
// Remove the draft tiddler
|
||||
this.wiki.deleteTiddler(event.tiddlerTitle);
|
||||
this.wiki.deleteTiddler(title);
|
||||
// Remove the original tiddler if we're renaming it
|
||||
if(isRename) {
|
||||
this.wiki.deleteTiddler(draftOf);
|
||||
@@ -275,22 +285,23 @@ NavigatorWidget.prototype.handleSaveTiddlerEvent = function(event) {
|
||||
NavigatorWidget.prototype.handleCancelTiddlerEvent = function(event) {
|
||||
this.getStoryList();
|
||||
var storyTiddlerModified = false;
|
||||
for(var t=0; t<this.storyList.length; t++) {
|
||||
if(this.storyList[t] === event.tiddlerTitle) {
|
||||
var tiddler = this.wiki.getTiddler(event.tiddlerTitle);
|
||||
if(tiddler && tiddler.hasField("draft.title")) {
|
||||
// Remove the draft tiddler
|
||||
this.wiki.deleteTiddler(event.tiddlerTitle);
|
||||
// Flip the specified tiddler from draft back to the original
|
||||
var draftTitle = event.param || event.tiddlerTitle,
|
||||
draftTiddler = this.wiki.getTiddler(draftTitle);
|
||||
if(draftTiddler && draftTiddler.hasField("draft.of")) {
|
||||
var originalTitle = draftTiddler.fields["draft.of"];
|
||||
// Remove the draft tiddler
|
||||
this.wiki.deleteTiddler(draftTitle);
|
||||
// Swap the draft for the original in the story
|
||||
for(var t=0; t<this.storyList.length; t++) {
|
||||
if(this.storyList[t] === draftTitle) {
|
||||
// Make the story record point to the original tiddler
|
||||
this.storyList[t] = tiddler.fields["draft.title"];
|
||||
// Check if we're modifying the story tiddler itself
|
||||
if(tiddler.fields["draft.title"] === this.storyTitle) {
|
||||
storyTiddlerModified = true;
|
||||
}
|
||||
this.storyList[t] = originalTitle;
|
||||
storyTiddlerModified = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
if(!storyTiddlerModified) {
|
||||
if(storyTiddlerModified) {
|
||||
this.saveStoryList();
|
||||
}
|
||||
return false;
|
||||
@@ -352,21 +363,21 @@ NavigatorWidget.prototype.handleImportTiddlersEvent = function(event) {
|
||||
}
|
||||
// Process each tiddler
|
||||
$tw.utils.each(tiddlers,function(tiddlerFields) {
|
||||
// Generate a unique title for the tiddler
|
||||
var title = self.wiki.generateNewTitle(tiddlerFields.title);
|
||||
var title = tiddlerFields.title;
|
||||
// Add it to the store
|
||||
self.wiki.addTiddler(new $tw.Tiddler(
|
||||
var imported = self.wiki.importTiddler(new $tw.Tiddler(
|
||||
self.wiki.getCreationFields(),
|
||||
tiddlerFields,
|
||||
self.wiki.getModificationFields(),
|
||||
{title: title}
|
||||
tiddlerFields
|
||||
));
|
||||
// Add it to the story
|
||||
if(self.storyList.indexOf(title) === -1) {
|
||||
self.storyList.unshift(title);
|
||||
if(imported) {
|
||||
// Add it to the story
|
||||
if(self.storyList.indexOf(title) === -1) {
|
||||
self.storyList.unshift(title);
|
||||
}
|
||||
// And to history
|
||||
history.push({title: title});
|
||||
}
|
||||
// And to history
|
||||
history.push({title: title});
|
||||
});
|
||||
// Save the updated story and history
|
||||
this.saveStoryList();
|
||||
|
||||
@@ -34,7 +34,7 @@ PasswordWidget.prototype.render = function(parent,nextSibling) {
|
||||
// Execute our logic
|
||||
this.execute();
|
||||
// Get the current password
|
||||
var password = $tw.browser ? $tw.utils.getPassword(this.passwordName) : "";
|
||||
var password = $tw.browser ? $tw.utils.getPassword(this.passwordName) || "" : "";
|
||||
// Create our element
|
||||
var domNode = this.document.createElement("input");
|
||||
domNode.setAttribute("type","password");
|
||||
@@ -77,16 +77,6 @@ PasswordWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
PasswordWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.password = PasswordWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -38,6 +38,7 @@ RevealWidget.prototype.render = function(parent,nextSibling) {
|
||||
this.renderChildren(domNode,null);
|
||||
if(!domNode.isTiddlyWikiFakeDom && this.type === "popup" && this.isOpen) {
|
||||
this.positionPopup(domNode);
|
||||
$tw.utils.addClass(domNode,"tw-popup"); // Make sure that clicks don't dismiss popups within the revealed content
|
||||
}
|
||||
if(!this.isOpen) {
|
||||
domNode.setAttribute("hidden","true")
|
||||
@@ -179,6 +180,8 @@ RevealWidget.prototype.updateState = function() {
|
||||
// Animate our DOM node
|
||||
if(!domNode.isTiddlyWikiFakeDom && this.type === "popup" && this.isOpen) {
|
||||
this.positionPopup(domNode);
|
||||
$tw.utils.addClass(domNode,"tw-popup"); // Make sure that clicks don't dismiss popups within the revealed content
|
||||
|
||||
}
|
||||
if(this.isOpen) {
|
||||
domNode.removeAttribute("hidden");
|
||||
@@ -190,16 +193,6 @@ RevealWidget.prototype.updateState = function() {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
RevealWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.reveal = RevealWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
/*\
|
||||
title: $:/core/modules/widgets/setvariable.js
|
||||
title: $:/core/modules/widgets/set.js
|
||||
type: application/javascript
|
||||
module-type: widget
|
||||
|
||||
Setvariable widget
|
||||
Set variable widget
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
@@ -14,19 +14,19 @@ Setvariable widget
|
||||
|
||||
var Widget = require("$:/core/modules/widgets/widget.js").widget;
|
||||
|
||||
var SetVariableWidget = function(parseTreeNode,options) {
|
||||
var SetWidget = function(parseTreeNode,options) {
|
||||
this.initialise(parseTreeNode,options);
|
||||
};
|
||||
|
||||
/*
|
||||
Inherit from the base widget class
|
||||
*/
|
||||
SetVariableWidget.prototype = new Widget();
|
||||
SetWidget.prototype = new Widget();
|
||||
|
||||
/*
|
||||
Render this widget into the DOM
|
||||
*/
|
||||
SetVariableWidget.prototype.render = function(parent,nextSibling) {
|
||||
SetWidget.prototype.render = function(parent,nextSibling) {
|
||||
this.parentDomNode = parent;
|
||||
this.computeAttributes();
|
||||
this.execute();
|
||||
@@ -36,7 +36,7 @@ SetVariableWidget.prototype.render = function(parent,nextSibling) {
|
||||
/*
|
||||
Compute the internal state of the widget
|
||||
*/
|
||||
SetVariableWidget.prototype.execute = function() {
|
||||
SetWidget.prototype.execute = function() {
|
||||
// Get our parameters
|
||||
this.setName = this.getAttribute("name","currentTiddler");
|
||||
this.setValue = this.getAttribute("value");
|
||||
@@ -49,7 +49,7 @@ SetVariableWidget.prototype.execute = function() {
|
||||
/*
|
||||
Selectively refreshes the widget if needed. Returns true if the widget or any of its children needed re-rendering
|
||||
*/
|
||||
SetVariableWidget.prototype.refresh = function(changedTiddlers) {
|
||||
SetWidget.prototype.refresh = function(changedTiddlers) {
|
||||
var changedAttributes = this.computeAttributes();
|
||||
if(changedAttributes.name || changedAttributes.value) {
|
||||
this.refreshSelf();
|
||||
@@ -59,6 +59,7 @@ SetVariableWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
exports.setvariable = SetVariableWidget;
|
||||
exports.setvariable = SetWidget;
|
||||
exports.set = SetWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -48,16 +48,6 @@ TextNodeWidget.prototype.refresh = function(changedTiddlers) {
|
||||
return false;
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
TextNodeWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.text = TextNodeWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -30,9 +30,14 @@ ViewWidget.prototype.render = function(parent,nextSibling) {
|
||||
this.parentDomNode = parent;
|
||||
this.computeAttributes();
|
||||
this.execute();
|
||||
var textNode = this.document.createTextNode(this.text);
|
||||
parent.insertBefore(textNode,nextSibling);
|
||||
this.domNodes.push(textNode);
|
||||
if(this.text) {
|
||||
var textNode = this.document.createTextNode(this.text);
|
||||
parent.insertBefore(textNode,nextSibling);
|
||||
this.domNodes.push(textNode);
|
||||
} else {
|
||||
this.makeChildWidgets();
|
||||
this.renderChildren(parent,nextSibling);
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -52,6 +57,12 @@ ViewWidget.prototype.execute = function() {
|
||||
case "htmlencoded":
|
||||
this.text = this.getValueAsHtmlEncoded();
|
||||
break;
|
||||
case "urlencoded":
|
||||
this.text = this.getValueAsUrlEncoded();
|
||||
break;
|
||||
case "doubleurlencoded":
|
||||
this.text = this.getValueAsDoubleUrlEncoded();
|
||||
break;
|
||||
case "date":
|
||||
this.text = this.getValueAsDate(this.viewTemplate);
|
||||
break;
|
||||
@@ -121,15 +132,29 @@ ViewWidget.prototype.getValueAsText = function() {
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsHtmlWikified = function() {
|
||||
return this.wiki.renderText("text/html","text/vnd.tiddlywiki",this.getValueAsText(),this);
|
||||
return this.wiki.renderText("text/html","text/vnd.tiddlywiki",this.getValueAsText(),{parentWidget: this});
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsHtmlEncoded = function() {
|
||||
return $tw.utils.htmlEncode(this.getValueAsText());
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsUrlEncoded = function() {
|
||||
return encodeURIComponent(this.getValueAsText());
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsDoubleUrlEncoded = function() {
|
||||
return encodeURIComponent(encodeURIComponent(this.getValueAsText()));
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsDate = function(format) {
|
||||
return $tw.utils.formatDateString(this.getValue(),format);
|
||||
format = format || "YYYY MM DD 0hh:0ss";
|
||||
var value = $tw.utils.parseDate(this.getValue());
|
||||
if(value && $tw.utils.isDate(value) && value.toString() !== "Invalid Date") {
|
||||
return $tw.utils.formatDateString(value,format);
|
||||
} else {
|
||||
return "";
|
||||
}
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsRelativeDate = function(format) {
|
||||
@@ -170,16 +195,6 @@ ViewWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
ViewWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.view = ViewWidget;
|
||||
|
||||
})();
|
||||
|
||||
@@ -38,8 +38,10 @@ Widget.prototype.initialise = function(parseTreeNode,options) {
|
||||
// Save widget info
|
||||
this.parseTreeNode = parseTreeNode;
|
||||
this.wiki = options.wiki;
|
||||
this.variables = options.variables || {};
|
||||
this.parentWidget = options.parentWidget;
|
||||
this.variablesConstructor = function() {};
|
||||
this.variablesConstructor.prototype = this.parentWidget ? this.parentWidget.variables : {};
|
||||
this.variables = new this.variablesConstructor();
|
||||
this.document = options.document;
|
||||
this.attributes = {};
|
||||
this.children = [];
|
||||
@@ -67,6 +69,16 @@ Widget.prototype.execute = function() {
|
||||
this.makeChildWidgets();
|
||||
};
|
||||
|
||||
/*
|
||||
Set the value of a context variable
|
||||
name: name of the variable
|
||||
value: value of the variable
|
||||
params: array of {name:, default:} for each parameter
|
||||
*/
|
||||
Widget.prototype.setVariable = function(name,value,params) {
|
||||
this.variables[name] = {value: value, params: params};
|
||||
};
|
||||
|
||||
/*
|
||||
Get the prevailing value of a context variable
|
||||
name: name of variable
|
||||
@@ -78,19 +90,14 @@ defaultValue: default value if the variable is not defined
|
||||
Widget.prototype.getVariable = function(name,options) {
|
||||
options = options || {};
|
||||
var actualParams = options.params || [];
|
||||
// Search up the widget tree for the variable name
|
||||
var node = this;
|
||||
while(node && !$tw.utils.hop(node.variables,name)) {
|
||||
node = node.parentWidget;
|
||||
}
|
||||
// If we get to the root then look for a macro module
|
||||
if(!node) {
|
||||
// If the variable doesn't exist then look for a macro module
|
||||
if(!(name in this.variables)) {
|
||||
return this.evaluateMacroModule(name,actualParams,options.defaultValue);
|
||||
}
|
||||
// Get the value
|
||||
var value = node.variables[name].value || "";
|
||||
var variable = this.variables[name],
|
||||
value = variable.value || "";
|
||||
// Substitute any parameters specified in the definition
|
||||
value = this.substituteVariableParameters(value,node.variables[name].params,actualParams);
|
||||
value = this.substituteVariableParameters(value,variable.params,actualParams);
|
||||
value = this.substituteVariableReferences(value);
|
||||
return value;
|
||||
};
|
||||
@@ -166,16 +173,6 @@ Widget.prototype.evaluateMacroModule = function(name,actualParams,defaultValue)
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Set the value of a context variable
|
||||
name: name of the variable
|
||||
value: value of the variable
|
||||
params: array of {name:, default:} for each parameter
|
||||
*/
|
||||
Widget.prototype.setVariable = function(name,value,params) {
|
||||
this.variables[name] = {value: value, params: params};
|
||||
};
|
||||
|
||||
/*
|
||||
Check whether a given context variable value exists in the parent chain
|
||||
*/
|
||||
@@ -191,7 +188,7 @@ Widget.prototype.hasVariable = function(name,value) {
|
||||
};
|
||||
|
||||
/*
|
||||
Construct a qualifying string based on concatenating the values of a given variable in the parent chain
|
||||
Construct a qualifying string based on a hash of concatenating the values of a given variable in the parent chain
|
||||
*/
|
||||
Widget.prototype.getStateQualifier = function(name) {
|
||||
name = name || "transclusion";
|
||||
@@ -203,7 +200,7 @@ Widget.prototype.getStateQualifier = function(name) {
|
||||
}
|
||||
node = node.parentWidget;
|
||||
}
|
||||
return output.join("");
|
||||
return "{" + $tw.utils.hashString(output.join("")) + "}";
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -217,8 +214,7 @@ Widget.prototype.computeAttributes = function() {
|
||||
if(attribute.type === "indirect") {
|
||||
value = self.wiki.getTextReference(attribute.textReference,"",self.getVariable("currentTiddler"));
|
||||
} else if(attribute.type === "macro") {
|
||||
var text = self.getVariable(attribute.value.name,{params: attribute.value.params});
|
||||
value = self.wiki.renderText("text/plain","text/vnd.tiddlywiki",text);
|
||||
value = self.getVariable(attribute.value.name,{params: attribute.value.params});
|
||||
} else { // String attribute
|
||||
value = attribute.value;
|
||||
}
|
||||
@@ -450,9 +446,18 @@ Widget.prototype.findFirstDomNode = function() {
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
Widget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.children,function(childWidget) {
|
||||
childWidget.removeChildDomNodes();
|
||||
});
|
||||
// If this widget has directly created DOM nodes, delete them and exit. This assumes that any child widgets are contained within the created DOM nodes, which would normally be the case
|
||||
if(this.domNodes.length > 0) {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
} else {
|
||||
// Otherwise, ask the child widgets to delete their DOM nodes
|
||||
$tw.utils.each(this.children,function(childWidget) {
|
||||
childWidget.removeChildDomNodes();
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
exports.widget = Widget;
|
||||
|
||||
@@ -8,14 +8,12 @@ Extension methods for the $tw.Wiki object
|
||||
Adds the following properties to the wiki object:
|
||||
|
||||
* `eventListeners` is a hashmap by type of arrays of listener functions
|
||||
* `changedTiddlers` is a hashmap describing changes to named tiddlers since wiki change events were
|
||||
last dispatched. Each entry is a hashmap containing two fields:
|
||||
* `changedTiddlers` is a hashmap describing changes to named tiddlers since wiki change events were last dispatched. Each entry is a hashmap containing two fields:
|
||||
modified: true/false
|
||||
deleted: true/false
|
||||
* `changeCount` is a hashmap by tiddler title containing a numerical index that starts at zero and is
|
||||
incremented each time a tiddler is created changed or deleted
|
||||
* `caches` is a hashmap by tiddler title containing a further hashmap of named cache objects. Caches
|
||||
are automatically cleared when a tiddler is modified or deleted
|
||||
* `changeCount` is a hashmap by tiddler title containing a numerical index that starts at zero and is incremented each time a tiddler is created changed or deleted
|
||||
* `caches` is a hashmap by tiddler title containing a further hashmap of named cache objects. Caches are automatically cleared when a tiddler is modified or deleted
|
||||
* `globalCache` is a hashmap by cache name of cache objects that are cleared whenever any tiddler change occurs
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
@@ -163,6 +161,7 @@ exports.getChangeCount = function(title) {
|
||||
exports.deleteTiddler = function(title) {
|
||||
delete this.tiddlers[title];
|
||||
this.clearCache(title);
|
||||
this.clearGlobalCache();
|
||||
this.enqueueTiddlerEvent(title,true);
|
||||
};
|
||||
|
||||
@@ -207,9 +206,27 @@ exports.addTiddler = function(tiddler) {
|
||||
// Save the tiddler
|
||||
this.tiddlers[title] = tiddler;
|
||||
this.clearCache(title);
|
||||
this.clearGlobalCache();
|
||||
this.enqueueTiddlerEvent(title);
|
||||
};
|
||||
|
||||
/*
|
||||
Like addTiddler() except it will silently reject any plugin tiddlers that are older than the currently loaded version. Returns true if the tiddler was imported
|
||||
*/
|
||||
exports.importTiddler = function(tiddler) {
|
||||
var existingTiddler = this.getTiddler(tiddler.fields.title);
|
||||
// Check if we're dealing with a plugin
|
||||
if(tiddler && tiddler.hasField("plugin-type") && tiddler.hasField("version") && existingTiddler && existingTiddler.hasField("plugin-type") && existingTiddler.hasField("version")) {
|
||||
// Reject the incoming plugin if it is older
|
||||
if($tw.utils.checkVersions(existingTiddler.fields.version,tiddler.fields.version)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
// Fall through to adding the tiddler
|
||||
this.addTiddler(tiddler);
|
||||
return true;
|
||||
};
|
||||
|
||||
/*
|
||||
Return a hashmap of the fields that should be set when a tiddler is created
|
||||
*/
|
||||
@@ -425,15 +442,36 @@ exports.getShadowTitles = function() {
|
||||
Retrieves a list of the tiddler titles that are tagged with a given tag
|
||||
*/
|
||||
exports.getTiddlersWithTag = function(tag) {
|
||||
// Get the list associated with the tag
|
||||
var titles = [];
|
||||
for(var title in this.tiddlers) {
|
||||
var tiddler = this.tiddlers[title];
|
||||
if($tw.utils.isArray(tiddler.fields.tags) && tiddler.fields.tags.indexOf(tag) !== -1) {
|
||||
titles.push(title);
|
||||
var self = this;
|
||||
return this.getGlobalCache("taglist-" + tag,function() {
|
||||
var tagmap = self.getTagMap();
|
||||
return self.sortByList(tagmap[tag],tag);
|
||||
});
|
||||
};
|
||||
|
||||
/*
|
||||
Get a hashmap by tag of arrays of tiddler titles
|
||||
*/
|
||||
exports.getTagMap = function() {
|
||||
var self = this;
|
||||
return this.getGlobalCache("tagmap",function() {
|
||||
var tags = {};
|
||||
// Collect up all the tags
|
||||
for(var title in self.tiddlers) {
|
||||
var tiddler = self.tiddlers[title];
|
||||
if(tiddler.fields.tags) {
|
||||
for(var index=0; index<tiddler.fields.tags.length; index++) {
|
||||
var tag = tiddler.fields.tags[index];
|
||||
if(tags[tag]) {
|
||||
tags[tag].push(title)
|
||||
} else {
|
||||
tags[tag] = [title];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return this.sortByList(titles,tag);
|
||||
return tags;
|
||||
});
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -456,7 +494,9 @@ Sorts an array of tiddler titles according to an ordered list
|
||||
*/
|
||||
exports.sortByList = function(array,listTitle) {
|
||||
var list = this.getTiddlerList(listTitle);
|
||||
if(list) {
|
||||
if(!array || array.length === 0) {
|
||||
return [];
|
||||
} else if(list) {
|
||||
var titles = [], t, title;
|
||||
// First place any entries that are present in the list
|
||||
for(t=0; t<list.length; t++) {
|
||||
@@ -557,6 +597,21 @@ exports.getTiddlerList = function(title) {
|
||||
return [];
|
||||
};
|
||||
|
||||
// Return a named global cache object. Global cache objects are cleared whenever a tiddler change occurs
|
||||
exports.getGlobalCache = function(cacheName,initializer) {
|
||||
this.globalCache = this.globalCache || {};
|
||||
if($tw.utils.hop(this.globalCache,cacheName)) {
|
||||
return this.globalCache[cacheName];
|
||||
} else {
|
||||
this.globalCache[cacheName] = initializer();
|
||||
return this.globalCache[cacheName];
|
||||
}
|
||||
};
|
||||
|
||||
exports.clearGlobalCache = function() {
|
||||
this.globalCache = {};
|
||||
}
|
||||
|
||||
// Return the named cache object for a tiddler. If the cache doesn't exist then the initializer function is invoked to create it
|
||||
exports.getCacheForTiddler = function(title,cacheName,initializer) {
|
||||
|
||||
@@ -654,7 +709,7 @@ var tweakParseTreeNodes = function(nodeList) {
|
||||
|
||||
var tweakMacroDefinition = function(nodeList) {
|
||||
if(nodeList && nodeList[0] && nodeList[0].type === "macrodef") {
|
||||
nodeList[0].type = "setvariable";
|
||||
nodeList[0].type = "set";
|
||||
nodeList[0].attributes = {
|
||||
name: {type: "string", value: nodeList[0].name},
|
||||
value: {type: "string", value: nodeList[0].text}
|
||||
@@ -690,6 +745,9 @@ exports.parseTiddler = function(title,options) {
|
||||
|
||||
exports.parseTextReference = function(title,field,index,options) {
|
||||
if(field === "text" || (!field && !index)) {
|
||||
// Force the tiddler to be lazily loaded
|
||||
this.getTiddlerText(title);
|
||||
// Parse it
|
||||
return this.parseTiddler(title,options);
|
||||
} else {
|
||||
var tiddler,text;
|
||||
@@ -723,10 +781,10 @@ exports.makeWidget = function(parser,options) {
|
||||
children: []
|
||||
},
|
||||
currWidgetNode = widgetNode;
|
||||
// Create setvariable widgets for each variable
|
||||
// Create set variable widgets for each variable
|
||||
$tw.utils.each(options.variables,function(value,name) {
|
||||
var setVariableWidget = {
|
||||
type: "setvariable",
|
||||
type: "set",
|
||||
attributes: {
|
||||
name: {type: "string", value: name},
|
||||
value: {type: "string", value: value}
|
||||
@@ -758,7 +816,7 @@ parentWidget: optional parent widget for the root node
|
||||
*/
|
||||
exports.renderText = function(outputType,textType,text,options) {
|
||||
options = options || {};
|
||||
var parser = $tw.wiki.parseText(textType,text),
|
||||
var parser = this.parseText(textType,text,options),
|
||||
widgetNode = this.makeWidget(parser,options);
|
||||
var container = $tw.document.createElement("div");
|
||||
widgetNode.render(container,null);
|
||||
@@ -825,16 +883,22 @@ exports.callSaver = function(method /*, args */ ) {
|
||||
|
||||
/*
|
||||
Save the wiki contents. Options are:
|
||||
method: "save" or "download"
|
||||
template: the tiddler containing the template to save
|
||||
downloadType: the content type for the saved file
|
||||
*/
|
||||
exports.saveWiki = function(options) {
|
||||
options = options || {};
|
||||
var template = options.template || "$:/core/templates/tiddlywiki5.template.html",
|
||||
var method = options.method || "save",
|
||||
template = options.template || "$:/core/save/all",
|
||||
downloadType = options.downloadType || "text/plain";
|
||||
var text = this.renderTiddler(downloadType,template);
|
||||
this.callSaver("save",text,function(err) {
|
||||
$tw.notifier.display("$:/messages/Saved");
|
||||
this.callSaver("save",text,method,function(err) {
|
||||
if(err) {
|
||||
alert("Error while saving:\n\n" + err);
|
||||
} else {
|
||||
$tw.notifier.display("$:/messages/Saved");
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
@@ -875,7 +939,7 @@ exports.search = function(text,options) {
|
||||
// Function to check a given tiddler for the search term
|
||||
var searchTiddler = function(title) {
|
||||
if(!searchTermsRegExps) {
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
var tiddler = self.getTiddler(title);
|
||||
if(!tiddler) {
|
||||
|
||||
6
core/templates/save-all.tid
Normal file
6
core/templates/save-all.tid
Normal file
@@ -0,0 +1,6 @@
|
||||
title: $:/core/save/all
|
||||
|
||||
\define saveTiddlerFilter()
|
||||
[is[tiddler]] -[type[text/css]] -[type[application/javascript]has[module-type]] -[type[application/javascript]library[yes]] -[[$:/boot/boot.js]] -[[$:/boot/bootprefix.js]] +[sort[title]]
|
||||
\end
|
||||
{{$:/core/templates/tiddlywiki5.html}}
|
||||
6
core/templates/save-empty.tid
Normal file
6
core/templates/save-empty.tid
Normal file
@@ -0,0 +1,6 @@
|
||||
title: $:/core/save/empty
|
||||
|
||||
\define saveTiddlerFilter()
|
||||
[is[system]] -[type[text/css]] -[type[application/javascript]has[module-type]] -[type[application/javascript]library[yes]] -[[$:/boot/boot.js]] -[[$:/boot/bootprefix.js]] +[sort[title]]
|
||||
\end
|
||||
{{$:/core/templates/tiddlywiki5.html}}
|
||||
8
core/templates/static.area.tid
Normal file
8
core/templates/static.area.tid
Normal file
@@ -0,0 +1,8 @@
|
||||
title: $:/core/templates/static.area
|
||||
|
||||
<$reveal type="nomatch" state="$:/isEncrypted" text="yes">
|
||||
{{$:/core/templates/static.content||$:/core/templates/html-tiddler}}
|
||||
</$reveal>
|
||||
<$reveal type="match" state="$:/isEncrypted" text="yes">
|
||||
This file contains an encrypted ~TiddlyWiki. Enable ~JavaScript and enter the decryption password when prompted.
|
||||
</$reveal>
|
||||
@@ -2,6 +2,10 @@ title: $:/core/templates/static.content
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<!-- For Google, and people without JavaScript-->
|
||||
<$list filter="[!is[system]sort[title]]" >
|
||||
<$view field="title" format="text"></$view>
|
||||
This [[TiddlyWiki|http://tiddlywiki.com]] contains the following tiddlers:
|
||||
|
||||
<ul>
|
||||
<$list filter=<<saveTiddlerFilter>>>
|
||||
<li><$view field="title" format="text"></$view></li>
|
||||
</$list>
|
||||
</ul>
|
||||
|
||||
@@ -2,12 +2,12 @@ title: $:/core/templates/store.area.template.html
|
||||
|
||||
<$reveal type="nomatch" state="$:/isEncrypted" text="yes">
|
||||
`<div id="storeArea" style="display:none;">`
|
||||
{{{ [!is[system]] ||$:/core/templates/html-div-tiddler}}}
|
||||
<$list filter=<<saveTiddlerFilter>> template="$:/core/templates/html-div-tiddler"/>
|
||||
`</div>`
|
||||
</$reveal>
|
||||
<$reveal type="match" state="$:/isEncrypted" text="yes">
|
||||
`<!------------- Encrypted tiddlers --------->`
|
||||
`<pre id="encryptedStoreArea" type="text/plain" style="display:none;">`
|
||||
<$encrypt filter="[!is[system]]"/>
|
||||
<$encrypt filter=<<saveTiddlerFilter>>/>
|
||||
`</pre>`
|
||||
</$reveal>
|
||||
@@ -1,4 +1,4 @@
|
||||
title: $:/core/templates/tiddlywiki5.template.html
|
||||
title: $:/core/templates/tiddlywiki5.html
|
||||
|
||||
\rules only filteredtranscludeinline transcludeinline
|
||||
<!doctype html>
|
||||
@@ -27,19 +27,14 @@ title: $:/core/templates/tiddlywiki5.template.html
|
||||
<!----------- Static content for Google and browsers without JavaScript ----------->
|
||||
<noscript>
|
||||
<div id="splashArea">
|
||||
{{$:/core/templates/static.content||$:/core/templates/html-tiddler}}
|
||||
{{$:/core/templates/static.area}}
|
||||
</div>
|
||||
</noscript>
|
||||
<!----------- Miscellaneous system tiddlers ----------->
|
||||
<div id="systemArea" style="display:none;">
|
||||
{{{ [is[system]] -[type[text/css]] -[type[application/javascript]has[module-type]] -[type[application/javascript]library[yes]] -[[$:/boot/boot.js]] -[[$:/boot/bootprefix.js]] ||$:/core/templates/html-div-tiddler}}}
|
||||
</div>
|
||||
<!----------- Ordinary tiddlers ----------->
|
||||
{{$:/core/templates/store.area.template.html}}
|
||||
<!----------- Library modules ----------->
|
||||
<div id="libraryModules" style="display:none;">
|
||||
{{$:/core/lib/jquery.min.js||$:/core/templates/javascript-tiddler}}
|
||||
{{{ [is[system]type[application/javascript]library[yes]] -[[$:/core/lib/jquery.min.js]] ||$:/core/templates/javascript-tiddler}}}
|
||||
{{{ [is[system]type[application/javascript]library[yes]] ||$:/core/templates/javascript-tiddler}}}
|
||||
</div>
|
||||
<!----------- Boot kernel prologue ----------->
|
||||
<div id="bootKernelPrefix" style="display:none;">
|
||||
3
core/ui/ControlPanel.tid
Normal file
3
core/ui/ControlPanel.tid
Normal file
@@ -0,0 +1,3 @@
|
||||
title: $:/ControlPanel
|
||||
|
||||
<div class="tw-control-panel"><<tabs "[is[shadow]!has[draft.of]tag[$:/tags/ControlPanel]] [!is[shadow]!has[draft.of]tag[$:/tags/ControlPanel]] +[tag[$:/tags/ControlPanel]]" "$:/core/ui/ControlPanel/Basics">></div>
|
||||
11
core/ui/ControlPanel/Appearance.tid
Normal file
11
core/ui/ControlPanel/Appearance.tid
Normal file
@@ -0,0 +1,11 @@
|
||||
title: $:/core/ui/ControlPanel/Appearance
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Appearance
|
||||
|
||||
! Theme
|
||||
|
||||
{{$:/snippets/themeswitcher}}
|
||||
|
||||
! Story View
|
||||
|
||||
{{$:/snippets/viewswitcher}}
|
||||
23
core/ui/ControlPanel/Basics.tid
Normal file
23
core/ui/ControlPanel/Basics.tid
Normal file
@@ -0,0 +1,23 @@
|
||||
title: $:/core/ui/ControlPanel/Basics
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Basics
|
||||
|
||||
! Settings
|
||||
|
||||
|[[Title of this TiddlyWiki|SiteTitle]] |<$edit-text tiddler="SiteTitle" default="" tag="input"/> |
|
||||
|[[Subtitle|SiteSubtitle]] |<$edit-text tiddler="SiteSubtitle" default="" tag="input"/> |
|
||||
|[[Username for signing edits|$:/status/UserName]] |<$edit-text tiddler="$:/status/UserName" default="" tag="input"/> |
|
||||
|[[Animation duration|$:/config/AnimationDuration]] |<$edit-text tiddler="$:/config/AnimationDuration" default="" tag="input"/> |
|
||||
|[[DefaultTiddlers|$:/DefaultTiddlers]] |Choose which tiddlers are displayed at startup:<br> <$edit-text tag="textarea" tiddler="$:/DefaultTiddlers"/> |
|
||||
|
||||
! Info
|
||||
|
||||
!! Your Stuff
|
||||
|
||||
* Number of tiddlers: <$count filter="[!is[system]]"/>
|
||||
|
||||
!! TiddlyWiki's Stuff
|
||||
|
||||
* Number of system tiddlers: <$count filter="[is[system]]"/>
|
||||
* Number of shadow tiddlers: <$count filter="[is[shadow]]"/>
|
||||
** Number of over-ridden shadow tiddlers: <$count filter="[!is[system]is[shadow]]"/>
|
||||
@@ -1,6 +1,6 @@
|
||||
title: $:/ConfigInfo
|
||||
|
||||
This tiddler displays the internal configuration of this wiki, which can be useful for troubleshooting, or just to help understand how TiddlyWiki5 works.
|
||||
title: $:/core/ui/ControlPanel/Internals
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Internals
|
||||
|
||||
! Tiddler fields
|
||||
|
||||
7
core/ui/ControlPanel/Plugins.tid
Normal file
7
core/ui/ControlPanel/Plugins.tid
Normal file
@@ -0,0 +1,7 @@
|
||||
title: $:/core/ui/ControlPanel/Plugins
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Plugins
|
||||
|
||||
<table><tbody><tr><th>Title</th><th>Description</th><th>Version</th></tr><$list filter="[!has[draft.of]has[plugin-type]sort[title]]"><tr><td><$link to={{!!title}}><$view field="title"/></$link></td><td><$view field="description"/></td><td><$view field="version"/></td></tr></$list>
|
||||
</tbody>
|
||||
</table>
|
||||
22
core/ui/ControlPanel/Saving.tid
Normal file
22
core/ui/ControlPanel/Saving.tid
Normal file
@@ -0,0 +1,22 @@
|
||||
title: $:/core/ui/ControlPanel/Saving
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Saving
|
||||
|
||||
\define backupURL()
|
||||
http://$(userName)$.tiddlyspot.com/backup/
|
||||
\end
|
||||
\define backupLink()
|
||||
<$reveal type="nomatch" state="$:/UploadName" text="">
|
||||
<$set name="userName" value={{$:/UploadName}}>
|
||||
<a href=<<backupURL>>><$macrocall $name="backupURL" $type="text/plain" $output="text/plain"/></a>
|
||||
</$set>
|
||||
</$reveal>
|
||||
\end
|
||||
! TiddlySpot
|
||||
|
||||
|[[Wiki name|$:/UploadName]] |<$edit-text tiddler="$:/UploadName" default="" tag="input"/> |
|
||||
|Password |<$password name="upload"/> |
|
||||
|Server URL |<$edit-text tiddler="$:/UploadURL" default="" tag="input"/> |
|
||||
|Backups |<<backupLink>> |
|
||||
|
||||
//The server URL defaults to `http://<wikiname>.tiddlyspot.com/store.cgi` and can be changed to use a custom server address//
|
||||
13
core/ui/ControlPanel/Tools.tid
Normal file
13
core/ui/ControlPanel/Tools.tid
Normal file
@@ -0,0 +1,13 @@
|
||||
title: $:/core/ui/ControlPanel/Tools
|
||||
tags: $:/tags/ControlPanel
|
||||
caption: Tools
|
||||
|
||||
! Import
|
||||
|
||||
<$browse/>
|
||||
|
||||
Browse for files on your computer to import their contents (the individual tiddlers within TiddlyWiki HTML files are imported separately). You can also drag and drop files directly to the browser window.
|
||||
|
||||
! Encryption
|
||||
|
||||
{{$:/snippets/encryptionstatus}}
|
||||
@@ -2,30 +2,6 @@ title: $:/core/ui/EditTemplate
|
||||
modifier: JeremyRuston
|
||||
|
||||
\define frame-classes()
|
||||
tw-tiddler-frame $(missingTiddlerClass)$ $(shadowTiddlerClass)$ $(systemTiddlerClass)$
|
||||
tw-tiddler-frame tw-tiddler-edit-frame $(missingTiddlerClass)$ $(shadowTiddlerClass)$ $(systemTiddlerClass)$
|
||||
\end
|
||||
<div class=<<frame-classes>>><span class="tw-tiddler-controls titlebar"> <$button message="tw-delete-tiddler" class="btn-invisible">{{$:/core/images/delete-button}}</$button> <$button message="tw-cancel-tiddler" class="btn-invisible">{{$:/core/images/cancel-button}}</$button> <$button message="tw-save-tiddler" class="btn-invisible">{{$:/core/images/done-button}}</$button> </span>
|
||||
|
||||
<$view field="title"/>
|
||||
|
||||
<$edit-text field="draft.title" class="titlebar tw-edit-texteditor"/>
|
||||
|
||||
<$transclude tiddler="$:/core/ui/TagsEditor"/>
|
||||
|
||||
<$reveal state="$:/ShowEditPreview" type="match" text="yes">
|
||||
<$transclude tiddler="$:/core/ui/EditorHint"/> <$button type="set" set="$:/ShowEditPreview" setTo="no">hide preview</$button>
|
||||
<div class="tw-tiddler-preview">
|
||||
<div class="tw-tiddler-preview-preview">
|
||||
<$transclude />
|
||||
</div>
|
||||
<div class="tw-tiddler-preview-edit">
|
||||
<$edit field="text" class="tw-edit-texteditor"/>
|
||||
</div>
|
||||
</div>
|
||||
</$reveal>
|
||||
<$reveal state="$:/ShowEditPreview" type="nomatch" text="yes">
|
||||
<$transclude tiddler="$:/core/ui/EditorHint"/> <$button type="set" set="$:/ShowEditPreview" setTo="yes">show preview</$button>
|
||||
<$edit field="text" class="tw-edit-texteditor"/>
|
||||
</$reveal>
|
||||
|
||||
<$transclude tiddler="$:/core/ui/FieldEditor"/></div>
|
||||
<div class=<<frame-classes>>><$list filter="[is[shadow]!has[draft.of]tag[$:/tags/EditTemplate]] [!is[shadow]!has[draft.of]tag[$:/tags/EditTemplate]] +[tag[$:/tags/EditTemplate]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list></div>
|
||||
|
||||
18
core/ui/EditTemplate/body.tid
Normal file
18
core/ui/EditTemplate/body.tid
Normal file
@@ -0,0 +1,18 @@
|
||||
title: $:/core/ui/EditTemplate/body
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<$reveal state="$:/ShowEditPreview" type="match" text="yes">
|
||||
//<$transclude tiddler="$:/core/ui/EditorHint"/>// <$button type="set" set="$:/ShowEditPreview" setTo="no">hide preview</$button>
|
||||
<div class="tw-tiddler-preview">
|
||||
<div class="tw-tiddler-preview-preview">
|
||||
<$transclude />
|
||||
</div>
|
||||
<div class="tw-tiddler-preview-edit">
|
||||
<$edit field="text" class="tw-edit-texteditor"/>
|
||||
</div>
|
||||
</div>
|
||||
</$reveal>
|
||||
<$reveal state="$:/ShowEditPreview" type="nomatch" text="yes">
|
||||
//<$transclude tiddler="$:/core/ui/EditorHint"/>// <$button type="set" set="$:/ShowEditPreview" setTo="yes">show preview</$button>
|
||||
<$edit field="text" class="tw-edit-texteditor"/>
|
||||
</$reveal>
|
||||
4
core/ui/EditTemplate/controls.tid
Normal file
4
core/ui/EditTemplate/controls.tid
Normal file
@@ -0,0 +1,4 @@
|
||||
title: $:/core/ui/EditTemplate/controls
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<span class="tw-tiddler-controls titlebar"> <$list filter="[is[shadow]!has[draft.of]tag[$:/tags/EditToolbar]] [!is[shadow]!has[draft.of]tag[$:/tags/EditToolbar]] +[tag[$:/tags/EditToolbar]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list> </span>
|
||||
14
core/ui/EditTemplate/fields.tid
Normal file
14
core/ui/EditTemplate/fields.tid
Normal file
@@ -0,0 +1,14 @@
|
||||
title: $:/core/ui/EditTemplate/fields
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<$fieldmangler><div class="tw-edit-fields">
|
||||
<table class="tw-edit-fields"><tbody><$list filter="[is[current]fields[]] -title -tags -text -creator -created -modified -modifier -type -[[draft.title]] -[[draft.of]]" variable="currentField"><tr class="tw-edit-field"><td class="tw-edit-field-name"><<currentField>>:</td><td class="tw-edit-field-value"><$edit-text tiddler=<<currentTiddler>> field=<<currentField>> placeholder="field value"/></td><td class="tw-edit-field-remove"><$button message="tw-remove-field" param=<<currentField>> class="btn-invisible">{{$:/core/images/delete-button}}</$button></td>
|
||||
</tr>
|
||||
</$list>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="tw-edit-field-add">//Add a new field:// <span class="tw-edit-field-add-name"><$edit-text tiddler="$:/NewFieldName" tag="input" default="" placeholder="field name" class="tw-edit-texteditor"/></span> <span class="tw-edit-field-add-button"><$button message="tw-add-field" param={{$:/NewFieldName}} set="$:/NewFieldName" setTo="" class="">add</$button></span></div>
|
||||
|
||||
</$fieldmangler>
|
||||
23
core/ui/EditTemplate/tags.tid
Normal file
23
core/ui/EditTemplate/tags.tid
Normal file
@@ -0,0 +1,23 @@
|
||||
title: $:/core/ui/EditTemplate/tags
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
\define tag-styles()
|
||||
background-color:$(backgroundColor)$;
|
||||
\end
|
||||
<div class="tw-edit-tags"><$fieldmangler><$list filter="[is[current]tags[]sort[title]]" storyview="pop" itemClass="tw-tag-editor-label"><$set name="backgroundColor" value={{!!color}}><span style=<<tag-styles>> class="tw-tag-label"><$view field="title" format="text" /><$button message="tw-remove-tag" param={{!!title}} class="btn-invisible tw-remove-tag-button">×</$button></span></$set>
|
||||
</$list>
|
||||
|
||||
<div class="tw-edit-add-tag"><span class="tw-add-tag-name"><$edit-text tiddler="$:/NewTagName" tag="input" default="" placeholder="tag name" focusPopup=<<qualify "$:/state/tagsAutoComplete">> class="tw-edit-texteditor"/></span> <$button popup=<<qualify "$:/state/tagsAutoComplete">> class="btn-invisible btn-dropdown">{{$:/core/images/down-arrow}}</$button> <span class="tw-add-tag-button"><$button message="tw-add-tag" param={{$:/NewTagName}} set="$:/NewTagName" setTo="" class="">add</$button></span></div>
|
||||
|
||||
<div class="tw-block-dropdown-wrapper">
|
||||
<$reveal state=<<qualify "$:/state/tagsAutoComplete">> type="nomatch" text="" default="">
|
||||
<div class="tw-block-dropdown">
|
||||
<$linkcatcher set="$:/NewTagName" setTo="" message="tw-add-tag"><$list filter="[!is[shadow]tags[]search{$:/NewTagName}sort[title]]"><$link><$set name="backgroundColor" value={{!!color}}><span style=<<tag-styles>> class="tw-tag-label"><$view field="title" format="text"/></span></$set></$link>
|
||||
</$list>
|
||||
</$linkcatcher>
|
||||
</div>
|
||||
|
||||
</$reveal>
|
||||
</div>
|
||||
</$fieldmangler>
|
||||
</div>
|
||||
6
core/ui/EditTemplate/title.tid
Normal file
6
core/ui/EditTemplate/title.tid
Normal file
@@ -0,0 +1,6 @@
|
||||
title: $:/core/ui/EditTemplate/title
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<$view field="title"/>
|
||||
|
||||
<$edit-text field="draft.title" class="titlebar tw-edit-texteditor"/>
|
||||
15
core/ui/EditTemplate/type.tid
Normal file
15
core/ui/EditTemplate/type.tid
Normal file
@@ -0,0 +1,15 @@
|
||||
title: $:/core/ui/EditTemplate/type
|
||||
tags: $:/tags/EditTemplate
|
||||
|
||||
<p>//Type:// <$edit-text field="type" tag="input" default="" placeholder="type" focusPopup=<<qualify "$:/state/typeDropdown">> class="tw-edit-typeeditor"/> <$button popup=<<qualify "$:/state/typeDropdown">> class="btn-invisible btn-dropdown">{{$:/core/images/down-arrow}}</$button></p>
|
||||
|
||||
<div class="tw-block-dropdown-wrapper">
|
||||
<$reveal state=<<qualify "$:/state/typeDropdown">> type="nomatch" text="" default="">
|
||||
<div class="tw-block-dropdown tw-edit-type-dropdown">
|
||||
<$linkcatcher to="!!type">
|
||||
<$list filter="[is[shadow]prefix[$:/docs/types/]] [!is[shadow]prefix[$:/docs/types/]] +[sort[description]]"><$link to={{!!name}}><$view field="description"/> (<$view field="name"/>)</$link>
|
||||
</$list>
|
||||
</$linkcatcher>
|
||||
</div>
|
||||
</$reveal>
|
||||
</div>
|
||||
4
core/ui/EditToolbar/cancel.tid
Normal file
4
core/ui/EditToolbar/cancel.tid
Normal file
@@ -0,0 +1,4 @@
|
||||
title: $:/core/ui/EditToolbar/cancel
|
||||
tags: $:/tags/EditToolbar
|
||||
|
||||
<$button message="tw-cancel-tiddler" class="btn-invisible">{{$:/core/images/cancel-button}}</$button>
|
||||
4
core/ui/EditToolbar/delete.tid
Normal file
4
core/ui/EditToolbar/delete.tid
Normal file
@@ -0,0 +1,4 @@
|
||||
title: $:/core/ui/EditToolbar/delete
|
||||
tags: $:/tags/EditToolbar
|
||||
|
||||
<$button message="tw-delete-tiddler" class="btn-invisible">{{$:/core/images/delete-button}}</$button>
|
||||
4
core/ui/EditToolbar/save.tid
Normal file
4
core/ui/EditToolbar/save.tid
Normal file
@@ -0,0 +1,4 @@
|
||||
title: $:/core/ui/EditToolbar/save
|
||||
tags: $:/tags/EditToolbar
|
||||
|
||||
<$button message="tw-save-tiddler" class="btn-invisible">{{$:/core/images/done-button}}</$button>
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/core/ui/EditorHint
|
||||
|
||||
<span class="tw-tiddler-help">Use WikiText to add formatting, images, and dynamic features</span>
|
||||
Use WikiText to add formatting, images, and dynamic features
|
||||
@@ -1,13 +0,0 @@
|
||||
title: $:/core/ui/FieldEditor
|
||||
|
||||
<$fieldmangler><div class="tw-edit-fields">
|
||||
<table class="tw-edit-fields"><tbody><$list filter="[is[current]fields[]] -title -tags -text -creator -created -modified -modifier -[[draft.title]] -[[draft.of]]" variable="currentField"><tr class="tw-edit-field"><td class="tw-edit-field-name"><<currentField>>:</td><td class="tw-edit-field-value"><$edit-text tiddler=<<currentTiddler>> field=<<currentField>> placeholder="field value"/></td><td class="tw-edit-field-remove"><$button message="tw-remove-field" param=<<currentField>> class="btn-invisible">{{$:/core/images/delete-button}}</$button></td>
|
||||
</tr>
|
||||
</$list>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="tw-edit-field-add">Add a new field: <span class="tw-edit-field-add-name"><$edit-text tiddler="$:/NewFieldName" tag="input" default="" placeholder="field name" class="tw-edit-texteditor"/></span> <span class="tw-edit-field-add-button"><$button message="tw-add-field" param={{$:/NewFieldName}} set="$:/NewFieldName" setTo="" class="">add</$button></span></div>
|
||||
|
||||
</$fieldmangler>
|
||||
@@ -1,64 +0,0 @@
|
||||
title: $:/core/ui/MoreSideBar
|
||||
|
||||
<div class="tw-tab-set tw-more-sidebar"><div class="tw-tab-buttons">
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="allTab" selectedClass="tw-tab-selected">All</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="recentTab" selectedClass="tw-tab-selected">Recent</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="tagsTab" selectedClass="tw-tab-selected">Tags</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="missingTab" selectedClass="tw-tab-selected">Missing</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="draftsTab" selectedClass="tw-tab-selected">Drafts</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="orphanTab" selectedClass="tw-tab-selected">Orphans</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="typeTab" selectedClass="tw-tab-selected">Types</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="systemTab" selectedClass="tw-tab-selected">System</$button>
|
||||
|
||||
<$button type="set" set=<<qualify "$:/state/moreSideBarTabSet">> setTo="shadowsTab" selectedClass="tw-tab-selected">Shadows</$button>
|
||||
|
||||
</div><div class="tw-tab-content">
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="allTab">
|
||||
<$list filter="[!is[system]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="recentTab">
|
||||
{{$:/snippets/recentchanges}}
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="tagsTab">
|
||||
<$list filter="[tags[]sort[title]]" itemClass="tw-menu-list-item">
|
||||
<$transclude tiddler="$:/core/ui/TagTemplate"/> <small class="tw-menu-list-count"><$count filter="[is[current]tagging[]]"/></small>
|
||||
</$list>
|
||||
----
|
||||
{{$:/core/ui/UntaggedTemplate}} <small class="tw-menu-list-count"><$count filter="[untagged[]!is[system]] -[tags[]]"/></small>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="missingTab">
|
||||
<$list filter="[is[missing]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/MissingTemplate"/>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="draftsTab">
|
||||
<$list filter="[has[draft.of]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="orphanTab">
|
||||
<$list filter="[is[orphan]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="typeTab">
|
||||
<$list filter="[!is[system]has[type]each[type]sort[type]]">
|
||||
<div class="tw-menu-list-item">
|
||||
<$view field="type"/>
|
||||
<$list filter="[type{!!type}!is[system]sort[title]]">
|
||||
<div class="tw-menu-list-subitem">
|
||||
<$link to={{!!title}}><$view field="title"/></$link>
|
||||
</div>
|
||||
</$list>
|
||||
</div>
|
||||
</$list>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="systemTab">
|
||||
<$list filter="[is[system]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$reveal>
|
||||
<$reveal type="match" state=<<qualify "$:/state/moreSideBarTabSet">> text="shadowsTab">
|
||||
<$list filter="[is[shadow]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$reveal>
|
||||
</div></div>
|
||||
5
core/ui/MoreSideBar/All.tid
Normal file
5
core/ui/MoreSideBar/All.tid
Normal file
@@ -0,0 +1,5 @@
|
||||
title: $:/core/ui/MoreSideBar/All
|
||||
tags: $:/tags/MoreSideBar
|
||||
caption: All
|
||||
|
||||
<$list filter="[!is[system]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
5
core/ui/MoreSideBar/Drafts.tid
Normal file
5
core/ui/MoreSideBar/Drafts.tid
Normal file
@@ -0,0 +1,5 @@
|
||||
title: $:/core/ui/MoreSideBar/Drafts
|
||||
tags: $:/tags/MoreSideBar
|
||||
caption: Drafts
|
||||
|
||||
<$list filter="[has[draft.of]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
5
core/ui/MoreSideBar/Missing.tid
Normal file
5
core/ui/MoreSideBar/Missing.tid
Normal file
@@ -0,0 +1,5 @@
|
||||
title: $:/core/ui/MoreSideBar/Missing
|
||||
tags: $:/tags/MoreSideBar
|
||||
caption: Missing
|
||||
|
||||
<$list filter="[is[missing]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/MissingTemplate"/>
|
||||
5
core/ui/MoreSideBar/Orphans.tid
Normal file
5
core/ui/MoreSideBar/Orphans.tid
Normal file
@@ -0,0 +1,5 @@
|
||||
title: $:/core/ui/MoreSideBar/Orphans
|
||||
tags: $:/tags/MoreSideBar
|
||||
caption: Orphans
|
||||
|
||||
<$list filter="[is[orphan]sort[title]]" itemClass="tw-menu-list-item" template="$:/core/ui/ListItemTemplate"/>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user