@redis-ui/styles 21.0.0 → 21.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1386 -1272
- package/dist/index.umd.cjs +9 -9
- package/dist/themes/themeDark/theme/components/button.js +21 -0
- package/dist/themes/themeDark/theme/components/gauge.d.ts +3 -0
- package/dist/themes/themeDark/theme/components/gauge.js +38 -0
- package/dist/themes/themeDark/theme.js +2 -0
- package/dist/themes/themeLight/theme/components/button.js +21 -0
- package/dist/themes/themeLight/theme/components/gauge.d.ts +3 -0
- package/dist/themes/themeLight/theme/components/gauge.js +38 -0
- package/dist/themes/themeLight/theme.js +2 -0
- package/dist/themes/types/theme/components/button.types.d.ts +1 -1
- package/dist/themes/types/theme/components/gauge.types.d.ts +21 -0
- package/dist/themes/types/theme/components/gauge.types.js +1 -0
- package/dist/themes/types/theme/components/index.d.ts +1 -0
- package/dist/themes/types/theme/components/index.js +1 -0
- package/dist/themes/types/theme/theme.types.d.ts +2 -1
- package/package.json +1 -1
|
@@ -196,6 +196,27 @@ const theme = {
|
|
|
196
196
|
borderColor: tokens.semantic.color.border.neutral200,
|
|
197
197
|
textColor: tokens.semantic.color.text.neutral400
|
|
198
198
|
}
|
|
199
|
+
},
|
|
200
|
+
notice: {
|
|
201
|
+
normal: {
|
|
202
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice500} 0%, ${tokens.semantic.color.background.notice400} 78%)`,
|
|
203
|
+
textColor: tokens.semantic.color.text.secondary0,
|
|
204
|
+
borderColor: tokens.semantic.color.border.notice600
|
|
205
|
+
},
|
|
206
|
+
hover: {
|
|
207
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice500} 0%, ${tokens.semantic.color.background.notice500} 78%)`,
|
|
208
|
+
borderColor: tokens.semantic.color.border.notice600
|
|
209
|
+
},
|
|
210
|
+
active: {
|
|
211
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice600} 0%, ${tokens.semantic.color.background.notice600} 78%)`,
|
|
212
|
+
borderColor: tokens.semantic.color.border.notice700
|
|
213
|
+
},
|
|
214
|
+
disabled: {
|
|
215
|
+
bgGradient: 'unset',
|
|
216
|
+
bgColor: tokens.semantic.color.background.secondary800,
|
|
217
|
+
borderColor: tokens.semantic.color.border.secondary700,
|
|
218
|
+
textColor: tokens.semantic.color.text.secondary600
|
|
219
|
+
}
|
|
199
220
|
}
|
|
200
221
|
}
|
|
201
222
|
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { tokens } from '../../tokens';
|
|
2
|
+
const theme = {
|
|
3
|
+
variant: {
|
|
4
|
+
success: {
|
|
5
|
+
arcColor: tokens.semantic.color.background.success300,
|
|
6
|
+
trackColor: tokens.semantic.color.background.success700,
|
|
7
|
+
textColor: tokens.semantic.color.text.success300
|
|
8
|
+
},
|
|
9
|
+
attention: {
|
|
10
|
+
arcColor: tokens.semantic.color.background.attention200,
|
|
11
|
+
trackColor: tokens.semantic.color.background.attention600,
|
|
12
|
+
textColor: tokens.semantic.color.text.attention300
|
|
13
|
+
},
|
|
14
|
+
danger: {
|
|
15
|
+
arcColor: tokens.semantic.color.background.danger200,
|
|
16
|
+
trackColor: tokens.semantic.color.background.danger500,
|
|
17
|
+
textColor: tokens.semantic.color.text.danger300
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
size: {
|
|
21
|
+
S: {
|
|
22
|
+
diameter: '4rem',
|
|
23
|
+
strokeWidth: '12',
|
|
24
|
+
fontSize: tokens.core.font.fontSize.s10
|
|
25
|
+
},
|
|
26
|
+
M: {
|
|
27
|
+
diameter: '5.3rem',
|
|
28
|
+
strokeWidth: '11',
|
|
29
|
+
fontSize: tokens.core.font.fontSize.s12
|
|
30
|
+
},
|
|
31
|
+
L: {
|
|
32
|
+
diameter: '7.2rem',
|
|
33
|
+
strokeWidth: '10',
|
|
34
|
+
fontSize: tokens.core.font.fontSize.s16
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
export default theme;
|
|
@@ -18,6 +18,7 @@ import countryFlag from './theme/components/countryFlag';
|
|
|
18
18
|
import drawer from './theme/components/drawer';
|
|
19
19
|
import filters from './theme/components/filters';
|
|
20
20
|
import formField from './theme/components/formField';
|
|
21
|
+
import gauge from './theme/components/gauge';
|
|
21
22
|
import highlightedIcon from './theme/components/highlightedIcon';
|
|
22
23
|
import icon from './theme/components/icon';
|
|
23
24
|
import iconButton from './theme/components/iconButton';
|
|
@@ -84,6 +85,7 @@ export const theme = {
|
|
|
84
85
|
drawer,
|
|
85
86
|
filters,
|
|
86
87
|
formField,
|
|
88
|
+
gauge,
|
|
87
89
|
highlightedIcon,
|
|
88
90
|
icon,
|
|
89
91
|
iconButton,
|
|
@@ -196,6 +196,27 @@ const theme = {
|
|
|
196
196
|
borderColor: tokens.semantic.color.border.neutral200,
|
|
197
197
|
textColor: tokens.semantic.color.text.neutral400
|
|
198
198
|
}
|
|
199
|
+
},
|
|
200
|
+
notice: {
|
|
201
|
+
normal: {
|
|
202
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice500} 0%, ${tokens.semantic.color.background.notice400} 78%)`,
|
|
203
|
+
textColor: tokens.semantic.color.text.secondary0,
|
|
204
|
+
borderColor: tokens.semantic.color.border.notice600
|
|
205
|
+
},
|
|
206
|
+
hover: {
|
|
207
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice500} 0%, ${tokens.semantic.color.background.notice500} 78%)`,
|
|
208
|
+
borderColor: tokens.semantic.color.border.notice600
|
|
209
|
+
},
|
|
210
|
+
active: {
|
|
211
|
+
bgGradient: `linear-gradient(316deg, ${tokens.semantic.color.background.notice600} 0%, ${tokens.semantic.color.background.notice600} 78%)`,
|
|
212
|
+
borderColor: tokens.semantic.color.border.notice700
|
|
213
|
+
},
|
|
214
|
+
disabled: {
|
|
215
|
+
bgGradient: 'unset',
|
|
216
|
+
bgColor: tokens.semantic.color.background.neutral100,
|
|
217
|
+
borderColor: tokens.semantic.color.border.neutral200,
|
|
218
|
+
textColor: tokens.semantic.color.text.neutral400
|
|
219
|
+
}
|
|
199
220
|
}
|
|
200
221
|
}
|
|
201
222
|
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { tokens } from '../../tokens';
|
|
2
|
+
const theme = {
|
|
3
|
+
variant: {
|
|
4
|
+
success: {
|
|
5
|
+
arcColor: tokens.semantic.color.background.success600,
|
|
6
|
+
trackColor: tokens.semantic.color.background.success50,
|
|
7
|
+
textColor: tokens.semantic.color.text.success600
|
|
8
|
+
},
|
|
9
|
+
attention: {
|
|
10
|
+
arcColor: tokens.semantic.color.background.attention400,
|
|
11
|
+
trackColor: tokens.semantic.color.background.attention50,
|
|
12
|
+
textColor: tokens.semantic.color.text.attention400
|
|
13
|
+
},
|
|
14
|
+
danger: {
|
|
15
|
+
arcColor: tokens.semantic.color.background.danger500,
|
|
16
|
+
trackColor: tokens.semantic.color.background.danger50,
|
|
17
|
+
textColor: tokens.semantic.color.text.danger500
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
size: {
|
|
21
|
+
S: {
|
|
22
|
+
diameter: '4rem',
|
|
23
|
+
strokeWidth: '12',
|
|
24
|
+
fontSize: tokens.core.font.fontSize.s10
|
|
25
|
+
},
|
|
26
|
+
M: {
|
|
27
|
+
diameter: '5.3rem',
|
|
28
|
+
strokeWidth: '11',
|
|
29
|
+
fontSize: tokens.core.font.fontSize.s12
|
|
30
|
+
},
|
|
31
|
+
L: {
|
|
32
|
+
diameter: '7.2rem',
|
|
33
|
+
strokeWidth: '10',
|
|
34
|
+
fontSize: tokens.core.font.fontSize.s16
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
export default theme;
|
|
@@ -18,6 +18,7 @@ import countryFlag from './theme/components/countryFlag';
|
|
|
18
18
|
import drawer from './theme/components/drawer';
|
|
19
19
|
import filters from './theme/components/filters';
|
|
20
20
|
import formField from './theme/components/formField';
|
|
21
|
+
import gauge from './theme/components/gauge';
|
|
21
22
|
import highlightedIcon from './theme/components/highlightedIcon';
|
|
22
23
|
import icon from './theme/components/icon';
|
|
23
24
|
import iconButton from './theme/components/iconButton';
|
|
@@ -84,6 +85,7 @@ export const theme = {
|
|
|
84
85
|
drawer,
|
|
85
86
|
filters,
|
|
86
87
|
formField,
|
|
88
|
+
gauge,
|
|
87
89
|
highlightedIcon,
|
|
88
90
|
icon,
|
|
89
91
|
iconButton,
|
|
@@ -6,7 +6,7 @@ export type ButtonStateColors = {
|
|
|
6
6
|
textColor: string;
|
|
7
7
|
borderColor?: string;
|
|
8
8
|
};
|
|
9
|
-
type ButtonVariants = 'primary' | 'destructive' | 'secondary-fill' | 'secondary-invert' | 'secondary-ghost' | 'upsell' | 'upsell-invert' | 'upsell-ghost';
|
|
9
|
+
type ButtonVariants = 'primary' | 'destructive' | 'secondary-fill' | 'secondary-invert' | 'secondary-ghost' | 'upsell' | 'upsell-invert' | 'upsell-ghost' | 'notice';
|
|
10
10
|
type ButtonSizes = 'large' | 'medium' | 'small';
|
|
11
11
|
export type ButtonTheme = {
|
|
12
12
|
gap: string;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export type GaugeVariant = 'success' | 'attention' | 'danger';
|
|
2
|
+
export type GaugeSize = 'S' | 'M' | 'L';
|
|
3
|
+
export interface GaugeVariantProperties {
|
|
4
|
+
arcColor: string;
|
|
5
|
+
trackColor: string;
|
|
6
|
+
textColor: string;
|
|
7
|
+
}
|
|
8
|
+
export interface GaugeSizeProperties {
|
|
9
|
+
/** Rendered diameter of the gauge. */
|
|
10
|
+
diameter: string;
|
|
11
|
+
/** Ring thickness, expressed in SVG viewBox units (0-100). */
|
|
12
|
+
strokeWidth: string;
|
|
13
|
+
/** Font size of the centered label. */
|
|
14
|
+
fontSize: string;
|
|
15
|
+
}
|
|
16
|
+
export type GaugeVariantStyles = Record<GaugeVariant, GaugeVariantProperties>;
|
|
17
|
+
export type GaugeSizeStyles = Record<GaugeSize, GaugeSizeProperties>;
|
|
18
|
+
export interface GaugeTheme {
|
|
19
|
+
variant: GaugeVariantStyles;
|
|
20
|
+
size: GaugeSizeStyles;
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -16,6 +16,7 @@ export * from './countryFlag.types';
|
|
|
16
16
|
export * from './drawer.types';
|
|
17
17
|
export * from './filters.types';
|
|
18
18
|
export * from './formField.types';
|
|
19
|
+
export * from './gauge.types';
|
|
19
20
|
export * from './global.types';
|
|
20
21
|
export * from './highlightedIcon.types';
|
|
21
22
|
export * from './icon.types';
|
|
@@ -16,6 +16,7 @@ export * from './countryFlag.types';
|
|
|
16
16
|
export * from './drawer.types';
|
|
17
17
|
export * from './filters.types';
|
|
18
18
|
export * from './formField.types';
|
|
19
|
+
export * from './gauge.types';
|
|
19
20
|
export * from './global.types';
|
|
20
21
|
export * from './highlightedIcon.types';
|
|
21
22
|
export * from './icon.types';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Tokens } from './tokens.types';
|
|
2
|
-
import { ActionIconButtonTheme, AppBarTheme, AppSelectionMenuTheme, AutoCompleteTheme, BadgeTheme, BannerTheme, BoxSelectionGroupTheme, BreadcrumbsTheme, ButtonGroupTheme, ButtonTheme, CardTheme, CheckboxTheme, ChipListTheme, ChipTheme, CountryFlagTheme, DrawerTheme, FiltersTheme, FormFieldTheme, HighlightedIconTheme, IconTheme, IconButtonTheme, InputTheme, KeyValueListTheme, LabelTheme, LayoutsTheme, LinkTheme, LoaderTheme, MenuTheme, MidBarTheme, ModalTheme, MoreInfoIconTheme, PopoverTheme, PopupCardTheme, ProfileIconTheme, ProgressBarTheme, RadioTheme, SearchBarTheme, SectionTheme, SelectTheme, SemanticButtonTheme, SemanticContainerTheme, SemanticIconTheme, SideBarTheme, SkeletonTheme, SliderTheme, StepperTheme, SwitchTheme, TableHeadingTheme, TableTheme, TabsTheme, TextButtonTheme, ThemeModeSwitchTheme, ToastTheme, ToggleButtonTheme, TooltipTheme, TreeViewTheme, TypoTheme, WindowBarTheme } from './components';
|
|
2
|
+
import { ActionIconButtonTheme, AppBarTheme, AppSelectionMenuTheme, AutoCompleteTheme, BadgeTheme, BannerTheme, BoxSelectionGroupTheme, BreadcrumbsTheme, ButtonGroupTheme, ButtonTheme, CardTheme, CheckboxTheme, ChipListTheme, ChipTheme, CountryFlagTheme, DrawerTheme, FiltersTheme, FormFieldTheme, GaugeTheme, HighlightedIconTheme, IconTheme, IconButtonTheme, InputTheme, KeyValueListTheme, LabelTheme, LayoutsTheme, LinkTheme, LoaderTheme, MenuTheme, MidBarTheme, ModalTheme, MoreInfoIconTheme, PopoverTheme, PopupCardTheme, ProfileIconTheme, ProgressBarTheme, RadioTheme, SearchBarTheme, SectionTheme, SelectTheme, SemanticButtonTheme, SemanticContainerTheme, SemanticIconTheme, SideBarTheme, SkeletonTheme, SliderTheme, StepperTheme, SwitchTheme, TableHeadingTheme, TableTheme, TabsTheme, TextButtonTheme, ThemeModeSwitchTheme, ToastTheme, ToggleButtonTheme, TooltipTheme, TreeViewTheme, TypoTheme, WindowBarTheme } from './components';
|
|
3
3
|
import { BodyTheme, ScrollbarTheme } from './globals';
|
|
4
4
|
import { ThemeCore } from './themeCore.types';
|
|
5
5
|
export interface Theme extends ThemeCore, Tokens {
|
|
@@ -22,6 +22,7 @@ export interface Theme extends ThemeCore, Tokens {
|
|
|
22
22
|
drawer: DrawerTheme;
|
|
23
23
|
filters: FiltersTheme;
|
|
24
24
|
formField: FormFieldTheme;
|
|
25
|
+
gauge: GaugeTheme;
|
|
25
26
|
highlightedIcon: HighlightedIconTheme;
|
|
26
27
|
icon: IconTheme;
|
|
27
28
|
iconButton: IconButtonTheme;
|