- Issue created by @jurgenhaas
- 🇪🇸Spain fjgarlin
Thanks for reporting that. It's weird, the event is linked to "change" https://git.drupalcode.org/project/contribution_records/-/blob/1.0.x/js/...
But yeah, it's clearly not working.
- 🇪🇸Spain fjgarlin
Core triggers a jQuery change event (https://git.drupalcode.org/project/drupal/-/blob/11.x/core/misc/tablesel...), which does not translate into a native change event: https://stackoverflow.com/questions/21290775/jquery-el-triggerchange-doe...
- 🇪🇸Spain fjgarlin
https://stackoverflow.com/questions/40915156/listen-for-jquery-event-wit...
The short answer is that this is impossible as jQuery provides an event layer over vanilla JS. That means that vanilla JS cannot talk to that added layer. So in summary, jQuery can catch vanilla JS events, but vanilla JS cannot catch jQuery added events.
- 🇪🇸Spain fjgarlin
Created 🐛 Native change event listeners don't work when triggered from jQuery Active in core.
-
fjgarlin →
committed 880291e5 on 1.0.x
#3540621: use jQuery for tableselect.
-
fjgarlin →
committed 880291e5 on 1.0.x
- 🇪🇸Spain fjgarlin
The immediate fix for us is to use jQuery (which we normally avoid, so as not to have more dependencies).
The commit above fixes the issue. It will be deployed today.
- 🇺🇸United States drumm NY, US
I also considered removing the “Credit all” checkbox entirely. We don’t have it in the old UI, and I’m not sure we want maintainers to be crediting everyone too often, it could give low-quality contributions more chances of receiving more credit than deserved. However, the current form structure has some scaffolding that’s helped by the API and “credit all” comes with it for free.