@zendeskgarden/react-chrome 8.62.1 → 8.63.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/index.cjs.js +176 -188
- package/dist/index.esm.js +42 -51
- package/dist/typings/types/index.d.ts +2 -2
- package/package.json +4 -4
package/dist/index.cjs.js
CHANGED
|
@@ -7,8 +7,6 @@
|
|
|
7
7
|
|
|
8
8
|
'use strict';
|
|
9
9
|
|
|
10
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
11
|
-
|
|
12
10
|
var React = require('react');
|
|
13
11
|
var PropTypes = require('prop-types');
|
|
14
12
|
var styled = require('styled-components');
|
|
@@ -19,7 +17,7 @@ var containerUtilities = require('@zendeskgarden/container-utilities');
|
|
|
19
17
|
var reactUid = require('react-uid');
|
|
20
18
|
var mergeRefs = require('react-merge-refs');
|
|
21
19
|
|
|
22
|
-
function
|
|
20
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
23
21
|
|
|
24
22
|
function _interopNamespace(e) {
|
|
25
23
|
if (e && e.__esModule) return e;
|
|
@@ -35,15 +33,14 @@ function _interopNamespace(e) {
|
|
|
35
33
|
}
|
|
36
34
|
});
|
|
37
35
|
}
|
|
38
|
-
n
|
|
36
|
+
n.default = e;
|
|
39
37
|
return Object.freeze(n);
|
|
40
38
|
}
|
|
41
39
|
|
|
42
|
-
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
43
40
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
44
|
-
var PropTypes__default = /*#__PURE__*/
|
|
45
|
-
var styled__default = /*#__PURE__*/
|
|
46
|
-
var mergeRefs__default = /*#__PURE__*/
|
|
41
|
+
var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);
|
|
42
|
+
var styled__default = /*#__PURE__*/_interopDefault(styled);
|
|
43
|
+
var mergeRefs__default = /*#__PURE__*/_interopDefault(mergeRefs);
|
|
47
44
|
|
|
48
45
|
function _extends$3() {
|
|
49
46
|
_extends$3 = Object.assign ? Object.assign.bind() : function (target) {
|
|
@@ -60,7 +57,7 @@ function _extends$3() {
|
|
|
60
57
|
return _extends$3.apply(this, arguments);
|
|
61
58
|
}
|
|
62
59
|
|
|
63
|
-
const ChromeContext =
|
|
60
|
+
const ChromeContext = React__namespace.default.createContext({
|
|
64
61
|
hue: 'chromeHue'
|
|
65
62
|
});
|
|
66
63
|
const useChromeContext = () => {
|
|
@@ -68,9 +65,9 @@ const useChromeContext = () => {
|
|
|
68
65
|
};
|
|
69
66
|
|
|
70
67
|
const COMPONENT_ID$A = 'chrome.chrome';
|
|
71
|
-
const StyledChrome = styled__default
|
|
68
|
+
const StyledChrome = styled__default.default.div.attrs({
|
|
72
69
|
'data-garden-id': COMPONENT_ID$A,
|
|
73
|
-
'data-garden-version': '8.
|
|
70
|
+
'data-garden-version': '8.63.0'
|
|
74
71
|
}).withConfig({
|
|
75
72
|
displayName: "StyledChrome",
|
|
76
73
|
componentId: "sc-1uqm6u6-0"
|
|
@@ -80,9 +77,9 @@ StyledChrome.defaultProps = {
|
|
|
80
77
|
};
|
|
81
78
|
|
|
82
79
|
const COMPONENT_ID$z = 'chrome.header_item_icon';
|
|
83
|
-
const StyledHeaderItemIcon = styled__default
|
|
80
|
+
const StyledHeaderItemIcon = styled__default.default.div.attrs({
|
|
84
81
|
'data-garden-id': COMPONENT_ID$z,
|
|
85
|
-
'data-garden-version': '8.
|
|
82
|
+
'data-garden-version': '8.63.0'
|
|
86
83
|
}).withConfig({
|
|
87
84
|
displayName: "StyledHeaderItemIcon",
|
|
88
85
|
componentId: "sc-1jhhp6z-0"
|
|
@@ -97,9 +94,9 @@ const sizeStyles$4 = props => {
|
|
|
97
94
|
const size = props.theme.space.base * 7.5;
|
|
98
95
|
return styled.css(["padding:0 3px;min-width:", "px;height:", ";line-height:", ";"], size, props.maxY ? '100%' : `${size}px`, reactTheming.getLineHeight(size, props.theme.fontSizes.md));
|
|
99
96
|
};
|
|
100
|
-
const StyledBaseHeaderItem = styled__default
|
|
97
|
+
const StyledBaseHeaderItem = styled__default.default.button.attrs({
|
|
101
98
|
'data-garden-id': COMPONENT_ID$y,
|
|
102
|
-
'data-garden-version': '8.
|
|
99
|
+
'data-garden-version': '8.63.0'
|
|
103
100
|
}).withConfig({
|
|
104
101
|
displayName: "StyledBaseHeaderItem",
|
|
105
102
|
componentId: "sc-1qua7h6-0"
|
|
@@ -118,9 +115,9 @@ StyledBaseHeaderItem.defaultProps = {
|
|
|
118
115
|
|
|
119
116
|
const COMPONENT_ID$x = 'chrome.header_item_text';
|
|
120
117
|
const clippedStyling = styled.css(["position:absolute;margin:0;clip:rect(1px,1px,1px,1px);width:1px;height:1px;overflow:hidden;white-space:nowrap;"]);
|
|
121
|
-
const StyledHeaderItemText = styled__default
|
|
118
|
+
const StyledHeaderItemText = styled__default.default.span.attrs({
|
|
122
119
|
'data-garden-id': COMPONENT_ID$x,
|
|
123
|
-
'data-garden-version': '8.
|
|
120
|
+
'data-garden-version': '8.63.0'
|
|
124
121
|
}).withConfig({
|
|
125
122
|
displayName: "StyledHeaderItemText",
|
|
126
123
|
componentId: "sc-goz7la-0"
|
|
@@ -142,9 +139,9 @@ const getNavWidth = props => {
|
|
|
142
139
|
const getExpandedNavWidth = () => {
|
|
143
140
|
return `200px`;
|
|
144
141
|
};
|
|
145
|
-
const StyledNav = styled__default
|
|
142
|
+
const StyledNav = styled__default.default.nav.attrs({
|
|
146
143
|
'data-garden-id': COMPONENT_ID$w,
|
|
147
|
-
'data-garden-version': '8.
|
|
144
|
+
'data-garden-version': '8.63.0'
|
|
148
145
|
}).withConfig({
|
|
149
146
|
displayName: "StyledNav",
|
|
150
147
|
componentId: "sc-6j462r-0"
|
|
@@ -174,9 +171,9 @@ const retrieveProductColor$1 = props => {
|
|
|
174
171
|
return 'inherit';
|
|
175
172
|
}
|
|
176
173
|
};
|
|
177
|
-
const StyledLogoHeaderItem = styled__default
|
|
174
|
+
const StyledLogoHeaderItem = styled__default.default(StyledBaseHeaderItem).attrs({
|
|
178
175
|
'data-garden-id': COMPONENT_ID$v,
|
|
179
|
-
'data-garden-version': '8.
|
|
176
|
+
'data-garden-version': '8.63.0',
|
|
180
177
|
as: 'div'
|
|
181
178
|
}).withConfig({
|
|
182
179
|
displayName: "StyledLogoHeaderItem",
|
|
@@ -195,9 +192,9 @@ const sizeStyles$3 = props => {
|
|
|
195
192
|
const horizontalPadding = polished.math(`(${getNavWidth(props)} - ${props.theme.iconSizes.lg}) / 4`);
|
|
196
193
|
return styled.css(["padding:", " ", ";min-height:", ";"], verticalPadding, horizontalPadding, getNavItemHeight);
|
|
197
194
|
};
|
|
198
|
-
const StyledBaseNavItem = styled__default
|
|
195
|
+
const StyledBaseNavItem = styled__default.default.button.attrs({
|
|
199
196
|
'data-garden-id': COMPONENT_ID$u,
|
|
200
|
-
'data-garden-version': '8.
|
|
197
|
+
'data-garden-version': '8.63.0'
|
|
201
198
|
}).withConfig({
|
|
202
199
|
displayName: "StyledBaseNavItem",
|
|
203
200
|
componentId: "sc-zvo43f-0"
|
|
@@ -210,9 +207,9 @@ const COMPONENT_ID$t = 'chrome.header';
|
|
|
210
207
|
const getHeaderHeight = props => {
|
|
211
208
|
return getNavItemHeight(props);
|
|
212
209
|
};
|
|
213
|
-
const StyledHeader = styled__default
|
|
210
|
+
const StyledHeader = styled__default.default.header.attrs({
|
|
214
211
|
'data-garden-id': COMPONENT_ID$t,
|
|
215
|
-
'data-garden-version': '8.
|
|
212
|
+
'data-garden-version': '8.63.0'
|
|
216
213
|
}).withConfig({
|
|
217
214
|
displayName: "StyledHeader",
|
|
218
215
|
componentId: "sc-1cexpz-0"
|
|
@@ -244,9 +241,9 @@ const sizeStyles$2 = props => {
|
|
|
244
241
|
const lineHeight = reactTheming.getLineHeight(padding, fontSize);
|
|
245
242
|
return styled.css(["top:", ";padding:", ";padding-", ":", ";line-height:", ";font-size:", ";"], top, padding, props.theme.rtl ? 'right' : 'left', paddingStart, lineHeight, fontSize);
|
|
246
243
|
};
|
|
247
|
-
const StyledSkipNav = styled__default
|
|
244
|
+
const StyledSkipNav = styled__default.default.a.attrs({
|
|
248
245
|
'data-garden-id': COMPONENT_ID$s,
|
|
249
|
-
'data-garden-version': '8.
|
|
246
|
+
'data-garden-version': '8.63.0'
|
|
250
247
|
}).withConfig({
|
|
251
248
|
displayName: "StyledSkipNav",
|
|
252
249
|
componentId: "sc-1tsro34-0"
|
|
@@ -256,9 +253,7 @@ StyledSkipNav.defaultProps = {
|
|
|
256
253
|
};
|
|
257
254
|
|
|
258
255
|
var _path$2;
|
|
259
|
-
|
|
260
256
|
function _extends$2() { _extends$2 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$2.apply(this, arguments); }
|
|
261
|
-
|
|
262
257
|
var SvgLinkStroke = function SvgLinkStroke(props) {
|
|
263
258
|
return /*#__PURE__*/React__namespace.createElement("svg", _extends$2({
|
|
264
259
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -266,8 +261,7 @@ var SvgLinkStroke = function SvgLinkStroke(props) {
|
|
|
266
261
|
height: 16,
|
|
267
262
|
focusable: "false",
|
|
268
263
|
viewBox: "0 0 16 16",
|
|
269
|
-
"aria-hidden": "true"
|
|
270
|
-
role: "img"
|
|
264
|
+
"aria-hidden": "true"
|
|
271
265
|
}, props), _path$2 || (_path$2 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
272
266
|
fill: "currentColor",
|
|
273
267
|
d: "M4.441 7.38l.095.083.939.939-.708.707-.939-.939-2 2-.132.142a2.829 2.829 0 003.99 3.99l.142-.132 2-2-.939-.939.707-.708.94.94a1 1 0 01.083 1.32l-.083.094-2 2A3.828 3.828 0 01.972 9.621l.15-.158 2-2A1 1 0 014.34 7.31l.101.07zm7.413-3.234a.5.5 0 01.057.638l-.057.07-7 7a.5.5 0 01-.765-.638l.057-.07 7-7a.5.5 0 01.708 0zm3.023-3.025a3.829 3.829 0 01.15 5.257l-.15.158-2 2a1 1 0 01-1.32.083l-.094-.083-.94-.94.708-.707.939.94 2-2 .132-.142a2.829 2.829 0 00-3.99-3.99l-.142.131-2 2 .939.939-.707.708-.94-.94a1 1 0 01-.082-1.32l.083-.094 2-2a3.828 3.828 0 015.414 0z"
|
|
@@ -280,9 +274,9 @@ const sizeStyles$1 = theme => {
|
|
|
280
274
|
const size = theme.iconSizes.md;
|
|
281
275
|
return styled.css(["margin-", ":", ";width:", ";height:", ";"], theme.rtl ? 'left' : 'right', margin, size, size);
|
|
282
276
|
};
|
|
283
|
-
const StyledSkipNavIcon = styled__default
|
|
277
|
+
const StyledSkipNavIcon = styled__default.default(SvgLinkStroke).attrs({
|
|
284
278
|
'data-garden-id': COMPONENT_ID$r,
|
|
285
|
-
'data-garden-version': '8.
|
|
279
|
+
'data-garden-version': '8.63.0'
|
|
286
280
|
}).withConfig({
|
|
287
281
|
displayName: "StyledSkipNavIcon",
|
|
288
282
|
componentId: "sc-1ika5z4-0"
|
|
@@ -292,9 +286,9 @@ StyledSkipNavIcon.defaultProps = {
|
|
|
292
286
|
};
|
|
293
287
|
|
|
294
288
|
const COMPONENT_ID$q = 'chrome.body';
|
|
295
|
-
const StyledBody = styled__default
|
|
289
|
+
const StyledBody = styled__default.default.div.attrs({
|
|
296
290
|
'data-garden-id': COMPONENT_ID$q,
|
|
297
|
-
'data-garden-version': '8.
|
|
291
|
+
'data-garden-version': '8.63.0'
|
|
298
292
|
}).withConfig({
|
|
299
293
|
displayName: "StyledBody",
|
|
300
294
|
componentId: "sc-c7h9kv-0"
|
|
@@ -307,9 +301,9 @@ const COMPONENT_ID$p = 'chrome.footer';
|
|
|
307
301
|
const getFooterHeight = props => {
|
|
308
302
|
return `${props.theme.space.base * 20}px`;
|
|
309
303
|
};
|
|
310
|
-
const StyledFooter = styled__default
|
|
304
|
+
const StyledFooter = styled__default.default.footer.attrs({
|
|
311
305
|
'data-garden-id': COMPONENT_ID$p,
|
|
312
|
-
'data-garden-version': '8.
|
|
306
|
+
'data-garden-version': '8.63.0'
|
|
313
307
|
}).withConfig({
|
|
314
308
|
displayName: "StyledFooter",
|
|
315
309
|
componentId: "sc-v7lib2-0"
|
|
@@ -319,9 +313,9 @@ StyledFooter.defaultProps = {
|
|
|
319
313
|
};
|
|
320
314
|
|
|
321
315
|
const COMPONENT_ID$o = 'chrome.content';
|
|
322
|
-
const StyledContent = styled__default
|
|
316
|
+
const StyledContent = styled__default.default.div.attrs({
|
|
323
317
|
'data-garden-id': COMPONENT_ID$o,
|
|
324
|
-
'data-garden-version': '8.
|
|
318
|
+
'data-garden-version': '8.63.0'
|
|
325
319
|
}).withConfig({
|
|
326
320
|
displayName: "StyledContent",
|
|
327
321
|
componentId: "sc-qcuzxn-0"
|
|
@@ -331,9 +325,9 @@ StyledContent.defaultProps = {
|
|
|
331
325
|
};
|
|
332
326
|
|
|
333
327
|
const COMPONENT_ID$n = 'chrome.main';
|
|
334
|
-
const StyledMain = styled__default
|
|
328
|
+
const StyledMain = styled__default.default.main.attrs({
|
|
335
329
|
'data-garden-id': COMPONENT_ID$n,
|
|
336
|
-
'data-garden-version': '8.
|
|
330
|
+
'data-garden-version': '8.63.0'
|
|
337
331
|
}).withConfig({
|
|
338
332
|
displayName: "StyledMain",
|
|
339
333
|
componentId: "sc-t61cre-0"
|
|
@@ -343,9 +337,9 @@ StyledMain.defaultProps = {
|
|
|
343
337
|
};
|
|
344
338
|
|
|
345
339
|
const COMPONENT_ID$m = 'chrome.sidebar';
|
|
346
|
-
const StyledSidebar = styled__default
|
|
340
|
+
const StyledSidebar = styled__default.default.aside.attrs({
|
|
347
341
|
'data-garden-id': COMPONENT_ID$m,
|
|
348
|
-
'data-garden-version': '8.
|
|
342
|
+
'data-garden-version': '8.63.0'
|
|
349
343
|
}).withConfig({
|
|
350
344
|
displayName: "StyledSidebar",
|
|
351
345
|
componentId: "sc-1q77fuw-0"
|
|
@@ -355,9 +349,9 @@ StyledSidebar.defaultProps = {
|
|
|
355
349
|
};
|
|
356
350
|
|
|
357
351
|
const COMPONENT_ID$l = 'chrome.footer_item';
|
|
358
|
-
const StyledFooterItem = styled__default
|
|
352
|
+
const StyledFooterItem = styled__default.default.div.attrs({
|
|
359
353
|
'data-garden-id': COMPONENT_ID$l,
|
|
360
|
-
'data-garden-version': '8.
|
|
354
|
+
'data-garden-version': '8.63.0'
|
|
361
355
|
}).withConfig({
|
|
362
356
|
displayName: "StyledFooterItem",
|
|
363
357
|
componentId: "sc-1cktm85-0"
|
|
@@ -371,9 +365,9 @@ const imgStyles = props => {
|
|
|
371
365
|
const size = polished.math(`${getHeaderItemSize(props)} - ${props.theme.space.base * 2}`);
|
|
372
366
|
return styled.css(["img{margin:0;border-radius:", ";width:", ";height:", ";}"], polished.math(`${props.theme.borderRadii.md} - 1`), size, size);
|
|
373
367
|
};
|
|
374
|
-
const StyledHeaderItem = styled__default
|
|
368
|
+
const StyledHeaderItem = styled__default.default(StyledBaseHeaderItem).attrs({
|
|
375
369
|
'data-garden-id': COMPONENT_ID$k,
|
|
376
|
-
'data-garden-version': '8.
|
|
370
|
+
'data-garden-version': '8.63.0'
|
|
377
371
|
}).withConfig({
|
|
378
372
|
displayName: "StyledHeaderItem",
|
|
379
373
|
componentId: "sc-14sft6n-0"
|
|
@@ -394,9 +388,9 @@ StyledHeaderItem.defaultProps = {
|
|
|
394
388
|
};
|
|
395
389
|
|
|
396
390
|
const COMPONENT_ID$j = 'chrome.header_item_wrapper';
|
|
397
|
-
const StyledHeaderItemWrapper = styled__default
|
|
391
|
+
const StyledHeaderItemWrapper = styled__default.default(StyledBaseHeaderItem).attrs({
|
|
398
392
|
'data-garden-id': COMPONENT_ID$j,
|
|
399
|
-
'data-garden-version': '8.
|
|
393
|
+
'data-garden-version': '8.63.0',
|
|
400
394
|
as: 'div'
|
|
401
395
|
}).withConfig({
|
|
402
396
|
displayName: "StyledHeaderItemWrapper",
|
|
@@ -432,9 +426,9 @@ const colorStyles$4 = props => {
|
|
|
432
426
|
const color = props.isLight || props.isDark ? fillColor : retrieveProductColor(props.product);
|
|
433
427
|
return styled.css(["color:", ";fill:", ";"], color, fillColor);
|
|
434
428
|
};
|
|
435
|
-
const StyledLogoNavItem = styled__default
|
|
429
|
+
const StyledLogoNavItem = styled__default.default(StyledBaseNavItem).attrs({
|
|
436
430
|
'data-garden-id': COMPONENT_ID$i,
|
|
437
|
-
'data-garden-version': '8.
|
|
431
|
+
'data-garden-version': '8.63.0',
|
|
438
432
|
as: 'div'
|
|
439
433
|
}).withConfig({
|
|
440
434
|
displayName: "StyledLogoNavItem",
|
|
@@ -445,9 +439,9 @@ StyledLogoNavItem.defaultProps = {
|
|
|
445
439
|
};
|
|
446
440
|
|
|
447
441
|
const COMPONENT_ID$h = 'chrome.brandmark_nav_item';
|
|
448
|
-
const StyledBrandmarkNavItem = styled__default
|
|
442
|
+
const StyledBrandmarkNavItem = styled__default.default(StyledBaseNavItem).attrs({
|
|
449
443
|
'data-garden-id': COMPONENT_ID$h,
|
|
450
|
-
'data-garden-version': '8.
|
|
444
|
+
'data-garden-version': '8.63.0',
|
|
451
445
|
as: 'div'
|
|
452
446
|
}).withConfig({
|
|
453
447
|
displayName: "StyledBrandmarkNavItem",
|
|
@@ -458,9 +452,9 @@ StyledBrandmarkNavItem.defaultProps = {
|
|
|
458
452
|
};
|
|
459
453
|
|
|
460
454
|
const COMPONENT_ID$g = 'chrome.nav_item_icon';
|
|
461
|
-
const StyledNavItemIcon = styled__default
|
|
455
|
+
const StyledNavItemIcon = styled__default.default.div.attrs({
|
|
462
456
|
'data-garden-id': COMPONENT_ID$g,
|
|
463
|
-
'data-garden-version': '8.
|
|
457
|
+
'data-garden-version': '8.63.0'
|
|
464
458
|
}).withConfig({
|
|
465
459
|
displayName: "StyledNavItemIcon",
|
|
466
460
|
componentId: "sc-7w9rpt-0"
|
|
@@ -490,9 +484,9 @@ const colorStyles$3 = props => {
|
|
|
490
484
|
const focusColor = polished.rgba(props.isLight ? BLACK : WHITE, 0.2);
|
|
491
485
|
return styled.css(["opacity:", ";background-color:", ";&:hover{opacity:1;background-color:", ";}&[data-garden-focus-visible]{opacity:1;box-shadow:inset ", ";}&:active{background-color:", ";}"], props.isCurrent ? 1 : 0.6, currentColor, hoverColor, props.theme.shadows.md(focusColor), activeColor);
|
|
492
486
|
};
|
|
493
|
-
const StyledNavItem = styled__default
|
|
487
|
+
const StyledNavItem = styled__default.default(StyledBaseNavItem).attrs({
|
|
494
488
|
'data-garden-id': COMPONENT_ID$f,
|
|
495
|
-
'data-garden-version': '8.
|
|
489
|
+
'data-garden-version': '8.63.0',
|
|
496
490
|
as: 'button'
|
|
497
491
|
}).withConfig({
|
|
498
492
|
displayName: "StyledNavItem",
|
|
@@ -507,9 +501,9 @@ StyledNavItem.defaultProps = {
|
|
|
507
501
|
};
|
|
508
502
|
|
|
509
503
|
const COMPONENT_ID$e = 'chrome.nav_item_text';
|
|
510
|
-
const StyledNavItemText = styled__default
|
|
504
|
+
const StyledNavItemText = styled__default.default.span.attrs({
|
|
511
505
|
'data-garden-id': COMPONENT_ID$e,
|
|
512
|
-
'data-garden-version': '8.
|
|
506
|
+
'data-garden-version': '8.63.0'
|
|
513
507
|
}).withConfig({
|
|
514
508
|
displayName: "StyledNavItemText",
|
|
515
509
|
componentId: "sc-13m84xl-0"
|
|
@@ -549,9 +543,9 @@ const colorStyles$2 = props => {
|
|
|
549
543
|
const getSubNavItemHeight = props => {
|
|
550
544
|
return `${props.theme.space.base * 7.5}px`;
|
|
551
545
|
};
|
|
552
|
-
const StyledSubNavItem = styled__default
|
|
546
|
+
const StyledSubNavItem = styled__default.default.button.attrs({
|
|
553
547
|
'data-garden-id': COMPONENT_ID$d,
|
|
554
|
-
'data-garden-version': '8.
|
|
548
|
+
'data-garden-version': '8.63.0'
|
|
555
549
|
}).withConfig({
|
|
556
550
|
displayName: "StyledSubNavItem",
|
|
557
551
|
componentId: "sc-1yg9dpx-0"
|
|
@@ -572,9 +566,9 @@ const colorStyles$1 = props => {
|
|
|
572
566
|
const foregroundColor = props.isLight ? props.theme.palette.grey[800] : props.theme.palette.white;
|
|
573
567
|
return styled.css(["background-color:", ";color:", ";"], backgroundColor, foregroundColor);
|
|
574
568
|
};
|
|
575
|
-
const StyledSubNav = styled__default
|
|
569
|
+
const StyledSubNav = styled__default.default.nav.attrs({
|
|
576
570
|
'data-garden-id': COMPONENT_ID$c,
|
|
577
|
-
'data-garden-version': '8.
|
|
571
|
+
'data-garden-version': '8.63.0'
|
|
578
572
|
}).withConfig({
|
|
579
573
|
displayName: "StyledSubNav",
|
|
580
574
|
componentId: "sc-19hjou6-0"
|
|
@@ -590,9 +584,9 @@ const sizeStyles = props => {
|
|
|
590
584
|
const lineHeight = reactTheming.getLineHeight(baseLineHeight, props.theme.fontSizes.md);
|
|
591
585
|
return styled.css(["margin:", " 0;line-height:", ";"], verticalMargin, lineHeight);
|
|
592
586
|
};
|
|
593
|
-
const StyledSubNavItemText = styled__default
|
|
587
|
+
const StyledSubNavItemText = styled__default.default.span.attrs({
|
|
594
588
|
'data-garden-id': COMPONENT_ID$b,
|
|
595
|
-
'data-garden-version': '8.
|
|
589
|
+
'data-garden-version': '8.63.0'
|
|
596
590
|
}).withConfig({
|
|
597
591
|
displayName: "StyledSubNavItemText",
|
|
598
592
|
componentId: "sc-1hy0pn7-0"
|
|
@@ -602,9 +596,9 @@ StyledSubNavItemText.defaultProps = {
|
|
|
602
596
|
};
|
|
603
597
|
|
|
604
598
|
const COMPONENT_ID$a = 'chrome.collapsible_sub_nav_item';
|
|
605
|
-
const StyledSubNavItemHeader = styled__default
|
|
599
|
+
const StyledSubNavItemHeader = styled__default.default(StyledSubNavItem).attrs({
|
|
606
600
|
'data-garden-id': COMPONENT_ID$a,
|
|
607
|
-
'data-garden-version': '8.
|
|
601
|
+
'data-garden-version': '8.63.0',
|
|
608
602
|
'data-garden-header': 'true'
|
|
609
603
|
}).withConfig({
|
|
610
604
|
displayName: "StyledSubNavItemHeader",
|
|
@@ -615,9 +609,7 @@ StyledSubNavItemHeader.defaultProps = {
|
|
|
615
609
|
};
|
|
616
610
|
|
|
617
611
|
var _path$1;
|
|
618
|
-
|
|
619
612
|
function _extends$1() { _extends$1 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$1.apply(this, arguments); }
|
|
620
|
-
|
|
621
613
|
var SvgChevronDownStroke = function SvgChevronDownStroke(props) {
|
|
622
614
|
return /*#__PURE__*/React__namespace.createElement("svg", _extends$1({
|
|
623
615
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -625,8 +617,7 @@ var SvgChevronDownStroke = function SvgChevronDownStroke(props) {
|
|
|
625
617
|
height: 12,
|
|
626
618
|
focusable: "false",
|
|
627
619
|
viewBox: "0 0 12 12",
|
|
628
|
-
"aria-hidden": "true"
|
|
629
|
-
role: "img"
|
|
620
|
+
"aria-hidden": "true"
|
|
630
621
|
}, props), _path$1 || (_path$1 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
631
622
|
fill: "currentColor",
|
|
632
623
|
d: "M1.646 3.646a.5.5 0 01.638-.057l.07.057L6 7.293l3.646-3.647a.5.5 0 01.638-.057l.07.057a.5.5 0 01.057.638l-.057.07-4 4a.5.5 0 01-.638.057l-.07-.057-4-4a.5.5 0 010-.708z"
|
|
@@ -634,27 +625,27 @@ var SvgChevronDownStroke = function SvgChevronDownStroke(props) {
|
|
|
634
625
|
};
|
|
635
626
|
|
|
636
627
|
const COMPONENT_ID$9 = 'chrome.collapsible_sub_nav_item_icon';
|
|
637
|
-
const FilteredChevronDownStrokeIcon =
|
|
628
|
+
const FilteredChevronDownStrokeIcon = React__namespace.default.forwardRef((_ref, ref) => {
|
|
638
629
|
let {
|
|
639
630
|
theme,
|
|
640
631
|
isExpanded,
|
|
641
632
|
...validProps
|
|
642
633
|
} = _ref;
|
|
643
|
-
return
|
|
634
|
+
return React__namespace.default.createElement(SvgChevronDownStroke, _extends$3({
|
|
644
635
|
ref: ref
|
|
645
636
|
}, validProps));
|
|
646
637
|
});
|
|
647
638
|
FilteredChevronDownStrokeIcon.displayName = 'FilteredChevronDownStrokeIcon';
|
|
648
|
-
const StyledSubNavItemIcon = styled__default
|
|
639
|
+
const StyledSubNavItemIcon = styled__default.default(FilteredChevronDownStrokeIcon).withConfig({
|
|
649
640
|
displayName: "StyledSubNavItemIcon",
|
|
650
641
|
componentId: "sc-1d02hho-0"
|
|
651
642
|
})(["width:", ";height:", ";"], props => props.theme.iconSizes.sm, props => props.theme.iconSizes.sm);
|
|
652
643
|
StyledSubNavItemIcon.defaultProps = {
|
|
653
644
|
theme: reactTheming.DEFAULT_THEME
|
|
654
645
|
};
|
|
655
|
-
const StyledSubNavItemIconWrapper = styled__default
|
|
646
|
+
const StyledSubNavItemIconWrapper = styled__default.default.div.attrs({
|
|
656
647
|
'data-garden-id': COMPONENT_ID$9,
|
|
657
|
-
'data-garden-version': '8.
|
|
648
|
+
'data-garden-version': '8.63.0'
|
|
658
649
|
}).withConfig({
|
|
659
650
|
displayName: "StyledSubNavItemIcon__StyledSubNavItemIconWrapper",
|
|
660
651
|
componentId: "sc-1d02hho-1"
|
|
@@ -670,9 +661,9 @@ StyledSubNavItemIconWrapper.defaultProps = {
|
|
|
670
661
|
|
|
671
662
|
const PANEL_COMPONENT_ID = 'chrome.collapsible_sub_nav_item_panel';
|
|
672
663
|
const hiddenStyling = styled.css(["visibility:hidden;max-height:0 !important;overflow:hidden;"]);
|
|
673
|
-
const StyledSubNavPanel = styled__default
|
|
664
|
+
const StyledSubNavPanel = styled__default.default.div.attrs({
|
|
674
665
|
'data-garden-id': PANEL_COMPONENT_ID,
|
|
675
|
-
'data-garden-version': '8.
|
|
666
|
+
'data-garden-version': '8.63.0'
|
|
676
667
|
}).withConfig({
|
|
677
668
|
displayName: "StyledSubNavPanel",
|
|
678
669
|
componentId: "sc-1jv3rpv-0"
|
|
@@ -701,9 +692,9 @@ const borderStyle = _ref => {
|
|
|
701
692
|
}
|
|
702
693
|
return `border${borderSide}: ${theme.borders.sm} ${borderColor};`;
|
|
703
694
|
};
|
|
704
|
-
const StyledSheet = styled__default
|
|
695
|
+
const StyledSheet = styled__default.default.aside.attrs({
|
|
705
696
|
'data-garden-id': COMPONENT_ID$8,
|
|
706
|
-
'data-garden-version': '8.
|
|
697
|
+
'data-garden-version': '8.63.0'
|
|
707
698
|
}).withConfig({
|
|
708
699
|
displayName: "StyledSheet",
|
|
709
700
|
componentId: "sc-dx8ijk-0"
|
|
@@ -713,9 +704,9 @@ StyledSheet.defaultProps = {
|
|
|
713
704
|
};
|
|
714
705
|
|
|
715
706
|
const COMPONENT_ID$7 = 'chrome.sheet_wrapper';
|
|
716
|
-
const StyledSheetWrapper = styled__default
|
|
707
|
+
const StyledSheetWrapper = styled__default.default.div.attrs({
|
|
717
708
|
'data-garden-id': COMPONENT_ID$7,
|
|
718
|
-
'data-garden-version': '8.
|
|
709
|
+
'data-garden-version': '8.63.0'
|
|
719
710
|
}).withConfig({
|
|
720
711
|
displayName: "StyledSheetWrapper",
|
|
721
712
|
componentId: "sc-f6x9zb-0"
|
|
@@ -740,9 +731,9 @@ StyledSheetWrapper.defaultProps = {
|
|
|
740
731
|
};
|
|
741
732
|
|
|
742
733
|
const COMPONENT_ID$6 = 'chrome.sheet_title';
|
|
743
|
-
const StyledSheetTitle = styled__default
|
|
734
|
+
const StyledSheetTitle = styled__default.default.div.attrs({
|
|
744
735
|
'data-garden-id': COMPONENT_ID$6,
|
|
745
|
-
'data-garden-version': '8.
|
|
736
|
+
'data-garden-version': '8.63.0'
|
|
746
737
|
}).withConfig({
|
|
747
738
|
displayName: "StyledSheetTitle",
|
|
748
739
|
componentId: "sc-1gogk75-0"
|
|
@@ -752,9 +743,9 @@ StyledSheetTitle.defaultProps = {
|
|
|
752
743
|
};
|
|
753
744
|
|
|
754
745
|
const COMPONENT_ID$5 = 'chrome.sheet_description';
|
|
755
|
-
const StyledSheetDescription = styled__default
|
|
746
|
+
const StyledSheetDescription = styled__default.default.div.attrs({
|
|
756
747
|
'data-garden-id': COMPONENT_ID$5,
|
|
757
|
-
'data-garden-version': '8.
|
|
748
|
+
'data-garden-version': '8.63.0'
|
|
758
749
|
}).withConfig({
|
|
759
750
|
displayName: "StyledSheetDescription",
|
|
760
751
|
componentId: "sc-1puglb6-0"
|
|
@@ -764,9 +755,9 @@ StyledSheetDescription.defaultProps = {
|
|
|
764
755
|
};
|
|
765
756
|
|
|
766
757
|
const COMPONENT_ID$4 = 'chrome.sheet_body';
|
|
767
|
-
const StyledSheetBody = styled__default
|
|
758
|
+
const StyledSheetBody = styled__default.default.div.attrs({
|
|
768
759
|
'data-garden-id': COMPONENT_ID$4,
|
|
769
|
-
'data-garden-version': '8.
|
|
760
|
+
'data-garden-version': '8.63.0'
|
|
770
761
|
}).withConfig({
|
|
771
762
|
displayName: "StyledSheetBody",
|
|
772
763
|
componentId: "sc-bt4eoj-0"
|
|
@@ -786,9 +777,9 @@ const colorStyles = props => {
|
|
|
786
777
|
const foregroundColor = 'neutralHue';
|
|
787
778
|
return styled.css(["background-color:transparent;color:", ";&:hover{background-color:", ";color:", ";}&[data-garden-focus-visible]{box-shadow:", ";}&:active{transition:background-color 0.1s ease-in-out,color 0.1s ease-in-out;background-color:", ";color:", ";}"], reactTheming.getColor(foregroundColor, 600, props.theme), reactTheming.getColor(backgroundColor, 600, props.theme, 0.08), reactTheming.getColor(foregroundColor, 700, props.theme), props.theme.shadows.md(reactTheming.getColor(backgroundColor, 600, props.theme, 0.35)), reactTheming.getColor(backgroundColor, 600, props.theme, 0.2), reactTheming.getColor(foregroundColor, 800, props.theme));
|
|
788
779
|
};
|
|
789
|
-
const StyledSheetClose = styled__default
|
|
780
|
+
const StyledSheetClose = styled__default.default.button.attrs({
|
|
790
781
|
'data-garden-id': COMPONENT_ID$3,
|
|
791
|
-
'data-garden-version': '8.
|
|
782
|
+
'data-garden-version': '8.63.0'
|
|
792
783
|
}).withConfig({
|
|
793
784
|
displayName: "StyledSheetClose",
|
|
794
785
|
componentId: "sc-1ab02oq-0"
|
|
@@ -798,9 +789,9 @@ StyledSheetClose.defaultProps = {
|
|
|
798
789
|
};
|
|
799
790
|
|
|
800
791
|
const COMPONENT_ID$2 = 'chrome.sheet_footer';
|
|
801
|
-
const StyledSheetFooter = styled__default
|
|
792
|
+
const StyledSheetFooter = styled__default.default.footer.attrs({
|
|
802
793
|
'data-garden-id': COMPONENT_ID$2,
|
|
803
|
-
'data-garden-version': '8.
|
|
794
|
+
'data-garden-version': '8.63.0'
|
|
804
795
|
}).withConfig({
|
|
805
796
|
displayName: "StyledSheetFooter",
|
|
806
797
|
componentId: "sc-2cktos-0"
|
|
@@ -810,9 +801,9 @@ StyledSheetFooter.defaultProps = {
|
|
|
810
801
|
};
|
|
811
802
|
|
|
812
803
|
const COMPONENT_ID$1 = 'chrome.sheet_footer_item';
|
|
813
|
-
const StyledSheetFooterItem = styled__default
|
|
804
|
+
const StyledSheetFooterItem = styled__default.default.div.attrs({
|
|
814
805
|
'data-garden-id': COMPONENT_ID$1,
|
|
815
|
-
'data-garden-version': '8.
|
|
806
|
+
'data-garden-version': '8.63.0'
|
|
816
807
|
}).withConfig({
|
|
817
808
|
displayName: "StyledSheetFooterItem",
|
|
818
809
|
componentId: "sc-r9ixh-0"
|
|
@@ -822,9 +813,9 @@ StyledSheetFooterItem.defaultProps = {
|
|
|
822
813
|
};
|
|
823
814
|
|
|
824
815
|
const COMPONENT_ID = 'chrome.sheet_header';
|
|
825
|
-
const StyledSheetHeader = styled__default
|
|
816
|
+
const StyledSheetHeader = styled__default.default.header.attrs({
|
|
826
817
|
'data-garden-id': COMPONENT_ID,
|
|
827
|
-
'data-garden-version': '8.
|
|
818
|
+
'data-garden-version': '8.63.0'
|
|
828
819
|
}).withConfig({
|
|
829
820
|
displayName: "StyledSheetHeader",
|
|
830
821
|
componentId: "sc-o2ry8i-0"
|
|
@@ -833,7 +824,7 @@ StyledSheetHeader.defaultProps = {
|
|
|
833
824
|
theme: reactTheming.DEFAULT_THEME
|
|
834
825
|
};
|
|
835
826
|
|
|
836
|
-
const Chrome =
|
|
827
|
+
const Chrome = React__namespace.default.forwardRef((_ref, ref) => {
|
|
837
828
|
let {
|
|
838
829
|
hue,
|
|
839
830
|
isFluid,
|
|
@@ -869,47 +860,47 @@ const Chrome = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
869
860
|
}
|
|
870
861
|
return undefined;
|
|
871
862
|
}, [environment, isFluid]);
|
|
872
|
-
return
|
|
863
|
+
return React__namespace.default.createElement(ChromeContext.Provider, {
|
|
873
864
|
value: chromeContextValue
|
|
874
|
-
},
|
|
865
|
+
}, React__namespace.default.createElement(StyledChrome, _extends$3({
|
|
875
866
|
ref: ref
|
|
876
867
|
}, props)));
|
|
877
868
|
});
|
|
878
869
|
Chrome.displayName = 'Chrome';
|
|
879
870
|
Chrome.propTypes = {
|
|
880
|
-
hue: PropTypes__default
|
|
871
|
+
hue: PropTypes__default.default.string
|
|
881
872
|
};
|
|
882
873
|
|
|
883
|
-
const SkipNav =
|
|
874
|
+
const SkipNav = React__namespace.default.forwardRef((_ref, ref) => {
|
|
884
875
|
let {
|
|
885
876
|
targetId,
|
|
886
877
|
zIndex,
|
|
887
878
|
children,
|
|
888
879
|
...props
|
|
889
880
|
} = _ref;
|
|
890
|
-
return
|
|
881
|
+
return React__namespace.default.createElement(StyledSkipNav, _extends$3({
|
|
891
882
|
href: `#${targetId}`,
|
|
892
883
|
zIndex: zIndex,
|
|
893
884
|
ref: ref
|
|
894
|
-
}, props),
|
|
885
|
+
}, props), React__namespace.default.createElement(StyledSkipNavIcon, null), children);
|
|
895
886
|
});
|
|
896
887
|
SkipNav.displayName = 'SkipNav';
|
|
897
888
|
SkipNav.propTypes = {
|
|
898
|
-
targetId: PropTypes__default
|
|
899
|
-
zIndex: PropTypes__default
|
|
889
|
+
targetId: PropTypes__default.default.string.isRequired,
|
|
890
|
+
zIndex: PropTypes__default.default.number
|
|
900
891
|
};
|
|
901
892
|
SkipNav.defaultProps = {
|
|
902
893
|
zIndex: 1
|
|
903
894
|
};
|
|
904
895
|
|
|
905
|
-
const BodyContext =
|
|
896
|
+
const BodyContext = React__namespace.default.createContext({
|
|
906
897
|
hasFooter: true
|
|
907
898
|
});
|
|
908
899
|
const useBodyContext = () => {
|
|
909
900
|
return React.useContext(BodyContext);
|
|
910
901
|
};
|
|
911
902
|
|
|
912
|
-
const Body$1 =
|
|
903
|
+
const Body$1 = React__namespace.default.forwardRef((_ref, ref) => {
|
|
913
904
|
let {
|
|
914
905
|
hasFooter,
|
|
915
906
|
...props
|
|
@@ -917,72 +908,72 @@ const Body$1 = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
917
908
|
const bodyContextValue = React.useMemo(() => ({
|
|
918
909
|
hasFooter: !!hasFooter
|
|
919
910
|
}), [hasFooter]);
|
|
920
|
-
return
|
|
911
|
+
return React__namespace.default.createElement(BodyContext.Provider, {
|
|
921
912
|
value: bodyContextValue
|
|
922
|
-
},
|
|
913
|
+
}, React__namespace.default.createElement(StyledBody, _extends$3({
|
|
923
914
|
ref: ref
|
|
924
915
|
}, props)));
|
|
925
916
|
});
|
|
926
917
|
Body$1.displayName = 'Body';
|
|
927
918
|
Body$1.propTypes = {
|
|
928
|
-
hasFooter: PropTypes__default
|
|
919
|
+
hasFooter: PropTypes__default.default.bool
|
|
929
920
|
};
|
|
930
921
|
|
|
931
|
-
const Content =
|
|
922
|
+
const Content = React__namespace.default.forwardRef((props, ref) => {
|
|
932
923
|
const {
|
|
933
924
|
hasFooter
|
|
934
925
|
} = useBodyContext();
|
|
935
|
-
return
|
|
926
|
+
return React__namespace.default.createElement(StyledContent, _extends$3({
|
|
936
927
|
ref: ref,
|
|
937
928
|
hasFooter: hasFooter
|
|
938
929
|
}, props));
|
|
939
930
|
});
|
|
940
931
|
Content.displayName = 'Content';
|
|
941
932
|
|
|
942
|
-
const Main =
|
|
933
|
+
const Main = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledMain, _extends$3({
|
|
943
934
|
ref: ref
|
|
944
935
|
}, props)));
|
|
945
936
|
Main.displayName = 'Main';
|
|
946
937
|
|
|
947
|
-
const Sidebar =
|
|
938
|
+
const Sidebar = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledSidebar, _extends$3({
|
|
948
939
|
ref: ref
|
|
949
940
|
}, props)));
|
|
950
941
|
Sidebar.displayName = 'Sidebar';
|
|
951
942
|
|
|
952
|
-
const Header$1 =
|
|
943
|
+
const Header$1 = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledHeader, _extends$3({
|
|
953
944
|
ref: ref
|
|
954
945
|
}, props)));
|
|
955
946
|
Header$1.displayName = 'Header';
|
|
956
947
|
Header$1.propTypes = {
|
|
957
|
-
isStandalone: PropTypes__default
|
|
948
|
+
isStandalone: PropTypes__default.default.bool
|
|
958
949
|
};
|
|
959
950
|
|
|
960
951
|
const PLACEMENT = ['end', 'start'];
|
|
961
952
|
const PRODUCT = ['chat', 'connect', 'explore', 'guide', 'message', 'support', 'talk'];
|
|
962
953
|
|
|
963
|
-
const HeaderItem =
|
|
954
|
+
const HeaderItem = React__namespace.default.forwardRef((_ref, ref) => {
|
|
964
955
|
let {
|
|
965
956
|
hasLogo,
|
|
966
957
|
product,
|
|
967
958
|
...other
|
|
968
959
|
} = _ref;
|
|
969
960
|
if (hasLogo) {
|
|
970
|
-
return
|
|
961
|
+
return React__namespace.default.createElement(StyledLogoHeaderItem, _extends$3({
|
|
971
962
|
ref: ref,
|
|
972
963
|
product: product
|
|
973
964
|
}, other));
|
|
974
965
|
}
|
|
975
|
-
return
|
|
966
|
+
return React__namespace.default.createElement(StyledHeaderItem, _extends$3({
|
|
976
967
|
ref: ref
|
|
977
968
|
}, other));
|
|
978
969
|
});
|
|
979
970
|
HeaderItem.displayName = 'HeaderItem';
|
|
980
971
|
HeaderItem.propTypes = {
|
|
981
|
-
maxX: PropTypes__default
|
|
982
|
-
maxY: PropTypes__default
|
|
983
|
-
isRound: PropTypes__default
|
|
984
|
-
product: PropTypes__default
|
|
985
|
-
hasLogo: PropTypes__default
|
|
972
|
+
maxX: PropTypes__default.default.bool,
|
|
973
|
+
maxY: PropTypes__default.default.bool,
|
|
974
|
+
isRound: PropTypes__default.default.bool,
|
|
975
|
+
product: PropTypes__default.default.oneOf(PRODUCT),
|
|
976
|
+
hasLogo: PropTypes__default.default.bool
|
|
986
977
|
};
|
|
987
978
|
|
|
988
979
|
const HeaderItemIcon = _ref => {
|
|
@@ -1002,44 +993,44 @@ const HeaderItemIcon = _ref => {
|
|
|
1002
993
|
...iconProps
|
|
1003
994
|
});
|
|
1004
995
|
};
|
|
1005
|
-
return
|
|
996
|
+
return React__namespace.default.createElement(StyledHeaderItemIcon, _extends$3({
|
|
1006
997
|
as: Icon
|
|
1007
998
|
}, props));
|
|
1008
999
|
}
|
|
1009
1000
|
return null;
|
|
1010
1001
|
};
|
|
1011
1002
|
|
|
1012
|
-
const HeaderItemText =
|
|
1003
|
+
const HeaderItemText = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledHeaderItemText, _extends$3({
|
|
1013
1004
|
ref: ref
|
|
1014
1005
|
}, props)));
|
|
1015
1006
|
HeaderItemText.displayName = 'HeaderItemText';
|
|
1016
1007
|
HeaderItemText.propTypes = {
|
|
1017
|
-
isClipped: PropTypes__default
|
|
1008
|
+
isClipped: PropTypes__default.default.bool
|
|
1018
1009
|
};
|
|
1019
1010
|
|
|
1020
|
-
const HeaderItemWrapper =
|
|
1011
|
+
const HeaderItemWrapper = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledHeaderItemWrapper, _extends$3({
|
|
1021
1012
|
ref: ref
|
|
1022
1013
|
}, props)));
|
|
1023
1014
|
HeaderItemWrapper.displayName = 'HeaderItemWrapper';
|
|
1024
1015
|
|
|
1025
|
-
const Footer$1 =
|
|
1016
|
+
const Footer$1 = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledFooter, _extends$3({
|
|
1026
1017
|
ref: ref
|
|
1027
1018
|
}, props)));
|
|
1028
1019
|
Footer$1.displayName = 'Footer';
|
|
1029
1020
|
|
|
1030
|
-
const FooterItem$1 =
|
|
1021
|
+
const FooterItem$1 = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledFooterItem, _extends$3({
|
|
1031
1022
|
ref: ref
|
|
1032
1023
|
}, props)));
|
|
1033
1024
|
FooterItem$1.displayName = 'FooterItem';
|
|
1034
1025
|
|
|
1035
|
-
const NavContext =
|
|
1026
|
+
const NavContext = React__namespace.default.createContext({
|
|
1036
1027
|
isExpanded: false
|
|
1037
1028
|
});
|
|
1038
1029
|
const useNavContext = () => {
|
|
1039
1030
|
return React.useContext(NavContext);
|
|
1040
1031
|
};
|
|
1041
1032
|
|
|
1042
|
-
const Nav =
|
|
1033
|
+
const Nav = React__namespace.default.forwardRef((props, ref) => {
|
|
1043
1034
|
const {
|
|
1044
1035
|
hue,
|
|
1045
1036
|
isLight,
|
|
@@ -1048,9 +1039,9 @@ const Nav = React__default["default"].forwardRef((props, ref) => {
|
|
|
1048
1039
|
const navContextValue = React.useMemo(() => ({
|
|
1049
1040
|
isExpanded: !!props.isExpanded
|
|
1050
1041
|
}), [props.isExpanded]);
|
|
1051
|
-
return
|
|
1042
|
+
return React__namespace.default.createElement(NavContext.Provider, {
|
|
1052
1043
|
value: navContextValue
|
|
1053
|
-
},
|
|
1044
|
+
}, React__namespace.default.createElement(StyledNav, _extends$3({
|
|
1054
1045
|
ref: ref
|
|
1055
1046
|
}, props, {
|
|
1056
1047
|
hue: hue,
|
|
@@ -1060,10 +1051,10 @@ const Nav = React__default["default"].forwardRef((props, ref) => {
|
|
|
1060
1051
|
});
|
|
1061
1052
|
Nav.displayName = 'Nav';
|
|
1062
1053
|
Nav.propTypes = {
|
|
1063
|
-
isExpanded: PropTypes__default
|
|
1054
|
+
isExpanded: PropTypes__default.default.bool
|
|
1064
1055
|
};
|
|
1065
1056
|
|
|
1066
|
-
const NavItem =
|
|
1057
|
+
const NavItem = React__namespace.default.forwardRef((_ref, ref) => {
|
|
1067
1058
|
let {
|
|
1068
1059
|
hasLogo,
|
|
1069
1060
|
hasBrandmark,
|
|
@@ -1080,7 +1071,7 @@ const NavItem = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1080
1071
|
} = useNavContext();
|
|
1081
1072
|
const ariaCurrent = other.isCurrent || undefined;
|
|
1082
1073
|
if (hasLogo) {
|
|
1083
|
-
return
|
|
1074
|
+
return React__namespace.default.createElement(StyledLogoNavItem, _extends$3({
|
|
1084
1075
|
ref: ref,
|
|
1085
1076
|
isDark: isDark,
|
|
1086
1077
|
isLight: isLight,
|
|
@@ -1089,11 +1080,11 @@ const NavItem = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1089
1080
|
}, other));
|
|
1090
1081
|
}
|
|
1091
1082
|
if (hasBrandmark) {
|
|
1092
|
-
return
|
|
1083
|
+
return React__namespace.default.createElement(StyledBrandmarkNavItem, _extends$3({
|
|
1093
1084
|
ref: ref
|
|
1094
1085
|
}, other));
|
|
1095
1086
|
}
|
|
1096
|
-
return
|
|
1087
|
+
return React__namespace.default.createElement(StyledNavItem, _extends$3({
|
|
1097
1088
|
tabIndex: 0,
|
|
1098
1089
|
ref: ref,
|
|
1099
1090
|
isExpanded: isExpanded,
|
|
@@ -1105,9 +1096,9 @@ const NavItem = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1105
1096
|
});
|
|
1106
1097
|
NavItem.displayName = 'NavItem';
|
|
1107
1098
|
NavItem.propTypes = {
|
|
1108
|
-
product: PropTypes__default
|
|
1109
|
-
hasLogo: PropTypes__default
|
|
1110
|
-
hasBrandmark: PropTypes__default
|
|
1099
|
+
product: PropTypes__default.default.oneOf(PRODUCT),
|
|
1100
|
+
hasLogo: PropTypes__default.default.bool,
|
|
1101
|
+
hasBrandmark: PropTypes__default.default.bool
|
|
1111
1102
|
};
|
|
1112
1103
|
|
|
1113
1104
|
const NavItemIcon = _ref => {
|
|
@@ -1127,34 +1118,34 @@ const NavItemIcon = _ref => {
|
|
|
1127
1118
|
...iconProps
|
|
1128
1119
|
});
|
|
1129
1120
|
};
|
|
1130
|
-
return
|
|
1121
|
+
return React__namespace.default.createElement(StyledNavItemIcon, _extends$3({
|
|
1131
1122
|
as: Icon
|
|
1132
1123
|
}, props));
|
|
1133
1124
|
}
|
|
1134
1125
|
return null;
|
|
1135
1126
|
};
|
|
1136
1127
|
|
|
1137
|
-
const NavItemText =
|
|
1128
|
+
const NavItemText = React__namespace.default.forwardRef((props, ref) => {
|
|
1138
1129
|
const {
|
|
1139
1130
|
isExpanded
|
|
1140
1131
|
} = useNavContext();
|
|
1141
|
-
return
|
|
1132
|
+
return React__namespace.default.createElement(StyledNavItemText, _extends$3({
|
|
1142
1133
|
ref: ref,
|
|
1143
1134
|
isExpanded: isExpanded
|
|
1144
1135
|
}, props));
|
|
1145
1136
|
});
|
|
1146
1137
|
NavItemText.displayName = 'NavItemText';
|
|
1147
1138
|
NavItemText.propTypes = {
|
|
1148
|
-
isWrapped: PropTypes__default
|
|
1139
|
+
isWrapped: PropTypes__default.default.bool
|
|
1149
1140
|
};
|
|
1150
1141
|
|
|
1151
|
-
const SubNav =
|
|
1142
|
+
const SubNav = React__namespace.default.forwardRef((props, ref) => {
|
|
1152
1143
|
const {
|
|
1153
1144
|
hue,
|
|
1154
1145
|
isLight,
|
|
1155
1146
|
isDark
|
|
1156
1147
|
} = useChromeContext();
|
|
1157
|
-
return
|
|
1148
|
+
return React__namespace.default.createElement(StyledSubNav, _extends$3({
|
|
1158
1149
|
ref: ref,
|
|
1159
1150
|
hue: hue,
|
|
1160
1151
|
isLight: isLight,
|
|
@@ -1163,12 +1154,12 @@ const SubNav = React__default["default"].forwardRef((props, ref) => {
|
|
|
1163
1154
|
});
|
|
1164
1155
|
SubNav.displayName = 'SubNav';
|
|
1165
1156
|
|
|
1166
|
-
const SubNavItem =
|
|
1157
|
+
const SubNavItem = React__namespace.default.forwardRef((props, ref) => {
|
|
1167
1158
|
const {
|
|
1168
1159
|
isDark,
|
|
1169
1160
|
isLight
|
|
1170
1161
|
} = useChromeContext();
|
|
1171
|
-
return
|
|
1162
|
+
return React__namespace.default.createElement(StyledSubNavItem, _extends$3({
|
|
1172
1163
|
ref: ref,
|
|
1173
1164
|
isDark: isDark,
|
|
1174
1165
|
isLight: isLight
|
|
@@ -1176,18 +1167,18 @@ const SubNavItem = React__default["default"].forwardRef((props, ref) => {
|
|
|
1176
1167
|
});
|
|
1177
1168
|
SubNavItem.displayName = 'SubNavItem';
|
|
1178
1169
|
SubNavItem.propTypes = {
|
|
1179
|
-
isCurrent: PropTypes__default
|
|
1170
|
+
isCurrent: PropTypes__default.default.bool
|
|
1180
1171
|
};
|
|
1181
1172
|
|
|
1182
|
-
const SubNavItemText =
|
|
1173
|
+
const SubNavItemText = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledSubNavItemText, _extends$3({
|
|
1183
1174
|
ref: ref
|
|
1184
1175
|
}, props)));
|
|
1185
1176
|
SubNavItemText.displayName = 'SubNavItemText';
|
|
1186
1177
|
SubNavItemText.propTypes = {
|
|
1187
|
-
isWrapped: PropTypes__default
|
|
1178
|
+
isWrapped: PropTypes__default.default.bool
|
|
1188
1179
|
};
|
|
1189
1180
|
|
|
1190
|
-
const CollapsibleSubNavItem =
|
|
1181
|
+
const CollapsibleSubNavItem = React__namespace.default.forwardRef((_ref, ref) => {
|
|
1191
1182
|
let {
|
|
1192
1183
|
header,
|
|
1193
1184
|
children,
|
|
@@ -1219,29 +1210,29 @@ const CollapsibleSubNavItem = React__default["default"].forwardRef((_ref, ref) =
|
|
|
1219
1210
|
panelRef.current.style.maxHeight = `${panelRef.current.scrollHeight}px`;
|
|
1220
1211
|
}
|
|
1221
1212
|
}, [expanded, children]);
|
|
1222
|
-
return
|
|
1213
|
+
return React__namespace.default.createElement("div", {
|
|
1223
1214
|
ref: ref
|
|
1224
|
-
},
|
|
1215
|
+
}, React__namespace.default.createElement("div", getHeaderProps({
|
|
1225
1216
|
ariaLevel: 2
|
|
1226
|
-
}),
|
|
1217
|
+
}), React__namespace.default.createElement(StyledSubNavItemHeader, getTriggerProps({
|
|
1227
1218
|
isExpanded: expanded,
|
|
1228
1219
|
index: 0,
|
|
1229
1220
|
role: null,
|
|
1230
1221
|
tabIndex: null,
|
|
1231
1222
|
...other
|
|
1232
|
-
}),
|
|
1223
|
+
}), React__namespace.default.createElement(React__namespace.default.Fragment, null, header, React__namespace.default.createElement(StyledSubNavItemIconWrapper, {
|
|
1233
1224
|
isExpanded: expanded
|
|
1234
|
-
},
|
|
1225
|
+
}, React__namespace.default.createElement(StyledSubNavItemIcon, null))))), React__namespace.default.createElement(StyledSubNavPanel, getPanelProps({
|
|
1235
1226
|
index: 0,
|
|
1236
1227
|
isHidden: !expanded,
|
|
1237
1228
|
ref: panelRef
|
|
1238
1229
|
}), children));
|
|
1239
1230
|
});
|
|
1240
1231
|
CollapsibleSubNavItem.propTypes = {
|
|
1241
|
-
header: PropTypes__default
|
|
1242
|
-
isExpanded: PropTypes__default
|
|
1243
|
-
onChange: PropTypes__default
|
|
1244
|
-
children: PropTypes__default
|
|
1232
|
+
header: PropTypes__default.default.any,
|
|
1233
|
+
isExpanded: PropTypes__default.default.bool,
|
|
1234
|
+
onChange: PropTypes__default.default.func,
|
|
1235
|
+
children: PropTypes__default.default.node
|
|
1245
1236
|
};
|
|
1246
1237
|
CollapsibleSubNavItem.displayName = 'CollapsibleSubNavItem';
|
|
1247
1238
|
|
|
@@ -1298,7 +1289,7 @@ const SheetTitle = React.forwardRef((_ref, ref) => {
|
|
|
1298
1289
|
const {
|
|
1299
1290
|
titleId
|
|
1300
1291
|
} = useSheetContext();
|
|
1301
|
-
return
|
|
1292
|
+
return React__namespace.default.createElement(StyledSheetTitle, _extends$3({
|
|
1302
1293
|
id: id || titleId,
|
|
1303
1294
|
ref: ref
|
|
1304
1295
|
}, props));
|
|
@@ -1314,7 +1305,7 @@ const SheetDescription = React.forwardRef((_ref, ref) => {
|
|
|
1314
1305
|
const {
|
|
1315
1306
|
descriptionId
|
|
1316
1307
|
} = useSheetContext();
|
|
1317
|
-
return
|
|
1308
|
+
return React__namespace.default.createElement(StyledSheetDescription, _extends$3({
|
|
1318
1309
|
id: id || descriptionId,
|
|
1319
1310
|
ref: ref
|
|
1320
1311
|
}, props));
|
|
@@ -1326,7 +1317,7 @@ const SheetHeader = React.forwardRef((props, ref) => {
|
|
|
1326
1317
|
const {
|
|
1327
1318
|
isCloseButtonPresent
|
|
1328
1319
|
} = useSheetContext();
|
|
1329
|
-
return
|
|
1320
|
+
return React__namespace.default.createElement(StyledSheetHeader, _extends$3({
|
|
1330
1321
|
ref: ref,
|
|
1331
1322
|
isCloseButtonPresent: isCloseButtonPresent
|
|
1332
1323
|
}, props));
|
|
@@ -1335,7 +1326,7 @@ SheetHeader.displayName = 'Sheet.Header';
|
|
|
1335
1326
|
const Header = SheetHeader;
|
|
1336
1327
|
|
|
1337
1328
|
const SheetBody = React.forwardRef((props, ref) => {
|
|
1338
|
-
return
|
|
1329
|
+
return React__namespace.default.createElement(StyledSheetBody, _extends$3({
|
|
1339
1330
|
ref: ref
|
|
1340
1331
|
}, props));
|
|
1341
1332
|
});
|
|
@@ -1343,7 +1334,7 @@ SheetBody.displayName = 'Sheet.Body';
|
|
|
1343
1334
|
const Body = SheetBody;
|
|
1344
1335
|
|
|
1345
1336
|
const SheetFooter = React.forwardRef((props, ref) => {
|
|
1346
|
-
return
|
|
1337
|
+
return React__namespace.default.createElement(StyledSheetFooter, _extends$3({
|
|
1347
1338
|
ref: ref
|
|
1348
1339
|
}, props));
|
|
1349
1340
|
});
|
|
@@ -1351,7 +1342,7 @@ SheetFooter.displayName = 'Sheet.Footer';
|
|
|
1351
1342
|
const Footer = SheetFooter;
|
|
1352
1343
|
|
|
1353
1344
|
const SheetFooterItem = React.forwardRef((props, ref) => {
|
|
1354
|
-
return
|
|
1345
|
+
return React__namespace.default.createElement(StyledSheetFooterItem, _extends$3({
|
|
1355
1346
|
ref: ref
|
|
1356
1347
|
}, props));
|
|
1357
1348
|
});
|
|
@@ -1359,9 +1350,7 @@ SheetFooterItem.displayName = 'Sheet.FooterItem';
|
|
|
1359
1350
|
const FooterItem = SheetFooterItem;
|
|
1360
1351
|
|
|
1361
1352
|
var _path;
|
|
1362
|
-
|
|
1363
1353
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
1364
|
-
|
|
1365
1354
|
var SvgXStroke = function SvgXStroke(props) {
|
|
1366
1355
|
return /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
1367
1356
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -1369,8 +1358,7 @@ var SvgXStroke = function SvgXStroke(props) {
|
|
|
1369
1358
|
height: 16,
|
|
1370
1359
|
focusable: "false",
|
|
1371
1360
|
viewBox: "0 0 16 16",
|
|
1372
|
-
"aria-hidden": "true"
|
|
1373
|
-
role: "img"
|
|
1361
|
+
"aria-hidden": "true"
|
|
1374
1362
|
}, props), _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1375
1363
|
stroke: "currentColor",
|
|
1376
1364
|
strokeLinecap: "round",
|
|
@@ -1386,15 +1374,15 @@ const SheetClose = React.forwardRef((props, ref) => {
|
|
|
1386
1374
|
setIsCloseButtonPresent(true);
|
|
1387
1375
|
return () => setIsCloseButtonPresent(false);
|
|
1388
1376
|
}, [setIsCloseButtonPresent]);
|
|
1389
|
-
return
|
|
1377
|
+
return React__namespace.default.createElement(StyledSheetClose, _extends$3({
|
|
1390
1378
|
"aria-label": "Close Sheet",
|
|
1391
1379
|
ref: ref
|
|
1392
|
-
}, props),
|
|
1380
|
+
}, props), React__namespace.default.createElement(SvgXStroke, null));
|
|
1393
1381
|
});
|
|
1394
1382
|
SheetClose.displayName = 'Sheet.Close';
|
|
1395
1383
|
const Close = SheetClose;
|
|
1396
1384
|
|
|
1397
|
-
const SheetComponent =
|
|
1385
|
+
const SheetComponent = React__namespace.default.forwardRef((_ref, ref) => {
|
|
1398
1386
|
let {
|
|
1399
1387
|
id,
|
|
1400
1388
|
isOpen,
|
|
@@ -1409,7 +1397,7 @@ const SheetComponent = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1409
1397
|
const sheetRef = React.useRef(null);
|
|
1410
1398
|
const seed = reactUid.useUIDSeed();
|
|
1411
1399
|
const [isCloseButtonPresent, setIsCloseButtonPresent] = React.useState(false);
|
|
1412
|
-
const idPrefix = React.useMemo(() => id || seed(`sheet_${'8.
|
|
1400
|
+
const idPrefix = React.useMemo(() => id || seed(`sheet_${'8.63.0'}`), [id, seed]);
|
|
1413
1401
|
const titleId = `${idPrefix}--title`;
|
|
1414
1402
|
const descriptionId = `${idPrefix}--description`;
|
|
1415
1403
|
const sheetContext = React.useMemo(() => ({
|
|
@@ -1424,9 +1412,9 @@ const SheetComponent = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1424
1412
|
focusOnMount,
|
|
1425
1413
|
restoreFocus
|
|
1426
1414
|
});
|
|
1427
|
-
return
|
|
1415
|
+
return React__namespace.default.createElement(SheetContext.Provider, {
|
|
1428
1416
|
value: sheetContext
|
|
1429
|
-
},
|
|
1417
|
+
}, React__namespace.default.createElement(StyledSheet, _extends$3({
|
|
1430
1418
|
isOpen: isOpen,
|
|
1431
1419
|
isAnimated: isAnimated,
|
|
1432
1420
|
placement: placement,
|
|
@@ -1435,8 +1423,8 @@ const SheetComponent = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1435
1423
|
id: idPrefix,
|
|
1436
1424
|
"aria-labelledby": titleId,
|
|
1437
1425
|
"aria-describedby": descriptionId,
|
|
1438
|
-
ref: mergeRefs__default
|
|
1439
|
-
}, props),
|
|
1426
|
+
ref: mergeRefs__default.default([sheetRef, ref])
|
|
1427
|
+
}, props), React__namespace.default.createElement(StyledSheetWrapper, {
|
|
1440
1428
|
isOpen: isOpen,
|
|
1441
1429
|
isAnimated: isAnimated,
|
|
1442
1430
|
placement: placement,
|
|
@@ -1445,13 +1433,13 @@ const SheetComponent = React__default["default"].forwardRef((_ref, ref) => {
|
|
|
1445
1433
|
});
|
|
1446
1434
|
SheetComponent.displayName = 'Sheet';
|
|
1447
1435
|
SheetComponent.propTypes = {
|
|
1448
|
-
id: PropTypes__default
|
|
1449
|
-
isOpen: PropTypes__default
|
|
1450
|
-
isAnimated: PropTypes__default
|
|
1451
|
-
focusOnMount: PropTypes__default
|
|
1452
|
-
restoreFocus: PropTypes__default
|
|
1453
|
-
placement: PropTypes__default
|
|
1454
|
-
size: PropTypes__default
|
|
1436
|
+
id: PropTypes__default.default.string,
|
|
1437
|
+
isOpen: PropTypes__default.default.bool,
|
|
1438
|
+
isAnimated: PropTypes__default.default.bool,
|
|
1439
|
+
focusOnMount: PropTypes__default.default.bool,
|
|
1440
|
+
restoreFocus: PropTypes__default.default.bool,
|
|
1441
|
+
placement: PropTypes__default.default.oneOf(PLACEMENT),
|
|
1442
|
+
size: PropTypes__default.default.string
|
|
1455
1443
|
};
|
|
1456
1444
|
SheetComponent.defaultProps = {
|
|
1457
1445
|
isAnimated: true,
|