From 89943640ac6194ee8e4f3e72d6245a5c8c18fea4 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 07 一月 2021 19:38:21 +0800
Subject: [PATCH] 2021-01-07
---
src/tabviews/zshare/actionList/asyncButtonComponent.jsx | 18 +++++++++++++++++-
1 files changed, 17 insertions(+), 1 deletions(-)
diff --git a/src/tabviews/zshare/actionList/asyncButtonComponent.jsx b/src/tabviews/zshare/actionList/asyncButtonComponent.jsx
index 34eb4ca..1d48bf6 100644
--- a/src/tabviews/zshare/actionList/asyncButtonComponent.jsx
+++ b/src/tabviews/zshare/actionList/asyncButtonComponent.jsx
@@ -25,10 +25,26 @@
render() {
const C = this.state.component
const btn = this.props.btn || {}
+ let style = {}
+
+ if (!C && btn.btnstyle) {
+ if (btn.btnstyle.marginRight) {
+ style.marginRight = btn.btnstyle.marginRight
+ }
+ if (btn.btnstyle.marginLeft) {
+ style.marginLeft = btn.btnstyle.marginLeft
+ }
+ if (btn.btnstyle.marginTop) {
+ style.marginTop = btn.btnstyle.marginTop
+ }
+ if (btn.btnstyle.marginBottom) {
+ style.marginBottom = btn.btnstyle.marginBottom
+ }
+ }
return C ?
<C {...this.props} /> :
- <Button className={'mk-btn mk-' + btn.class} icon={btn.icon} disabled={true} >{btn.label}</Button>
+ <Button className={'mk-btn mk-' + btn.class} style={style} icon={btn.icon} disabled={true} >{btn.label}</Button>
}
}
}
\ No newline at end of file
--
Gitblit v1.8.0