mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-01-27 13:23:42 +00:00
Compare commits
84 Commits
rsoe-emerg
...
confetti-p
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
535581cf81 | ||
|
|
0710054e64 | ||
|
|
a7d469ae99 | ||
|
|
547582c1e7 | ||
|
|
e40b83f141 | ||
|
|
518c23d06d | ||
|
|
a2f4e71080 | ||
|
|
10fad328dd | ||
|
|
d7a58a01b9 | ||
|
|
b8fdb320dc | ||
|
|
fd5c073654 | ||
|
|
343839b4d4 | ||
|
|
94e27ccc48 | ||
|
|
80c52d071e | ||
|
|
cd2b375d80 | ||
|
|
9eac359a5d | ||
|
|
9b6570f420 | ||
|
|
906cb8f92b | ||
|
|
6f46775e94 | ||
|
|
aa3f931721 | ||
|
|
0213f1ab8f | ||
|
|
1351109119 | ||
|
|
3254684dd6 | ||
|
|
29575d01bf | ||
|
|
b1eece2a93 | ||
|
|
1c6fba6108 | ||
|
|
c3167d5368 | ||
|
|
184e30afb8 | ||
|
|
44d322868f | ||
|
|
455a51f671 | ||
|
|
5ea2243fd9 | ||
|
|
5a4470e6ed | ||
|
|
d460f9f066 | ||
|
|
ef5b3a8840 | ||
|
|
4ef8ce3caa | ||
|
|
6088fd7d95 | ||
|
|
c7cac0f7ea | ||
|
|
7b1701583f | ||
|
|
804e253f93 | ||
|
|
7c619da913 | ||
|
|
4e938fad00 | ||
|
|
943dcd7567 | ||
|
|
783a5be00e | ||
|
|
4792d241c4 | ||
|
|
06af391773 | ||
|
|
0656580439 | ||
|
|
a4d74be3d8 | ||
|
|
701a038559 | ||
|
|
dd9b4dc787 | ||
|
|
4f026e45a8 | ||
|
|
d2fbbc408a | ||
|
|
c9d8806682 | ||
|
|
d28cf74115 | ||
|
|
d332baabe7 | ||
|
|
d29ed6a5de | ||
|
|
0c5c673ddc | ||
|
|
1721203a69 | ||
|
|
3d0a015ae5 | ||
|
|
080ca5ed31 | ||
|
|
abcd2f110f | ||
|
|
cf9864ebe3 | ||
|
|
1aef8405bd | ||
|
|
d419161686 | ||
|
|
9d2bab0ae3 | ||
|
|
40fd941394 | ||
|
|
8fd4da607d | ||
|
|
62d0c197eb | ||
|
|
1c3dd6b39b | ||
|
|
36041cf38b | ||
|
|
87c2fb390a | ||
|
|
f9cf5764ff | ||
|
|
55a52c9d8d | ||
|
|
0c67269a20 | ||
|
|
74258d66b8 | ||
|
|
5fe542a05b | ||
|
|
0bc6decefb | ||
|
|
8169e43087 | ||
|
|
1d32ef44e5 | ||
|
|
75af83174b | ||
|
|
f4f37460b8 | ||
|
|
5b9f464f26 | ||
|
|
9676706052 | ||
|
|
c977baebca | ||
|
|
8a1ec1d055 |
39
boot/boot.js
39
boot/boot.js
@@ -177,7 +177,6 @@ document: defaults to current document
|
||||
eventListeners: array of event listeners (this option won't work until $tw.utils.addEventListeners() has been loaded)
|
||||
*/
|
||||
$tw.utils.domMaker = function(tag,options) {
|
||||
var options = options || {};
|
||||
var doc = options.document || document;
|
||||
var element = doc.createElementNS(options.namespace || "http://www.w3.org/1999/xhtml",tag);
|
||||
if(options["class"]) {
|
||||
@@ -219,34 +218,9 @@ $tw.utils.error = function(err) {
|
||||
heading = dm("h1",{text: errHeading}),
|
||||
prompt = dm("div",{text: promptMsg, "class": "tc-error-prompt"}),
|
||||
message = dm("div",{text: err, "class":"tc-error-message"}),
|
||||
closeButton = dm("div",{children: [dm("button",{text: ( $tw.language == undefined ? "close" : $tw.language.getString("Buttons/Close/Caption") )})], "class": "tc-error-prompt"}),
|
||||
downloadButton = dm("div",{children: [dm("button",{text: ( $tw.language == undefined ? "download tiddlers" : $tw.language.getString("Buttons/EmergencyDownload/Caption") )})], "class": "tc-error-prompt"}),
|
||||
form = dm("form",{children: [heading,prompt,downloadButton,message,closeButton], "class": "tc-error-form"});
|
||||
button = dm("div",{children: [dm("button",{text: ( $tw.language == undefined ? "close" : $tw.language.getString("Buttons/Close/Caption") )})], "class": "tc-error-prompt"}),
|
||||
form = dm("form",{children: [heading,prompt,message,button], "class": "tc-error-form"});
|
||||
document.body.insertBefore(form,document.body.firstChild);
|
||||
downloadButton.addEventListener("click",function(event) {
|
||||
if($tw && $tw.wiki) {
|
||||
var tiddlers = [];
|
||||
$tw.wiki.each(function(tiddler,title) {
|
||||
tiddlers.push(tiddler.fields);
|
||||
});
|
||||
var link = dm("a"),
|
||||
text = JSON.stringify(tiddlers);
|
||||
if(Blob !== undefined) {
|
||||
var blob = new Blob([text], {type: "text/html"});
|
||||
link.setAttribute("href", URL.createObjectURL(blob));
|
||||
} else {
|
||||
link.setAttribute("href","data:text/html," + encodeURIComponent(text));
|
||||
}
|
||||
link.setAttribute("download","emergency-tiddlers-" + (new Date()) + ".json");
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
document.body.removeChild(link);
|
||||
} else {
|
||||
alert("Emergency tiddler download is not available");
|
||||
}
|
||||
event.preventDefault();
|
||||
return false;
|
||||
},true);
|
||||
form.addEventListener("submit",function(event) {
|
||||
document.body.removeChild(form);
|
||||
event.preventDefault();
|
||||
@@ -1993,10 +1967,10 @@ $tw.loadTiddlersFromSpecification = function(filepath,excludeRegExp) {
|
||||
var value = tiddler[name];
|
||||
switch(fieldInfo.source) {
|
||||
case "subdirectories":
|
||||
value = path.relative(rootPath, filename).split(path.sep).slice(0, -1);
|
||||
value = path.relative(rootPath, filename).split('/').slice(0, -1);
|
||||
break;
|
||||
case "filepath":
|
||||
value = path.relative(rootPath, filename).split(path.sep).join('/');
|
||||
value = path.relative(rootPath, filename);
|
||||
break;
|
||||
case "filename":
|
||||
value = path.basename(filename);
|
||||
@@ -2464,7 +2438,6 @@ $tw.boot.initStartup = function(options) {
|
||||
$tw.utils.registerFileType("image/svg+xml","utf8",".svg",{flags:["image"]});
|
||||
$tw.utils.registerFileType("image/vnd.microsoft.icon","base64",".ico",{flags:["image"]});
|
||||
$tw.utils.registerFileType("image/x-icon","base64",".ico",{flags:["image"]});
|
||||
$tw.utils.registerFileType("application/wasm","base64",".wasm");
|
||||
$tw.utils.registerFileType("application/font-woff","base64",".woff");
|
||||
$tw.utils.registerFileType("application/x-font-ttf","base64",".woff");
|
||||
$tw.utils.registerFileType("application/font-woff2","base64",".woff2");
|
||||
@@ -2479,12 +2452,8 @@ $tw.boot.initStartup = function(options) {
|
||||
$tw.utils.registerFileType("text/x-markdown","utf8",[".md",".markdown"]);
|
||||
$tw.utils.registerFileType("application/enex+xml","utf8",".enex");
|
||||
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.wordprocessingml.document","base64",".docx");
|
||||
$tw.utils.registerFileType("application/msword","base64",".doc");
|
||||
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","base64",".xlsx");
|
||||
$tw.utils.registerFileType("application/excel","base64",".xls");
|
||||
$tw.utils.registerFileType("application/vnd.ms-excel","base64",".xls");
|
||||
$tw.utils.registerFileType("application/vnd.openxmlformats-officedocument.presentationml.presentation","base64",".pptx");
|
||||
$tw.utils.registerFileType("application/mspowerpoint","base64",".ppt");
|
||||
$tw.utils.registerFileType("text/x-bibtex","utf8",".bib",{deserializerType:"application/x-bibtex"});
|
||||
$tw.utils.registerFileType("application/x-bibtex","utf8",".bib");
|
||||
$tw.utils.registerFileType("application/epub+zip","base64",".epub");
|
||||
|
||||
@@ -28,7 +28,6 @@ Encryption/ClearPassword/Caption: clear password
|
||||
Encryption/ClearPassword/Hint: Clear the password and save this wiki without encryption
|
||||
Encryption/SetPassword/Caption: set password
|
||||
Encryption/SetPassword/Hint: Set a password for saving this wiki with encryption
|
||||
EmergencyDownload/Caption: download tiddlers as json
|
||||
ExportPage/Caption: export all
|
||||
ExportPage/Hint: Export all tiddlers
|
||||
ExportTiddler/Caption: export tiddler
|
||||
|
||||
@@ -289,7 +289,7 @@ exports.httpRequest = function(options) {
|
||||
return;
|
||||
}
|
||||
// Something went wrong
|
||||
options.callback($tw.language.getString("Error/XMLHttpRequest") + ": " + this.status,this[returnProp],this);
|
||||
options.callback($tw.language.getString("Error/XMLHttpRequest") + ": " + this.status,null,this);
|
||||
}
|
||||
};
|
||||
// Handle progress
|
||||
|
||||
@@ -155,8 +155,6 @@ LinkWidget.prototype.renderLink = function(parent,nextSibling) {
|
||||
};
|
||||
|
||||
LinkWidget.prototype.handleClickEvent = function(event) {
|
||||
// Force an error to try out the Red Screen Of Embarrassment
|
||||
var something = Everything;
|
||||
// Send the click on its way as a navigate event
|
||||
var bounds = this.domNodes[0].getBoundingClientRect();
|
||||
this.dispatchEvent({
|
||||
|
||||
@@ -4,17 +4,17 @@ type: application/json
|
||||
{
|
||||
"newTiddlerPosition": {"x": 360,"y": 100},
|
||||
"positions": {
|
||||
" ": {"x": 30,"y": 17,"w": 120,"h": 120, "r": -2},
|
||||
"Tiddlers": {"x": 60,"y": 15,"w": 120,"h": 120, "r": 10},
|
||||
"Links": {"x": 90,"y": 13,"w": 120,"h": 120, "r": -7},
|
||||
"Formatting": {"x": 120,"y": 18,"w": 120,"h": 120, "r": 5},
|
||||
"Images": {"x": 150,"y": 12,"w": 120,"h": 120, "r": -11},
|
||||
"Audio": {"x": 180,"y": 14,"w": 120,"h": 120, "r": 16},
|
||||
"Tags": {"x": 210,"y": 15,"w": 120,"h": 120, "r": 20},
|
||||
"Transclusion": {"x": 240,"y": 16,"w": 120,"h": 120, "r": -4},
|
||||
"Lists": {"x": 275,"y": 13,"w": 120,"h": 120, "r": 6},
|
||||
"Customisation": {"x": 310,"y": 19,"w": 120,"h": 120, "r": -5},
|
||||
"Plugins": {"x": 350,"y": 12,"w": 120,"h": 120, "r": 10},
|
||||
"Translations": {"x": 390,"y": 15,"w": 120,"h": 120, "r": 8}
|
||||
" ": {"x": 30,"y": 17,"w": 140,"h": 140, "r": -2},
|
||||
"Tiddlers": {"x": 60,"y": 15,"w": 140,"h": 140, "r": 10},
|
||||
"Links": {"x": 90,"y": 13,"w": 140,"h": 140, "r": -7},
|
||||
"Formatting": {"x": 120,"y": 18,"w": 140,"h": 140, "r": 5},
|
||||
"Images": {"x": 150,"y": 12,"w": 140,"h": 140, "r": -11},
|
||||
"Audio": {"x": 180,"y": 14,"w": 140,"h": 140, "r": 16},
|
||||
"Tags": {"x": 210,"y": 15,"w": 140,"h": 140, "r": 20},
|
||||
"Transclusion": {"x": 240,"y": 16,"w": 140,"h": 140, "r": -4},
|
||||
"Lists": {"x": 275,"y": 13,"w": 140,"h": 140, "r": 6},
|
||||
"Customisation": {"x": 310,"y": 19,"w": 140,"h": 140, "r": -5},
|
||||
"Plugins": {"x": 350,"y": 12,"w": 140,"h": 140, "r": 10},
|
||||
"Translations": {"x": 390,"y": 15,"w": 140,"h": 140, "r": 8}
|
||||
}
|
||||
}
|
||||
@@ -1,3 +1,3 @@
|
||||
[
|
||||
{"title": " ", "text": "[[TiddlyWiki]]"}
|
||||
{"title": " ", "text": "TiddlyWiki"}
|
||||
]
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
created: 20210101154635213
|
||||
modified: 20240131143350890
|
||||
modified: 20210110210929321
|
||||
tags: [[Community Themes]]
|
||||
title: "Notebook theme" by Nicolas Petton
|
||||
type: text/vnd.tiddlywiki
|
||||
url: https://saqimtiaz.github.io/sq-tw/notebook.html
|
||||
url: https://nicolas.petton.fr/tw/notebook.html
|
||||
|
||||
Notebook is a clean, uncluttered theme for ~TiddlyWiki.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user