- Issue created by @sean_fremouw
- Assigned to justcaldwell
- 🇺🇸United States justcaldwell Austin, Texas
This should be pretty simple, since the IndentBlock functionality already exists in CKEditor 5 Core—it was disabled in #3211125: Add "Block Indentation" plugin, but only allow list indentation → —so we just need to re-enable it. No need for an external plugin.
- @justcaldwell opened merge request.
- Issue was unassigned.
- Status changed to Needs review
almost 2 years ago 7:27pm 27 February 2023 - 🇺🇸United States justcaldwell Austin, Texas
In my testing, MR6 works with CKEditor 5 on both Drupal 9 and 10. It replicates the functionality of the current version with the exception of the ability to enable/disable paragraph indention on a per text editor/format basis. I'm guessing that this (or some version of it) would be released as a new 2.x branch.
Please test/review if you're able. Thanks!
- 🇺🇸United States justcaldwell Austin, Texas
Latest update adds the ability to enable/disable per text editor/format. The way I've done this feels a bit janky to me, but I couldn't find alternative. Maybe it's possible to fully disable the plugin in javascript?
Also, I assume an upgrade path is still needed (i.e. implement
CKEditor4To5Upgrade
). I may take a crack at that in the next few days if nobody beats me to it. - First commit to issue fork.
- Status changed to RTBC
almost 2 years ago 8:29pm 14 March 2023 - 🇺🇸United States neclimdul Houston, TX
Worked well in testing. Made a few changes so the module could support CKEditor 4 transitions better and fixed a few nits.
- Status changed to Needs review
over 1 year ago 7:01pm 6 April 2023 - heddn Nicaragua
We just added tests to the module and made the compatible w/ D10 and CK4. Can we re-review the work here again to make sure it will still work? We'll probably need a 2.x branch, but thats just logistics when it comes time to commit.
- last update
over 1 year ago Composer require failure - last update
over 1 year ago Composer require failure - 🇺🇸United States percoction
As
.patch
and.diff
files automatically generated from MRs on Gitlab may change as new commits are pushed, and similarly to the recommendation to download local copies of the patches to use in your workflow, I'm uploading a patch here, a copy of the current diff generated from the MR, that applies to the current latest commit of the8.x-1.x-dev
branch.Note: We have to target the
8.x-1.x-dev
branch here instead of the latest8.x-1.0-beta3
release as D.O. releases modify thecomposer.json
file, which, I believe, was disallowing the patch to be applied. - last update
over 1 year ago Composer require failure - last update
over 1 year ago Composer require failure - last update
over 1 year ago 1 pass - 🇺🇸United States justcaldwell Austin, Texas
Okay, the tests are passing now. To do that I:
- Removed the drupal/ckeditor5 requirement from composer.json. It's included in core, so it's not needed and was causing Composer errors.
- Updated the hook_requirements() implementation to add a check for ckeditor5. The test was relying on a 'CKEditor IndentBlock' entry on at 'admin/reports/status' and none is present if ckeditor5 is installed instead of ckeditor(4).
I manually tested again on Drupal 10 with no issues 🙌.
I also manually tested 'upgrading' from ckeditor(4) to ckeditor5 on a fresh Drupal 9.5 instance. Again, no problems there, either (thanks to @neclimdul).
I think this is good to go for a 2.x branch, but I don't want to RTBC since a lot of this is my code.
- 🇺🇸United States justcaldwell Austin, Texas
Here's the latest version of the MR as a patch, should anyone need it.
- last update
over 1 year ago Patch Failed to Apply - last update
over 1 year ago Patch Failed to Apply An available patch was created based on 8.x-1.0-beta3. We will use this until the new release.
- last update
over 1 year ago Patch Failed to Apply - 🇨🇦Canada ryanrobinson_wlu
Patch worked for me to add it to ckeditor 5 (Drupal 9.5.10, PHP 8.1), but took it away from ckeditor 4 in the process.
Is it possible to have it working in both at the same time? I'm currently evaluating 5 and trying to line up that we won't lose any features in the transition, allowing content editors to see it as a "preview." If that's not possible, so be it, I'll keep it only in 4 until I know everything else for 5 is ready.
- 🇺🇸United States justcaldwell Austin, Texas
Hi @ryanrobinson_wlu! Can you elaborate on what you mean by "took it away from ckeditor 4 in the process"?
It's absolutely possible to have both ckeditor 4 and ckeditor 5 in use in the same Drupal instance, and in all my testing the version of ckeditor_indentblock represented by the MR works fine with either 4 or 5.
Have you created a new text format that uses ckeditor 5, so that your editors can switch to that to evaluate the new version?
- 🇨🇦Canada ryanrobinson_wlu
Hi @justcaldwell
I appreciate the follow-up.
I have a ckeditor 4 text format and a ckeditor 5 text format. Without the MR, I could indent paragraphs in ckeditor 4 but not 5. With the MR, I could indent paragraphs in ckeditor 5 but not 4, which I guess is different than your tests with it.
Because of a few other factors I think we're now going to do a harder cutover to 5 instead of a slow transition, in which case this doesn't matter as much for us. If it isn't also a problem for anybody else, don't worry about it.
- 🇺🇸United States justcaldwell Austin, Texas
Got it. Thanks for the additional info. I'm hoping this will get a review from the new maintainer soon.
I assume this will be released as part of a 2.x branch, but I'm not entirely sure...
- last update
over 1 year ago 1 pass - heddn Nicaragua
I've been able to test this on the CK5 site I have running. I didn't test the CK4 v CK5 scenario outlined in #15, but I think that is enough of an edge case I'm not going to worry about right now. Still testing things though.
- last update
over 1 year ago 2 fail - last update
over 1 year ago 2 fail - last update
over 1 year ago 1 pass - last update
over 1 year ago 1 pass - Status changed to RTBC
over 1 year ago 9:22pm 21 August 2023 - heddn Nicaragua
I lied about not worrying about ck4 support. The test now tests that ck4 still works in d9 and ck5 works w/ d10. I think that is about as good as we'll get.
- heddn Nicaragua
We also need to tell site visitors that ck5 is required now with the module. It will _still_ work with ck4 (as seen w/ tests) but let's inform all new users of the module they want to install ck5. So I'm going to leave the entries:
dependencies: - ckeditor:ckeditor - drupal:ckeditor5
in info.yml. This doesn't mean we can't still provide a bc shim for ck4. But eventually we'll remove even that bc shim and only support ck5 going forward.
-
heddn →
committed 347e61a1 on 8.x-1.x authored by
justcaldwell →
Issue #3338085 by justcaldwell, heddn, neclimdul: Make...
-
heddn →
committed 347e61a1 on 8.x-1.x authored by
justcaldwell →
- Status changed to Fixed
over 1 year ago 9:26pm 21 August 2023 - heddn Nicaragua
Thanks everyone for your assistance to get this over the finished line.
Automatically closed - issue fixed for 2 weeks with no activity.