@codecademy/brand 3.19.0-alpha.c35a1cb4bd.0 → 3.19.0-alpha.c8b1055646.0
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/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/MarketingBanner.d.ts +1 -3
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/MarketingBanner.js +7 -4
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/NavPanels.d.ts +0 -1
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/NavPanels.js +3 -4
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/consts.d.ts +2 -9
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/consts.js +2 -48
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/index.js +8 -20
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/tabConfig.d.ts +2 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogDropdown/tabConfig.js +48 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderDropdown/index.js +9 -14
- package/dist/AppHeader/AppHeaderElements/AppHeaderDropdownLinks/elements/AppHeaderDropdownLink.js +3 -2
- package/dist/AppHeader/AppHeaderElements/AppHeaderDropdownLinks/elements/AppHeaderMenuItem.js +5 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderDropdownLinks/elements/StyledAppHeaderLink.js +5 -2
- package/dist/AppHeader/AppHeaderElements/AppHeaderLinkSections/index.js +3 -2
- package/dist/AppHeader/AppHeaderElements/AppHeaderNavButton/AppHeaderDropdownNavButton.js +5 -5
- package/dist/AppHeader/AppHeaderElements/AppHeaderNavButton/AppHeaderMenuNavButton.js +9 -7
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/NavPanels.js +12 -6
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/consts.d.ts +1 -8
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/consts.js +1 -39
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/index.js +7 -22
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/tabConfig.d.ts +2 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderResourcesDropdown/tabConfig.js +39 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/AppHeaderSection.test.js +215 -30
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/MobileBackButton.js +4 -5
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/MobileNavMenu.d.ts +2 -5
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/MobileNavMenu.js +7 -5
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/consts.d.ts +2 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/consts.js +37 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/elements.d.ts +37 -0
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/elements.js +86 -12
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/index.d.ts +9 -6
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/index.js +123 -41
- package/dist/AppHeader/shared/elements.d.ts +15 -3
- package/dist/AppHeader/shared/elements.js +138 -27
- package/dist/AppHeaderMobile/AppHeaderSubMenuMobile/index.js +9 -11
- package/dist/LearningOutcomeTile/index.js +1 -2
- package/package.json +2 -1
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/NavSection.d.ts +0 -21
- package/dist/AppHeader/AppHeaderElements/AppHeaderSection/NavSection.js +0 -162
|
@@ -2,11 +2,12 @@ import { setupRtl } from '@codecademy/gamut-tests';
|
|
|
2
2
|
import userEvent from '@testing-library/user-event';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { GlobalHeaderItemClickContext } from '../../../GlobalHeader/context';
|
|
5
|
-
import {
|
|
5
|
+
import { CATALOG_TAB_SECTIONS } from '../AppHeaderCatalogDropdown/tabConfig';
|
|
6
6
|
import { AppHeaderSection } from '.';
|
|
7
7
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
8
|
const mockOnClick = jest.fn();
|
|
9
9
|
const mockKeyDownEvents = jest.fn();
|
|
10
|
+
const mockHandleClose = jest.fn();
|
|
10
11
|
const mockItem = {
|
|
11
12
|
text: 'catalog',
|
|
12
13
|
id: 'the-catalog',
|
|
@@ -21,6 +22,15 @@ const defaultProps = {
|
|
|
21
22
|
const mockContextValue = {
|
|
22
23
|
globalHeaderItemClick: mockOnClick
|
|
23
24
|
};
|
|
25
|
+
const MockMarketingBanner = jest.fn().mockReturnValue(/*#__PURE__*/_jsx("div", {
|
|
26
|
+
"data-testid": "marketing-banner",
|
|
27
|
+
children: "Marketing Banner"
|
|
28
|
+
}));
|
|
29
|
+
jest.mock('../../../GlobalHeader/context', () => ({
|
|
30
|
+
...jest.requireActual('../../../GlobalHeader/context'),
|
|
31
|
+
useGlobalHeaderDynamicDataContext: jest.fn()
|
|
32
|
+
}));
|
|
33
|
+
const mockUseGlobalHeaderDynamicDataContext = require('../../../GlobalHeader/context').useGlobalHeaderDynamicDataContext;
|
|
24
34
|
describe('AppHeaderSection', () => {
|
|
25
35
|
const renderView = setupRtl(AppHeaderSection, defaultProps).options({
|
|
26
36
|
wrapper: ({
|
|
@@ -30,50 +40,171 @@ describe('AppHeaderSection', () => {
|
|
|
30
40
|
children: children
|
|
31
41
|
})
|
|
32
42
|
});
|
|
33
|
-
|
|
43
|
+
beforeEach(() => {
|
|
44
|
+
mockUseGlobalHeaderDynamicDataContext.mockReturnValue({
|
|
45
|
+
globalHeaderDynamicData: {
|
|
46
|
+
catalogDropdown: {
|
|
47
|
+
banner: null,
|
|
48
|
+
skillPaths: {
|
|
49
|
+
totalSkillPathCount: 0,
|
|
50
|
+
promotedSkillPaths: []
|
|
51
|
+
},
|
|
52
|
+
careerPaths: {
|
|
53
|
+
totalCareerPathCount: 0,
|
|
54
|
+
promotedCareerPaths: []
|
|
55
|
+
},
|
|
56
|
+
certificationPaths: {
|
|
57
|
+
totalCertificationPathCount: 0
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
});
|
|
63
|
+
it('renders the component with default tab selected', () => {
|
|
34
64
|
const {
|
|
35
65
|
view
|
|
36
66
|
} = renderView({
|
|
37
|
-
|
|
38
|
-
handleClose:
|
|
67
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
68
|
+
handleClose: mockHandleClose,
|
|
39
69
|
type: 'catalog-dropdown'
|
|
40
70
|
});
|
|
41
71
|
expect(view.getByRole('heading', {
|
|
42
72
|
name: 'Course topics'
|
|
43
73
|
})).toBeInTheDocument();
|
|
74
|
+
|
|
75
|
+
// First tab should be active by default, this is handled by the react-aria-component
|
|
76
|
+
// but leaving this test anyway to ensure the right default tab is selected
|
|
77
|
+
expect(view.getByRole('tab', {
|
|
78
|
+
selected: true
|
|
79
|
+
})).toHaveTextContent('Course topics');
|
|
44
80
|
});
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
});
|
|
54
|
-
const courseTopicsButton = view.getByTestId('nav-section-course-topics');
|
|
55
|
-
expect(courseTopicsButton).toHaveAttribute('aria-expanded', 'true');
|
|
81
|
+
it('renders with custom defaultSelectedKey', () => {
|
|
82
|
+
const {
|
|
83
|
+
view
|
|
84
|
+
} = renderView({
|
|
85
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
86
|
+
handleClose: mockHandleClose,
|
|
87
|
+
type: 'catalog-dropdown',
|
|
88
|
+
defaultSelectedKey: 'career-paths'
|
|
56
89
|
});
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
90
|
+
expect(view.getByRole('tab', {
|
|
91
|
+
selected: true
|
|
92
|
+
})).toHaveTextContent('Career paths');
|
|
93
|
+
});
|
|
94
|
+
it('shows right arrow icon for active tab on larger screens', () => {
|
|
95
|
+
const {
|
|
96
|
+
view
|
|
97
|
+
} = renderView({
|
|
98
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
99
|
+
handleClose: mockHandleClose,
|
|
100
|
+
type: 'catalog-dropdown'
|
|
101
|
+
});
|
|
102
|
+
|
|
103
|
+
// First tab should be active and show arrow
|
|
104
|
+
const activeTab = view.getByRole('tab', {
|
|
105
|
+
selected: true
|
|
106
|
+
});
|
|
107
|
+
expect(activeTab.querySelector('svg')).toBeInTheDocument();
|
|
108
|
+
});
|
|
109
|
+
it('renders marketing banner when banner data and component are provided', () => {
|
|
110
|
+
mockUseGlobalHeaderDynamicDataContext.mockReturnValue({
|
|
111
|
+
globalHeaderDynamicData: {
|
|
112
|
+
catalogDropdown: {
|
|
113
|
+
banner: {
|
|
114
|
+
title: 'Test Banner'
|
|
115
|
+
},
|
|
116
|
+
skillPaths: {
|
|
117
|
+
totalSkillPathCount: 0,
|
|
118
|
+
promotedSkillPaths: []
|
|
119
|
+
},
|
|
120
|
+
careerPaths: {
|
|
121
|
+
totalCareerPathCount: 0,
|
|
122
|
+
promotedCareerPaths: []
|
|
123
|
+
},
|
|
124
|
+
certificationPaths: {
|
|
125
|
+
totalCertificationPathCount: 0
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
});
|
|
131
|
+
it('does not render marketing banner when no banner data', () => {
|
|
132
|
+
mockUseGlobalHeaderDynamicDataContext.mockReturnValue({
|
|
133
|
+
globalHeaderDynamicData: {
|
|
134
|
+
catalogDropdown: {
|
|
135
|
+
banner: null,
|
|
136
|
+
skillPaths: {
|
|
137
|
+
totalSkillPathCount: 0,
|
|
138
|
+
promotedSkillPaths: []
|
|
139
|
+
},
|
|
140
|
+
careerPaths: {
|
|
141
|
+
totalCareerPathCount: 0,
|
|
142
|
+
promotedCareerPaths: []
|
|
143
|
+
},
|
|
144
|
+
certificationPaths: {
|
|
145
|
+
totalCertificationPathCount: 0
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
const {
|
|
151
|
+
view
|
|
152
|
+
} = renderView({
|
|
153
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
154
|
+
handleClose: mockHandleClose,
|
|
155
|
+
type: 'catalog-dropdown',
|
|
156
|
+
MarketingBanner: MockMarketingBanner
|
|
157
|
+
});
|
|
158
|
+
expect(MockMarketingBanner).not.toHaveBeenCalled();
|
|
159
|
+
});
|
|
160
|
+
it('renders with custom aria-label when provided', () => {
|
|
161
|
+
const {
|
|
162
|
+
view
|
|
163
|
+
} = renderView({
|
|
164
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
165
|
+
handleClose: mockHandleClose,
|
|
166
|
+
type: 'catalog-dropdown',
|
|
167
|
+
ariaLabel: 'Custom Navigation Label'
|
|
168
|
+
});
|
|
169
|
+
expect(view.getByRole('tablist')).toHaveAttribute('aria-label', 'Custom Navigation Label');
|
|
170
|
+
});
|
|
171
|
+
it('uses default aria-label when not provided', () => {
|
|
172
|
+
const {
|
|
173
|
+
view
|
|
174
|
+
} = renderView({
|
|
175
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
176
|
+
handleClose: mockHandleClose,
|
|
177
|
+
type: 'catalog-dropdown'
|
|
178
|
+
});
|
|
179
|
+
expect(view.getByRole('tablist')).toHaveAttribute('aria-label', 'catalog navigation');
|
|
180
|
+
});
|
|
181
|
+
it('uses resources aria-label for resources dropdown type', () => {
|
|
182
|
+
const {
|
|
183
|
+
view
|
|
184
|
+
} = renderView({
|
|
185
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
186
|
+
handleClose: mockHandleClose,
|
|
187
|
+
type: 'resources-dropdown'
|
|
70
188
|
});
|
|
189
|
+
expect(view.getByRole('tablist')).toHaveAttribute('aria-label', 'resources navigation');
|
|
190
|
+
});
|
|
191
|
+
it('handles empty tabSections gracefully', () => {
|
|
192
|
+
const {
|
|
193
|
+
view
|
|
194
|
+
} = renderView({
|
|
195
|
+
tabSections: [],
|
|
196
|
+
handleClose: mockHandleClose,
|
|
197
|
+
type: 'catalog-dropdown'
|
|
198
|
+
});
|
|
199
|
+
expect(view.container).toBeInTheDocument();
|
|
200
|
+
});
|
|
201
|
+
describe('tab tracking', () => {
|
|
71
202
|
it('calls tracking with correct parameters when clicking nav section', async () => {
|
|
72
203
|
const {
|
|
73
204
|
view
|
|
74
205
|
} = renderView({
|
|
75
|
-
|
|
76
|
-
handleClose:
|
|
206
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
207
|
+
handleClose: mockHandleClose,
|
|
77
208
|
type: 'catalog-dropdown'
|
|
78
209
|
});
|
|
79
210
|
const careerPathsButton = view.getByTestId('nav-section-career-paths');
|
|
@@ -87,5 +218,59 @@ describe('AppHeaderSection', () => {
|
|
|
87
218
|
}) // tracking parameters
|
|
88
219
|
);
|
|
89
220
|
});
|
|
221
|
+
it('calls tracking for all tab sections when clicked', async () => {
|
|
222
|
+
const {
|
|
223
|
+
view
|
|
224
|
+
} = renderView({
|
|
225
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
226
|
+
handleClose: mockHandleClose,
|
|
227
|
+
type: 'catalog-dropdown'
|
|
228
|
+
});
|
|
229
|
+
|
|
230
|
+
// Click each tab to verify tracking
|
|
231
|
+
const tabs = ['course-topics', 'skill-paths', 'career-paths', 'certification-paths', 'live-learning'];
|
|
232
|
+
await Promise.all(tabs.map(async tabId => {
|
|
233
|
+
const tabButton = view.getByTestId(`nav-section-${tabId}`);
|
|
234
|
+
await userEvent.click(tabButton);
|
|
235
|
+
}));
|
|
236
|
+
expect(mockOnClick).toHaveBeenCalledTimes(5);
|
|
237
|
+
});
|
|
238
|
+
});
|
|
239
|
+
describe('tab panel rendering', () => {
|
|
240
|
+
it('renders the active tab panel content', () => {
|
|
241
|
+
const {
|
|
242
|
+
view
|
|
243
|
+
} = renderView({
|
|
244
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
245
|
+
handleClose: mockHandleClose,
|
|
246
|
+
type: 'catalog-dropdown'
|
|
247
|
+
});
|
|
248
|
+
expect(view.getByRole('tabpanel', {
|
|
249
|
+
name: 'Course topics'
|
|
250
|
+
})).toBeInTheDocument();
|
|
251
|
+
});
|
|
252
|
+
it('switches panel content when different tab is selected', async () => {
|
|
253
|
+
const {
|
|
254
|
+
view
|
|
255
|
+
} = renderView({
|
|
256
|
+
tabSections: CATALOG_TAB_SECTIONS,
|
|
257
|
+
handleClose: mockHandleClose,
|
|
258
|
+
type: 'catalog-dropdown'
|
|
259
|
+
});
|
|
260
|
+
|
|
261
|
+
// Click on career paths tab
|
|
262
|
+
const careerPathsTab = view.getByRole('tab', {
|
|
263
|
+
name: 'Career paths'
|
|
264
|
+
});
|
|
265
|
+
await userEvent.click(careerPathsTab);
|
|
266
|
+
|
|
267
|
+
// Career paths panel should now be visible
|
|
268
|
+
expect(view.getByRole('tabpanel', {
|
|
269
|
+
name: 'Career paths'
|
|
270
|
+
})).toBeInTheDocument();
|
|
271
|
+
expect(view.queryByRole('tabpanel', {
|
|
272
|
+
name: 'Course topics'
|
|
273
|
+
})).not.toBeInTheDocument();
|
|
274
|
+
});
|
|
90
275
|
});
|
|
91
276
|
});
|
|
@@ -3,8 +3,7 @@ import { Box, FlexBox, IconButton, Text } from '@codecademy/gamut';
|
|
|
3
3
|
import { ArrowLeftIcon } from '@codecademy/gamut-icons';
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useGlobalHeaderItemClick } from '../../../GlobalHeader/context';
|
|
6
|
-
import { SmallMenuButton } from './elements';
|
|
7
|
-
import { NavigationButton } from './NavSection';
|
|
6
|
+
import { NavigationButton, SmallMenuButton } from './elements';
|
|
8
7
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
9
8
|
export const NavIconButton = /*#__PURE__*/_styled(IconButton, {
|
|
10
9
|
target: "ew664c00",
|
|
@@ -13,7 +12,7 @@ export const NavIconButton = /*#__PURE__*/_styled(IconButton, {
|
|
|
13
12
|
theme
|
|
14
13
|
}) => theme.colors.primary, ";background-color:", ({
|
|
15
14
|
theme
|
|
16
|
-
}) => theme.colors['navy-100'], ";}}" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,
|
|
15
|
+
}) => theme.colors['navy-100'], ";}}" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9BcHBIZWFkZXIvQXBwSGVhZGVyRWxlbWVudHMvQXBwSGVhZGVyU2VjdGlvbi9Nb2JpbGVCYWNrQnV0dG9uLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFRK0MiLCJmaWxlIjoiLi4vLi4vLi4vLi4vc3JjL0FwcEhlYWRlci9BcHBIZWFkZXJFbGVtZW50cy9BcHBIZWFkZXJTZWN0aW9uL01vYmlsZUJhY2tCdXR0b24udHN4Iiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgQm94LCBGbGV4Qm94LCBJY29uQnV0dG9uLCBUZXh0IH0gZnJvbSAnQGNvZGVjYWRlbXkvZ2FtdXQnO1xuaW1wb3J0IHsgQXJyb3dMZWZ0SWNvbiB9IGZyb20gJ0Bjb2RlY2FkZW15L2dhbXV0LWljb25zJztcbmltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJztcbmltcG9ydCBSZWFjdCBmcm9tICdyZWFjdCc7XG5cbmltcG9ydCB7IHVzZUdsb2JhbEhlYWRlckl0ZW1DbGljayB9IGZyb20gJy4uLy4uLy4uL0dsb2JhbEhlYWRlci9jb250ZXh0JztcbmltcG9ydCB7IE5hdmlnYXRpb25CdXR0b24sIFNtYWxsTWVudUJ1dHRvbiB9IGZyb20gJy4vZWxlbWVudHMnO1xuXG5leHBvcnQgY29uc3QgTmF2SWNvbkJ1dHRvbiA9IHN0eWxlZChJY29uQnV0dG9uKWBcbiAgJjpob3ZlcixcbiAgJjpmb2N1cyBzdmcge1xuICAgICY6aG92ZXIsXG4gICAgJjpmb2N1cyB7XG4gICAgICBjb2xvcjogJHsoeyB0aGVtZSB9KSA9PiB0aGVtZS5jb2xvcnMucHJpbWFyeX07XG4gICAgICBiYWNrZ3JvdW5kLWNvbG9yOiAkeyh7IHRoZW1lIH0pID0+IHRoZW1lLmNvbG9yc1snbmF2eS0xMDAnXX07XG4gICAgfVxuICB9XG5gO1xuXG5leHBvcnQgdHlwZSBNb2JpbGVCYWNrQnV0dG9uUHJvcHMgPSB7XG4gIGhhbmRsZUNsb3NlOiAoKSA9PiB2b2lkO1xuICB0eXBlOiAnY2F0YWxvZy1kcm9wZG93bicgfCAncmVzb3VyY2VzLWRyb3Bkb3duJztcbn07XG5cbmV4cG9ydCBjb25zdCBNb2JpbGVCYWNrQnV0dG9uOiBSZWFjdC5GQzxNb2JpbGVCYWNrQnV0dG9uUHJvcHM+ID0gKHtcbiAgaGFuZGxlQ2xvc2UsXG4gIHR5cGUsXG59KSA9PiB7XG4gIGNvbnN0IHsgZ2xvYmFsSGVhZGVySXRlbUNsaWNrIH0gPSB1c2VHbG9iYWxIZWFkZXJJdGVtQ2xpY2soKTtcblxuICBjb25zdCBoYW5kbGVCYWNrQnV0dG9uQ2xpY2sgPSAoXG4gICAgZXZlbnQ6IFJlYWN0Lk1vdXNlRXZlbnQ8SFRNTEJ1dHRvbkVsZW1lbnQ+XG4gICkgPT4ge1xuICAgIGdsb2JhbEhlYWRlckl0ZW1DbGljayhldmVudCwge1xuICAgICAgaWQ6ICdiYWNrJyxcbiAgICAgIHRleHQ6ICdCYWNrJyxcbiAgICAgIHR5cGUsXG4gICAgfSk7XG4gICAgaGFuZGxlQ2xvc2UoKTtcbiAgfTtcblxuICByZXR1cm4gKFxuICAgIDw+XG4gICAgICA8Qm94IGRpc3BsYXk9e3sgXzogJ25vbmUnLCBzbTogJ2Jsb2NrJyB9fT5cbiAgICAgICAgPE5hdmlnYXRpb25CdXR0b25cbiAgICAgICAgICBpc0FjdGl2ZT17ZmFsc2V9XG4gICAgICAgICAgaW5kZXg9ezB9XG4gICAgICAgICAgb25DbGljaz17aGFuZGxlQmFja0J1dHRvbkNsaWNrfVxuICAgICAgICAgIGRhdGEtdGVzdGlkPVwibW9iaWxlLWJhY2stYnV0dG9uXCJcbiAgICAgICAgPlxuICAgICAgICAgIDxGbGV4Qm94IGdhcD17OH0gYWxpZ25JdGVtcz1cImNlbnRlclwiPlxuICAgICAgICAgICAgPEJveCBoZWlnaHQ9ezI0fSB3aWR0aD17MjR9PlxuICAgICAgICAgICAgICA8QXJyb3dMZWZ0SWNvbiBzaXplPXsyNH0gLz5cbiAgICAgICAgICAgIDwvQm94PlxuICAgICAgICAgICAgPFRleHQ+QmFjazwvVGV4dD5cbiAgICAgICAgICA8L0ZsZXhCb3g+XG4gICAgICAgIDwvTmF2aWdhdGlvbkJ1dHRvbj5cbiAgICAgIDwvQm94PlxuICAgICAgPEJveFxuICAgICAgICBkaXNwbGF5PXt7IF86ICdub25lJywgeHM6ICdncmlkJywgc206ICdub25lJyB9fVxuICAgICAgICBtbD17OH1cbiAgICAgICAgZ3JpZENvbHVtbj1cIjFcIlxuICAgICAgICBncmlkUm93PVwiMVwiXG4gICAgICAgIGRhdGEtdGVzdGlkPVwibW9iaWxlLWJhY2staWNvbi1idXR0b25cIlxuICAgICAgPlxuICAgICAgICA8TmF2SWNvbkJ1dHRvblxuICAgICAgICAgIG9uQ2xpY2s9e2hhbmRsZUJhY2tCdXR0b25DbGlja31cbiAgICAgICAgICBpY29uPXtBcnJvd0xlZnRJY29ufVxuICAgICAgICAgIHRpcD1cIkJhY2sgdG8gbWFpbiBuYXZpZ2F0aW9uXCJcbiAgICAgICAgICB0aXBQcm9wcz17e1xuICAgICAgICAgICAgYWxpZ25tZW50OiAncmlnaHQtY2VudGVyJyxcbiAgICAgICAgICAgIG5hcnJvdzogZmFsc2UsXG4gICAgICAgICAgICBwbGFjZW1lbnQ6ICdmbG9hdGluZycsXG4gICAgICAgICAgfX1cbiAgICAgICAgICBhcmlhLWxhYmVsPVwiQmFjayB0byBtYWluIG5hdmlnYXRpb25cIlxuICAgICAgICAvPlxuICAgICAgPC9Cb3g+XG4gICAgICA8Qm94IGRpc3BsYXk9e3sgXzogJ2ZsZXgnLCB4czogJ25vbmUnIH19PlxuICAgICAgICA8U21hbGxNZW51QnV0dG9uIGluZGV4PXswfSBvbkNsaWNrPXtoYW5kbGVCYWNrQnV0dG9uQ2xpY2t9PlxuICAgICAgICAgIDxGbGV4Qm94IGdhcD17OH0gYWxpZ25JdGVtcz1cImNlbnRlclwiPlxuICAgICAgICAgICAgPEJveCBoZWlnaHQ9ezI0fSB3aWR0aD17MjR9PlxuICAgICAgICAgICAgICA8QXJyb3dMZWZ0SWNvbiBzaXplPXsyNH0gLz5cbiAgICAgICAgICAgIDwvQm94PlxuICAgICAgICAgICAgPFRleHQ+QmFjazwvVGV4dD5cbiAgICAgICAgICA8L0ZsZXhCb3g+XG4gICAgICAgIDwvU21hbGxNZW51QnV0dG9uPlxuICAgICAgPC9Cb3g+XG4gICAgPC8+XG4gICk7XG59O1xuIl19 */"));
|
|
17
16
|
export const MobileBackButton = ({
|
|
18
17
|
handleClose,
|
|
19
18
|
type
|
|
@@ -39,6 +38,7 @@ export const MobileBackButton = ({
|
|
|
39
38
|
isActive: false,
|
|
40
39
|
index: 0,
|
|
41
40
|
onClick: handleBackButtonClick,
|
|
41
|
+
"data-testid": "mobile-back-button",
|
|
42
42
|
children: /*#__PURE__*/_jsxs(FlexBox, {
|
|
43
43
|
gap: 8,
|
|
44
44
|
alignItems: "center",
|
|
@@ -49,7 +49,6 @@ export const MobileBackButton = ({
|
|
|
49
49
|
size: 24
|
|
50
50
|
})
|
|
51
51
|
}), /*#__PURE__*/_jsx(Text, {
|
|
52
|
-
variant: "p-large",
|
|
53
52
|
children: "Back"
|
|
54
53
|
})]
|
|
55
54
|
})
|
|
@@ -63,6 +62,7 @@ export const MobileBackButton = ({
|
|
|
63
62
|
ml: 8,
|
|
64
63
|
gridColumn: "1",
|
|
65
64
|
gridRow: "1",
|
|
65
|
+
"data-testid": "mobile-back-icon-button",
|
|
66
66
|
children: /*#__PURE__*/_jsx(NavIconButton, {
|
|
67
67
|
onClick: handleBackButtonClick,
|
|
68
68
|
icon: ArrowLeftIcon,
|
|
@@ -92,7 +92,6 @@ export const MobileBackButton = ({
|
|
|
92
92
|
size: 24
|
|
93
93
|
})
|
|
94
94
|
}), /*#__PURE__*/_jsx(Text, {
|
|
95
|
-
variant: "p-large",
|
|
96
95
|
children: "Back"
|
|
97
96
|
})]
|
|
98
97
|
})
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { TabSectionConfig } from '.';
|
|
3
3
|
export type MobileNavMenuProps = {
|
|
4
4
|
handleClose: () => void;
|
|
5
5
|
type: 'catalog-dropdown' | 'resources-dropdown';
|
|
6
|
-
|
|
7
|
-
item: AppHeaderCatalogDropdownItem | AppHeaderResourcesDropdownItem;
|
|
8
|
-
panel: React.ComponentType;
|
|
9
|
-
}[];
|
|
6
|
+
tabSections: TabSectionConfig[];
|
|
10
7
|
};
|
|
11
8
|
export declare const MobileNavMenu: React.FC<MobileNavMenuProps>;
|
|
@@ -9,13 +9,16 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
9
9
|
export const MobileNavMenu = ({
|
|
10
10
|
handleClose,
|
|
11
11
|
type,
|
|
12
|
-
|
|
12
|
+
tabSections
|
|
13
13
|
}) => {
|
|
14
14
|
const {
|
|
15
15
|
activePanel,
|
|
16
16
|
setActivePanel
|
|
17
17
|
} = useAppHeaderSectionContext();
|
|
18
|
-
|
|
18
|
+
if (tabSections.length === 0) {
|
|
19
|
+
return null;
|
|
20
|
+
}
|
|
21
|
+
const ActivePanel = tabSections[activePanel ?? 0].panel;
|
|
19
22
|
return /*#__PURE__*/_jsxs(FlexBox, {
|
|
20
23
|
display: {
|
|
21
24
|
_: 'flex',
|
|
@@ -28,7 +31,7 @@ export const MobileNavMenu = ({
|
|
|
28
31
|
children: [/*#__PURE__*/_jsx(MobileBackButton, {
|
|
29
32
|
handleClose: handleClose,
|
|
30
33
|
type: type
|
|
31
|
-
}),
|
|
34
|
+
}), tabSections.map(({
|
|
32
35
|
item
|
|
33
36
|
}, index) => {
|
|
34
37
|
return /*#__PURE__*/_jsxs(SmallMenuButton, {
|
|
@@ -44,10 +47,9 @@ export const MobileNavMenu = ({
|
|
|
44
47
|
size: 24
|
|
45
48
|
})
|
|
46
49
|
}), /*#__PURE__*/_jsx(Text, {
|
|
47
|
-
variant: "p-large",
|
|
48
50
|
children: item.text
|
|
49
51
|
})]
|
|
50
|
-
}), /*#__PURE__*/_jsx(
|
|
52
|
+
}), /*#__PURE__*/_jsx(FlexBox, {
|
|
51
53
|
children: /*#__PURE__*/_jsx(ArrowChevronRightIcon, {})
|
|
52
54
|
})]
|
|
53
55
|
}, item.id);
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
2
|
+
|
|
3
|
+
export const syntheticMouseEvent = {
|
|
4
|
+
type: 'click',
|
|
5
|
+
target: null,
|
|
6
|
+
currentTarget: null,
|
|
7
|
+
bubbles: true,
|
|
8
|
+
cancelable: true,
|
|
9
|
+
defaultPrevented: false,
|
|
10
|
+
eventPhase: 2,
|
|
11
|
+
isTrusted: true,
|
|
12
|
+
nativeEvent: null,
|
|
13
|
+
preventDefault: () => {},
|
|
14
|
+
isDefaultPrevented: () => false,
|
|
15
|
+
stopPropagation: () => {},
|
|
16
|
+
isPropagationStopped: () => false,
|
|
17
|
+
persist: () => {},
|
|
18
|
+
timeStamp: Date.now(),
|
|
19
|
+
altKey: false,
|
|
20
|
+
button: 0,
|
|
21
|
+
buttons: 0,
|
|
22
|
+
clientX: 0,
|
|
23
|
+
clientY: 0,
|
|
24
|
+
ctrlKey: false,
|
|
25
|
+
getModifierState: () => false,
|
|
26
|
+
metaKey: false,
|
|
27
|
+
movementX: 0,
|
|
28
|
+
movementY: 0,
|
|
29
|
+
pageX: 0,
|
|
30
|
+
pageY: 0,
|
|
31
|
+
relatedTarget: null,
|
|
32
|
+
screenX: 0,
|
|
33
|
+
screenY: 0,
|
|
34
|
+
shiftKey: false,
|
|
35
|
+
x: 0,
|
|
36
|
+
y: 0
|
|
37
|
+
};
|
|
@@ -6,6 +6,12 @@ export declare const StyledSection: import("@emotion/styled").StyledComponent<{
|
|
|
6
6
|
} & {
|
|
7
7
|
activePanelSelected: boolean;
|
|
8
8
|
}, {}, {}>;
|
|
9
|
+
export declare const StyledTabs: import("@emotion/styled").StyledComponent<import("react-aria-components").TabsProps & import("react").RefAttributes<HTMLDivElement> & {
|
|
10
|
+
theme?: import("@emotion/react").Theme;
|
|
11
|
+
}, {}, {}>;
|
|
12
|
+
export declare const StyledTabList: import("@emotion/styled").StyledComponent<import("react-aria-components").TabListProps<object> & import("react").RefAttributes<HTMLDivElement> & {
|
|
13
|
+
theme?: import("@emotion/react").Theme;
|
|
14
|
+
}, {}, {}>;
|
|
9
15
|
export declare const StyledGridBox: import("@emotion/styled").StyledComponent<{
|
|
10
16
|
theme?: import("@emotion/react").Theme | undefined;
|
|
11
17
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
@@ -24,3 +30,34 @@ export declare const SmallMenuButton: import("@emotion/styled").StyledComponent<
|
|
|
24
30
|
} & {
|
|
25
31
|
index: number;
|
|
26
32
|
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
33
|
+
export declare const OverflowText: import("@emotion/styled").StyledComponent<((Omit<{
|
|
34
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
35
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
36
|
+
} & import("@codecademy/gamut").TextTruncateProps & Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "content" | "translate" | "property" | "hidden" | "slot" | "style" | "title" | "suppressHydrationWarning" | "className" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "nonce" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof import("react").ClassAttributes<HTMLSpanElement>>, "ref"> | Omit<{
|
|
37
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
38
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
39
|
+
} & import("@codecademy/gamut").TextNoTruncateProps & Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "content" | "translate" | "property" | "hidden" | "slot" | "style" | "title" | "suppressHydrationWarning" | "className" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "nonce" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof import("react").ClassAttributes<HTMLSpanElement>>, "ref">) & import("react").RefAttributes<HTMLSpanElement>) & {
|
|
40
|
+
theme?: import("@emotion/react").Theme;
|
|
41
|
+
}, {}, {}>;
|
|
42
|
+
export declare const NavTabPanelContainer: import("@emotion/styled").StyledComponent<import("react-aria-components").TabPanelProps & import("react").RefAttributes<HTMLDivElement> & {
|
|
43
|
+
theme?: import("@emotion/react").Theme;
|
|
44
|
+
} & {
|
|
45
|
+
isActive: boolean;
|
|
46
|
+
isFirst: boolean;
|
|
47
|
+
}, {}, {}>;
|
|
48
|
+
export declare const NavigationButton: import("@emotion/styled").StyledComponent<{
|
|
49
|
+
theme?: import("@emotion/react").Theme;
|
|
50
|
+
as?: React.ElementType;
|
|
51
|
+
} & {
|
|
52
|
+
isActive: boolean;
|
|
53
|
+
index: number;
|
|
54
|
+
}, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
|
|
55
|
+
export declare const NavIconButtonContainer: import("@emotion/styled").StyledComponent<{
|
|
56
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
57
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
58
|
+
} & import("@codecademy/gamut").BoxProps & Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "content" | "translate" | "property" | "hidden" | "slot" | "style" | "title" | "suppressHydrationWarning" | "className" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "nonce" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof import("react").ClassAttributes<HTMLDivElement>> & {
|
|
59
|
+
theme?: import("@emotion/react").Theme;
|
|
60
|
+
} & {
|
|
61
|
+
isActive: boolean;
|
|
62
|
+
index: number;
|
|
63
|
+
}, {}, {}>;
|