My biggest concern is that when the user moves beyond the root level… we’re setting root to display:none. Therefore, I have questions about whether or not the submit button is actually going to submit the root with the given branch.
Are you just concerned, or are you actually having this problem? It should submit just fine. For example
<form action=? method=post> <fieldset style="display: none"><input name=displaynone value=hello></fieldset> <fieldset><input name=displaynormal value=hello></fieldset> <input type=submit value=submit> </form>
I see both inputs when I submit the form.