ui(colors): Adds neutral color variable and updates scrollbars (#4933)

This commit is contained in:
Dan Rukas authored and GitHub committed 2025-04-08 09:43:30 -04:00
1 parent cfa202e89a
commit 49c08298fc
7 files changed
+14 -7

No files matched your search

@@ -114,7 +114,7 @@ const ScrollBar = React.forwardRef<
)}
{...props}
>
<ScrollAreaPrimitive.ScrollAreaThumb className="bg-input relative flex-1 rounded-full" />
<ScrollAreaPrimitive.ScrollAreaThumb className="bg-neutral/50 relative flex-1 rounded-full" />
</ScrollAreaPrimitive.ScrollAreaScrollbar>
));
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
@@ -32,7 +32,8 @@
/* Thumb styles for WebKit browsers - more specific selector */
input[type='range'].scrollbarInput::-webkit-slider-thumb {
-webkit-appearance: none !important;
background-color: hsl(var(--input));
background-color: hsl(var(--neutral));
opacity: 50%;
border: none;
border-radius: 57px;
cursor: -webkit-grab;
@@ -44,12 +45,14 @@ input[type='range'].scrollbarInput::-webkit-slider-thumb {
input[type='range'].scrollbarInput::-webkit-slider-thumb:active,
input[type='range'].scrollbarInput::-webkit-slider-thumb:hover {
background-color: hsl(var(--primary));
opacity: 60%;
cursor: -webkit-grabbing;
}
/* Thumb styles for Firefox - more specific selector */
input[type='range'].scrollbarInput::-moz-range-thumb {
background-color: hsl(var(--input));
background-color: hsl(var(--neutral));
opacity: 50%;
border: none;
border-radius: 57px;
cursor: -moz-grab;
@@ -60,6 +63,7 @@ input[type='range'].scrollbarInput::-moz-range-thumb {
input[type='range'].scrollbarInput::-moz-range-thumb:active,
input[type='range'].scrollbarInput::-moz-range-thumb:hover {
background-color: hsl(var(--primary));
opacity: 50%;
cursor: -moz-grabbing;
}
+2 -1
View File
@@ -9,6 +9,7 @@
@layer base {
:root {
--highlight: 191 74% 63%;
--neutral: 213 22% 59%;
--background: 236 62% 5%;
--foreground: 0 0% 98%;
--card: 234 64% 10%;
@@ -252,4 +253,4 @@ input[type='number']::-webkit-outer-spin-button {
input[type='number'] {
-moz-appearance: textfield; /* For Firefox */
}
}
+1
View File
@@ -44,6 +44,7 @@ module.exports = {
extend: {
colors: {
highlight: 'hsl(var(--highlight))',
neutral: 'hsl(var(--neutral))',
border: 'hsl(var(--border))',
input: 'hsl(var(--input))',
ring: 'hsl(var(--ring))',