Tablehelper - Show and tell

This isn’t a real plugin yet, just a first draft of something I built myself for a specific common need. I like to use wikitext tables for things I don’t want clogging up extra tiddlers, but occasionally I have the need to modify the tables after the fact like manually entering, deleting, or re-arranging columns.

So I hacked together a pure wikitext “macro” where you feed it a wikitext table (warning: I’ve only tested it using very basic wikitext features as it’s really only for myself right now), and it adds 12 little buttons when you hover on the table. I’m sure there are other, and better things already out there, but it was a fun scripting exercise for me.

I posted this in a fairly unpolished state with the title of “show and tell” because while I love the more polished plugins, when I was learning, I found those harder to learn from, so I’m hoping that a fellow learner out there gets ideas from this more than anything. So a big dose of “at your own risk” is advised!

Anyways, if you want to check it out, I’ve attached a file that you can drag/drop onto TiddlyWiki.com and a little recorded .gif of me quickly going through the motions.

tablehelper.json (21.8 KB)

tablehelper

5 Likes

Cool, but is it possible to edit cell content and save it back to currentTiddler?

1 Like

I believe the answer is yes, but maybe I misunderstand your question - have you tried it? Essentially the buttons take the text in the macro, use filters to modify it, and then write it all back to the originating tiddler.

1 Like

@stobot Adam, this is quite impressive. It will certainly make using the Wiki text tables a lot easier.

  • This tempts me to use this form of table more often because its easier to change critical display parameters, I tend to use html table tags, especially when introducing filters (inner list widgets).

Once a table is built placing providing access to the column sort buttons ONLY would help people viewing the table to review it in different orders.

As I understand it not in the view mode, you can change order and even add columns, but to edit the cells you will need to edit the tiddler containing the table and find the cell you want to edit, is that correct @stobot ?

Ah, correct. It’s not a a view mode WYSIWYG editor for editing table content. I did intend to expand my bullets plugin for tables which is that way, and it uses similar techniques. Maybe one day I’ll merge them.

1 Like

Thanks for the answer @stobot, the question was more as an answer to @dyp1121054136 but good to hear it from you.

Oh, and I must say welcome to the forums @dyp1121054136 perhaps you could give a real name to your account even a nick name?

  • Don’t hesitate to ask any question, in its own thread, even silly questions are OK. We all have to start somewhere.

I’m coming rather late to this thread, but this is an amazing tool—well done! I hardly ever use wikitext tables because editing them is such a chore, and this may finally change that.

Should you ever have the time and inclination, I think this would be an incredibly valuable addition!

(And here’s a link to @stobot’s equally elegant Bullets plugin for anyone else who may have missed it originally. :wink: )