Account created on 20 June 2019, almost 6 years ago
#

Merge Requests

Recent comments

🇮🇳India sumit_saini

Facing a similar issue described in #13. Patch suggested in #11 fixes the issue for us.

🇮🇳India sumit_saini

Added changes as per #17. Also, fixed flag name mismatch in files.
For #19, I have tested and confirm that it is possible to override this container parameter in services.local.yml with these changes.

🇮🇳India sumit_saini

Patch in #120 is missing a use statement for Node class.
Updated patch in #120 to fix it. (created for 10.2.x)

🇮🇳India sumit_saini

On this link https://ckeditor.com/docs/ckeditor5/latest/examples/builds/classic-edito..., table properties plugin and source edit pluign is not available. So let me try to explain/reproduce this on https://ckeditor.com/docs/ckeditor5/41.1.0/examples/builds-custom/full-f....
There, I created 3 one cell tables with left(L), center(C) and right(R) alignment respectively as shown below

The html will render as below when viewed(generated html and its view can be checked here - https://jsfiddle.net/Lsepjmut ).
See that L and R tables are rendered as expected but the table C is left aligned instead of center aligned.

Because ckeditor5 only handled its look inside editor and did not account for the browser behaviour, this is a problem for
- pages rendered with drupal theme(easy fix is to attach extra css fix to handle it with theme)
- API responses for headless implementation (not possible to add a css fix for this case by drupal)
One solution to fix for both above cases, is to implement a text processor(filter) to add the necessary style properties but this sounds like a overhead already.

In the meantime, we can use the workaround suggested in #3 but this is not good UX for a non-technical contributor. So, it is better if this is fixed upstream by ckeditor5 (which unfortunately has been disagreed here https://github.com/ckeditor/ckeditor5/issues/15535#issuecomment-1864029206 ).

🇮🇳India sumit_saini

This issue seems to address same problem as #3089105: When cloneReferencedEntities is called it should dispatch events (other issue patch also includes tests). Maybe we can close the other one (copying changes and credits from there) as this targets 2.x branch.

🇮🇳India sumit_saini

Zip in #118 don't get unzipped in desired folder structure due to a composer issue, so here is the complete zip.
I needed fixes from both issues mentioned in #115, so here is a zip of build file including both fixes.
As suggested in comments already, require "drupal-library/ckeditor5-anchor-drupal" after adding below snippet in composer's repositories section:

       {
            "type": "package",
            "package": {
                "name": "drupal-library/ckeditor5-anchor-drupal",
                "version": "0.0.0",
                "type": "drupal-library",
                "dist": {
                    "url": "https://www.drupal.org/files/issues/2023-10-25/ckeditor5-anchor-drupal.zip",
                    "type": "zip"
                }
            }
        }
🇮🇳India sumit_saini

I needed fixes from both issues mentioned in #115, so here is a zip of build file including both fixes.
As suggested in comments already, require "drupal-library/ckeditor5-anchor-drupal" after adding below snippet in composer's repositories section:

       {
            "type": "package",
            "package": {
                "name": "drupal-library/ckeditor5-anchor-drupal",
                "version": "0.0.0",
                "type": "drupal-library",
                "dist": {
                    "url": "https://www.drupal.org/files/issues/2023-10-25/ckeditor5-anchor-drupal.zip",
                    "type": "zip"
                }
            }
        }

🇮🇳India sumit_saini

@Abyss This issue was still present after applying the fix from 🐛 E-mail addresses are automatically picked up as anchor links Needs review . So, I feel that we will need a different fix for this one.

🇮🇳India sumit_saini

Further debugging took me to src/Plugin/GraphQL/DataProducer/Route::resolve() where language option is not added to $url object just after determining the correct language. The language is being set in access check condition (after comparing the passed path $value with the generated path $target_url which is causing this issue) which seemed out of place. Moving it before generating $target_url seems to work correctly.

--- a/src/Plugin/GraphQL/DataProducer/Route.php
+++ b/src/Plugin/GraphQL/DataProducer/Route.php
@@ -247,7 +247,9 @@ class Route extends DataProducerPluginBase implements ContainerFactoryPluginInte
           }
         }

-        // Check URL access.
+        $negotiatedLanguage = $this->languageManager->getLanguage($negotiatedLangcode);
+        $url->setOption('language', $negotiatedLanguage);
+        $field->setContextValue('language', $negotiatedLangcode);
         $target_url = $url->toString(TRUE)->getGeneratedUrl();

         // if language detection is domain based, remove domain from $target_url
