Skip to content

Commit 2de904d

Browse files
committed
Update version to 2.1.0 and enhance ToolbarComponent with version display. Modified webpack configuration to include alias for easier imports. Updated ToolbarComponent styles for improved layout and alignment.
1 parent b5856f4 commit 2de904d

4 files changed

Lines changed: 13 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"version": "2.1.0",
23
"scripts": {
34
"dev": "NODE_ENV=development npx webpack --mode=development --watch",
45
"build": "NODE_ENV=production npx webpack --mode=production",
Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
c-toolbar {
22
position: relative;
33
z-index: 5;
4-
display: block;
4+
display: flex;
5+
align-items: center;
6+
justify-content: space-between;
57
padding: 0 16px 0 8px;
68
overflow: hidden;
79
border-bottom: solid 1px var(--color-separator);
810
}
911
c-toolbar nav, c-toolbar header { overflow: hidden; }
1012

11-
c-toolbar nav ul { display: flex; flex-direction: row; float: left; }
13+
c-toolbar nav ul { display: flex; flex-direction: row; }
1214
c-toolbar nav li a {
1315
display: block;
1416
padding: 12px 8px;
@@ -17,3 +19,8 @@ c-toolbar nav li a {
1719
transition: 0.05s ease-in color;
1820
}
1921
c-toolbar nav .active a, c-toolbar nav li a:hover { color: var(--color-text-primary); text-decoration: none; }
22+
23+
c-toolbar .version {
24+
font: var(--type-medium-normal);
25+
color: var(--color-text-tertiary);
26+
}

src/ui/components/toolbar/ToolbarComponent.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import './ToolbarComponent.css'
22
import Router from 'src/utils/Router'
33
import Tracking from 'src/utils/Tracking'
44
import Element from 'src/ui/Element'
5+
import packageJson from '@/package.json'
56

67
class ToolbarComponent extends Element {
78

@@ -32,6 +33,7 @@ class ToolbarComponent extends Element {
3233
<li class="${(isLicense) ? 'active' : ''}"><a href="${Router.routes.license}">License</a></li>
3334
</ul>
3435
</nav>
36+
<div class="version">v${packageJson.version}</div>
3537
`
3638
}
3739
}

webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ module.exports = (env, argv) => ({
3030
resolve: {
3131
extensions: ['.js'],
3232
alias: {
33+
'@': path.resolve(__dirname, './'),
3334
src: path.resolve(__dirname, 'src/'),
3435
leo: path.resolve(__dirname, 'node_modules/@basiclines/leo/dist/'),
3536
}

0 commit comments

Comments
 (0)