@atlaskit/navigation-system 7.1.2 → 7.1.4
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 +16 -0
- package/constellation/layout/examples.mdx +88 -59
- package/constellation/layout/images/layout-anatomy-dark.png +0 -0
- package/constellation/layout/images/layout-anatomy-light.png +0 -0
- package/constellation/layout/images/layout-do-dark.png +0 -0
- package/constellation/layout/images/layout-do-light.png +0 -0
- package/constellation/layout/images/layout-dont-dark.png +0 -0
- package/constellation/layout/images/layout-dont-light.png +0 -0
- package/constellation/layout/images/layout-example-dark.png +0 -0
- package/constellation/layout/images/layout-example-light.png +0 -0
- package/constellation/layout/images/layout-example-sideNav-dark.png +0 -0
- package/constellation/layout/images/layout-example-sideNav-light.png +0 -0
- package/constellation/layout/images/layout-example-topNav-1-dark.png +0 -0
- package/constellation/layout/images/layout-example-topNav-1-light.png +0 -0
- package/constellation/layout/images/layout-example-topNav-2-dark.png +0 -0
- package/constellation/layout/images/layout-example-topNav-2-light.png +0 -0
- package/constellation/layout/usage.mdx +32 -24
- package/constellation/top-nav-items/examples.mdx +62 -54
- package/constellation/top-nav-items/images/topNavItems-anatomy-dark.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-anatomy-light.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-do-1-dark.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-do-1-light.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-do-2-dark.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-do-2-light.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-dont-1-dark.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-dont-1-light.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-dont-2-dark.png +0 -0
- package/constellation/top-nav-items/images/topNavItems-dont-2-light.png +0 -0
- package/constellation/top-nav-items/usage.mdx +28 -12
- package/package.json +10 -10
- package/constellation/layout/diagram.tsx +0 -115
- package/constellation/layout/images/layout-anatomy.png +0 -0
- package/constellation/layout/images/layout-do.png +0 -0
- package/constellation/layout/images/layout-dont.png +0 -0
- package/constellation/top-nav-items/images/top-nav-anatomy.png +0 -0
- package/constellation/top-nav-items/images/top-nav-do-1.png +0 -0
- package/constellation/top-nav-items/images/top-nav-do-2.png +0 -0
- package/constellation/top-nav-items/images/top-nav-dont-1.png +0 -0
- package/constellation/top-nav-items/images/top-nav-dont-2.png +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @atlassian/navigation-system
|
|
2
2
|
|
|
3
|
+
## 7.1.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`e2085d35701ca`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e2085d35701ca) -
|
|
8
|
+
Internal changes to remove unnecessary token fallbacks and imports from `@atlaskit/theme`
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
11
|
+
## 7.1.3
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- [`08170da1fbf62`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/08170da1fbf62) -
|
|
16
|
+
Migrate spacing prop usages on icons to Flex wrapper
|
|
17
|
+
- Updated dependencies
|
|
18
|
+
|
|
3
19
|
## 7.1.2
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
|
@@ -4,18 +4,33 @@ description: Layout components define a page’s structure and the areas for nav
|
|
|
4
4
|
order: 1
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
+
import Image from '@atlaskit/image';
|
|
8
|
+
|
|
9
|
+
import layoutExampleLight from './images/layout-example-light.png';
|
|
10
|
+
import layoutExampleDark from './images/layout-example-dark.png';
|
|
11
|
+
import layoutExampleSideNavLight from './images/layout-example-sideNav-light.png';
|
|
12
|
+
import layoutExampleSideNavDark from './images/layout-example-sideNav-dark.png';
|
|
13
|
+
import layoutExampleTopNav1Light from './images/layout-example-topNav-1-light.png';
|
|
14
|
+
import layoutExampleTopNav1Dark from './images/layout-example-topNav-1-dark.png';
|
|
15
|
+
import layoutExampleTopNav2Light from './images/layout-example-topNav-2-light.png';
|
|
16
|
+
import layoutExampleTopNav2Dark from './images/layout-example-topNav-2-dark.png';
|
|
17
|
+
|
|
7
18
|
import SectionMessage from '@atlaskit/section-message';
|
|
8
19
|
|
|
9
20
|
import { CustomSkipLinkExample } from '../../examples/constellation/layout/custom-skip-links';
|
|
10
21
|
import { ExpandSideNavButtonExample } from '../../examples/constellation/layout/expand-side-nav';
|
|
11
22
|
import { ToggleSideNavKeyboardShortcutExample } from '../../examples/constellation/layout/toggle-side-nav-keyboard-shortcut';
|
|
12
23
|
|
|
13
|
-
import { PageLayoutDiagram } from './diagram';
|
|
14
|
-
|
|
15
24
|
The full page layout with all areas rendered has the structure depicted below, or see the
|
|
16
25
|
[interactive example](https://go.atlassian.com/nav4-interactive-example).
|
|
17
26
|
|
|
18
|
-
<
|
|
27
|
+
<Image
|
|
28
|
+
src={layoutExampleLight}
|
|
29
|
+
srcDark={layoutExampleDark}
|
|
30
|
+
alt="Example of the navigation system layout areas"
|
|
31
|
+
/>
|
|
32
|
+
|
|
33
|
+
The top nav overlaps the side nav when it is expanded to give the appearance of a full height side nav.
|
|
19
34
|
|
|
20
35
|
When composing your page layout ensure that:
|
|
21
36
|
|
|
@@ -27,7 +42,7 @@ When composing your page layout ensure that:
|
|
|
27
42
|
These are the distinct areas in the layout. These components are designed to contain other
|
|
28
43
|
components and content.
|
|
29
44
|
|
|
30
|
-
|
|
45
|
+
For examples, see [navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE).
|
|
31
46
|
|
|
32
47
|
### Banner
|
|
33
48
|
|
|
@@ -39,20 +54,33 @@ the top of the screen.
|
|
|
39
54
|
Use the top nav area to render [top nav items](/components/navigation-system/top-nav-items).
|
|
40
55
|
|
|
41
56
|
- It will display at the top of the screen, below the banner if one is present. It has a fixed
|
|
42
|
-
height of
|
|
57
|
+
height of 56px.
|
|
43
58
|
- Use the [top nav slots](#top-nav-slots) to position actions within top nav.
|
|
44
|
-
- The top nav is [
|
|
45
|
-
|
|
59
|
+
- The top nav is responsive, with the [top nav items](/components/navigation-system/top-nav-items) changing according to the viewport size.
|
|
60
|
+
|
|
61
|
+
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
46
62
|
|
|
47
63
|
#### Top nav slots
|
|
48
64
|
|
|
49
65
|
The top nav has three layout components that you must use to position
|
|
50
66
|
[top nav items](/components/navigation-system/top-nav-items) within the top nav flexbox.
|
|
51
67
|
|
|
52
|
-
- `TopNavStart`: Area for left-aligned items.
|
|
68
|
+
- `TopNavStart`: Area for left-aligned items. Appears in the side nav when the side nav is expanded to give the appearance of a full height sidebar.
|
|
53
69
|
- `TopNavMiddle`: Area for centre-aligned items.
|
|
54
70
|
- `TopNavEnd`: Area for right-aligned items.
|
|
55
71
|
|
|
72
|
+
<Image
|
|
73
|
+
src={layoutExampleTopNav1Light}
|
|
74
|
+
srcDark={layoutExampleTopNav1Dark}
|
|
75
|
+
alt="Example of the top nav slots - side nav collapsed"
|
|
76
|
+
/>
|
|
77
|
+
|
|
78
|
+
<Image
|
|
79
|
+
src={layoutExampleTopNav2Light}
|
|
80
|
+
srcDark={layoutExampleTopNav2Dark}
|
|
81
|
+
alt="Example of the top nav slots - side nav opened"
|
|
82
|
+
/>
|
|
83
|
+
|
|
56
84
|
#### Top nav custom theming
|
|
57
85
|
|
|
58
86
|
See the [custom theming](/components/navigation-system/layout/custom-theming) tab.
|
|
@@ -63,7 +91,9 @@ See the [custom theming](/components/navigation-system/layout/custom-theming) ta
|
|
|
63
91
|
render [side nav items](https://atlaskit.atlassian.com/packages/navigation/side-nav-items). It
|
|
64
92
|
will show on the left of the screen. The default width of the side nav is 320px.
|
|
65
93
|
- Use the [side nav slots](#side-nav-slots) to position content within the side nav.
|
|
66
|
-
- The side nav is collapsable and expandable, resizable, responsive, and offers flyout behaviour.
|
|
94
|
+
- The side nav is [collapsable and expandable](#side-nav-collapseexpand), [resizable](#side-nav-resizing), [responsive](#side-nav-responsive), and offers [flyout](#side-nav-flyout) behaviour.
|
|
95
|
+
|
|
96
|
+
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
67
97
|
|
|
68
98
|
#### Side nav slots
|
|
69
99
|
|
|
@@ -78,10 +108,28 @@ flexbox.
|
|
|
78
108
|
Note: make sure to render `SideNavBody` to ensure that the footer is positioned at the bottom of the
|
|
79
109
|
side nav, simulating a sticky footer.
|
|
80
110
|
|
|
111
|
+
<Image
|
|
112
|
+
src={layoutExampleSideNavLight}
|
|
113
|
+
srcDark={layoutExampleSideNavDark}
|
|
114
|
+
alt="Example of the side nav slots"
|
|
115
|
+
/>
|
|
116
|
+
|
|
81
117
|
#### Side nav collapse/expand
|
|
82
118
|
|
|
83
|
-
The side nav can
|
|
84
|
-
|
|
119
|
+
The side nav can collapse and expand based on user input or programmatically through hooks.
|
|
120
|
+
|
|
121
|
+
##### Toggle button
|
|
122
|
+
|
|
123
|
+
The side nav can collapse and expand using the `SideNavToggleButton` from
|
|
124
|
+
[top nav items](/components/navigation-system/top-nav-items/examples#start-items) or the keyboard shortcut.
|
|
125
|
+
|
|
126
|
+
##### Keyboard shortcut
|
|
127
|
+
|
|
128
|
+
The keyboard shortcut Ctrl+[ is enabled globally through the `isSideNavShortcutEnabled` on `Root`. It’s disabled by default.
|
|
129
|
+
|
|
130
|
+
When enabled, additional checks can be performed on individual keypresses through the `canToggleWithShortcut` prop on the side nav. This allows for apps to conditionally disable the shortcut based on additional app-specific requirements.
|
|
131
|
+
|
|
132
|
+
##### Programmatic / Hooks
|
|
85
133
|
|
|
86
134
|
There are two hooks available for programmatically toggling the side nav.
|
|
87
135
|
|
|
@@ -93,7 +141,7 @@ There are two hooks available for programmatically toggling the side nav.
|
|
|
93
141
|
, as they require the internal React context that it provides.
|
|
94
142
|
</SectionMessage>
|
|
95
143
|
|
|
96
|
-
|
|
144
|
+
**useExpandSideNav**
|
|
97
145
|
|
|
98
146
|
Returns a function that will expand the side nav.
|
|
99
147
|
|
|
@@ -101,8 +149,9 @@ This can be useful for ensuring the side nav is expanded before displaying an on
|
|
|
101
149
|
for example. If the side nav is already expanded, it will simply no-op.
|
|
102
150
|
|
|
103
151
|
<Example Component={ExpandSideNavButtonExample} appearance="source-only" />
|
|
152
|
+
<br />
|
|
104
153
|
|
|
105
|
-
|
|
154
|
+
**useToggleSideNav**
|
|
106
155
|
|
|
107
156
|
Returns a function that will toggle the side nav.
|
|
108
157
|
|
|
@@ -114,39 +163,32 @@ This is useful for toggling the side nav based on a keyboard shortcut.
|
|
|
114
163
|
|
|
115
164
|
- In the collapsed state, hovering over the `SideNavToggleButton` from
|
|
116
165
|
[top nav items](/components/navigation-system/top-nav-items/examples#start-items) will trigger the
|
|
117
|
-
side nav to open as an overlay. Moving the
|
|
166
|
+
side nav to open as an overlay. Moving the cursor away will close it. If there are any open
|
|
118
167
|
supported ADS layering components (e.g. popups, dropdown menus) within the side nav, the flyout
|
|
119
168
|
will stay locked open, until the layering components are closed.
|
|
120
169
|
|
|
121
170
|
- The expansion and collapse of the side nav flyout is animated on **supported browsers**.
|
|
122
171
|
Currently, Firefox does not support the animation. Instead, it will instantly expand and collapse.
|
|
123
172
|
|
|
124
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
125
|
-
|
|
126
173
|
#### Side nav resizing
|
|
127
174
|
|
|
128
|
-
|
|
129
|
-
side nav resizable. It is resized using the drag handle. When hovering on the drag handle the
|
|
130
|
-
mouse pointer changes to a resize pointer.
|
|
131
|
-
- The side nav can be resized to a minimum width of 240px, and a maximum width equal to 50% of the
|
|
132
|
-
total viewport width. It retains this resized width even after collapsing, reopening, or
|
|
133
|
-
refreshing the page. When resizing, any open layer components (e.g. popups, dropdowns, selects,
|
|
134
|
-
tooltips) will be closed.
|
|
135
|
-
- The side nav panel splitter can be also double clicked to collapse the side nav.
|
|
136
|
-
|
|
137
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
175
|
+
You can optionally render a [side nav panel splitter](#resizable-areas) as a child to make the side nav resizable.
|
|
138
176
|
|
|
177
|
+
- The side nav is resized using the drag handle. When you hover over the drag handle, the mouse pointer changes to a resize cursor.
|
|
178
|
+
- The side nav can be resized to a minimum width of 240px and a maximum width equal to 50% of the viewport width.
|
|
179
|
+
- The side nav retains its resized width after it's collapsed or expanded. Persist the chosen width across page refreshes by providing it to the `defaultWidth` prop.
|
|
180
|
+
- When resizing, any open layer components (for example, popups, dropdowns, selects, and tooltips) are closed.
|
|
181
|
+
- You can also double-click the side nav panel splitter to collapse the side nav.
|
|
182
|
+
|
|
139
183
|
#### Side nav responsive
|
|
140
184
|
|
|
141
185
|
- At `s`, `xs`, and `xxs` breakpoints (i.e. viewports smaller than 1024px), the side nav
|
|
142
186
|
automatically collapses to make room for the content. Users have the option to manually
|
|
143
|
-
[open or close
|
|
187
|
+
[open or close](/components/navigation-system/layout/examples#side-nav-collapseexpand) the side nav
|
|
144
188
|
according to their preferences. Doing so will open it as an overlay.
|
|
145
189
|
- At `xs` and `xxs` breakpoints (i.e. viewports smaller than 768px), the max width of the overlay
|
|
146
190
|
side nav is either 320px or 90% of the screen width - whichever value is smaller.
|
|
147
191
|
|
|
148
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
149
|
-
|
|
150
192
|
### Main
|
|
151
193
|
|
|
152
194
|
Use the main area for the [page header](/components/page-header) and main page content. It will
|
|
@@ -157,10 +199,12 @@ expand to fill available space.
|
|
|
157
199
|
- On small viewports, the element will always use body scroll, to make it easier to scroll the page
|
|
158
200
|
when the content is tall.
|
|
159
201
|
|
|
202
|
+
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
203
|
+
|
|
160
204
|
### Aside
|
|
161
205
|
|
|
162
206
|
<SectionMessage appearance="warning" title="Caution">
|
|
163
|
-
|
|
207
|
+
We plan to deprecate aside. Use panel instead.
|
|
164
208
|
</SectionMessage>
|
|
165
209
|
|
|
166
210
|
The aside area is rendered to the right of the main area.
|
|
@@ -180,19 +224,13 @@ The aside area is rendered to the right of the main area.
|
|
|
180
224
|
You can optionally render a [panel splitter](#resizable-areas) as a child to make the aside
|
|
181
225
|
resizable.
|
|
182
226
|
|
|
183
|
-
-
|
|
184
|
-
|
|
185
|
-
-
|
|
186
|
-
total viewport width. It retains this resized width even after refreshing the page.
|
|
187
|
-
|
|
188
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
227
|
+
- The aside is resized using the drag handle. When you hover over the drag handle, the mouse pointer changes to a resize cursor.
|
|
228
|
+
- The aside can be resized to a minimum width of 120px and a maximum width equal to 50% of the viewport width.
|
|
229
|
+
- Persist the chosen width across page refreshes by providing it to the `defaultWidth` prop.
|
|
189
230
|
|
|
190
231
|
#### Aside responsive
|
|
191
232
|
|
|
192
|
-
At `s`, `xs`, and `xxs` breakpoints (i.e. viewports smaller than 1024px), the aside moves below the
|
|
193
|
-
main area, and conforms to main width and behaviour.
|
|
194
|
-
|
|
195
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
233
|
+
At `s`, `xs`, and `xxs` breakpoints (i.e. viewports smaller than 1024px), the aside moves below the main area, and conforms to main width and behaviour.
|
|
196
234
|
|
|
197
235
|
### Panel
|
|
198
236
|
|
|
@@ -204,34 +242,25 @@ The panel area is rendered to the right of the main and aside areas.
|
|
|
204
242
|
[resizable](/components/navigation-system/layout/examples#panel-resizing), and
|
|
205
243
|
[responsive](/components/navigation-system/layout/examples#panel-responsive).
|
|
206
244
|
|
|
207
|
-
|
|
208
|
-
[Preview panel](https://atlaskit-website-staging.stg-east.frontend.public.atl-paas.net/#/packages/navigation/preview-panel)
|
|
245
|
+
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
209
246
|
|
|
210
247
|
#### Panel collapse/expand
|
|
211
248
|
|
|
212
249
|
The panel can be collapsed and expanded using a trigger of your choosing.
|
|
213
250
|
|
|
214
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
215
|
-
|
|
216
251
|
#### Panel resizing
|
|
217
252
|
|
|
218
253
|
You can optionally render a [panel splitter](#resizable-areas) as a child to make the panel
|
|
219
|
-
resizable.
|
|
220
|
-
pointer changes to a resize pointer.
|
|
221
|
-
|
|
222
|
-
- The panel can be resized larger than the `defaultWidth` to a maximum of 50% of content area
|
|
223
|
-
(viewport minus the side nav area).
|
|
224
|
-
- It retains this resized width even after collapsing, reopening, or refreshing the page.
|
|
225
|
-
- It has no ability to resize smaller than `defaultWidth`.
|
|
254
|
+
resizable.
|
|
226
255
|
|
|
227
|
-
|
|
256
|
+
- The panel is resized using the drag handle. When you hover over the drag handle, the mouse pointer changes to a resize cursor.
|
|
257
|
+
- The panel can be resized larger than `defaultWidth` to a maximum of 50% of the content area (viewport minus the side nav area). The panel can't be resized smaller than `defaultWidth`.
|
|
258
|
+
- The panel retains its resized width after it's collapsed or expanded. Persist the chosen width across page refreshes by providing it to the `defaultWidth` prop.
|
|
228
259
|
|
|
229
260
|
#### Panel responsive
|
|
230
261
|
|
|
231
|
-
At `m` breakpoints (between 1024-1440px), the panel will overlay the aside area. At `s` breakpoints
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
262
|
+
At `m` breakpoints (between 1024-1440px), the panel will overlay the aside area. At `s` breakpoints and
|
|
263
|
+
below (less than 1024px) it will start to overlay the main area.
|
|
235
264
|
|
|
236
265
|
## Resizable areas
|
|
237
266
|
|
|
@@ -239,9 +268,9 @@ Render a `PanelSplitter` in a layout area to make it resizable.
|
|
|
239
268
|
|
|
240
269
|
Resizing is supported for the following areas:
|
|
241
270
|
|
|
242
|
-
- [Side nav](/components/navigation-system/layout/examples#side-nav)
|
|
243
|
-
- [Aside](/components/navigation-system/layout/examples#aside)
|
|
244
|
-
- [Panel](/components/navigation-system/layout/examples#panel)
|
|
271
|
+
- [Side nav](/components/navigation-system/layout/examples#side-nav): Use `SideNavPanelSplitter`
|
|
272
|
+
- [Aside](/components/navigation-system/layout/examples#aside): Use `PanelSplitter`
|
|
273
|
+
- [Panel](/components/navigation-system/layout/examples#panel): Use `PanelSplitter`
|
|
245
274
|
|
|
246
275
|
[View interactive example](https://go.atlassian.com/nav4-interactive-example)
|
|
247
276
|
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -4,8 +4,14 @@ description: Layout components define a page’s structure and the areas for nav
|
|
|
4
4
|
order: 4
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
import
|
|
8
|
-
|
|
7
|
+
import Image from '@atlaskit/image';
|
|
8
|
+
|
|
9
|
+
import layoutAnatomyLight from './images/layout-anatomy-light.png';
|
|
10
|
+
import layoutAnatomyDark from './images/layout-anatomy-dark.png';
|
|
11
|
+
import layoutDoLight from './images/layout-do-light.png';
|
|
12
|
+
import layoutDoDark from './images/layout-do-dark.png';
|
|
13
|
+
import layoutDontLight from './images/layout-dont-light.png';
|
|
14
|
+
import layoutDontDark from './images/layout-dont-dark.png';
|
|
9
15
|
|
|
10
16
|
import SectionMessage from '@atlaskit/section-message';
|
|
11
17
|
|
|
@@ -14,10 +20,13 @@ import SectionMessage from '@atlaskit/section-message';
|
|
|
14
20
|
Use layout to compose the structure of your application. It also defines the page behavior and
|
|
15
21
|
navigational areas.
|
|
16
22
|
|
|
17
|
-
When applying components to the navigational areas,
|
|
18
|
-
[see navigation experience guidelines (Atlassians only)](https://hello.atlassian.net/wiki/spaces/navx/pages/5104144812).
|
|
23
|
+
When applying components to the navigational areas, [see navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/spaces/navx/pages/5104144812).
|
|
19
24
|
|
|
20
|
-
|
|
25
|
+
<Image
|
|
26
|
+
src={layoutAnatomyLight}
|
|
27
|
+
srcDark={layoutAnatomyDark}
|
|
28
|
+
alt="Diagram of the navigation system layout areas"
|
|
29
|
+
/>
|
|
21
30
|
|
|
22
31
|
<ol>
|
|
23
32
|
<li>
|
|
@@ -28,7 +37,7 @@ When applying components to the navigational areas,
|
|
|
28
37
|
<a href="/components/navigation-system/top-nav-items">top nav items</a>.
|
|
29
38
|
<ol type="a">
|
|
30
39
|
<li>
|
|
31
|
-
<strong>Top nav start:</strong> Area for left-aligned actions.
|
|
40
|
+
<strong>Top nav start:</strong> Area for left-aligned actions. Appears in the side nav when the side nav is expanded.
|
|
32
41
|
</li>
|
|
33
42
|
<li>
|
|
34
43
|
<strong>Top nav middle:</strong> Area for centre-aligned actions.
|
|
@@ -39,10 +48,9 @@ When applying components to the navigational areas,
|
|
|
39
48
|
</ol>
|
|
40
49
|
</li>
|
|
41
50
|
<li>
|
|
42
|
-
<strong>Side nav:</strong> Use to display
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
<ol type="a" start="4">
|
|
51
|
+
<strong>Side nav:</strong> Use to display <a href="https://atlaskit.atlassian.com/packages/navigation/side-nav-items">side nav items</a>. Is resizable and
|
|
52
|
+
collapsible.
|
|
53
|
+
<ol type="a">
|
|
46
54
|
<li>
|
|
47
55
|
<strong>Side nav header:</strong> Optional. Top part of the side nav (fixed).
|
|
48
56
|
</li>
|
|
@@ -60,7 +68,7 @@ When applying components to the navigational areas,
|
|
|
60
68
|
</li>
|
|
61
69
|
<li>
|
|
62
70
|
<strong>Aside:</strong> Optional. Use to display supporting or supplementary content. Is
|
|
63
|
-
resizable. <em>We plan to deprecate
|
|
71
|
+
resizable. <em>We plan to deprecate aside, please use panel instead.</em>
|
|
64
72
|
</li>
|
|
65
73
|
<li>
|
|
66
74
|
<strong>Panel:</strong> Optional. Use to display supporting or supplementary content. Is
|
|
@@ -71,26 +79,25 @@ When applying components to the navigational areas,
|
|
|
71
79
|
### The difference between aside, panel and modal dialog
|
|
72
80
|
|
|
73
81
|
<SectionMessage appearance="warning" title="Caution">
|
|
74
|
-
We
|
|
82
|
+
We plan to deprecate aside. Use panel instead.
|
|
75
83
|
</SectionMessage>
|
|
76
84
|
|
|
77
85
|
The main difference between aside, panel and modal dialog is their behaviours:
|
|
78
86
|
|
|
79
87
|
- **Aside** is not collapsible, while **panel** can be collapsible.
|
|
80
|
-
- **Panel** and **aside** present content alongside the **main** area, while **modal dialog**
|
|
88
|
+
- **Panel** and **aside** present content alongside the **main** area, while a **modal dialog** appears
|
|
81
89
|
in a layer above the page.
|
|
82
90
|
- On small viewports (1024px and below), the **panel** becomes an overlay, while the **aside** moves
|
|
83
|
-
below **main
|
|
91
|
+
below the **main** area.
|
|
84
92
|
|
|
85
|
-
#### Usage guidance
|
|
93
|
+
#### Usage guidance
|
|
86
94
|
|
|
87
|
-
- Use **
|
|
88
|
-
|
|
89
|
-
- Use **panel** for contextual information or tertiary actions that complement the user's workflow.
|
|
90
|
-
Panels enable greater multitasking by functioning as an additional work space, while keeping users
|
|
95
|
+
- Use the **panel** for contextual information or tertiary actions that complement the user's workflow.
|
|
96
|
+
Panels enable multitasking by providing an additional work space, while keeping users
|
|
91
97
|
connected to their primary task.
|
|
92
|
-
- Use **modal dialog** when you need
|
|
93
|
-
task,
|
|
98
|
+
- Use a **modal dialog** when you need the user to focus on a specific
|
|
99
|
+
task, such as making a decision or completing an action, before they can return to their primary task.
|
|
100
|
+
- Don’t use aside for new experiences. It is planned for deprecation.
|
|
94
101
|
|
|
95
102
|
## Best practices
|
|
96
103
|
|
|
@@ -100,7 +107,8 @@ The main difference between aside, panel and modal dialog is their behaviours:
|
|
|
100
107
|
<DoDont
|
|
101
108
|
type="do"
|
|
102
109
|
image={{
|
|
103
|
-
url:
|
|
110
|
+
url: layoutDoLight,
|
|
111
|
+
urlDarkMode: layoutDoDark,
|
|
104
112
|
alt: 'A layout with a grid overlay on the Main area.',
|
|
105
113
|
}}
|
|
106
114
|
isFullWidth
|
|
@@ -111,7 +119,8 @@ The main difference between aside, panel and modal dialog is their behaviours:
|
|
|
111
119
|
<DoDont
|
|
112
120
|
type="dont"
|
|
113
121
|
image={{
|
|
114
|
-
url:
|
|
122
|
+
url: layoutDontLight,
|
|
123
|
+
urlDarkMode: layoutDontDark,
|
|
115
124
|
alt: 'A layout with a grid overlay on the Main area, but also on the Side nav, Aside and Panel areas.',
|
|
116
125
|
}}
|
|
117
126
|
isFullWidth
|
|
@@ -125,4 +134,3 @@ The main difference between aside, panel and modal dialog is their behaviours:
|
|
|
125
134
|
- [Page header](/components/page-header)
|
|
126
135
|
- [Top nav items](/components/navigation-system/top-nav-items)
|
|
127
136
|
- [Navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE)
|
|
128
|
-
- [Preview panel (Atlassians only)](https://atlaskit-website-staging.stg-east.frontend.public.atl-paas.net/#/packages/navigation/preview-panel)
|
|
@@ -7,6 +7,7 @@ order: 1
|
|
|
7
7
|
import SectionMessage from '@atlaskit/section-message';
|
|
8
8
|
|
|
9
9
|
import { TopNavStartLayoutExample } from '../../examples/constellation/top-nav-items/top-nav-start';
|
|
10
|
+
import { TopNavStartToggleExample } from '../../examples/constellation/top-nav-items/top-nav-start-toggle';
|
|
10
11
|
import { TopNavMiddleLayoutExample } from '../../examples/constellation/top-nav-items/top-nav-middle';
|
|
11
12
|
import { TopNavEndLayoutExample } from '../../examples/constellation/top-nav-items/top-nav-end';
|
|
12
13
|
import { AppLogoExample } from '../../examples/constellation/top-nav-items/app-logo';
|
|
@@ -18,89 +19,96 @@ import { EndItemExample } from '../../examples/constellation/top-nav-items/end-i
|
|
|
18
19
|
import { TopNavButtonExample } from '../../examples/constellation/top-nav-items/top-nav-button';
|
|
19
20
|
import { CustomTitleExample } from '../../examples/constellation/top-nav-items/custom-title';
|
|
20
21
|
|
|
21
|
-
These components can be used within the
|
|
22
|
-
[top nav](/components/navigation-system/layout/examples#top-nav).
|
|
22
|
+
These components can be used within the top nav from [layout](/components/navigation-system/layout/examples).
|
|
23
23
|
|
|
24
24
|
For other components that can be used within the top nav, see
|
|
25
|
-
[navigation
|
|
25
|
+
[navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE).
|
|
26
26
|
|
|
27
27
|
## Start items
|
|
28
28
|
|
|
29
|
-
These actions go in the [
|
|
30
|
-
area.
|
|
29
|
+
These actions go in the [top nav start](/components/navigation-system/layout/examples#top-nav-slots)
|
|
30
|
+
area.
|
|
31
31
|
|
|
32
|
-
-
|
|
32
|
+
- Side nav toggle button: Opens and closes the
|
|
33
33
|
[side nav](/components/navigation-system/layout/examples#side-nav).
|
|
34
|
-
-
|
|
35
|
-
[navigation
|
|
34
|
+
- App switcher: Opens and closes an app switcher. See
|
|
35
|
+
[navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE)
|
|
36
36
|
for recommended platform components.
|
|
37
37
|
|
|
38
38
|
Use one of the following logo components to orient users and provide a persistent link to the app
|
|
39
39
|
landing page:
|
|
40
40
|
|
|
41
|
-
- [
|
|
42
|
-
- [
|
|
43
|
-
- [
|
|
41
|
+
- [App logo](#app-logo): A container for an app's [logo icon](/components/logo) and name.
|
|
42
|
+
- [Custom logo](#custom-logo): A container for custom logo images.
|
|
43
|
+
- [Custom title](#custom-title): Optional text used for app customisation by customers.
|
|
44
44
|
|
|
45
45
|
<Example Component={TopNavStartLayoutExample} />
|
|
46
46
|
|
|
47
|
-
###
|
|
47
|
+
### Side nav toggle button
|
|
48
48
|
|
|
49
|
-
`
|
|
49
|
+
The side nav toggle button must be passed to `TopNavStart` through the `sideNavToggleButton` prop, not via `children`.
|
|
50
|
+
- When the keyboard shortcut is enabled, the toggle button’s tooltip will automatically show Ctrl+[ as the shortcut.
|
|
51
|
+
- The toggle button is left-aligned when the side nav is collapsed, and right-aligned when the side nav is expanded.
|
|
50
52
|
|
|
51
|
-
|
|
53
|
+
<Example Component={TopNavStartToggleExample} />
|
|
54
|
+
|
|
55
|
+
### App logo
|
|
56
|
+
|
|
57
|
+
App logo displays an app [logo icon](/components/logo) and name.
|
|
58
|
+
- It has a maximum width of 320px, after which the app name truncates. The app name also truncates based on the available space when the side nav is resized.
|
|
52
59
|
- At `s` breakpoints and below (less that 1024px), the app name is not shown.
|
|
53
60
|
|
|
54
|
-
See the [
|
|
61
|
+
See the [responsive section](#responsive) for more information.
|
|
55
62
|
|
|
56
63
|
<Example Component={AppLogoExample} />
|
|
57
64
|
|
|
58
|
-
###
|
|
65
|
+
### Custom logo
|
|
59
66
|
|
|
60
|
-
|
|
67
|
+
Custom logo provides a container for custom logo images with the following constraints:
|
|
68
|
+
- Maximum width: 320px. If the image is wider than this, or if space is limited when the side nav is resized, the logo will scale down to fit.
|
|
69
|
+
- Maximum height: 24px. If the image is shorter than this, the logo will scale up to fit.
|
|
61
70
|
|
|
62
|
-
|
|
63
|
-
- Max height 24px. If smaller, the logo will scale up to fit.
|
|
71
|
+
Do not provide explicit width and height values on the image, otherwise it will not respect the container size.
|
|
64
72
|
|
|
65
|
-
|
|
66
|
-
At `s` breakpoints and below (less that 1024px), the provided icon is shown. Above `s` breakpoints,
|
|
73
|
+
At `s` breakpoints and below (less that 1024px), only the provided icon is shown. Above `s` breakpoints,
|
|
67
74
|
the provided logo is shown.
|
|
68
75
|
|
|
69
|
-
See the [
|
|
76
|
+
See the [responsive section](#responsive) for more information.
|
|
70
77
|
|
|
71
78
|
<Example Component={CustomLogoExample} />
|
|
72
79
|
|
|
73
|
-
###
|
|
80
|
+
### Custom title
|
|
74
81
|
|
|
75
82
|
Optional text used for app customisation by customers.
|
|
76
83
|
|
|
77
|
-
When present, it
|
|
78
|
-
|
|
84
|
+
- When present, it appears to the right of the logo.
|
|
85
|
+
- It has a maximum width of 200px, after which the text truncates. It also truncates based on the available space when the side nav is resized.
|
|
86
|
+
- At `s` breakpoints and below (less than 1024px), the custom title is not displayed.
|
|
79
87
|
|
|
80
88
|
<Example Component={CustomTitleExample} />
|
|
81
89
|
|
|
82
90
|
## Middle items
|
|
83
91
|
|
|
84
92
|
These actions go in the
|
|
85
|
-
[
|
|
86
|
-
centre-aligned.
|
|
93
|
+
[top nav middle](/components/navigation-system/layout/examples#top-nav-slots) area.
|
|
87
94
|
|
|
88
|
-
-
|
|
95
|
+
- They should consist of a search component and a create component, in that order to maintain the
|
|
89
96
|
correct layout behaviour.
|
|
97
|
+
- The actions are centre-aligned when the side nav is collapsed, and left-aligned when the side nav is expanded.
|
|
98
|
+
- At `xl` breakpoints (1768px or greater), the middle items are centred in the viewport when the side nav is expanded, but are pushed out by the side nav to avoid overlapping.
|
|
90
99
|
- We have provided placeholder components. See
|
|
91
|
-
[navigation
|
|
100
|
+
[navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE)
|
|
92
101
|
for recommended platform components.
|
|
93
102
|
- Our placeholder search field scales to fill the available area of common actions, up to a maximum
|
|
94
103
|
width of 780px. At `xxs` breakpoints (less than 480px), the search field converts to an icon only
|
|
95
104
|
button.
|
|
96
105
|
|
|
97
|
-
See the [
|
|
106
|
+
See the [responsive section](#responsive) for more information. If you use search or create components
|
|
98
107
|
from other packages, you may experience different responsive behaviour.
|
|
99
108
|
|
|
100
109
|
<SectionMessage>
|
|
101
110
|
|
|
102
|
-
The search bar must be the first child
|
|
103
|
-
this is not the case, you may see unexpected layout behavior.
|
|
111
|
+
The search bar must be the first child of `TopNavMiddle`, in line with our design specifications. Otherwise, you may see unexpected layout behavior.
|
|
104
112
|
|
|
105
113
|
</SectionMessage>
|
|
106
114
|
|
|
@@ -108,7 +116,7 @@ this is not the case, you may see unexpected layout behavior.
|
|
|
108
116
|
|
|
109
117
|
## End items
|
|
110
118
|
|
|
111
|
-
These actions
|
|
119
|
+
These actions appear in the [top nav end](/components/navigation-system/layout/examples#top-nav-slots)
|
|
112
120
|
area. They are right-aligned and provided as a list for accessibility. Contains, in the following
|
|
113
121
|
order:
|
|
114
122
|
|
|
@@ -119,12 +127,12 @@ order:
|
|
|
119
127
|
- Settings - Use to open and close a settings menu.
|
|
120
128
|
- Profile/Login - A placeholder for an account component.
|
|
121
129
|
|
|
122
|
-
See [navigation
|
|
123
|
-
for recommended platform components for these buttons, or triggered by these buttons.
|
|
130
|
+
See [navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/x/rBE7MAE)
|
|
131
|
+
for recommended platform components for these buttons, or components triggered by these buttons.
|
|
124
132
|
|
|
125
|
-
At `xs` breakpoints and below (less than 768px), these buttons collapse into a single '
|
|
133
|
+
At `xs` breakpoints and below (less than 768px), these buttons collapse into a single 'More' button.
|
|
126
134
|
|
|
127
|
-
See the [
|
|
135
|
+
See the [responsive section](#responsive) for more details.
|
|
128
136
|
|
|
129
137
|
<Example Component={TopNavEndLayoutExample} />
|
|
130
138
|
|
|
@@ -132,27 +140,27 @@ See the [Responsive section](#responsive) for more details.
|
|
|
132
140
|
|
|
133
141
|
If none of the provided end items are suitable, you can create your own icon button using `EndItem`.
|
|
134
142
|
|
|
135
|
-
If you need a more customised button, use
|
|
143
|
+
If you need a more customised button, use [top nav button](#top-nav-button) and wrap it in a list item.
|
|
136
144
|
|
|
137
145
|
<Example Component={EndItemExample} />
|
|
138
146
|
|
|
139
|
-
## Top
|
|
147
|
+
## Top nav button
|
|
140
148
|
|
|
141
|
-
A button that supports theming.
|
|
149
|
+
A button component that supports theming. The following variants are available:
|
|
142
150
|
|
|
143
|
-
-
|
|
144
|
-
-
|
|
145
|
-
-
|
|
146
|
-
-
|
|
151
|
+
- Top nav icon button
|
|
152
|
+
- Top nav link button
|
|
153
|
+
- Top nav link icon button
|
|
154
|
+
- Top nav button
|
|
147
155
|
|
|
148
|
-
Use
|
|
156
|
+
Use this component when you need to add buttons to the top nav. Be aware that adding custom buttons may negatively impact the consistency
|
|
149
157
|
across apps.
|
|
150
158
|
|
|
151
159
|
<Example Component={TopNavButtonExample} />
|
|
152
160
|
|
|
153
161
|
## Responsive
|
|
154
162
|
|
|
155
|
-
Top nav items respond to the viewport size. See default behaviour below, or the
|
|
163
|
+
Top nav items respond to the viewport size. See the default behaviour below, or explore the
|
|
156
164
|
[interactive example](/components/navigation-system/examples#examples).
|
|
157
165
|
|
|
158
166
|
**Note:** If using other platform components in top nav, they may have different responsive
|
|
@@ -169,14 +177,14 @@ behaviour.
|
|
|
169
177
|
|
|
170
178
|
## Custom theming
|
|
171
179
|
|
|
172
|
-
Custom theming is
|
|
180
|
+
Custom theming is configured on the [top nav](/components/navigation-system/layout/custom-theming).
|
|
173
181
|
|
|
174
182
|
### Logos
|
|
175
183
|
|
|
176
|
-
Logos and icons from the [
|
|
184
|
+
Logos and icons from the [logo](/components/logo) package will automatically consume the theme when
|
|
177
185
|
used with the `AppLogo` or `CustomLogo` component.
|
|
178
186
|
|
|
179
|
-
Custom logos uploaded by organization admins are
|
|
187
|
+
Custom logos uploaded by organization admins are not affected by theming.
|
|
180
188
|
|
|
181
189
|
<Example Component={CustomThemingLogoExample} />
|
|
182
190
|
|
|
@@ -187,7 +195,7 @@ Search Platform components.
|
|
|
187
195
|
|
|
188
196
|
<SectionMessage appearance="warning" title="Use sparingly">
|
|
189
197
|
|
|
190
|
-
Do not create new components that rely on the `useLegacySearchTheme()` hook. It is only
|
|
198
|
+
Do not create new components that rely on the `useLegacySearchTheme()` hook. It is intended only for
|
|
191
199
|
backwards compatibility, and may be deprecated if the Search Platform evolves.
|
|
192
200
|
|
|
193
201
|
</SectionMessage>
|
|
@@ -196,12 +204,12 @@ backwards compatibility, and may be deprecated if the Search Platform evolves.
|
|
|
196
204
|
|
|
197
205
|
### Buttons
|
|
198
206
|
|
|
199
|
-
Do not use [
|
|
207
|
+
Do not use [button](/components/button) inside of the top navigation.
|
|
200
208
|
|
|
201
|
-
Use the action components exported from this package (such as `AppSwitcher`
|
|
202
|
-
|
|
209
|
+
Use the action components exported from this package (such as `AppSwitcher`), as they
|
|
210
|
+
automatically consume the custom theme.
|
|
203
211
|
|
|
204
|
-
Custom actions can be created using
|
|
212
|
+
Custom actions can be created using [end item](#end-item) for icon buttons and [top nav button](#top-nav-button) for buttons with
|
|
205
213
|
visible text.
|
|
206
214
|
|
|
207
215
|
<Example Component={CustomThemingButtonsExample} />
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -4,17 +4,29 @@ description: Buttons and elements for the top nav.
|
|
|
4
4
|
order: 3
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
import
|
|
8
|
-
|
|
9
|
-
import
|
|
10
|
-
import
|
|
7
|
+
import Image from '@atlaskit/image';
|
|
8
|
+
|
|
9
|
+
import topNavItemsAnatomyLight from './images/topNavItems-anatomy-light.png';
|
|
10
|
+
import topNavItemsAnatomyDark from './images/topNavItems-anatomy-dark.png';
|
|
11
|
+
import topNavItemsDo1Light from './images/topNavItems-do-1-light.png';
|
|
12
|
+
import topNavItemsDo1Dark from './images/topNavItems-do-1-dark.png';
|
|
13
|
+
import topNavItemsDo2Light from './images/topNavItems-do-2-light.png';
|
|
14
|
+
import topNavItemsDo2Dark from './images/topNavItems-do-2-dark.png';
|
|
15
|
+
import topNavItemsDont1Light from './images/topNavItems-dont-1-light.png';
|
|
16
|
+
import topNavItemsDont1Dark from './images/topNavItems-dont-1-dark.png';
|
|
17
|
+
import topNavItemsDont2Light from './images/topNavItems-dont-2-light.png';
|
|
18
|
+
import topNavItemsDont2Dark from './images/topNavItems-dont-2-dark.png';
|
|
11
19
|
|
|
12
20
|
## Usage
|
|
13
21
|
|
|
14
22
|
Use top nav items to create common utilities in
|
|
15
|
-
the
|
|
23
|
+
the top nav within [layout](/components/navigation-system/layout/examples).
|
|
16
24
|
|
|
17
|
-
|
|
25
|
+
<Image
|
|
26
|
+
src={topNavItemsAnatomyLight}
|
|
27
|
+
srcDark={topNavItemsAnatomyDark}
|
|
28
|
+
alt="Diagram of the navigation system top nav"
|
|
29
|
+
/>
|
|
18
30
|
|
|
19
31
|
1. **Start items:** Left-aligned buttons.
|
|
20
32
|
2. **Middle items:** Centre-aligned actions.
|
|
@@ -23,8 +35,8 @@ the [top nav](/components/navigation-system/top-nav-items).
|
|
|
23
35
|
## Follow Atlassian's navigation patterns
|
|
24
36
|
|
|
25
37
|
The current navigation has specific menu items that are similar across apps. Make sure your top
|
|
26
|
-
navigation follows Atlassian patterns consistently,
|
|
27
|
-
[
|
|
38
|
+
navigation follows Atlassian patterns consistently. For all the guidelines, see
|
|
39
|
+
[navigation resources (Atlassians only)](https://hello.atlassian.net/wiki/spaces/navx/pages/5104144812).
|
|
28
40
|
|
|
29
41
|
## Best practices
|
|
30
42
|
|
|
@@ -34,7 +46,8 @@ navigation follows Atlassian patterns consistently,
|
|
|
34
46
|
<DoDont
|
|
35
47
|
type="do"
|
|
36
48
|
image={{
|
|
37
|
-
url:
|
|
49
|
+
url: topNavItemsDo1Light,
|
|
50
|
+
urlDarkMode: topNavItemsDo1Dark,
|
|
38
51
|
alt: 'Two buttons, one outlined and one solid purple, both labeled "Button".',
|
|
39
52
|
}}
|
|
40
53
|
>
|
|
@@ -43,7 +56,8 @@ navigation follows Atlassian patterns consistently,
|
|
|
43
56
|
<DoDont
|
|
44
57
|
type="dont"
|
|
45
58
|
image={{
|
|
46
|
-
url:
|
|
59
|
+
url: topNavItemsDont1Light,
|
|
60
|
+
urlDarkMode: topNavItemsDont1Dark,
|
|
47
61
|
alt: 'Two buttons, one outlined and one solid purple, both labeled "Button".',
|
|
48
62
|
}}
|
|
49
63
|
>
|
|
@@ -57,7 +71,8 @@ navigation follows Atlassian patterns consistently,
|
|
|
57
71
|
<DoDont
|
|
58
72
|
type="do"
|
|
59
73
|
image={{
|
|
60
|
-
url:
|
|
74
|
+
url: topNavItemsDo2Light,
|
|
75
|
+
urlDarkMode: topNavItemsDo2Dark,
|
|
61
76
|
alt: 'A segment of a top navigation bar showing standard Atlassian icons and a highlighted "ate" item.',
|
|
62
77
|
}}
|
|
63
78
|
>
|
|
@@ -66,7 +81,8 @@ navigation follows Atlassian patterns consistently,
|
|
|
66
81
|
<DoDont
|
|
67
82
|
type="dont"
|
|
68
83
|
image={{
|
|
69
|
-
url:
|
|
84
|
+
url: topNavItemsDont2Light,
|
|
85
|
+
urlDarkMode: topNavItemsDont2Dark,
|
|
70
86
|
alt: 'A segment of a top navigation bar showing standard Atlassian icons with an additional "Logout" button and a diamond icon.',
|
|
71
87
|
}}
|
|
72
88
|
>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/navigation-system",
|
|
3
|
-
"version": "7.1.
|
|
3
|
+
"version": "7.1.4",
|
|
4
4
|
"description": "The latest navigation system for Atlassian apps.",
|
|
5
5
|
"repository": "https://bitbucket.org/atlassian/atlassian-frontend-mirror",
|
|
6
6
|
"author": "Atlassian Pty Ltd",
|
|
@@ -68,16 +68,16 @@
|
|
|
68
68
|
"@atlaskit/button": "^23.10.0",
|
|
69
69
|
"@atlaskit/css": "^0.19.0",
|
|
70
70
|
"@atlaskit/ds-lib": "^6.0.0",
|
|
71
|
-
"@atlaskit/icon": "^
|
|
71
|
+
"@atlaskit/icon": "^34.0.0",
|
|
72
72
|
"@atlaskit/layering": "^3.6.0",
|
|
73
73
|
"@atlaskit/logo": "^19.10.0",
|
|
74
74
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
75
|
-
"@atlaskit/popup": "^4.
|
|
75
|
+
"@atlaskit/popup": "^4.16.0",
|
|
76
76
|
"@atlaskit/pragmatic-drag-and-drop": "^1.7.0",
|
|
77
77
|
"@atlaskit/primitives": "^18.1.0",
|
|
78
78
|
"@atlaskit/side-nav-items": "^1.12.0",
|
|
79
79
|
"@atlaskit/tokens": "^11.4.0",
|
|
80
|
-
"@atlaskit/tooltip": "^21.
|
|
80
|
+
"@atlaskit/tooltip": "^21.1.0",
|
|
81
81
|
"@atlaskit/visually-hidden": "^3.0.0",
|
|
82
82
|
"@babel/runtime": "^7.0.0",
|
|
83
83
|
"@compiled/react": "^0.20.0",
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
"@af/accessibility-testing": "workspace:^",
|
|
94
94
|
"@af/integration-testing": "workspace:^",
|
|
95
95
|
"@af/visual-regression": "workspace:^",
|
|
96
|
-
"@atlaskit/app-provider": "^4.
|
|
96
|
+
"@atlaskit/app-provider": "^4.2.0",
|
|
97
97
|
"@atlaskit/badge": "^18.4.0",
|
|
98
98
|
"@atlaskit/banner": "^14.0.0",
|
|
99
99
|
"@atlaskit/breadcrumbs": "^16.0.0",
|
|
@@ -103,21 +103,21 @@
|
|
|
103
103
|
"@atlaskit/link": "^3.3.0",
|
|
104
104
|
"@atlaskit/lozenge": "^13.5.0",
|
|
105
105
|
"@atlaskit/menu": "^8.4.0",
|
|
106
|
-
"@atlaskit/modal-dialog": "^14.
|
|
106
|
+
"@atlaskit/modal-dialog": "^14.14.0",
|
|
107
107
|
"@atlaskit/onboarding": "^14.5.0",
|
|
108
108
|
"@atlaskit/page-header": "^12.1.0",
|
|
109
109
|
"@atlaskit/page-layout": "^4.2.0",
|
|
110
110
|
"@atlaskit/popper": "^7.1.0",
|
|
111
111
|
"@atlaskit/pragmatic-drag-and-drop-auto-scroll": "^2.1.0",
|
|
112
|
-
"@atlaskit/select": "^21.
|
|
112
|
+
"@atlaskit/select": "^21.10.0",
|
|
113
113
|
"@atlaskit/skeleton": "^2.1.0",
|
|
114
114
|
"@atlaskit/textfield": "^8.2.0",
|
|
115
115
|
"@atlassian/feature-flags-test-utils": "^1.0.0",
|
|
116
|
-
"@atlassian/gemini": "^1.
|
|
117
|
-
"@atlassian/search-dialog": "^9.
|
|
116
|
+
"@atlassian/gemini": "^1.39.0",
|
|
117
|
+
"@atlassian/search-dialog": "^9.20.0",
|
|
118
118
|
"@atlassian/ssr-tests": "workspace:^",
|
|
119
119
|
"@atlassian/test-utils": "^1.0.0",
|
|
120
|
-
"@atlassian/testing-library": "^0.
|
|
120
|
+
"@atlassian/testing-library": "^0.5.0",
|
|
121
121
|
"@axe-core/playwright": "^4.11.1",
|
|
122
122
|
"@testing-library/react": "^16.3.0",
|
|
123
123
|
"@testing-library/user-event": "^14.4.3",
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @jsxRuntime classic
|
|
3
|
-
* @jsx jsx
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
import { cssMap, jsx } from '@compiled/react';
|
|
7
|
-
|
|
8
|
-
import { token } from '@atlaskit/tokens';
|
|
9
|
-
|
|
10
|
-
const styles = cssMap({
|
|
11
|
-
root: {
|
|
12
|
-
display: 'grid',
|
|
13
|
-
gridTemplateColumns: '1fr 3fr 1fr 1fr',
|
|
14
|
-
gridTemplateRows: 'auto auto 300px',
|
|
15
|
-
gridTemplateAreas: `
|
|
16
|
-
"banner banner banner banner"
|
|
17
|
-
"top-bar top-bar top-bar top-bar"
|
|
18
|
-
"side-nav main aside panel"
|
|
19
|
-
`,
|
|
20
|
-
paddingBlockStart: token('space.100'),
|
|
21
|
-
paddingInlineEnd: token('space.100'),
|
|
22
|
-
paddingBlockEnd: token('space.100'),
|
|
23
|
-
paddingInlineStart: token('space.100'),
|
|
24
|
-
marginBlockEnd: token('space.100'),
|
|
25
|
-
borderWidth: token('border.width'),
|
|
26
|
-
borderStyle: 'solid',
|
|
27
|
-
borderColor: token('color.border'),
|
|
28
|
-
borderRadius: token('radius.small'),
|
|
29
|
-
backgroundColor: `linear-gradient(
|
|
30
|
-
45deg,
|
|
31
|
-
${token('elevation.surface.sunken')} 25%,
|
|
32
|
-
transparent 25%
|
|
33
|
-
),linear-gradient(
|
|
34
|
-
135deg,
|
|
35
|
-
${token('elevation.surface.sunken')} 25%,
|
|
36
|
-
transparent 25%
|
|
37
|
-
),linear-gradient(
|
|
38
|
-
45deg,
|
|
39
|
-
transparent 75%,
|
|
40
|
-
${token('elevation.surface.sunken')} 75%
|
|
41
|
-
),linear-gradient(
|
|
42
|
-
135deg,
|
|
43
|
-
transparent 75%,
|
|
44
|
-
${token('elevation.surface.sunken')} 75%
|
|
45
|
-
)`,
|
|
46
|
-
backgroundPosition: '0 0,10px 0,10px -10px,0px 10px',
|
|
47
|
-
backgroundSize: '20px 20px',
|
|
48
|
-
},
|
|
49
|
-
slot: {
|
|
50
|
-
width: '100%',
|
|
51
|
-
height: '100%',
|
|
52
|
-
paddingBlockStart: token('space.100'),
|
|
53
|
-
paddingInlineEnd: token('space.100'),
|
|
54
|
-
paddingBlockEnd: token('space.100'),
|
|
55
|
-
paddingInlineStart: token('space.100'),
|
|
56
|
-
},
|
|
57
|
-
placeholder: {
|
|
58
|
-
width: '100%',
|
|
59
|
-
height: '100%',
|
|
60
|
-
backgroundColor: token('color.background.neutral'),
|
|
61
|
-
borderWidth: token('border.width'),
|
|
62
|
-
borderStyle: 'solid',
|
|
63
|
-
borderColor: token('color.border'),
|
|
64
|
-
borderRadius: token('radius.small'),
|
|
65
|
-
paddingBlockStart: token('space.100'),
|
|
66
|
-
paddingInlineEnd: token('space.100'),
|
|
67
|
-
paddingBlockEnd: token('space.100'),
|
|
68
|
-
paddingInlineStart: token('space.100'),
|
|
69
|
-
},
|
|
70
|
-
bannerSlot: {
|
|
71
|
-
gridArea: 'banner',
|
|
72
|
-
},
|
|
73
|
-
topBarSlot: {
|
|
74
|
-
gridArea: 'top-bar',
|
|
75
|
-
backgroundColor: token('elevation.surface'),
|
|
76
|
-
},
|
|
77
|
-
sideNavSlot: {
|
|
78
|
-
gridArea: 'side-nav',
|
|
79
|
-
backgroundColor: token('elevation.surface'),
|
|
80
|
-
},
|
|
81
|
-
mainSlot: {
|
|
82
|
-
gridArea: 'main',
|
|
83
|
-
},
|
|
84
|
-
asideSlot: {
|
|
85
|
-
gridArea: 'aside',
|
|
86
|
-
paddingInlineStart: token('space.0'),
|
|
87
|
-
},
|
|
88
|
-
panelSlot: {
|
|
89
|
-
gridArea: 'panel',
|
|
90
|
-
paddingInlineStart: token('space.0'),
|
|
91
|
-
},
|
|
92
|
-
});
|
|
93
|
-
|
|
94
|
-
export const PageLayoutDiagram: () => JSX.Element = () => (
|
|
95
|
-
<div css={styles.root}>
|
|
96
|
-
<div css={[styles.slot, styles.bannerSlot]}>
|
|
97
|
-
<div css={styles.placeholder}>Banner</div>
|
|
98
|
-
</div>
|
|
99
|
-
<div css={[styles.slot, styles.topBarSlot]}>
|
|
100
|
-
<div css={styles.placeholder}>Top nav</div>
|
|
101
|
-
</div>
|
|
102
|
-
<div css={[styles.slot, styles.sideNavSlot]}>
|
|
103
|
-
<div css={styles.placeholder}>Side nav</div>
|
|
104
|
-
</div>
|
|
105
|
-
<div css={[styles.slot, styles.mainSlot]}>
|
|
106
|
-
<div css={styles.placeholder}>Main</div>
|
|
107
|
-
</div>
|
|
108
|
-
<div css={[styles.slot, styles.asideSlot]}>
|
|
109
|
-
<div css={styles.placeholder}>Aside</div>
|
|
110
|
-
</div>
|
|
111
|
-
<div css={[styles.slot, styles.panelSlot]}>
|
|
112
|
-
<div css={styles.placeholder}>Panel</div>
|
|
113
|
-
</div>
|
|
114
|
-
</div>
|
|
115
|
-
);
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|