@atlaskit/side-nav-items 1.13.0 → 1.13.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @atlaskit/side-nav-items
2
2
 
3
+ ## 1.13.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`9205cdd5ef843`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9205cdd5ef843) -
8
+ (NAVX-3624): Fixing eslint suppression warnings in GSN
9
+
10
+ ## 1.13.1
11
+
12
+ ### Patch Changes
13
+
14
+ - Updated dependencies
15
+
3
16
  ## 1.13.0
4
17
 
5
18
  ### Minor Changes
@@ -3,7 +3,7 @@
3
3
  * @jsxRuntime classic
4
4
  * @jsx jsx
5
5
  */
6
- import { type ReactNode } from 'react';
6
+ import { type JSXElementConstructor, type MutableRefObject, type ReactElement, type ReactNode, type ReactPortal } from 'react';
7
7
  import { type Instruction } from '@atlaskit/pragmatic-drag-and-drop-hitbox/list-item';
8
8
  import { draggable, dropTargetForElements } from '@atlaskit/pragmatic-drag-and-drop/element/adapter';
9
9
  import { attachInstruction } from './hitbox';
@@ -52,11 +52,11 @@ export declare function useMenuItemDragAndDrop({ draggable: draggableArgs, dropT
52
52
  draggable?: TDraggableArgs;
53
53
  dropTarget?: TDropTargetArgs;
54
54
  }): {
55
- state: TMenuItemDragAndDropState;
56
- draggableButtonRef: import("react").MutableRefObject<HTMLButtonElement | null>;
57
- dropTargetRef: import("react").MutableRefObject<HTMLDivElement | null>;
58
- draggableAnchorRef: import("react").MutableRefObject<HTMLAnchorElement | null>;
59
- dragPreview: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | import("react").ReactPortal | null;
55
+ draggableAnchorRef: MutableRefObject<HTMLAnchorElement | null>;
56
+ draggableButtonRef: MutableRefObject<HTMLButtonElement | null>;
57
+ dragPreview: ReactElement<any, string | JSXElementConstructor<any>> | ReactPortal | null;
60
58
  dropIndicator: false | JSX.Element | null;
59
+ dropTargetRef: MutableRefObject<HTMLDivElement | null>;
60
+ state: TMenuItemDragAndDropState;
61
61
  };
62
62
  export {};
@@ -1,25 +1,26 @@
1
+ import { type Context } from 'react';
1
2
  type onExpansionToggle = (isExpanded: boolean) => void;
2
3
  /**
3
4
  * Whether all ancestor menu items of the current menu item are expanded. Used to know if the current menu item is
4
5
  * shown within the menu item tree.
5
6
  */
6
- export declare const AreAllAncestorsExpandedContext: import("react").Context<boolean | null>;
7
+ export declare const AreAllAncestorsExpandedContext: Context<boolean | null>;
7
8
  /**
8
9
  * A context for storing the isExpanded value of the ExpandableMenuItem.
9
10
  */
10
- export declare const IsExpandedContext: import("react").Context<boolean | null>;
11
+ export declare const IsExpandedContext: Context<boolean | null>;
11
12
  /**
12
13
  * A context for storing a function that sets isExpanded value of the ExpandableMenuItem.
13
14
  */
14
- export declare const SetIsExpandedContext: import("react").Context<((value: boolean) => void) | null>;
15
+ export declare const SetIsExpandedContext: Context<((value: boolean) => void) | null>;
15
16
  /**
16
17
  * A context for storing a function that triggers when isExpanded value of the ExpandableMenuItem is changed.
17
18
  */
18
- export declare const OnExpansionToggleContext: import("react").Context<onExpansionToggle | null>;
19
+ export declare const OnExpansionToggleContext: Context<onExpansionToggle | null>;
19
20
  /**
20
21
  * A context for storing the level value of the ExpandableMenuItem.
21
22
  */
22
- export declare const LevelContext: import("react").Context<number>;
23
+ export declare const LevelContext: Context<number>;
23
24
  export declare const useIsExpanded: () => boolean;
24
25
  export declare const useSetIsExpanded: () => ((value: boolean) => void);
25
26
  export declare const useOnExpansionToggle: () => onExpansionToggle | null;
@@ -1,4 +1,5 @@
1
+ import { type Context } from 'react';
1
2
  /**
2
3
  * A context for storing the level value of the ExpandableMenuItem.
3
4
  */
4
- export declare const ExpandableMenuItemLevelContext: import("react").Context<number>;
5
+ export declare const ExpandableMenuItemLevelContext: Context<number>;
@@ -1,18 +1,19 @@
1
+ import { type Context, type MutableRefObject, type Provider } from 'react';
1
2
  import type { FlyoutCloseSource } from './flyout-menu-item-content';
2
3
  /**
3
4
  * __Is open context__
4
5
  *
5
6
  * A context for storing the isOpen value of the FlyoutMenuItem.
6
7
  */
7
- export declare const IsOpenContext: import("react").Context<boolean>;
8
+ export declare const IsOpenContext: Context<boolean>;
8
9
  /**
9
10
  * __Set is open context__
10
11
  *
11
12
  * A context for storing a function that sets isOpen value of the FlyoutMenuItem.
12
13
  */
13
- export declare const SetIsOpenContext: import("react").Context<(value: boolean) => void>;
14
+ export declare const SetIsOpenContext: Context<(value: boolean) => void>;
14
15
  export declare const useFlyoutMenuOpen: () => boolean;
15
- export declare const useSetFlyoutMenuOpen: () => (value: boolean) => void;
16
+ export declare const useSetFlyoutMenuOpen: () => ((value: boolean) => void);
16
17
  /**
17
18
  * __On close context__
18
19
  *
@@ -20,7 +21,7 @@ export declare const useSetFlyoutMenuOpen: () => (value: boolean) => void;
20
21
  * is used by FlyoutMenuItemContent, FlyoutMenuItemTrigger and FlyoutHeader to store
21
22
  * the on close function and source information for closing the flyout menu.
22
23
  */
23
- export declare const OnCloseContext: import("react").Context<import("react").MutableRefObject<((event: Event | React.MouseEvent<HTMLButtonElement> | KeyboardEvent | MouseEvent | null, source?: FlyoutCloseSource) => void) | null>>;
24
+ export declare const OnCloseContext: Context<MutableRefObject<((event: Event | React.MouseEvent<HTMLButtonElement> | KeyboardEvent | MouseEvent | null, source?: FlyoutCloseSource) => void) | null>>;
24
25
  /**
25
26
  * __Title id context__
26
27
  *
@@ -28,11 +29,11 @@ export declare const OnCloseContext: import("react").Context<import("react").Mut
28
29
  * FlyoutHeader, and used as the aria-labelledby on the FlyoutMenuItemContent
29
30
  * container.
30
31
  */
31
- export declare const TitleIdContext: import("react").Context<string | undefined>;
32
+ export declare const TitleIdContext: Context<string | undefined>;
32
33
  export declare const useTitleId: () => string | undefined;
33
34
  /**
34
35
  * __Title id provider__
35
36
  *
36
37
  * A context provider for supplying the title id to the FlyoutHeader.
37
38
  */
38
- export declare const TitleIdContextProvider: import("react").Provider<string | undefined>;
39
+ export declare const TitleIdContextProvider: Provider<string | undefined>;
@@ -1,6 +1,7 @@
1
+ import { type Context } from 'react';
1
2
  /**
2
3
  * Context for the current menu section. It holds a unique ID for the section, used for associating the section heading
3
4
  * as an accessible label for the group.
4
5
  */
5
- export declare const MenuSectionContext: import("react").Context<string | null>;
6
+ export declare const MenuSectionContext: Context<string | null>;
6
7
  export declare const useMenuSectionContext: () => string;
@@ -3,7 +3,7 @@
3
3
  * @jsxRuntime classic
4
4
  * @jsx jsx
5
5
  */
6
- import { type ReactNode } from 'react';
6
+ import { type JSXElementConstructor, type MutableRefObject, type ReactElement, type ReactNode, type ReactPortal } from 'react';
7
7
  import { type Instruction } from '@atlaskit/pragmatic-drag-and-drop-hitbox/list-item';
8
8
  import { draggable, dropTargetForElements } from '@atlaskit/pragmatic-drag-and-drop/element/adapter';
9
9
  import { attachInstruction } from './hitbox';
@@ -52,11 +52,11 @@ export declare function useMenuItemDragAndDrop({ draggable: draggableArgs, dropT
52
52
  draggable?: TDraggableArgs;
53
53
  dropTarget?: TDropTargetArgs;
54
54
  }): {
55
- state: TMenuItemDragAndDropState;
56
- draggableButtonRef: import("react").MutableRefObject<HTMLButtonElement | null>;
57
- dropTargetRef: import("react").MutableRefObject<HTMLDivElement | null>;
58
- draggableAnchorRef: import("react").MutableRefObject<HTMLAnchorElement | null>;
59
- dragPreview: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | import("react").ReactPortal | null;
55
+ draggableAnchorRef: MutableRefObject<HTMLAnchorElement | null>;
56
+ draggableButtonRef: MutableRefObject<HTMLButtonElement | null>;
57
+ dragPreview: ReactElement<any, string | JSXElementConstructor<any>> | ReactPortal | null;
60
58
  dropIndicator: false | JSX.Element | null;
59
+ dropTargetRef: MutableRefObject<HTMLDivElement | null>;
60
+ state: TMenuItemDragAndDropState;
61
61
  };
62
62
  export {};
@@ -1,25 +1,26 @@
1
+ import { type Context } from 'react';
1
2
  type onExpansionToggle = (isExpanded: boolean) => void;
2
3
  /**
3
4
  * Whether all ancestor menu items of the current menu item are expanded. Used to know if the current menu item is
4
5
  * shown within the menu item tree.
5
6
  */
6
- export declare const AreAllAncestorsExpandedContext: import("react").Context<boolean | null>;
7
+ export declare const AreAllAncestorsExpandedContext: Context<boolean | null>;
7
8
  /**
8
9
  * A context for storing the isExpanded value of the ExpandableMenuItem.
9
10
  */
10
- export declare const IsExpandedContext: import("react").Context<boolean | null>;
11
+ export declare const IsExpandedContext: Context<boolean | null>;
11
12
  /**
12
13
  * A context for storing a function that sets isExpanded value of the ExpandableMenuItem.
13
14
  */
14
- export declare const SetIsExpandedContext: import("react").Context<((value: boolean) => void) | null>;
15
+ export declare const SetIsExpandedContext: Context<((value: boolean) => void) | null>;
15
16
  /**
16
17
  * A context for storing a function that triggers when isExpanded value of the ExpandableMenuItem is changed.
17
18
  */
18
- export declare const OnExpansionToggleContext: import("react").Context<onExpansionToggle | null>;
19
+ export declare const OnExpansionToggleContext: Context<onExpansionToggle | null>;
19
20
  /**
20
21
  * A context for storing the level value of the ExpandableMenuItem.
21
22
  */
22
- export declare const LevelContext: import("react").Context<number>;
23
+ export declare const LevelContext: Context<number>;
23
24
  export declare const useIsExpanded: () => boolean;
24
25
  export declare const useSetIsExpanded: () => ((value: boolean) => void);
25
26
  export declare const useOnExpansionToggle: () => onExpansionToggle | null;
@@ -1,4 +1,5 @@
1
+ import { type Context } from 'react';
1
2
  /**
2
3
  * A context for storing the level value of the ExpandableMenuItem.
3
4
  */
4
- export declare const ExpandableMenuItemLevelContext: import("react").Context<number>;
5
+ export declare const ExpandableMenuItemLevelContext: Context<number>;
@@ -1,18 +1,19 @@
1
+ import { type Context, type MutableRefObject, type Provider } from 'react';
1
2
  import type { FlyoutCloseSource } from './flyout-menu-item-content';
2
3
  /**
3
4
  * __Is open context__
4
5
  *
5
6
  * A context for storing the isOpen value of the FlyoutMenuItem.
6
7
  */
7
- export declare const IsOpenContext: import("react").Context<boolean>;
8
+ export declare const IsOpenContext: Context<boolean>;
8
9
  /**
9
10
  * __Set is open context__
10
11
  *
11
12
  * A context for storing a function that sets isOpen value of the FlyoutMenuItem.
12
13
  */
13
- export declare const SetIsOpenContext: import("react").Context<(value: boolean) => void>;
14
+ export declare const SetIsOpenContext: Context<(value: boolean) => void>;
14
15
  export declare const useFlyoutMenuOpen: () => boolean;
15
- export declare const useSetFlyoutMenuOpen: () => (value: boolean) => void;
16
+ export declare const useSetFlyoutMenuOpen: () => ((value: boolean) => void);
16
17
  /**
17
18
  * __On close context__
18
19
  *
@@ -20,7 +21,7 @@ export declare const useSetFlyoutMenuOpen: () => (value: boolean) => void;
20
21
  * is used by FlyoutMenuItemContent, FlyoutMenuItemTrigger and FlyoutHeader to store
21
22
  * the on close function and source information for closing the flyout menu.
22
23
  */
23
- export declare const OnCloseContext: import("react").Context<import("react").MutableRefObject<((event: Event | React.MouseEvent<HTMLButtonElement> | KeyboardEvent | MouseEvent | null, source?: FlyoutCloseSource) => void) | null>>;
24
+ export declare const OnCloseContext: Context<MutableRefObject<((event: Event | React.MouseEvent<HTMLButtonElement> | KeyboardEvent | MouseEvent | null, source?: FlyoutCloseSource) => void) | null>>;
24
25
  /**
25
26
  * __Title id context__
26
27
  *
@@ -28,11 +29,11 @@ export declare const OnCloseContext: import("react").Context<import("react").Mut
28
29
  * FlyoutHeader, and used as the aria-labelledby on the FlyoutMenuItemContent
29
30
  * container.
30
31
  */
31
- export declare const TitleIdContext: import("react").Context<string | undefined>;
32
+ export declare const TitleIdContext: Context<string | undefined>;
32
33
  export declare const useTitleId: () => string | undefined;
33
34
  /**
34
35
  * __Title id provider__
35
36
  *
36
37
  * A context provider for supplying the title id to the FlyoutHeader.
37
38
  */
38
- export declare const TitleIdContextProvider: import("react").Provider<string | undefined>;
39
+ export declare const TitleIdContextProvider: Provider<string | undefined>;
@@ -1,6 +1,7 @@
1
+ import { type Context } from 'react';
1
2
  /**
2
3
  * Context for the current menu section. It holds a unique ID for the section, used for associating the section heading
3
4
  * as an accessible label for the group.
4
5
  */
5
- export declare const MenuSectionContext: import("react").Context<string | null>;
6
+ export declare const MenuSectionContext: Context<string | null>;
6
7
  export declare const useMenuSectionContext: () => string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/side-nav-items",
3
- "version": "1.13.0",
3
+ "version": "1.13.2",
4
4
  "description": "Menu items and elements for the side nav area.",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -37,19 +37,19 @@
37
37
  "atlaskit:src": "src/index.ts",
38
38
  "dependencies": {
39
39
  "@atlaskit/analytics-next": "^11.2.0",
40
- "@atlaskit/avatar": "^25.11.0",
40
+ "@atlaskit/avatar": "^25.12.0",
41
41
  "@atlaskit/button": "^23.11.0",
42
42
  "@atlaskit/css": "^0.19.0",
43
43
  "@atlaskit/ds-lib": "^7.0.0",
44
44
  "@atlaskit/heading": "^5.4.0",
45
- "@atlaskit/icon": "^34.0.0",
45
+ "@atlaskit/icon": "^34.2.0",
46
46
  "@atlaskit/platform-feature-flags": "^1.1.0",
47
47
  "@atlaskit/popup": "^4.16.0",
48
- "@atlaskit/pragmatic-drag-and-drop": "^1.7.0",
48
+ "@atlaskit/pragmatic-drag-and-drop": "^1.8.0",
49
49
  "@atlaskit/pragmatic-drag-and-drop-hitbox": "^1.1.0",
50
50
  "@atlaskit/pragmatic-drag-and-drop-react-drop-indicator": "^3.2.0",
51
- "@atlaskit/primitives": "^18.1.0",
52
- "@atlaskit/tokens": "^12.0.0",
51
+ "@atlaskit/primitives": "^19.0.0",
52
+ "@atlaskit/tokens": "^13.0.0",
53
53
  "@atlaskit/tooltip": "^21.1.0",
54
54
  "@babel/runtime": "^7.0.0",
55
55
  "@compiled/react": "^0.20.0",
@@ -63,9 +63,9 @@
63
63
  "@af/accessibility-testing": "workspace:^",
64
64
  "@af/integration-testing": "workspace:^",
65
65
  "@af/visual-regression": "workspace:^",
66
- "@atlaskit/app-provider": "^4.2.0",
67
- "@atlaskit/lozenge": "^13.6.0",
68
- "@atlaskit/navigation-system": "^7.2.0",
66
+ "@atlaskit/app-provider": "^4.3.0",
67
+ "@atlaskit/lozenge": "^13.7.0",
68
+ "@atlaskit/navigation-system": "^8.0.0",
69
69
  "@atlaskit/ssr": "workspace:^",
70
70
  "@atlassian/a11y-jest-testing": "^0.11.0",
71
71
  "@atlassian/feature-flags-test-utils": "^1.0.0",