Hiding the first column of a wiki table

61 views
Skip to first unread message

whatever

unread,
Jun 21, 2012, 9:43:53 AM6/21/12
to TiddlyWiki
Hi!

Is it possible to use some kind of CSS class to hide the first column
of a wiki table?
I have tables like this:
|1||||
|2||||
|3||||
|4||||
I'd like to hide the first column.
I know this is possible with the first-child pseudoclass for normal
HTML tables (and in some other ways), but I'm not sure how to apply it
here.

w

Jon

unread,
Jun 22, 2012, 12:30:58 AM6/22/12
to tiddl...@googlegroups.com
Is it possible to use some kind of CSS class to hide the first column
of a wiki table?

Sure. Give the table a class, then use the first-child pseudoclass in your StyleSheet tiddler:

|myTable|k
|1|xxx|
|2|yyy|
...

.myTable td:first-child { display:none; }

--Jon

whatever

unread,
Jun 22, 2012, 3:23:31 AM6/22/12
to TiddlyWiki
Thanks, Jon! It works nicely. I was trying something similar, bit I
didn't get it quite right. Also, I realized that in my use case, I
need to put the class row at the end, not at the beginning.

w
Reply all
Reply to author
Forward
0 new messages