mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-03-21 18:04:39 -05:00
Rename global CSS files
This commit is contained in:
parent
6de71121dc
commit
61ace7e9b2
2
TODO.md
2
TODO.md
|
|
@ -21,7 +21,7 @@ Calendar
|
|||
- [x] WeekLinks make opaque blocks not take space on mobile
|
||||
- [x] Type problem with Avatar
|
||||
- [x] Maybe classNames that do nothing on calendar event page?
|
||||
- [ ] refactor global.css/common.css -> variables.css / utils.css / common.css
|
||||
- [x] refactor global.css/common.css -> variables.css / utils.css / common.css
|
||||
- [ ] addTagArray get tags type from constant
|
||||
- [x] Rename model events -> calendarEvents
|
||||
- [x] On the event page should not say Day 1 if only one day
|
||||
|
|
|
|||
|
|
@ -16,7 +16,8 @@ import {
|
|||
} from "@remix-run/react";
|
||||
import * as React from "react";
|
||||
import commonStyles from "~/styles/common.css";
|
||||
import globalStyles from "~/styles/global.css";
|
||||
import variableStyles from "~/styles/vars.css";
|
||||
import utilStyles from "~/styles/utils.css";
|
||||
import layoutStyles from "~/styles/layout.css";
|
||||
import resetStyles from "~/styles/reset.css";
|
||||
import { Catcher } from "./components/Catcher";
|
||||
|
|
@ -34,8 +35,9 @@ export const unstable_shouldReload: ShouldReloadFunction = () => false;
|
|||
export const links: LinksFunction = () => {
|
||||
return [
|
||||
{ rel: "stylesheet", href: resetStyles },
|
||||
{ rel: "stylesheet", href: globalStyles },
|
||||
{ rel: "stylesheet", href: commonStyles },
|
||||
{ rel: "stylesheet", href: variableStyles },
|
||||
{ rel: "stylesheet", href: utilStyles },
|
||||
{ rel: "stylesheet", href: layoutStyles },
|
||||
];
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,3 +1,307 @@
|
|||
*,
|
||||
*::before,
|
||||
*::after {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
width: 100%;
|
||||
background-color: var(--bg);
|
||||
color: var(--text);
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial,
|
||||
sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: antialiased;
|
||||
line-height: 1.55;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
|
||||
*:focus:not(:focus-visible) {
|
||||
outline: none !important;
|
||||
}
|
||||
|
||||
a {
|
||||
color: var(--theme);
|
||||
font-weight: var(--semi-bold);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
:is(button, .button) {
|
||||
display: flex;
|
||||
width: auto;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border: 2px solid var(--theme);
|
||||
appearance: none;
|
||||
background: var(--theme);
|
||||
border-radius: var(--rounded-sm);
|
||||
color: var(--button-text);
|
||||
cursor: pointer;
|
||||
font-size: var(--fonts-sm);
|
||||
font-weight: var(--bold);
|
||||
line-height: 1.2;
|
||||
outline-offset: 2px;
|
||||
padding-block: var(--s-1-5);
|
||||
padding-inline: var(--s-2-5);
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
:is(button, .button):focus-visible {
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
:is(button, .button):active {
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
:is(button, .button):disabled {
|
||||
cursor: not-allowed;
|
||||
opacity: 0.5;
|
||||
transform: initial;
|
||||
}
|
||||
|
||||
:is(button, .button).outlined {
|
||||
background-color: transparent;
|
||||
color: var(--theme);
|
||||
}
|
||||
|
||||
:is(button, .button).outlined-success {
|
||||
border-color: var(--theme-success);
|
||||
background-color: transparent;
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).tiny {
|
||||
font-size: var(--fonts-xs);
|
||||
padding-block: var(--s-1);
|
||||
padding-inline: var(--s-2);
|
||||
}
|
||||
|
||||
:is(button, .button).minimal {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme);
|
||||
outline: initial;
|
||||
}
|
||||
|
||||
:is(button, .button).minimal-success {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).success {
|
||||
border-color: var(--theme-success);
|
||||
background-color: var(--theme-success);
|
||||
outline-color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).destructive {
|
||||
border-color: var(--theme-error);
|
||||
background-color: transparent;
|
||||
color: var(--theme-error);
|
||||
outline-color: var(--theme-error);
|
||||
}
|
||||
|
||||
:is(button, .button).minimal-destructive {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme-error);
|
||||
outline-color: var(--theme-error);
|
||||
}
|
||||
|
||||
:is(button, .button).loading {
|
||||
cursor: not-allowed;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.button-icon {
|
||||
width: 1.25rem;
|
||||
margin-inline-end: var(--s-1-5);
|
||||
}
|
||||
|
||||
.button-icon.lonely {
|
||||
margin-inline-end: 0;
|
||||
}
|
||||
|
||||
:is(button, .button).tiny > .button-icon {
|
||||
width: 1rem;
|
||||
margin-inline-end: var(--s-1);
|
||||
}
|
||||
|
||||
textarea:not(.plain) {
|
||||
padding: var(--s-2-5) var(--s-3);
|
||||
border: 1px solid var(--border);
|
||||
accent-color: var(--theme-secondary);
|
||||
background-color: transparent;
|
||||
border-radius: var(--rounded);
|
||||
color: var(--text);
|
||||
font-size: var(--fonts-sm);
|
||||
outline: none;
|
||||
overflow-wrap: normal;
|
||||
overflow-x: scroll;
|
||||
white-space: pre;
|
||||
}
|
||||
|
||||
progress {
|
||||
accent-color: var(--theme);
|
||||
}
|
||||
|
||||
textarea:not(.plain):focus-within {
|
||||
border-color: transparent;
|
||||
|
||||
/* TODO: rectangle on Safari */
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
input:not(.plain) {
|
||||
height: 1rem;
|
||||
padding: var(--s-4) var(--s-3);
|
||||
border: 1px solid var(--border);
|
||||
accent-color: var(--theme-secondary);
|
||||
background-color: transparent;
|
||||
border-radius: var(--rounded);
|
||||
color: var(--text);
|
||||
font-size: var(--fonts-sm);
|
||||
outline: none;
|
||||
}
|
||||
|
||||
input:user-invalid {
|
||||
border-color: transparent;
|
||||
outline: 2px solid var(--theme-error);
|
||||
}
|
||||
|
||||
input:not(.plain):focus-within {
|
||||
border-color: transparent;
|
||||
|
||||
/* TODO: rectangle on Safari */
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
input:not(.plain)::placeholder {
|
||||
color: var(--text-lighter);
|
||||
font-size: var(--fonts-xxs);
|
||||
font-weight: var(--semi-bold);
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
input:not(.plain).error {
|
||||
border-color: transparent;
|
||||
outline: 2px solid var(--theme-error);
|
||||
}
|
||||
|
||||
input[type="checkbox"] {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
|
||||
label {
|
||||
display: block;
|
||||
font-size: var(--fonts-xs);
|
||||
font-weight: var(--bold);
|
||||
margin-block-end: var(--label-margin);
|
||||
}
|
||||
|
||||
details summary {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
fieldset {
|
||||
border: none;
|
||||
background-color: var(--bg-darker-transparent);
|
||||
border-radius: var(--rounded);
|
||||
font-size: var(--fonts-sm);
|
||||
padding-block-end: var(--s-3);
|
||||
padding-inline: var(--s-3);
|
||||
}
|
||||
|
||||
legend {
|
||||
background-color: transparent;
|
||||
border-radius: 2px;
|
||||
border-radius: var(--rounded-sm);
|
||||
font-size: var(--fonts-xs);
|
||||
font-weight: var(--bold);
|
||||
}
|
||||
|
||||
article {
|
||||
padding-inline: var(--s-3);
|
||||
white-space: pre-line;
|
||||
}
|
||||
|
||||
select {
|
||||
all: unset;
|
||||
width: 90%;
|
||||
border: 1px solid var(--border);
|
||||
background: var(--select-background, var(--bg-lighter));
|
||||
|
||||
/* TODO: Get color from CSS var */
|
||||
background-image: url('data:image/svg+xml;utf8,<svg width="1rem" color="rgb(255 255 255 / 55%)" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7" /></svg>');
|
||||
background-position-x: 92%;
|
||||
background-position-y: 50%;
|
||||
background-repeat: no-repeat;
|
||||
border-radius: var(--rounded);
|
||||
cursor: pointer;
|
||||
font-size: var(--fonts-sm);
|
||||
font-weight: 500;
|
||||
padding-block: 3.5px;
|
||||
padding-inline: var(--s-3);
|
||||
}
|
||||
|
||||
select::selection {
|
||||
overflow: hidden;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
select:focus {
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
hr {
|
||||
border-color: var(--theme-transparent);
|
||||
}
|
||||
|
||||
abbr:not([title]) {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
abbr[title] {
|
||||
cursor: help;
|
||||
}
|
||||
|
||||
dialog {
|
||||
width: min(90%, 24rem);
|
||||
border: 0;
|
||||
margin: auto;
|
||||
background-color: var(--bg);
|
||||
border-radius: var(--rounded);
|
||||
}
|
||||
|
||||
dialog::backdrop {
|
||||
background: hsla(237deg 98% 1% / 70%);
|
||||
}
|
||||
|
||||
@supports ((-webkit-backdrop-filter: none) or (backdrop-filter: none)) {
|
||||
dialog::backdrop {
|
||||
-webkit-backdrop-filter: blur(7px) brightness(70%);
|
||||
backdrop-filter: blur(7px) brightness(70%);
|
||||
background-color: transparent;
|
||||
}
|
||||
}
|
||||
|
||||
dialog[open],
|
||||
dialog::backdrop {
|
||||
animation: show 500ms ease;
|
||||
}
|
||||
|
||||
@keyframes show {
|
||||
0% {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.button-text-paragraph {
|
||||
display: flex;
|
||||
gap: var(--s-1);
|
||||
|
|
@ -192,81 +496,3 @@
|
|||
border-radius: var(--rounded);
|
||||
padding-inline: var(--s-1-5);
|
||||
}
|
||||
|
||||
/*
|
||||
*
|
||||
* Utility classes
|
||||
*
|
||||
*/
|
||||
|
||||
.text-sm {
|
||||
font-size: var(--fonts-sm);
|
||||
}
|
||||
|
||||
.text-xs {
|
||||
font-size: var(--fonts-xs);
|
||||
}
|
||||
|
||||
.text-center {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.text-lighter {
|
||||
color: var(--text-lighter);
|
||||
}
|
||||
|
||||
.text-error {
|
||||
color: var(--theme-error);
|
||||
}
|
||||
|
||||
.text-success {
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
.font-semi-bold {
|
||||
font-weight: var(--semi-bold);
|
||||
}
|
||||
|
||||
.w-full {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mt-2 {
|
||||
margin-block-start: var(--s-2);
|
||||
}
|
||||
|
||||
.mt-4 {
|
||||
margin-block-start: var(--s-4);
|
||||
}
|
||||
|
||||
.ml-auto {
|
||||
margin-inline-start: auto;
|
||||
}
|
||||
|
||||
.mx-auto {
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.hidden {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.invisible {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.items-center {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.justify-center {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.all-unset {
|
||||
all: unset;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,408 +0,0 @@
|
|||
:root {
|
||||
--bg: hsl(202deg 100% 96%);
|
||||
--bg-darker: hsl(202deg 90% 90%);
|
||||
--bg-lighter: hsl(225deg 100% 88%);
|
||||
--bg-lighter-transparent: hsla(225deg 100% 88% / 50%);
|
||||
--bg-darker-very-transparent: hsl(202deg 90% 90% / 50%);
|
||||
--bg-darker-transparent: hsla(202deg 90% 90% / 65%);
|
||||
--bg-badge: #000;
|
||||
--badge-text: rgb(255 255 255 / 95%);
|
||||
--border: hsl(237deg 100% 86%);
|
||||
--button-text: rgb(255 255 255 / 85%);
|
||||
--button-text-transparent: rgb(0 0 0 / 65%);
|
||||
--text: rgb(0 0 0 / 95%);
|
||||
--text-lighter: rgb(75 75 75 / 95%);
|
||||
--theme-error: rgb(199 13 6);
|
||||
--theme-error-transparent: rgba(199 13 6 / 75%);
|
||||
--theme-warning: #c9c900;
|
||||
--theme-success: #00a514;
|
||||
--theme-success-transparent: #00a51452;
|
||||
--theme: hsl(255deg 64% 63%);
|
||||
--theme-vibrant: hsl(255deg 100% 81%);
|
||||
--theme-transparent: hsl(255deg 66.7% 75% / 40%);
|
||||
--theme-very-transparent: hsl(255deg 66.7% 75% / 30%);
|
||||
--theme-transparent-vibrant: hsl(255deg 100% 81% / 54%);
|
||||
--theme-semi-transparent-vibrant: hsl(255deg 100% 81% / 75%);
|
||||
--theme-secondary: hsl(85deg 66.7% 55.3%);
|
||||
--rounded: 16px;
|
||||
--rounded-sm: 10px;
|
||||
--fonts-xl: 1.5rem;
|
||||
--fonts-lg: 1.2rem;
|
||||
--fonts-md: 1rem;
|
||||
--fonts-sm: 0.92rem;
|
||||
--fonts-xs: 0.8rem;
|
||||
--fonts-xxs: 0.7rem;
|
||||
--fonts-xxxs: 0.6rem;
|
||||
--fonts-xxxxs: 0.5rem;
|
||||
--extra-bold: 700;
|
||||
--bold: 600;
|
||||
--semi-bold: 500;
|
||||
--body: 400;
|
||||
--s-1: 0.25rem;
|
||||
--s-1-5: 0.375rem;
|
||||
--s-2: 0.5rem;
|
||||
--s-2-5: 0.625rem;
|
||||
--s-3: 0.75rem;
|
||||
--s-4: 1rem;
|
||||
--s-5: 1.25rem;
|
||||
--s-6: 1.5rem;
|
||||
--s-7: 1.75rem;
|
||||
--s-8: 2rem;
|
||||
--s-9: 2.25rem;
|
||||
--s-10: 2.5rem;
|
||||
--s-11: 2.75rem;
|
||||
--s-12: 3rem;
|
||||
--s-14: 3.5rem;
|
||||
--s-16: 4rem;
|
||||
--s-20: 5rem;
|
||||
--s-24: 6rem;
|
||||
--s-28: 7rem;
|
||||
--s-32: 8rem;
|
||||
--s-40: 10rem;
|
||||
--s-48: 12rem;
|
||||
--s-56: 14rem;
|
||||
--s-64: 16rem;
|
||||
--s-72: 18rem;
|
||||
--s-80: 20rem;
|
||||
--s-96: 2rem;
|
||||
--sparse: 0.4px;
|
||||
--label-margin: var(--s-1);
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
:root {
|
||||
--bg: hsl(237.3deg 42.3% 30.6%);
|
||||
--bg-darker: hsl(237.3deg 42.3% 26.6%);
|
||||
--bg-lighter: hsl(237.3deg 42.3% 35.6%);
|
||||
--bg-lighter-transparent: rgb(64 67 108 / 50%);
|
||||
--bg-darker-very-transparent: hsla(237.3deg 42.3% 26.6% / 50%);
|
||||
--bg-darker-transparent: hsla(237.3deg 42.3% 26.6% / 90%);
|
||||
--bg-badge: #000;
|
||||
--border: hsl(237.3deg 42.3% 45.6%);
|
||||
--button-text: rgb(0 0 0 / 85%);
|
||||
--button-text-transparent: rgb(0 0 0 / 65%);
|
||||
--text: rgb(255 255 255 / 95%);
|
||||
--text-lighter: rgb(255 255 255 / 55%);
|
||||
--theme-error: rgb(219 70 65);
|
||||
--theme-error-transparent: rgba(219 70 65 / 75%);
|
||||
--theme-warning: #f5f587;
|
||||
--theme-success: #a3ffae;
|
||||
--theme-success-transparent: #a3ffae52;
|
||||
--theme: hsl(255deg 66.7% 75%);
|
||||
--theme-vibrant: hsl(255deg 78% 65%);
|
||||
--theme-transparent: hsl(255deg 66.7% 75% / 40%);
|
||||
--theme-transparent-vibrant: hsl(255deg 78% 65% / 54%);
|
||||
--theme-semi-transparent-vibrant: hsl(255deg 78% 65% / 75%);
|
||||
--theme-secondary: hsl(85deg 66.7% 55.3%);
|
||||
}
|
||||
}
|
||||
|
||||
/* xs: "(min-width: 480px)",
|
||||
sm: "(min-width: 640px)",
|
||||
md: "(min-width: 768px)",
|
||||
lg: "(min-width: 1024px)",
|
||||
xl: "(min-width: 1280px)", */
|
||||
|
||||
*,
|
||||
*::before,
|
||||
*::after {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
width: 100%;
|
||||
background-color: var(--bg);
|
||||
color: var(--text);
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial,
|
||||
sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: antialiased;
|
||||
line-height: 1.55;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
|
||||
*:focus:not(:focus-visible) {
|
||||
outline: none !important;
|
||||
}
|
||||
|
||||
a {
|
||||
color: var(--theme);
|
||||
font-weight: var(--semi-bold);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
:is(button, .button) {
|
||||
display: flex;
|
||||
width: auto;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border: 2px solid var(--theme);
|
||||
appearance: none;
|
||||
background: var(--theme);
|
||||
border-radius: var(--rounded-sm);
|
||||
color: var(--button-text);
|
||||
cursor: pointer;
|
||||
font-size: var(--fonts-sm);
|
||||
font-weight: var(--bold);
|
||||
line-height: 1.2;
|
||||
outline-offset: 2px;
|
||||
padding-block: var(--s-1-5);
|
||||
padding-inline: var(--s-2-5);
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
:is(button, .button):focus-visible {
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
:is(button, .button):active {
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
:is(button, .button):disabled {
|
||||
cursor: not-allowed;
|
||||
opacity: 0.5;
|
||||
transform: initial;
|
||||
}
|
||||
|
||||
:is(button, .button).outlined {
|
||||
background-color: transparent;
|
||||
color: var(--theme);
|
||||
}
|
||||
|
||||
:is(button, .button).outlined-success {
|
||||
border-color: var(--theme-success);
|
||||
background-color: transparent;
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).tiny {
|
||||
font-size: var(--fonts-xs);
|
||||
padding-block: var(--s-1);
|
||||
padding-inline: var(--s-2);
|
||||
}
|
||||
|
||||
:is(button, .button).minimal {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme);
|
||||
outline: initial;
|
||||
}
|
||||
|
||||
:is(button, .button).minimal-success {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).success {
|
||||
border-color: var(--theme-success);
|
||||
background-color: var(--theme-success);
|
||||
outline-color: var(--theme-success);
|
||||
}
|
||||
|
||||
:is(button, .button).destructive {
|
||||
border-color: var(--theme-error);
|
||||
background-color: transparent;
|
||||
color: var(--theme-error);
|
||||
outline-color: var(--theme-error);
|
||||
}
|
||||
|
||||
:is(button, .button).minimal-destructive {
|
||||
padding: 0;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
color: var(--theme-error);
|
||||
outline-color: var(--theme-error);
|
||||
}
|
||||
|
||||
:is(button, .button).loading {
|
||||
cursor: not-allowed;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.button-icon {
|
||||
width: 1.25rem;
|
||||
margin-inline-end: var(--s-1-5);
|
||||
}
|
||||
|
||||
.button-icon.lonely {
|
||||
margin-inline-end: 0;
|
||||
}
|
||||
|
||||
:is(button, .button).tiny > .button-icon {
|
||||
width: 1rem;
|
||||
margin-inline-end: var(--s-1);
|
||||
}
|
||||
|
||||
textarea:not(.plain) {
|
||||
padding: var(--s-2-5) var(--s-3);
|
||||
border: 1px solid var(--border);
|
||||
accent-color: var(--theme-secondary);
|
||||
background-color: transparent;
|
||||
border-radius: var(--rounded);
|
||||
color: var(--text);
|
||||
font-size: var(--fonts-sm);
|
||||
outline: none;
|
||||
overflow-wrap: normal;
|
||||
overflow-x: scroll;
|
||||
white-space: pre;
|
||||
}
|
||||
|
||||
progress {
|
||||
accent-color: var(--theme);
|
||||
}
|
||||
|
||||
textarea:not(.plain):focus-within {
|
||||
border-color: transparent;
|
||||
|
||||
/* TODO: rectangle on Safari */
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
input:not(.plain) {
|
||||
height: 1rem;
|
||||
padding: var(--s-4) var(--s-3);
|
||||
border: 1px solid var(--border);
|
||||
accent-color: var(--theme-secondary);
|
||||
background-color: transparent;
|
||||
border-radius: var(--rounded);
|
||||
color: var(--text);
|
||||
font-size: var(--fonts-sm);
|
||||
outline: none;
|
||||
}
|
||||
|
||||
input:user-invalid {
|
||||
border-color: transparent;
|
||||
outline: 2px solid var(--theme-error);
|
||||
}
|
||||
|
||||
input:not(.plain):focus-within {
|
||||
border-color: transparent;
|
||||
|
||||
/* TODO: rectangle on Safari */
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
input:not(.plain)::placeholder {
|
||||
color: var(--text-lighter);
|
||||
font-size: var(--fonts-xxs);
|
||||
font-weight: var(--semi-bold);
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
input:not(.plain).error {
|
||||
border-color: transparent;
|
||||
outline: 2px solid var(--theme-error);
|
||||
}
|
||||
|
||||
input[type="checkbox"] {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
|
||||
label {
|
||||
display: block;
|
||||
font-size: var(--fonts-xs);
|
||||
font-weight: var(--bold);
|
||||
margin-block-end: var(--label-margin);
|
||||
}
|
||||
|
||||
details summary {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
fieldset {
|
||||
border: none;
|
||||
background-color: var(--bg-darker-transparent);
|
||||
border-radius: var(--rounded);
|
||||
font-size: var(--fonts-sm);
|
||||
padding-block-end: var(--s-3);
|
||||
padding-inline: var(--s-3);
|
||||
}
|
||||
|
||||
legend {
|
||||
background-color: transparent;
|
||||
border-radius: 2px;
|
||||
border-radius: var(--rounded-sm);
|
||||
font-size: var(--fonts-xs);
|
||||
font-weight: var(--bold);
|
||||
}
|
||||
|
||||
article {
|
||||
padding-inline: var(--s-3);
|
||||
white-space: pre-line;
|
||||
}
|
||||
|
||||
select {
|
||||
all: unset;
|
||||
width: 90%;
|
||||
border: 1px solid var(--border);
|
||||
background: var(--select-background, var(--bg-lighter));
|
||||
|
||||
/* TODO: Get color from CSS var */
|
||||
background-image: url('data:image/svg+xml;utf8,<svg width="1rem" color="rgb(255 255 255 / 55%)" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7" /></svg>');
|
||||
background-position-x: 92%;
|
||||
background-position-y: 50%;
|
||||
background-repeat: no-repeat;
|
||||
border-radius: var(--rounded);
|
||||
cursor: pointer;
|
||||
font-size: var(--fonts-sm);
|
||||
font-weight: 500;
|
||||
padding-block: 3.5px;
|
||||
padding-inline: var(--s-3);
|
||||
}
|
||||
|
||||
select::selection {
|
||||
overflow: hidden;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
select:focus {
|
||||
outline: 2px solid var(--theme);
|
||||
}
|
||||
|
||||
hr {
|
||||
border-color: var(--theme-transparent);
|
||||
}
|
||||
|
||||
abbr:not([title]) {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
abbr[title] {
|
||||
cursor: help;
|
||||
}
|
||||
|
||||
dialog {
|
||||
width: min(90%, 24rem);
|
||||
border: 0;
|
||||
margin: auto;
|
||||
background-color: var(--bg);
|
||||
border-radius: var(--rounded);
|
||||
}
|
||||
|
||||
dialog::backdrop {
|
||||
background: hsla(237deg 98% 1% / 70%);
|
||||
}
|
||||
|
||||
@supports ((-webkit-backdrop-filter: none) or (backdrop-filter: none)) {
|
||||
dialog::backdrop {
|
||||
-webkit-backdrop-filter: blur(7px) brightness(70%);
|
||||
backdrop-filter: blur(7px) brightness(70%);
|
||||
background-color: transparent;
|
||||
}
|
||||
}
|
||||
|
||||
dialog[open],
|
||||
dialog::backdrop {
|
||||
animation: show 500ms ease;
|
||||
}
|
||||
|
||||
@keyframes show {
|
||||
0% {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
71
app/styles/utils.css
Normal file
71
app/styles/utils.css
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
.text-sm {
|
||||
font-size: var(--fonts-sm);
|
||||
}
|
||||
|
||||
.text-xs {
|
||||
font-size: var(--fonts-xs);
|
||||
}
|
||||
|
||||
.text-center {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.text-lighter {
|
||||
color: var(--text-lighter);
|
||||
}
|
||||
|
||||
.text-error {
|
||||
color: var(--theme-error);
|
||||
}
|
||||
|
||||
.text-success {
|
||||
color: var(--theme-success);
|
||||
}
|
||||
|
||||
.font-semi-bold {
|
||||
font-weight: var(--semi-bold);
|
||||
}
|
||||
|
||||
.w-full {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mt-2 {
|
||||
margin-block-start: var(--s-2);
|
||||
}
|
||||
|
||||
.mt-4 {
|
||||
margin-block-start: var(--s-4);
|
||||
}
|
||||
|
||||
.ml-auto {
|
||||
margin-inline-start: auto;
|
||||
}
|
||||
|
||||
.mx-auto {
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.hidden {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.invisible {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.items-center {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.justify-center {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.all-unset {
|
||||
all: unset;
|
||||
}
|
||||
104
app/styles/vars.css
Normal file
104
app/styles/vars.css
Normal file
|
|
@ -0,0 +1,104 @@
|
|||
:root {
|
||||
--bg: hsl(202deg 100% 96%);
|
||||
--bg-darker: hsl(202deg 90% 90%);
|
||||
--bg-lighter: hsl(225deg 100% 88%);
|
||||
--bg-lighter-transparent: hsla(225deg 100% 88% / 50%);
|
||||
--bg-darker-very-transparent: hsl(202deg 90% 90% / 50%);
|
||||
--bg-darker-transparent: hsla(202deg 90% 90% / 65%);
|
||||
--bg-badge: #000;
|
||||
--badge-text: rgb(255 255 255 / 95%);
|
||||
--border: hsl(237deg 100% 86%);
|
||||
--button-text: rgb(255 255 255 / 85%);
|
||||
--button-text-transparent: rgb(0 0 0 / 65%);
|
||||
--text: rgb(0 0 0 / 95%);
|
||||
--text-lighter: rgb(75 75 75 / 95%);
|
||||
--theme-error: rgb(199 13 6);
|
||||
--theme-error-transparent: rgba(199 13 6 / 75%);
|
||||
--theme-warning: #c9c900;
|
||||
--theme-success: #00a514;
|
||||
--theme-success-transparent: #00a51452;
|
||||
--theme: hsl(255deg 64% 63%);
|
||||
--theme-vibrant: hsl(255deg 100% 81%);
|
||||
--theme-transparent: hsl(255deg 66.7% 75% / 40%);
|
||||
--theme-very-transparent: hsl(255deg 66.7% 75% / 30%);
|
||||
--theme-transparent-vibrant: hsl(255deg 100% 81% / 54%);
|
||||
--theme-semi-transparent-vibrant: hsl(255deg 100% 81% / 75%);
|
||||
--theme-secondary: hsl(85deg 66.7% 55.3%);
|
||||
--rounded: 16px;
|
||||
--rounded-sm: 10px;
|
||||
--fonts-xl: 1.5rem;
|
||||
--fonts-lg: 1.2rem;
|
||||
--fonts-md: 1rem;
|
||||
--fonts-sm: 0.92rem;
|
||||
--fonts-xs: 0.8rem;
|
||||
--fonts-xxs: 0.7rem;
|
||||
--fonts-xxxs: 0.6rem;
|
||||
--fonts-xxxxs: 0.5rem;
|
||||
--extra-bold: 700;
|
||||
--bold: 600;
|
||||
--semi-bold: 500;
|
||||
--body: 400;
|
||||
--s-1: 0.25rem;
|
||||
--s-1-5: 0.375rem;
|
||||
--s-2: 0.5rem;
|
||||
--s-2-5: 0.625rem;
|
||||
--s-3: 0.75rem;
|
||||
--s-4: 1rem;
|
||||
--s-5: 1.25rem;
|
||||
--s-6: 1.5rem;
|
||||
--s-7: 1.75rem;
|
||||
--s-8: 2rem;
|
||||
--s-9: 2.25rem;
|
||||
--s-10: 2.5rem;
|
||||
--s-11: 2.75rem;
|
||||
--s-12: 3rem;
|
||||
--s-14: 3.5rem;
|
||||
--s-16: 4rem;
|
||||
--s-20: 5rem;
|
||||
--s-24: 6rem;
|
||||
--s-28: 7rem;
|
||||
--s-32: 8rem;
|
||||
--s-40: 10rem;
|
||||
--s-48: 12rem;
|
||||
--s-56: 14rem;
|
||||
--s-64: 16rem;
|
||||
--s-72: 18rem;
|
||||
--s-80: 20rem;
|
||||
--s-96: 2rem;
|
||||
--sparse: 0.4px;
|
||||
--label-margin: var(--s-1);
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
:root {
|
||||
--bg: hsl(237.3deg 42.3% 30.6%);
|
||||
--bg-darker: hsl(237.3deg 42.3% 26.6%);
|
||||
--bg-lighter: hsl(237.3deg 42.3% 35.6%);
|
||||
--bg-lighter-transparent: rgb(64 67 108 / 50%);
|
||||
--bg-darker-very-transparent: hsla(237.3deg 42.3% 26.6% / 50%);
|
||||
--bg-darker-transparent: hsla(237.3deg 42.3% 26.6% / 90%);
|
||||
--bg-badge: #000;
|
||||
--border: hsl(237.3deg 42.3% 45.6%);
|
||||
--button-text: rgb(0 0 0 / 85%);
|
||||
--button-text-transparent: rgb(0 0 0 / 65%);
|
||||
--text: rgb(255 255 255 / 95%);
|
||||
--text-lighter: rgb(255 255 255 / 55%);
|
||||
--theme-error: rgb(219 70 65);
|
||||
--theme-error-transparent: rgba(219 70 65 / 75%);
|
||||
--theme-warning: #f5f587;
|
||||
--theme-success: #a3ffae;
|
||||
--theme-success-transparent: #a3ffae52;
|
||||
--theme: hsl(255deg 66.7% 75%);
|
||||
--theme-vibrant: hsl(255deg 78% 65%);
|
||||
--theme-transparent: hsl(255deg 66.7% 75% / 40%);
|
||||
--theme-transparent-vibrant: hsl(255deg 78% 65% / 54%);
|
||||
--theme-semi-transparent-vibrant: hsl(255deg 78% 65% / 75%);
|
||||
--theme-secondary: hsl(85deg 66.7% 55.3%);
|
||||
}
|
||||
}
|
||||
|
||||
/* xs: "(min-width: 480px)",
|
||||
sm: "(min-width: 640px)",
|
||||
md: "(min-width: 768px)",
|
||||
lg: "(min-width: 1024px)",
|
||||
xl: "(min-width: 1280px)", */
|
||||
Loading…
Reference in New Issue
Block a user