omeka / omeka-s

Omeka S is a web publication system for universities, galleries, libraries, archives, and museums. It consists of a local network of independently curated exhibits sharing a collaboratively built pool of items, media, and their metadata.
GNU General Public License v3.0
401 stars 134 forks source link

Make jstree node patterns consistent with other sortable values #2141

Open kimisgold opened 8 months ago

kimisgold commented 8 months ago

Right now, jstree nodes break from the sortable value pattern in two ways: they do not have a means of providing "restore value" strings, and they do not hide other actions when marked for removal.

jimsafley commented 8 months ago

I've pushed the "jstree-improvements" branch, which is where we can collaborate on this. So far I've added the title and aria-label attributes to the icons, and I've toggled the visibility of the icons when a link is removed and restored.

One problem I'm facing is the interaction of remove/restore on child links. When I remove a link, all of its icons and the icons of its child links are hidden. This is expected and desirable. But when I collapse and expand one of these links, the icons reappear, and I'm not sure why. It could be some jsTree nonsense, but it could also be something to do with CSS. Would you take a look to see if the CSS controls this behavior?

kimisgold commented 8 months ago

I'm seeing that it's inline styles controlling the action icon visibility, so I think it's JS controlling the behavior.

image
jimsafley commented 8 months ago

It's the visibility of the .jstree-themeicon, .jstree-displaylink and .jstree-editlink-edit icons specifically that are the problem here. They are being hidden by JS, but they are being made visible by some unknown means.