From 7cd13f71630bdc2fef67f2b9b9f601ffff0ceff0 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 07:49:48 +0100 Subject: [PATCH 01/15] Give Cecily a readme --- plugins/tiddlywiki/cecily/plugin.info | 3 ++- plugins/tiddlywiki/cecily/readme.tid | 7 +++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 plugins/tiddlywiki/cecily/readme.tid diff --git a/plugins/tiddlywiki/cecily/plugin.info b/plugins/tiddlywiki/cecily/plugin.info index 1463a4a58..d60579389 100644 --- a/plugins/tiddlywiki/cecily/plugin.info +++ b/plugins/tiddlywiki/cecily/plugin.info @@ -2,5 +2,6 @@ "title": "$:/plugins/tiddlywiki/cecily", "description": "Zoomable User Interface for TiddlyWiki", "author": "JeremyRuston", - "core-version": ">=5.0.0" + "core-version": ">=5.0.0", + "list": "readme" } diff --git a/plugins/tiddlywiki/cecily/readme.tid b/plugins/tiddlywiki/cecily/readme.tid new file mode 100644 index 000000000..c12e6b314 --- /dev/null +++ b/plugins/tiddlywiki/cecily/readme.tid @@ -0,0 +1,7 @@ +title: $:/plugins/tiddlywiki/cecily/readme + +This plugin provides a new story visualisation that displays individual tiddlers as resizable tiles on an infinite canvas. + +Cecily is based on an earlier plugin for TiddlyWiki Classic: http://jermolene.com/cecily + +Cecily is currently in the early stages of development with little functionality yet implemented. From 3d7e43fa7aa1ee0e98d5ca4454aee00d434a44c2 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 07:50:00 +0100 Subject: [PATCH 02/15] Move the Cecily icon --- {core/images => plugins/tiddlywiki/cecily}/storyview-cecily.tid | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename {core/images => plugins/tiddlywiki/cecily}/storyview-cecily.tid (100%) diff --git a/core/images/storyview-cecily.tid b/plugins/tiddlywiki/cecily/storyview-cecily.tid similarity index 100% rename from core/images/storyview-cecily.tid rename to plugins/tiddlywiki/cecily/storyview-cecily.tid From b64b1ab9cc2182ef802f2659e39d14ef26155c18 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 10:00:40 +0100 Subject: [PATCH 03/15] Better icon for the core plugin --- core/icon.tid | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/icon.tid b/core/icon.tid index fb8262d61..933275a2c 100644 --- a/core/icon.tid +++ b/core/icon.tid @@ -1,3 +1,8 @@ title: $:/core/icon +tags: $:/tags/Image -{{$:/core/images/globe}} + + + + + \ No newline at end of file From d01efe86980586dba93d2434d028db68e530c93c Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 10:00:59 +0100 Subject: [PATCH 04/15] Generic fallback icons for plugins --- core/images/plugin-generic-language.tid | 8 ++++++++ core/images/plugin-generic-plugin.tid | 8 ++++++++ core/images/plugin-generic-theme.tid | 8 ++++++++ 3 files changed, 24 insertions(+) create mode 100644 core/images/plugin-generic-language.tid create mode 100644 core/images/plugin-generic-plugin.tid create mode 100644 core/images/plugin-generic-theme.tid diff --git a/core/images/plugin-generic-language.tid b/core/images/plugin-generic-language.tid new file mode 100644 index 000000000..1c5aa3ce5 --- /dev/null +++ b/core/images/plugin-generic-language.tid @@ -0,0 +1,8 @@ +title: $:/core/images/plugin-generic-language +tags: $:/tags/Image + + + + + + \ No newline at end of file diff --git a/core/images/plugin-generic-plugin.tid b/core/images/plugin-generic-plugin.tid new file mode 100644 index 000000000..eb24b4e0b --- /dev/null +++ b/core/images/plugin-generic-plugin.tid @@ -0,0 +1,8 @@ +title: $:/core/images/plugin-generic-plugin +tags: $:/tags/Image + + + + + + \ No newline at end of file diff --git a/core/images/plugin-generic-theme.tid b/core/images/plugin-generic-theme.tid new file mode 100644 index 000000000..3785aa1b1 --- /dev/null +++ b/core/images/plugin-generic-theme.tid @@ -0,0 +1,8 @@ +title: $:/core/images/plugin-generic-theme +tags: $:/tags/Image + + + + + + \ No newline at end of file From bd92dc3692c5dcb4f0722c1b6d563c237cff355e Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 10:01:21 +0100 Subject: [PATCH 05/15] Improve plugin tab layout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It’s still a bit of a mess, and the vertical alignment isn’t working properly --- core/ui/ControlPanel/Plugins.tid | 61 ++++++++++++++---------------- themes/tiddlywiki/vanilla/base.tid | 17 +++++++++ 2 files changed, 45 insertions(+), 33 deletions(-) diff --git a/core/ui/ControlPanel/Plugins.tid b/core/ui/ControlPanel/Plugins.tid index ece3ba717..a63026cc8 100644 --- a/core/ui/ControlPanel/Plugins.tid +++ b/core/ui/ControlPanel/Plugins.tid @@ -14,23 +14,10 @@ $(currentTiddler)$/icon \end \define plugin-table(type) <$set name="qualified-state" value=<>> - - - - - - - <$list filter="[!has[draft.of]plugin-type[$type$]sort[description]]"> <$set name="popup-state" value=<>> - - - - - - - - + - -
-  - -<> - -<> -
+
+
<$reveal type="nomatch" state=<> text="yes"> <$button class="btn-invisible btn-dropdown" set=<> setTo="yes"> {{$:/core/images/right-arrow}} @@ -41,34 +28,42 @@ $(currentTiddler)$/icon {{$:/core/images/down-arrow}} -
-<$link to={{!!title}}> -<$transclude tiddler=<> subtiddler=<>/> -''<$view field="description"><$view field="title"/>''
-<$view field="title"/> - -
+ +<$link to={{!!title}} class="tw-plugin-info-link"> +
+
+<$transclude tiddler=<> subtiddler=<>> +<$transclude tiddler="$:/core/images/plugin-generic-$type$"/> + +
+
+
+''<$view field="description"><$view field="title"/>'' +
+
+<$view field="title"/>
+
+
<$view field="version"/> -
+ + + + <$reveal type="match" text="yes" state=<>> <$reveal type="nomatch" text="" state="!!list"> +
<$macrocall $name="tabs" state=<> tabsList={{!!list}} default="readme" template="$:/core/ui/PluginInfo"/> +
<$reveal type="match" text="" state="!!list"> -<$transclude tiddler="$:/core/ui/TiddlerInfo/Advanced/PluginInfo"/> +
+No information provided +
-
\end diff --git a/themes/tiddlywiki/vanilla/base.tid b/themes/tiddlywiki/vanilla/base.tid index 2bf84c75d..7d70c92b2 100644 --- a/themes/tiddlywiki/vanilla/base.tid +++ b/themes/tiddlywiki/vanilla/base.tid @@ -1238,6 +1238,23 @@ canvas.tw-edit-bitmapeditor { width: 100%; } +.tw-plugin-info { + vertical-align: middle; + border: 1px solid <>; + margin: 1em 0 1em 0; + padding: 8px; +} + +.tw-plugin-info img, .tw-plugin-info svg { + width: 3em; + height: 3em; +} + +.tw-plugin-info .tw-plugin-info-dropdown-button, +.tw-plugin-info .tw-tiddlylink { + display: inline-block; +} + /* ** Message boxes */ From d7390dbbe160f80236e7c6f3bc4afeb119b8faa2 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 11:13:41 +0100 Subject: [PATCH 06/15] Remove support for underscore and dash in wikilinks Starting to fix #337 --- core/modules/parsers/wikiparser/rules/wikilink.js | 7 +++---- editions/test/tiddlers/tests/test-wikitext.js | 5 +++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/core/modules/parsers/wikiparser/rules/wikilink.js b/core/modules/parsers/wikiparser/rules/wikilink.js index 152b4e193..e41be42cf 100644 --- a/core/modules/parsers/wikiparser/rules/wikilink.js +++ b/core/modules/parsers/wikiparser/rules/wikilink.js @@ -25,9 +25,8 @@ exports.types = {inline: true}; var textPrimitives = { upperLetter: "[A-Z\u00c0-\u00de\u0150\u0170]", - lowerLetter: "[a-z0-9_\\-\u00df-\u00ff\u0151\u0171]", - anyLetter: "[A-Za-z0-9_\\-\u00c0-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]", - anyLetterStrict: "[A-Za-z0-9\u00c0-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]" + lowerLetter: "[a-z0-9\u00df-\u00ff\u0151\u0171]", + anyLetter: "[A-Za-z0-9\u00c0-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]" }; textPrimitives.unWikiLink = "~"; @@ -56,7 +55,7 @@ exports.parse = function() { } // If the link has been preceded with a letter then don't treat it as a link if(this.match.index > 0) { - var preRegExp = new RegExp(textPrimitives.anyLetterStrict,"mg"); + var preRegExp = new RegExp(textPrimitives.anyLetter,"mg"); preRegExp.lastIndex = this.match.index-1; var preMatch = preRegExp.exec(this.parser.source); if(preMatch && preMatch.index === this.match.index-1) { diff --git a/editions/test/tiddlers/tests/test-wikitext.js b/editions/test/tiddlers/tests/test-wikitext.js index 223f3306e..39c1649df 100644 --- a/editions/test/tiddlers/tests/test-wikitext.js +++ b/editions/test/tiddlers/tests/test-wikitext.js @@ -45,6 +45,11 @@ describe("WikiText tests", function() { it("should support attributes specified as macro invocations", function() { expect(wiki.renderTiddler("text/html","TiddlerFour")).toBe("

