[Mobile] Improve bottom buttons position of edit profile dialog
This commit is contained in:
@@ -50,7 +50,11 @@ const styles = (theme: any) => ({
|
|||||||
},
|
},
|
||||||
dialogContentRoot: {
|
dialogContentRoot: {
|
||||||
maxHeight: 400,
|
maxHeight: 400,
|
||||||
minWidth: 330
|
minWidth: 330,
|
||||||
|
[theme.breakpoints.down('xs')]: {
|
||||||
|
maxHeight: '100%',
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
fullPageXs: {
|
fullPageXs: {
|
||||||
[theme.breakpoints.down('xs')]: {
|
[theme.breakpoints.down('xs')]: {
|
||||||
@@ -59,6 +63,21 @@ const styles = (theme: any) => ({
|
|||||||
margin: 0,
|
margin: 0,
|
||||||
overflowY: 'auto'
|
overflowY: 'auto'
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
fixedDownStickyXS: {
|
||||||
|
[theme.breakpoints.down('xs')]: {
|
||||||
|
position: 'fixed',
|
||||||
|
bottom: 0,
|
||||||
|
right: 0,
|
||||||
|
background: 'white',
|
||||||
|
width: '100%'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
bottomSpace: {
|
||||||
|
height: 16,
|
||||||
|
[theme.breakpoints.down('xs')]: {
|
||||||
|
height: 36
|
||||||
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -326,7 +345,7 @@ export class EditProfileComponent extends Component<IEditProfileComponentProps,
|
|||||||
<div>
|
<div>
|
||||||
{/* Edit profile dialog */}
|
{/* Edit profile dialog */}
|
||||||
<Dialog
|
<Dialog
|
||||||
PaperProps={{className: classes.fullPageXs}}
|
PaperProps={{ className: classes.fullPageXs }}
|
||||||
key='Edit-Profile'
|
key='Edit-Profile'
|
||||||
open={this.props.open!}
|
open={this.props.open!}
|
||||||
onClose={this.props.onRequestClose}
|
onClose={this.props.onRequestClose}
|
||||||
@@ -391,17 +410,17 @@ export class EditProfileComponent extends Component<IEditProfileComponentProps,
|
|||||||
<br />
|
<br />
|
||||||
|
|
||||||
</Paper>
|
</Paper>
|
||||||
<div style={{ height: '16px' }}></div>
|
<div className={classes.bottomSpace}></div>
|
||||||
</DialogContent>
|
</DialogContent>
|
||||||
<DialogActions>
|
<DialogActions className={classes.fixedDownStickyXS}>
|
||||||
<Button onClick={this.props.onRequestClose} > {translate!('profile.cancelButton')} </Button>
|
<Button onClick={this.props.onRequestClose} > {translate!('profile.cancelButton')} </Button>
|
||||||
<Button variant='raised' color='primary' onClick={this.handleUpdate} style={this.styles.updateButton}> {translate!('profile.updateButton')} </Button>
|
<Button variant='raised' color='primary' onClick={this.handleUpdate} style={this.styles.updateButton}> {translate!('profile.updateButton')} </Button>
|
||||||
</DialogActions>
|
</DialogActions>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
|
|
||||||
{/* Image gallery for banner*/}
|
{/* Image gallery for banner*/}
|
||||||
<Dialog
|
<Dialog
|
||||||
PaperProps={{className: classes.fullPageXs}}
|
PaperProps={{ className: classes.fullPageXs }}
|
||||||
open={this.state.openBanner}
|
open={this.state.openBanner}
|
||||||
onClose={this.handleCloseBannerGallery}
|
onClose={this.handleCloseBannerGallery}
|
||||||
|
|
||||||
@@ -414,7 +433,7 @@ export class EditProfileComponent extends Component<IEditProfileComponentProps,
|
|||||||
|
|
||||||
{/* Image gallery for avatar */}
|
{/* Image gallery for avatar */}
|
||||||
<Dialog
|
<Dialog
|
||||||
PaperProps={{className: classes.fullPageXs}}
|
PaperProps={{ className: classes.fullPageXs }}
|
||||||
open={this.state.openAvatar}
|
open={this.state.openAvatar}
|
||||||
onClose={this.handleCloseAvatarGallery}
|
onClose={this.handleCloseAvatarGallery}
|
||||||
>
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user