Skip to content

best way to save what you love

web/Omnibox: workarounds for border rendering bugs in browsers

wukko7e9b7542acaf
diff --git a/web/src/components/save/Omnibox.svelte b/web/src/components/save/Omnibox.svelte
index 17e2f83a..1b2fe2ed 100644
--- a/web/src/components/save/Omnibox.svelte
+++ b/web/src/components/save/Omnibox.svelte
@@ -231,6 +231,10 @@
--input-padding: 10px;
display: flex;
box-shadow: 0 0 0 1.5px var(--input-border) inset;
+ /* webkit can't render the 1.5px box shadow properly,
+ so we duplicate the border as outline to fix it visually */
+ outline: 1.5px solid var(--input-border);
+ outline-offset: -1.5px;
border-radius: var(--border-radius);
align-items: center;
gap: var(--input-padding);
@@ -264,8 +268,9 @@
}
#input-container.focused {
- box-shadow: 0 0 0 1px var(--secondary) inset;
- outline: var(--secondary) 1px solid;
+ box-shadow: none;
+ outline: var(--secondary) 2px solid;
+ outline-offset: -1px;
}
#input-container.focused :global(#input-icons svg) {