@digital-ai/dot-components 1.0.10 → 1.0.11

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.
@@ -1,6 +1,7 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { CommonProps } from '../CommonProps';
3
3
  import { IconButtonProps } from '../button/IconButton';
4
+ import { ListItemProps } from '../list/List';
4
5
  export interface AppToolbarProps extends CommonProps {
5
6
  /** Product name displayed next to Digital.ai logo */
6
7
  appName?: string;
@@ -12,11 +13,13 @@ export interface AppToolbarProps extends CommonProps {
12
13
  children?: ReactNode;
13
14
  /** Allow to display custom logo */
14
15
  customLogo?: ReactNode;
15
- /** If provided will display a hamburger main menu drawer */
16
+ /** If provided will overwrite `mainMenuItems` and display within the main menu drawer */
16
17
  mainMenu?: ReactNode;
18
+ /** If provided will display the menu items within the main menu drawer */
19
+ mainMenuItems?: Array<ListItemProps>;
17
20
  /** Width of main menu drawer if mainMenu provided, defaults to 240px */
18
21
  mainMenuWidth?: number;
19
22
  /** Array of nav items to be displayed on the right side */
20
23
  navItems?: Array<IconButtonProps>;
21
24
  }
22
- export declare const DotAppToolbar: ({ ariaLabel, avatar, borderColor, appName, children, className, customLogo, "data-testid": dataTestId, navItems, mainMenu, mainMenuWidth, }: AppToolbarProps) => JSX.Element;
25
+ export declare const DotAppToolbar: ({ ariaLabel, avatar, borderColor, appName, children, className, customLogo, "data-testid": dataTestId, navItems, mainMenu, mainMenuItems, mainMenuWidth, }: AppToolbarProps) => JSX.Element;
@@ -17,7 +17,7 @@ export interface AvatarProps extends CommonProps {
17
17
  onClick?: (event: MouseEvent) => void;
18
18
  /** Size of avatar displayed */
19
19
  size?: AvatarSize;
20
- /** To be used to override syles inline */
20
+ /** To be used to override styles inline */
21
21
  style?: CSSProperties;
22
22
  /** The text to be displayed. Only the first 2 letters will be displayed. */
23
23
  text?: string;
@@ -0,0 +1,3 @@
1
+ import { AvatarColor } from './avatar/Avatar';
2
+ export declare const calculateNumberFromText: (text: string) => number;
3
+ export declare const getAvatarColorForInputText: (value: string) => AvatarColor;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital-ai/dot-components",
3
- "version": "1.0.10",
3
+ "version": "1.0.11",
4
4
  "private": false,
5
5
  "license": "SEE LICENSE IN <LICENSE.md>",
6
6
  "contributors": [