Reputation: 1
I’m creating a configurable diagram using the custom link feature in Diagrams.net. When I crest a button to show cells with a certain tag and hide cells with a different tag, it hides all cells. What am I doing wrong here?
Upvotes: 0
Views: 1107
Reputation: 86
Without knowing more, I can't be exactly sure what you're doing wrong, but I can show you what does work and some gotcha's around it.
I'm assuming you've labeled your tags correctly,
If you're using the Create Custom Link tool, be sure to validate the link. You can build Actions for Show/Hide, but it's not the best way (anymore).
Update Every time I use this tool either there's something new or at least I didn't notice before.
At the bottom, the last option is Add Tags: Hidden: Visible:
This is the way to go! It works great for Tables! The show/hide method doesn't work well with individual table cells.
This will build a custom link like this:
data:action/json,{
"actions": [
{
"tags": {
"hidden": [
"rectangular"
],
"visible": [
"round"
]
}
}
]
}
Just flip the tags around to do the opposite. This sounds like what you want.
At least, as long as you spell things the same as you did in your tags, it works fine. (I misspelled 'rectangular' and couldn't figure out why it didn't show/hide my rectangles.)
Upvotes: 2