@@ -272,10 +274,8 @@ class Route extends DataProducerPluginBase implements ContainerFactoryPluginInte
         $access = $url->access(NULL, TRUE);
         $field->addCacheableDependency($access);

+        // Check URL access.
         if ($access->isAllowed()) {
-          $negotiatedLanguage = $this->languageManager->getLanguage($negotiatedLangcode);
-          $url->setOption('language', $negotiatedLanguage);
-          $field->setContextValue('language', $negotiatedLangcode);
           return $url;
         }
         else {

After above fix, EntityUrl and EntityCanonicalUrl are returning correct language data.

🇮🇳India sumit_saini

As maintenance mode is stored in state, it is good to log message in Drupal\Core\State::set() method. So, moving the fix given in #21 to State.php. This way, there will be a log for both cases - drush and form save. Verified the attached patch with Drupal 10.1.4

🇮🇳India sumit_saini

Used patch in #98 with 3.0.x-dev and requiring the library as suggested in #88.
- Anchor jump to end of paragraph (#71) is fixed
- Link change to Anchor automatically (#94) is fixed.
- Email linking do not work (#103)

🇮🇳India sumit_saini

Backported patch for Generic Revision UI in D9.5.9 including below fixes
- disallow revert link for current revision from #4
- 🐛 Generic Revision UI's Revision overview page generates wrong operations/view links for a translation Fixed
- Workaround fix for 🐛 Revision UI reverts all language translations when only one language is reverted Active

🇮🇳India sumit_saini

🐛 Revision UI reverts all language translations when only one language is reverted Active should be fixed before switching to new revision UI to maintain existing behavior for reverting revisions of node translations.

🇮🇳India sumit_saini

This issue no longer occurs in latest version as the related issue is fixed in 🐛 Compatibility with the newly stable paragraphs widget Fixed . The fix is available since 2.1.0-alpha1 release.

🇮🇳India sumit_saini

Backported patch for Generic Revision UI in D9.5.9 including below fixes
- disallow revert link for current revision from #4
- 🐛 Generic Revision UI's Revision overview page generates wrong operations/view links for a translation Fixed

🇮🇳India sumit_saini

The issue is still present for grouped filters on D9.5.9. So, here is a reroll of the patch in #36.

🇮🇳India sumit_saini

With this patch/fix, the hooks are firing for the cloned referenced entities also. Using this fix on a site without any issue so, changing status to RTBC.

🇮🇳India sumit_saini

Patch in #8 fixes the issue.

🇮🇳India sumit_saini

reroll of patch from #2350939-317: Implement a generic revision UI + disallow revert link for current revision

 +++ b/core/lib/Drupal/Core/Entity/Controller/VersionHistoryController.php
-@@ -0,0 +1,335 @@
+@@ -0,0 +1,340 @@
 +<?php
 +
 +namespace Drupal\Core\Entity\Controller;
@@ -275,6 +292,11 @@ index 0000000000..fd5d00f2e4
 +      return NULL;
 +    }
 +
++    // Disallow reverting to the default revision.
++    if ($revision->isDefaultRevision()) {
++      return NULL;
++    }
++
 +    return [
 +      'title' => $this->t('Revert'),
 +      'url' => $url,
🇮🇳India sumit_saini

Patch in #314 did not apply to D9.5.2 for the same reason. So, here is a reroll for someone using D9.5.2.

🇮🇳India sumit_saini

Generic Revision UI has been implemented in Implement a generic revision UI Fixed within core which has made possible to implement Revision UI for ECK revision support. Refer #2788507-116: Add revision support for the patch.

🇮🇳India sumit_saini

As Implement a generic revision UI Fixed is merged in D10.1 and patch for D9.5 is available, I have updated patch in #109 to use core's generic revision UI by following this change record .

Below modifications are done in this patch(Refer interdiff) :
1. The patch no longer needs entity module and so the related update hook to install entity module is removed.
2. Modified Drupal\eck\EckEntityAccessControlHandler::checkAccess() for revision permission handling [need to improve permission checking logic].
3. Removed 'Revisions' local task added by earlier patch which is now added by core.
4. Revision routes related implementation removed from Drupal\eck\Entity\EckEntityRouteProvider which is now supplied by Drupal\Core\Entity\Routing\RevisionHtmlRouteProvider (promoted revision routes as _admin_route in Drupal\eck\EventSubscriber\EckEntityAdminRouteSubscriber )
5. Added 'revision-delete-form' link to eck entity definition.

Note: This patch is generated against eck v8.x-1.0-beta2 and tested with D9.5.3

Production build 0.71.5 2024