From 20fda7434c88eae3237399a008f6ae0db50d0eab Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 15 九月 2022 19:12:29 +0800 Subject: [PATCH] 2022-09-15 --- src/menu/stylecombcontrolbutton/index.jsx | 10 ++-------- 1 files changed, 2 insertions(+), 8 deletions(-) diff --git a/src/menu/stylecombcontrolbutton/index.jsx b/src/menu/stylecombcontrolbutton/index.jsx index 3beaaf4..6041a8d 100644 --- a/src/menu/stylecombcontrolbutton/index.jsx +++ b/src/menu/stylecombcontrolbutton/index.jsx @@ -58,10 +58,7 @@ if (!parent) { let _parent = null - if (_type === 'propcard') { - _parent = _p - MKEmitter.emit('changeCombineStyle', ['margin', 'padding', 'border', 'background', 'shadow']) - } else if (_type === 'cardcell') { + if (_type === 'cardcell') { _parent = _p MKEmitter.emit('changeCombineStyle', ['margin', 'padding', 'border', 'background', 'font']) } else { @@ -105,10 +102,7 @@ if (components.findIndex(cell => cell.uuid === card.uuid) > -1) { components = components.filter(cell => cell.uuid !== card.uuid) document.getElementById(card.uuid).classList.remove('selected-control-element') - } else if (type !== 'propcard' && parent.components.findIndex(cell => cell.uuid === card.uuid) > -1) { - components.push(card) - document.getElementById(card.uuid).classList.add('selected-control-element') - } else if (type === 'propcard' && parent.subcards.findIndex(cell => cell.uuid === card.uuid) > -1) { + } else if (type === 'cardcell' && parent.elements.findIndex(cell => cell.uuid === card.uuid) > -1) { components.push(card) document.getElementById(card.uuid).classList.add('selected-control-element') } -- Gitblit v1.8.0