Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions core/images/default-layout.tid
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
title: $:/core/images/default-layout
tags: $:/tags/Image

\parameters (size:"22pt")
<svg width=<<size>> height=<<size>> class="tc-image-default-layout tc-image-button" viewBox="0 0 128 128">
<path d="M71.93 72A8.07 8.07 0 0 1 80 80.07v7.86A8.071 8.071 0 0 1 71.93 96H8.07A8.067 8.067 0 0 1 0 87.93v-7.86A8.072 8.072 0 0 1 8.07 72h63.86Zm0 32a8.07 8.07 0 0 1 8.07 8.07v7.86a8.071 8.071 0 0 1-8.07 8.07H8.07A8.067 8.067 0 0 1 0 119.93v-7.86A8.072 8.072 0 0 1 8.07 104h63.86Zm0-104A8.068 8.068 0 0 1 80 8.07v47.86A8.073 8.073 0 0 1 71.93 64H8.07A8.07 8.07 0 0 1 0 55.93V8.07A8.072 8.072 0 0 1 8.07 0h63.86Zm48 0c2.14 0 4.193.85 5.706 2.364A8.067 8.067 0 0 1 128 8.07v111.86c0 2.14-.85 4.193-2.364 5.706A8.067 8.067 0 0 1 119.93 128H96.07c-2.14 0-4.193-.85-5.706-2.364A8.067 8.067 0 0 1 88 119.93V8.07c0-2.14.85-4.193 2.364-5.706A8.067 8.067 0 0 1 96.07 0h23.86ZM116 24h-16a3.995 3.995 0 0 0-2.828 1.172 3.995 3.995 0 0 0 0 5.656A3.995 3.995 0 0 0 100 32h16a3.995 3.995 0 0 0 2.828-1.172 3.995 3.995 0 0 0 0-5.656A3.995 3.995 0 0 0 116 24Z"/>
</svg>
2 changes: 1 addition & 1 deletion core/ui/LayoutSwitcher.tid
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ caption: {{$:/language/ControlPanel/LayoutSwitcher/Caption}}
\whitespace trim
<$linkcatcher to="$:/layout">
<div class="tc-chooser">
<$list filter="[all[tiddlers+shadows]tag[$:/tags/Layout]] [[$:/core/ui/PageTemplate]] +[!is[draft]sort[name]]">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reason that we manually include $:/core/ui/PageTemplate is so that the default page template is shown in the chooser even if the user is using a customised $:/core/ui/PageTemplate that dates from before the introduction of switchable layouts, and hence lacks the tag $:/tags/Layout.

Was the intention just to clean things up, or was the current arrangement causing problems for you?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is reasonable, added back!

I was trying to save a bit of calculation...

<$list filter="[all[tiddlers+shadows]tag[$:/tags/Layout]] +[!is[draft]sort[name]]">
<$list
filter="[{$:/layout}!has[text]]"
variable="ignore"
Expand Down
3 changes: 2 additions & 1 deletion core/ui/PageTemplate.tid
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
title: $:/core/ui/PageTemplate
tags: $:/tags/Layout
Copy link
Contributor Author

@linonetwo linonetwo Mar 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to keep this, so it shows in 3rd party launchers.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @linonetwo rethinking the tag on $:/tags/ui/PageTemplate is really a separate topic, and should go into its own PR with some documentation updates.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, let's discuss this later. If add this tag, may need additional list on $:/tags/Layout tiddler to keep $:/core/ui/PageTemplate on top.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @linonetwo

name: {{$:/language/PageTemplate/Name}}
description: {{$:/language/PageTemplate/Description}}
icon: $:/core/images/layout-button
icon: $:/core/images/default-layout
code-body: yes

\whitespace trim
Expand Down