fix: some browser hsl function compatibility issues

This commit is contained in:
vben 2024-07-13 22:55:13 +08:00
parent 91058c3ed9
commit 31fd19f17a
3 changed files with 16 additions and 16 deletions

View File

@ -72,25 +72,25 @@ const BUILT_IN_THEME_PRESETS: BuiltinThemePreset[] = [
},
{
color: 'hsl(240 5% 26%)',
darkPrimaryColor: 'hsl(0 0 98%)',
darkPrimaryColor: 'hsl(0 0% 98%)',
primaryColor: 'hsl(240 5.9% 10%)',
type: 'zinc',
},
{
color: 'hsl(0 0% 25%)',
darkPrimaryColor: 'hsl(0 0 98%)',
darkPrimaryColor: 'hsl(0 0% 98%)',
primaryColor: 'hsl(240 5.9% 10%)',
type: 'neutral',
},
{
color: 'hsl(215 25% 27%)',
darkPrimaryColor: 'hsl(0 0 98%)',
darkPrimaryColor: 'hsl(0 0% 98%)',
primaryColor: 'hsl(240 5.9% 10%)',
type: 'slate',
},
{
color: 'hsl(217 19% 27%)',
darkPrimaryColor: 'hsl(0 0 98%)',
darkPrimaryColor: 'hsl(0 0% 98%)',
primaryColor: 'hsl(240 5.9% 10%)',
type: 'gray',
},

View File

@ -22,31 +22,31 @@
/* 主题颜色 */
/* --primary: 245 82% 67%; */
--primary-foreground: 0 0 98%;
--primary-foreground: 0 0% 98%;
/* Used for destructive actions such as <Button variant="destructive"> */
--destructive: 0 78% 68%;
--destructive-foreground: 0 0 98%;
--destructive-foreground: 0 0% 98%;
/* Used for success actions such as <message> */
--success: 144 57% 58%;
--success-foreground: 0 0 98%;
--success-foreground: 0 0% 98%;
/* Used for warning actions such as <message> */
--warning: 42 84% 61%;
--warning-foreground: 0 0 98%;
--warning-foreground: 0 0% 98%;
/* 颜色次要 */
--secondary: 240 5% 17%;
--secondary-foreground: 0 0 98%;
--secondary-foreground: 0 0% 98%;
/* Used for accents such as hover effects on <DropdownMenuItem>, <SelectItem>...etc */
--accent: 0deg 0% 100% / 8%;
--accent-hover: 0deg 0% 100% / 12%;
--accent-foreground: 0 0 98%;
--accent-foreground: 0 0% 98%;
/* Darker color */
--heavy: 0deg 0% 100% / 12%;

View File

@ -5,7 +5,7 @@
'Segoe UI Symbol';
/* Default background color of <body />...etc */
--background: 0 0 100%;
--background: 0 0% 100%;
--foreground: 210 6% 21%;
/* Background color for <Card /> */
@ -23,22 +23,22 @@
/* 主题颜色 */
--primary: 211 91% 39%;
--primary-foreground: 0 0 98%;
--primary-foreground: 0 0% 98%;
/* Used for destructive actions such as <Button variant="destructive"> */
--destructive: 0 78% 68%;
--destructive-foreground: 0 0 98%;
--destructive-foreground: 0 0% 98%;
/* Used for success actions such as <message> */
--success: 144 57% 58%;
--success-foreground: 0 0 98%;
--success-foreground: 0 0% 98%;
/* Used for warning actions such as <message> */
--warning: 42 84% 61%;
--warning-foreground: 0 0 98%;
--warning-foreground: 0 0% 98%;
/* Secondary colors for <Button /> */
@ -60,7 +60,7 @@
/* Border color for inputs such as <Input />, <Select />, <Textarea /> */
--input: 240deg 5.88% 90%;
--input-placeholder: 217 10.6% 65%;
--input-background: 0 0 100%;
--input-background: 0 0% 100%;
/* Used for focus ring */
--ring: 222.2 84% 4.9%;