mirror of
https://github.com/Steffo99/steffoweb.git
synced 2024-11-21 23:54:30 +00:00
✨ Add "Gestione Amber" theme
This commit is contained in:
parent
747189e3fe
commit
2f1562798f
3 changed files with 11 additions and 13 deletions
|
@ -8,7 +8,7 @@
|
|||
"@fortawesome/free-regular-svg-icons": "^5.15.4",
|
||||
"@fortawesome/free-solid-svg-icons": "^5.15.4",
|
||||
"@fortawesome/react-fontawesome": "^0.1.15",
|
||||
"@steffo/bluelib-react": "^3.0.4",
|
||||
"@steffo/bluelib-react": "^4.2.0",
|
||||
"react": "^17.0.2",
|
||||
"react-dom": "^17.0.2",
|
||||
"react-scripts": "4.0.3",
|
||||
|
|
14
src/App.tsx
14
src/App.tsx
|
@ -1,3 +1,4 @@
|
|||
import {BluelibTheme} from "@steffo/bluelib-react/dist/types"
|
||||
import React from 'react'
|
||||
import {Bluelib, LayoutThreeCol, Heading, Chapter, Box, BringAttention as B, Anchor, Form} from "@steffo/bluelib-react";
|
||||
import {Project} from "./components/Project"
|
||||
|
@ -7,11 +8,8 @@ import {Account} from "./components/Account"
|
|||
import {faEnvelope} from "@fortawesome/free-solid-svg-icons"
|
||||
|
||||
|
||||
type Theme = "paper" | "royalblue" | "hacker" | "sophon"
|
||||
|
||||
|
||||
type ThemeMap = {
|
||||
[fullname: string]: Theme;
|
||||
[fullname: string]: BluelibTheme;
|
||||
};
|
||||
|
||||
|
||||
|
@ -20,11 +18,12 @@ const FULL_THEME_NAMES: ThemeMap = {
|
|||
"The Sophonity": "sophon",
|
||||
"Sheet of Paper": "paper",
|
||||
"Hacker Terminal": "hacker",
|
||||
"Gestione Amber": "amber",
|
||||
}
|
||||
|
||||
|
||||
function App() {
|
||||
const [theme, setTheme] = React.useState<Theme>("royalblue")
|
||||
const [theme, setTheme] = React.useState<BluelibTheme>("royalblue")
|
||||
|
||||
return (
|
||||
<Bluelib theme={theme}>
|
||||
|
@ -51,6 +50,7 @@ function App() {
|
|||
<Heading level={3}>
|
||||
My software projects
|
||||
</Heading>
|
||||
<Project user={"Steffo99"} repo={"sophon"}/>
|
||||
<Project user={"Steffo99"} repo={"greed"}/>
|
||||
<Project user={"Steffo99"} repo={"bluelib"}/>
|
||||
<Project user={"RYGhub"} repo={"bobbot"}/>
|
||||
|
@ -79,9 +79,7 @@ function App() {
|
|||
Other stuff
|
||||
</Heading>
|
||||
<Form>
|
||||
<Form.Select label={"Theme"} onChange={event => setTheme(FULL_THEME_NAMES[event.target.value])}>
|
||||
{Object.keys(FULL_THEME_NAMES).map(key => <Form.Select.Option value={key}/>)}
|
||||
</Form.Select>
|
||||
<Form.Select label={"Theme"} onChange={event => setTheme(FULL_THEME_NAMES[event.target.value])} options={FULL_THEME_NAMES}/>
|
||||
</Form>
|
||||
</Box>
|
||||
</Chapter>
|
||||
|
|
|
@ -1603,10 +1603,10 @@
|
|||
dependencies:
|
||||
"@sinonjs/commons" "^1.7.0"
|
||||
|
||||
"@steffo/bluelib-react@^3.0.4":
|
||||
version "3.0.5"
|
||||
resolved "https://registry.yarnpkg.com/@steffo/bluelib-react/-/bluelib-react-3.0.5.tgz#4543056a0a06efa5fc1ab48d2288b32430eb32f8"
|
||||
integrity sha512-CkvEzeXS7PuIFvTFrDpAU2Gtxhe4L3CF+YkenSzCm0YNWSZ9dW3R1ePEeBNESQW8QZ+fuRu93586etP+bvnBfg==
|
||||
"@steffo/bluelib-react@^4.2.0":
|
||||
version "4.2.0"
|
||||
resolved "https://registry.yarnpkg.com/@steffo/bluelib-react/-/bluelib-react-4.2.0.tgz#12d10517be68366519c4ddf0e21a3b341c9b47b4"
|
||||
integrity sha512-meWWsjiD4cjt7A2nbQHbtY6iFdVJyjlbzUUH5zcPCwVtL6H8gTZ5VTabw+38j5ydDToTd4u9/LNdl8DMq2EcQg==
|
||||
dependencies:
|
||||
"@babel/runtime" "^7.15.3"
|
||||
classnames "^2.3.1"
|
||||
|
|
Loading…
Reference in a new issue