@rocket.chat/fuselage 0.32.0-dev.360 → 0.32.0-dev.362

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.
@@ -0,0 +1,16 @@
1
+ import type { UsePositionOptions } from '@rocket.chat/fuselage-hooks';
2
+ import type { ComponentProps } from 'react';
3
+ import type { AriaMenuProps } from 'react-aria';
4
+ import type { MenuTriggerProps } from 'react-stately';
5
+ import { IconButton } from '../../Button';
6
+ interface MenuButtonProps<T> extends AriaMenuProps<T>, MenuTriggerProps {
7
+ icon?: ComponentProps<typeof IconButton>['icon'];
8
+ small?: boolean;
9
+ tiny?: boolean;
10
+ mini?: boolean;
11
+ placement?: UsePositionOptions['placement'];
12
+ title?: string;
13
+ }
14
+ declare const Menu: <T extends object>({ icon, placement, title, ...props }: MenuButtonProps<T>) => JSX.Element;
15
+ export default Menu;
16
+ //# sourceMappingURL=Menu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Menu.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/Menu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,6BAA6B,CAAC;AACtE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAShD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAGtD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAI1C,UAAU,eAAe,CAAC,CAAC,CAAE,SAAQ,aAAa,CAAC,CAAC,CAAC,EAAE,gBAAgB;IACrE,IAAI,CAAC,EAAE,cAAc,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;IACjD,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,SAAS,CAAC,EAAE,kBAAkB,CAAC,WAAW,CAAC,CAAC;IAC5C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AACD,QAAA,MAAM,IAAI,6FAgDT,CAAC;AACF,eAAe,IAAI,CAAC"}
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ import type { AriaMenuProps } from 'react-aria';
3
+ declare function MenuDropDown<T extends object>(props: AriaMenuProps<T>): JSX.Element;
4
+ export default MenuDropDown;
5
+ //# sourceMappingURL=MenuDropdown.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MenuDropdown.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/MenuDropdown.tsx"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAOhD,iBAAS,YAAY,CAAC,CAAC,SAAS,MAAM,EAAE,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,eAiB9D;AAED,eAAe,YAAY,CAAC"}
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ import type { TreeState } from 'react-stately';
3
+ import type { Node } from './types';
4
+ type MenuItemProps = {
5
+ item: Node<unknown>;
6
+ state: TreeState<unknown>;
7
+ };
8
+ declare function MenuItem({ item, state }: MenuItemProps): JSX.Element;
9
+ export default MenuItem;
10
+ //# sourceMappingURL=MenuItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MenuItem.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/MenuItem.tsx"],"names":[],"mappings":";AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAG/C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAEpC,KAAK,aAAa,GAAG;IACnB,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;IACpB,KAAK,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;CAC3B,CAAC;AAEF,iBAAS,QAAQ,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,aAAa,eAmB/C;AAED,eAAe,QAAQ,CAAC"}
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ import type { TreeState } from 'react-stately';
3
+ import type { Node } from './types';
4
+ type MenuSectionProps = {
5
+ section: Node<unknown>;
6
+ state: TreeState<unknown>;
7
+ };
8
+ declare function MenuSection({ section, state }: MenuSectionProps): JSX.Element;
9
+ export default MenuSection;
10
+ //# sourceMappingURL=MenuSection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MenuSection.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/MenuSection.tsx"],"names":[],"mappings":";AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAM/C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAEpC,KAAK,gBAAgB,GAAG;IACtB,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;IACvB,KAAK,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;CAC3B,CAAC;AAEF,iBAAS,WAAW,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,gBAAgB,eA4BxD;AAED,eAAe,WAAW,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { Item, Section } from 'react-stately';
2
+ import { OptionIcon, OptionAvatar, OptionColumn, OptionContent, OptionInput, OptionSkeleton, OptionTitle } from '../../Option';
3
+ export { default as MenuV2 } from './Menu';
4
+ export { Item as MenuItem, Section as MenuSection };
5
+ export { OptionAvatar as MenuItemAvatar, OptionColumn as MenuItemColumn, OptionContent as MenuItemContent, OptionIcon as MenuItemIcon, OptionInput as MenuItemInput, OptionSkeleton as MenuItemSkeleton, OptionTitle as MenuItemTitle, };
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAE9C,OAAO,EACL,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,aAAa,EACb,WAAW,EACX,cAAc,EACd,WAAW,EACZ,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,QAAQ,CAAC;AAE3C,OAAO,EAAE,IAAI,IAAI,QAAQ,EAAE,OAAO,IAAI,WAAW,EAAE,CAAC;AACpD,OAAO,EACL,YAAY,IAAI,cAAc,EAC9B,YAAY,IAAI,cAAc,EAC9B,aAAa,IAAI,eAAe,EAChC,UAAU,IAAI,YAAY,EAC1B,WAAW,IAAI,aAAa,EAC5B,cAAc,IAAI,gBAAgB,EAClC,WAAW,IAAI,aAAa,GAC7B,CAAC"}
@@ -0,0 +1,36 @@
1
+ import type { Key, ReactElement, ReactNode } from 'react';
2
+ export interface Node<T> {
3
+ /** The type of item this node represents. */
4
+ 'type': string;
5
+ /** A unique key for the node. */
6
+ 'key': Key;
7
+ /** The object value the node was created from. */
8
+ 'value': T;
9
+ /** The level of depth this node is at in the heirarchy. */
10
+ 'level': number;
11
+ /** Whether this item has children, even if not loaded yet. */
12
+ 'hasChildNodes': boolean;
13
+ /** The loaded children of this node. */
14
+ 'childNodes': Iterable<Node<T>>;
15
+ /** The rendered contents of this node (e.g. JSX). */
16
+ 'rendered': ReactNode;
17
+ /** A string value for this node, used for features like typeahead. */
18
+ 'textValue': string;
19
+ /** An accessibility label for this node. */
20
+ 'aria-label'?: string;
21
+ /** The index of this node within its parent. */
22
+ 'index'?: number;
23
+ /** A function that should be called to wrap the rendered node. */
24
+ 'wrapper'?: (element: ReactElement) => ReactElement;
25
+ /** The key of the parent node. */
26
+ 'parentKey'?: Key;
27
+ /** The key of the node before this node. */
28
+ 'prevKey'?: Key;
29
+ /** The key of the node after this node. */
30
+ 'nextKey'?: Key;
31
+ /** Additional properties specific to a particular node type. */
32
+ 'props'?: any;
33
+ /** @private */
34
+ 'shouldInvalidate'?: (context: unknown) => boolean;
35
+ }
36
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/Menu/V2/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAK1D,MAAM,WAAW,IAAI,CAAC,CAAC;IACrB,6CAA6C;IAC7C,MAAM,EAAE,MAAM,CAAC;IACf,iCAAiC;IACjC,KAAK,EAAE,GAAG,CAAC;IACX,kDAAkD;IAClD,OAAO,EAAE,CAAC,CAAC;IACX,2DAA2D;IAC3D,OAAO,EAAE,MAAM,CAAC;IAChB,8DAA8D;IAC9D,eAAe,EAAE,OAAO,CAAC;IACzB,wCAAwC;IACxC,YAAY,EAAE,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;IAChC,qDAAqD;IACrD,UAAU,EAAE,SAAS,CAAC;IACtB,sEAAsE;IACtE,WAAW,EAAE,MAAM,CAAC;IACpB,4CAA4C;IAC5C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gDAAgD;IAChD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,kEAAkE;IAClE,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,YAAY,KAAK,YAAY,CAAC;IACpD,kCAAkC;IAClC,WAAW,CAAC,EAAE,GAAG,CAAC;IAClB,4CAA4C;IAC5C,SAAS,CAAC,EAAE,GAAG,CAAC;IAChB,2CAA2C;IAC3C,SAAS,CAAC,EAAE,GAAG,CAAC;IAChB,gEAAgE;IAChE,OAAO,CAAC,EAAE,GAAG,CAAC;IACd,eAAe;IACf,kBAAkB,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,CAAC;CACpD"}
@@ -1,2 +1,3 @@
1
1
  export * from './Menu';
2
+ export * from './V2';
2
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Menu/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Menu/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,MAAM,CAAC"}