hierarchy-select
hierarchy-select copied to clipboard
Remove selected value
How to remove selected value from hierarchy
You can add your own id attribute to the <a> element:
<a id="item-33" class="dropdown-item" data-value="4" data-level="3" href="#">White</a>
And use javascript:
const element = document.getElementById('item-33');
element.hidden = true; // to hide element
element.remove(); // or removed it
Also you can find it via querySelectorAll":
document.querySelectorAll('[data-value]')[3].hidden = true
Why do we need some additional internal functionality to remove elements? Or do you mean the need to delete the entire branch of the hierarchy?