diff --git a/src/css/main.css b/src/css/main.css index dedff00..1628381 100644 --- a/src/css/main.css +++ b/src/css/main.css @@ -2,10 +2,9 @@ * Version: 1.0.0 */ -:root { - color-scheme: light dark; -} - +/* :root { */ +/* color-scheme: only light; */ +/* } */ html, body { margin: 0px; @@ -13,53 +12,68 @@ body { height: 100%; display: flex; flex-direction: column; +} + +html { /* colors */ background-image: linear-gradient(-30deg, #C0E0FF6F 70%, #FFE0C04F); } main { margin: auto; - width: 80%; + min-width: 80%; padding: 10px; min-height: 40%; /* colors */ border: 1px solid darkblue; background-color: white; - box-shadow: 3px 3px 3px #30303090; + box-shadow: 3px 3px 3px #30303090; } -main h1 { +main>h1 { font-family: "Raleway", sans-serif; font-size: 4em; - margin-top: 4px; + margin-top: 0px; margin-bottom: 8px; text-decoration: underline; text-shadow: 0px 0px 4px white, 2px 2px 6px; } -main p, -main a { - padding-left: 1em; +main>p { + margin-left: 1em; +} + +main>h2 { + margin-left: 0.2em; +} + +ul.dashed { + list-style-type: '- '; } .text-red { color: red; } -@media(prefers-color-scheme: dark) { +html.theme-dark { + color-scheme: dark; + background-image: none; + background-image: linear-gradient(-10deg, #1010206F 60%, #5050506F); + color: white; +} - html, - body { - background-image: linear-gradient(-10deg, #1010206F 60%, #5050506F); - } +.theme-dark>body>main { + border: 1px solid darkgray; + background-color: black; + box-shadow: 3px 3px 5px #101010C0; +} - main { - border: 1px solid darkgray; - background-color: black; - box-shadow: 3px 3px 5px #101010C0; - } - - main h1 { +.theme-dark>body>main>h1 { text-shadow: 0px 0px 3px blue, 2px 2px 6px; +} + +@media(orientation: portrait){ + main{ + margin: 1em; } } diff --git a/src/docs/CV_WardTruyen_2024.pdf b/src/docs/CV_WardTruyen_2024.pdf new file mode 100644 index 0000000..82c2d99 Binary files /dev/null and b/src/docs/CV_WardTruyen_2024.pdf differ diff --git a/src/index.html b/src/index.html index 4cdceb1..ed10671 100644 --- a/src/index.html +++ b/src/index.html @@ -7,15 +7,24 @@ +

Ward Truyen home

+

Ik ben een computer wizzard op zoek naar een job in de ICT. + Voor meer informatie bekijk mijn cv.

+

Links

+

Status:

Under construction

-

Links

- truyen.network
+ diff --git a/src/js/theme.js b/src/js/theme.js new file mode 100644 index 0000000..c1c7ee8 --- /dev/null +++ b/src/js/theme.js @@ -0,0 +1,34 @@ +function toggleTheme() { + const theme = "theme-dark";//localStorage.getItem('theme'); + const root = document.querySelector(":root"); + root.classList.toggle(theme); +} + +function setTheme(themeName) { + console.log("setting them: " + themeName); + const root = document.querySelector(":root"); + root.classList.add(themeName); + localStorage.setItem('theme', themeName); +} + +function detectTheme() { + const theme = localStorage.getItem('theme'); + if (theme === 'theme-dark' || theme === 'theme-light') { + setTheme(theme); + return; + } + + if (window.matchMedia('(prefers-color-scheme: dark)').matches) { + setTheme('theme-dark'); + return; + } + + // if (window.matchMedia('(prefers-color-scheme: light)').matches) { + // setTheme('theme-light'); + // return; + // } + + // setTheme('theme-light'); +} +detectTheme(); +