Very rough implementation but it does the job. The following hides master tag on "tag2" page but keeps the nested tags visible; and it hides the nested tags and keeps the main one visible everywhere else.
// 1. hide child tags everywhere except of these --tagX pages
.IndexPage:not(.IndexPage--tag2) .TagsLabel .TagLabel--child {
display: none;
}
// 2. match rounded corners on main tag after removal
.IndexPage:not(.IndexPage--tag2) .TagsLabel .TagLabel:nth-child(1) {
border-top-right-radius:4px;
border-bottom-right-radius:4px;
}
// 3. hide main tag specifically on --tagX page
.IndexPage.IndexPage--tag2 .TagsLabel .TagLabel:not(.TagLabel--child) {
display: none;
}
// 4. match rounded corners on child after removal
.IndexPage.IndexPage--tag2 .TagsLabel .TagLabel:nth-child(2) {
border-top-left-radius:4px;
border-bottom-left-radius:4px;
}
On the actual topic itself:
On All Discussions:
This is the nested structure: