mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-10-31 23:26:18 +00:00
Merge branch 'master' of https://github.com/Jermolene/TiddlyWiki5 into de-DE
This commit is contained in:
commit
470c056b8d
@ -1456,6 +1456,7 @@ $tw.boot.startup = function(options) {
|
|||||||
pluginsPath: "../plugins/",
|
pluginsPath: "../plugins/",
|
||||||
themesPath: "../themes/",
|
themesPath: "../themes/",
|
||||||
languagesPath: "../languages/",
|
languagesPath: "../languages/",
|
||||||
|
editionsPath: "../editions/",
|
||||||
wikiInfo: "./tiddlywiki.info",
|
wikiInfo: "./tiddlywiki.info",
|
||||||
wikiPluginsSubDir: "./plugins",
|
wikiPluginsSubDir: "./plugins",
|
||||||
wikiThemesSubDir: "./themes",
|
wikiThemesSubDir: "./themes",
|
||||||
|
@ -16,6 +16,7 @@ tiddlerdeserializer: Converts different content types into tiddlers.
|
|||||||
tiddlerfield: Defines the behaviour of an individual tiddler field.
|
tiddlerfield: Defines the behaviour of an individual tiddler field.
|
||||||
tiddlermethod: Adds methods to the `$tw.Tiddler` prototype.
|
tiddlermethod: Adds methods to the `$tw.Tiddler` prototype.
|
||||||
utils: Adds methods to `$tw.utils`.
|
utils: Adds methods to `$tw.utils`.
|
||||||
|
utils-node: Adds Node.js-specific methods to `$tw.utils`.
|
||||||
widget: Widgets encapsulate DOM rendering and refreshing.
|
widget: Widgets encapsulate DOM rendering and refreshing.
|
||||||
wikimethod: Adds methods to `$tw.Wiki`.
|
wikimethod: Adds methods to `$tw.Wiki`.
|
||||||
wikirule: Individual parser rules for the main WikiText parser.
|
wikirule: Individual parser rules for the main WikiText parser.
|
||||||
|
59
core/modules/commands/init.js
Normal file
59
core/modules/commands/init.js
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
/*\
|
||||||
|
title: $:/core/modules/commands/init.js
|
||||||
|
type: application/javascript
|
||||||
|
module-type: command
|
||||||
|
|
||||||
|
Command to initialise an empty wiki folder
|
||||||
|
|
||||||
|
\*/
|
||||||
|
(function(){
|
||||||
|
|
||||||
|
/*jslint node: true, browser: true */
|
||||||
|
/*global $tw: false */
|
||||||
|
"use strict";
|
||||||
|
|
||||||
|
exports.info = {
|
||||||
|
name: "init",
|
||||||
|
synchronous: true
|
||||||
|
};
|
||||||
|
|
||||||
|
var Command = function(params,commander) {
|
||||||
|
this.params = params;
|
||||||
|
this.commander = commander;
|
||||||
|
};
|
||||||
|
|
||||||
|
Command.prototype.execute = function() {
|
||||||
|
var fs = require("fs"),
|
||||||
|
path = require("path");
|
||||||
|
// Check that we don't already have a valid wiki folder
|
||||||
|
if($tw.boot.wikiTiddlersPath) {
|
||||||
|
return "Wiki folder is not empty";
|
||||||
|
}
|
||||||
|
// Loop through each of the specified editions
|
||||||
|
var editions = this.params.length > 0 ? this.params : ["empty"];
|
||||||
|
for(var editionIndex=0; editionIndex<editions.length; editionIndex++) {
|
||||||
|
var editionName = editions[editionIndex];
|
||||||
|
// Check the edition exists
|
||||||
|
var editionPath = path.resolve($tw.boot.corePath,$tw.config.editionsPath) + "/" + editionName;
|
||||||
|
if(!$tw.utils.isDirectory(editionPath)) {
|
||||||
|
return "Edition '" + editionName + "' not found";
|
||||||
|
}
|
||||||
|
// Copy the edition content
|
||||||
|
var err = $tw.utils.copyDirectory(editionPath,$tw.boot.wikiPath);
|
||||||
|
if(!err) {
|
||||||
|
this.commander.streams.output.write("Copied edition '" + editionName + "' to " + $tw.boot.wikiPath + "\n");
|
||||||
|
} else {
|
||||||
|
return err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Tweak the tiddlywiki.info to remove any included wikis
|
||||||
|
var packagePath = $tw.boot.wikiPath + "/tiddlywiki.info",
|
||||||
|
packageJson = JSON.parse(fs.readFileSync(packagePath));
|
||||||
|
delete packageJson.includeWikis;
|
||||||
|
fs.writeFileSync(packagePath,JSON.stringify(packageJson,null,$tw.config.preferences.jsonSpaces));
|
||||||
|
return null;
|
||||||
|
};
|
||||||
|
|
||||||
|
exports.Command = Command;
|
||||||
|
|
||||||
|
})();
|
@ -18,6 +18,9 @@ exports.startup = function() {
|
|||||||
var modules,n,m,f,commander;
|
var modules,n,m,f,commander;
|
||||||
// Load modules
|
// Load modules
|
||||||
$tw.modules.applyMethods("utils",$tw.utils);
|
$tw.modules.applyMethods("utils",$tw.utils);
|
||||||
|
if($tw.node) {
|
||||||
|
$tw.modules.applyMethods("utils-node",$tw.utils);
|
||||||
|
}
|
||||||
$tw.modules.applyMethods("global",$tw);
|
$tw.modules.applyMethods("global",$tw);
|
||||||
$tw.modules.applyMethods("config",$tw.config);
|
$tw.modules.applyMethods("config",$tw.config);
|
||||||
if($tw.browser) {
|
if($tw.browser) {
|
||||||
|
111
core/modules/utils/filesystem.js
Normal file
111
core/modules/utils/filesystem.js
Normal file
@ -0,0 +1,111 @@
|
|||||||
|
/*\
|
||||||
|
title: $:/core/modules/utils/filesystem.js
|
||||||
|
type: application/javascript
|
||||||
|
module-type: utils-node
|
||||||
|
|
||||||
|
File system utilities
|
||||||
|
|
||||||
|
\*/
|
||||||
|
(function(){
|
||||||
|
|
||||||
|
/*jslint node: true, browser: true */
|
||||||
|
/*global $tw: false */
|
||||||
|
"use strict";
|
||||||
|
|
||||||
|
var fs = require("fs"),
|
||||||
|
path = require("path");
|
||||||
|
|
||||||
|
/*
|
||||||
|
Recursively (and synchronously) copy a directory and all its content
|
||||||
|
*/
|
||||||
|
exports.copyDirectory = function(srcPath,dstPath) {
|
||||||
|
// Remove any trailing path separators
|
||||||
|
srcPath = $tw.utils.removeTrailingSeparator(srcPath);
|
||||||
|
dstPath = $tw.utils.removeTrailingSeparator(dstPath);
|
||||||
|
// Create the destination directory
|
||||||
|
var err = $tw.utils.createDirectory(dstPath);
|
||||||
|
if(err) {
|
||||||
|
return err;
|
||||||
|
}
|
||||||
|
// Function to copy a folder full of files
|
||||||
|
var copy = function(srcPath,dstPath) {
|
||||||
|
var srcStats = fs.lstatSync(srcPath),
|
||||||
|
dstExists = fs.existsSync(dstPath);
|
||||||
|
if(srcStats.isFile()) {
|
||||||
|
$tw.utils.copyFile(srcPath,dstPath);
|
||||||
|
} else if(srcStats.isDirectory()) {
|
||||||
|
var items = fs.readdirSync(srcPath);
|
||||||
|
for(var t=0; t<items.length; t++) {
|
||||||
|
var item = items[t],
|
||||||
|
err = copy(srcPath + path.sep + item,dstPath + path.sep + item);
|
||||||
|
if(err) {
|
||||||
|
return err;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
};
|
||||||
|
copy(srcPath,dstPath);
|
||||||
|
return null;
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
Copy a file
|
||||||
|
*/
|
||||||
|
var FILE_BUFFER_LENGTH = 64 * 1024,
|
||||||
|
fileBuffer = $tw.node && new Buffer(FILE_BUFFER_LENGTH);
|
||||||
|
|
||||||
|
exports.copyFile = function(srcPath,dstPath) {
|
||||||
|
// Create any directories in the destination
|
||||||
|
$tw.utils.createDirectory(path.dirname(dstPath));
|
||||||
|
// Copy the file
|
||||||
|
var srcFile = fs.openSync(srcPath,"r"),
|
||||||
|
dstFile = fs.openSync(dstPath,"w"),
|
||||||
|
bytesRead = 1,
|
||||||
|
pos = 0;
|
||||||
|
while (bytesRead > 0) {
|
||||||
|
bytesRead = fs.readSync(srcFile,fileBuffer,0,FILE_BUFFER_LENGTH,pos);
|
||||||
|
fs.writeSync(dstFile,fileBuffer,0,bytesRead);
|
||||||
|
pos += bytesRead;
|
||||||
|
}
|
||||||
|
fs.closeSync(srcFile);
|
||||||
|
fs.closeSync(dstFile);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Remove trailing path separator
|
||||||
|
*/
|
||||||
|
exports.removeTrailingSeparator = function(dirPath) {
|
||||||
|
var len = dirPath.length;
|
||||||
|
if(dirPath.charAt(len-1) === path.sep) {
|
||||||
|
dirPath = dirPath.substr(0,len-1);
|
||||||
|
}
|
||||||
|
return dirPath;
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
Recursively create a directory
|
||||||
|
*/
|
||||||
|
exports.createDirectory = function(dirPath) {
|
||||||
|
var parts = dirPath.split(path.sep);
|
||||||
|
for(var component=0; component<parts.length; component++) {
|
||||||
|
var subDirPath = parts.slice(0,component+1).join(path.sep);
|
||||||
|
if(!$tw.utils.isDirectory(subDirPath)) {
|
||||||
|
try {
|
||||||
|
fs.mkdirSync(subDirPath);
|
||||||
|
} catch(e) {
|
||||||
|
return "Error creating directory '" + subDirPath + "'";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
Check if a path identifies a directory
|
||||||
|
*/
|
||||||
|
exports.isDirectory = function(dirPath) {
|
||||||
|
return fs.existsSync(dirPath) && fs.statSync(dirPath).isDirectory();
|
||||||
|
};
|
||||||
|
|
||||||
|
})();
|
@ -436,4 +436,15 @@ exports.base64Decode = function(string64) {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
Convert a hashmap into a tiddler dictionary format sequence of name:value pairs
|
||||||
|
*/
|
||||||
|
exports.makeTiddlerDictionary = function(data) {
|
||||||
|
var output = [];
|
||||||
|
for(var name in data) {
|
||||||
|
output.push(name + ": " + data[name]);
|
||||||
|
}
|
||||||
|
return output.join("\n");
|
||||||
|
};
|
||||||
|
|
||||||
})();
|
})();
|
||||||
|
@ -203,6 +203,10 @@ NavigatorWidget.prototype.handleDeleteTiddlerEvent = function(event) {
|
|||||||
if(tiddler.hasField("draft.title")) {
|
if(tiddler.hasField("draft.title")) {
|
||||||
// Delete the original tiddler
|
// Delete the original tiddler
|
||||||
var originalTitle = tiddler.fields["draft.of"];
|
var originalTitle = tiddler.fields["draft.of"];
|
||||||
|
// Ask for confirmation if the tiddler has changed
|
||||||
|
if(!confirm("Do you wish to delete the tiddler '" + originalTitle + "'")) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
this.wiki.deleteTiddler(originalTitle);
|
this.wiki.deleteTiddler(originalTitle);
|
||||||
this.removeTitleFromStory(storyList,originalTitle);
|
this.removeTitleFromStory(storyList,originalTitle);
|
||||||
}
|
}
|
||||||
|
@ -620,8 +620,17 @@ data: object that can be serialised to JSON
|
|||||||
fields: optional hashmap of additional tiddler fields to be set
|
fields: optional hashmap of additional tiddler fields to be set
|
||||||
*/
|
*/
|
||||||
exports.setTiddlerData = function(title,data,fields) {
|
exports.setTiddlerData = function(title,data,fields) {
|
||||||
var tiddler = this.getTiddler(title);
|
var existingTiddler = this.getTiddler(title),
|
||||||
this.addTiddler(new $tw.Tiddler(tiddler,fields,{title: title, type: "application/json", text: JSON.stringify(data,null,$tw.config.preferences.jsonSpaces)},this.getModificationFields()));
|
newFields = {
|
||||||
|
title: title
|
||||||
|
};
|
||||||
|
if(existingTiddler && existingTiddler.fields.type === "application/x-tiddler-dictionary") {
|
||||||
|
newFields.text = $tw.utils.makeTiddlerDictionary(data);
|
||||||
|
} else {
|
||||||
|
newFields.type = "application/json";
|
||||||
|
newFields.text = JSON.stringify(data,null,$tw.config.preferences.jsonSpaces);
|
||||||
|
}
|
||||||
|
this.addTiddler(new $tw.Tiddler(existingTiddler,fields,newFields,this.getModificationFields()));
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -22,6 +22,12 @@ dropdown-border: <<colour muted-foreground>>
|
|||||||
dropdown-tab-background-selected: #fff
|
dropdown-tab-background-selected: #fff
|
||||||
dropdown-tab-background: #ececec
|
dropdown-tab-background: #ececec
|
||||||
dropzone-background: rgba(0,200,0,0.7)
|
dropzone-background: rgba(0,200,0,0.7)
|
||||||
|
external-link-background-hover:
|
||||||
|
external-link-background-visited:
|
||||||
|
external-link-background:
|
||||||
|
external-link-foreground-hover:
|
||||||
|
external-link-foreground-visited: #0000aa
|
||||||
|
external-link-foreground: #0000ee
|
||||||
foreground: #333333
|
foreground: #333333
|
||||||
message-background: #ecf2ff
|
message-background: #ecf2ff
|
||||||
message-border: #cfd6e6
|
message-border: #cfd6e6
|
||||||
@ -41,11 +47,17 @@ pre-border: #cccccc
|
|||||||
primary: #7897f3
|
primary: #7897f3
|
||||||
sidebar-controls-foreground-hover: #000000
|
sidebar-controls-foreground-hover: #000000
|
||||||
sidebar-controls-foreground: #ccc
|
sidebar-controls-foreground: #ccc
|
||||||
sidebar-foreground: #acacac
|
|
||||||
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
||||||
|
sidebar-foreground: #acacac
|
||||||
sidebar-muted-foreground-hover: #444444
|
sidebar-muted-foreground-hover: #444444
|
||||||
sidebar-muted-foreground: #c0c0c0
|
sidebar-muted-foreground: #c0c0c0
|
||||||
sidebar-tab-background-selected: #ffffff
|
sidebar-tab-background-selected: #ffffff
|
||||||
|
sidebar-tab-background: <<colour tab-background>>
|
||||||
|
sidebar-tab-border-selected: <<colour tab-border-selected>>
|
||||||
|
sidebar-tab-border: <<colour tab-border>>
|
||||||
|
sidebar-tab-divider: <<colour tab-divider>>
|
||||||
|
sidebar-tab-foreground-selected:
|
||||||
|
sidebar-tab-foreground: <<colour tab-foreground>>
|
||||||
sidebar-tiddler-link-foreground-hover: #444444
|
sidebar-tiddler-link-foreground-hover: #444444
|
||||||
sidebar-tiddler-link-foreground: #7897f3
|
sidebar-tiddler-link-foreground: #7897f3
|
||||||
static-alert-foreground: #aaaaaa
|
static-alert-foreground: #aaaaaa
|
||||||
@ -54,6 +66,7 @@ tab-background: #eeeeee
|
|||||||
tab-border-selected: #cccccc
|
tab-border-selected: #cccccc
|
||||||
tab-border: #cccccc
|
tab-border: #cccccc
|
||||||
tab-divider: #d8d8d8
|
tab-divider: #d8d8d8
|
||||||
|
tab-foreground-selected: <<colour tab-foreground>>
|
||||||
tab-foreground: #666666
|
tab-foreground: #666666
|
||||||
table-border: #dddddd
|
table-border: #dddddd
|
||||||
table-footer-background: #a8a8a8
|
table-footer-background: #a8a8a8
|
||||||
@ -77,5 +90,14 @@ tiddler-link-background: <<colour background>>
|
|||||||
tiddler-link-foreground: <<colour primary>>
|
tiddler-link-foreground: <<colour primary>>
|
||||||
tiddler-subtitle-foreground: #c0c0c0
|
tiddler-subtitle-foreground: #c0c0c0
|
||||||
tiddler-title-foreground: #ff9900
|
tiddler-title-foreground: #ff9900
|
||||||
|
toolbar-new-button:
|
||||||
|
toolbar-options-button:
|
||||||
|
toolbar-save-button:
|
||||||
|
toolbar-info-button:
|
||||||
|
toolbar-edit-button:
|
||||||
|
toolbar-close-button:
|
||||||
|
toolbar-delete-button:
|
||||||
|
toolbar-cancel-button:
|
||||||
|
toolbar-done-button:
|
||||||
untagged-background: #999999
|
untagged-background: #999999
|
||||||
very-muted-foreground: #888888
|
very-muted-foreground: #888888
|
||||||
|
@ -22,6 +22,12 @@ dropdown-border: <<colour muted-foreground>>
|
|||||||
dropdown-tab-background-selected: #fff
|
dropdown-tab-background-selected: #fff
|
||||||
dropdown-tab-background: #ececec
|
dropdown-tab-background: #ececec
|
||||||
dropzone-background: rgba(0,200,0,0.7)
|
dropzone-background: rgba(0,200,0,0.7)
|
||||||
|
external-link-background-hover:
|
||||||
|
external-link-background-visited:
|
||||||
|
external-link-background:
|
||||||
|
external-link-foreground-hover:
|
||||||
|
external-link-foreground-visited: #0000aa
|
||||||
|
external-link-foreground: #0000ee
|
||||||
foreground: #333353
|
foreground: #333353
|
||||||
message-background: #ecf2ff
|
message-background: #ecf2ff
|
||||||
message-border: #cfd6e6
|
message-border: #cfd6e6
|
||||||
@ -41,11 +47,17 @@ pre-border: #cccccc
|
|||||||
primary: #5778d8
|
primary: #5778d8
|
||||||
sidebar-controls-foreground-hover: #000000
|
sidebar-controls-foreground-hover: #000000
|
||||||
sidebar-controls-foreground: #ffffff
|
sidebar-controls-foreground: #ffffff
|
||||||
sidebar-foreground: #acacac
|
|
||||||
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
||||||
|
sidebar-foreground: #acacac
|
||||||
sidebar-muted-foreground-hover: #444444
|
sidebar-muted-foreground-hover: #444444
|
||||||
sidebar-muted-foreground: #c0c0c0
|
sidebar-muted-foreground: #c0c0c0
|
||||||
sidebar-tab-background-selected: <<colour page-background>>
|
sidebar-tab-background-selected: <<colour page-background>>
|
||||||
|
sidebar-tab-background: <<colour tab-background>>
|
||||||
|
sidebar-tab-border-selected: <<colour tab-border-selected>>
|
||||||
|
sidebar-tab-border: <<colour tab-border>>
|
||||||
|
sidebar-tab-divider: <<colour tab-divider>>
|
||||||
|
sidebar-tab-foreground-selected:
|
||||||
|
sidebar-tab-foreground: <<colour tab-foreground>>
|
||||||
sidebar-tiddler-link-foreground-hover: #444444
|
sidebar-tiddler-link-foreground-hover: #444444
|
||||||
sidebar-tiddler-link-foreground: #5959c0
|
sidebar-tiddler-link-foreground: #5959c0
|
||||||
static-alert-foreground: #aaaaaa
|
static-alert-foreground: #aaaaaa
|
||||||
@ -54,6 +66,7 @@ tab-background: #ccccdd
|
|||||||
tab-border-selected: #ccccdd
|
tab-border-selected: #ccccdd
|
||||||
tab-border: #cccccc
|
tab-border: #cccccc
|
||||||
tab-divider: #d8d8d8
|
tab-divider: #d8d8d8
|
||||||
|
tab-foreground-selected: <<colour tab-foreground>>
|
||||||
tab-foreground: #666666
|
tab-foreground: #666666
|
||||||
table-border: #dddddd
|
table-border: #dddddd
|
||||||
table-footer-background: #a8a8a8
|
table-footer-background: #a8a8a8
|
||||||
@ -62,7 +75,7 @@ tag-background: #eeeeff
|
|||||||
tag-foreground: #000
|
tag-foreground: #000
|
||||||
tiddler-background: <<colour background>>
|
tiddler-background: <<colour background>>
|
||||||
tiddler-border: <<colour background>>
|
tiddler-border: <<colour background>>
|
||||||
tiddler-controls-foreground-hover: #888888
|
tiddler-controls-foreground-hover: #666666
|
||||||
tiddler-controls-foreground-selected: #444444
|
tiddler-controls-foreground-selected: #444444
|
||||||
tiddler-controls-foreground: #cccccc
|
tiddler-controls-foreground: #cccccc
|
||||||
tiddler-editor-background: #f8f8f8
|
tiddler-editor-background: #f8f8f8
|
||||||
@ -77,5 +90,14 @@ tiddler-link-background: <<colour background>>
|
|||||||
tiddler-link-foreground: <<colour primary>>
|
tiddler-link-foreground: <<colour primary>>
|
||||||
tiddler-subtitle-foreground: #c0c0c0
|
tiddler-subtitle-foreground: #c0c0c0
|
||||||
tiddler-title-foreground: #5959c0
|
tiddler-title-foreground: #5959c0
|
||||||
|
toolbar-new-button: #5eb95e
|
||||||
|
toolbar-options-button: rgb(128, 88, 165)
|
||||||
|
toolbar-save-button: #0e90d2
|
||||||
|
toolbar-info-button: #0e90d2
|
||||||
|
toolbar-edit-button: rgb(243, 123, 29)
|
||||||
|
toolbar-close-button: #dd514c
|
||||||
|
toolbar-delete-button: #dd514c
|
||||||
|
toolbar-cancel-button: rgb(243, 123, 29)
|
||||||
|
toolbar-done-button: #5eb95e
|
||||||
untagged-background: #999999
|
untagged-background: #999999
|
||||||
very-muted-foreground: #888888
|
very-muted-foreground: #888888
|
||||||
|
@ -22,6 +22,12 @@ dropdown-border: <<colour muted-foreground>>
|
|||||||
dropdown-tab-background-selected: #fff
|
dropdown-tab-background-selected: #fff
|
||||||
dropdown-tab-background: #ececec
|
dropdown-tab-background: #ececec
|
||||||
dropzone-background: rgba(0,200,0,0.7)
|
dropzone-background: rgba(0,200,0,0.7)
|
||||||
|
external-link-background-hover:
|
||||||
|
external-link-background-visited:
|
||||||
|
external-link-background:
|
||||||
|
external-link-foreground-hover:
|
||||||
|
external-link-foreground-visited: #0000aa
|
||||||
|
external-link-foreground: #0000ee
|
||||||
foreground: #333333
|
foreground: #333333
|
||||||
message-background: #ecf2ff
|
message-background: #ecf2ff
|
||||||
message-border: #cfd6e6
|
message-border: #cfd6e6
|
||||||
@ -41,11 +47,17 @@ pre-border: #cccccc
|
|||||||
primary: #5778d8
|
primary: #5778d8
|
||||||
sidebar-controls-foreground-hover: #000000
|
sidebar-controls-foreground-hover: #000000
|
||||||
sidebar-controls-foreground: #ffffff
|
sidebar-controls-foreground: #ffffff
|
||||||
sidebar-foreground: #ffffff
|
|
||||||
sidebar-foreground-shadow: rgba(255,0,0, 0.5)
|
sidebar-foreground-shadow: rgba(255,0,0, 0.5)
|
||||||
|
sidebar-foreground: #ffffff
|
||||||
sidebar-muted-foreground-hover: #444444
|
sidebar-muted-foreground-hover: #444444
|
||||||
sidebar-muted-foreground: #c0c0c0
|
sidebar-muted-foreground: #c0c0c0
|
||||||
sidebar-tab-background-selected: #ececec
|
sidebar-tab-background-selected: #ececec
|
||||||
|
sidebar-tab-background: <<colour tab-background>>
|
||||||
|
sidebar-tab-border-selected: <<colour tab-border-selected>>
|
||||||
|
sidebar-tab-border: <<colour tab-border>>
|
||||||
|
sidebar-tab-divider: <<colour tab-divider>>
|
||||||
|
sidebar-tab-foreground-selected:
|
||||||
|
sidebar-tab-foreground: <<colour tab-foreground>>
|
||||||
sidebar-tiddler-link-foreground-hover: #444444
|
sidebar-tiddler-link-foreground-hover: #444444
|
||||||
sidebar-tiddler-link-foreground: #999999
|
sidebar-tiddler-link-foreground: #999999
|
||||||
static-alert-foreground: #aaaaaa
|
static-alert-foreground: #aaaaaa
|
||||||
@ -54,6 +66,7 @@ tab-background: #d8d8d8
|
|||||||
tab-border-selected: #d8d8d8
|
tab-border-selected: #d8d8d8
|
||||||
tab-border: #cccccc
|
tab-border: #cccccc
|
||||||
tab-divider: #d8d8d8
|
tab-divider: #d8d8d8
|
||||||
|
tab-foreground-selected: <<colour tab-foreground>>
|
||||||
tab-foreground: #666666
|
tab-foreground: #666666
|
||||||
table-border: #dddddd
|
table-border: #dddddd
|
||||||
table-footer-background: #a8a8a8
|
table-footer-background: #a8a8a8
|
||||||
@ -77,5 +90,14 @@ tiddler-link-background: <<colour background>>
|
|||||||
tiddler-link-foreground: <<colour primary>>
|
tiddler-link-foreground: <<colour primary>>
|
||||||
tiddler-subtitle-foreground: #c0c0c0
|
tiddler-subtitle-foreground: #c0c0c0
|
||||||
tiddler-title-foreground: #182955
|
tiddler-title-foreground: #182955
|
||||||
|
toolbar-new-button:
|
||||||
|
toolbar-options-button:
|
||||||
|
toolbar-save-button:
|
||||||
|
toolbar-info-button:
|
||||||
|
toolbar-edit-button:
|
||||||
|
toolbar-close-button:
|
||||||
|
toolbar-delete-button:
|
||||||
|
toolbar-cancel-button:
|
||||||
|
toolbar-done-button:
|
||||||
untagged-background: #999999
|
untagged-background: #999999
|
||||||
very-muted-foreground: #888888
|
very-muted-foreground: #888888
|
||||||
|
@ -22,6 +22,12 @@ dropdown-border: <<colour muted-foreground>>
|
|||||||
dropdown-tab-background-selected: #fff
|
dropdown-tab-background-selected: #fff
|
||||||
dropdown-tab-background: #ececec
|
dropdown-tab-background: #ececec
|
||||||
dropzone-background: rgba(0,200,0,0.7)
|
dropzone-background: rgba(0,200,0,0.7)
|
||||||
|
external-link-background-hover:
|
||||||
|
external-link-background-visited:
|
||||||
|
external-link-background:
|
||||||
|
external-link-foreground-hover:
|
||||||
|
external-link-foreground-visited: #0000aa
|
||||||
|
external-link-foreground: #0000ee
|
||||||
foreground: #333333
|
foreground: #333333
|
||||||
message-background: #ecf2ff
|
message-background: #ecf2ff
|
||||||
message-border: #cfd6e6
|
message-border: #cfd6e6
|
||||||
@ -41,11 +47,17 @@ pre-border: #cccccc
|
|||||||
primary: #cc0000
|
primary: #cc0000
|
||||||
sidebar-controls-foreground-hover: #000000
|
sidebar-controls-foreground-hover: #000000
|
||||||
sidebar-controls-foreground: #ffffff
|
sidebar-controls-foreground: #ffffff
|
||||||
sidebar-foreground: #acacac
|
|
||||||
sidebar-foreground-shadow: rgba(255,255,255, 0.0)
|
sidebar-foreground-shadow: rgba(255,255,255, 0.0)
|
||||||
|
sidebar-foreground: #acacac
|
||||||
sidebar-muted-foreground-hover: #444444
|
sidebar-muted-foreground-hover: #444444
|
||||||
sidebar-muted-foreground: #c0c0c0
|
sidebar-muted-foreground: #c0c0c0
|
||||||
sidebar-tab-background-selected: #000
|
sidebar-tab-background-selected: #000
|
||||||
|
sidebar-tab-background: <<colour tab-background>>
|
||||||
|
sidebar-tab-border-selected: <<colour tab-border-selected>>
|
||||||
|
sidebar-tab-border: <<colour tab-border>>
|
||||||
|
sidebar-tab-divider: <<colour tab-divider>>
|
||||||
|
sidebar-tab-foreground-selected:
|
||||||
|
sidebar-tab-foreground: <<colour tab-foreground>>
|
||||||
sidebar-tiddler-link-foreground-hover: #ffbb99
|
sidebar-tiddler-link-foreground-hover: #ffbb99
|
||||||
sidebar-tiddler-link-foreground: #cc0000
|
sidebar-tiddler-link-foreground: #cc0000
|
||||||
static-alert-foreground: #aaaaaa
|
static-alert-foreground: #aaaaaa
|
||||||
@ -54,6 +66,7 @@ tab-background: #d8d8d8
|
|||||||
tab-border-selected: #d8d8d8
|
tab-border-selected: #d8d8d8
|
||||||
tab-border: #cccccc
|
tab-border: #cccccc
|
||||||
tab-divider: #d8d8d8
|
tab-divider: #d8d8d8
|
||||||
|
tab-foreground-selected: <<colour tab-foreground>>
|
||||||
tab-foreground: #666666
|
tab-foreground: #666666
|
||||||
table-border: #dddddd
|
table-border: #dddddd
|
||||||
table-footer-background: #a8a8a8
|
table-footer-background: #a8a8a8
|
||||||
@ -77,5 +90,14 @@ tiddler-link-background: <<colour background>>
|
|||||||
tiddler-link-foreground: <<colour primary>>
|
tiddler-link-foreground: <<colour primary>>
|
||||||
tiddler-subtitle-foreground: #c0c0c0
|
tiddler-subtitle-foreground: #c0c0c0
|
||||||
tiddler-title-foreground: #cc0000
|
tiddler-title-foreground: #cc0000
|
||||||
|
toolbar-new-button:
|
||||||
|
toolbar-options-button:
|
||||||
|
toolbar-save-button:
|
||||||
|
toolbar-info-button:
|
||||||
|
toolbar-edit-button:
|
||||||
|
toolbar-close-button:
|
||||||
|
toolbar-delete-button:
|
||||||
|
toolbar-cancel-button:
|
||||||
|
toolbar-done-button:
|
||||||
untagged-background: #999999
|
untagged-background: #999999
|
||||||
very-muted-foreground: #888888
|
very-muted-foreground: #888888
|
||||||
|
@ -22,6 +22,12 @@ dropdown-border: <<colour muted-foreground>>
|
|||||||
dropdown-tab-background-selected: #fff
|
dropdown-tab-background-selected: #fff
|
||||||
dropdown-tab-background: #ececec
|
dropdown-tab-background: #ececec
|
||||||
dropzone-background: rgba(0,200,0,0.7)
|
dropzone-background: rgba(0,200,0,0.7)
|
||||||
|
external-link-background-hover:
|
||||||
|
external-link-background-visited:
|
||||||
|
external-link-background:
|
||||||
|
external-link-foreground-hover:
|
||||||
|
external-link-foreground-visited: #0000aa
|
||||||
|
external-link-foreground: #0000ee
|
||||||
foreground: #333333
|
foreground: #333333
|
||||||
message-background: #ecf2ff
|
message-background: #ecf2ff
|
||||||
message-border: #cfd6e6
|
message-border: #cfd6e6
|
||||||
@ -41,11 +47,17 @@ pre-border: #cccccc
|
|||||||
primary: #5778d8
|
primary: #5778d8
|
||||||
sidebar-controls-foreground-hover: #000000
|
sidebar-controls-foreground-hover: #000000
|
||||||
sidebar-controls-foreground: #ffffff
|
sidebar-controls-foreground: #ffffff
|
||||||
sidebar-foreground: #acacac
|
|
||||||
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
sidebar-foreground-shadow: rgba(255,255,255, 0.8)
|
||||||
|
sidebar-foreground: #acacac
|
||||||
sidebar-muted-foreground-hover: #444444
|
sidebar-muted-foreground-hover: #444444
|
||||||
sidebar-muted-foreground: #c0c0c0
|
sidebar-muted-foreground: #c0c0c0
|
||||||
sidebar-tab-background-selected: #ececec
|
sidebar-tab-background-selected: #ececec
|
||||||
|
sidebar-tab-background: <<colour tab-background>>
|
||||||
|
sidebar-tab-border-selected: <<colour tab-border-selected>>
|
||||||
|
sidebar-tab-border: <<colour tab-border>>
|
||||||
|
sidebar-tab-divider: #e4e4e4
|
||||||
|
sidebar-tab-foreground-selected:
|
||||||
|
sidebar-tab-foreground: <<colour tab-foreground>>
|
||||||
sidebar-tiddler-link-foreground-hover: #444444
|
sidebar-tiddler-link-foreground-hover: #444444
|
||||||
sidebar-tiddler-link-foreground: #999999
|
sidebar-tiddler-link-foreground: #999999
|
||||||
static-alert-foreground: #aaaaaa
|
static-alert-foreground: #aaaaaa
|
||||||
@ -54,6 +66,7 @@ tab-background: #d8d8d8
|
|||||||
tab-border-selected: #d8d8d8
|
tab-border-selected: #d8d8d8
|
||||||
tab-border: #cccccc
|
tab-border: #cccccc
|
||||||
tab-divider: #d8d8d8
|
tab-divider: #d8d8d8
|
||||||
|
tab-foreground-selected: <<colour tab-foreground>>
|
||||||
tab-foreground: #666666
|
tab-foreground: #666666
|
||||||
table-border: #dddddd
|
table-border: #dddddd
|
||||||
table-footer-background: #a8a8a8
|
table-footer-background: #a8a8a8
|
||||||
@ -77,5 +90,14 @@ tiddler-link-background: <<colour background>>
|
|||||||
tiddler-link-foreground: <<colour primary>>
|
tiddler-link-foreground: <<colour primary>>
|
||||||
tiddler-subtitle-foreground: #c0c0c0
|
tiddler-subtitle-foreground: #c0c0c0
|
||||||
tiddler-title-foreground: #182955
|
tiddler-title-foreground: #182955
|
||||||
|
toolbar-new-button:
|
||||||
|
toolbar-options-button:
|
||||||
|
toolbar-save-button:
|
||||||
|
toolbar-info-button:
|
||||||
|
toolbar-edit-button:
|
||||||
|
toolbar-close-button:
|
||||||
|
toolbar-delete-button:
|
||||||
|
toolbar-cancel-button:
|
||||||
|
toolbar-done-button:
|
||||||
untagged-background: #999999
|
untagged-background: #999999
|
||||||
very-muted-foreground: #888888
|
very-muted-foreground: #888888
|
||||||
|
12
editions/server/tiddlywiki.info
Normal file
12
editions/server/tiddlywiki.info
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"plugins": [
|
||||||
|
"tiddlywiki/tiddlyweb",
|
||||||
|
"tiddlywiki/filesystem",
|
||||||
|
"tiddlywiki/codemirror",
|
||||||
|
"tiddlywiki/highlight"
|
||||||
|
],
|
||||||
|
"themes": [
|
||||||
|
"tiddlywiki/vanilla",
|
||||||
|
"tiddlywiki/snowwhite"
|
||||||
|
]
|
||||||
|
}
|
@ -1,5 +1,5 @@
|
|||||||
<h1 class=''>Building <span>TiddlyWikiClassic</span></h1><p><span>TiddlyWiki5</span> can be used to build older 2.x.x versions of <span>TiddlyWikiClassic</span> from their constituent components. Doing so involves these features:</p><ul><li>The <code>tiddlywiki/classictools</code> plugin, containing a deserializer module which allows tiddlers to be loaded from <span>TiddlyWiki</span> 2.x.x <code>.recipe</code> files</li><li>The <code>stripcomments</code> format for the <span>ViewWidget</span>, which strips single line <span>JavaScript</span> comments starting <code>//#</code></li><li>The <code>stripTitlePrefix='yes'</code> attribute of the <span>FieldsWidget</span>, which removes prefixes wrapped in curly braces from the <code>title</code> attribute<ul><li>For example, <code>{tiddler}HelloThere</code> would be transformed to <code>HelloThere</code></li></ul></li></ul><h1 class=''>Usage</h1><p><span>TiddlyWikiClassic</span> is built from the command line by running <span>TiddlyWiki on Node.js</span>. A typical usage would be:</p><pre>node ../../tiddlywiki.js \
|
<h1 class=''>Building <span>TiddlyWikiClassic</span></h1><p><span>TiddlyWiki5</span> can be used to build older 2.x.x versions of <span>TiddlyWikiClassic</span> from their constituent components. Doing so involves these features:</p><ul><li>The <code>tiddlywiki/classictools</code> plugin, containing a deserializer module which allows tiddlers to be loaded from <span>TiddlyWiki</span> 2.x.x <code>.recipe</code> files</li><li>The <code>stripcomments</code> format for the <span>ViewWidget</span>, which strips single line <span>JavaScript</span> comments starting <code>//#</code></li><li>The <code>stripTitlePrefix='yes'</code> attribute of the <span>FieldsWidget</span>, which removes prefixes wrapped in curly braces from the <code>title</code> attribute<ul><li>For example, <code>{tiddler}HelloThere</code> would be transformed to <code>HelloThere</code></li></ul></li></ul><h1 class=''>Usage</h1><p><span>TiddlyWikiClassic</span> is built from the command line by running <span>TiddlyWiki on Node.js</span>. A typical usage would be:</p><pre><code>node ../../tiddlywiki.js \
|
||||||
--verbose \
|
--verbose \
|
||||||
--load <path_to_recipe_file> \
|
--load <path_to_recipe_file> \
|
||||||
--rendertiddler $:/core/templates/tiddlywiki2.template.html <path_to_write_index_file> text/plain \
|
--rendertiddler $:/core/templates/tiddlywiki2.template.html <path_to_write_index_file> text/plain \
|
||||||
|| exit 1</pre>
|
|| exit 1</code></pre>
|
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 6.4 KiB |
@ -1,5 +1,5 @@
|
|||||||
created: 20140127143652456
|
created: 20140127143652456
|
||||||
modified: 20140206191028534
|
modified: 20140223191618338
|
||||||
tags: releasenote
|
tags: releasenote
|
||||||
title: Release 5.0.8-beta
|
title: Release 5.0.8-beta
|
||||||
type: text/vnd.tiddlywiki
|
type: text/vnd.tiddlywiki
|
||||||
@ -10,8 +10,9 @@ type: text/vnd.tiddlywiki
|
|||||||
|
|
||||||
See [[Notes for upgrading to 5.0.8-beta]] for more details of these changes:
|
See [[Notes for upgrading to 5.0.8-beta]] for more details of these changes:
|
||||||
|
|
||||||
* Changed wikitext syntax rules for parsing content of HTML elements
|
* Changed rules for parsing content of HTML elements
|
||||||
* Switched SiteTitle and SiteSubtitle to [[$:/SiteTitle]] and [[$:/SiteSubtitle]]
|
* Switched SiteTitle and SiteSubtitle to [[$:/SiteTitle]] and [[$:/SiteSubtitle]]
|
||||||
|
* Changes to commands used with [[TiddlyWiki on Node.js]]
|
||||||
|
|
||||||
!! Documentation Improvements
|
!! Documentation Improvements
|
||||||
|
|
||||||
@ -20,6 +21,7 @@ See [[Notes for upgrading to 5.0.8-beta]] for more details of these changes:
|
|||||||
!! Usability Improvements
|
!! Usability Improvements
|
||||||
|
|
||||||
* Rejigged [[$:/ControlPanel]] to use nested tabs
|
* Rejigged [[$:/ControlPanel]] to use nested tabs
|
||||||
|
* Added confirmation dialogue when deleting tiddlers
|
||||||
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/e3a05625b2368b2167a2a1b30aa82369e96a7538]] experimental KeyboardWidget, including support for ''ctrl-enter'' (or ''cmd-enter'') to finish editing a tiddler
|
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/e3a05625b2368b2167a2a1b30aa82369e96a7538]] experimental KeyboardWidget, including support for ''ctrl-enter'' (or ''cmd-enter'') to finish editing a tiddler
|
||||||
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/a01bbd4b9c7ca284141078340c8f568b1e0561a2]] [[automatic saving|AutoSave]] on editing a tiddler and a warning when attempting to close the window with unsaved changes
|
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/a01bbd4b9c7ca284141078340c8f568b1e0561a2]] [[automatic saving|AutoSave]] on editing a tiddler and a warning when attempting to close the window with unsaved changes
|
||||||
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/e6fa9b8a859867c147fb289859169b204dea003e]] number of tags to control panel ''Basics'' tab
|
* [[Added|https://github.com/Jermolene/TiddlyWiki5/commit/e6fa9b8a859867c147fb289859169b204dea003e]] number of tags to control panel ''Basics'' tab
|
||||||
@ -39,6 +41,7 @@ See [[Notes for upgrading to 5.0.8-beta]] for more details of these changes:
|
|||||||
|
|
||||||
!! Hackability Improvements
|
!! Hackability Improvements
|
||||||
|
|
||||||
|
* Extended ButtonWidget to allow navigating to a tiddler
|
||||||
* Added experimental support for building plugins in the browser: [[How to create plugins in the browser]]
|
* Added experimental support for building plugins in the browser: [[How to create plugins in the browser]]
|
||||||
* Extend the TranscludeWidget to display its content as a fallback if the tiddler or field is missing
|
* Extend the TranscludeWidget to display its content as a fallback if the tiddler or field is missing
|
||||||
* Add logging and AlertMechanism
|
* Add logging and AlertMechanism
|
||||||
|
26
editions/tw5.com/tiddlers/commands/InitCommand.tid
Normal file
26
editions/tw5.com/tiddlers/commands/InitCommand.tid
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
created: 20140223195548209
|
||||||
|
modified: 20140223195738745
|
||||||
|
tags: command
|
||||||
|
title: InitCommand
|
||||||
|
type: text/vnd.tiddlywiki
|
||||||
|
|
||||||
|
Initialise an empty [[WikiFolder|WikiFolders]] with a copy of the specified edition.
|
||||||
|
|
||||||
|
```
|
||||||
|
--init <edition> [<edition> ...]
|
||||||
|
```
|
||||||
|
|
||||||
|
For example:
|
||||||
|
|
||||||
|
```
|
||||||
|
tiddlywiki ./MyWikiFolder --init empty
|
||||||
|
```
|
||||||
|
|
||||||
|
Note:
|
||||||
|
|
||||||
|
* The edition directory will be created if necessary
|
||||||
|
* The "edition" defaults to ''empty''
|
||||||
|
* The init command will fail if the wiki folder does not exist, or is not empty
|
||||||
|
* The init command removes any `includeWikis` definitions in the edition's `tiddlywiki.info` file
|
||||||
|
* When multiple editions are specified, editions initialised later will overwrite any files shared with earlier editions (so, the final `tiddlywiki.info` file will be copied from the last edition)
|
||||||
|
|
@ -8,6 +8,8 @@ The ''Oxford ~TiddlyWiki Interest Group'' meets monthly for discussions and demo
|
|||||||
|
|
||||||
See https://oxtwig.eventbrite.co.uk/ for details of our next meeting.
|
See https://oxtwig.eventbrite.co.uk/ for details of our next meeting.
|
||||||
|
|
||||||
|
We have an email discussion list, too: https://groups.google.com/forum/#!members/oxtwig
|
||||||
|
|
||||||
! OXTWIG #2
|
! OXTWIG #2
|
||||||
|
|
||||||
The second OXTWIG meeting was held on Thursday 16th January 2014:
|
The second OXTWIG meeting was held on Thursday 16th January 2014:
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
created: 20131219100608529
|
created: 20131219100608529
|
||||||
modified: 20140102214547249
|
modified: 20140224134148737
|
||||||
tags: howto
|
tags: howto
|
||||||
title: Installing TiddlyWiki on Node.js
|
title: Installing TiddlyWiki on Node.js
|
||||||
type: text/vnd.tiddlywiki
|
type: text/vnd.tiddlywiki
|
||||||
@ -12,11 +12,10 @@ type: text/vnd.tiddlywiki
|
|||||||
#> `sudo npm install -g tiddlywiki` (Mac/Linux)
|
#> `sudo npm install -g tiddlywiki` (Mac/Linux)
|
||||||
# Check TiddlyWiki is installed by typing:
|
# Check TiddlyWiki is installed by typing:
|
||||||
#> `tiddlywiki --version`
|
#> `tiddlywiki --version`
|
||||||
# In response, you should see TiddlyWiki report its current version (eg `5.0.4-beta`; you may also see other debugging information reported)
|
# In response, you should see TiddlyWiki report its current version (eg `5.0.8-beta`; you may also see other debugging information reported)
|
||||||
# Try it out:
|
# Try it out:
|
||||||
## `mkdir mywiki` to create a folder for a new wiki
|
## `tiddlywiki mynewwiki --init server` to create a folder for a new wiki that includes server-related components
|
||||||
## `cd mywiki` to move into the new folder
|
## `tiddlywiki mynewwiki --server` to start TiddlyWiki
|
||||||
## `tiddlywiki --server` to start TiddlyWiki
|
|
||||||
## Visit http://127.0.0.1:8080/ in your browser
|
## Visit http://127.0.0.1:8080/ in your browser
|
||||||
## Try editing and creating tiddlers
|
## Try editing and creating tiddlers
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
created: 20131129094353704
|
created: 20131129094353704
|
||||||
modified: 20131219100410583
|
modified: 20140224134310019
|
||||||
title: TiddlyWiki on Node.js
|
title: TiddlyWiki on Node.js
|
||||||
type: text/vnd.tiddlywiki
|
type: text/vnd.tiddlywiki
|
||||||
|
|
||||||
@ -20,9 +20,3 @@ Running TiddlyWiki on [[Node.js]] brings several important benefits over and abo
|
|||||||
! Upgrading
|
! Upgrading
|
||||||
|
|
||||||
{{Upgrading TiddlyWiki on Node.js}}
|
{{Upgrading TiddlyWiki on Node.js}}
|
||||||
|
|
||||||
! Commands
|
|
||||||
|
|
||||||
The following commands are available:
|
|
||||||
|
|
||||||
<ul><$list filter="[tag[command]]"><li><$link to={{!!title}}><$view field="title"/></$link></li></$list></ul>
|
|
||||||
|
@ -0,0 +1,64 @@
|
|||||||
|
created: 20140223183404938
|
||||||
|
modified: 20140223195514667
|
||||||
|
tags: howto
|
||||||
|
title: Notes for upgrading to 5.0.8-beta
|
||||||
|
type: text/vnd.tiddlywiki
|
||||||
|
|
||||||
|
Version 5.0.8-beta includes some changes that can break content from earlier releases of ~TiddlyWiki 5.
|
||||||
|
|
||||||
|
! Change to [[$:/SiteTitle]] and [[$:/SiteSubtitle]]
|
||||||
|
|
||||||
|
You should rename any existing SiteTitle and SiteSubtitle tiddlers to [[$:/SiteTitle]] and [[$:/SiteSubtitle]] respectively.
|
||||||
|
|
||||||
|
! Changed parsing rules for content of HTML elements
|
||||||
|
|
||||||
|
Version 5.0.8-beta marks a change in the way that TiddlyWiki determines whether to parse the content of an HTML element or widget in //block mode// or //inline mode//.
|
||||||
|
|
||||||
|
* In block mode, TiddlyWiki parses text into paragraphs, creating `<p>` tags to wrap them. It also recognises block syntax like headings, lists and tables.
|
||||||
|
|
||||||
|
* In inline mode, TiddlyWiki ignores paragraph formatting, and just recognises character formatting, like bold and italic.
|
||||||
|
|
||||||
|
It's important to be able to control which type of parsing is performed for different situations.
|
||||||
|
|
||||||
|
Prior to 5.0.8-beta, TiddlyWiki parsed the content of an element in inline mode unless the opening tag of the element were immediately followed by a line break. This meant that much of the time element tags would be shunted together into a long line, hindering readability.
|
||||||
|
|
||||||
|
The new behaviour for 5.0.8-beta is to parse the content of an element in inline mode unless the opening tag is immediately followed by two line breaks.
|
||||||
|
|
||||||
|
To adjust existing content for 5.0.8-beta you will need to manually add the additional line break after the opening tag of elements and widgets whose content should be parsed in block mode.
|
||||||
|
|
||||||
|
The positive aspect of the change is that it removes the need to pack multiple HTML tags onto a single line, improving readability.
|
||||||
|
|
||||||
|
!! Examples
|
||||||
|
|
||||||
|
Consider the difference between these two examples. First, here's an HTML tag that starts with two line breaks:
|
||||||
|
|
||||||
|
<<wikitext-example src:"
|
||||||
|
<blockquote>
|
||||||
|
|
||||||
|
! This is a heading
|
||||||
|
|
||||||
|
And a paragraph of text.
|
||||||
|
|
||||||
|
</blockquote>
|
||||||
|
">>
|
||||||
|
|
||||||
|
Secondly, here's an HTML tag with just a single line break. Notice how the heading is no longer recognised as a heading
|
||||||
|
|
||||||
|
<<wikitext-example src:"
|
||||||
|
<blockquote>
|
||||||
|
! This is a heading
|
||||||
|
|
||||||
|
And a paragraph of text.
|
||||||
|
</blockquote>
|
||||||
|
">>
|
||||||
|
|
||||||
|
! Changed commands for [[TiddlyWiki on Node.js]]
|
||||||
|
|
||||||
|
The handling of wiki folders has changed. Previously, if the `tiddlywiki` command was run against a wiki folder that didn't have the necessary `tiddlywiki.info` file then it would be automatically created. Now, the wiki folder must be initialised with the InitCommand.
|
||||||
|
|
||||||
|
This is how to create and start a new server-based wiki:
|
||||||
|
|
||||||
|
```
|
||||||
|
tiddlywiki mywikifolder --init server
|
||||||
|
tiddlywiki mywikifolder --server
|
||||||
|
```
|
@ -12,10 +12,7 @@
|
|||||||
"tiddlywiki/starlight",
|
"tiddlywiki/starlight",
|
||||||
"tiddlywiki/stickytitles",
|
"tiddlywiki/stickytitles",
|
||||||
"tiddlywiki/centralised",
|
"tiddlywiki/centralised",
|
||||||
"tiddlywiki/readonly",
|
"tiddlywiki/readonly"
|
||||||
"giffmex/rocker",
|
|
||||||
"giffmex/blue",
|
|
||||||
"giffmex/blanca"
|
|
||||||
],
|
],
|
||||||
"languages": [
|
"languages": [
|
||||||
"en-US",
|
"en-US",
|
||||||
|
@ -40,10 +40,10 @@ Plugins/Caption: 插件
|
|||||||
Plugins/Fields/Description: 说明
|
Plugins/Fields/Description: 说明
|
||||||
Plugins/Fields/Title: 标题
|
Plugins/Fields/Title: 标题
|
||||||
Plugins/Fields/Version: 版本
|
Plugins/Fields/Version: 版本
|
||||||
Saving/AutoSave/Disabled/Button:
|
Saving/AutoSave/Disabled/Button: 启用
|
||||||
Saving/AutoSave/Disabled/Prompt: 自动保存已<$linkcatcher to="$:/config/AutoSave"><$link to="yes">@@color:#c0c0c0;''停用''@@</$link></$linkcatcher>
|
Saving/AutoSave/Disabled/Prompt: 自动保存已停用
|
||||||
Saving/AutoSave/Enabled/Button:
|
Saving/AutoSave/Enabled/Button: 停用
|
||||||
Saving/AutoSave/Enabled/Prompt: 自动保存已<$linkcatcher to="$:/config/AutoSave"><$link to="no">@@color:green;''启用''@@</$link></$linkcatcher>
|
Saving/AutoSave/Enabled/Prompt: 自动保存已启用
|
||||||
Saving/AutoSave: 自动保存
|
Saving/AutoSave: 自动保存
|
||||||
Saving/Caption: 保存
|
Saving/Caption: 保存
|
||||||
Saving/Heading: 保存
|
Saving/Heading: 保存
|
||||||
|
@ -40,10 +40,10 @@ Plugins/Caption: 插件
|
|||||||
Plugins/Fields/Description: 說明
|
Plugins/Fields/Description: 說明
|
||||||
Plugins/Fields/Title: 標題
|
Plugins/Fields/Title: 標題
|
||||||
Plugins/Fields/Version: 版本
|
Plugins/Fields/Version: 版本
|
||||||
Saving/AutoSave/Disabled/Button:
|
Saving/AutoSave/Disabled/Button: 啟用
|
||||||
Saving/AutoSave/Disabled/Prompt: 自動儲存已<$linkcatcher to="$:/config/AutoSave"><$link to="yes">@@color:#c0c0c0;''停用''@@</$link></$linkcatcher>
|
Saving/AutoSave/Disabled/Prompt: 自動儲存已停用
|
||||||
Saving/AutoSave/Enabled/Button:
|
Saving/AutoSave/Enabled/Button: 停用
|
||||||
Saving/AutoSave/Enabled/Prompt: 自動儲存已<$linkcatcher to="$:/config/AutoSave"><$link to="no">@@color:green;''啟用''@@</$link></$linkcatcher>
|
Saving/AutoSave/Enabled/Prompt: 自動儲存已啟用
|
||||||
Saving/AutoSave: 自動儲存
|
Saving/AutoSave: 自動儲存
|
||||||
Saving/Caption: 儲存
|
Saving/Caption: 儲存
|
||||||
Saving/Heading: 儲存
|
Saving/Heading: 儲存
|
||||||
|
@ -5,7 +5,7 @@ rem serve TiddlyWiki5 over HTTP
|
|||||||
rem Optional parameter is the username for signing edits
|
rem Optional parameter is the username for signing edits
|
||||||
|
|
||||||
node .\tiddlywiki.js ^
|
node .\tiddlywiki.js ^
|
||||||
editions\clientserver ^
|
editions\tw5.com-server ^
|
||||||
--verbose ^
|
--verbose ^
|
||||||
--server 8080 $:/core/save/all text/plain text/html %1 %2^
|
--server 8080 $:/core/save/all text/plain text/html %1 %2^
|
||||||
|| exit 1
|
|| exit 1
|
||||||
|
2
serve.sh
2
serve.sh
@ -5,7 +5,7 @@
|
|||||||
# Optional parameter is the username for signing edits
|
# Optional parameter is the username for signing edits
|
||||||
|
|
||||||
node ./tiddlywiki.js \
|
node ./tiddlywiki.js \
|
||||||
editions/clientserver \
|
editions/tw5.com-server \
|
||||||
--verbose \
|
--verbose \
|
||||||
--server 8080 $:/core/save/all text/plain text/html $1 $2\
|
--server 8080 $:/core/save/all text/plain text/html $1 $2\
|
||||||
|| exit 1
|
|| exit 1
|
||||||
|
@ -22,44 +22,3 @@ html body {
|
|||||||
.tw-page-controls svg {
|
.tw-page-controls svg {
|
||||||
<<filter "drop-shadow(1px 1px 2px rgba(255,255,255,0.9))">>
|
<<filter "drop-shadow(1px 1px 2px rgba(255,255,255,0.9))">>
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
** Some rainbow icon colours
|
|
||||||
*/
|
|
||||||
|
|
||||||
svg.tw-image-new-button {
|
|
||||||
fill: #5eb95e; /* Green */
|
|
||||||
}
|
|
||||||
|
|
||||||
svg.tw-image-options-button {
|
|
||||||
fill: rgb(128, 88, 165); /* Purple */
|
|
||||||
}
|
|
||||||
|
|
||||||
svg.tw-image-save-button {
|
|
||||||
fill: #0e90d2; /* Light blue */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-info-button {
|
|
||||||
fill: #0e90d2; /* Light blue */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-edit-button {
|
|
||||||
fill: rgb(243, 123, 29); /* Orange */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-close-button {
|
|
||||||
fill: #dd514c; /* Red */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-delete-button {
|
|
||||||
fill: #dd514c; /* Red */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-cancel-button {
|
|
||||||
fill: rgb(243, 123, 29); /* Orange */
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tiddler-controls button svg.tw-image-done-button {
|
|
||||||
fill: #5eb95e; /* Green */
|
|
||||||
}
|
|
||||||
|
|
||||||
|
@ -150,6 +150,18 @@ a.tw-tiddlylink-missing {
|
|||||||
|
|
||||||
a.tw-tiddlylink-external {
|
a.tw-tiddlylink-external {
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
|
color: <<colour external-link-foreground>>;
|
||||||
|
background-color: <<colour external-link-background>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.tw-tiddlylink-external:visited {
|
||||||
|
color: <<colour external-link-foreground-visited>>;
|
||||||
|
background-color: <<colour external-link-background-visited>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.tw-tiddlylink-external:hover {
|
||||||
|
color: <<colour external-link-foreground-hover>>;
|
||||||
|
background-color: <<colour external-link-background-hover>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -301,6 +313,10 @@ a.tw-tiddlylink-external {
|
|||||||
margin-bottom: 3px;
|
margin-bottom: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.sidebar-header .tw-missing-tiddler-label {
|
||||||
|
color: <<colour sidebar-foreground>>;
|
||||||
|
}
|
||||||
|
|
||||||
.tw-search a svg {
|
.tw-search a svg {
|
||||||
height: 0.75em;
|
height: 0.75em;
|
||||||
}
|
}
|
||||||
@ -325,7 +341,7 @@ a.tw-tiddlylink-external {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.tw-page-controls button:hover svg, .tw-page-controls a:hover svg {
|
.tw-page-controls button:hover svg, .tw-page-controls a:hover svg {
|
||||||
fill: <<colour sidebar-controls-foreground-hover>;
|
fill: <<colour sidebar-controls-foreground-hover>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tw-menu-list-item {
|
.tw-menu-list-item {
|
||||||
@ -493,7 +509,7 @@ a.tw-tiddlylink-external {
|
|||||||
fill: <<colour tiddler-controls-foreground-selected>>;
|
fill: <<colour tiddler-controls-foreground-selected>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tw-tiddler-controls button:hover svg {
|
.tw-tiddler-controls button.btn-invisible:hover svg {
|
||||||
fill: <<colour tiddler-controls-foreground-hover>>;
|
fill: <<colour tiddler-controls-foreground-hover>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -543,6 +559,46 @@ canvas.tw-edit-bitmapeditor {
|
|||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
** Toolbar buttons
|
||||||
|
*/
|
||||||
|
|
||||||
|
.tw-page-controls svg.tw-image-new-button {
|
||||||
|
fill: <<colour toolbar-new-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-page-controls svg.tw-image-options-button {
|
||||||
|
fill: <<colour toolbar-options-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-page-controls svg.tw-image-save-button {
|
||||||
|
fill: <<colour toolbar-save-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-info-button {
|
||||||
|
fill: <<colour toolbar-info-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-edit-button {
|
||||||
|
fill: <<colour toolbar-edit-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-close-button {
|
||||||
|
fill: <<colour toolbar-close-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-delete-button {
|
||||||
|
fill: <<colour toolbar-delete-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-cancel-button {
|
||||||
|
fill: <<colour toolbar-cancel-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-tiddler-controls button svg.tw-image-done-button {
|
||||||
|
fill: <<colour toolbar-done-button>>;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Tiddler edit mode
|
** Tiddler edit mode
|
||||||
*/
|
*/
|
||||||
@ -816,6 +872,14 @@ canvas.tw-edit-bitmapeditor {
|
|||||||
margin-bottom: -1px;
|
margin-bottom: -1px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.tw-tab-buttons button.tw-tab-selected {
|
||||||
|
color: <<colour tab-foreground-selected>>;
|
||||||
|
background-color: <<colour tab-background-selected>>;
|
||||||
|
border-left: 1px solid <<colour tab-border-selected>>;
|
||||||
|
border-top: 1px solid <<colour tab-border-selected>>;
|
||||||
|
border-right: 1px solid <<colour tab-border-selected>>;
|
||||||
|
}
|
||||||
|
|
||||||
.tw-tab-buttons button {
|
.tw-tab-buttons button {
|
||||||
color: <<colour tab-foreground>>;
|
color: <<colour tab-foreground>>;
|
||||||
margin-left: 2px;
|
margin-left: 2px;
|
||||||
@ -823,16 +887,6 @@ canvas.tw-edit-bitmapeditor {
|
|||||||
font-weight: 300;
|
font-weight: 300;
|
||||||
border: none;
|
border: none;
|
||||||
background: inherit;
|
background: inherit;
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tab-buttons button.tw-tab-selected {
|
|
||||||
background-color: <<colour tab-background-selected>>;
|
|
||||||
border-left: 1px solid <<colour tab-border-selected>>;
|
|
||||||
border-top: 1px solid <<colour tab-border-selected>>;
|
|
||||||
border-right: 1px solid <<colour tab-border-selected>>;
|
|
||||||
}
|
|
||||||
|
|
||||||
.tw-tab-buttons button:not(.tw-tab-selected) {
|
|
||||||
background-color: <<colour tab-background>>;
|
background-color: <<colour tab-background>>;
|
||||||
border-left: 1px solid <<colour tab-border>>;
|
border-left: 1px solid <<colour tab-border>>;
|
||||||
border-top: 1px solid <<colour tab-border>>;
|
border-top: 1px solid <<colour tab-border>>;
|
||||||
@ -849,12 +903,22 @@ canvas.tw-edit-bitmapeditor {
|
|||||||
|
|
||||||
.tw-sidebar-lists .tw-tab-buttons button.tw-tab-selected {
|
.tw-sidebar-lists .tw-tab-buttons button.tw-tab-selected {
|
||||||
background-color: <<colour sidebar-tab-background-selected>>;
|
background-color: <<colour sidebar-tab-background-selected>>;
|
||||||
|
color: <<colour sidebar-tab-foreground-selected>>;
|
||||||
|
border-left: 1px solid <<colour sidebar-tab-border-selected>>;
|
||||||
|
border-top: 1px solid <<colour sidebar-tab-border-selected>>;
|
||||||
|
border-right: 1px solid <<colour sidebar-tab-border-selected>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tw-sidebar-lists .tw-tab-buttons button {
|
||||||
|
background-color: <<colour sidebar-tab-background>>;
|
||||||
|
color: <<colour sidebar-tab-foreground>>;
|
||||||
|
border-left: 1px solid <<colour sidebar-tab-border>>;
|
||||||
|
border-top: 1px solid <<colour sidebar-tab-border>>;
|
||||||
|
border-right: 1px solid <<colour sidebar-tab-border>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tw-sidebar-lists .tw-tab-divider {
|
.tw-sidebar-lists .tw-tab-divider {
|
||||||
border-top: none;
|
border-top: 1px solid <<colour sidebar-tab-divider>>;
|
||||||
height: 1px;
|
|
||||||
<<background-linear-gradient "left, rgb(216,216,216) 0%, rgb(236,236,236) 250px">>
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.tw-more-sidebar {
|
.tw-more-sidebar {
|
||||||
|
Loading…
Reference in New Issue
Block a user