简体   繁体   English

在 Trumbowyg 编辑器中,内置的撤消/重做和历史插件有什么区别?

[英]In the Trumbowyg editor, what's the difference between the built in undo/redo and the History plugin?

I've read the doc and tried the demo, but I can't tell the difference between the built in undo/redo and the History plugin.我已经阅读了文档并尝试了演示,但我无法分辨内置撤消/重做和历史插件之间的区别。

The default buttons are:默认按钮是:

['undo', 'redo'],

The plugin buttons are:插件按钮是:

['historyUndo','historyRedo'],

I've now noticed two differences:我现在注意到两个不同之处:

  1. With the plugin, the undo/redo buttons are greyed out and unclickable if there are no changes to undo or redo, which is a good improvement.使用该插件,如果撤消或重做没有更改,撤消/重做按钮将变灰且不可点击,这是一个很好的改进。 The default undo/redo buttons are not greyed out.默认的撤消/重做按钮不会变灰。
  2. With the plugin, it one undo/redo removes or re-adds whole words.使用该插件,它可以一次撤消/重做删除或重新添加整个单词。 The default does a single character or a few characters at a time, seemingly inconsistently.默认一次显示一个字符或几个字符,看起来不一致。

Curiously, if both the default and plugin buttons are displayed, then clicking either of the default undo/redo buttons will make the plugin's undo button clickable as if there is a change to undo.奇怪的是,如果同时显示默认按钮和插件按钮,那么单击任一默认撤消/重做按钮将使插件的撤消按钮可单击,就好像有更改要撤消一样。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM