Pretify the Export as HTML

  • I normally open the collection of tiddler in story river
  • Manually sort them through Open Tab
  • Then open $:/AdvancedSearch and select filter:“Tiddlers in StoryRiver excluding $:/AdvancedSearch”
  • Finaly select Export as “Static Html”

My question is:

  1. How can I make the output centered?
    The current export makes tiddlers to occupy the whole width. this makes output on wide screen (very common these days) ugly
  2. I do not like to overwrite shadow tiddlers
  3. I like to simple be able to export min(50%, 800px) or better 80 character line length (see Readability: The Optimal Line Length – Baymard)

Its possible to find and alter the static template or start by creating another exporter. You can follow the trail and work it out or start with SystemTag: $:/tags/Exporter
or https://tiddlywiki.com/#Creating%20a%20custom%20export%20format

A quick look on my part before I go to bed $:/core/templates/exporters/StaticRiver
this is possibly the export format and it uses $:/core/templates/html-tiddler to render each tiddler.

I think you may be able to set or indicate a width in $:/core/templates/exporters/StaticRiver as this crafts the html file in which the tiddlers are displayed, or one of the templates included.

You can add a stylesheet tiddler (including tag $:/tags/Stylesheet) with this content:

section.tc-story-river.tc-static-story-river {
    width: min(50%, 800px);
    margin: auto;
}

or add that to any existing stylesheet.

1 Like