List type attribute in wiki text

109 views
Skip to first unread message

passingby

unread,
Jul 18, 2019, 12:30:03 PM7/18/19
to TiddlyWiki
Is there a way to define the 'type' attribute of the list in wiki text. In my notes these days, I frequently type="a" lists.

Mark S.

unread,
Jul 18, 2019, 6:08:15 PM7/18/19
to TiddlyWiki
You could make a stylesheet tiddler like

div[data-tags~=Lists] ul li {list-style-type:  lower-alpha }

This assumes you have your tiddler tagged "Lists", but of course you might use some other tag. You would want to use some
sort of tag because otherwise *everything* that is in a list will use lower-alpha.

passingby

unread,
Jul 18, 2019, 8:25:51 PM7/18/19
to TiddlyWiki
Thanks Mark. But my lists are varied and some are multi level. 

Mark S.

unread,
Jul 18, 2019, 8:28:24 PM7/18/19
to TiddlyWiki
You can assign different styles for different levels, though I'm not sure you get as many choices as with just the tags.

If you explain what you want in more detail, there are some people here who are really good with CSS.

passingby

unread,
Jul 18, 2019, 8:48:42 PM7/18/19
to tiddl...@googlegroups.com
I am making some notes from some legal text. I am taking notes in easy and concise everyday english. I try to follow the numbering, but I am not too strict about. Usually the pattern is restricted to 2 level, with numbers outside and small case alphabets inside. But sometimes there are deeper levels as is shown in a screenshot I have attached with this post.

I have attached a screenshot. Please have a look. Thanks.
Snip01.jpg

Mark S.

unread,
Jul 19, 2019, 12:38:44 AM7/19/19
to TiddlyWiki
This CSS matches up with your sample text, if I understand it correctly. It goes to 3 levels. You can work out other levels if necessary.

<style>
div[data-tags~=Lists] > div >  ul > li {list-style-type:  lower-alpha }
div[data-tags~=Lists] > div >  ul > li > ul > li {list-style-type:  lower-roman }
div[data-tags~=Lists] > div >  ul > li > ul > li > ul > li {list-style-type:  upper-alpha }
</style>

passingby

unread,
Jul 19, 2019, 5:29:59 PM7/19/19
to TiddlyWiki
Thanks Mark! I am going to try this on my next note-taking tiddler.

passingby

unread,
Jul 19, 2019, 9:12:01 PM7/19/19
to tiddl...@googlegroups.com
Hello again Mark,
I just used it and its working perfectly! Thanks again. I even removed the data-tag attribute and made it general, because in this particular tiddlywiki all my lists would be like this. In some special case, I can perhaps enclose it is a span with a class and do it different.
I should have asked this earlier. Its a impressive how just a small thing can make such a big difference. 
Thanks!

Mat

unread,
Jul 21, 2019, 4:04:16 PM7/21/19
to TiddlyWiki
Mark, that is brilliant! I would guess that little tweak alone could be a major part in a "legal documents TW edition".

<:-)

Mark S.

unread,
Jul 21, 2019, 9:47:08 PM7/21/19
to TiddlyWiki
Thanks Mat!

I'll definitely take that as a compliment, coming from someone I consider a TW guru.
Reply all
Reply to author
Forward
0 new messages