- 🇧🇬Bulgaria ovanes Sofia
Hello adding adjusted patch for core 9.5.x
- 🇨🇦Canada b_sharpe
There's some issues here with focus with:
if (this.focus) { target = document.querySelector(this.focus); } else {
Seeing the following error in the console:
An error occurred during the execution of the Ajax response: SyntaxError: Document.querySelector: 'function focus() { [native code] }' is not a valid selector
because in the context here, "this" is actually the Window object, so focus is a function.
- 🇲🇦Morocco m.bkm
I have applied patch #64 to my Drupal 9.5.3 and I’m having the same issue and getting the same error message. Anyone have any ideas on how to fix this ?
An error occurred during the execution of the Ajax response: SyntaxError: Failed to execute ‘querySelector’ on ‘Document’: ‘function focus() { [native code] }’ is not a valid selector.
- 🇱🇻Latvia martins.bertins Rēzekne
Adjusted patch for 10.1.x from #63.
Found that progress was not being set correctly and there was a .orig file included. - last update
12 months ago 29,723 pass - 🇺🇸United States tregonia
Found out today that the patches do not apply against 10.2. I have been debugging and the apply failure is isolated to the form loop in ajax.js; or the logic that handles the focus.
I have removed that section, and resolved the apply failure. I cannot speak to whether any further changes are necessary for other concerns. Please review.
- last update
11 months ago Patch Failed to Apply - last update
11 months ago Patch Failed to Apply - 🇺🇸United States tregonia
Updated the diff because it was not applying.
- last update
11 months ago 25,790 pass, 1,823 fail - last update
11 months ago Build Successful - 🇪🇸Spain akalam
The wrapper ajax setting is not being considered when replacing the content. That can causes issues when the wrapper is set to something different than the content region. Here is a patch fixing it. Basically if the wrapper exist on the content inside the ajax response, we reduce the content to just the "wrapper" element. If the wrapper element is not found, we keep the content as it is, replacing the wrapper with the content from the ajax response.
- 🇪🇸Spain akalam
Patch 73 was introducing a regression: In the context of an Ajax call, there are situations when the wrapper id is in the response, but we don't want to replace just the partial but the whole response. This is the case of the media library after adding a new media, because the div containing the media add form, has the same id as the form with the file upload at the top of the media list.
As consequence, with the patch applied, when you add a new media through the media library, the dialog gets replaced with just the file upload form, so the auto-insert feature doesn't work (because the media list doesn't get replaced).As a solution, I'm proposing the replacement of partial response to be an opt-in (disabled by default). This setting can be activated through a data attribute (data-replace-partial="true") on specific links, so it can be used keeping the default behavior untouched.