@atlaskit/atlassian-navigation 2.1.3 → 2.1.6
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 +19 -0
- package/README.md +3 -3
- package/dist/cjs/components/AtlassianNavigation/skeleton.js +4 -2
- package/dist/cjs/controllers/overflow/index.js +2 -2
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/components/AtlassianNavigation/skeleton.js +2 -1
- package/dist/es2019/controllers/overflow/index.js +2 -2
- package/dist/es2019/version.json +1 -1
- package/dist/esm/components/AtlassianNavigation/skeleton.js +2 -1
- package/dist/esm/controllers/overflow/index.js +2 -2
- package/dist/esm/version.json +1 -1
- package/dist/types/common/styles.d.ts +519 -514
- package/dist/types/components/AtlassianNavigation/skeleton.d.ts +1 -0
- package/dist/types/components/AtlassianNavigation/types.d.ts +30 -15
- package/dist/types/components/Help/index.d.ts +1 -1
- package/dist/types/components/IconButton/index.d.ts +1 -1
- package/dist/types/components/PrimaryButton/index.d.ts +1 -1
- package/dist/types/components/PrimaryDropdownButton/index.d.ts +1 -1
- package/dist/types/components/Profile/index.d.ts +1 -1
- package/dist/types/controllers/overflow/index.d.ts +2 -2
- package/package.json +7 -4
- package/skeleton/package.json +1 -0
- package/skeleton-help-button/package.json +1 -0
- package/skeleton-notification-button/package.json +1 -0
- package/skeleton-settings-button/package.json +1 -0
- package/skeleton-switcher-button/package.json +1 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { NavigationSkeletonProps } from './types';
|
|
3
3
|
export declare const NavigationSkeleton: ({ primaryItemsCount, secondaryItemsCount, theme, showSiteName, shouldShowSearch, testId, }: NavigationSkeletonProps) => JSX.Element;
|
|
4
|
+
export default NavigationSkeleton;
|
|
@@ -8,63 +8,50 @@ export interface AtlassianNavigationProps {
|
|
|
8
8
|
label: string;
|
|
9
9
|
/**
|
|
10
10
|
* Slot for the primary actions.
|
|
11
|
-
* Refer to [primary actions](atlassian-navigation/docs/primary-actions) docs for more information.
|
|
12
11
|
*/
|
|
13
12
|
primaryItems: ReactNodeArray;
|
|
14
13
|
/**
|
|
15
14
|
* Slot for the app switcher.
|
|
16
|
-
* Refer to [app switcher](atlassian-navigation/docs/app-switcher) docs for more information.
|
|
17
15
|
*/
|
|
18
16
|
renderAppSwitcher?: React.ComponentType<{}>;
|
|
19
17
|
/**
|
|
20
18
|
* Slot for the create call to action button.
|
|
21
|
-
* Refer to [create](atlassian-navigation/docs/create) docs for more information.
|
|
22
19
|
*/
|
|
23
20
|
renderCreate?: React.ComponentType<{}>;
|
|
24
21
|
/**
|
|
25
22
|
* Slot for the help button.
|
|
26
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
27
23
|
*/
|
|
28
24
|
renderHelp?: React.ComponentType<{}>;
|
|
29
25
|
/**
|
|
30
26
|
* Slot for the notification button.
|
|
31
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
32
27
|
*/
|
|
33
28
|
renderNotifications?: React.ComponentType<{}>;
|
|
34
29
|
/**
|
|
35
|
-
* Slot for the product home logo
|
|
36
|
-
* this will render your product brand.
|
|
37
|
-
* Refer to [product home](atlassian-navigation/docs/product home) docs for more information.
|
|
30
|
+
* Slot for the product home logo which renders a product's brand.
|
|
38
31
|
*/
|
|
39
32
|
renderProductHome: React.ComponentType<{}>;
|
|
40
33
|
/**
|
|
41
34
|
* Slot for the profile button.
|
|
42
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
43
35
|
*/
|
|
44
36
|
renderProfile?: React.ComponentType<{}>;
|
|
45
37
|
/**
|
|
46
38
|
* Slot for the search textbox.
|
|
47
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
48
39
|
*/
|
|
49
40
|
renderSearch?: React.ComponentType<{}>;
|
|
50
41
|
/**
|
|
51
42
|
* Slot for the sign in button.
|
|
52
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
53
43
|
*/
|
|
54
44
|
renderSignIn?: React.ComponentType<{}>;
|
|
55
45
|
/**
|
|
56
46
|
* Slot for the settings button.
|
|
57
|
-
* Refer to [secondary actions](atlassian-navigation/docs/secondary-actions) docs for more information.
|
|
58
47
|
*/
|
|
59
48
|
renderSettings?: React.ComponentType<{}>;
|
|
60
49
|
/**
|
|
61
50
|
* Label used for the overflow menu button tooltip.
|
|
62
|
-
* Refer to [overflow menu](atlassian-navigation/docs/overflow-menu) docs for more information.
|
|
63
51
|
*/
|
|
64
52
|
moreLabel?: ReactNode;
|
|
65
53
|
/**
|
|
66
|
-
*
|
|
67
|
-
* Refer to [theming](atlassian-navigation/docs/theming) docs for more information.
|
|
54
|
+
* __Slow and discouraged custom theme API.__
|
|
68
55
|
*/
|
|
69
56
|
theme?: NavigationTheme;
|
|
70
57
|
/**
|
|
@@ -83,10 +70,38 @@ export interface AtlassianNavigationProps {
|
|
|
83
70
|
testId?: string;
|
|
84
71
|
}
|
|
85
72
|
export interface NavigationSkeletonProps {
|
|
73
|
+
/**
|
|
74
|
+
* How many skeleton primary items to display.
|
|
75
|
+
*/
|
|
86
76
|
primaryItemsCount?: number;
|
|
77
|
+
/**
|
|
78
|
+
* How many skeleton secondary items to display.
|
|
79
|
+
*/
|
|
87
80
|
secondaryItemsCount?: number;
|
|
81
|
+
/**
|
|
82
|
+
* Whether to display a skeleton for the site name.
|
|
83
|
+
*/
|
|
88
84
|
showSiteName?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Whether to display a skeleton for the search bar.
|
|
87
|
+
*/
|
|
89
88
|
shouldShowSearch?: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* __Slow and discouraged custom theme API.__
|
|
91
|
+
*/
|
|
90
92
|
theme?: NavigationTheme;
|
|
93
|
+
/**
|
|
94
|
+
* A `testId` prop is provided for specified elements,
|
|
95
|
+
* which is a unique string that appears as a data attribute `data-testid` in the rendered code,
|
|
96
|
+
* serving as a hook for automated tests.
|
|
97
|
+
|
|
98
|
+
* Will set these elements when defined:
|
|
99
|
+
|
|
100
|
+
* - Header element - `{testId}-header`
|
|
101
|
+
* - Primary actions container - `{testId}-primary-actions`
|
|
102
|
+
* - Secondary actions container - `{testId}-secondary-actions`
|
|
103
|
+
* - Overflow menu popup - `{testId}-overflow-menu-popup`
|
|
104
|
+
* - Overflow menu button - `{testId}-overflow-menu-trigger`
|
|
105
|
+
*/
|
|
91
106
|
testId?: string;
|
|
92
107
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
export declare const Help: React.ForwardRefExoticComponent<import("../IconButton/types").BaseIconButtonProps & {
|
|
3
|
-
badge?: React.
|
|
3
|
+
badge?: React.ComponentType<{}> | undefined;
|
|
4
4
|
} & React.RefAttributes<any>>;
|
|
5
5
|
export default Help;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
export declare const IconButton: React.ForwardRefExoticComponent<import("./types").BaseIconButtonProps & {
|
|
3
|
-
icon:
|
|
3
|
+
icon: React.ReactChild | undefined;
|
|
4
4
|
theme?: ((current: (props: import("@atlaskit/button/custom-theme-button").ThemeProps) => import("@atlaskit/button/custom-theme-button").ThemeTokens, props: import("@atlaskit/button/custom-theme-button").ThemeProps) => import("@atlaskit/button/custom-theme-button").ThemeTokens) | undefined;
|
|
5
5
|
} & React.RefAttributes<HTMLElement>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const PrimaryButton: import("react").ForwardRefExoticComponent<
|
|
2
|
+
export declare const PrimaryButton: import("react").ForwardRefExoticComponent<Omit<import("@atlaskit/button/custom-theme-button").CustomThemeButtonProps, "appearance" | "onClick"> & {
|
|
3
3
|
isHighlighted?: boolean | undefined;
|
|
4
4
|
testId?: string | undefined;
|
|
5
5
|
tooltip?: import("react").ReactNode;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const PrimaryDropdownButton: import("react").ForwardRefExoticComponent<
|
|
2
|
+
export declare const PrimaryDropdownButton: import("react").ForwardRefExoticComponent<Omit<import("../..").PrimaryButtonProps, "iconAfter"> & {
|
|
3
3
|
isHighlighted?: boolean | undefined;
|
|
4
4
|
testId?: string | undefined;
|
|
5
5
|
tooltip?: import("react").ReactNode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { IconButtonProps } from '../IconButton/types';
|
|
3
3
|
export declare const Profile: import("react").ForwardRefExoticComponent<import("../IconButton/types").BaseIconButtonProps & {
|
|
4
|
-
icon:
|
|
4
|
+
icon: import("react").ReactChild | undefined;
|
|
5
5
|
theme?: ((current: (props: import("@atlaskit/button").ThemeProps) => import("@atlaskit/button").ThemeTokens, props: import("@atlaskit/button").ThemeProps) => import("@atlaskit/button").ThemeTokens) | undefined;
|
|
6
6
|
} & import("react").RefAttributes<HTMLElement>>;
|
|
7
7
|
declare const _default: (props: IconButtonProps) => void;
|
|
@@ -23,8 +23,8 @@ export declare const useOverflowStatus: () => {
|
|
|
23
23
|
closeOverflowMenu: () => void;
|
|
24
24
|
};
|
|
25
25
|
export declare const useOverflowController: (nodes: ReactNode | ReactNode[]) => {
|
|
26
|
-
visibleItems: React.
|
|
27
|
-
overflowItems: React.
|
|
26
|
+
visibleItems: (string | number | boolean | {} | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactNodeArray | React.ReactPortal | null | undefined)[];
|
|
27
|
+
overflowItems: (string | number | boolean | {} | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactNodeArray | React.ReactPortal | null | undefined)[];
|
|
28
28
|
updateWidth: React.Dispatch<React.SetStateAction<number>> & import("lodash").Cancelable;
|
|
29
29
|
};
|
|
30
30
|
declare const _default: (props: OverflowContextType) => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/atlassian-navigation",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.6",
|
|
4
4
|
"description": "A horizontal navigation component for Atlassian products.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -24,12 +24,12 @@
|
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@atlaskit/analytics-namespaced-context": "^6.4.0",
|
|
27
|
-
"@atlaskit/button": "^16.
|
|
27
|
+
"@atlaskit/button": "^16.3.0",
|
|
28
28
|
"@atlaskit/icon": "^21.10.0",
|
|
29
29
|
"@atlaskit/logo": "*",
|
|
30
30
|
"@atlaskit/popup": "^1.3.0",
|
|
31
31
|
"@atlaskit/theme": "^12.1.0",
|
|
32
|
-
"@atlaskit/tokens": "^0.
|
|
32
|
+
"@atlaskit/tokens": "^0.9.0",
|
|
33
33
|
"@atlaskit/tooltip": "^17.5.0",
|
|
34
34
|
"@atlaskit/width-detector": "^4.0.0",
|
|
35
35
|
"@babel/runtime": "^7.0.0",
|
|
@@ -43,6 +43,7 @@
|
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@atlaskit/analytics-next": "*",
|
|
45
45
|
"@atlaskit/atlassian-notifications": "*",
|
|
46
|
+
"@atlaskit/avatar": "*",
|
|
46
47
|
"@atlaskit/badge": "*",
|
|
47
48
|
"@atlaskit/docs": "*",
|
|
48
49
|
"@atlaskit/drawer": "*",
|
|
@@ -55,11 +56,12 @@
|
|
|
55
56
|
"@atlassian/switcher": "*",
|
|
56
57
|
"@atlassian/switcher-test-utils": "*",
|
|
57
58
|
"@testing-library/react": "^8.0.1",
|
|
59
|
+
"@testing-library/react-hooks": "^1.0.4",
|
|
58
60
|
"jest-axe": "^4.0.0",
|
|
59
61
|
"jest-emotion": "^10.0.32",
|
|
60
62
|
"react": "^16.8.0",
|
|
61
63
|
"react-intl-next": "npm:react-intl@^5.18.1",
|
|
62
|
-
"typescript": "
|
|
64
|
+
"typescript": "4.2.4"
|
|
63
65
|
},
|
|
64
66
|
"techstack": {
|
|
65
67
|
"@atlassian/frontend": {
|
|
@@ -76,5 +78,6 @@
|
|
|
76
78
|
"deprecation": "no-deprecated-imports"
|
|
77
79
|
}
|
|
78
80
|
},
|
|
81
|
+
"homepage": "https://atlassian.design/components/atlassian-navigation/",
|
|
79
82
|
"prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.1"
|
|
80
83
|
}
|
package/skeleton/package.json
CHANGED
|
@@ -3,5 +3,6 @@
|
|
|
3
3
|
"main": "../dist/cjs/skeleton-notification-button.js",
|
|
4
4
|
"module": "../dist/esm/skeleton-notification-button.js",
|
|
5
5
|
"module:es2019": "../dist/es2019/skeleton-notification-button.js",
|
|
6
|
+
"sideEffects": false,
|
|
6
7
|
"types": "../dist/types/skeleton-notification-button.d.ts"
|
|
7
8
|
}
|