chore(style&dashboard): optimize scss variable file & add version field to Dashboard

This commit is contained in:
haitao(lj) 2022-10-19 11:06:31 +08:00
parent 8ab5dde21e
commit 16db109186
8 changed files with 14 additions and 8 deletions

View File

@ -1,2 +1,2 @@
REACT_APP_API_URL=/
CDN_PATH=/
REACT_APP_VERSION=

View File

@ -1,2 +1,2 @@
REACT_APP_API_URL=http://10.0.10.98:2060
CDN_PATH=https://cdn.dev.segmentfault.com/<projectName>/<version>/
REACT_APP_API_URL=http://10.0.10.98:206
REACT_APP_VERSION=

View File

@ -68,7 +68,7 @@ const Index: FC = () => {
{t('edit')}
</Button>
</Card.Header>
<Card.Body className="mx-n1">
<Card.Body className="m-n1">
{followingTags?.length ? (
<>
{followingTags.map((item) => {

View File

@ -6,7 +6,6 @@
box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .15), $box-shadow-sm;
.logo {
max-height: 1.75rem;
line-height: 1;
}
.nav-link {
color: rgba(255, 255, 255, 0.7);

View File

@ -738,7 +738,8 @@
},
"dashboard": {
"title": "Dashboard",
"welcome": "Welcome to Answer Admin !"
"welcome": "Welcome to Answer Admin !",
"version": "Version"
},
"flags": {
"title": "Flags",
@ -858,4 +859,4 @@
}
}
}
}
}

View File

@ -54,7 +54,7 @@ a {
border-radius: 50%;
position: absolute;
left: 20px;
top: 0px;
top: 0;
border: 1px solid #fff;
}

View File

@ -7,6 +7,12 @@ const Dashboard: FC = () => {
<>
<h3 className="text-capitalize">{t('title')}</h3>
<p className="mt-4">{t('welcome')}</p>
{process.env.REACT_APP_VERSION && (
<p className="mt-4">
{`${t('version')} `}
{process.env.REACT_APP_VERSION}
</p>
)}
</>
);
};