@pingux/astro 2.84.0-alpha.1 → 2.84.0-alpha.11
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/lib/cjs/components/Avatar/Avatar.js +43 -8
- package/lib/cjs/components/Avatar/Avatar.test.js +10 -1
- package/lib/cjs/components/CheckboxField/CheckboxField.stories.js +5 -3
- package/lib/cjs/components/CodeView/CodeView.js +5 -2
- package/lib/cjs/components/CodeView/CodeView.styles.d.ts +2 -1
- package/lib/cjs/components/CodeView/CodeView.styles.js +4 -3
- package/lib/cjs/components/Link/Link.js +3 -1
- package/lib/cjs/components/LinkSelectField/LinkSelectField.stories.js +3 -6
- package/lib/cjs/components/ListBox/ListBox.styles.js +6 -3
- package/lib/cjs/components/Menu/Menu.js +15 -3
- package/lib/cjs/components/Menu/Menu.test.js +23 -0
- package/lib/cjs/components/MenuItem/MenuItem.styles.d.ts +1 -0
- package/lib/cjs/components/MenuItem/MenuItem.styles.js +2 -1
- package/lib/cjs/components/MenuSection/MenuSection.d.ts +9 -0
- package/lib/cjs/components/MenuSection/MenuSection.js +76 -0
- package/lib/cjs/components/MenuSection/MenuSection.styles.d.ts +21 -0
- package/lib/cjs/components/MenuSection/MenuSection.styles.js +35 -0
- package/lib/cjs/components/MenuSection/MenuSection.test.d.ts +1 -0
- package/lib/cjs/components/MenuSection/MenuSection.test.js +100 -0
- package/lib/cjs/components/MenuSection/index.d.ts +1 -0
- package/lib/cjs/components/MenuSection/index.js +14 -0
- package/lib/cjs/components/PopoverMenu/PopoverMenu.stories.d.ts +2 -0
- package/lib/cjs/components/PopoverMenu/PopoverMenu.stories.js +73 -5
- package/lib/cjs/components/SelectField/SelectField.stories.js +3 -6
- package/lib/cjs/components/SwitchField/SwitchField.d.ts +4 -0
- package/lib/cjs/components/SwitchField/SwitchField.js +12 -32
- package/lib/cjs/components/SwitchField/SwitchField.stories.d.ts +11 -0
- package/lib/cjs/components/SwitchField/SwitchField.stories.js +4 -2
- package/lib/cjs/components/SwitchField/SwitchField.test.d.ts +1 -0
- package/lib/cjs/components/SwitchField/index.d.ts +1 -0
- package/lib/cjs/components/SwitchField/switchFieldAttributes.d.ts +94 -0
- package/lib/cjs/components/SwitchField/switchFieldAttributes.js +2 -30
- package/lib/cjs/components/Tabs/Tabs.js +0 -1
- package/lib/cjs/components/Tabs/Tabs.style.d.ts +1 -0
- package/lib/cjs/components/Tabs/Tabs.style.js +2 -1
- package/lib/cjs/components/TimeField/TimeField.stories.js +2 -2
- package/lib/cjs/styles/theme.js +5 -1
- package/lib/cjs/styles/themes/next-gen/codeView/codeView.d.ts +105 -0
- package/lib/cjs/styles/themes/next-gen/codeView/codeView.js +134 -0
- package/lib/cjs/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/cjs/styles/themes/next-gen/next-gen.d.ts +344 -36
- package/lib/cjs/styles/themes/next-gen/next-gen.js +24 -4
- package/lib/cjs/styles/themes/next-gen/sizes.d.ts +18 -0
- package/lib/cjs/styles/themes/next-gen/sizes.js +27 -0
- package/lib/cjs/styles/themes/next-gen/spacing.d.ts +9 -0
- package/lib/cjs/styles/themes/next-gen/spacing.js +17 -0
- package/lib/cjs/styles/themes/next-gen/text.d.ts +8 -2
- package/lib/cjs/styles/themes/next-gen/text.js +16 -13
- package/lib/cjs/styles/themes/next-gen/variants/button.d.ts +36 -3
- package/lib/cjs/styles/themes/next-gen/variants/button.js +25 -5
- package/lib/cjs/styles/themes/next-gen/variants/cards.d.ts +20 -0
- package/lib/cjs/styles/themes/next-gen/variants/cards.js +28 -0
- package/lib/cjs/styles/themes/next-gen/variants/images.d.ts +4 -0
- package/lib/cjs/styles/themes/next-gen/variants/images.js +12 -0
- package/lib/cjs/styles/themes/next-gen/variants/links.d.ts +56 -0
- package/lib/cjs/styles/themes/next-gen/variants/links.js +62 -0
- package/lib/cjs/styles/themes/next-gen/variants/text.d.ts +7 -0
- package/lib/cjs/styles/themes/next-gen/variants/text.js +9 -2
- package/lib/cjs/styles/themes/next-gen/variants/variants.d.ts +82 -31
- package/lib/cjs/styles/themes/next-gen/variants/variants.js +91 -30
- package/lib/cjs/styles/variants/variants.js +2 -0
- package/lib/cjs/types/avatar.d.ts +5 -1
- package/lib/cjs/types/checkboxField.d.ts +3 -1
- package/lib/cjs/types/codeView.d.ts +1 -0
- package/lib/cjs/types/index.d.ts +2 -0
- package/lib/cjs/types/index.js +43 -21
- package/lib/cjs/types/link.d.ts +1 -0
- package/lib/cjs/types/menuSection.d.ts +24 -0
- package/lib/cjs/types/menuSection.js +6 -0
- package/lib/cjs/types/switchField.d.ts +29 -0
- package/lib/cjs/types/switchField.js +6 -0
- package/lib/components/Avatar/Avatar.js +44 -7
- package/lib/components/Avatar/Avatar.test.js +10 -1
- package/lib/components/CheckboxField/CheckboxField.stories.js +5 -3
- package/lib/components/CodeView/CodeView.js +5 -2
- package/lib/components/CodeView/CodeView.styles.js +4 -3
- package/lib/components/Link/Link.js +3 -1
- package/lib/components/LinkSelectField/LinkSelectField.stories.js +4 -7
- package/lib/components/ListBox/ListBox.styles.js +6 -3
- package/lib/components/Menu/Menu.js +15 -3
- package/lib/components/Menu/Menu.test.js +24 -1
- package/lib/components/MenuItem/MenuItem.styles.js +2 -1
- package/lib/components/MenuSection/MenuSection.js +64 -0
- package/lib/components/MenuSection/MenuSection.styles.js +27 -0
- package/lib/components/MenuSection/MenuSection.test.js +97 -0
- package/lib/components/MenuSection/index.js +1 -0
- package/lib/components/PopoverMenu/PopoverMenu.stories.js +70 -4
- package/lib/components/SelectField/SelectField.stories.js +4 -7
- package/lib/components/SwitchField/SwitchField.js +14 -34
- package/lib/components/SwitchField/SwitchField.stories.js +4 -2
- package/lib/components/SwitchField/switchFieldAttributes.js +1 -28
- package/lib/components/Tabs/Tabs.js +0 -1
- package/lib/components/Tabs/Tabs.style.js +2 -1
- package/lib/components/TimeField/TimeField.stories.js +2 -2
- package/lib/styles/theme.js +5 -1
- package/lib/styles/themes/next-gen/codeView/codeView.js +126 -0
- package/lib/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/styles/themes/next-gen/next-gen.js +24 -4
- package/lib/styles/themes/next-gen/sizes.js +19 -0
- package/lib/styles/themes/next-gen/spacing.js +9 -0
- package/lib/styles/themes/next-gen/text.js +16 -13
- package/lib/styles/themes/next-gen/variants/button.js +25 -5
- package/lib/styles/themes/next-gen/variants/cards.js +20 -0
- package/lib/styles/themes/next-gen/variants/images.js +4 -0
- package/lib/styles/themes/next-gen/variants/links.js +54 -0
- package/lib/styles/themes/next-gen/variants/text.js +9 -2
- package/lib/styles/themes/next-gen/variants/variants.js +91 -30
- package/lib/styles/variants/variants.js +2 -0
- package/lib/types/index.js +2 -0
- package/lib/types/menuSection.js +1 -0
- package/lib/types/switchField.js +1 -0
- package/package.json +1 -1
- package/lib/cjs/recipes/NextGen/DefaultAvatar.stories.d.ts +0 -6
- package/lib/cjs/recipes/NextGen/DefaultAvatar.stories.js +0 -41
- package/lib/recipes/NextGen/DefaultAvatar.stories.js +0 -31
@@ -419,6 +419,9 @@ declare const _default: {
|
|
419
419
|
color: string;
|
420
420
|
bg: string;
|
421
421
|
pl: number;
|
422
|
+
'&.is-focused': {
|
423
|
+
color: string;
|
424
|
+
};
|
422
425
|
};
|
423
426
|
};
|
424
427
|
};
|
@@ -446,44 +449,60 @@ declare const _default: {
|
|
446
449
|
bg: string;
|
447
450
|
};
|
448
451
|
};
|
452
|
+
separator: {
|
453
|
+
my: string;
|
454
|
+
};
|
449
455
|
};
|
450
456
|
avatar: {
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
fontSize: string;
|
457
|
+
backgroundColor: string;
|
458
|
+
color: string;
|
459
|
+
cursor: string;
|
460
|
+
'&.is-orange': {
|
461
|
+
backgroundColor: string;
|
462
|
+
color: string;
|
458
463
|
};
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
textAlign: string;
|
463
|
-
justifyContent: string;
|
464
|
-
fontFamily: string;
|
465
|
-
size: string;
|
464
|
+
'&.is-green': {
|
465
|
+
backgroundColor: string;
|
466
|
+
color: string;
|
466
467
|
};
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
textAlign: string;
|
471
|
-
justifyContent: string;
|
472
|
-
fontFamily: string;
|
473
|
-
size: string;
|
468
|
+
'&.is-purple': {
|
469
|
+
backgroundColor: string;
|
470
|
+
color: string;
|
474
471
|
};
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
textAlign: string;
|
479
|
-
justifyContent: string;
|
480
|
-
fontFamily: string;
|
481
|
-
size: string;
|
472
|
+
'&.is-pink': {
|
473
|
+
backgroundColor: string;
|
474
|
+
color: string;
|
482
475
|
};
|
476
|
+
'&.is-red': {
|
477
|
+
backgroundColor: string;
|
478
|
+
color: string;
|
479
|
+
};
|
480
|
+
'&.is-yellow': {
|
481
|
+
backgroundColor: string;
|
482
|
+
color: string;
|
483
|
+
};
|
484
|
+
'&.is-cyan': {
|
485
|
+
backgroundColor: string;
|
486
|
+
color: string;
|
487
|
+
};
|
488
|
+
'&.is-teal': {
|
489
|
+
backgroundColor: string;
|
490
|
+
color: string;
|
491
|
+
};
|
492
|
+
display: string;
|
493
|
+
borderRadius: string;
|
494
|
+
textAlign: string;
|
495
|
+
alignItems: string;
|
496
|
+
justifyContent: string;
|
497
|
+
fontFamily: string;
|
483
498
|
};
|
484
499
|
listViewItem: {
|
500
|
+
rightOfData: {
|
501
|
+
flexShrink: number;
|
502
|
+
whiteSpace: string;
|
503
|
+
};
|
485
504
|
iconContainer: {
|
486
|
-
|
505
|
+
ml: string;
|
487
506
|
};
|
488
507
|
styledListItem: {
|
489
508
|
bg: string;
|
@@ -544,8 +563,17 @@ declare const _default: {
|
|
544
563
|
borderRadius: string;
|
545
564
|
border: string;
|
546
565
|
borderColor: string;
|
547
|
-
'& > div': {
|
548
|
-
|
566
|
+
'& > div > div': {
|
567
|
+
'& > div:first-of-type': {
|
568
|
+
'& > div > div': {
|
569
|
+
borderRadius: string;
|
570
|
+
};
|
571
|
+
};
|
572
|
+
'& > div:last-of-type': {
|
573
|
+
'& > div > div': {
|
574
|
+
borderRadius: string;
|
575
|
+
};
|
576
|
+
};
|
549
577
|
};
|
550
578
|
};
|
551
579
|
};
|
@@ -576,5 +604,28 @@ declare const _default: {
|
|
576
604
|
fontSize: string;
|
577
605
|
};
|
578
606
|
};
|
607
|
+
codeView: {
|
608
|
+
wrapper: {
|
609
|
+
backgroundColor: string;
|
610
|
+
borderRadius: string;
|
611
|
+
'> button >svg': {
|
612
|
+
color: string;
|
613
|
+
path: {
|
614
|
+
fill: string;
|
615
|
+
};
|
616
|
+
};
|
617
|
+
'> pre': {
|
618
|
+
p: string;
|
619
|
+
};
|
620
|
+
};
|
621
|
+
};
|
622
|
+
tabs: {
|
623
|
+
gap: string;
|
624
|
+
};
|
625
|
+
menu: {
|
626
|
+
p: string;
|
627
|
+
border: string;
|
628
|
+
borderColor: string;
|
629
|
+
};
|
579
630
|
};
|
580
631
|
export default _default;
|
@@ -213,7 +213,10 @@ var listBox = {
|
|
213
213
|
'&.is-selected': {
|
214
214
|
color: 'text.primary',
|
215
215
|
bg: 'lightblue',
|
216
|
-
pl: 0
|
216
|
+
pl: 0,
|
217
|
+
'&.is-focused': {
|
218
|
+
color: 'text.primary'
|
219
|
+
}
|
217
220
|
}
|
218
221
|
}
|
219
222
|
};
|
@@ -235,40 +238,59 @@ var menuItem = {
|
|
235
238
|
color: 'text.primary',
|
236
239
|
bg: 'lightblue'
|
237
240
|
}
|
241
|
+
},
|
242
|
+
separator: {
|
243
|
+
my: 'sm'
|
238
244
|
}
|
239
245
|
};
|
240
246
|
var separator = {
|
241
247
|
base: {
|
242
|
-
bg: 'gray-
|
248
|
+
bg: 'gray-300'
|
243
249
|
}
|
244
250
|
};
|
245
|
-
var
|
251
|
+
var avatar = {
|
252
|
+
backgroundColor: 'lightcyan',
|
253
|
+
color: 'darkcyan',
|
254
|
+
cursor: 'pointer',
|
255
|
+
'&.is-orange': {
|
256
|
+
backgroundColor: 'lightorange',
|
257
|
+
color: 'darkorange'
|
258
|
+
},
|
259
|
+
'&.is-green': {
|
260
|
+
backgroundColor: 'lightgreen',
|
261
|
+
color: 'darkgreen'
|
262
|
+
},
|
263
|
+
'&.is-purple': {
|
264
|
+
backgroundColor: 'lightpurple',
|
265
|
+
color: 'darkpurple'
|
266
|
+
},
|
267
|
+
'&.is-pink': {
|
268
|
+
backgroundColor: 'lightpink',
|
269
|
+
color: 'darkpink'
|
270
|
+
},
|
271
|
+
'&.is-red': {
|
272
|
+
backgroundColor: 'lightred',
|
273
|
+
color: 'darkred'
|
274
|
+
},
|
275
|
+
'&.is-yellow': {
|
276
|
+
backgroundColor: 'lightyellow',
|
277
|
+
color: 'darkyellow'
|
278
|
+
},
|
279
|
+
'&.is-cyan': {
|
280
|
+
backgroundColor: 'lightcyan',
|
281
|
+
color: 'darkcyan'
|
282
|
+
},
|
283
|
+
'&.is-teal': {
|
284
|
+
backgroundColor: 'lightteal',
|
285
|
+
color: 'darkteal'
|
286
|
+
},
|
287
|
+
display: 'flex',
|
246
288
|
borderRadius: '50%',
|
247
289
|
textAlign: 'center',
|
290
|
+
alignItems: 'center',
|
248
291
|
justifyContent: 'center',
|
249
292
|
fontFamily: 'standard'
|
250
293
|
};
|
251
|
-
var avatar = {
|
252
|
-
xl: _objectSpread({
|
253
|
-
size: '104px',
|
254
|
-
fontSize: 'calc(104px * .4)'
|
255
|
-
}, avatarBase),
|
256
|
-
lg: _objectSpread(_objectSpread({
|
257
|
-
size: '72px'
|
258
|
-
}, avatarBase), {}, {
|
259
|
-
fontSize: 'calc(72px * .4)'
|
260
|
-
}),
|
261
|
-
md: _objectSpread(_objectSpread({
|
262
|
-
size: '34px'
|
263
|
-
}, avatarBase), {}, {
|
264
|
-
fontSize: 'calc(34px * .4)'
|
265
|
-
}),
|
266
|
-
sm: _objectSpread(_objectSpread({
|
267
|
-
size: '24px'
|
268
|
-
}, avatarBase), {}, {
|
269
|
-
fontSize: 'calc(24px * .4)'
|
270
|
-
})
|
271
|
-
};
|
272
294
|
var progressBarContainer = {
|
273
295
|
backgroundColor: 'gray-200',
|
274
296
|
borderRadius: '.5rem',
|
@@ -282,8 +304,12 @@ var progressBar = {
|
|
282
304
|
})
|
283
305
|
};
|
284
306
|
var listViewItem = {
|
307
|
+
rightOfData: {
|
308
|
+
flexShrink: 4,
|
309
|
+
whiteSpace: 'nowrap'
|
310
|
+
},
|
285
311
|
iconContainer: {
|
286
|
-
|
312
|
+
ml: '0px'
|
287
313
|
},
|
288
314
|
styledListItem: {
|
289
315
|
bg: 'white',
|
@@ -304,8 +330,8 @@ var listViewItem = {
|
|
304
330
|
}
|
305
331
|
},
|
306
332
|
styledContainer: {
|
307
|
-
py: '
|
308
|
-
px: '
|
333
|
+
py: 'md',
|
334
|
+
px: 'lg',
|
309
335
|
bg: 'transparent',
|
310
336
|
'&.is-hovered': {
|
311
337
|
bg: 'transparent',
|
@@ -427,8 +453,17 @@ var listView = {
|
|
427
453
|
borderRadius: '16px',
|
428
454
|
border: '1px solid',
|
429
455
|
borderColor: '#e7eef4',
|
430
|
-
'& > div': {
|
431
|
-
|
456
|
+
'& > div > div': {
|
457
|
+
'& > div:first-of-type': {
|
458
|
+
'& > div > div': {
|
459
|
+
borderRadius: '16px 16px 0 0'
|
460
|
+
}
|
461
|
+
},
|
462
|
+
'& > div:last-of-type': {
|
463
|
+
'& > div > div': {
|
464
|
+
borderRadius: ' 0 0 16px 16px'
|
465
|
+
}
|
466
|
+
}
|
432
467
|
}
|
433
468
|
}
|
434
469
|
};
|
@@ -459,6 +494,29 @@ var dataTable = {
|
|
459
494
|
fontSize: 'md'
|
460
495
|
}
|
461
496
|
};
|
497
|
+
var codeView = {
|
498
|
+
wrapper: {
|
499
|
+
backgroundColor: 'gray-900',
|
500
|
+
borderRadius: '4px',
|
501
|
+
'> button >svg': {
|
502
|
+
color: 'gray-300',
|
503
|
+
path: {
|
504
|
+
fill: 'gray-300'
|
505
|
+
}
|
506
|
+
},
|
507
|
+
'> pre': {
|
508
|
+
p: 'md'
|
509
|
+
}
|
510
|
+
}
|
511
|
+
};
|
512
|
+
var tabs = {
|
513
|
+
gap: '0px'
|
514
|
+
};
|
515
|
+
var menu = {
|
516
|
+
p: 'sm',
|
517
|
+
border: '1px solid',
|
518
|
+
borderColor: 'gray-300'
|
519
|
+
};
|
462
520
|
var _default = {
|
463
521
|
navBar: navBar,
|
464
522
|
fieldHelperText: fieldHelperText,
|
@@ -473,6 +531,9 @@ var _default = {
|
|
473
531
|
listViewItem: listViewItem,
|
474
532
|
progressBar: progressBar,
|
475
533
|
listView: listView,
|
476
|
-
dataTable: dataTable
|
534
|
+
dataTable: dataTable,
|
535
|
+
codeView: codeView,
|
536
|
+
tabs: tabs,
|
537
|
+
menu: menu
|
477
538
|
};
|
478
539
|
exports["default"] = _default;
|
@@ -41,6 +41,7 @@ var _ListViewItem = _interopRequireDefault(require("../../components/ListViewIte
|
|
41
41
|
var _Loader = _interopRequireDefault(require("../../components/Loader/Loader.styles"));
|
42
42
|
var _Menu = _interopRequireDefault(require("../../components/Menu/Menu.styles"));
|
43
43
|
var _MenuItem = _interopRequireDefault(require("../../components/MenuItem/MenuItem.styles"));
|
44
|
+
var _MenuSection = _interopRequireDefault(require("../../components/MenuSection/MenuSection.styles"));
|
44
45
|
var _Message = _interopRequireDefault(require("../../components/Messages/Message.styles"));
|
45
46
|
var _Modal = _interopRequireDefault(require("../../components/Modal/Modal.styles"));
|
46
47
|
var _NavBar = _interopRequireDefault(require("../../components/NavBar/NavBar.styles"));
|
@@ -90,6 +91,7 @@ var _default = _objectSpread({
|
|
90
91
|
loader: _Loader["default"],
|
91
92
|
menu: _Menu["default"],
|
92
93
|
menuItem: _MenuItem["default"],
|
94
|
+
menuSection: _MenuSection["default"],
|
93
95
|
message: _Message["default"],
|
94
96
|
modal: _Modal["default"],
|
95
97
|
navBar: _NavBar["default"],
|
@@ -1,9 +1,13 @@
|
|
1
1
|
import { AvatarProps as ThemeUIAvatarProps, ThemeUICSSObject } from 'theme-ui';
|
2
2
|
export interface AvatarProps extends ThemeUIAvatarProps {
|
3
3
|
/** Source of avatar. */
|
4
|
-
src
|
4
|
+
src?: string;
|
5
5
|
/** Alternative text for avatar. */
|
6
6
|
alt?: string;
|
7
7
|
/** Inline styling prop */
|
8
8
|
sx?: ThemeUICSSObject;
|
9
|
+
/** If no image src is supplied, this text will render inside of a styled div */
|
10
|
+
defaultText?: string;
|
11
|
+
size?: string;
|
12
|
+
color?: string;
|
9
13
|
}
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { UseFieldProps } from '../hooks/useField/useField';
|
2
|
-
export interface CheckboxFieldProps extends UseFieldProps<HTMLInputElement> {
|
2
|
+
export interface CheckboxFieldProps extends Omit<UseFieldProps<HTMLInputElement>, 'onChange'> {
|
3
3
|
/** Handler that is called when a key is pressed. */
|
4
4
|
onKeyDown?: () => void;
|
5
5
|
/** Handler that is called when a key is released. */
|
6
6
|
onKeyUp?: () => void;
|
7
|
+
/** Handler that is called when the element's selection state changes. */
|
8
|
+
onChange?: (isSelected: boolean) => void;
|
7
9
|
}
|
package/lib/cjs/types/index.d.ts
CHANGED
@@ -30,6 +30,7 @@ export * from './listItem';
|
|
30
30
|
export * from './loader';
|
31
31
|
export * from './menu';
|
32
32
|
export * from './menuItem';
|
33
|
+
export * from './menuSection';
|
33
34
|
export * from './messages';
|
34
35
|
export * from './Modal';
|
35
36
|
export * from './navBar';
|
@@ -43,6 +44,7 @@ export * from './rockerButtonGroup';
|
|
43
44
|
export * from './scrollBox';
|
44
45
|
export * from './separator';
|
45
46
|
export * from './shared';
|
47
|
+
export * from './switchField';
|
46
48
|
export * from './tab';
|
47
49
|
export * from './table';
|
48
50
|
export * from './tabs';
|
package/lib/cjs/types/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
-
var _context, _context2, _context3, _context4, _context5, _context6, _context7, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _context15, _context16, _context17, _context18, _context19, _context20, _context21, _context22, _context23, _context24, _context25, _context26, _context27, _context28, _context29, _context30, _context31, _context32, _context33, _context34, _context35, _context36, _context37, _context38, _context39, _context40, _context41, _context42, _context43, _context44, _context45, _context46, _context47, _context48, _context49, _context50, _context51, _context52;
|
3
|
+
var _context, _context2, _context3, _context4, _context5, _context6, _context7, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _context15, _context16, _context17, _context18, _context19, _context20, _context21, _context22, _context23, _context24, _context25, _context26, _context27, _context28, _context29, _context30, _context31, _context32, _context33, _context34, _context35, _context36, _context37, _context38, _context39, _context40, _context41, _context42, _context43, _context44, _context45, _context46, _context47, _context48, _context49, _context50, _context51, _context52, _context53, _context54;
|
4
4
|
var _Object$defineProperty = require("@babel/runtime-corejs3/core-js-stable/object/define-property");
|
5
5
|
var _forEachInstanceProperty = require("@babel/runtime-corejs3/core-js-stable/instance/for-each");
|
6
6
|
var _Object$keys = require("@babel/runtime-corejs3/core-js-stable/object/keys");
|
@@ -359,8 +359,19 @@ _forEachInstanceProperty(_context32 = _Object$keys(_menuItem)).call(_context32,
|
|
359
359
|
}
|
360
360
|
});
|
361
361
|
});
|
362
|
+
var _menuSection = require("./menuSection");
|
363
|
+
_forEachInstanceProperty(_context33 = _Object$keys(_menuSection)).call(_context33, function (key) {
|
364
|
+
if (key === "default" || key === "__esModule") return;
|
365
|
+
if (key in exports && exports[key] === _menuSection[key]) return;
|
366
|
+
_Object$defineProperty(exports, key, {
|
367
|
+
enumerable: true,
|
368
|
+
get: function get() {
|
369
|
+
return _menuSection[key];
|
370
|
+
}
|
371
|
+
});
|
372
|
+
});
|
362
373
|
var _messages = require("./messages");
|
363
|
-
_forEachInstanceProperty(
|
374
|
+
_forEachInstanceProperty(_context34 = _Object$keys(_messages)).call(_context34, function (key) {
|
364
375
|
if (key === "default" || key === "__esModule") return;
|
365
376
|
if (key in exports && exports[key] === _messages[key]) return;
|
366
377
|
_Object$defineProperty(exports, key, {
|
@@ -371,7 +382,7 @@ _forEachInstanceProperty(_context33 = _Object$keys(_messages)).call(_context33,
|
|
371
382
|
});
|
372
383
|
});
|
373
384
|
var _Modal = require("./Modal");
|
374
|
-
_forEachInstanceProperty(
|
385
|
+
_forEachInstanceProperty(_context35 = _Object$keys(_Modal)).call(_context35, function (key) {
|
375
386
|
if (key === "default" || key === "__esModule") return;
|
376
387
|
if (key in exports && exports[key] === _Modal[key]) return;
|
377
388
|
_Object$defineProperty(exports, key, {
|
@@ -382,7 +393,7 @@ _forEachInstanceProperty(_context34 = _Object$keys(_Modal)).call(_context34, fun
|
|
382
393
|
});
|
383
394
|
});
|
384
395
|
var _navBar = require("./navBar");
|
385
|
-
_forEachInstanceProperty(
|
396
|
+
_forEachInstanceProperty(_context36 = _Object$keys(_navBar)).call(_context36, function (key) {
|
386
397
|
if (key === "default" || key === "__esModule") return;
|
387
398
|
if (key in exports && exports[key] === _navBar[key]) return;
|
388
399
|
_Object$defineProperty(exports, key, {
|
@@ -393,7 +404,7 @@ _forEachInstanceProperty(_context35 = _Object$keys(_navBar)).call(_context35, fu
|
|
393
404
|
});
|
394
405
|
});
|
395
406
|
var _navSideBar = require("./navSideBar");
|
396
|
-
_forEachInstanceProperty(
|
407
|
+
_forEachInstanceProperty(_context37 = _Object$keys(_navSideBar)).call(_context37, function (key) {
|
397
408
|
if (key === "default" || key === "__esModule") return;
|
398
409
|
if (key in exports && exports[key] === _navSideBar[key]) return;
|
399
410
|
_Object$defineProperty(exports, key, {
|
@@ -404,7 +415,7 @@ _forEachInstanceProperty(_context36 = _Object$keys(_navSideBar)).call(_context36
|
|
404
415
|
});
|
405
416
|
});
|
406
417
|
var _overlayPanel = require("./overlayPanel");
|
407
|
-
_forEachInstanceProperty(
|
418
|
+
_forEachInstanceProperty(_context38 = _Object$keys(_overlayPanel)).call(_context38, function (key) {
|
408
419
|
if (key === "default" || key === "__esModule") return;
|
409
420
|
if (key in exports && exports[key] === _overlayPanel[key]) return;
|
410
421
|
_Object$defineProperty(exports, key, {
|
@@ -415,7 +426,7 @@ _forEachInstanceProperty(_context37 = _Object$keys(_overlayPanel)).call(_context
|
|
415
426
|
});
|
416
427
|
});
|
417
428
|
var _popoverContainer = require("./popoverContainer");
|
418
|
-
_forEachInstanceProperty(
|
429
|
+
_forEachInstanceProperty(_context39 = _Object$keys(_popoverContainer)).call(_context39, function (key) {
|
419
430
|
if (key === "default" || key === "__esModule") return;
|
420
431
|
if (key in exports && exports[key] === _popoverContainer[key]) return;
|
421
432
|
_Object$defineProperty(exports, key, {
|
@@ -426,7 +437,7 @@ _forEachInstanceProperty(_context38 = _Object$keys(_popoverContainer)).call(_con
|
|
426
437
|
});
|
427
438
|
});
|
428
439
|
var _popoverMenu = require("./popoverMenu");
|
429
|
-
_forEachInstanceProperty(
|
440
|
+
_forEachInstanceProperty(_context40 = _Object$keys(_popoverMenu)).call(_context40, function (key) {
|
430
441
|
if (key === "default" || key === "__esModule") return;
|
431
442
|
if (key in exports && exports[key] === _popoverMenu[key]) return;
|
432
443
|
_Object$defineProperty(exports, key, {
|
@@ -437,7 +448,7 @@ _forEachInstanceProperty(_context39 = _Object$keys(_popoverMenu)).call(_context3
|
|
437
448
|
});
|
438
449
|
});
|
439
450
|
var _progressBar = require("./progressBar");
|
440
|
-
_forEachInstanceProperty(
|
451
|
+
_forEachInstanceProperty(_context41 = _Object$keys(_progressBar)).call(_context41, function (key) {
|
441
452
|
if (key === "default" || key === "__esModule") return;
|
442
453
|
if (key in exports && exports[key] === _progressBar[key]) return;
|
443
454
|
_Object$defineProperty(exports, key, {
|
@@ -448,7 +459,7 @@ _forEachInstanceProperty(_context40 = _Object$keys(_progressBar)).call(_context4
|
|
448
459
|
});
|
449
460
|
});
|
450
461
|
var _requirementsList = require("./requirementsList");
|
451
|
-
_forEachInstanceProperty(
|
462
|
+
_forEachInstanceProperty(_context42 = _Object$keys(_requirementsList)).call(_context42, function (key) {
|
452
463
|
if (key === "default" || key === "__esModule") return;
|
453
464
|
if (key in exports && exports[key] === _requirementsList[key]) return;
|
454
465
|
_Object$defineProperty(exports, key, {
|
@@ -459,7 +470,7 @@ _forEachInstanceProperty(_context41 = _Object$keys(_requirementsList)).call(_con
|
|
459
470
|
});
|
460
471
|
});
|
461
472
|
var _rockerButtonGroup = require("./rockerButtonGroup");
|
462
|
-
_forEachInstanceProperty(
|
473
|
+
_forEachInstanceProperty(_context43 = _Object$keys(_rockerButtonGroup)).call(_context43, function (key) {
|
463
474
|
if (key === "default" || key === "__esModule") return;
|
464
475
|
if (key in exports && exports[key] === _rockerButtonGroup[key]) return;
|
465
476
|
_Object$defineProperty(exports, key, {
|
@@ -470,7 +481,7 @@ _forEachInstanceProperty(_context42 = _Object$keys(_rockerButtonGroup)).call(_co
|
|
470
481
|
});
|
471
482
|
});
|
472
483
|
var _scrollBox = require("./scrollBox");
|
473
|
-
_forEachInstanceProperty(
|
484
|
+
_forEachInstanceProperty(_context44 = _Object$keys(_scrollBox)).call(_context44, function (key) {
|
474
485
|
if (key === "default" || key === "__esModule") return;
|
475
486
|
if (key in exports && exports[key] === _scrollBox[key]) return;
|
476
487
|
_Object$defineProperty(exports, key, {
|
@@ -481,7 +492,7 @@ _forEachInstanceProperty(_context43 = _Object$keys(_scrollBox)).call(_context43,
|
|
481
492
|
});
|
482
493
|
});
|
483
494
|
var _separator = require("./separator");
|
484
|
-
_forEachInstanceProperty(
|
495
|
+
_forEachInstanceProperty(_context45 = _Object$keys(_separator)).call(_context45, function (key) {
|
485
496
|
if (key === "default" || key === "__esModule") return;
|
486
497
|
if (key in exports && exports[key] === _separator[key]) return;
|
487
498
|
_Object$defineProperty(exports, key, {
|
@@ -492,7 +503,7 @@ _forEachInstanceProperty(_context44 = _Object$keys(_separator)).call(_context44,
|
|
492
503
|
});
|
493
504
|
});
|
494
505
|
var _shared = require("./shared");
|
495
|
-
_forEachInstanceProperty(
|
506
|
+
_forEachInstanceProperty(_context46 = _Object$keys(_shared)).call(_context46, function (key) {
|
496
507
|
if (key === "default" || key === "__esModule") return;
|
497
508
|
if (key in exports && exports[key] === _shared[key]) return;
|
498
509
|
_Object$defineProperty(exports, key, {
|
@@ -502,8 +513,19 @@ _forEachInstanceProperty(_context45 = _Object$keys(_shared)).call(_context45, fu
|
|
502
513
|
}
|
503
514
|
});
|
504
515
|
});
|
516
|
+
var _switchField = require("./switchField");
|
517
|
+
_forEachInstanceProperty(_context47 = _Object$keys(_switchField)).call(_context47, function (key) {
|
518
|
+
if (key === "default" || key === "__esModule") return;
|
519
|
+
if (key in exports && exports[key] === _switchField[key]) return;
|
520
|
+
_Object$defineProperty(exports, key, {
|
521
|
+
enumerable: true,
|
522
|
+
get: function get() {
|
523
|
+
return _switchField[key];
|
524
|
+
}
|
525
|
+
});
|
526
|
+
});
|
505
527
|
var _tab = require("./tab");
|
506
|
-
_forEachInstanceProperty(
|
528
|
+
_forEachInstanceProperty(_context48 = _Object$keys(_tab)).call(_context48, function (key) {
|
507
529
|
if (key === "default" || key === "__esModule") return;
|
508
530
|
if (key in exports && exports[key] === _tab[key]) return;
|
509
531
|
_Object$defineProperty(exports, key, {
|
@@ -514,7 +536,7 @@ _forEachInstanceProperty(_context46 = _Object$keys(_tab)).call(_context46, funct
|
|
514
536
|
});
|
515
537
|
});
|
516
538
|
var _table = require("./table");
|
517
|
-
_forEachInstanceProperty(
|
539
|
+
_forEachInstanceProperty(_context49 = _Object$keys(_table)).call(_context49, function (key) {
|
518
540
|
if (key === "default" || key === "__esModule") return;
|
519
541
|
if (key in exports && exports[key] === _table[key]) return;
|
520
542
|
_Object$defineProperty(exports, key, {
|
@@ -525,7 +547,7 @@ _forEachInstanceProperty(_context47 = _Object$keys(_table)).call(_context47, fun
|
|
525
547
|
});
|
526
548
|
});
|
527
549
|
var _tabs = require("./tabs");
|
528
|
-
_forEachInstanceProperty(
|
550
|
+
_forEachInstanceProperty(_context50 = _Object$keys(_tabs)).call(_context50, function (key) {
|
529
551
|
if (key === "default" || key === "__esModule") return;
|
530
552
|
if (key in exports && exports[key] === _tabs[key]) return;
|
531
553
|
_Object$defineProperty(exports, key, {
|
@@ -536,7 +558,7 @@ _forEachInstanceProperty(_context48 = _Object$keys(_tabs)).call(_context48, func
|
|
536
558
|
});
|
537
559
|
});
|
538
560
|
var _text = require("./text");
|
539
|
-
_forEachInstanceProperty(
|
561
|
+
_forEachInstanceProperty(_context51 = _Object$keys(_text)).call(_context51, function (key) {
|
540
562
|
if (key === "default" || key === "__esModule") return;
|
541
563
|
if (key in exports && exports[key] === _text[key]) return;
|
542
564
|
_Object$defineProperty(exports, key, {
|
@@ -547,7 +569,7 @@ _forEachInstanceProperty(_context49 = _Object$keys(_text)).call(_context49, func
|
|
547
569
|
});
|
548
570
|
});
|
549
571
|
var _textField = require("./textField");
|
550
|
-
_forEachInstanceProperty(
|
572
|
+
_forEachInstanceProperty(_context52 = _Object$keys(_textField)).call(_context52, function (key) {
|
551
573
|
if (key === "default" || key === "__esModule") return;
|
552
574
|
if (key in exports && exports[key] === _textField[key]) return;
|
553
575
|
_Object$defineProperty(exports, key, {
|
@@ -558,7 +580,7 @@ _forEachInstanceProperty(_context50 = _Object$keys(_textField)).call(_context50,
|
|
558
580
|
});
|
559
581
|
});
|
560
582
|
var _timefield = require("./timefield");
|
561
|
-
_forEachInstanceProperty(
|
583
|
+
_forEachInstanceProperty(_context53 = _Object$keys(_timefield)).call(_context53, function (key) {
|
562
584
|
if (key === "default" || key === "__esModule") return;
|
563
585
|
if (key in exports && exports[key] === _timefield[key]) return;
|
564
586
|
_Object$defineProperty(exports, key, {
|
@@ -569,7 +591,7 @@ _forEachInstanceProperty(_context51 = _Object$keys(_timefield)).call(_context51,
|
|
569
591
|
});
|
570
592
|
});
|
571
593
|
var _tooltipTrigger = require("./tooltipTrigger");
|
572
|
-
_forEachInstanceProperty(
|
594
|
+
_forEachInstanceProperty(_context54 = _Object$keys(_tooltipTrigger)).call(_context54, function (key) {
|
573
595
|
if (key === "default" || key === "__esModule") return;
|
574
596
|
if (key in exports && exports[key] === _tooltipTrigger[key]) return;
|
575
597
|
_Object$defineProperty(exports, key, {
|
package/lib/cjs/types/link.d.ts
CHANGED
@@ -0,0 +1,24 @@
|
|
1
|
+
import { Node, TreeState } from 'react-stately';
|
2
|
+
import { TestingAttributes } from './shared/test';
|
3
|
+
import { BoxProps } from './box';
|
4
|
+
export interface MenuSectionProps extends BoxProps, TestingAttributes {
|
5
|
+
/** Whether the menu item is currently pressed. */
|
6
|
+
isPressed?: boolean;
|
7
|
+
/**
|
8
|
+
* Whether the containing menu has keyboard focus.
|
9
|
+
* Used to determine when to present hover vs focus styling.
|
10
|
+
*/
|
11
|
+
isFocusVisible?: boolean;
|
12
|
+
/**
|
13
|
+
* Whether menu item should receive focus state on hover.
|
14
|
+
*/
|
15
|
+
isNotFocusedOnHover?: boolean;
|
16
|
+
/** A screen reader only label for the menu item. */
|
17
|
+
/** Handler that is called when the menu should close after selecting an item. */
|
18
|
+
onClose?: () => void;
|
19
|
+
/** Handler that is called when the user activates the item. */
|
20
|
+
onAction?: () => void;
|
21
|
+
section: Node<object>;
|
22
|
+
state: TreeState<object>;
|
23
|
+
defaultSelectedKey?: string | number;
|
24
|
+
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { ControlProps } from '../hooks/useField/useField';
|
3
|
+
import { Status } from './item';
|
4
|
+
import { LabelProps } from './label';
|
5
|
+
import { DOMAttributes } from './shared';
|
6
|
+
export interface SwitchFieldProps extends DOMAttributes {
|
7
|
+
className?: string;
|
8
|
+
label?: React.ReactNode;
|
9
|
+
helperText?: string;
|
10
|
+
isDefaultSelected?: boolean;
|
11
|
+
isDisabled?: boolean;
|
12
|
+
status?: Status;
|
13
|
+
controlProps?: ControlProps;
|
14
|
+
isSelected?: boolean;
|
15
|
+
onChange?: () => void;
|
16
|
+
value?: string;
|
17
|
+
isRequired?: boolean;
|
18
|
+
hintText?: string;
|
19
|
+
labelProps?: LabelProps;
|
20
|
+
hasAutoFocus?: boolean;
|
21
|
+
id?: string;
|
22
|
+
isReadOnly?: boolean;
|
23
|
+
name?: string;
|
24
|
+
onBlur?: () => void;
|
25
|
+
onFocus?: () => void;
|
26
|
+
onFocusChange?: () => void;
|
27
|
+
onKeyDown?: () => void;
|
28
|
+
onKeyUp?: () => void;
|
29
|
+
}
|