From 229159fea7e25ffae5037c1fdda1dcc8d934aec8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?T=C3=A9lumire?= <31185220+Telumire@users.noreply.github.com> Date: Mon, 5 Dec 2022 00:29:36 +0100 Subject: [PATCH 1/6] Correction of zindex for tc-card-ribbon-wrapper (new ribbon) (#7088) --- editions/tw5.com/tiddlers/system/tw5.com-styles.tid | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/editions/tw5.com/tiddlers/system/tw5.com-styles.tid b/editions/tw5.com/tiddlers/system/tw5.com-styles.tid index d4ce76a8e..b446b363b 100644 --- a/editions/tw5.com/tiddlers/system/tw5.com-styles.tid +++ b/editions/tw5.com/tiddlers/system/tw5.com-styles.tid @@ -192,7 +192,7 @@ type: text/vnd.tiddlywiki right: 0; overflow: hidden; top: 0; - z-index: 999; + z-index: 849; pointer-events: none; } From 10bb3ba09d258b22d7d854dda9637436261741fa Mon Sep 17 00:00:00 2001 From: Mario Pietsch Date: Mon, 5 Dec 2022 23:04:52 +0100 Subject: [PATCH 2/6] German Translation Update (#7093) --- languages/de-DE/Buttons.multids | 6 +++++- languages/de-DE/Help/commands.tid | 14 ++++++++++++++ languages/de-DE/Misc.multids | 1 + 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 languages/de-DE/Help/commands.tid diff --git a/languages/de-DE/Buttons.multids b/languages/de-DE/Buttons.multids index 15094f23a..4615d41c0 100644 --- a/languages/de-DE/Buttons.multids +++ b/languages/de-DE/Buttons.multids @@ -17,7 +17,9 @@ ControlPanel/Hint: Öffne das Control-Panel CopyToClipboard/Caption: Kopiere in die Zwischenablage CopyToClipboard/Hint: Kopiere diesen Text in die Zwischenablage Delete/Caption: Löschen -Delete/Hint: Lösche diesen Tiddler +Delete/Hint: Lösche den Tiddler +DeleteTiddlers/Caption: Lösche Tiddler +DeleteTiddlers/Hint: Lösche diese Tiddler Edit/Caption: Bearbeiten Edit/Hint: Bearbeite diesen Tiddler Encryption/Caption: Verschlüsselung @@ -57,6 +59,8 @@ Home/Caption: Home Home/Hint: Öffnen der Standard-Tiddler Language/Caption: Sprache Language/Hint: Auswahldialog für die Systemsprache +LayoutSwitcher/Hint: Öffne den Layout Selektor +LayoutSwitcher/Caption: Layout Manager/Caption: Tiddler Manager Manager/Hint: Öffne den Tiddler Manager More/Caption: mehr diff --git a/languages/de-DE/Help/commands.tid b/languages/de-DE/Help/commands.tid new file mode 100644 index 000000000..b7de1b86f --- /dev/null +++ b/languages/de-DE/Help/commands.tid @@ -0,0 +1,14 @@ +title: $:/language/Help/commands +description: Ausführen von Befehlen aus einem Tiddler + +Sequentielle Abarbeitung von Befehlen aus einem Tiddler. + +``` +--commands +``` + +Beispiele + +`--commands "[enlist{$:/build-commands-as-text}]"` + +`--commands "[{$:/build-commands-as-json}jsonindexes[]] :map[{$:/build-commands-as-json}jsonget]"` \ No newline at end of file diff --git a/languages/de-DE/Misc.multids b/languages/de-DE/Misc.multids index 32c8b9d13..da5b15411 100644 --- a/languages/de-DE/Misc.multids +++ b/languages/de-DE/Misc.multids @@ -8,6 +8,7 @@ CloseAll/Button: alle schließen ColourPicker/Recent: Kürzlich: ConfirmCancelTiddler: Wollen Sie die Änderungen im Tiddler: "<$text text=<>/>" verwerfen? ConfirmDeleteTiddler: Wollen Sie den Tiddler: "<$text text=<<title>>/>" löschen? +ConfirmDeleteTiddlers: Wollen Sie <<resultCount>> Tiddler löschen? ConfirmOverwriteTiddler: Tiddler: "<$text text=<<title>>/>" existiert! OK überschreibt den tiddler! ConfirmEditShadowTiddler: Sie sind dabei, einen Schatten-Tiddler zu verändern. Zukünftige, automatische Anpassungen werden dadurch unterdrückt. Sie können Ihre Änderungen rückgängig machen, indem Sie diesen Tiddler wieder löschen. Wollen Sie den Tiddler: "<$text text=<<title>>/>" ändern? ConfirmAction: Möchten Sie weitermachen? From 80442b7f7f4a7779570cfc707419ab62273ed65d Mon Sep 17 00:00:00 2001 From: FlashSystems <developer@flashsystems.de> Date: Mon, 5 Dec 2022 23:05:20 +0100 Subject: [PATCH 3/6] Fix for bug #7054 (#7092) * Fix Bug #7054: Reuse of $:/core/ui/EditTemplate/fields broken This fixes Bug #7054 by creating a new variable `safeNewFieldValueTiddlerPrefix` that is always set to a valid, temporary prefix. This variable is used within `$action-deletetiddler`. If the passed `newFieldValueTiddlerPrefix` variable is empty a new prefix will be generated by the same logic that creates the original `newFieldValueTiddlerPrefix` variable. To be even more defensive, the prefix-filter was prepended with another prefix filter that limits matches to `$:/temp/NewFieldValue`. This prevents a bogus but non empty value in `newFieldValueTiddlerPrefix` to delete arbitrary tiddlers. * Add a default for `newFieldValueTiddlerPrefix` This fixes a problem that was identified while fixing bug #7054. If the tiddler `$:/core/ui/EditTemplate/fields` is transcluded directly and `newFieldValueTiddlerPrefix` is not set, it will be generated. This makes sure that this value is defined. It can not be redefined unconditionally because if this tiddler is transcluded from `EditTemplate.tid` these two tiddlers must agree on the same prefix because the clean-up is duplicated between `EditTemplate.tid` and `fields.tid`. This would make `safeNewFieldValueTiddlerPrefix` obsolete, but I leave it in there to make the macros safe and prevent any problems if the `newFieldValueTiddlerPrefix` is unset by a later change. --- core/ui/EditTemplate.tid | 7 ++++++- core/ui/EditTemplate/fields.tid | 14 ++++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/core/ui/EditTemplate.tid b/core/ui/EditTemplate.tid index b63a02ee2..4d6dec5d6 100644 --- a/core/ui/EditTemplate.tid +++ b/core/ui/EditTemplate.tid @@ -1,7 +1,12 @@ title: $:/core/ui/EditTemplate -\define delete-edittemplate-state-tiddlers() <$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix<newFieldValueTiddlerPrefix>] [<newFieldNameInputTiddler>] [<newFieldNameSelectionTiddler>] [<newTagNameTiddler>] [<newTagNameInputTiddler>] [<newTagNameSelectionTiddler>] [<typeInputTiddler>] [<typeSelectionTiddler>]"/> +\define delete-edittemplate-state-tiddlers() +<$set name="safeNewFieldValueTiddlerPrefix" value=<<newFieldValueTiddlerPrefix>> emptyValue=<<qualify "$:/temp/NewFieldValue">> > + <$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix[$:/temp/NewFieldValue]prefix<safeNewFieldValueTiddlerPrefix>] [<newFieldNameInputTiddler>] [<newFieldNameSelectionTiddler>] [<newTagNameTiddler>] [<newTagNameInputTiddler>] [<newTagNameSelectionTiddler>] [<typeInputTiddler>] [<typeSelectionTiddler>]"/> +</$set> +\end +<!-- Beware this is duplicated from fields.tid. For details see bug #7054 --> \define get-field-value-tiddler-filter() [subfilter<get-field-editor-filter>sha256[16]addprefix[/]addprefix<newFieldValueTiddlerPrefix>] \define get-field-editor-filter() [<newFieldNameTiddler>get[text]else[]] :cascade[all[shadows+tiddlers]tag[$:/tags/FieldEditorFilter]!is[draft]get[text]] :and[!is[blank]else{$:/core/ui/EditTemplate/fieldEditor/default}] diff --git a/core/ui/EditTemplate/fields.tid b/core/ui/EditTemplate/fields.tid index 6173d9b76..6a767517b 100644 --- a/core/ui/EditTemplate/fields.tid +++ b/core/ui/EditTemplate/fields.tid @@ -10,6 +10,10 @@ $:/config/EditTemplateFields/Visibility/$(currentField)$ [[hide]] -[title{$(config-title)$}] \end +<!-- Beware this is duplicated from EditTemplate.tid. For details see bug #7054 --> +\define get-field-value-tiddler-filter() [subfilter<get-field-editor-filter>sha256[16]addprefix[/]addprefix<newFieldValueTiddlerPrefix>] +\define get-field-editor-filter() [<newFieldNameTiddler>get[text]else[]] :cascade[all[shadows+tiddlers]tag[$:/tags/FieldEditorFilter]!is[draft]get[text]] :and[!is[blank]else{$:/core/ui/EditTemplate/fieldEditor/default}] + \define current-tiddler-new-field-selector() [data-tiddler-title="$(currentTiddlerCSSescaped)$"] .tc-edit-field-add-name-wrapper input \end @@ -17,7 +21,9 @@ $:/config/EditTemplateFields/Visibility/$(currentField)$ \define new-field-actions() \whitespace trim <$action-sendmessage $message="tm-add-field" $name={{{ [<newFieldNameTiddler>get[text]] }}} $value={{{ [<newFieldNameTiddler>get[text]] :map[subfilter<get-field-value-tiddler-filter>get[text]] }}}/> -<$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix<newFieldValueTiddlerPrefix>] [<storeTitle>] [<searchListState>]"/> +<$set name="safeNewFieldValueTiddlerPrefix" value=<<newFieldValueTiddlerPrefix>> emptyValue=<<qualify "$:/temp/NewFieldValue">> > + <$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix[$:/temp/NewFieldValue]prefix<safeNewFieldValueTiddlerPrefix>] [<storeTitle>] [<searchListState>]"/> +</$set> <$action-sendmessage $message="tm-focus-selector" $param=<<current-tiddler-new-field-selector>>/> \end @@ -52,7 +58,9 @@ $:/config/EditTemplateFields/Visibility/$(currentField)$ <$action-sendmessage $message="tm-add-field" $name=<<name>> $value={{{ [subfilter<get-field-value-tiddler-filter>get[text]] }}}/> -<$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix<newFieldValueTiddlerPrefix>] [<storeTitle>] [<searchListState>]"/> +<$set name="safeNewFieldValueTiddlerPrefix" value=<<newFieldValueTiddlerPrefix>> emptyValue=<<qualify "$:/temp/NewFieldValue">> > + <$action-deletetiddler $filter="[<newFieldNameTiddler>] [prefix[$:/temp/NewFieldValue]prefix<safeNewFieldValueTiddlerPrefix>] [<storeTitle>] [<searchListState>]"/> +</$set> <<lingo Fields/Add/Button>> </$button> </$reveal> @@ -65,6 +73,7 @@ $value={{{ [subfilter<get-field-value-tiddler-filter>get[text]] }}}/> \end \whitespace trim +<$set name="newFieldValueTiddlerPrefix" value=<<newFieldValueTiddlerPrefix>> emptyValue=<<qualify "$:/temp/NewFieldValue">> > <div class="tc-edit-fields"> <table class={{{ [all[current]fields[]] :filter[lookup[$:/config/EditTemplateFields/Visibility/]!match[hide]] +[count[]!match[0]] +[then[tc-edit-fields]] ~[[tc-edit-fields tc-edit-fields-small]] }}}> <tbody> @@ -148,3 +157,4 @@ $value={{{ [subfilter<get-field-value-tiddler-filter>get[text]] }}}/> </$vars> </div> </$fieldmangler> +</$set> \ No newline at end of file From e77006de63e423c91cd98689530bc99c84a2f98b Mon Sep 17 00:00:00 2001 From: "jeremy@jermolene.com" <jeremy@jermolene.com> Date: Mon, 5 Dec 2022 22:44:35 +0000 Subject: [PATCH 4/6] Update links to Open Collective --- editions/tw.org/tiddlers/Fundraising.tid | 4 ++-- editions/tw5.com/tiddlers/about/Open Collective.tid | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/editions/tw.org/tiddlers/Fundraising.tid b/editions/tw.org/tiddlers/Fundraising.tid index 0ccc5736b..0c521caea 100644 --- a/editions/tw.org/tiddlers/Fundraising.tid +++ b/editions/tw.org/tiddlers/Fundraising.tid @@ -14,10 +14,10 @@ We do need a small amount of money on an ongoing basis to pay the costs of runni We use Open Collective to allow you to contribute towards these costs. You can contribute a one-off donation, or make an ongoing monthly commitment. Find out more: -https://opencollective.com/tiddlywikidotorg +https://opencollective.com/tiddlywiki !! Community Projects We also use Open Collective to raise funds to support the development of major new features, plugins or community infrastructure. These projects generally involve a small team of individuals getting together and making a proposal to the rest of the community. -For example, the [[File Upload Plugin Project|https://opencollective.com/tiddlywikidotorg/projects/tiddlywiki-file-upload]] aims to radically simplify working with attached images. +For example, the [[File Upload Plugin Project|https://opencollective.com/tiddlywiki/projects/tiddlywiki-file-upload]] aims to radically simplify working with attached images. diff --git a/editions/tw5.com/tiddlers/about/Open Collective.tid b/editions/tw5.com/tiddlers/about/Open Collective.tid index 8d096cdc8..1113535c3 100644 --- a/editions/tw5.com/tiddlers/about/Open Collective.tid +++ b/editions/tw5.com/tiddlers/about/Open Collective.tid @@ -5,10 +5,10 @@ tags: About HelloThere [[Open Collective]] Open Collective is a platform for transparent fundraising and expenses for projects like TiddlyWiki. It is the official TiddlyWiki community fundraising space. -https://opencollective.com/tiddlywikidotorg +https://opencollective.com/tiddlywiki You can make a fixed one-time donation, or setup a recurring contribution. The main goals listed for donations are to cover basic costs for community infrastructure like the Discourse forum, and a new goal for supporting the TiddlyWiki Core. -Additionally, the community can make use of the platform for special projects - to pool funds to pay for development, design, or anything else. The [[File Upload Plugin|https://opencollective.com/tiddlywikidotorg/projects/tiddlywiki-file-upload]] is the first of these, and we want to welcome others to launch projects here. +Additionally, the community can make use of the platform for special projects - to pool funds to pay for development, design, or anything else. The [[File Upload Plugin|https://opencollective.com/tiddlywiki/projects/tiddlywiki-file-upload]] is the first of these, and we want to welcome others to launch projects here. From 2db886793e095ef3040cae197936356b0f474ccd Mon Sep 17 00:00:00 2001 From: Mario Pietsch <pmariojo@gmail.com> Date: Tue, 6 Dec 2022 17:36:26 +0100 Subject: [PATCH 5/6] Fix table overflow for small screens (#7010) * fix table overflow for small screens * add PRE word-break for Chrome and Safari on mobile * remove comment, since it looks better for all browsers now * add 1 space to trigger the new automatic build * change small screen settings only for tiddler frame --- themes/tiddlywiki/vanilla/base.tid | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/themes/tiddlywiki/vanilla/base.tid b/themes/tiddlywiki/vanilla/base.tid index c323a6f19..d2fe757f6 100644 --- a/themes/tiddlywiki/vanilla/base.tid +++ b/themes/tiddlywiki/vanilla/base.tid @@ -30,6 +30,10 @@ background-size:` {{$:/themes/tiddlywiki/vanilla/settings/backgroundimagesize}}` <$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}] }}}/> \end +\define tiddler-width() + <$text text={{$:/themes/tiddlywiki/vanilla/metrics/tiddlerwidth}}/> +\end + \define if-fluid-fixed(text,hiddenSidebarText) <$reveal state="$:/themes/tiddlywiki/vanilla/options/sidebarlayout" type="match" text="fluid-fixed"> $text$ @@ -144,7 +148,7 @@ pre { display: block; margin-top: 1em; margin-bottom: 1em; - word-break: normal; + word-break: break-word; word-wrap: break-word; white-space: {{$:/themes/tiddlywiki/vanilla/options/codewrapping}}; background-color: <<colour pre-background>>; @@ -1173,6 +1177,28 @@ button.tc-btn-invisible.tc-remove-tag-button { } } + +/* prevent overflow for table content for small screens*/ +@media (max-width: <<sidebarbreakpoint>>) { + .tc-tiddler-frame tr { + word-wrap: anywhere; + } + + .tc-tiddler-frame table blockquote { + margin-left: 12.5px; + margin-right: 12.5px; + } + + .tc-tiddler-frame table dd { + margin-left: 12.5px; + } + + .tc-tiddler-frame table ol, + .tc-tiddler-frame table ul { + padding-left: 20px; + } +} + .tc-site-title, .tc-titlebar { font-weight: normal; From 28c1e6bfc3b4a842323ab6cc03c34c17a93e45e9 Mon Sep 17 00:00:00 2001 From: "jeremy@jermolene.com" <jeremy@jermolene.com> Date: Wed, 7 Dec 2022 09:43:39 +0000 Subject: [PATCH 6/6] Docs update for nested macro definitions Suggested by @kookma in https://github.com/FlashSystems/TiddlyWiki5/commit/bcb3b06d60a3b616083e9df36fc487cbbbf8abb7#commitcomment-91922651 and https://github.com/FlashSystems/TiddlyWiki5/commit/bcb3b06d60a3b616083e9df36fc487cbbbf8abb7#commitcomment-91922974 --- .../Macro Definitions in WikiText.tid | 41 +++++++++++-------- 1 file changed, 24 insertions(+), 17 deletions(-) diff --git a/editions/tw5.com/tiddlers/wikitext/Macro Definitions in WikiText.tid b/editions/tw5.com/tiddlers/wikitext/Macro Definitions in WikiText.tid index d5c7ce509..cae2b2009 100644 --- a/editions/tw5.com/tiddlers/wikitext/Macro Definitions in WikiText.tid +++ b/editions/tw5.com/tiddlers/wikitext/Macro Definitions in WikiText.tid @@ -1,6 +1,6 @@ caption: Macro Definitions created: 20150220181617000 -modified: 20221022135909352 +modified: 20221207094236472 tags: WikiText title: Macro Definitions in WikiText type: text/vnd.tiddlywiki @@ -19,22 +19,6 @@ Alternatively, the entire definition can be presented on a single line without a \define sayhi(name:"Bugs Bunny") Hi, I'm $name$. ``` -Macro definitions can be nested by specifying the name of the macro in the `\end` marker. For example: - -<<wikitext-example-without-html src:"""\define special-button(caption:"Click me") -\define actions() -<$action-sendmessage $message="tm-notify" $param="HelloThere"/> -\end actions -<$button actions=<<actions>>> -$caption$ -</$button> -\end special-button - -<<special-button>> -""">> - -A more formal [[presentation|Macro Definition Syntax]] of this syntax is also available. - !! Accessing variables and parameters Inside the macro there are several methods for accessing variables defined outside of the macro or parameters from the macro parameter list. @@ -93,3 +77,26 @@ To make a macro available to all tiddlers, define it in a tiddler that has the t It is also possible to write a macro as a [[JavaScript module|https://tiddlywiki.com/dev/index.html#JavaScript%20Macros]]. ~JavaScript macros are available to all tiddlers, and offer the maximum flexibility. A tiddler can manually import macro definitions from a [[selection|Title Selection]] of other tiddlers by using the <<.wlink ImportVariablesWidget>> widget. + +!! Nested Macro Definitions + +Macro definitions can be nested to any number of required levels by specifying the name of the macro in the `\end` marker. Nested macro definitions must appear at the start of the definition that contains them. For example: + +<<wikitext-example-without-html src:"""\define special-button(caption:"Click me") +\define actions() +<$action-sendmessage $message="tm-notify" $param="HelloThere"/> +\end actions +<$button actions=<<actions>>> +$caption$ +</$button> +\end special-button + +<<special-button>> +""">> + +Note that the textual substitution of macro parameters that occurs when the outer macro is rendered will apply to the nested definitions as well. That generally means that textual substitution of macro parameters should not be used within nested macros. + +Parameters of nested macros can also be accessed via the `<<__variablename__>>` syntax. As ordinary variables, these parameters are available within nested child macros (and grandchildren etc). + +A more formal [[presentation|Macro Definition Syntax]] of this syntax is also available. +