Account created on 11 March 2009, about 16 years ago
  • Senior Developer at Phase2 
#

Merge Requests

More

Recent comments

🇺🇸United States recrit

I created the MR 5 with the new hook. Attached is a static patch that can be used for composer builds. Any further development should be done in the issue branch.

🇺🇸United States recrit

For Drupal 10.4.x+ support along with jQuery UI updated to 1.14.1 in the jquery_ui module, test the MR 20 on 📌 Update to jQuery UI 1.14.0 Active , see comment #15 📌 Update to jQuery UI 1.14.0 Active for details. The MR 20 📌 Update to jQuery UI 1.14.0 Active includes the changes from 📌 Update to jQuery UI 1.14.0 Active and this issue 🐛 Remove duplicate modules in JavaScript bundles Active .

🇺🇸United States recrit

@flyke and @nelo_drup please test the MR 20 see comment #15 📌 Update to jQuery UI 1.14.0 Active for details.

🇺🇸United States recrit

I opened a new MR 20 that is MR 19 with the changes from 🐛 Remove duplicate modules in JavaScript bundles Active . The result is that jquery_ui is updated to 1.14.1 similar to Drupal core after 10.4.x and gives jquery_ui full control over the files with the changes from 🐛 Remove duplicate modules in JavaScript bundles Active .

Attached is a static patch of MR 20 for any composer builds.

🇺🇸United States recrit

recrit changed the visibility of the branch 3420890-remove-duplicates--after-3483054-jqueryui-1.14.1 to hidden.

🇺🇸United States recrit

@flyke - with still having errors, then you are most likely running into 🐛 Remove duplicate modules in JavaScript bundles Active where some of the core files are still loaded. The patch in 3420890 gives the jquery_ui module full control over all the JS files.

I am working on updating the patch to work with the updates in this issue for 1.14.1 since Drupal 10.4.x includes that version too.

🇺🇸United States recrit

@v.dovhaliuk - you may want to try the fix on 🐛 Re-order + remove broken with the Entity Reference (and File) widget Needs review instead since it has some cardinality fixes as well.

🇺🇸United States recrit

Attached is a static patch of the latest MR that can be used for composer builds.

🇺🇸United States recrit

Attached is a static patch of the latest MR that can be used for composer builds.

🇺🇸United States recrit

MR 22 created with the latest 1.0.x-dev and using Drupal's FileExist enums. I also added some error catching since the file move operation can throw a few errors, most notably when the file does not exist which commonly occurs when using the stage_file_proxy module.

🇺🇸United States recrit

recrit made their first commit to this issue’s fork.

🇺🇸United States recrit

attached is a static patch for any composer builds

🇺🇸United States recrit

created MR with a cleaner unset based on the array key instead of the loop variable.
attached is a static patch that can be used for composer builds.

🇺🇸United States recrit

Attached is a static patch of the MR that applies to tmgmt 8.x-1.17

🇺🇸United States recrit

@fskreuz your original MR was ignoring the already created list of fields $embedded_fields = ContentEntitySource::getEmbeddableFields($entity); which is already patched for computed fields in this issue's changes.

🇺🇸United States recrit

@nelo_drup This patch does not affect jQuery UI libraries, for example jquery_ui_accordion/accordion. It only replaces JavaScript files in the Drupal Core libraries with the equivalent files in the jQuery UI module's assets directory.
For that reason, it would not be causing the issues that you are seeing with jquery_ui_accordion/accordion.

I would suggest doing some debugging:

  • Are there any JavaScript errors on the page in the developer console? Use the browser's developer tools to inspect the page.
  • Check the Drupal watchdog logs for any errors
  • Verify that "jquery_ui_accordion" is installed
  • Do you have any custom code - JavaScript or Drupal - that could be interfering with it
  • If you have access to Drush on the site, then post the output of the following commands in order to see the library definitions:
    • drush ev "echo print_r(\Drupal::service('library.discovery')->getLibraryByName('jquery_ui_accordion', 'accordion'), TRUE);"
    • drush ev "echo print_r(\Drupal::service('library.discovery')->getLibraryByName('faqfield', 'faqfield.accordion'), TRUE);"
