@getsoren/design-system 4.43.1 → 4.45.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/main.cjs +50 -50
- package/dist/main.js +3037 -2872
- package/dist/src/components/DataDisplay/Icons/EmptyStateIcon.d.ts +2 -0
- package/dist/src/components/Feedback/EmptyState/EmptyState.d.ts +24 -0
- package/dist/src/components/Navigation/NavigationMenu/NavigationMenu.d.ts +6 -1
- package/dist/src/main.d.ts +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ElementType, ReactNode } from 'react';
|
|
2
|
+
import { ButtonProps } from '../../Inputs/Button';
|
|
3
|
+
export interface EmptyStateProps<RootComponent extends ElementType = "button"> {
|
|
4
|
+
/** Illustration displayed above the description. Defaults to the empty state illustration. */
|
|
5
|
+
icon?: ReactNode;
|
|
6
|
+
/** Main message explaining the empty state */
|
|
7
|
+
description?: ReactNode;
|
|
8
|
+
/** Label of the action button. The button is only rendered when provided. */
|
|
9
|
+
actionLabel?: ReactNode;
|
|
10
|
+
/**
|
|
11
|
+
* Props forwarded to the action button. Polymorphic like the Button component:
|
|
12
|
+
* pass a routing component via `component` (e.g. `{ component: Link, to: "/home" }`).
|
|
13
|
+
*/
|
|
14
|
+
actionProps?: ButtonProps<RootComponent>;
|
|
15
|
+
/** Free slot rendered below the action button for fully custom content */
|
|
16
|
+
children?: ReactNode;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Centered empty state with an illustration, a description and an optional action button.
|
|
20
|
+
* The action button accepts any root component, so consumers can plug their router link
|
|
21
|
+
* without coupling the design system to a routing library.
|
|
22
|
+
*/
|
|
23
|
+
declare const EmptyState: <RootComponent extends ElementType = "button">({ icon, description, actionLabel, actionProps, children, }: EmptyStateProps<RootComponent>) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
24
|
+
export default EmptyState;
|
|
@@ -123,6 +123,11 @@ export interface NavigationMenuProps {
|
|
|
123
123
|
* Search component
|
|
124
124
|
*/
|
|
125
125
|
Footer?: ReactNode;
|
|
126
|
+
/**
|
|
127
|
+
* localStorage key used to persist the sidebar collapsed state
|
|
128
|
+
* @default "soren-navigation-menu-collapsed"
|
|
129
|
+
*/
|
|
130
|
+
storageKey?: string;
|
|
126
131
|
}
|
|
127
132
|
declare const DEFAULT_CONTEXT_VALUE: {
|
|
128
133
|
closeDrawerMenu: () => void;
|
|
@@ -135,5 +140,5 @@ declare const DEFAULT_CONTEXT_VALUE: {
|
|
|
135
140
|
};
|
|
136
141
|
type NavigationMenuContextValue = NavigationMenuProps & typeof DEFAULT_CONTEXT_VALUE;
|
|
137
142
|
export declare const NavigationMenuContext: import('react').Context<NavigationMenuContextValue>;
|
|
138
|
-
declare const _default: import('react').MemoExoticComponent<({ AppBar, NavLink, Search, Logo, Footer, items, enableSearchFocusShortcut, disableResponsive, hideSearchDesktop, bottomLink, sideBarWidth, }: NavigationMenuProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
143
|
+
declare const _default: import('react').MemoExoticComponent<({ AppBar, NavLink, Search, Logo, Footer, items, enableSearchFocusShortcut, disableResponsive, hideSearchDesktop, bottomLink, sideBarWidth, storageKey, }: NavigationMenuProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
139
144
|
export default _default;
|
package/dist/src/main.d.ts
CHANGED
|
@@ -39,6 +39,8 @@ export * from './components/Feedback/Dialog/DialogPopper';
|
|
|
39
39
|
export { default as DialogPopper } from './components/Feedback/Dialog/DialogPopper';
|
|
40
40
|
export * from './components/Feedback/Dialog/DialogValidation/DialogValidation';
|
|
41
41
|
export { default as DialogValidation } from './components/Feedback/Dialog/DialogValidation/DialogValidation';
|
|
42
|
+
export type { EmptyStateProps } from './components/Feedback/EmptyState/EmptyState';
|
|
43
|
+
export { default as EmptyState } from './components/Feedback/EmptyState/EmptyState';
|
|
42
44
|
export * from './components/Feedback/Lightbox';
|
|
43
45
|
export { default as Lightbox } from './components/Feedback/Lightbox';
|
|
44
46
|
export * from './components/Inputs/ActionAppBar';
|