Skip to content

Commit bde97bf

Browse files
fix: Deploy button align
1 parent d19ec1b commit bde97bf

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

src/dashboard/Data/CloudCode/B4ACloudCode.react.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ class B4ACloudCode extends CloudCode {
6262
}
6363

6464
async componentWillMount() {
65-
back4AppNavigation && back4AppNavigation.atCloudCodePageEvent()
65+
typeof back4AppNavigation === 'object' && back4AppNavigation.atCloudCodePageEvent()
6666
await this.fetchSource()
6767
// define the parameters to show unsaved changes warning modal
6868
const unbindHook = this.props.router.setRouteLeaveHook(this.props.route, nextLocation => {
@@ -240,7 +240,7 @@ class B4ACloudCode extends CloudCode {
240240

241241
footer = <div className={`${styles.row} ${styles.footer}`}>
242242
<Button
243-
value={<div><Icon name='icon-deploy' fill='#fff' width={17} height={30} /> DEPLOY</div>}
243+
value={<div className={styles['b4a-cc-deploy-btn']}><Icon name='icon-deploy' fill='#fff' width={17} height={30} /> DEPLOY</div>}
244244
primary={true}
245245
color='b4a-green'
246246
onClick={this.uploadCode.bind(this)}

src/dashboard/Data/CloudCode/B4ACloudCode.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@
5050
margin-right: 0px;
5151
float: right;
5252

53+
.b4a-cc-deploy-btn {
54+
display: flex;
55+
align-items: center;
56+
justify-content: center;
57+
}
58+
5359
span {
5460
font-family: Raleway;
5561
font-size: 16px;

0 commit comments

Comments
 (0)