Skip to content

Commit

Permalink
feat(version): show current version in menu (#511)
Browse files Browse the repository at this point in the history
* feat(version): show current version in menu

* refactor(vesion): keep position on mobile
  • Loading branch information
KatvonRivia authored Aug 24, 2020
1 parent 2c98372 commit a349974
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/scripts/components/main/menu/menu.styl
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@

.logo
position: absolute
bottom: 1.5em
bottom: emCalc(24px)
display: flex
flex-direction: row
justify-content: center
Expand All @@ -59,6 +59,13 @@
svg
fill: $main

.version
position: absolute
right: emCalc(32px)
bottom: emCalc(24px)
color: $textDefault
font-size: 10px

@media screen and (max-width: 480px)
.menuContainer
width: 100%
Expand Down
3 changes: 3 additions & 0 deletions src/scripts/components/main/menu/menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ import styles from './menu.styl';

const Menu: FunctionComponent = () => {
const [showOverlay, setShowOverlay] = useState(false);
// @ts-ignore - injected via webpack's define plugin
const version = INFO_VERSION;

return (
<React.Fragment>
Expand Down Expand Up @@ -135,6 +137,7 @@ const Menu: FunctionComponent = () => {
<div className={styles.logo}>
<CCILogo />
</div>
<div className={styles.version}>{version}</div>
</React.Fragment>
);
};
Expand Down

0 comments on commit a349974

Please sign in to comment.