Tag Browse Tree : node filter

Hi

I'm editing the tag browse tree components right now.

I want to bring only "value" of the tag, but all unnecessary properties(Deadband, Tooltip, ReadOnly etc) are displayed. Please tell me how I can hide these elements.

I can't find a way to change what the tag browse tree displays, but... We can hide things with css.

Whip out the style sheet, and try something like this:

.terminal-node:has(.tree-item:not([data-label="value"])) {
	display: none;
}

image

This leaves behind a rather bad-looking branch thing. I'm trying to handle this gracefully, but...
The last item has a last-child css class, which makes the branchy thing different.
image

But I can't find this class anywhere :X
I tried grep -lri last-child on ignition's data folder and nothing came up.

edit:
You could remove the whole thing instead, I guess ?

.terminal-node .terminal-alignment:has(+ .tree-item[data-label="value"]) {
	visibility: hidden;
}
1 Like

thank you! fragnoud.

It can't be helped that the branch is annoying.

Thank you for answer.

Try the second css snippet to remove the branch and see if it looks better like this.
If it messes other things up, let me know, I'll try to fix it.

hi,

the code just works, but if you add alarms on the tag, it wont hide alarms properties.

any ideas?

thanks

Alarms still show because they're in a parent-node and not in a terminal-node.
Target those too and your alarms will disappear.

Change it to

.parent-node:has(.tree-item:not([data-label="value"])) {
	display: none;
}

still doesnt work

.parent-node:has(.tree-item:([data-label="Alarms"])) {
	display: none;
}

does not work... i have tried few combination to target those alarms, but still no luck

slight oversight and a syntax error, sorry. This should work:

.parent-node>.tree-row:has(.tree-item[data-label="Alarms"]) {display: none; }

I'll also suggest to add a specific class to the selector, that you'll apply to your tag browse tree. Otherwise, it will apply to ALL tag browse trees, which might not be the intended effect.
Even if it's the only one you have, because when some time from now you or someone else want to add a second one and the alarms don't show up, it might take a while to figure out why.

1 Like

yes, thats right, i just realize that power chart with browse tags, lost all the tags because of the css apply to all browse tree.

btw, how to add specific class?

.psc-your_class_name .parent-node>.tree-row:has(.tree-item[data-label="Alarms"]) {display: none; }

then add your_class_name to the classes of the component.

1 Like

thanks, it works and its only applied to the specific class..