Locations context menu no longer working after Gin Admin Toolbar RC1

Created on 22 February 2023, over 1 year ago
Updated 18 January 2024, 10 months ago

Problem/Motivation

When accessing the Entitree admin page to browse the locations, you can't expand the menu for each location. This prevents adding or editing the locations. This only started happening after updating the Gin Admin Toolbar to RC1 (from beta 22).

Not sure why this is happening now (there's nothing obvious in the Gin Toolbar source).

Steps to reproduce

Nothing special, just navigate to the Entitree Locations browser and click the downward arrow on Entitree Site Root.

Proposed resolution

It looks like this is a problem with the entitree.js file's Drupal.behaviors implementation. Limiting the context seems to help so maybe this needs to use once() or something similar.

When inspecting the DOM and adding some logs to the JS, it looks like the click events are just running too many times.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States inversed

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024