🇺🇸United States recrit

@nelo_drup The faqfield module does have the correct dependency for jquery_ui_accordion/accordion. The change in this ticket should not affect that dependency.

What are the errors that you are seeing?

What version of faqfield are you using?

🇺🇸United States recrit

The patch and MR need updated to address the issue described in #7 🐛 modal dialog close button doesn't reset buttons that trigger modal Needs work

Regarding the comment in #9 🐛 modal dialog close button doesn't reset buttons that trigger modal Needs work : You can have more than one dialog open at a time. If have nested entities using the entity browser to edit or select the reference fields on them.

🇺🇸United States recrit

marking as needs review. the MR tests are failing for unrelated PHP unit tests.

🇺🇸United States recrit

This is not a duplicate of 🐛 modal dialog close button doesn't reset buttons that trigger modal Needs work . This is issue is specific to the "Replace" option.

🇺🇸United States recrit

I recently ran into this issue. When Drupal.detachBehaviors() is called with an empty context, it will numerous issues. Any JS implementing a detach will remove everything that it did in attach. For example, any autcomplete UX added by core/misc/autocomplete.js.

I created the MR with the 1 line fix.
The attached static patch can be used for composer builds and applies to both 11.x and 10.3.x+.

🇺🇸United States recrit

recrit made their first commit to this issue’s fork.

🇺🇸United States recrit

MR 39: Updates the existing bynder_metadata to output a single metadata attribute from the JSON field value.

Pending automated tests.

🇺🇸United States recrit

Created MR 38 that adds the loading attribute support.

🇺🇸United States recrit

let's try adding that 10.3.x patch again

🇺🇸United States recrit

MR passed. Attached is an equivalent 10.3.x for any builds still using that.

🇺🇸United States recrit

@peterwcm thank you. Using the node language worked for me and is a lot cleaner. I will update the PR.

🇺🇸United States recrit

@drunken monkey - MR looks good to me and works as expected. There is conflict with src/Utility/AutocompleteHelper.php but other than that looks good. Thanks!

🇺🇸United States recrit

@drunken monkey - I am using the better_exposed_filters . It appears that it builds the element with its element info process callbacks before any form alter would be called, for example "search_api_autocomplete_form_views_exposed_form_alter".

MR Updates:
I have added tests to simulate the better_exposed_filters exposed form plugin.
I manually ran the "test-only" tests on the MR and it failed as expected for "There should not be duplicate element #process callbacks."

better_exposed_filters: 6.0.6 or 7.0.2: \Drupal\better_exposed_filters\Plugin\views\exposed_form\BetterExposedFilters::exposedFormAlter().

    // Ensure default process/pre_render callbacks are included when a BEF
    // widget has added their own.
    foreach (Element::children($form) as $key) {
      $element = &$form[$key];
      $this->addDefaultElementInfo($element);
    }

Drupal: 10.3.10
better_exposed_filters: 6.0.6
"#process" IN:

['Drupal\Core\Render\Element\Textfield',' processAutocomplete']
['Drupal\Core\Render\Element\Textfield',' processAjaxForm']
['Drupal\Core\Render\Element\Textfield',' processPattern']
['Drupal\Core\Render\Element\Textfield',' processGroup']

WITH BUG:
"#process" OUT:

['Drupal\Core\Render\Element\Textfield',' processAutocomplete']
['Drupal\Core\Render\Element\Textfield',' processAjaxForm']
['Drupal\Core\Render\Element\Textfield',' processPattern']
['Drupal\Core\Render\Element\Textfield',' processGroup']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processSearchApiAutocomplete']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processAutocomplete']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processAjaxForm']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processPattern']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processGroup']

WITH THE FIX IN THIS ISSUE:

['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processSearchApiAutocomplete']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processAutocomplete']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processAjaxForm']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processPattern']
['Drupal\search_api_autocomplete\Element\SearchApiAutocomplete',' processGroup']
🇺🇸United States recrit

Pushed some fixes for better error handling. This is now working for me when Vimeo does not have a high resolution option.
Thinking about this more, I feel like it could be better handled in \Drupal\media\Plugin\media\Source\OEmbed::getLocalThumbnailUri() so that the high resolution image is only requested once and then the local file is created. Currently, the fixes in this issue would causes the high resolution images to be request every time the resource cache is rebuilt. This seems a bit excessive to me.

🇺🇸United States recrit

There are a few issues with the patch in #19:

  1. In the new method doVimeoRequest, the TransferException is not defined and needs to be imported.
  2. the import "use GuzzleHttp\Client" is never used.
  3. The fallback for Youtube should be uncommented:
          catch (RequestException $e) {
            // Use default thumbnail.
            //$data['thumbnail_url'] = str_replace('maxresdefault', 'hqdefault', $data['thumbnail_url']);
          }
    
🇺🇸United States recrit

The MR build is failing for phpstan errors unrelated to the 1 line change in the MR.
Error from phpstan:

 ------ ------------------------------------------------------------------------------------------------------ 
  Line   src/Controller/NodeRevisionController.php                                                             
 ------ ------------------------------------------------------------------------------------------------------ 
         Ignored error pattern #^Method                                                                        
         Drupal\\Core\\Form\\FormBuilderInterface\:\:getForm\(\) invoked with                                  
         2 parameters, 1 required\.$# in path                                                                  
         /builds/issue/diff-3488283/web/modules/custom/diff-3488283/src/Controller/NodeRevisionController.php  
         was not matched in reported errors.                                                                   
 ------ ------------------------------------------------------------------------------------------------------
🇺🇸United States recrit

MR is ready for review. Attached is a static patch for composer builds.

🇺🇸United States recrit

code cleanup complete.
Attached is a static patch of the MR to use for composer builds.

🇺🇸United States recrit

Use the MR 109 for the latest changes applied to 1.8+. Attached is a static patch of the MR to use for composer builds.

🇺🇸United States recrit

attached is a backport patch for 6.0.x for anyone that has not updated to 7.0.x yet.

🇺🇸United States recrit

MR 105 created with the following:
- Maintains the same intended solution as the original - find the element with "data-bef-auto-submit-delay" and attach listeners to it.
- Finds the correct parent with "[data-bef-auto-submit-full-form]" even when there are intermediate elements in between "[data-bef-auto-submit]" and "[data-bef-auto-submit-full-form]".
- Changed the "$form" variable to "$needsAutoSubmit" since not all elements found with the selectors are forms.

🇺🇸United States recrit

MR 38 created from the patch #37 Add option to not upscale images that are too small to fit target scale Needs review . The patch 37 can be used for any composer builds and applies to the latest 2.x.

🇺🇸United States recrit

the attached patch adds the following:
- AJAX controller updates only from 🐛 Facets with AJAX not working in most of situations Needs work to properly set the session on the new request. The other changes in 3052574 conflict with this patch since it is trying to fix the JS and change how the blocks are rendered in the AJAX controller.

- AJAX controller updates from 🐛 New $request created in FacetBlockAjaxController missing ajax_page_state RTBC to persist the "ajax_page_state".

🇺🇸United States recrit

static patch for safe composer builds.

🇺🇸United States recrit

@joseph.olstad using the automatically generate patch is dangerous since it is actively updated. A static patch is preferred to avoid any issues with new code pushed to the MR

🇺🇸United States recrit

The change can cause JS errors for $form is null when there is no delay found on the element or parent. This can happen when the front end theme has an extra element in between the `.views-exposed-form` top level DIV and the child FORM element.

-        let $form = $(e);
+        const $delay = $(e).data('bef-auto-submit-delay') ? $(e) : $(e).parent().data('bef-auto-submit-delay');
+        const $form= $delay ? $(e).parent() : null;

when there is no delay set, the $form is null here causing errors.
🇺🇸United States recrit

I created MR 145 with the paragraphs-3315835-2.patch.

🇺🇸United States recrit

@camhoward thanks for the summary of how to use 2.x. The site that I am working on does not use Google Analytics, just GTM. It seems that this can only be accomplished with the 1.x version of the module at this point.

🇺🇸United States recrit

