Skip to content
This repository was archived by the owner on Aug 31, 2022. It is now read-only.

Commit 9261499

Browse files
author
ANISHA SWAIN
authored
adds dashboard version number (#200)
1 parent ce32e40 commit 9261499

File tree

3 files changed

+25
-5
lines changed

3 files changed

+25
-5
lines changed

src/components/Footer/index.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import './index.less';
2+
import React from 'react';
3+
import packageJSON from '../../../package.json';
4+
5+
export default function Footer() {
6+
return (
7+
<>
8+
<div className="footer">
9+
<em>Version: {packageJSON.version}</em>
10+
</div>
11+
</>
12+
);
13+
}

src/components/Footer/index.less

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.footer {
2+
font-size: 0.8rem;
3+
width: -webkit-fill-available;
4+
text-align: center;
5+
padding: 0.5rem 0;
6+
bottom: 0;
7+
background-color: #cfe8ff;
8+
color: black;
9+
}

src/layouts/BasicLayout.js

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { persistStore } from 'redux-persist';
88
import memoizeOne from 'memoize-one';
99
import GlobalHeader from '@/components/GlobalHeader';
1010
import { getDvaApp } from 'umi';
11+
import Footer from '@/components/Footer';
1112
import {
1213
Page,
1314
Bullseye,
@@ -173,11 +174,7 @@ class BasicLayout extends React.PureComponent {
173174
</React.Fragment>
174175
}
175176
>
176-
<DescriptionList
177-
columnModifier={{
178-
default: '2Col',
179-
}}
180-
>
177+
<DescriptionList columnModifier={{ default: '2Col' }}>
181178
<DescriptionListGroup>
182179
<DescriptionListTerm>ID</DescriptionListTerm>
183180
<DescriptionListDescription>{sessionId}</DescriptionListDescription>
@@ -222,6 +219,7 @@ class BasicLayout extends React.PureComponent {
222219
</PageSection>
223220
{children}
224221
</PersistGate>
222+
<Footer />
225223
</Page>
226224
</DocumentTitle>
227225
</React.Fragment>

0 commit comments

Comments
 (0)