-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Updates project listing and main menu to make table scroll - Updates Main Menu page with header and footer
- Loading branch information
1 parent
a73744b
commit 4f04521
Showing
7 changed files
with
115 additions
and
76 deletions.
There are no files selected for viewing
9 changes: 9 additions & 0 deletions
9
react/src/components/HazmapperHeader/HazmapperHeader.module.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
.root { | ||
display: flex; | ||
align-items: center; | ||
flex-direction: row; | ||
justify-content: space-between; | ||
} | ||
.userName { | ||
color: white; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import React from 'react'; | ||
import useAuthenticatedUser from '@hazmapper/hooks/user/useAuthenticatedUser'; | ||
import { AuthenticatedUser } from '@hazmapper/types'; | ||
import { Layout } from 'antd'; | ||
import styles from './HazmapperHeader.module.css' | ||
|
||
|
||
|
||
export const HazmapperHeader: React.FC<{ user: string;}> = ({user}) => { | ||
const { Header } = Layout; | ||
|
||
return ( | ||
<Header className={styles.root}> | ||
<img width="150px" src="./src/assets/hazmapper-header-logo.png" /> | ||
Check failure on line 14 in react/src/components/HazmapperHeader/HazmapperHeader.tsx GitHub Actions / React-Linting
|
||
<div className={styles.userName}>{user}</div> | ||
</Header> | ||
|
||
) | ||
} | ||
export default HazmapperHeader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from './HazmapperHeader'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,76 +1,101 @@ | ||
.root { | ||
display: flex; | ||
flex-direction: column; | ||
width: 100vh; | ||
height: 100vh; | ||
padding-left:50px; | ||
padding-right: 50px; | ||
} | ||
|
||
.projectList { | ||
display: flex; | ||
flex-direction: column; | ||
width: 100%; | ||
table-layout: fixed; | ||
padding: 10px; | ||
overflow-y: scroll; | ||
height: 60%; | ||
flex-grow: 1; | ||
overflow: hidden; | ||
justify-content: center; | ||
padding:10px; | ||
} | ||
.errorMessage { | ||
|
||
.projectList table { | ||
width: 100%; | ||
padding: 10px; | ||
table-layout: fixed; | ||
border-collapse: collapse; | ||
|
||
} | ||
.projectList th { | ||
|
||
.projectList thead { | ||
position: sticky; | ||
top: 0; | ||
z-index: 10; | ||
background: #d0d0d0; | ||
} | ||
|
||
.projectList thead th { | ||
text-overflow: ellipsis; | ||
overflow: hidden; | ||
white-space: nowrap; | ||
background: #d0d0d0; | ||
} | ||
.projectList th, | ||
button { | ||
overflow: visible; | ||
overflow-wrap: normal; | ||
|
||
.projectList tbody { | ||
display: block; | ||
max-height: 300px; | ||
overflow-y: auto; | ||
} | ||
.projectList tr, | ||
td { | ||
|
||
.projectList tr { | ||
display: table; | ||
width: 100%; | ||
text-overflow: ellipsis; | ||
overflow: hidden; | ||
white-space: nowrap; | ||
table-layout: fixed; | ||
} | ||
|
||
.projectList tr:hover td { | ||
color: white; | ||
background-color: var(--global-color-accent--light); | ||
} | ||
|
||
.projectList tr:hover td button { | ||
color: white; | ||
} | ||
|
||
.mapColumn { | ||
width: 42%; | ||
text-overflow: ellipsis; | ||
overflow: hidden; | ||
white-space: nowrap; | ||
} | ||
|
||
.projectColumn { | ||
width: 42%; | ||
text-overflow: ellipsis; | ||
overflow: hidden; | ||
white-space: nowrap; | ||
} | ||
|
||
.buttonColumn { | ||
width: 16%; | ||
text-align: end; | ||
} | ||
|
||
.buttonColumn button { | ||
max-width: 100%; | ||
text-overflow: ellipsis; | ||
white-space: wrap; | ||
white-space: nowrap; | ||
justify-content: flex-start; | ||
} | ||
|
||
.userGuide { | ||
font-weight: bold; | ||
font-size: medium; | ||
justify-content: flex-end; | ||
height: 10%; | ||
padding-right: 10px; | ||
} | ||
|
||
.versionContainer { | ||
display: flex; | ||
flex-direction: column; | ||
height: 30%; | ||
|
||
justify-content: center; | ||
align-items: center; | ||
} | ||
|
||
.versionContainer img { | ||
height: 80%; | ||
max-height: min-content; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,7 +56,8 @@ const ProjectListing: React.FC = () => { | |
<img src="./src/assets/[email protected]"></img> | ||
<div className={styles.version}>{'Version 2.17'}</div> | ||
</div> | ||
<table className={styles.projectList}> | ||
<div className={styles.projectList}> | ||
<table > | ||
<thead> | ||
<tr> | ||
<th className={styles.mapColumn}>Map</th> | ||
|
@@ -104,6 +105,7 @@ const ProjectListing: React.FC = () => { | |
)} | ||
</tbody> | ||
</table> | ||
</div> | ||
<Button | ||
className={styles.userGuide} | ||
iconNameBefore="exit" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters