feat(ckeditor): google docs paste, use strong/em not css - #1161
Merged
Conversation
wesleyboar
marked this pull request as ready for review
May 23, 2026 01:10
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
wesleyboar
added a commit
that referenced
this pull request
May 28, 2026
## Overview Fixes CKEditor failing to open on remote servers after #1161. The `pastefromgdocs` plugin registered via `extraPlugins` was returning 404 because `addExternal` (which redirects CKEditor to the CDN) was placed in the `stylesSet` file. That file loads during editor initialization, after `extraPlugins` are already resolved — so the redirect never took effect on prod/pre-prod. Moving `addExternal` to a dedicated `customConfig` file fixes this: CKEditor loads `customConfig` first, before plugin resolution. ## Related - fixes #1161 regression ## Changes - **added** `ckeditor.config.js` — new CKEditor `customConfig` file; holds `addExternal` for CDN plugin - **updated** `djangocms_plugins.py` — register `customConfig` - **deleted** `addExternal` from `ckeditor.wysiwyg.js` (wrong timing; now in config file) ## Testing 1. Deploy to pre-prod. 2. Open any page in edit mode and open a text plugin (WYSIWYG). 3. Verify CKEditor opens without console errors about `pastefromgdocs`. 4. Paste content from Google Docs and verify bold/italic paste behavior still works. ## UI https://github.com/user-attachments/assets/6359151f-b7d4-419d-a48e-36a076499e8e --- Made with [Cursor](https://cursor.com) Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Allow pasting from Google docs:
<span style="font-weight: 700">with<strong>.<span style="font-style: italic">with<em>.Caution
Only worked locally. Broke WYSIWYGs on pre-prod and prod (not live) servers. Fixed by #1164.
Related
Changes
pastefromgdocspluginTesting & UI
Before
Before.mov
Working… Almost
Archived content.
<b>nor<strong>.Current.Status.mov
After
<strong>.After.mov