Hi Mat, I've been wishing for something like this - thanks! However, I think it doesn't work with your Tablinks. It only worked for me when I reverted to the shadow version of $:/core/macros/tabs. With the Tablinks version of $:/core/macros/tabs, if I create the whateveryourwant tiddler in your example and inspect the elements, it looks as though the second tab has become nth-child(3) and the third and fourth tabs aren't nth-children at all. But I don't even know if that's the real problem. Sorry to only be able to report things rather than offer solutions. I'm really hoping there's a way to get both colors and links on tabs! Thanks, cmari
On Saturday, January 21, 2017 at 4:30:33 PM UTC-8, Mat wrote: > > On Saturday, January 21, 2017 at 7:29:38 PM UTC+1, Odder wrote: >> >> I have a tebmenu with 6 tabs and I want each tab with a different >> background-color? Is this possible maybe with css? >> Odder >> > > Yes, unless I misunderstand you. > > title:whateveryouwant > tags:colortabs > > <<tabs "one two three four" "one">> > > <style> > .tc-tagged-colortabs .tc-tab-buttons button:nth-child(1) {background:blue > ;} > .tc-tagged-colortabs .tc-tab-buttons button:nth-child(2) {background:green > ;} > .tc-tagged-colortabs .tc-tab-buttons button:nth-child(3) {background: > yellow;} > .tc-tagged-colortabs .tc-tab-buttons button:nth-child(4) {background:red;} > </style> > > The reason you need the tag "colortabs" is to prevent the styling from > affecting all tabs in the TW. Instead you can then use .tc-tagged-colortabs > to limitit it to that particular tiddler. > > Generally, you'd not want to put the styles in the tiddler itself but in a > separate stylesheet tiddler, i.e any tiddler with the tag > "$:/tags/Stylesheet". And you omit the <style> tags there, just put the > lines starting with .tc-tagged..... etc > > <:-) > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywiki@googlegroups.com. Visit this group at https://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/113c26a5-afee-4fe3-9954-9461ee3d0046%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.