feat: make chemistry and MVP buttons more button-like
This commit is contained in:
		
							
								
								
									
										21
									
								
								src/App.css
									
									
									
									
									
								
							
							
						
						
									
										21
									
								
								src/App.css
									
									
									
									
									
								
							| @@ -1,5 +1,5 @@ | |||||||
| * { | * { | ||||||
|   border-radius: 8px; |   border-radius: 16px; | ||||||
| } | } | ||||||
|  |  | ||||||
| body { | body { | ||||||
| @@ -154,15 +154,20 @@ button { | |||||||
| } | } | ||||||
|  |  | ||||||
| .tablink { | .tablink { | ||||||
|   background-color: unset; |   color: white; | ||||||
|   font-weight: unset; |  | ||||||
|   color: black; |  | ||||||
|   border: 2px solid black; |  | ||||||
|   border-radius: unset; |  | ||||||
|   outline: black; |  | ||||||
|   cursor: pointer; |   cursor: pointer; | ||||||
|   padding: 8px 16px; |   padding: 8px 16px; | ||||||
|   width: 50%; |   width: 48%; | ||||||
|  | } | ||||||
|  |  | ||||||
|  | .navbar { | ||||||
|  |   button { | ||||||
|  |     opacity: 50%; | ||||||
|  |     &:hover { | ||||||
|  |       opacity: 75%; | ||||||
|  |     } | ||||||
|  |   } | ||||||
|  |   padding: 16px; | ||||||
| } | } | ||||||
|  |  | ||||||
| /* Style the tab content (and add height:100% for full page content) */ | /* Style the tab content (and add height:100% for full page content) */ | ||||||
|   | |||||||
| @@ -279,10 +279,7 @@ function openPage(pageName: string, color: string) { | |||||||
|   tablinks = document.getElementsByClassName("tablink"); |   tablinks = document.getElementsByClassName("tablink"); | ||||||
|   for (i = 0; i < tablinks.length; i++) { |   for (i = 0; i < tablinks.length; i++) { | ||||||
|     let button = tablinks[i] as HTMLElement; |     let button = tablinks[i] as HTMLElement; | ||||||
|     button.style.backgroundColor = "unset"; |     button.style.opacity = "50%"; | ||||||
|     button.style.textDecoration = "unset"; |  | ||||||
|     button.style.fontWeight = "unset"; |  | ||||||
|     button.style.color = "unset"; |  | ||||||
|   } |   } | ||||||
|   // Show the specific tab content |   // Show the specific tab content | ||||||
|   (document.getElementById(pageName) as HTMLElement).style.display = "block"; |   (document.getElementById(pageName) as HTMLElement).style.display = "block"; | ||||||
| @@ -290,10 +287,8 @@ function openPage(pageName: string, color: string) { | |||||||
|   let activeButton = document.getElementById( |   let activeButton = document.getElementById( | ||||||
|     pageName + "Button" |     pageName + "Button" | ||||||
|   ) as HTMLElement; |   ) as HTMLElement; | ||||||
|   activeButton.style.textDecoration = "underline"; |  | ||||||
|   activeButton.style.fontWeight = "bold"; |   activeButton.style.fontWeight = "bold"; | ||||||
|   activeButton.style.backgroundColor = "#3366cc"; |   activeButton.style.opacity = "100%"; | ||||||
|   activeButton.style.color = "white"; |  | ||||||
|   document.body.style.backgroundColor = color; |   document.body.style.backgroundColor = color; | ||||||
| } | } | ||||||
|  |  | ||||||
| @@ -318,20 +313,20 @@ export default function Rankings() { | |||||||
|       <SelectUser {...{ user, setUser, players, setPlayers }} /> |       <SelectUser {...{ user, setUser, players, setPlayers }} /> | ||||||
|       {user.length === 1 && ( |       {user.length === 1 && ( | ||||||
|         <> |         <> | ||||||
|           <div className="container"> |           <div className="container navbar"> | ||||||
|             <button |             <button | ||||||
|               className="tablink" |               className="tablink" | ||||||
|               id="ChemistryButton" |               id="ChemistryButton" | ||||||
|               onClick={() => openPage("Chemistry", "aliceblue")} |               onClick={() => openPage("Chemistry", "aliceblue")} | ||||||
|             > |             > | ||||||
|               Chemistry |               🧪 Chemistry | ||||||
|             </button> |             </button> | ||||||
|             <button |             <button | ||||||
|               className="tablink" |               className="tablink" | ||||||
|               id="MVPButton" |               id="MVPButton" | ||||||
|               onClick={() => openPage("MVP", "aliceblue")} |               onClick={() => openPage("MVP", "aliceblue")} | ||||||
|             > |             > | ||||||
|               MVP |               🏆 MVP | ||||||
|             </button> |             </button> | ||||||
|           </div> |           </div> | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user