Proposed Solution:
Update "drupal-rector/src/Drupal10/Rector/Deprecation/AnnotationToAttributeRector.php" with the following to detect single argument plugins with a missing key.
The patch attached for palantirnet/drupal-rector applies the following update:

    /**
     * @param array|ArrayItemNode[] $parsedArgs
     *
     * @return Attribute
     */
    private function createAttribute(string $attributeClass, array $parsedArgs): Attribute
    {
        $fullyQualified = new FullyQualified($attributeClass);
        // Support attributes with a single value constructor.
        // For example: '@ViewsField("my_custom_views_field")'.
        if (count($parsedArgs) === 1 && empty($parsedArgs[0]->key)) {
          $parsedArgs[0]->key = 'id';
        }

        $args = [];
       ...
🇺🇸United States recrit

it appears that composer just ignores any patched changes to the composer so you may still need the following to be able to remove the "drupal/variationcache" dependency:

    "replace": {
      "drupal/variationcache": "*"
    },
🇺🇸United States recrit

ignore 3421610-9-do-not-test.patch, i left a comman in the composer.json.
the attached patch also removes the dependency from composer.json. This patch is for 8.x-1.6 with the package info.

🇺🇸United States recrit

the attached patch also removes the dependency from composer.json. This patch is for 8.x-1.6 with the package info.

🇺🇸United States recrit

@msnassar The Undefined variable $resource_url should be fixed in the latest MR.
I created an MR against 11.x with error message updated to the following. I removed the "|" from the message since system logs often are delimited with "|" which could cause issue with parsing the log.

      $this->logger->error(
       'An error occurred while fetching an oEmbed resource for Media ID: %media_id, Embed URL: %media_url, oEmbed Resource URL: %resource_url. Error: @error',
        [
          '%resource_url' => !empty($resource_url) ? $resource_url : 'unknown',
          '%media_url' => $media_url,
          '%media_id' => $media->id(),
          '@error' => $e->getMessage(),
        ]
      );

Attached is a static patch of the MR for composer builds. Please contrib to the MR for any further development.

🇺🇸United States recrit

recrit changed the visibility of the branch 3202896-dont-display-oembed to hidden.

🇺🇸United States recrit

Cleaner patch for 10.3.x with no tests

🇺🇸United States recrit

Attached is static patch of the MR 7350 for 11.x and a patch adapted for 10.3.x

🇺🇸United States recrit

In general, dev work should be done on the MR 5385 for the latest 11.x branch since this incorporates all the discussion thus far in this issue. Once approved, the changes would be back ported to any older branches.

🇺🇸United States recrit

Attached are static patches that can be used for composer builds.

  • Patch for 11.x only: drupal-11.x-MR-5385--20240827-1.patch
  • Patch for 10.3.x, 11.x: drupal-11.x-10.3.x-MR-5385--without-phpstan-changes--20240827-1.patch - This is the MR 5385 for 11.x without the phpstan changes so that it can be applied to 10.3.x also.
🇺🇸United States recrit

MR 3 created to rename the config file.
Attached is a static patch of the MR for composer builds.

🇺🇸United States recrit

The MR diff cannot be applied to a stable tag (i.e. 8.x-1.12) due to the changes in tests/modules/entity_composite_relationship_test/entity_composite_relationship_test.info.yml. The attached patch does not include any tests changes so that it can be used in a composer build.

🇺🇸United States recrit

MR 233 created. Attached is a static patch for composer builds.

🇺🇸United States recrit

Adding static patch with the PHP 8.3 fix.

🇺🇸United States recrit

Closing as I just realized the get_class code is added in the patch in https://www.drupal.org/project/access_unpublished/issues/3335950 Move Access Tokens UI to an entity Local Task / Tab Needs work

🇺🇸United States recrit

Adding static patch the MR9 for composer builds.

🇺🇸United States recrit

@joevagyok it has been a minute since I created this patch, but I thought changing the class to "error" when it was enforced handled the "hard limit" OR am I missing something?

        if ($this.hasClass('maxlength_js_enforce')) {
          options['enforce'] = true;
          options.cssExceeded = 'error';
        }
Production build 0.71.5 2024