Skip to content

Commit

Permalink
website: display version.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Jul 13, 2023
1 parent cc81790 commit 4de98b8
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
8 changes: 7 additions & 1 deletion www/src/App.module.less
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,13 @@ html {
padding-bottom: 30px;
color: white;
}

.version {
position: fixed;
z-index: 9;
left: 40px;
top: 10px;
background-color: #ffffff4f;
}
.logo {
max-width: 210px;
}
Expand Down
1 change: 1 addition & 0 deletions www/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const App: React.FC = () => {
return (
<div className={styles.app}>
<dark-mode permanent style={{ position: 'fixed', top: 8, left: 10, zIndex: 10 }}></dark-mode>
<sup className={styles.version}>{VERSION}</sup>
<GitHubCorners zIndex={9999} fixed href="https://github.com/uiwjs/react-heat-map" />
<header className={styles.header}>
<img src={logo} className={styles.logo} alt="react logo" />
Expand Down
2 changes: 2 additions & 0 deletions www/src/react-app-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
/// <reference types="react-scripts" />

declare var VERSION: string;

declare module '*.module.less' {
const classes: { readonly [key: string]: string };
export default classes;
Expand Down

0 comments on commit 4de98b8

Please sign in to comment.