ckeditor5 icon indicating copy to clipboard operation
ckeditor5 copied to clipboard

Undo or redo in source editing mode

Open wildfrontend opened this issue 1 year ago • 9 comments

Provide a description of the task

is it possible do undo /redo in source editing? it look like only can do it after close souce code mode,

What steps should be taken to fulfill the task?

📃 Other details

  • Browser: …
  • OS: …
  • CKEditor version: …
  • Installed CKEditor plugins: …

wildfrontend avatar Mar 17 '23 04:03 wildfrontend

Unfortunately, it's not possible right now. Let's gather the interest of the community in this issue.

Witoso avatar Apr 14 '23 07:04 Witoso

Could we suggest the addition of undo and redo in the function: private _enableCommands(): void { const editor = this.editor;

	for ( const command of editor.commands.commands() ) {
		command.clearForceDisabled( COMMAND_FORCE_DISABLE_ID );
	}
}

taken from ckeditor5/packages/ckeditor5-source-editing/src/sourceediting.ts

or specifically, can we NOT add 'ck-disabled' class to undo and redo buttons after switching to source editing. Moreever, i would like to know why are we disabling them at the first place?

bravodivs avatar Sep 15 '23 14:09 bravodivs

The source editor is right now a separate textarea and is not an editor's instance by itself. Commands or API calls won't have an effect on it, that's why they are disabled.

Witoso avatar Sep 18 '23 07:09 Witoso

Since this is to gather support, noting that undo-redo (ctrl+z working as expected) in source editing is very important to us.

mlncn avatar Nov 07 '23 17:11 mlncn

Hi Team,

CKeditor5 editor window Undo / redo is not working. IS any option for that? it look like only can do it after close source code mode! Thanks

nithinnath avatar Dec 05 '23 13:12 nithinnath

Why intentionally disable undo/redo keyboard shortcut functionality in any textarea, ever? Please add this standard, expected functionality to CKEditor 5's source editing mode!

timwood avatar Dec 15 '23 13:12 timwood

Can you let us know of any plan on including this feature in the upcoming versions?

ramprassads avatar Apr 15 '24 12:04 ramprassads

Would like to bump this as well, my users are quite surprised that they lost this functionality with the upgrade to Ckeditor5.

There is a work around for this though, you can still right click and get access to the browsers Undo/Redo functionality - I'm not sure why Ctrl-Z is disabled though, that might be the actual bug in CKEditor5 - it's fine that the package button is disabled.

Please consider prioritizing having default browser textarea Undo/Redo in the Source Input view

cewernlund avatar Apr 18 '24 16:04 cewernlund

This would help my organization a lot, as well. We often are working in the source view of things and several of of team use Ctrl+Z and Ctrl+Y like it's second nature and are we are surprised that this isn't working.

flagbrad avatar May 13 '24 17:05 flagbrad