diff --git a/package.json b/package.json
index a6daabf2..5b5b6f57 100644
--- a/package.json
+++ b/package.json
@@ -13,8 +13,10 @@
},
"scripts": {
"dev": "npm-run-all --parallel vite typesafe-i18n",
+ "dev:external": "npm-run-all --parallel vite:external typesafe-i18n",
"dev:tauri": "tauri dev",
"vite": "vite dev",
+ "vite:external": "vite --host",
"build": "typesafe-i18n --no-watch && vite build",
"build:tauri": "tauri build",
"tauri": "tauri",
diff --git a/src/lib/components/ActionListItem.svelte b/src/lib/components/ActionListItem.svelte
index 241cb86d..4693cb66 100644
--- a/src/lib/components/ActionListItem.svelte
+++ b/src/lib/components/ActionListItem.svelte
@@ -48,16 +48,28 @@
padding: 8px;
font-family: "Noto Sans Mono", monospace;
- color: inherit;
-
- background: transparent;
- border: none;
border-radius: 8px;
- &:focus-visible {
- color: var(--md-sys-color-on-surface-variant);
- background: var(--md-sys-color-surface-variant);
- outline: none;
+ @media not (forced-colors: active) {
+ color: inherit;
+
+ background: transparent;
+ border: none;
+
+ &:focus-visible {
+ color: var(--md-sys-color-on-surface-variant);
+ background: var(--md-sys-color-surface-variant);
+ outline: none;
+ }
+ }
+
+ @media (forced-colors: active) {
+ border: 1px solid ButtonBorder;
+ margin-block: 4px;
+
+ &:hover {
+ color: ActiveText;
+ }
}
}
diff --git a/src/lib/components/layout/ActionSelector.svelte b/src/lib/components/layout/ActionSelector.svelte
index 022dee77..b0e39301 100644
--- a/src/lib/components/layout/ActionSelector.svelte
+++ b/src/lib/components/layout/ActionSelector.svelte
@@ -186,6 +186,7 @@
height: 100%;
background: rgba(0 0 0 / 60%);
+
border: none;
}
@@ -211,6 +212,11 @@
@media (prefers-contrast: more) {
opacity: 0.8;
}
+
+ @media (forced-colors: active) {
+ opacity: 1;
+ color: GrayText;
+ }
}
.search-row {
@@ -235,6 +241,10 @@
background: var(--md-sys-color-background);
border-radius: 16px;
+
+ @media (forced-colors: active) {
+ border: 1px solid CanvasText;
+ }
}
input[type="search"] {
@@ -302,5 +312,9 @@
background: var(--md-sys-color-primary);
border-radius: 0 0 8px 8px;
}
+
+ @media (forced-colors: active) {
+ background: Mark;
+ }
}
diff --git a/src/lib/style/form/_button.scss b/src/lib/style/form/_button.scss
index 62e83103..d297ddf2 100644
--- a/src/lib/style/form/_button.scss
+++ b/src/lib/style/form/_button.scss
@@ -19,10 +19,23 @@ button {
font-family: inherit;
font-weight: 600;
- color: currentcolor;
- background: transparent;
- border: none;
+ @media not (forced-colors: active) {
+ color: currentcolor;
+ background: transparent;
+ border: none;
+
+ &.primary {
+ color: var(--md-sys-color-on-primary);
+ background: var(--md-sys-color-primary);
+ }
+ }
+
+ @media (forced-colors: active) {
+ border: 1px solid ButtonBorder;
+ color: ButtonText;
+ }
+
border-radius: 32px;
transition: all 250ms ease;
@@ -37,11 +50,11 @@ button {
font-size: 24px;
border-radius: 50%;
- }
- &.primary {
- color: var(--md-sys-color-on-primary);
- background: var(--md-sys-color-primary);
+ @media (forced-colors: active) {
+ padding: 2px;
+ margin: 2px;
+ }
}
&.compact {
@@ -49,27 +62,48 @@ button {
}
}
-label:has(input):hover,
-.button:hover:not(:active),
-a:hover:not(:active),
-button:hover:not(:active) {
- filter: brightness(70%);
- transition: filter 250ms ease;
+@media not (forced-colors: active) {
+ label:has(input):hover,
+ .button:hover:not(:active),
+ a:hover:not(:active),
+ button:hover:not(:active) {
+ filter: brightness(70%);
+ transition: filter 250ms ease;
- &:has(:checked),
- &.active {
- filter: brightness(120%);
+ &:has(:checked),
+ &.active {
+ filter: brightness(120%);
+ }
+
+ &:disabled,
+ &.disabled {
+ opacity: 0.5;
+ filter: none;
+ }
}
+}
- &:disabled,
- &.disabled {
- opacity: 0.5;
- filter: none;
+@media (forced-colors: active) {
+ label:has(input) .button,
+ a button {
+ &:hover {
+ color: ActiveText;
+ }
+ &.active,
+ &:active {
+ color: SelectedItemText;
+ background: SelectedItem;
+ }
}
}
.disabled,
:disabled {
pointer-events: none;
- opacity: 0.5;
+ @media not (forced-colors: active) {
+ opacity: 0.5;
+ }
+ @media (forced-colors: active) {
+ color: GrayText;
+ }
}
diff --git a/src/lib/style/scrollbar.scss b/src/lib/style/scrollbar.scss
index 4fe1a666..b940575b 100644
--- a/src/lib/style/scrollbar.scss
+++ b/src/lib/style/scrollbar.scss
@@ -1,23 +1,25 @@
-::-webkit-scrollbar {
- width: 8px;
- background: transparent;
- border-radius: 4px;
-}
-
-::-webkit-scrollbar-thumb {
- background: var(--scrollbar-color, white);
- border-radius: 4px;
- transition: all 250ms ease;
-
- &:hover {
- filter: brightness(120%);
+@media not (forced-colors: active) {
+ ::-webkit-scrollbar {
+ width: 8px;
+ background: transparent;
+ border-radius: 4px;
}
- &:active {
- filter: brightness(80%);
+ ::-webkit-scrollbar-thumb {
+ background: var(--scrollbar-color, white);
+ border-radius: 4px;
+ transition: all 250ms ease;
+
+ &:hover {
+ filter: brightness(120%);
+ }
+
+ &:active {
+ filter: brightness(80%);
+ }
+ }
+
+ ::-webkit-resizer {
+ display: none;
}
}
-
-::-webkit-resizer {
- display: none;
-}
diff --git a/src/lib/style/tippy.scss b/src/lib/style/tippy.scss
index 4e58e978..2b442741 100644
--- a/src/lib/style/tippy.scss
+++ b/src/lib/style/tippy.scss
@@ -22,6 +22,17 @@ $padding: 16px;
border-#{$placement}-color: var(--md-sys-color-surface-variant);
}
}
+
+ @media (forced-colors: active) {
+ color: CanvasText;
+ background-color: Canvas;
+ filter: none;
+ border: 1px solid CanvasText;
+
+ > .tippy-arrow {
+ display: none;
+ }
+ }
}
.tippy-box[data-theme~="tooltip"] {
diff --git a/src/routes/Footer.svelte b/src/routes/Footer.svelte
index 691be139..c1c568a0 100644
--- a/src/routes/Footer.svelte
+++ b/src/routes/Footer.svelte
@@ -66,10 +66,10 @@