1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-09-21 11:49:44 +00:00
TiddlyWiki5/editions/tw5.com/tiddlers/wikitext/Utility Classes.tid
Mario Pietsch e1b3308a9d
Fix float right overflow (#8557)
* tc-subtitle is not a sibling to tc-body,
So tc-subtitle needs a clearfix to contains float:right

* add clearfix to all tiddler elements that could contain floats

* add clearfix to tc-tiddler-title in ViewTemplate

* add clearfix to plugin/blog/templates

* add clearfix to plugin/tour/templates

* remove test tiddler

* rename draft title class to tc-tiddler-title-draft

* undo title field covering

* move tc-clearfix to tc-float-right in the base CSS file

* rename clearfix CSS class to tc-clearfix

* update documentation tiddlers
2024-09-09 09:48:57 +01:00

21 lines
1.4 KiB
Plaintext

created: 20220818093624828
modified: 20221010074235929
tags: WikiText
title: Utility Classes
type: text/vnd.tiddlywiki
<<.from-version "5.2.4">> The following outlines a few predefined CSS classes intended to make it simpler to style [[HTML block-elements|HTML Block Elements]] and [[wikitext tables|Tables in WikiText CSS Utility Classes]].
!! General Utility Classes
|`tc-center` |Centres a block-element to the middle of the container |
|`tc-max-width `|Expands a block-element to use the maximum width of the container |
|`tc-max-width-80`|Sets the width of a block-element to use 80% of the maximum container width. This setting is useful with the `tc-center` class |
|`tc-edit-max-width `|Expands [[TextWidget]]s to use the maximum available width. See [[ControlPanel -> Info -> Basics|$:/core/ui/ControlPanel/Basics]]|
|`tc-first-link-nowrap` |Ensures that any links in the first table column will never wrap to the next line |
|`tc-clearfix`|<<.from-version "5.3.6">> This class can be used to prevent elements, that have a `class="tc-float-right"` from overflowing their container elements. tc-clearfix is already assigned to all major ViewTemplate and EditTemplate elements. So it only needs to be used where the default does not work out of the box.|
!! Table Utility Classes
|`tc-table-no-border` |Removes the borders of a table |
|`tc-first-col-min-width` |The first column of a table will take up minimal possible width. It adapts to the content |