diff --git a/frontend/src/lib/components/Header.svelte b/frontend/src/lib/components/Header.svelte index ea54c67..4f42cff 100644 --- a/frontend/src/lib/components/Header.svelte +++ b/frontend/src/lib/components/Header.svelte @@ -3,7 +3,7 @@ import { applyAction, enhance } from "$app/forms"; import { page } from "$app/stores"; // import Developer from "$lib/img/hero-image.png"; - import Avatar from "$lib/img/teamavatar.png"; + import Avatar from "$lib/img/TeamAvatar.jpeg"; onMount(() => { console.log("Page data in Header:", $page); }); diff --git a/frontend/src/lib/components/ImageInput.svelte b/frontend/src/lib/components/ImageInput.svelte new file mode 100644 index 0000000..680030c --- /dev/null +++ b/frontend/src/lib/components/ImageInput.svelte @@ -0,0 +1,117 @@ + + +
+ {#if avatar} + d + {:else} + + onFileSelected(e)} + /> + + {/if} +
+ + diff --git a/frontend/src/lib/components/InputField.svelte b/frontend/src/lib/components/InputField.svelte new file mode 100644 index 0000000..cc84630 --- /dev/null +++ b/frontend/src/lib/components/InputField.svelte @@ -0,0 +1,100 @@ + + +
+ {label} +
+ {#if error} + {error} + {/if} + +
+
+ + diff --git a/frontend/src/lib/components/Modal.svelte b/frontend/src/lib/components/Modal.svelte new file mode 100644 index 0000000..3a9f5ae --- /dev/null +++ b/frontend/src/lib/components/Modal.svelte @@ -0,0 +1,127 @@ + + + + + diff --git a/frontend/src/lib/components/SmallLoader.svelte b/frontend/src/lib/components/SmallLoader.svelte new file mode 100644 index 0000000..e8324aa --- /dev/null +++ b/frontend/src/lib/components/SmallLoader.svelte @@ -0,0 +1,24 @@ + + +
+

+ {#if message} +

{message}

+ {/if} +
+ + diff --git a/frontend/src/lib/css/styles.css b/frontend/src/lib/css/styles.css index 366084f..6408cd0 100644 --- a/frontend/src/lib/css/styles.css +++ b/frontend/src/lib/css/styles.css @@ -1,46 +1,46 @@ @font-face { - font-family: "Roboto Mono"; - font-style: normal; - font-weight: 300; - src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_gPq_ROW9.ttf) - format("truetype"); + font-family: "Roboto Mono"; + font-style: normal; + font-weight: 300; + src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_gPq_ROW9.ttf) + format("truetype"); } @font-face { - font-family: "Roboto Mono"; - font-style: normal; - font-weight: 400; - src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_ROW9.ttf) - format("truetype"); + font-family: "Roboto Mono"; + font-style: normal; + font-weight: 400; + src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_ROW9.ttf) + format("truetype"); } html { - padding: 0 30px; - background-color: black; - color: #9b9b9b; - font-family: "Quicksand", sans-serif; - font-size: 16px; - font-weight: normal; + padding: 0 30px; + background-color: black; + color: #9b9b9b; + font-family: "Quicksand", sans-serif; + font-size: 16px; + font-weight: normal; } body { - max-width: 1200px; - margin: 5em auto 0 auto; + max-width: 1200px; + margin: 5em auto 0 auto; } pre, code { - display: inline; - font-family: "Roboto Mono", monospace; - font-size: 16px; + display: inline; + font-family: "Roboto Mono", monospace; + font-size: 16px; } input { - font-family: "Roboto Mono", monospace; - color: white; - border-style: none; - height: 21px; - font-size: 16px; + font-family: "Roboto Mono", monospace; + color: white; + border-style: none; + height: 21px; + font-size: 16px; } button { - font-size: 16px; + font-size: 16px; } h1, h2, @@ -48,474 +48,466 @@ h3, h4, h5, h6 { - margin: 0; - font-weight: normal; + margin: 0; + font-weight: normal; } h2 { - margin: 0 0 45px 0; - color: #fff; - font-size: 36px; + margin: 0 0 45px 0; + color: #fff; + font-size: 36px; } h3 { - margin: 0 0 2rem 0; - color: #fff; - font-size: 32px; + margin: 0 0 2rem 0; + color: #fff; + font-size: 32px; } p { - margin: 0 0 45px; - line-height: 1.8; + margin: 0 0 45px; + line-height: 1.8; } ul { - margin: 0 0 32px; + margin: 0 0 32px; } a { - transition: border 0.2s ease-in-out; - border-bottom: 1px solid transparent; - text-decoration: none; - color: #00b7ef; + transition: border 0.2s ease-in-out; + border-bottom: 1px solid transparent; + text-decoration: none; + color: #00b7ef; } a:hover { - border-bottom-color: #00b7ef; + border-bottom-color: #00b7ef; } li { - line-height: 1.8; + line-height: 1.8; } li strong { - color: #fff; + color: #fff; } .image { - width: 100%; - margin: 0 0 32px; - padding: 0; + width: 100%; + margin: 0 0 32px; + padding: 0; } .image img { - width: 100%; + width: 100%; } .optanon-alert-box-wrapper { - left: 0; + left: 0; } .hidden { - display: none !important; + display: none !important; } .hide-mobile { - display: none; + display: none; } @media (min-width: 680px) { - body { - margin: 8em auto 0 auto; - } - .hide-mobile { - display: initial; - } + body { + margin: 8em auto 0 auto; + } + .hide-mobile { + display: initial; + } } .header { - position: fixed; - top: 0; - left: 0; - z-index: 1; - box-sizing: border-box; - width: 100%; - padding: 3em 0 0; - background: black; + position: fixed; + top: 0; + left: 0; + z-index: 1; + box-sizing: border-box; + width: 100%; + padding: 3em 0 0; + background: black; } .header.top-banner-open { - margin-top: 5px; - transition: all 0.2s linear; + margin-top: 5px; + transition: all 0.2s linear; } .header .header-container { - width: 100%; - max-width: calc(1200px + 10em); - height: 5em; - display: flex; - flex-direction: column; - align-items: center; - margin: 0 auto; + width: 100%; + max-width: calc(1200px + 10em); + height: 5em; + display: flex; + flex-direction: column; + align-items: center; + margin: 0 auto; } .header .header-container .header-left { - display: flex; - flex-grow: 1; + display: flex; + flex-grow: 1; } .header .header-container .header-left .header-crafted-by-container { - font-size: 18px; - font-weight: 300; + font-size: 18px; + font-weight: 300; } .header .header-container .header-left .header-crafted-by-container a { - display: flex; - color: #9b9b9b; - border: none; + display: flex; + color: #9b9b9b; + border: none; } .header .header-container .header-left .header-crafted-by-container a img { - height: 28px; + height: 28px; } .header .header-container .header-left .header-crafted-by-container a span { - display: inline-block; - margin: 2px 1ch 0 0; + display: inline-block; + margin: 2px 1ch 0 0; } .header .header-container .header-left .header-crafted-by-container .auth0 { - margin-left: 1ch; - color: #fff; - font-weight: bold; + margin-left: 1ch; + color: #fff; + font-weight: bold; } .header .header-container .header-right { - display: flex; - flex-grow: 1; - justify-content: space-between; - letter-spacing: 1px; - font-weight: 500; + display: flex; + flex-grow: 1; + justify-content: space-between; + letter-spacing: 1px; + font-weight: 500; } .header .header-container .header-right .header-nav-item { - text-transform: uppercase; - margin-left: 10px; + text-transform: uppercase; + margin-left: 10px; } .header .header-container .header-right .header-nav-item button { - all: unset; - cursor: pointer; + all: unset; + cursor: pointer; } .header .header-container .header-right .header-nav-item.active a, .header .header-container .header-right .header-nav-item.active button { - color: #fff; + color: #fff; } .header .header-container .header-right a img { - margin-top: -0.4rem; - height: 28px; + margin-top: -0.4rem; + height: 28px; } .header .header-container .header-right .header-nav-item a, .header .header-container .header-right .header-nav-item button { - transition: color 0.3s ease-in-out; - display: block; - padding: 20px 0; - border: none; - color: #9b9b9b; + transition: color 0.3s ease-in-out; + display: block; + padding: 20px 0; + border: none; + color: #9b9b9b; } .header .header-container .header-right .header-nav-item:hover a, .header .header-container .header-right .header-nav-item:hover button { - color: #fdfff5; + color: #fdfff5; } @media (min-width: 680px) { - .header { - padding: 3em 5rem 0; - } - .header.top-banner-open { - margin-top: 48px; - } - .header .header-container { - flex-direction: row; - } - .header .header-container .header-right { - justify-content: flex-end; - } - .header .header-container .header-right .header-nav-item { - margin-left: 26px; - } + .header { + padding: 3em 5rem 0; + } + .header.top-banner-open { + margin-top: 48px; + } + .header .header-container { + flex-direction: row; + } + .header .header-container .header-right { + justify-content: flex-end; + } + .header .header-container .header-right .header-nav-item { + margin-left: 26px; + } } .button-dark { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: white; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: transparent; - border: 1px solid #595b5c; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: transparent; + border: 1px solid #595b5c; + margin: 2px; } .button-dark:hover { - border-color: #fff; + border-color: #fff; } .button-colorful { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: white; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #d43aff; - border: 1px solid #d43aff; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #d43aff; + border: 1px solid #d43aff; } .button-colorful:hover { - background-color: #c907ff; - border-color: #c907ff; + background-color: #c907ff; + border-color: #c907ff; } .button-orange { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: white; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #eb5424; - border: 1px solid #eb5424; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #eb5424; + border: 1px solid #eb5424; } .button-orange:hover { - background-color: #ca3f12; - border-color: #ca3f12; + background-color: #ca3f12; + border-color: #ca3f12; } .button-colorful:disabled { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: white; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #9a9a9a; - border: 1px solid #9a9a9a; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #9a9a9a; + border: 1px solid #9a9a9a; } .hero-container { - max-width: 795px; - display: flex; - flex-direction: column; - align-items: center; - margin: 0 auto 70px auto; + max-width: 795px; + display: flex; + flex-direction: column; + align-items: center; + margin: 0 auto 70px auto; } .hero-container .hero-logo { - margin-top: 88px; - margin-bottom: 32px; + margin-top: 88px; + margin-bottom: 32px; } .hero-container .hero-subtitle { - font-size: 20px; - text-align: center; - line-height: 32px; - margin: 0 0 45px 0; + font-size: 20px; + text-align: center; + line-height: 32px; + margin: 0 0 45px 0; } .hero-container .hero-buttons-container { - display: flex; + display: flex; } .hero-container .hero-buttons-container button { - margin: 0 8px; + margin: 0 8px; } @media (min-width: 680px) { - .hero-container { - margin: 0 auto 140px auto; - } + .hero-container { + margin: 0 auto 140px auto; + } } .container { - transition: opacity 0.2s ease-in-out; - color: white; - letter-spacing: 0; - opacity: 1; + transition: opacity 0.2s ease-in-out; + color: white; + letter-spacing: 0; + opacity: 1; } .container .content { - width: 100%; - flex-grow: 1; + width: 100%; + flex-grow: 1; } .container .content .step-title { - color: #fff; - font-size: 20px; - font-weight: 500; - line-height: 86px; - opacity: 1; + color: #fff; + font-size: 20px; + font-weight: 500; + line-height: 86px; + opacity: 1; } .container .content .step-subtitle { - position: relative; - top: -5px; - font-size: 16px; - font-weight: 300; + position: relative; + top: -5px; + font-size: 16px; + font-weight: 300; } @media (max-width: 680px) { - .container .content { - margin-top: 120px; - } + .container .content { + margin-top: 120px; + } } @media (min-width: 680px) { - .container { - position: relative; - left: 100px; - display: flex; - width: calc(100% - 100px); - padding: 0; - } - .container .content { - max-width: 795px; - padding-left: 116px; - } - .container .content .step-title { - font-size: 36px; - } + .container { + position: relative; + left: 100px; + display: flex; + width: calc(100% - 100px); + padding: 0; + } + .container .content { + max-width: 795px; + } + .container .content .step-title { + font-size: 36px; + } } .input-box { - display: flex; - align-items: center; - margin: 10px 0; - padding: 0 20px; - width: 100%; - height: 73px; - box-sizing: border-box; - background-color: #2f2f2f; - border-radius: 3px; - font-family: "Roboto Mono", monospace; - font-size: 13px; + display: flex; + align-items: center; + justify-content: space-between; + margin: 10px 0; + padding: 0 20px; + width: 100%; + height: 73px; + box-sizing: border-box; + background-color: #2f2f2f; + border-radius: 3px; + font-family: "Roboto Mono", monospace; + font-size: 13px; } .input-box .label { - text-transform: lowercase; - margin: 0 1ch 0 0; + margin: 0 1ch 0 0; + font-size: 16px; } .input-box .input { - background-color: #494848; - border-radius: 6px; - outline: none; - border: 3px solid #494848; - width: 100%; - max-width: 444px; - font-size: 13px; + background-color: #494848; + border-radius: 6px; + outline: none; + border: 3px solid #494848; + width: 100%; + max-width: 444px; + font-size: 13px; } @media (min-width: 680px) { - .input-box { - padding: 0 30px; - margin: 32px 0; - } + .input-box { + padding: 0 30px; + } } .btn-container { - display: flex; - justify-content: space-between; - align-items: first baseline; + display: flex; + justify-content: space-between; + align-items: first baseline; } @media (max-width: 680px) { - .btn-container { - align-items: flex-start; - } - .btn-container p { - margin-left: 1rem; - } + .btn-container { + align-items: flex-start; + } + .btn-container p { + margin-left: 1rem; + } } .warning { - margin: 20px 0; - padding: 1rem; - width: 100%; - box-sizing: border-box; - background-color: rgb(255 228 230); - border: 1px solid rgb(225 29 72); - border-radius: 6px; - color: rgb(225 29 72); - font-size: 16px; + margin: 20px 0; + padding: 1rem; + width: 100%; + box-sizing: border-box; + background-color: rgb(255 228 230); + border: 1px solid rgb(225 29 72); + border-radius: 6px; + color: rgb(225 29 72); + font-size: 16px; } .warning a { - color: rgb(225 29 72); - text-decoration: underline; + color: rgb(225 29 72); + text-decoration: underline; } .warning.hidden { - display: none; + display: none; } .error { - margin-top: 10rem; - padding: 30px 40px; - background: #2f3132; - color: #fff; + margin-top: 10rem; + padding: 30px 40px; + background: #2f3132; + color: #fff; } .error p { - margin: 0 0 1rem; + margin: 0 0 1rem; } .error p.intro { - font-size: 1.3rem; + font-size: 1.3rem; } .error .button-colorful { - display: inline-block; + display: inline-block; } @media (min-width: 680px) { - .error { - padding: 65px 80px; - } + .error { + padding: 65px 80px; + } } .footer-branding-container { - color: white; - font-weight: 300; - margin-bottom: 73px; + color: white; + font-weight: 300; + margin-bottom: 73px; } .footer-branding-container .footer-branding { - display: flex; - width: 400px; + display: flex; + width: 400px; } .footer-branding-container .footer-branding { - flex-direction: column; - text-align: center; - margin: 30px 0 0; + flex-direction: column; + text-align: center; + margin: 30px 0 0; } .footer-branding-container .footer-branding .footer-crafted-by-container { - display: flex; - align-items: center; - justify-content: center; - margin-bottom: 16px; - color: white; + display: flex; + align-items: center; + justify-content: center; + margin-bottom: 16px; + color: white; } .footer-branding-container .footer-branding .footer-crafted-by-container span { - display: inline-block; - margin: 3px 1ch 0 0; + display: inline-block; + margin: 3px 1ch 0 0; } .footer-branding-container - .footer-branding - .footer-crafted-by-container - .footer-branded-crafted-img { - height: 28px; + .footer-branding + .footer-crafted-by-container + .footer-branded-crafted-img { + height: 28px; } .footer-branding-container .footer-branding .footer-copyright { - color: #696969; - letter-spacing: 0.5px; + color: #696969; + letter-spacing: 0.5px; } .footer-container { - width: 100%; - color: white; - box-sizing: border-box; - display: flex; - justify-content: center; - align-items: center; + width: 100%; + color: white; + box-sizing: border-box; + display: flex; + justify-content: center; + align-items: center; } @media (min-width: 680px) { - .footer-container { - padding: 0; - } + .footer-container { + padding: 0; + } } .simple-loader { - --b: 20px; /* border thickness */ - --n: 15; /* number of dashes*/ - --g: 7deg; /* gap between dashes*/ - --c: #d43aff; /* the color */ + --b: 20px; /* border thickness */ + --n: 15; /* number of dashes*/ + --g: 7deg; /* gap between dashes*/ + --c: #d43aff; /* the color */ - width: 40px; /* size */ - aspect-ratio: 1; - border-radius: 50%; - padding: 1px; /* get rid of bad outlines */ - background: conic-gradient(#0000, var(--c)) content-box; - --_m: /* we use +/-1deg between colors to avoid jagged edges */ repeating-conic-gradient( - #0000 0deg, - #000 1deg calc(360deg / var(--n) - var(--g) - 1deg), - #0000 calc(360deg / var(--n) - var(--g)) calc(360deg / var(--n)) - ), - radial-gradient( - farthest-side, - #0000 calc(98% - var(--b)), - #000 calc(100% - var(--b)) - ); - -webkit-mask: var(--_m); - mask: var(--_m); - -webkit-mask-composite: destination-in; - mask-composite: intersect; - animation: load 1s infinite steps(var(--n)); + width: 40px; /* size */ + aspect-ratio: 1; + border-radius: 50%; + padding: 1px; /* get rid of bad outlines */ + background: conic-gradient(#0000, var(--c)) content-box; + --_m: /* we use +/-1deg between colors to avoid jagged edges */ repeating-conic-gradient( + #0000 0deg, + #000 1deg calc(360deg / var(--n) - var(--g) - 1deg), + #0000 calc(360deg / var(--n) - var(--g)) calc(360deg / var(--n)) + ), + radial-gradient( + farthest-side, + #0000 calc(98% - var(--b)), + #000 calc(100% - var(--b)) + ); + -webkit-mask: var(--_m); + mask: var(--_m); + -webkit-mask-composite: destination-in; + mask-composite: intersect; + animation: load 1s infinite steps(var(--n)); } @keyframes load { - to { - transform: rotate(1turn); - } + to { + transform: rotate(1turn); + } } diff --git a/frontend/src/lib/css/styles.min.css b/frontend/src/lib/css/styles.min.css index 4174e87..6408cd0 100644 --- a/frontend/src/lib/css/styles.min.css +++ b/frontend/src/lib/css/styles.min.css @@ -1,44 +1,46 @@ @font-face { - font-family: "Roboto Mono"; - font-style: normal; - font-weight: 300; - src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_gPq_ROW9.ttf) - format("truetype"); + font-family: "Roboto Mono"; + font-style: normal; + font-weight: 300; + src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_gPq_ROW9.ttf) + format("truetype"); } @font-face { - font-family: "Roboto Mono"; - font-style: normal; - font-weight: 400; - src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_ROW9.ttf) - format("truetype"); + font-family: "Roboto Mono"; + font-style: normal; + font-weight: 400; + src: url(https://fonts.gstatic.com/s/robotomono/v22/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_ROW9.ttf) + format("truetype"); } + html { - padding: 0 30px; - background-color: #000; - color: #9b9b9b; - font-family: Quicksand, sans-serif; - font-size: 16px; - font-weight: 400; + padding: 0 30px; + background-color: black; + color: #9b9b9b; + font-family: "Quicksand", sans-serif; + font-size: 16px; + font-weight: normal; } body { - max-width: 1200px; - margin: 5em auto 0 auto; + max-width: 1200px; + margin: 5em auto 0 auto; } -code, -pre { - display: inline; - font-family: "Roboto Mono", monospace; - font-size: 16px; +pre, +code { + display: inline; + font-family: "Roboto Mono", monospace; + font-size: 16px; } + input { - font-family: "Roboto Mono", monospace; - color: #fff; - border-style: none; - height: 21px; - font-size: 16px; + font-family: "Roboto Mono", monospace; + color: white; + border-style: none; + height: 21px; + font-size: 16px; } button { - font-size: 16px; + font-size: 16px; } h1, h2, @@ -46,460 +48,466 @@ h3, h4, h5, h6 { - margin: 0; - font-weight: 400; + margin: 0; + font-weight: normal; } h2 { - margin: 0 0 45px 0; - color: #fff; - font-size: 36px; + margin: 0 0 45px 0; + color: #fff; + font-size: 36px; } h3 { - margin: 0 0 2rem 0; - color: #fff; - font-size: 32px; + margin: 0 0 2rem 0; + color: #fff; + font-size: 32px; } p { - margin: 0 0 45px; - line-height: 1.8; + margin: 0 0 45px; + line-height: 1.8; } ul { - margin: 0 0 32px; + margin: 0 0 32px; } a { - transition: border 0.2s ease-in-out; - border-bottom: 1px solid transparent; - text-decoration: none; - color: #00b7ef; + transition: border 0.2s ease-in-out; + border-bottom: 1px solid transparent; + text-decoration: none; + color: #00b7ef; } a:hover { - border-bottom-color: #00b7ef; + border-bottom-color: #00b7ef; } li { - line-height: 1.8; + line-height: 1.8; } li strong { - color: #fff; + color: #fff; } .image { - width: 100%; - margin: 0 0 32px; - padding: 0; + width: 100%; + margin: 0 0 32px; + padding: 0; } .image img { - width: 100%; + width: 100%; } .optanon-alert-box-wrapper { - left: 0; + left: 0; } .hidden { - display: none !important; + display: none !important; } .hide-mobile { - display: none; + display: none; } @media (min-width: 680px) { - body { - margin: 8em auto 0 auto; - } - .hide-mobile { - display: initial; - } + body { + margin: 8em auto 0 auto; + } + .hide-mobile { + display: initial; + } } + .header { - position: fixed; - top: 0; - left: 0; - z-index: 1; - box-sizing: border-box; - width: 100%; - padding: 3em 0 0; - background: #000; + position: fixed; + top: 0; + left: 0; + z-index: 1; + box-sizing: border-box; + width: 100%; + padding: 3em 0 0; + background: black; } .header.top-banner-open { - margin-top: 5px; - transition: all 0.2s linear; + margin-top: 5px; + transition: all 0.2s linear; } .header .header-container { - width: 100%; - max-width: calc(1200px + 10em); - height: 5em; - display: flex; - flex-direction: column; - align-items: center; - margin: 0 auto; + width: 100%; + max-width: calc(1200px + 10em); + height: 5em; + display: flex; + flex-direction: column; + align-items: center; + margin: 0 auto; } .header .header-container .header-left { - display: flex; - flex-grow: 1; + display: flex; + flex-grow: 1; } .header .header-container .header-left .header-crafted-by-container { - font-size: 18px; - font-weight: 300; + font-size: 18px; + font-weight: 300; } .header .header-container .header-left .header-crafted-by-container a { - display: flex; - color: #9b9b9b; - border: none; + display: flex; + color: #9b9b9b; + border: none; } .header .header-container .header-left .header-crafted-by-container a img { - height: 28px; + height: 28px; } .header .header-container .header-left .header-crafted-by-container a span { - display: inline-block; - margin: 2px 1ch 0 0; + display: inline-block; + margin: 2px 1ch 0 0; } .header .header-container .header-left .header-crafted-by-container .auth0 { - margin-left: 1ch; - color: #fff; - font-weight: 700; + margin-left: 1ch; + color: #fff; + font-weight: bold; } .header .header-container .header-right { - display: flex; - flex-grow: 1; - justify-content: space-between; - letter-spacing: 1px; - font-weight: 500; + display: flex; + flex-grow: 1; + justify-content: space-between; + letter-spacing: 1px; + font-weight: 500; } .header .header-container .header-right .header-nav-item { - text-transform: uppercase; - margin-left: 10px; + text-transform: uppercase; + margin-left: 10px; } .header .header-container .header-right .header-nav-item button { - all: unset; - cursor: pointer; + all: unset; + cursor: pointer; } .header .header-container .header-right .header-nav-item.active a, .header .header-container .header-right .header-nav-item.active button { - color: #fff; + color: #fff; } + .header .header-container .header-right a img { - margin-top: -0.4rem; - height: 28px; + margin-top: -0.4rem; + height: 28px; } + .header .header-container .header-right .header-nav-item a, .header .header-container .header-right .header-nav-item button { - transition: color 0.3s ease-in-out; - display: block; - padding: 20px 0; - border: none; - color: #9b9b9b; + transition: color 0.3s ease-in-out; + display: block; + padding: 20px 0; + border: none; + color: #9b9b9b; } .header .header-container .header-right .header-nav-item:hover a, .header .header-container .header-right .header-nav-item:hover button { - color: #fdfff5; + color: #fdfff5; } @media (min-width: 680px) { - .header { - padding: 3em 5rem 0; - } - .header.top-banner-open { - margin-top: 48px; - } - .header .header-container { - flex-direction: row; - } - .header .header-container .header-right { - justify-content: flex-end; - } - .header .header-container .header-right .header-nav-item { - margin-left: 26px; - } + .header { + padding: 3em 5rem 0; + } + .header.top-banner-open { + margin-top: 48px; + } + .header .header-container { + flex-direction: row; + } + .header .header-container .header-right { + justify-content: flex-end; + } + .header .header-container .header-right .header-nav-item { + margin-left: 26px; + } } .button-dark { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: #fff; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: transparent; - border: 1px solid #595b5c; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: transparent; + border: 1px solid #595b5c; + margin: 2px; } .button-dark:hover { - border-color: #fff; + border-color: #fff; } .button-colorful { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: #fff; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #d43aff; - border: 1px solid #d43aff; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #d43aff; + border: 1px solid #d43aff; } .button-colorful:hover { - background-color: #c907ff; - border-color: #c907ff; + background-color: #c907ff; + border-color: #c907ff; } .button-orange { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: #fff; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #eb5424; - border: 1px solid #eb5424; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #eb5424; + border: 1px solid #eb5424; } .button-orange:hover { - background-color: #ca3f12; - border-color: #ca3f12; + background-color: #ca3f12; + border-color: #ca3f12; } .button-colorful:disabled { - transition: - border-color 0.3s ease-in-out, - background-color 0.3s ease-in-out; - color: #fff; - text-transform: uppercase; - font-weight: 500; - padding: 18px 28px; - letter-spacing: 1px; - cursor: pointer; - background-color: #9a9a9a; - border: 1px solid #9a9a9a; + transition: border-color 0.3s ease-in-out, background-color 0.3s ease-in-out; + color: white; + text-transform: uppercase; + font-weight: 500; + padding: 18px 28px; + letter-spacing: 1px; + cursor: pointer; + background-color: #9a9a9a; + border: 1px solid #9a9a9a; } .hero-container { - max-width: 795px; - display: flex; - flex-direction: column; - align-items: center; - margin: 0 auto 70px auto; + max-width: 795px; + display: flex; + flex-direction: column; + align-items: center; + margin: 0 auto 70px auto; } .hero-container .hero-logo { - margin-top: 88px; - margin-bottom: 32px; + margin-top: 88px; + margin-bottom: 32px; } .hero-container .hero-subtitle { - font-size: 20px; - text-align: center; - line-height: 32px; - margin: 0 0 45px 0; + font-size: 20px; + text-align: center; + line-height: 32px; + margin: 0 0 45px 0; } .hero-container .hero-buttons-container { - display: flex; + display: flex; } .hero-container .hero-buttons-container button { - margin: 0 8px; + margin: 0 8px; } @media (min-width: 680px) { - .hero-container { - margin: 0 auto 140px auto; - } + .hero-container { + margin: 0 auto 140px auto; + } } + .container { - transition: opacity 0.2s ease-in-out; - color: #fff; - letter-spacing: 0; - opacity: 1; + transition: opacity 0.2s ease-in-out; + color: white; + letter-spacing: 0; + opacity: 1; } + .container .content { - width: 100%; - flex-grow: 1; + width: 100%; + flex-grow: 1; } .container .content .step-title { - color: #fff; - font-size: 20px; - font-weight: 500; - line-height: 86px; - opacity: 1; + color: #fff; + font-size: 20px; + font-weight: 500; + line-height: 86px; + opacity: 1; } .container .content .step-subtitle { - position: relative; - top: -5px; - font-size: 16px; - font-weight: 300; + position: relative; + top: -5px; + font-size: 16px; + font-weight: 300; } + @media (max-width: 680px) { - .container .content { - margin-top: 120px; - } + .container .content { + margin-top: 120px; + } } + @media (min-width: 680px) { - .container { - position: relative; - left: 100px; - display: flex; - width: calc(100% - 100px); - padding: 0; - } - .container .content { - max-width: 795px; - padding-left: 116px; - } - .container .content .step-title { - font-size: 36px; - } + .container { + position: relative; + left: 100px; + display: flex; + width: calc(100% - 100px); + padding: 0; + } + .container .content { + max-width: 795px; + } + .container .content .step-title { + font-size: 36px; + } } .input-box { - display: flex; - align-items: center; - margin: 10px 0; - padding: 0 20px; - width: 100%; - height: 73px; - box-sizing: border-box; - background-color: #2f2f2f; - border-radius: 3px; - font-family: "Roboto Mono", monospace; - font-size: 13px; + display: flex; + align-items: center; + justify-content: space-between; + margin: 10px 0; + padding: 0 20px; + width: 100%; + height: 73px; + box-sizing: border-box; + background-color: #2f2f2f; + border-radius: 3px; + font-family: "Roboto Mono", monospace; + font-size: 13px; } .input-box .label { - text-transform: lowercase; - margin: 0 1ch 0 0; + margin: 0 1ch 0 0; + font-size: 16px; } .input-box .input { - background-color: #494848; - border-radius: 6px; - outline: 0; - border: 3px solid #494848; - width: 100%; - max-width: 444px; - font-size: 13px; + background-color: #494848; + border-radius: 6px; + outline: none; + border: 3px solid #494848; + width: 100%; + max-width: 444px; + font-size: 13px; } @media (min-width: 680px) { - .input-box { - padding: 0 30px; - margin: 32px 0; - } + .input-box { + padding: 0 30px; + } } .btn-container { - display: flex; - justify-content: space-between; - align-items: first baseline; + display: flex; + justify-content: space-between; + align-items: first baseline; } @media (max-width: 680px) { - .btn-container { - align-items: flex-start; - } - .btn-container p { - margin-left: 1rem; - } + .btn-container { + align-items: flex-start; + } + .btn-container p { + margin-left: 1rem; + } } .warning { - margin: 20px 0; - padding: 1rem; - width: 100%; - box-sizing: border-box; - background-color: rgb(255 228 230); - border: 1px solid rgb(225 29 72); - border-radius: 6px; - color: rgb(225 29 72); - font-size: 16px; + margin: 20px 0; + padding: 1rem; + width: 100%; + box-sizing: border-box; + background-color: rgb(255 228 230); + border: 1px solid rgb(225 29 72); + border-radius: 6px; + color: rgb(225 29 72); + font-size: 16px; } .warning a { - color: rgb(225 29 72); - text-decoration: underline; + color: rgb(225 29 72); + text-decoration: underline; } .warning.hidden { - display: none; + display: none; } + .error { - margin-top: 10rem; - padding: 30px 40px; - background: #2f3132; - color: #fff; + margin-top: 10rem; + padding: 30px 40px; + background: #2f3132; + color: #fff; } .error p { - margin: 0 0 1rem; + margin: 0 0 1rem; } .error p.intro { - font-size: 1.3rem; + font-size: 1.3rem; } .error .button-colorful { - display: inline-block; + display: inline-block; } @media (min-width: 680px) { - .error { - padding: 65px 80px; - } + .error { + padding: 65px 80px; + } } + .footer-branding-container { - color: #fff; - font-weight: 300; - margin-bottom: 73px; + color: white; + font-weight: 300; + margin-bottom: 73px; +} + +.footer-branding-container .footer-branding { + display: flex; + width: 400px; } .footer-branding-container .footer-branding { - display: flex; - width: 400px; -} -.footer-branding-container .footer-branding { - flex-direction: column; - text-align: center; - margin: 30px 0 0; + flex-direction: column; + text-align: center; + margin: 30px 0 0; } .footer-branding-container .footer-branding .footer-crafted-by-container { - display: flex; - align-items: center; - justify-content: center; - margin-bottom: 16px; - color: #fff; + display: flex; + align-items: center; + justify-content: center; + margin-bottom: 16px; + color: white; } .footer-branding-container .footer-branding .footer-crafted-by-container span { - display: inline-block; - margin: 3px 1ch 0 0; + display: inline-block; + margin: 3px 1ch 0 0; } .footer-branding-container - .footer-branding - .footer-crafted-by-container - .footer-branded-crafted-img { - height: 28px; + .footer-branding + .footer-crafted-by-container + .footer-branded-crafted-img { + height: 28px; } + .footer-branding-container .footer-branding .footer-copyright { - color: #696969; - letter-spacing: 0.5px; + color: #696969; + letter-spacing: 0.5px; } .footer-container { - width: 100%; - color: #fff; - box-sizing: border-box; - display: flex; - justify-content: center; - align-items: center; + width: 100%; + color: white; + box-sizing: border-box; + display: flex; + justify-content: center; + align-items: center; } + @media (min-width: 680px) { - .footer-container { - padding: 0; - } + .footer-container { + padding: 0; + } } + .simple-loader { - --b: 20px; - --n: 15; - --g: 7deg; - --c: #d43aff; - width: 40px; - aspect-ratio: 1; - border-radius: 50%; - padding: 1px; - background: conic-gradient(#0000, var(--c)) content-box; - --_m: repeating-conic-gradient( - #0000 0deg, - #000 1deg calc(360deg / var(--n) - var(--g) - 1deg), - #0000 calc(360deg / var(--n) - var(--g)) calc(360deg / var(--n)) - ), - radial-gradient( - farthest-side, - #0000 calc(98% - var(--b)), - #000 calc(100% - var(--b)) - ); - -webkit-mask: var(--_m); - mask: var(--_m); - -webkit-mask-composite: destination-in; - mask-composite: intersect; - animation: load 1s infinite steps(var(--n)); + --b: 20px; /* border thickness */ + --n: 15; /* number of dashes*/ + --g: 7deg; /* gap between dashes*/ + --c: #d43aff; /* the color */ + + width: 40px; /* size */ + aspect-ratio: 1; + border-radius: 50%; + padding: 1px; /* get rid of bad outlines */ + background: conic-gradient(#0000, var(--c)) content-box; + --_m: /* we use +/-1deg between colors to avoid jagged edges */ repeating-conic-gradient( + #0000 0deg, + #000 1deg calc(360deg / var(--n) - var(--g) - 1deg), + #0000 calc(360deg / var(--n) - var(--g)) calc(360deg / var(--n)) + ), + radial-gradient( + farthest-side, + #0000 calc(98% - var(--b)), + #000 calc(100% - var(--b)) + ); + -webkit-mask: var(--_m); + mask: var(--_m); + -webkit-mask-composite: destination-in; + mask-composite: intersect; + animation: load 1s infinite steps(var(--n)); } @keyframes load { - to { - transform: rotate(1turn); - } + to { + transform: rotate(1turn); + } } diff --git a/frontend/src/lib/img/Avatar-f1.jpeg b/frontend/src/lib/img/Avatar-f1.jpeg new file mode 100644 index 0000000..d77debe Binary files /dev/null and b/frontend/src/lib/img/Avatar-f1.jpeg differ diff --git a/frontend/src/lib/img/Avatar-f2.jpeg b/frontend/src/lib/img/Avatar-f2.jpeg new file mode 100644 index 0000000..4d5c6a3 Binary files /dev/null and b/frontend/src/lib/img/Avatar-f2.jpeg differ diff --git a/frontend/src/lib/img/Avatar-m1.jpeg b/frontend/src/lib/img/Avatar-m1.jpeg new file mode 100644 index 0000000..ebfcb3f Binary files /dev/null and b/frontend/src/lib/img/Avatar-m1.jpeg differ diff --git a/frontend/src/lib/img/Avatar-m2.jpeg b/frontend/src/lib/img/Avatar-m2.jpeg new file mode 100644 index 0000000..2b3c432 Binary files /dev/null and b/frontend/src/lib/img/Avatar-m2.jpeg differ diff --git a/frontend/src/lib/img/Avatar-m3.jpeg b/frontend/src/lib/img/Avatar-m3.jpeg new file mode 100644 index 0000000..7902a0c Binary files /dev/null and b/frontend/src/lib/img/Avatar-m3.jpeg differ diff --git a/frontend/src/lib/img/TeamAvatar.jpeg b/frontend/src/lib/img/TeamAvatar.jpeg new file mode 100644 index 0000000..f85293b Binary files /dev/null and b/frontend/src/lib/img/TeamAvatar.jpeg differ diff --git a/frontend/src/lib/locales/de.js b/frontend/src/lib/locales/de.js new file mode 100644 index 0000000..5e8e3e8 --- /dev/null +++ b/frontend/src/lib/locales/de.js @@ -0,0 +1,50 @@ +export default { + userStatus: { + 1: "Nicht verifiziert", + 2: "Verifiziert", + 3: "Aktiv", + 4: "Passiv", + 5: "Deaktiviert", + }, + userRole: { + 0: "Mitglied", + 1: "Betrachter", + 4: "Bearbeiter", + 8: "Administrator", + }, + unknown: "Unbekannt", + notes: "Notizen", + address: "Straße & Hausnummer", + city: "Wohnort", + zip_code: "PLZ", + forgot_password: "Passwort vergessen?", + password: "Passwort", + password_repeat: "Passwort wiederholen", + placeholder_password: "Passwort eingeben...", + email: "Email", + placeholder_email: "Emailadresse eingeben...", + login: "Anmelden", + user: "Nutzer", + user_login: "Nutzer Anmeldung", + user_edit: "Nutzer bearbeiten", + profile: "Profil", + membership: "Mitgliedschaft", + bankaccount: "Kontodaten", + status: "Status", + start: "Beginn", + end: "Ende", + parent_member_id: "Hauptmitgliedsnr.", + placeholder_parent_member_id: "Mitgliedsnr des Hauptmitglieds eingeben...", + bank_account_holder: "Kontoinhaber", + bank_name: "Name der Bank", + iban: "IBAN", + bic: "BIC", + mandate_reference: "SEPA Mandat", + placeholder_bank_account_holder: "Namen eingeben...", + placeholder_iban: "IBAN eingeben..", + placeholder_bic: "BIC eingeben(optional)...", + placeholder_mandate_reference: "SEPA Mandatsreferenz eingeben..", + required: "Eingabe benötigt", + required_password: "Password zu kurz, mindestens 8 Zeichen", + required_password_match: "Passwörter stimmen nicht überein!", +}; diff --git a/frontend/src/lib/locales/en.js b/frontend/src/lib/locales/en.js new file mode 100644 index 0000000..fc51328 --- /dev/null +++ b/frontend/src/lib/locales/en.js @@ -0,0 +1,15 @@ +export default { + userStatus: { + 1: "Unverified", + 2: "Verified", + 3: "Active", + 4: "Passive", + 5: "Disabled", + }, + userRole: { + 0: "Member", + 1: "Viewer", + 4: "Editor", + 8: "Admin", + }, +}; diff --git a/frontend/src/lib/utils/i18n.js b/frontend/src/lib/utils/i18n.js new file mode 100644 index 0000000..b2a7af7 --- /dev/null +++ b/frontend/src/lib/utils/i18n.js @@ -0,0 +1,20 @@ +import { register, init, getLocaleFromNavigator, locale } from "svelte-i18n"; + +function setupI18n() { + register("en", () => import("../locales/en.js")); + register("de", () => import("../locales/de.js")); + + init({ + fallbackLocale: "de", + initialLocale: getLocaleFromNavigator(), + }); +} + +setupI18n(); + +/** + * @param {string} newLocale - The new locale to set + */ +export const changeLocale = (newLocale) => { + locale.set(newLocale); +}; diff --git a/frontend/src/routes/+layout.svelte b/frontend/src/routes/+layout.svelte index fbdbf8c..a655cea 100644 --- a/frontend/src/routes/+layout.svelte +++ b/frontend/src/routes/+layout.svelte @@ -4,14 +4,27 @@ import Transition from "$lib/components/Transition.svelte"; import "$lib/css/styles.min.css"; + import { waitLocale } from "svelte-i18n"; + import { onMount } from "svelte"; + import "$lib/utils/i18n.js"; + /** @type {import('./$types').PageData} */ export let data; + + let ready = false; + + onMount(async () => { + await waitLocale(); + ready = true; + }); - -
+{#if ready} + +
- + -