1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-04-08 19:56:39 +00:00

Stripy backgrounds for lists

This commit is contained in:
Jeremy Ruston 2025-04-03 21:22:33 +01:00
parent 3cb6712ccb
commit 1972e8b5f3
2 changed files with 27 additions and 13 deletions

View File

@ -10,18 +10,20 @@ tags: $:/tags/Macro
<span class="tc-pill"><$text text={{{ [<jsonList>jsonindexes[]count[]] }}}/></span>
</div>
<div class="tc-box-content">
<$list filter="[<jsonList>jsonindexes[]limit[10]]" variable="indexList">
<$list-template>
<div class="tc-box-content-list-item">
<$text text={{{ [<jsonList>jsonget<indexList>] }}} />
</div>
</$list-template>
<$list-empty>
<div class="tc-box-content-list-empty">
(No items)
</div>
</$list-empty>
</$list>
<div class="tc-box-content-list">
<$list filter="[<jsonList>jsonindexes[]]" variable="indexList">
<$list-template>
<div class="tc-box-content-list-item">
<$text text={{{ [<jsonList>jsonget<indexList>] }}} />
</div>
</$list-template>
<$list-empty>
<div class="tc-box-content-list-empty">
(No items)
</div>
</$list-empty>
</$list>
</div>
</div>
</div>
\end inspect-list

View File

@ -3519,8 +3519,20 @@ span.tc-translink > a:first-child {
background-color: var(--box-background-color);
}
.tc-box-content-list-item {
.tc-box-content-list {
margin: -0.25em;
max-height: 25vh;
overflow: scroll;
}
.tc-box-content-list-item {
font-size: 0.7em;
line-height: 1.1;
padding: 0.25em;
}
.tc-box-content-list-item:nth-child(even) {
background: rgb(255, 255, 255, 0.5);
}
.tc-box-content-list-empty {