Browse Source

fix(bug): 配置了showtoolbarConfig.undoRedo进行隐藏会出错

master
break-wave 4 years ago
parent
commit
98a16d2b18
  1. 2
      src/controllers/resize.js
  2. 2
      src/controllers/toolbar.js

2
src/controllers/resize.js

@ -392,7 +392,7 @@ export function menuToolBarWidth() {
if (JSON.stringify(showtoolbarConfig) !== '{}') {
if(showtoolbarConfig.hasOwnProperty('undoRedo')){
config.undo = config.redo = showtoolbarConfig.undoRedo;
delete showtoolbarConfig.undoRedo;
// delete showtoolbarConfig.undoRedo;
}
Object.assign(config, showtoolbarConfig);

2
src/controllers/toolbar.js

@ -876,7 +876,7 @@ export function createToolbarHtml() {
if (JSON.stringify(showtoolbarConfig) !== '{}') {
if(showtoolbarConfig.hasOwnProperty('undoRedo')){
config.undo = config.redo = showtoolbarConfig.undoRedo;
delete showtoolbarConfig.undoRedo;
// delete showtoolbarConfig.undoRedo;
}
Object.assign(config, showtoolbarConfig);
}

Loading…
Cancel
Save