-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(fabric-history): refactor the fabric-history and tuning the HistoryPlugin #521
Merged
Conversation
This file contains 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
…abbing is not so much available
# Conflicts: # packages/core/plugin/HistoryPlugin.ts # packages/core/utils/fabric-history.js
感谢大佬 PR, 晚点我测试后合并,[抱拳] |
上面的图片反了😂 |
Closed
@GeorgeSmith215 感谢大佬,已经合并到主分支,之前有开发者反馈,一直也没时间处理,被大佬搞定了 [抱拳]。 |
Closed
@GeorgeSmith215 大佬早上好呀,方便留一个联系方式吗?给您寄一个礼品过去。 |
还有小礼品吗,谢谢作者。 已经收到了,谢谢作者。 |
@GeorgeSmith215 大佬 有兴趣搞定这个问题吗?#374 |
哦哦,我重构 fabric-history 的时候加了一个 refreshHistory 方法就是专门解决这个问题的。 |
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.
贡献者你好
很高兴你能付出自己的时间参与到vue-fabric-editor的共享当中去,相信很多人都因为你提交的代码而收益。
原则
我们希望每次提交尽量小,较大重构除外,确保我们每次的改动影响范围清晰明了,能够方便项目维护者快速的将代码合并到主分支。
确保你的代码与主仓库没有冲突
在PR前,请确保你的代码与主仓库保持同步,可以参考这篇文章。
确保你的代码代码能正常打包构建
在PR前,请在本地进行打包构建,并进行功能测试,确保功能正常,且不影响其他功能。
告知项目维护者本次修改的功能
重构了 fabric-history.js 文件。并调整了 HistoryPlugin.ts 文件以适配新的 fabric-history。
大致实现/修复了以下功能:
1、修复了每次都要撤销两次的bug。
2、实现保存历史前先清除可redo的旧记录,不然可能会redo之前某个阶段的操作记录。
3、实现保存历史数添加上限值。
4、修复历史记录恢复后,鼠标悬浮 workspace 会出现可操作样式的bug。
5、修复 当页面复杂且快速 undo/redo 多次后,可能会在之前的历史上 redo/undo(loadFromJSON 是异步操作)。
具体内容参看代码及注释。