@midas-ds/components 7.1.0 → 8.1.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.
Files changed (51) hide show
  1. package/CHANGELOG.md +53 -0
  2. package/accordion/Accordion.d.ts +1 -1
  3. package/accordion/AccordionItem.d.ts +5 -2
  4. package/breadcrumbs/Breadcrumbs.d.ts +5 -6
  5. package/character-counter/CharacterCounter.d.ts +4 -1
  6. package/checkbox/CheckboxGroup.d.ts +2 -1
  7. package/color-scheme-switch/ColorSchemeSwitch.d.ts +13 -0
  8. package/color-scheme-switch/index.d.ts +1 -0
  9. package/combobox/ComboBox.d.ts +4 -1
  10. package/combobox/index.d.ts +2 -1
  11. package/combobox/types.d.ts +3 -0
  12. package/combobox/utils.d.ts +8 -0
  13. package/date-field/DateField.d.ts +2 -1
  14. package/date-picker/DatePicker.d.ts +4 -2
  15. package/field-error/index.d.ts +1 -1
  16. package/heading/Heading.d.ts +1 -2
  17. package/index.cjs +44 -29
  18. package/index.css +1 -1
  19. package/index.d.ts +11 -9
  20. package/index.js +8499 -8050
  21. package/label/Label.d.ts +1 -2
  22. package/layout/Layout.d.ts +6 -0
  23. package/layout/components/Navbar.d.ts +1 -0
  24. package/layout/context/LayoutContext.d.ts +3 -2
  25. package/layout/index.d.ts +1 -0
  26. package/link/Link.d.ts +3 -0
  27. package/link/index.d.ts +1 -1
  28. package/package.json +1 -1
  29. package/radio/Radio.d.ts +2 -1
  30. package/search-field/SearchField.d.ts +1 -0
  31. package/select/Select.d.ts +2 -1
  32. package/select/useMultiSelectState.d.ts +3 -10
  33. package/select/utils.d.ts +7 -0
  34. package/spinner/Spinner.d.ts +8 -3
  35. package/table/Table.d.ts +6 -1
  36. package/table/index.d.ts +1 -1
  37. package/tabs/Tabs.d.ts +18 -8
  38. package/tabs/index.d.ts +1 -1
  39. package/text/Text.d.ts +1 -2
  40. package/textfield/TextFieldBase.d.ts +2 -1
  41. package/theme/index.d.ts +32 -28
  42. package/theme/tokens.d.ts +32 -28
  43. package/theme.cjs +1 -1
  44. package/theme.js +7 -6
  45. package/toggle-button/ToggleButton.d.ts +2 -0
  46. package/toggle-button/ToggleButtonGroup.d.ts +3 -0
  47. package/toggle-button/index.d.ts +2 -0
  48. package/tokens-B0IQe84F.cjs +1 -0
  49. package/{tokens-XrriCAqI.js → tokens-BWq37Xsh.js} +62 -57
  50. package/utils/useObserveElement.d.ts +17 -1
  51. package/tokens-CG8BaZyJ.cjs +0 -1
package/label/Label.d.ts CHANGED
@@ -1,10 +1,9 @@
1
1
  import { LabelProps as AriaLabelProps } from 'react-aria-components';
2
2
  import * as React from 'react';
3
- export type LabelVariant = 'label-01' | 'label-02';
4
3
  export interface LabelProps extends AriaLabelProps {
5
4
  /**
6
5
  * The visual variant of the component
7
6
  */
8
- variant?: LabelVariant;
7
+ variant?: 'label-01' | 'label-02';
9
8
  }
10
9
  export declare const Label: React.FC<LabelProps>;
@@ -4,6 +4,8 @@ import { Header } from './components/Header';
4
4
  import { SidebarLink } from './components/SidebarLink';
5
5
  import { Href } from '@react-types/shared';
6
6
  import { LayoutProvider } from './context/LayoutContext';
7
+ import { Backdrop } from './components/Backdrop';
8
+ import { Navbar } from './components/Navbar';
7
9
  import * as React from 'react';
