diff options
author | Anton Tananaev <anton@traccar.org> | 2022-10-18 17:19:20 -0700 |
---|---|---|
committer | Anton Tananaev <anton@traccar.org> | 2022-10-18 17:19:20 -0700 |
commit | f2529d17e6594eaa62f982629c6cf1079a254a84 (patch) | |
tree | 5992bb0af6b861e74374fc43a820c71f8d6c5476 /modern/src/main | |
parent | c8d49e57b95e3e91e35740967e1197f251f0c754 (diff) | |
download | trackermap-web-f2529d17e6594eaa62f982629c6cf1079a254a84.tar.gz trackermap-web-f2529d17e6594eaa62f982629c6cf1079a254a84.tar.bz2 trackermap-web-f2529d17e6594eaa62f982629c6cf1079a254a84.zip |
Unify status card styles
Diffstat (limited to 'modern/src/main')
-rw-r--r-- | modern/src/main/MainPage.js | 26 |
1 files changed, 6 insertions, 20 deletions
diff --git a/modern/src/main/MainPage.js b/modern/src/main/MainPage.js index a174096e..4e88733a 100644 --- a/modern/src/main/MainPage.js +++ b/modern/src/main/MainPage.js @@ -80,19 +80,6 @@ const useStyles = makeStyles((theme) => ({ deviceList: { flex: 1, }, - statusCard: { - position: 'fixed', - zIndex: 5, - [theme.breakpoints.up('md')]: { - left: `calc(50% + ${theme.dimensions.drawerWidthDesktop} / 2)`, - bottom: theme.spacing(3), - }, - [theme.breakpoints.down('md')]: { - left: '50%', - bottom: `calc(${theme.spacing(3)} + ${theme.dimensions.bottomBarHeight}px)`, - }, - transform: 'translateX(-50%)', - }, sidebarToggle: { position: 'fixed', left: theme.spacing(1.5), @@ -367,13 +354,12 @@ const MainPage = () => { )} {!features.disableEvents && <EventsDrawer open={eventsOpen} onClose={() => setEventsOpen(false)} />} {selectedDeviceId && ( - <div className={classes.statusCard}> - <StatusCard - deviceId={selectedDeviceId} - position={positions[selectedDeviceId]} - onClose={() => dispatch(devicesActions.select(null))} - /> - </div> + <StatusCard + deviceId={selectedDeviceId} + position={positions[selectedDeviceId]} + onClose={() => dispatch(devicesActions.select(null))} + desktopPadding={theme.dimensions.drawerWidthDesktop} + /> )} </div> ); |