🇪🇸Spain @javier_rey

Account created on 5 February 2019, almost 6 years ago
#

Recent comments

🇪🇸Spain javier_rey

The code works like a charm :)

🇪🇸Spain javier_rey

I agree. I had an old Drupal 10 project and when I re-launched the migrations with “item_selector: /” I found that they didn't work. Using “item_selector: 0” they work perfectly again.

🇪🇸Spain javier_rey

Maybe I'm doing something wrong. If I try setting the “Icon Class Name” field, the icon on the map does not show the class I have saved.

I have tested this on “https://simplytest.me/”, with Leaflet version 10.2.25.

🇪🇸Spain javier_rey

I think that the patch #44 has a bug. If you set a field with “Number of items to display = 0”, when you reach to the second "if”, the condition will be FALSE and will not hide unwanted fields.

if ($items_to_display = (int) $block_configuration['items_to_display']) {

      // If this is a multi-value block configured to not display all values,
      // remove those field items from the render array.
      $block_configuration = $block->getConfiguration();
      if (!$is_content_empty && isset($block_configuration['display_items']) && $block_configuration['display_items'] == 'display_some') {
        if ($items_to_display = (int) $block_configuration['items_to_display']) {
          $offset = (int) $block_configuration['offset'];
          $range = range(0, $content[0]['#items']->count());
          foreach ($range as $key) {
            $top_range = $offset + $items_to_display - 1;
            if ($key < $offset || $key > $top_range) {
              $content[0][$key]['#access'] = FALSE;
            }
          }
        }
      }
🇪🇸Spain javier_rey

After implementing this change, when installing a fresh install in a language other than English and using the “standard” installation profile, for example”, I get the following error:

the configuration objects have different language codes so they cannot be translated
🇪🇸Spain javier_rey

Without patch number 27, I get the warning mentioned in the issue.
But when applying it I don't get any "value" in the method "public function alterView(ViewExecutable $view, $value)" of my "
ViewsReferenceSetting custom setting.

My version is 2.0-beta7.

🇪🇸Spain javier_rey

I've been testing, and seems like this issue solves the problem: Library order asset weights do not work properly when a large number of javascript files is loaded between two jQuery UI libraries 🐛 Library order asset weights do not work properly when a large number of javascript files is loaded between two jQuery UI libraries Fixed

🇪🇸Spain javier_rey

This happens to me too and I don't see exactly what the problem is. As administrator it doesn't happen to me, but with a user with less permissions, it fails.

🇪🇸Spain javier_rey

Hi! I think there is a bug in the patch, as it is defined, in line 163, the variable "$render_array" is overwritten, losing the title of the view.

if ($plugin_types) {
        // Add a custom template if the title is available.
        $title = $view->getTitle();
        if (!empty($title)) {
          // If the title contains tokens, we need to render the view to
          // populate the rowTokens.
          if (strpos($title, '{{') !== FALSE) {
            $view->render();
            $title = $view->getTitle();
          }
          $render_array['title'] = [
            '#theme' => 'viewsreference__view_title',
            '#title' => $title,
          ];
        }
      }
      $render_array = $view->buildRenderable($display_id, $view->args, FALSE);

Also, when we return an empty array and we have the "Internal Page Cache" module enabled, the page cache is not being refreshed.

  1. Create a view block that lists basic pages with the "tag based" option.
  2. Insert the block as a field inside another type of content, such as a landing page.
  3. Open the landing page as anonymous and as a registered user.
  4. Create a basic page and reload the landing page as anonymous and as a registered user.

I've added a patch which imo fixes these two cases. I am not an expert, so if there are any problems any help is welcome.

🇪🇸Spain javier_rey

Adding a patch for the 10.1.x branch.

Production build 0.71.5 2024