8
10
  export interface SidebarLinkGroup {
9
11
  title?: string;
@@ -14,6 +16,7 @@ export interface SidebarLinkProps {
14
16
  href: string;
15
17
  icon: LucideIcon;
16
18
  active?: boolean;
19
+ hasBadge?: boolean;
17
20
  isCollapsed?: boolean;
18
21
  setIsOpened?: React.Dispatch<React.SetStateAction<boolean>>;
19
22
  }
@@ -44,11 +47,14 @@ export interface MidasLayout {
44
47
  */
45
48
  clientSideRouter?: (path: string, routerOptions: undefined) => void;
46
49
  clientSideHref?: (href: Href) => string;
50
+ variant: 'internal' | 'external';
47
51
  }
48
52
  export declare const Layout: React.FC<MidasLayout> & {
49
53
  Provider: typeof LayoutProvider;
50
54
  Header: typeof Header;
51
55
  Sidebar: typeof Sidebar;
52
56
  SidebarLink: typeof SidebarLink;
57
+ Navbar: typeof Navbar;
58
+ Backdrop: typeof Backdrop;
53
59
  };
54
60
  export {};
@@ -0,0 +1 @@
1
+ export declare const Navbar: React.FC;
@@ -9,10 +9,11 @@ interface LayoutContextProps {
9
9
  headerChildren: React.ReactNode;
10
10
  isCollapsed: boolean;
11
11
  setIsCollapsed: React.Dispatch<React.SetStateAction<boolean>>;
12
- isOpened: boolean;
13
- setIsOpened: React.Dispatch<React.SetStateAction<boolean>>;
12
+ isOpened?: boolean;
13
+ setIsOpened?: React.Dispatch<React.SetStateAction<boolean>>;
14
14
  clientSideRouter?: (path: string, routerOptions: undefined) => void;
15
15
  clientSideHref?: (href: Href) => string;
16
+ variant: 'internal' | 'external';
16
17
  }
17
18
  export declare const LayoutProvider: React.FC<LayoutContextProps & {
18
19
  children: React.ReactNode;
package/layout/index.d.ts CHANGED
@@ -2,3 +2,4 @@ export * from './Layout';
2
2
  export * from './components/Header';
3
3
  export * from './components/Sidebar';
4
4
  export * from './components/SidebarLink';
5
+ export * from './components/Navbar';
package/link/Link.d.ts CHANGED
@@ -2,8 +2,11 @@ import { Link as AriaLink, RouterProvider } from 'react-aria-components';
2
2
  import { LucideIcon } from 'lucide-react';
3
3
  interface MidasLinkProps<C extends React.ElementType> {
4
4
  children: React.ReactNode;
5
+ /** Use standalone to use the component as a standalone link, for example under a block of text.*/
5
6
  standalone?: boolean;
7
+ /** Use stretched to make the entire parent element clickable to the link. The parent must have position: relative; so that the clickable area of the link does not extend too far.*/
6
8
  stretched?: boolean;
9
+ /** Optional icon, placed to the left of the link */
7
10
  icon?: LucideIcon;
8
11
  className?: string;
9
12
  as?: C;
package/link/index.d.ts CHANGED
@@ -1 +1 @@
1
- export { Link, RouterProvider } from './Link';
1
+ export { Link, RouterProvider, type LinkProps } from './Link';
package/package.json CHANGED
@@ -14,7 +14,7 @@
14
14
  "description": "Midas Components",
15
15
  "homepage": "https://designsystem.migrationsverket.se/",
16
16
  "license": "CC0-1.0",
17
- "version": "7.1.0",
17
+ "version": "8.1.0",
18
18
  "main": "./index.cjs",
19
19
  "module": "./index.js",
20
20
  "types": "./index.d.ts",
package/radio/Radio.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { RadioGroupProps, ValidationResult, RadioProps } from 'react-aria-components';
1
+ import { RadioGroupProps, RadioProps, ValidationResult } from 'react-aria-components';
2
2
  import * as React from 'react';
3
3
  interface MVDSRadioGroupProps extends Omit<RadioGroupProps, 'children'> {
4
4
  children?: React.ReactNode;
@@ -8,6 +8,7 @@ interface MVDSRadioGroupProps extends Omit<RadioGroupProps, 'children'> {
8
8
  description?: string;
9
9
  /** String to display as error message or function to handle the result and produce the error message */
10
10
  errorMessage?: string | ((validation: ValidationResult) => string);
11
+ errorPosition?: 'top' | 'bottom';
11
12
  }
12
13
  /**
13
14
  * RadioGroup is used to group several radio items together
@@ -13,5 +13,6 @@ export interface SearchFieldProps extends Omit<AriaSearchFieldProps, 'isRequired
13
13
  * A custom error message if using the isInvalid prop.
14
14
  */
15
15
  errorMessage?: string;
16
+ errorPosition?: 'top' | 'bottom';
16
17
  }
17
18
  export declare const SearchField: React.FC<SearchFieldProps>;
@@ -16,7 +16,7 @@ type OptionSection = {
16
16
  };
17
17
  export type Option = OptionItem | OptionSection;
18
18
  export type SelectionMode = 'single' | 'multiple';
19
- type SelectProps = {
19
+ export type SelectProps = {
20
20
  /** Whether the element should receive focus on render. */
21
21
  autoFocus?: boolean;
22
22
  children: CollectionChildren<Option>;
@@ -65,6 +65,7 @@ type SelectProps = {
65
65
  isRequired?: boolean;
66
66
  /** Name of the field, for uncontrolled use */
67
67
  name?: string;
68
+ errorPosition?: 'top' | 'bottom';
68
69
  };
69
70
  export declare const SelectComponent: React.ForwardRefExoticComponent<SelectProps & React.RefAttributes<HTMLButtonElement>>;
70
71
  export declare const Select: React.ForwardRefExoticComponent<Omit<SelectProps, "children" | "items"> & {
@@ -1,26 +1,19 @@
1
1
  import { MenuTriggerState } from '@react-stately/menu';
2
- import { Key } from 'react-aria';
3
2
  import { MultiSelectListState } from './useMultiSelectListState';
4
3
  import { OverlayTriggerProps } from '@react-types/overlays';
5
- import { AsyncLoadable, CollectionBase, FocusableProps, InputBase, LabelableProps, MultipleSelection, TextInputBase, Validation, Selection } from '@react-types/shared';
4
+ import { AsyncLoadable, CollectionBase, FocusableProps, InputBase, LabelableProps, MultipleSelection, TextInputBase, Validation } from '@react-types/shared';
6
5
  import { FormValidationState } from '@react-stately/form';
7
- import { SingleSelectListState } from 'react-stately';
8
- /** Added this for a better output, will see how this plays out */
9
- interface ArraySelection extends Omit<MultipleSelection, 'onSelectionChange'> {
10
- onSelectionChange?: (value: Selection | Key | Key[]) => void;
11
- }
12
- export interface MultiSelectProps<T> extends CollectionBase<T>, AsyncLoadable, Omit<InputBase, 'isReadOnly'>, Validation, LabelableProps, TextInputBase, ArraySelection, FocusableProps, OverlayTriggerProps {
6
+ export interface MultiSelectProps<T> extends CollectionBase<T>, AsyncLoadable, Omit<InputBase, 'isReadOnly'>, Validation, LabelableProps, TextInputBase, MultipleSelection, FocusableProps, OverlayTriggerProps {
13
7
  /**
14
8
  * Whether the menu should automatically flip direction when space is limited.
15
9
  * @default true
16
10
  */
17
11
  shouldFlip?: boolean;
18
12
  }
19
- export interface MultiSelectState<T> extends MultiSelectListState<T>, MenuTriggerState, SingleSelectListState<T>, FormValidationState {
13
+ export interface MultiSelectState<T> extends MultiSelectListState<T>, MenuTriggerState, FormValidationState {
20
14
  /** Whether the select is currently focused. */
21
15
  isFocused: boolean;
22
16
  /** Sets whether the select is focused. */
23
17
  setFocused(isFocused: boolean): void;
24
18
  }
25
19
  export declare function useMultiSelectState<T extends object>(props: MultiSelectProps<T>): MultiSelectState<T>;
26
- export {};
package/select/utils.d.ts CHANGED
@@ -2,3 +2,10 @@ export declare const options: {
2
2
  name: string;
3
3
  id: string;
4
4
  }[];
5
+ export declare const optionsWithSections: {
6
+ name: string;
7
+ children: {
8
+ name: string;
9
+ id: string;
10
+ }[];
11
+ }[];
@@ -1,11 +1,16 @@
1
1
  export interface SpinnerProps {
2
- /** Displays a smaller when set to true
2
+ /** Displays a smaller spinner when set to true
3
3
  * @default false
4
- * */
4
+ */
5
5
  small?: boolean;
6
+ /** For use on coloured background
7
+ * @default false
8
+ */
9
+ isOnColor?: boolean;
6
10
  /** For use on dark background
7
11
  * @default false
8
- * */
12
+ * @deprecated please use `isOnColor` instead
13
+ */
9
14
  dark?: boolean;
10
15
  }
11
16
  export declare const Spinner: React.FC<SpinnerProps>;
package/table/Table.d.ts CHANGED
@@ -1,7 +1,12 @@
1
1
  import { RowProps, TableHeaderProps, ColumnProps, TableProps as AriaTableProps, CellProps, TableBody } from 'react-aria-components';
2
2
  export interface TableProps extends AriaTableProps {
3
- /** @deprecated This variant will be replaced with a new scaling api accross all components. */
3
+ /**
4
+ * @deprecated This variant will be replaced with a new scaling api accross all components.
5
+ */
4
6
  narrow?: boolean;
7
+ /**
8
+ * Alternating colors for rows
9
+ */
5
10
  striped?: boolean;
6
11
  }
7
12
  export declare const Table: ({ narrow, striped, className, ...rest }: TableProps) => import("react/jsx-runtime").JSX.Element;
package/table/index.d.ts CHANGED
@@ -1 +1 @@
1
- export { Table, TableHeader, TableBody, Row, Cell, Column } from './Table';
1
+ export * from './Table';
package/tabs/Tabs.d.ts CHANGED
@@ -1,12 +1,22 @@
1
+ import { TabsProps as AriaTabsProps } from 'react-aria-components';
1
2
  import * as React from 'react';
2
- export interface TabsProps<T extends string> {
3
- /** An array of tab titles */
4
- tabs: T[];
5
- /** Lable for accecibility */
3
+ export interface TabsProps extends Omit<AriaTabsProps, 'orientation'> {
4
+ /**
5
+ * An array of tab titles
6
+ */
7
+ tabs: string[];
8
+ /**
9
+ * Label for accessibility
10
+ */
6
11
  label: string;
7
- /** Choose another than the first tab to be selected by default. Name must match one of the tabs */
8
- defaultSelected?: T;
9
- /** Amount of children must match the amount of tabs */
12
+ /**
13
+ * Amount of children must match the amount of tabs
14
+ */
10
15
  children: React.ReactNode;
16
+ /**
17
+ * @deprecated
18
+ * Please use `defaultSelectedKey` instead
19
+ */
20
+ defaultSelected?: string;
11
21
  }
12
- export declare const Tabs: <T extends string>({ tabs, label, defaultSelected, children }: TabsProps<T>) => import("react/jsx-runtime").JSX.Element;
22
+ export declare const Tabs: React.FC<TabsProps>;
package/tabs/index.d.ts CHANGED
@@ -1 +1 @@
1
- export { Tabs } from './Tabs';
1
+ export * from './Tabs';
package/text/Text.d.ts CHANGED
@@ -1,11 +1,10 @@
1
1
  import { TextProps as AriaTextProps } from 'react-aria-components';
2
2
  import * as React from 'react';
3
- export type TextVariant = 'body-01' | 'body-02';
4
3
  export interface TextProps extends AriaTextProps {
5
4
  /**
6
5
  * The visual variant of the component
7
6
  */
8
- variant?: TextVariant;
7
+ variant?: 'body-01' | 'body-02';
9
8
  /**
10
9
  * Use the external/expressive look
11
10
  */
@@ -7,7 +7,8 @@ export interface TextFieldBaseProps extends Omit<TextFieldProps, 'className'> {
7
7
  /** Specify description displayed below the label */
8
8
  description?: string;
9
9
  /** Custom error messages */
10
- errorMessage?: string | ((validation: ValidationResult) => string) | undefined;
10
+ errorMessage?: string | ((validation: ValidationResult) => string);
11
+ errorPosition?: 'top' | 'bottom';
11
12
  /**
12
13
  * Whether to show the character counter or not
13
14
  * @default
package/theme/index.d.ts CHANGED
@@ -37,16 +37,19 @@ export declare const theme: {
37
37
  purple80: string;
38
38
  purple140: string;
39
39
  red100: string;
40
- signalBlue20: string;
41
- signalBlue140: string;
40
+ signalBlue10: string;
41
+ signalBlue100: string;
42
42
  signalGreen20: string;
43
- signalGreen140: string;
43
+ signalGreen30: string;
44
+ signalGreen100: string;
45
+ signalYellow10: string;
46
+ signalYellow100: string;
44
47
  signalRed20: string;
45
- signalRed140: string;
48
+ signalRed30: string;
49
+ signalRed80: string;
50
+ signalRed100: string;
46
51
  signalRed160: string;
47
52
  signalRed180: string;
48
- signalYellow20: string;
49
- signalYellow140: string;
50
53
  };
51
54
  typography: {
52
55
  fontFamily: string;
@@ -101,6 +104,11 @@ export declare const theme: {
101
104
  normal: string;
102
105
  fast: string;
103
106
  };
107
+ windowSizes: {
108
+ md: number;
109
+ lg: number;
110
+ xl: number;
111
+ };
104
112
  breakpoints: {
105
113
  sm: string;
106
114
  md: string;
@@ -111,9 +119,9 @@ export declare const theme: {
111
119
  prefersReducedMotion: string;
112
120
  };
113
121
  semantic: {
114
- background01: string;
115
- backgroundHover01: string;
116
- backgroundInverse01: string;
122
+ background: string;
123
+ backgroundHover: string;
124
+ backgroundInverse: string;
117
125
  layer01: string;
118
126
  layerHover01: string;
119
127
  layerSelected01: string;
@@ -129,14 +137,12 @@ export declare const theme: {
129
137
  layerAccentHover02: string;
130
138
  layerAccentSelected02: string;
131
139
  brandPrimary: string;
132
- borderStrong: string;
133
- borderMedium: string;
140
+ borderPrimary: string;
141
+ borderSecondary: string;
134
142
  borderSubtle: string;
135
- borderBrand: string;
143
+ borderTertiary: string;
136
144
  borderInvalid: string;
137
145
  borderDisabled: string;
138
- borderSkeleton: string;
139
- borderInverse: string;
140
146
  field01: string;
141
147
  fieldHover01: string;
142
148
  fieldActive01: string;
@@ -149,7 +155,6 @@ export declare const theme: {
149
155
  iconSecondary: string;
150
156
  iconInverse: string;
151
157
  iconOnColor: string;
152
- iconDanger: string;
153
158
  iconDisabled: string;
154
159
  iconSuccess: string;
155
160
  iconInfo: string;
@@ -159,20 +164,21 @@ export declare const theme: {
159
164
  linkHover: string;
160
165
  linkPressed: string;
161
166
  linkVisited: string;
162
- notificationBorderSuccess: string;
163
- notificationBorderInfo: string;
164
- notificationBorderImportant: string;
165
- notificationBorderWarning: string;
166
- notificationBackgroundSuccess: string;
167
- notificationBackgroundInfo: string;
168
- notificationBackgroundImportant: string;
169
- notificationBackgroundWarning: string;
167
+ supportBorderSuccess: string;
168
+ supportBorderInfo: string;
169
+ supportBorderImportant: string;
170
+ supportBorderWarning: string;
171
+ supportBackgroundSuccess: string;
172
+ supportBackgroundSuccessHover: string;
173
+ supportBackgroundInfo: string;
174
+ supportBackgroundImportant: string;
175
+ supportBackgroundWarning: string;
176
+ supportBackgroundWarningHover: string;
170
177
  textPrimary: string;
171
178
  textSecondary: string;
172
- textBrand: string;
179
+ textTertiary: string;
173
180
  textOnColor: string;
174
181
  textInverse: string;
175
- textSubtle: string;
176
182
  textDisabled: string;
177
183
  textInvalid: string;
178
184
  textPlaceholder: string;
@@ -189,9 +195,7 @@ export declare const theme: {
189
195
  buttonBackgroundDangerActive: string;
190
196
  buttonBackgroundDisabled: string;
191
197
  buttonBackgroundSkeleton: string;
192
- buttonBackgroundGhostHover: string;
193
- buttonBackgroundGhostActive: string;
194
- buttonBorderPrimary: string;
198
+ buttonBorderSecondary: string;
195
199
  logoPrimary: string;
196
200
  };
197
201
  zIndex: {
package/theme/tokens.d.ts CHANGED
@@ -35,16 +35,19 @@ export declare const baseColors: {
35
35
  purple80: string;
36
36
  purple140: string;
37
37
  red100: string;
38
- signalBlue20: string;
39
- signalBlue140: string;
38
+ signalBlue10: string;
39
+ signalBlue100: string;
40
40
  signalGreen20: string;
41
- signalGreen140: string;
41
+ signalGreen30: string;
42
+ signalGreen100: string;
43
+ signalYellow10: string;
44
+ signalYellow100: string;
42
45
  signalRed20: string;
43
- signalRed140: string;
46
+ signalRed30: string;
47
+ signalRed80: string;
48
+ signalRed100: string;
44
49
  signalRed160: string;
45
50
  signalRed180: string;
46
- signalYellow20: string;
47
- signalYellow140: string;
48
51
  };
49
52
  export declare const typography: {
50
53
  fontFamily: string;
@@ -99,6 +102,11 @@ export declare const transitions: {
99
102
  normal: string;
100
103
  fast: string;
101
104
  };
105
+ export declare const windowSizes: {
106
+ md: number;
107
+ lg: number;
108
+ xl: number;
109
+ };
102
110
  export declare const breakpoints: {
103
111
  sm: string;
104
112
  md: string;
@@ -109,9 +117,9 @@ export declare const breakpoints: {
109
117
  prefersReducedMotion: string;
110
118
  };
111
119
  export declare const semantic: {
112
- background01: string;
113
- backgroundHover01: string;
114
- backgroundInverse01: string;
120
+ background: string;
121
+ backgroundHover: string;
122
+ backgroundInverse: string;
115
123
  layer01: string;
116
124
  layerHover01: string;
117
125
  layerSelected01: string;
@@ -127,14 +135,12 @@ export declare const semantic: {
127
135
  layerAccentHover02: string;
128
136
  layerAccentSelected02: string;
129
137
  brandPrimary: string;
130
- borderStrong: string;
131
- borderMedium: string;
138
+ borderPrimary: string;
139
+ borderSecondary: string;
132
140
  borderSubtle: string;
133
- borderBrand: string;
141
+ borderTertiary: string;
134
142
  borderInvalid: string;
135
143
  borderDisabled: string;
136
- borderSkeleton: string;
137
- borderInverse: string;
138
144
  field01: string;
139
145
  fieldHover01: string;
140
146
  fieldActive01: string;
@@ -147,7 +153,6 @@ export declare const semantic: {
147
153
  iconSecondary: string;
148
154
  iconInverse: string;
149
155
  iconOnColor: string;
150
- iconDanger: string;
151
156
  iconDisabled: string;
152
157
  iconSuccess: string;
153
158
  iconInfo: string;
@@ -157,20 +162,21 @@ export declare const semantic: {
157
162
  linkHover: string;
158
163
  linkPressed: string;
159
164
  linkVisited: string;
160
- notificationBorderSuccess: string;
161
- notificationBorderInfo: string;
162
- notificationBorderImportant: string;
163
- notificationBorderWarning: string;
164
- notificationBackgroundSuccess: string;
165
- notificationBackgroundInfo: string;
166
- notificationBackgroundImportant: string;
167
- notificationBackgroundWarning: string;
165
+ supportBorderSuccess: string;
166
+ supportBorderInfo: string;
167
+ supportBorderImportant: string;
168
+ supportBorderWarning: string;
169
+ supportBackgroundSuccess: string;
170
+ supportBackgroundSuccessHover: string;
171
+ supportBackgroundInfo: string;
172
+ supportBackgroundImportant: string;
173
+ supportBackgroundWarning: string;
174
+ supportBackgroundWarningHover: string;
168
175
  textPrimary: string;
169
176
  textSecondary: string;
170
- textBrand: string;
177
+ textTertiary: string;
171
178
  textOnColor: string;
172
179
  textInverse: string;
173
- textSubtle: string;
174
180
  textDisabled: string;
175
181
  textInvalid: string;
176
182
  textPlaceholder: string;
@@ -187,9 +193,7 @@ export declare const semantic: {
187
193
  buttonBackgroundDangerActive: string;
188
194
  buttonBackgroundDisabled: string;
189
195
  buttonBackgroundSkeleton: string;
190
- buttonBackgroundGhostHover: string;
191
- buttonBackgroundGhostActive: string;
192
- buttonBorderPrimary: string;
196
+ buttonBorderSecondary: string;
193
197
  logoPrimary: string;
194
198
  };
195
199
  export declare const zIndex: {
package/theme.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./tokens-CG8BaZyJ.cjs"),e={...t.tokens};exports.baseColors=t.baseColors;exports.breakpoints=t.breakpoints;exports.semantic=t.semantic;exports.spacing=t.spacing;exports.states=t.states;exports.transitions=t.transitions;exports.typography=t.typography;exports.zIndex=t.zIndex;exports.theme=e;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./tokens-B0IQe84F.cjs"),s={...e.tokens};exports.baseColors=e.baseColors;exports.breakpoints=e.breakpoints;exports.semantic=e.semantic;exports.spacing=e.spacing;exports.states=e.states;exports.transitions=e.transitions;exports.typography=e.typography;exports.windowSizes=e.windowSizes;exports.zIndex=e.zIndex;exports.theme=s;
package/theme.js CHANGED
@@ -1,14 +1,15 @@
1
- import { t as s } from "./tokens-XrriCAqI.js";
2
- import { b as r, f as n, s as p, c as i, d as m, e as c, a as b, z as f } from "./tokens-XrriCAqI.js";
1
+ import { t as s } from "./tokens-BWq37Xsh.js";
2
+ import { b as n, f as r, s as i, c as p, d as m, e as c, a as b, w as d, z as f } from "./tokens-BWq37Xsh.js";
3
3
  const t = { ...s };
4
4
  export {
5
- r as baseColors,
6
- n as breakpoints,
7
- p as semantic,
8
- i as spacing,
5
+ n as baseColors,
6
+ r as breakpoints,
7
+ i as semantic,
8
+ p as spacing,
9
9
  m as states,
10
10
  t as theme,
11
11
  c as transitions,
12
12
  b as typography,
13
+ d as windowSizes,
13
14
  f as zIndex
14
15
  };
@@ -0,0 +1,2 @@
1
+ import { ToggleButtonProps } from 'react-aria-components';
2
+ export declare const ToggleButton: React.FC<ToggleButtonProps & React.RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,3 @@
1
+ import { ToggleButtonGroupProps } from 'react-aria-components';
2
+ import * as React from 'react';
3
+ export declare const ToggleButtonGroup: React.FC<ToggleButtonGroupProps & React.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,2 @@
1
+ export * from './ToggleButton';
2
+ export * from './ToggleButtonGroup';
@@ -0,0 +1 @@
1
+ "use strict";const r={black:"#000000",white:"#ffffff",blackHover:"#0d0d0d",whiteHover:"#e6e6e6",gray10:"#f2f2f2",gray20:"#e6e6e6",gray30:"#d9d9d9",gray40:"#cccccc",gray50:"#bfbfbf",gray60:"#b3b3b3",gray70:"#a6a6a6",gray80:"#999999",gray90:"#8c8c8c",gray100:"#808080",gray110:"#737373",gray120:"#666666",gray130:"#5d5d5d",gray140:"#525252",gray150:"#474747",gray160:"#383838",gray170:"#333333",gray180:"#262626",gray190:"#212121",gray200:"#171717",blue10:"#eaf2f6",blue20:"#d5e5ed",blue40:"#abcbdb",blue60:"#82b0c9",blue80:"#5897b8",blue90:"#4289ad",blue100:"#2e7ca5",blue140:"#25607f",blue170:"#143c50",purple80:"#b46ab4",purple140:"#954b95",red100:"#b90835",signalBlue10:"#eaf2f6",signalBlue100:"#0066cc",signalGreen20:"#d5f2d9",signalGreen30:"#bae5c5",signalGreen100:"#008d3c",signalYellow10:"#fff8e1",signalYellow100:"#fdb813",signalRed20:"#ffdfdf",signalRed30:"#fcc8c8",signalRed80:"#eb4e4e",signalRed100:"#e62323",signalRed160:"#b31b1b",signalRed180:"#801313"},a={fontFamily:'"Inter", sans-serif',lineHeight01:1,lineHeight02:1.125,lineHeight03:1.25,lineHeight04:1.375,lineHeight05:1.5,lineHeight06:1.75,lineHeight07:2,lineHeight08:2.25,lineHeight09:2.5,size01:"0.75rem",size02:"0.875rem",size03:"1rem",size04:"1.125rem",size05:"1.25rem",size06:"1.5rem",size07:"1.75rem",size08:"2rem",size09:"2.25rem",size10:"2.625rem",weightThin:100,weightExtraLight:200,weightLight:300,weightRegular:400,weightMedium:500,weightSemiBold:600,weightBold:700,weightExtraBold:800,weightBlack:900},g={"01":"0.125rem","02":"0.25rem","03":"0.5rem","04":"0.75rem","05":"1rem","06":"1.5rem","07":"2rem","08":"2.5rem","09":"3rem",10:"4rem",11:"5rem",12:"6rem"},i={focus:"0 0 0 2px light-dark(white, black), 0 0 0 4px light-dark(black, white)"},l={slow:"500ms",normal:"300ms",fast:"250ms"},e={md:768,lg:1200,xl:1440},t={sm:`(max-width: ${e.md-1}px)`,md:`(min-width: ${e.md}px)`,lg:`(min-width: ${e.lg}px)`,xl:`(min-width: ${e.xl}px)`,forcedColorsMode:"(forced-colors: active)",darkMode:"(prefers-color-scheme: dark)",prefersReducedMotion:"(prefers-reduced-motion: reduced)"},d={background:`light-dark(${r.white}, ${r.gray200})`,backgroundHover:`light-dark(${r.whiteHover}, ${r.gray190})`,backgroundInverse:`light-dark(${r.gray200}, ${r.gray10})`,layer01:`light-dark(${r.gray10}, ${r.gray180})`,layerHover01:`light-dark(${r.gray20}, ${r.gray170})`,layerSelected01:`light-dark(${r.gray30}, ${r.gray160})`,layerSelectedHover01:`light-dark(${r.gray40}, ${r.gray150})`,layer02:`light-dark(${r.white}, ${r.gray160})`,layerHover02:`light-dark(${r.whiteHover}, ${r.gray150})`,layerSelected02:`light-dark(${r.gray30}, ${r.gray140})`,layerSelectedHover02:`light-dark(${r.gray40}, ${r.gray130})`,layerAccent01:`light-dark(${r.gray30}, ${r.gray160})`,layerAccentHover01:`light-dark(${r.gray40}, ${r.gray150})`,layerAccentSelected01:`light-dark(${r.gray50}, ${r.gray140})`,layerAccent02:`light-dark(${r.gray10}, ${r.gray180})`,layerAccentHover02:`light-dark(${r.gray20}, ${r.gray170})`,layerAccentSelected02:`light-dark(${r.gray30}, ${r.gray160})`,brandPrimary:`light-dark(${r.red100}, ${r.red100})`,borderPrimary:`light-dark(${r.gray200}, ${r.gray10})`,borderSecondary:`light-dark(${r.gray110}, ${r.gray90})`,borderSubtle:`light-dark(${r.gray50}, ${r.gray160})`,borderTertiary:`light-dark(${r.blue170}, ${r.blue100})`,borderInvalid:`light-dark(${r.signalRed100}, ${r.signalRed80})`,borderDisabled:`light-dark(${r.gray50}, ${r.gray140})`,field01:`light-dark(${r.gray10}, ${r.gray180})`,fieldHover01:`light-dark(${r.gray20}, ${r.gray170})`,fieldActive01:`light-dark(${r.gray30}, ${r.gray160})`,field02:`light-dark(${r.white}, ${r.gray160})`,fieldHover02:`light-dark(${r.whiteHover}, ${r.gray150})`,fieldActive02:`light-dark(${r.gray30}, ${r.gray140})`,fieldDisabled:`light-dark(${r.gray10}, ${r.gray180})`,fieldSkeleton:`light-dark(${r.gray10}, ${r.gray180})`,iconPrimary:`light-dark(${r.gray200}, ${r.gray10})`,iconSecondary:`light-dark(${r.blue170}, ${r.gray10})`,iconInverse:`light-dark(${r.white}, ${r.gray200})`,iconOnColor:`light-dark(${r.white}, ${r.white})`,iconDisabled:`light-dark(${r.gray50}, ${r.gray140})`,iconSuccess:`light-dark(${r.signalGreen100}, ${r.signalGreen100})`,iconInfo:`light-dark(${r.signalBlue100}, ${r.signalBlue100})`,iconWarning:`light-dark(${r.signalRed100}, ${r.signalRed100})`,iconImportant:`light-dark(${r.signalYellow100}, ${r.signalYellow100})`,linkEnabled:`light-dark(${r.blue100}, ${r.blue90})`,linkHover:`light-dark(${r.blue170}, ${r.blue80})`,linkPressed:`light-dark(${r.gray200}, ${r.blue60})`,linkVisited:`light-dark(${r.purple140}, ${r.purple80})`,supportBorderSuccess:`light-dark(${r.signalGreen100}, ${r.signalGreen100})`,supportBorderInfo:`light-dark(${r.signalBlue100}, ${r.signalBlue100})`,supportBorderImportant:`light-dark(${r.signalYellow100}, ${r.signalYellow100})`,supportBorderWarning:`light-dark(${r.signalRed100}, ${r.signalRed100})`,supportBackgroundSuccess:`light-dark(${r.signalGreen20}, ${r.gray180})`,supportBackgroundSuccessHover:`light-dark(${r.signalGreen30}, ${r.gray170})`,supportBackgroundInfo:`light-dark(${r.signalBlue10}, ${r.gray180})`,supportBackgroundImportant:`light-dark(${r.signalYellow10}, ${r.gray180})`,supportBackgroundWarning:`light-dark(${r.signalRed20}, ${r.gray180})`,supportBackgroundWarningHover:`light-dark(${r.signalRed30}, ${r.gray170})`,textPrimary:`light-dark(${r.gray200}, ${r.gray10})`,textSecondary:`light-dark(${r.gray140}, ${r.gray70})`,textTertiary:`light-dark(${r.blue170}, ${r.gray10})`,textOnColor:`light-dark(${r.white}, ${r.white})`,textInverse:`light-dark(${r.gray10}, ${r.gray200})`,textDisabled:`light-dark(${r.gray50}, ${r.gray140})`,textInvalid:`light-dark(${r.signalRed100}, ${r.signalRed80})`,textPlaceholder:`light-dark(${r.gray70}, ${r.gray140})`,buttonBackgroundPrimary:`light-dark(${r.blue170}, ${r.blue100})`,buttonBackgroundPrimaryHover:`light-dark(${r.blue140}, ${r.blue140})`,buttonBackgroundPrimaryActive:`light-dark(${r.blue100}, ${r.blue170})`,buttonBackgroundSecondary:`light-dark(${r.white}, ${r.gray200})`,buttonBackgroundSecondaryHover:`light-dark(${r.whiteHover}, ${r.gray190})`,buttonBackgroundSecondaryActive:`light-dark(${r.gray30}, ${r.gray180})`,buttonBackgroundTertiaryHover:`light-dark(${r.whiteHover}, ${r.gray190})`,buttonBackgroundTertiaryActive:`light-dark(${r.gray30}, ${r.gray180})`,buttonBackgroundDanger:`light-dark(${r.signalRed100}, ${r.signalRed100})`,buttonBackgroundDangerHover:`light-dark(${r.signalRed160}, ${r.signalRed160})`,buttonBackgroundDangerActive:`light-dark(${r.signalRed180}, ${r.signalRed180})`,buttonBackgroundDisabled:`light-dark(${r.gray10}, ${r.gray180})`,buttonBackgroundSkeleton:`light-dark(${r.gray10}, ${r.gray180})`,buttonBorderSecondary:`light-dark(${r.blue170}, ${r.gray10})`,logoPrimary:`light-dark(${r.red100}, ${r.white})`},n={base:1,above:10,modal:1e3,toast:1100,skipToContent:1200},o=Object.freeze(Object.defineProperty({__proto__:null,baseColors:r,breakpoints:t,semantic:d,spacing:g,states:i,transitions:l,typography:a,windowSizes:e,zIndex:n},Symbol.toStringTag,{value:"Module"}));exports.baseColors=r;exports.breakpoints=t;exports.semantic=d;exports.spacing=g;exports.states=i;exports.tokens=o;exports.transitions=l;exports.typography=a;exports.windowSizes=e;exports.zIndex=n;