This is a link

"); }); + it("should identify wikiwords to automatically link", function() { + expect(wiki.renderText("text/html","text/vnd-tiddlywiki","No wikilinks here").indexOf(" Date: Fri, 8 Aug 2014 16:09:56 +0100 Subject: [PATCH 07/15] =?UTF-8?q?Stop=20classifying=20"=C3=97"=20(\u00d7)?= =?UTF-8?q?=20as=20a=20lower=20case=20letter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Part of #337 --- core/modules/parsers/wikiparser/rules/wikilink.js | 4 ++-- editions/test/tiddlers/tests/test-wikitext.js | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/core/modules/parsers/wikiparser/rules/wikilink.js b/core/modules/parsers/wikiparser/rules/wikilink.js index e41be42cf..447bf660d 100644 --- a/core/modules/parsers/wikiparser/rules/wikilink.js +++ b/core/modules/parsers/wikiparser/rules/wikilink.js @@ -24,9 +24,9 @@ exports.name = "wikilink"; exports.types = {inline: true}; var textPrimitives = { - upperLetter: "[A-Z\u00c0-\u00de\u0150\u0170]", + upperLetter: "[A-Z\u00c0-\u00d6\u00d8-\u00de\u0150\u0170]", lowerLetter: "[a-z0-9\u00df-\u00ff\u0151\u0171]", - anyLetter: "[A-Za-z0-9\u00c0-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]" + anyLetter: "[A-Za-z0-9\u00c0-\u00d6\u00d8-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]" }; textPrimitives.unWikiLink = "~"; diff --git a/editions/test/tiddlers/tests/test-wikitext.js b/editions/test/tiddlers/tests/test-wikitext.js index 39c1649df..c9f47ebcd 100644 --- a/editions/test/tiddlers/tests/test-wikitext.js +++ b/editions/test/tiddlers/tests/test-wikitext.js @@ -49,6 +49,7 @@ describe("WikiText tests", function() { expect(wiki.renderText("text/html","text/vnd-tiddlywiki","No wikilinks here").indexOf(" Date: Fri, 8 Aug 2014 16:12:23 +0100 Subject: [PATCH 08/15] =?UTF-8?q?Stop=20classifyinh=20"=C3=B7"=20(\u00f7)?= =?UTF-8?q?=20as=20an=20upper=20case=20letter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Part of #337 --- core/modules/parsers/wikiparser/rules/wikilink.js | 4 ++-- editions/test/tiddlers/tests/test-wikitext.js | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/core/modules/parsers/wikiparser/rules/wikilink.js b/core/modules/parsers/wikiparser/rules/wikilink.js index 447bf660d..7be9a5f0e 100644 --- a/core/modules/parsers/wikiparser/rules/wikilink.js +++ b/core/modules/parsers/wikiparser/rules/wikilink.js @@ -25,8 +25,8 @@ exports.types = {inline: true}; var textPrimitives = { upperLetter: "[A-Z\u00c0-\u00d6\u00d8-\u00de\u0150\u0170]", - lowerLetter: "[a-z0-9\u00df-\u00ff\u0151\u0171]", - anyLetter: "[A-Za-z0-9\u00c0-\u00d6\u00d8-\u00de\u00df-\u00ff\u0150\u0170\u0151\u0171]" + lowerLetter: "[a-z0-9\u00df-\u00f6\u00f8-\u00ff\u0151\u0171]", + anyLetter: "[A-Za-z0-9\u00c0-\u00d6\u00d8-\u00de\u00df-\u00f6\u00f8-\u00ff\u0150\u0170\u0151\u0171]" }; textPrimitives.unWikiLink = "~"; diff --git a/editions/test/tiddlers/tests/test-wikitext.js b/editions/test/tiddlers/tests/test-wikitext.js index c9f47ebcd..c252ddffc 100644 --- a/editions/test/tiddlers/tests/test-wikitext.js +++ b/editions/test/tiddlers/tests/test-wikitext.js @@ -50,6 +50,7 @@ describe("WikiText tests", function() { expect(wiki.renderText("text/html","text/vnd-tiddlywiki","One WikiLink here").indexOf(" Date: Fri, 8 Aug 2014 16:20:15 +0100 Subject: [PATCH 09/15] Disable wikilinking when preceded with dash or underscore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit “HelloThere” in “My-HelloThere” shouldn’t be wikified. Part of #337 --- core/modules/parsers/wikiparser/rules/wikilink.js | 7 ++++--- editions/test/tiddlers/tests/test-wikitext.js | 3 +++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/core/modules/parsers/wikiparser/rules/wikilink.js b/core/modules/parsers/wikiparser/rules/wikilink.js index 7be9a5f0e..f4b543896 100644 --- a/core/modules/parsers/wikiparser/rules/wikilink.js +++ b/core/modules/parsers/wikiparser/rules/wikilink.js @@ -26,7 +26,8 @@ exports.types = {inline: true}; var textPrimitives = { upperLetter: "[A-Z\u00c0-\u00d6\u00d8-\u00de\u0150\u0170]", lowerLetter: "[a-z0-9\u00df-\u00f6\u00f8-\u00ff\u0151\u0171]", - anyLetter: "[A-Za-z0-9\u00c0-\u00d6\u00d8-\u00de\u00df-\u00f6\u00f8-\u00ff\u0150\u0170\u0151\u0171]" + anyLetter: "[A-Za-z0-9\u00c0-\u00d6\u00d8-\u00de\u00df-\u00f6\u00f8-\u00ff\u0150\u0170\u0151\u0171]", + blockPrefixLetters: "[A-Za-z0-9\-_\u00c0-\u00d6\u00d8-\u00de\u00df-\u00f6\u00f8-\u00ff\u0150\u0170\u0151\u0171]" }; textPrimitives.unWikiLink = "~"; @@ -53,9 +54,9 @@ exports.parse = function() { if(linkText.substr(0,1) === textPrimitives.unWikiLink) { return [{type: "text", text: linkText.substr(1)}]; } - // If the link has been preceded with a letter then don't treat it as a link + // If the link has been preceded with a blocked letter then don't treat it as a link if(this.match.index > 0) { - var preRegExp = new RegExp(textPrimitives.anyLetter,"mg"); + var preRegExp = new RegExp(textPrimitives.blockPrefixLetters,"mg"); preRegExp.lastIndex = this.match.index-1; var preMatch = preRegExp.exec(this.parser.source); if(preMatch && preMatch.index === this.match.index-1) { diff --git a/editions/test/tiddlers/tests/test-wikitext.js b/editions/test/tiddlers/tests/test-wikitext.js index c252ddffc..271688cee 100644 --- a/editions/test/tiddlers/tests/test-wikitext.js +++ b/editions/test/tiddlers/tests/test-wikitext.js @@ -51,6 +51,9 @@ describe("WikiText tests", function() { expect(wiki.renderText("text/html","text/vnd-tiddlywiki","No Wiki-Link here").indexOf(" Date: Fri, 8 Aug 2014 16:35:17 +0100 Subject: [PATCH 10/15] Improved formatting for control panel plugins --- core/ui/ControlPanel/Plugins.tid | 6 +++--- themes/tiddlywiki/snowwhite/base.tid | 4 ++++ themes/tiddlywiki/vanilla/base.tid | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/core/ui/ControlPanel/Plugins.tid b/core/ui/ControlPanel/Plugins.tid index a63026cc8..cc3755620 100644 --- a/core/ui/ControlPanel/Plugins.tid +++ b/core/ui/ControlPanel/Plugins.tid @@ -31,17 +31,17 @@ $(currentTiddler)$/icon <$link to={{!!title}} class="tw-plugin-info-link">
-
+
<$transclude tiddler=<> subtiddler=<>> <$transclude tiddler="$:/core/images/plugin-generic-$type$"/>
-
+
''<$view field="description"><$view field="title"/>''
-<$view field="title"/>
+<$view field="title"/>
<$view field="version"/> diff --git a/themes/tiddlywiki/snowwhite/base.tid b/themes/tiddlywiki/snowwhite/base.tid index 30f5d66d3..5a93f2b3e 100644 --- a/themes/tiddlywiki/snowwhite/base.tid +++ b/themes/tiddlywiki/snowwhite/base.tid @@ -100,3 +100,7 @@ canvas.tw-edit-bitmapeditor { .tw-message-box img { <> } + +.tw-plugin-info { + <> +} diff --git a/themes/tiddlywiki/vanilla/base.tid b/themes/tiddlywiki/vanilla/base.tid index 7d70c92b2..bc3ee4f00 100644 --- a/themes/tiddlywiki/vanilla/base.tid +++ b/themes/tiddlywiki/vanilla/base.tid @@ -1239,7 +1239,6 @@ canvas.tw-edit-bitmapeditor { } .tw-plugin-info { - vertical-align: middle; border: 1px solid <>; margin: 1em 0 1em 0; padding: 8px; @@ -1253,6 +1252,7 @@ canvas.tw-edit-bitmapeditor { .tw-plugin-info .tw-plugin-info-dropdown-button, .tw-plugin-info .tw-tiddlylink { display: inline-block; + vertical-align: middle; } /* From cc4552f5446c52a37459849e54bc60085d6a0941 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 16:35:28 +0100 Subject: [PATCH 11/15] Readme update --- plugins/tiddlywiki/browser-sniff/readme.tid | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/plugins/tiddlywiki/browser-sniff/readme.tid b/plugins/tiddlywiki/browser-sniff/readme.tid index cdcd03de3..474b935ff 100644 --- a/plugins/tiddlywiki/browser-sniff/readme.tid +++ b/plugins/tiddlywiki/browser-sniff/readme.tid @@ -7,7 +7,7 @@ This plugin adds a number of `$:/info/` tiddlers containing information about th |!Title |!Description | |[[$:/info/browser/is/android]] |Running on Android? ("yes" or "no") | |[[$:/info/browser/is/bada]] |Running on Bada? ("yes" or "no") | -|[[$:/info/browser/is/blackberry]] |Running on Blackberry? ("yes" or "no") | +|[[$:/info/browser/is/blackberry]] |Running on ~BlackBerry? ("yes" or "no") | |[[$:/info/browser/is/chrome]] |Running on Chrome? ("yes" or "no") | |[[$:/info/browser/is/firefox]] |Running on Firefox? ("yes" or "no") | |[[$:/info/browser/is/firefoxos]] |Running on Firefox OS? ("yes" or "no") | @@ -17,14 +17,14 @@ This plugin adds a number of `$:/info/` tiddlers containing information about th |[[$:/info/browser/is/iphone]] |Running on iPhone? ("yes" or "no") | |[[$:/info/browser/is/ipod]] |Running on iPod? ("yes" or "no") | |[[$:/info/browser/is/opera]] |Running on Opera? ("yes" or "no") | -|[[$:/info/browser/is/phantomjs]] |Running on PhantomJS? ("yes" or "no") | +|[[$:/info/browser/is/phantomjs]] |Running on ~PhantomJS? ("yes" or "no") | |[[$:/info/browser/is/safari]] |Running on Safari? ("yes" or "no") | |[[$:/info/browser/is/sailfish]] |Running on Sailfish? ("yes" or "no") | |[[$:/info/browser/is/seamonkey]] |Running on Sea Monkey? ("yes" or "no") | |[[$:/info/browser/is/silk]] |Running on Amazon's Silk? ("yes" or "no") | |[[$:/info/browser/is/tizen]] |Running on Tizen? ("yes" or "no") | -|[[$:/info/browser/is/webkit]] |Running on WebKit? ("yes" or "no") | -|[[$:/info/browser/is/webos]] |Running on WebOS? ("yes" or "no") | +|[[$:/info/browser/is/webkit]] |Running on ~WebKit? ("yes" or "no") | +|[[$:/info/browser/is/webos]] |Running on ~WebOS? ("yes" or "no") | |[[$:/info/browser/is/windowsphone]] |Running on Windows Phone? ("yes" or "no") | |[[$:/info/browser/name]] |Platform name (see below) | |[[$:/info/browser/version]] |Browser version | @@ -34,19 +34,19 @@ The browser information is obtained with [[Bowser, a browser detector library fr * ''"Amazon Silk"'' * ''"Android"'' * ''"Bada"'' -* ''"BlackBerry"'' +* ''"~BlackBerry"'' * ''"Chrome"'' * ''"Firefox"'' * ''"Internet Explorer"'' * ''"iOS"'' * ''"Opera"'' -* ''"PhantomJS"'' +* ''"~PhantomJS"'' * ''"Safari"'' * ''"Sailfish"'' -* ''"SeaMonkey"'' -* ''"TiddlyDesktop"'' +* ''"~SeaMonkey"'' +* ''"~TiddlyDesktop"'' * ''"Tizen"'' -* ''"WebOS"'' +* ''"~WebOS"'' * ''"Windows Phone"'' Note that Bowser returns "iPhone", "iPad" and "iPod" as distinct values for the name of the current browser. TiddlyWiki converts all three distinct values into "iOS" before copying to [[$:/info/browser/name]]. From bcf89d533d9b8bbefbda1fa6256aaf96ff361f51 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 16:35:33 +0100 Subject: [PATCH 12/15] Docs update --- editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid b/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid index 44a4a5f76..c329f2adf 100644 --- a/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid +++ b/editions/tw5.com/tiddlers/mechanisms/PluginMechanism.tid @@ -32,6 +32,7 @@ Plugins are stored as tiddlers with the following fields: |type |Must be ''application/json'' | |plugin-type |Can be ''plugin'' (default) or ''theme'' | |text |JSON encoding of the list of tiddlers comprising the plugin | +|list |Names of exposed plugin information tiddlers (see below) | |dependents |List of dependent plugins (currently only implemented for themes) | ! Plugin folders @@ -50,7 +51,8 @@ The JSON structure for plugin tiddlers is as follows: "version": "1.2.3-alpha3", "core-version": ">=5.0.0", "source": "http://tiddlywiki.com/MyPlugin", - "plugin-type": "plugin" + "plugin-type": "plugin", + "list": "readme license history" } ``` @@ -85,7 +87,7 @@ The wiki object keeps track of all of the currently loaded plugins. If a request In the browser, any constituent tiddlers that are JavaScript modules (ie shadow tiddlers of content type `application/javascript` and possessing the field `module-type`) are executed during startup processing. -! Standard Tiddlers for Plugins +! Information Tiddlers for Plugins Plugin authors are encouraged to provide special information and documentation tiddlers that TiddlyWiki can include as plugin information tabs in the [[control panel|$:/ControlPanel]]. From 76914c40455c04300ead873ed84be129cb1ed637 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 16:35:48 +0100 Subject: [PATCH 13/15] Minor icon tweaks --- core/icon.tid | 2 +- core/images/plugin-generic-plugin.tid | 2 +- core/images/plugin-generic-theme.tid | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/core/icon.tid b/core/icon.tid index 933275a2c..70187c55f 100644 --- a/core/icon.tid +++ b/core/icon.tid @@ -3,6 +3,6 @@ tags: $:/tags/Image - + \ No newline at end of file diff --git a/core/images/plugin-generic-plugin.tid b/core/images/plugin-generic-plugin.tid index eb24b4e0b..6f56da7a3 100644 --- a/core/images/plugin-generic-plugin.tid +++ b/core/images/plugin-generic-plugin.tid @@ -3,6 +3,6 @@ tags: $:/tags/Image - + \ No newline at end of file diff --git a/core/images/plugin-generic-theme.tid b/core/images/plugin-generic-theme.tid index 3785aa1b1..bfc667c79 100644 --- a/core/images/plugin-generic-theme.tid +++ b/core/images/plugin-generic-theme.tid @@ -3,6 +3,6 @@ tags: $:/tags/Image - + \ No newline at end of file From 5e06ef871adbc624cc80a8cc314864d4ddd8ff80 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 16:48:40 +0100 Subject: [PATCH 14/15] Docs update --- editions/tw5.com/tiddlers/Contributing.tid | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/editions/tw5.com/tiddlers/Contributing.tid b/editions/tw5.com/tiddlers/Contributing.tid index b18b625ce..5f41e1d6d 100644 --- a/editions/tw5.com/tiddlers/Contributing.tid +++ b/editions/tw5.com/tiddlers/Contributing.tid @@ -33,4 +33,4 @@ eg: `Jeremy Ruston, @Jermolene, 2011/11/22` !!!! Attribution -The CLA documents used for this project were created using [[Harmony Project Templates|http://www.harmonyagreements.org]]. "~HA-CLA-I-LIST Version 1.0" for "CLA-individual" and "~HA-CLA-E-LIST Version 1.0" for "CLA-entity" +The CLA documents used for this project were created using [[Harmony Project Templates|http://www.harmonyagreements.org]]. "HA-CLA-I-LIST Version 1.0" for "CLA-individual" and "HA-CLA-E-LIST Version 1.0" for "CLA-entity" From 2ff20926156c15713621237b43357b693130a122 Mon Sep 17 00:00:00 2001 From: Jermolene Date: Fri, 8 Aug 2014 17:19:48 +0100 Subject: [PATCH 15/15] More improvements to control panel plugin formatting --- core/modules/widgets/link.js | 8 +++++++- core/ui/ControlPanel/Plugins.tid | 12 ++++-------- themes/tiddlywiki/vanilla/base.tid | 12 ++++++------ 3 files changed, 17 insertions(+), 15 deletions(-) diff --git a/core/modules/widgets/link.js b/core/modules/widgets/link.js index 111896219..b5cd89fd8 100755 --- a/core/modules/widgets/link.js +++ b/core/modules/widgets/link.js @@ -56,7 +56,11 @@ LinkWidget.prototype.renderLink = function(parent,nextSibling) { // Create our element var domNode = this.document.createElement("a"); // Assign classes - var classes = ["tw-tiddlylink"]; + var classes = []; + if(this.linkClasses) { + classes.push(this.linkClasses); + } + classes.push("tw-tiddlylink"); if(this.isShadow) { classes.push("tw-tiddlylink-shadow"); } @@ -182,6 +186,8 @@ LinkWidget.prototype.execute = function() { // Get the link title and aria label this.tooltip = this.getAttribute("tooltip"); this["aria-label"] = this.getAttribute("aria-label"); + // Get the link classes + this.linkClasses = this.getAttribute("class"); // Determine the link characteristics this.isMissing = !this.wiki.tiddlerExists(this.to); this.isShadow = this.wiki.isShadowTiddler(this.to); diff --git a/core/ui/ControlPanel/Plugins.tid b/core/ui/ControlPanel/Plugins.tid index cc3755620..654c34502 100644 --- a/core/ui/ControlPanel/Plugins.tid +++ b/core/ui/ControlPanel/Plugins.tid @@ -16,8 +16,8 @@ $(currentTiddler)$/icon <$set name="qualified-state" value=<>> <$list filter="[!has[draft.of]plugin-type[$type$]sort[description]]"> <$set name="popup-state" value=<>> -
-
+<$link to={{!!title}} class="tw-plugin-info"> +
<$reveal type="nomatch" state=<> text="yes"> <$button class="btn-invisible btn-dropdown" set=<> setTo="yes"> {{$:/core/images/right-arrow}} @@ -29,14 +29,12 @@ $(currentTiddler)$/icon
-<$link to={{!!title}} class="tw-plugin-info-link"> -
-
+
<$transclude tiddler=<> subtiddler=<>> <$transclude tiddler="$:/core/images/plugin-generic-$type$"/>
-
+
''<$view field="description"><$view field="title"/>''
@@ -47,7 +45,6 @@ $(currentTiddler)$/icon <$view field="version"/>
-
<$reveal type="match" text="yes" state=<>> <$reveal type="nomatch" text="" state="!!list"> @@ -61,7 +58,6 @@ No information provided
-
diff --git a/themes/tiddlywiki/vanilla/base.tid b/themes/tiddlywiki/vanilla/base.tid index bc3ee4f00..69c190736 100644 --- a/themes/tiddlywiki/vanilla/base.tid +++ b/themes/tiddlywiki/vanilla/base.tid @@ -1239,20 +1239,20 @@ canvas.tw-edit-bitmapeditor { } .tw-plugin-info { + display: block; border: 1px solid <>; margin: 1em 0 1em 0; padding: 8px; } +.tw-plugin-info-chunk { + display: inline-block; + vertical-align: middle; +} + .tw-plugin-info img, .tw-plugin-info svg { width: 3em; height: 3em; -} - -.tw-plugin-info .tw-plugin-info-dropdown-button, -.tw-plugin-info .tw-tiddlylink { - display: inline-block; - vertical-align: middle; } /*