@rocket.chat/fuselage 0.33.0 → 0.35.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/CHANGELOG.md +35 -0
- package/dist/Theme.d.ts +11 -12
- package/dist/Theme.d.ts.map +1 -1
- package/dist/components/Button/ActionButton.d.ts +2 -2
- package/dist/components/Button/Button.d.ts +2 -2
- package/dist/components/Button/IconButton.d.ts +1 -1
- package/dist/components/Callout/Callout.d.ts +1 -1
- package/dist/components/Callout/Callout.d.ts.map +1 -1
- package/dist/components/CheckBox/CheckBox.d.ts +1 -1
- package/dist/components/Contextualbar/ContextualbarButton.d.ts +2 -2
- package/dist/components/Contextualbar/ContextualbarContent.d.ts +1 -1
- package/dist/components/Contextualbar/ContextualbarEmptyContent.d.ts +1 -1
- package/dist/components/Contextualbar/ContextualbarFooter.d.ts +1 -1
- package/dist/components/Contextualbar/ContextualbarIcon.d.ts +2 -2
- package/dist/components/EmailInput/EmailInput.d.ts +1 -1
- package/dist/components/Field/index.d.ts +6 -6
- package/dist/components/Icon/Icon.d.ts +1 -1
- package/dist/components/InputBox/Addon.d.ts +1 -1
- package/dist/components/InputBox/Input.d.ts +1 -1
- package/dist/components/InputBox/Option.d.ts +1 -1
- package/dist/components/InputBox/Placeholder.d.ts +1 -1
- package/dist/components/InputBox/index.d.ts +6 -6
- package/dist/components/Menu/V2/MenuOption.d.ts +2 -2
- package/dist/components/Message/MessageMetrics/MessageMetricsItem/index.d.ts +2 -2
- package/dist/components/Message/MessageMetrics/index.d.ts +4 -4
- package/dist/components/Message/MessageToolbox/MessageToolboxItem.d.ts +3 -3
- package/dist/components/Message/MessageToolbox/index.d.ts +6 -6
- package/dist/components/Message/index.d.ts +10 -10
- package/dist/components/Modal/Modal.d.ts +1 -1
- package/dist/components/Modal/index.d.ts +1 -1
- package/dist/components/MultiSelect/MultiSelect.d.ts +2 -2
- package/dist/components/NumberInput/NumberInput.d.ts +1 -1
- package/dist/components/Option/CheckOption.d.ts +3 -3
- package/dist/components/Option/Option.d.ts +3 -3
- package/dist/components/Option/index.d.ts +7 -7
- package/dist/components/Options/Options.d.ts +2 -2
- package/dist/components/Options/index.d.ts +1 -1
- package/dist/components/OptionsPaginated/OptionsPaginated.d.ts +4 -4
- package/dist/components/PaginatedSelect/PaginatedMultiSelect.d.ts +3 -1
- package/dist/components/PaginatedSelect/PaginatedMultiSelect.d.ts.map +1 -1
- package/dist/components/PaginatedSelect/PaginatedSelectWrapper.d.ts +1 -1
- package/dist/components/PasswordInput/PasswordInput.d.ts +1 -1
- package/dist/components/ProgressBar/ProgressBar.d.ts +1 -1
- package/dist/components/RadioButton/RadioButton.d.ts +1 -1
- package/dist/components/SearchInput/SearchInput.d.ts +1 -1
- package/dist/components/Select/SelectAddon.d.ts +1 -1
- package/dist/components/Select/SelectFiltered.d.ts +4 -4
- package/dist/components/Select/SelectFocus.d.ts +1 -1
- package/dist/components/Select/SelectLegacy.d.ts +2 -2
- package/dist/components/SelectInput/SelectInput.d.ts +1 -1
- package/dist/components/SelectInput/index.d.ts +1 -1
- package/dist/components/Sidebar/Item.d.ts +3 -3
- package/dist/components/Sidebar/SidebarActions.d.ts +3 -3
- package/dist/components/Sidebar/SidebarBanner.d.ts +2 -1
- package/dist/components/Sidebar/SidebarBanner.d.ts.map +1 -1
- package/dist/components/Sidebar/TopBar.d.ts +8 -8
- package/dist/components/Sidebar/index.d.ts +11 -10
- package/dist/components/Sidebar/index.d.ts.map +1 -1
- package/dist/components/Tabs/Tabs.d.ts +1 -1
- package/dist/components/Tabs/TabsItem.d.ts +1 -1
- package/dist/components/Tag/Tag.d.ts +2 -2
- package/dist/components/Tag/Tag.d.ts.map +1 -1
- package/dist/components/TelephoneInput/TelephoneInput.d.ts +1 -1
- package/dist/components/TextAreaInput/TextArea.d.ts +1 -1
- package/dist/components/TextInput/TextInput.d.ts +1 -1
- package/dist/components/Throbber/Throbber.d.ts +1 -1
- package/dist/components/Tile/Tile.d.ts +1 -1
- package/dist/components/ToggleSwitch/ToggleSwitch.d.ts +1 -1
- package/dist/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/UrlInput/UrlInput.d.ts +1 -1
- package/dist/fuselage.css +4 -4
- package/dist/fuselage.css.map +1 -1
- package/dist/fuselage.development.js +170 -204
- package/dist/fuselage.development.js.map +1 -1
- package/dist/fuselage.production.js +1 -1
- package/dist/getPaletteColor.d.ts +7 -6
- package/dist/getPaletteColor.d.ts.map +1 -1
- package/dist/styleTokens.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -401,169 +401,154 @@ var __setThrowErrorOnInvalidToken__ = function (value) {
|
|
|
401
401
|
};
|
|
402
402
|
exports.__setThrowErrorOnInvalidToken__ = __setThrowErrorOnInvalidToken__;
|
|
403
403
|
exports.neutral = {
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
600: new Var('service-1-600', colors_json_1.default['s1-600']),
|
|
482
|
-
700: new Var('service-1-700', colors_json_1.default['s1-700']),
|
|
483
|
-
800: new Var('service-1-800', colors_json_1.default['s1-800']),
|
|
484
|
-
900: new Var('service-1-900', colors_json_1.default['s1-900']),
|
|
485
|
-
};
|
|
486
|
-
var service2 = {
|
|
487
|
-
100: new Var('service-2-100', colors_json_1.default['s2-100']),
|
|
488
|
-
200: new Var('service-2-200', colors_json_1.default['s2-200']),
|
|
489
|
-
300: new Var('service-2-300', colors_json_1.default['s2-300']),
|
|
490
|
-
400: new Var('service-2-400', colors_json_1.default['s2-400']),
|
|
491
|
-
500: new Var('service-2-500', colors_json_1.default['s2-500']),
|
|
492
|
-
600: new Var('service-2-600', colors_json_1.default['s2-600']),
|
|
493
|
-
700: new Var('service-2-700', colors_json_1.default['s2-700']),
|
|
494
|
-
800: new Var('service-2-800', colors_json_1.default['s2-800']),
|
|
495
|
-
900: new Var('service-2-900', colors_json_1.default['s2-900']),
|
|
404
|
+
100: new Var('neutral-100', colors_json_1.default.n100),
|
|
405
|
+
200: new Var('neutral-200', colors_json_1.default.n200),
|
|
406
|
+
250: new Var('neutral-250', colors_json_1.default.n250),
|
|
407
|
+
300: new Var('neutral-300', colors_json_1.default.n300),
|
|
408
|
+
400: new Var('neutral-400', colors_json_1.default.n400),
|
|
409
|
+
450: new Var('neutral-450', colors_json_1.default.n450),
|
|
410
|
+
500: new Var('neutral-500', colors_json_1.default.n500),
|
|
411
|
+
600: new Var('neutral-600', colors_json_1.default.n600),
|
|
412
|
+
700: new Var('neutral-700', colors_json_1.default.n700),
|
|
413
|
+
800: new Var('neutral-800', colors_json_1.default.n800),
|
|
414
|
+
900: new Var('neutral-900', colors_json_1.default.n900),
|
|
415
|
+
};
|
|
416
|
+
var blue = {
|
|
417
|
+
100: new Var('primary-100', colors_json_1.default.b100),
|
|
418
|
+
200: new Var('primary-200', colors_json_1.default.b200),
|
|
419
|
+
300: new Var('primary-300', colors_json_1.default.b300),
|
|
420
|
+
400: new Var('primary-400', colors_json_1.default.b400),
|
|
421
|
+
500: new Var('primary-500', colors_json_1.default.b500),
|
|
422
|
+
600: new Var('primary-600', colors_json_1.default.b600),
|
|
423
|
+
700: new Var('primary-700', colors_json_1.default.b700),
|
|
424
|
+
800: new Var('primary-800', colors_json_1.default.b800),
|
|
425
|
+
900: new Var('primary-900', colors_json_1.default.b900),
|
|
426
|
+
};
|
|
427
|
+
var green = {
|
|
428
|
+
100: new Var('success-100', colors_json_1.default.g100),
|
|
429
|
+
200: new Var('success-200', colors_json_1.default.g200),
|
|
430
|
+
300: new Var('success-300', colors_json_1.default.g300),
|
|
431
|
+
400: new Var('success-400', colors_json_1.default.g400),
|
|
432
|
+
500: new Var('success-500', colors_json_1.default.g500),
|
|
433
|
+
600: new Var('success-600', colors_json_1.default.g600),
|
|
434
|
+
700: new Var('success-700', colors_json_1.default.g700),
|
|
435
|
+
800: new Var('success-800', colors_json_1.default.g800),
|
|
436
|
+
900: new Var('success-900', colors_json_1.default.g900),
|
|
437
|
+
};
|
|
438
|
+
var yellow = {
|
|
439
|
+
100: new Var('warning-100', colors_json_1.default.y100),
|
|
440
|
+
200: new Var('warning-200', colors_json_1.default.y200),
|
|
441
|
+
300: new Var('warning-300', colors_json_1.default.y300),
|
|
442
|
+
400: new Var('warning-400', colors_json_1.default.y400),
|
|
443
|
+
500: new Var('warning-500', colors_json_1.default.y500),
|
|
444
|
+
600: new Var('warning-600', colors_json_1.default.y600),
|
|
445
|
+
700: new Var('warning-700', colors_json_1.default.y700),
|
|
446
|
+
800: new Var('warning-800', colors_json_1.default.y800),
|
|
447
|
+
900: new Var('warning-900', colors_json_1.default.y900),
|
|
448
|
+
};
|
|
449
|
+
var red = {
|
|
450
|
+
100: new Var('danger-100', colors_json_1.default.r100),
|
|
451
|
+
200: new Var('danger-200', colors_json_1.default.r200),
|
|
452
|
+
300: new Var('danger-300', colors_json_1.default.r300),
|
|
453
|
+
400: new Var('danger-400', colors_json_1.default.r400),
|
|
454
|
+
500: new Var('danger-500', colors_json_1.default.r500),
|
|
455
|
+
600: new Var('danger-600', colors_json_1.default.r600),
|
|
456
|
+
700: new Var('danger-700', colors_json_1.default.r700),
|
|
457
|
+
800: new Var('danger-800', colors_json_1.default.r800),
|
|
458
|
+
900: new Var('danger-900', colors_json_1.default.r900),
|
|
459
|
+
};
|
|
460
|
+
var orange = {
|
|
461
|
+
100: new Var('service-1-100', colors_json_1.default.o100),
|
|
462
|
+
200: new Var('service-1-200', colors_json_1.default.o200),
|
|
463
|
+
300: new Var('service-1-300', colors_json_1.default.o300),
|
|
464
|
+
400: new Var('service-1-400', colors_json_1.default.o400),
|
|
465
|
+
500: new Var('service-1-500', colors_json_1.default.o500),
|
|
466
|
+
600: new Var('service-1-600', colors_json_1.default.o600),
|
|
467
|
+
700: new Var('service-1-700', colors_json_1.default.o700),
|
|
468
|
+
800: new Var('service-1-800', colors_json_1.default.o800),
|
|
469
|
+
900: new Var('service-1-900', colors_json_1.default.o900),
|
|
470
|
+
};
|
|
471
|
+
var purple = {
|
|
472
|
+
100: new Var('service-2-100', colors_json_1.default.p100),
|
|
473
|
+
200: new Var('service-2-200', colors_json_1.default.p200),
|
|
474
|
+
300: new Var('service-2-300', colors_json_1.default.p300),
|
|
475
|
+
400: new Var('service-2-400', colors_json_1.default.p400),
|
|
476
|
+
500: new Var('service-2-500', colors_json_1.default.p500),
|
|
477
|
+
600: new Var('service-2-600', colors_json_1.default.p600),
|
|
478
|
+
700: new Var('service-2-700', colors_json_1.default.p700),
|
|
479
|
+
800: new Var('service-2-800', colors_json_1.default.p800),
|
|
480
|
+
900: new Var('service-2-900', colors_json_1.default.p900),
|
|
496
481
|
};
|
|
497
482
|
exports.surfaceColors = {
|
|
498
483
|
'surface-light': white.theme('surface-light'),
|
|
499
|
-
'surface-tint': exports.neutral.
|
|
484
|
+
'surface-tint': exports.neutral[100].theme('surface-tint'),
|
|
500
485
|
'surface-room': white.theme('surface-room'),
|
|
501
|
-
'surface-neutral': exports.neutral.
|
|
502
|
-
'surface-disabled': exports.neutral.
|
|
503
|
-
'surface-hover': exports.neutral.
|
|
504
|
-
'surface-selected': exports.neutral.
|
|
505
|
-
'surface-dark': exports.neutral.
|
|
506
|
-
'surface-featured':
|
|
507
|
-
'surface-featured-hover':
|
|
508
|
-
'surface-overlay': exports.neutral.
|
|
486
|
+
'surface-neutral': exports.neutral[400].theme('surface-neutral'),
|
|
487
|
+
'surface-disabled': exports.neutral[100].theme('surface-disabled'),
|
|
488
|
+
'surface-hover': exports.neutral[200].theme('surface-hover'),
|
|
489
|
+
'surface-selected': exports.neutral[450].theme('surface-selected'),
|
|
490
|
+
'surface-dark': exports.neutral[800].theme('surface-dark'),
|
|
491
|
+
'surface-featured': purple['700'].theme('surface-featured'),
|
|
492
|
+
'surface-featured-hover': purple['800'].theme('surface-featured-hover'),
|
|
493
|
+
'surface-overlay': exports.neutral[800].theme('surface-overlay'),
|
|
509
494
|
'surface-transparent': 'transparent',
|
|
510
495
|
};
|
|
511
496
|
exports.strokeColors = {
|
|
512
|
-
'stroke-extra-light': exports.neutral.
|
|
513
|
-
'stroke-light': exports.neutral.
|
|
514
|
-
'stroke-medium': exports.neutral.
|
|
515
|
-
'stroke-dark': exports.neutral.
|
|
516
|
-
'stroke-extra-dark': exports.neutral.
|
|
517
|
-
'stroke-extra-light-highlight':
|
|
518
|
-
'stroke-highlight':
|
|
519
|
-
'stroke-extra-light-error':
|
|
520
|
-
'stroke-error':
|
|
497
|
+
'stroke-extra-light': exports.neutral[250].theme('stroke-extra-light'),
|
|
498
|
+
'stroke-light': exports.neutral[500].theme('stroke-light'),
|
|
499
|
+
'stroke-medium': exports.neutral[600].theme('stroke-medium'),
|
|
500
|
+
'stroke-dark': exports.neutral[700].theme('stroke-dark'),
|
|
501
|
+
'stroke-extra-dark': exports.neutral[800].theme('stroke-extra-dark'),
|
|
502
|
+
'stroke-extra-light-highlight': blue[200].theme('stroke-extra-light-highlight'),
|
|
503
|
+
'stroke-highlight': blue[500].theme('stroke-highlight'),
|
|
504
|
+
'stroke-extra-light-error': red[200].theme('stroke-extra-light-error'),
|
|
505
|
+
'stroke-error': red[500].theme('stroke-error'),
|
|
521
506
|
};
|
|
522
507
|
exports.textIconColors = {
|
|
523
508
|
'font-white': white.theme('font-white'),
|
|
524
|
-
'font-disabled': exports.neutral.
|
|
525
|
-
'font-annotation': exports.neutral.
|
|
526
|
-
'font-hint': exports.neutral.
|
|
527
|
-
'font-secondary-info': exports.neutral.
|
|
528
|
-
'font-default': exports.neutral.
|
|
529
|
-
'font-titles-labels': exports.neutral.
|
|
530
|
-
'font-info':
|
|
531
|
-
'font-danger':
|
|
532
|
-
'font-pure-black': exports.neutral.
|
|
509
|
+
'font-disabled': exports.neutral[500].theme('font-disabled'),
|
|
510
|
+
'font-annotation': exports.neutral[600].theme('font-annotation'),
|
|
511
|
+
'font-hint': exports.neutral[700].theme('font-hint'),
|
|
512
|
+
'font-secondary-info': exports.neutral[700].theme('font-secondary-info'),
|
|
513
|
+
'font-default': exports.neutral[800].theme('font-default'),
|
|
514
|
+
'font-titles-labels': exports.neutral[900].theme('font-titles-labels'),
|
|
515
|
+
'font-info': blue[600].theme('font-info'),
|
|
516
|
+
'font-danger': red[600].theme('font-danger'),
|
|
517
|
+
'font-pure-black': exports.neutral[800].theme('font-pure-black'),
|
|
533
518
|
'font-pure-white': white.theme('font-pure-white'),
|
|
534
519
|
};
|
|
535
520
|
exports.statusBackgroundColors = {
|
|
536
|
-
'status-background-info':
|
|
537
|
-
'status-background-success':
|
|
538
|
-
'status-background-danger':
|
|
539
|
-
'status-background-warning':
|
|
540
|
-
'status-background-warning-2':
|
|
541
|
-
'status-background-service-1':
|
|
542
|
-
'status-background-service-2':
|
|
521
|
+
'status-background-info': blue[200].theme('status-background-info'),
|
|
522
|
+
'status-background-success': green[200].theme('status-background-success'),
|
|
523
|
+
'status-background-danger': red[200].theme('status-background-danger'),
|
|
524
|
+
'status-background-warning': yellow[200].theme('status-background-warning'),
|
|
525
|
+
'status-background-warning-2': yellow[100].theme('status-background-warning-2'),
|
|
526
|
+
'status-background-service-1': orange[200].theme('status-background-service-1'),
|
|
527
|
+
'status-background-service-2': purple[200].theme('status-background-service-2'),
|
|
543
528
|
};
|
|
544
529
|
exports.statusColors = {
|
|
545
|
-
'status-font-on-info':
|
|
546
|
-
'status-font-on-success':
|
|
547
|
-
'status-font-on-warning':
|
|
548
|
-
'status-font-on-warning-2': exports.neutral.
|
|
549
|
-
'status-font-on-danger':
|
|
550
|
-
'status-font-on-service-1':
|
|
551
|
-
'status-font-on-service-2':
|
|
530
|
+
'status-font-on-info': blue[600].theme('status-font-on-info'),
|
|
531
|
+
'status-font-on-success': green[800].theme('status-font-on-success'),
|
|
532
|
+
'status-font-on-warning': yellow[800].theme('status-font-on-warning'),
|
|
533
|
+
'status-font-on-warning-2': exports.neutral[800].theme('status-font-on-warning-2'),
|
|
534
|
+
'status-font-on-danger': red[800].theme('status-font-on-danger'),
|
|
535
|
+
'status-font-on-service-1': orange[800].theme('status-font-on-service-1'),
|
|
536
|
+
'status-font-on-service-2': purple[600].theme('status-font-on-service-2'),
|
|
552
537
|
};
|
|
553
538
|
exports.badgeBackgroundColors = {
|
|
554
|
-
'badge-background-level-0': exports.neutral.
|
|
555
|
-
'badge-background-level-1': exports.neutral.
|
|
556
|
-
'badge-background-level-2':
|
|
557
|
-
'badge-background-level-3':
|
|
558
|
-
'badge-background-level-4':
|
|
539
|
+
'badge-background-level-0': exports.neutral[400].theme('badge-background-level-0'),
|
|
540
|
+
'badge-background-level-1': exports.neutral[600].theme('badge-background-level-1'),
|
|
541
|
+
'badge-background-level-2': blue[500].theme('badge-background-level-2'),
|
|
542
|
+
'badge-background-level-3': orange[500].theme('badge-background-level-3'),
|
|
543
|
+
'badge-background-level-4': red[500].theme('badge-background-level-4'),
|
|
559
544
|
};
|
|
560
545
|
exports.shadowColors = {
|
|
561
546
|
'shadow-elevation-border': exports.strokeColors['stroke-extra-light'].theme('shadow-elevation-border'),
|
|
562
547
|
'shadow-elevation-1': new Var('shadow-elevation-1', (0, getPaletteColor_1.getPaletteColor)('neutral', 800, 0.1)[1]),
|
|
563
548
|
'shadow-elevation-2x': new Var('shadow-elevation-2x', (0, getPaletteColor_1.getPaletteColor)('neutral', 800, 0.08)[1]),
|
|
564
549
|
'shadow-elevation-2y': new Var('shadow-elevation-2y', (0, getPaletteColor_1.getPaletteColor)('neutral', 800, 0.12)[1]),
|
|
565
|
-
'shadow-highlight':
|
|
566
|
-
'shadow-danger':
|
|
550
|
+
'shadow-highlight': blue[200].theme('shadow-highlight'),
|
|
551
|
+
'shadow-danger': red[100].theme('shadow-danger'),
|
|
567
552
|
};
|
|
568
553
|
var isSurfaceColor = function (color) {
|
|
569
554
|
return typeof color === 'string' && color in exports.surfaceColors;
|
|
@@ -2669,17 +2654,21 @@ var react_1 = __importDefault(__webpack_require__(/*! react */ "react"));
|
|
|
2669
2654
|
var Box_1 = __importDefault(__webpack_require__(/*! ../Box */ "./src/components/Box/index.tsx"));
|
|
2670
2655
|
var Icon_1 = __webpack_require__(/*! ../Icon */ "./src/components/Icon/index.ts");
|
|
2671
2656
|
var Callout = function (_a) {
|
|
2672
|
-
var type = _a.type, title = _a.title, children = _a.children, icon = _a.icon, props = __rest(_a, ["type", "title", "children", "icon"]);
|
|
2657
|
+
var type = _a.type, title = _a.title, children = _a.children, icon = _a.icon, className = _a.className, props = __rest(_a, ["type", "title", "children", "icon", "className"]);
|
|
2673
2658
|
var defaultIcon = (type === 'info' && 'info-circled') ||
|
|
2674
2659
|
(type === 'success' && 'checkmark-circled') ||
|
|
2675
2660
|
(type === 'warning' && 'warning') ||
|
|
2676
2661
|
(type === 'danger' && 'ban') ||
|
|
2677
2662
|
'info-circled';
|
|
2678
|
-
return (react_1.default.createElement(Box_1.default, __assign({ is: 'section',
|
|
2679
|
-
|
|
2663
|
+
return (react_1.default.createElement(Box_1.default, __assign({ is: 'section', className: [
|
|
2664
|
+
"rcx-callout ".concat(type && "rcx-callout--".concat(type), " ").concat(className || ''),
|
|
2665
|
+
]
|
|
2666
|
+
.filter(Boolean)
|
|
2667
|
+
.join(' ') }, props),
|
|
2668
|
+
react_1.default.createElement(Icon_1.Icon, { className: 'rcx-callout__icon', name: icon || defaultIcon, size: 'x20' }),
|
|
2680
2669
|
react_1.default.createElement(Box_1.default, { "rcx-callout__wrapper": true },
|
|
2681
|
-
title &&
|
|
2682
|
-
children && react_1.default.createElement(Box_1.default, { "rcx-
|
|
2670
|
+
title && react_1.default.createElement(Box_1.default, { "rcx-callout__title": true }, title),
|
|
2671
|
+
children && react_1.default.createElement(Box_1.default, { "rcx-callout__content": true }, children))));
|
|
2683
2672
|
};
|
|
2684
2673
|
exports.Callout = Callout;
|
|
2685
2674
|
|
|
@@ -3189,7 +3178,7 @@ var react_1 = __importStar(__webpack_require__(/*! react */ "react"));
|
|
|
3189
3178
|
var __1 = __webpack_require__(/*! .. */ "./src/components/index.ts");
|
|
3190
3179
|
var ContextualbarAction = function (_a) {
|
|
3191
3180
|
var name = _a.name, props = __rest(_a, ["name"]);
|
|
3192
|
-
return (react_1.default.createElement(__1.IconButton, __assign({ flexShrink: 0, icon: name }
|
|
3181
|
+
return (react_1.default.createElement(__1.IconButton, __assign({}, props, { small: true, flexShrink: 0, icon: name })));
|
|
3193
3182
|
};
|
|
3194
3183
|
exports["default"] = (0, react_1.memo)(ContextualbarAction);
|
|
3195
3184
|
|
|
@@ -11170,21 +11159,22 @@ var Chip_1 = __importDefault(__webpack_require__(/*! ../Chip */ "./src/component
|
|
|
11170
11159
|
var Flex_1 = __importDefault(__webpack_require__(/*! ../Flex */ "./src/components/Flex/index.ts"));
|
|
11171
11160
|
var Icon_1 = __webpack_require__(/*! ../Icon */ "./src/components/Icon/index.ts");
|
|
11172
11161
|
var Margins_1 = __importDefault(__webpack_require__(/*! ../Margins */ "./src/components/Margins/index.ts"));
|
|
11162
|
+
var Option_1 = __importDefault(__webpack_require__(/*! ../Option */ "./src/components/Option/index.tsx"));
|
|
11173
11163
|
var useVisible_1 = __webpack_require__(/*! ../Options/useVisible */ "./src/components/Options/useVisible.ts");
|
|
11174
11164
|
var OptionsPaginated_1 = __webpack_require__(/*! ../OptionsPaginated */ "./src/components/OptionsPaginated/index.ts");
|
|
11175
11165
|
var Position_1 = __importDefault(__webpack_require__(/*! ../Position */ "./src/components/Position/index.ts"));
|
|
11176
11166
|
var SelectAddon_1 = __importDefault(__webpack_require__(/*! ../Select/SelectAddon */ "./src/components/Select/SelectAddon.tsx"));
|
|
11177
11167
|
var SelectFocus_1 = __importDefault(__webpack_require__(/*! ../Select/SelectFocus */ "./src/components/Select/SelectFocus.tsx"));
|
|
11178
11168
|
var PaginatedMultiSelect = function (_a) {
|
|
11179
|
-
var withTitle = _a.withTitle, value = _a.value, filter = _a.filter, _b = _a.options, options = _b === void 0 ? [] : _b, error = _a.error, disabled = _a.disabled, _c = _a.anchor, Anchor = _c === void 0 ? SelectFocus_1.default : _c, _d = _a.onChange, onChange = _d === void 0 ? function () { } : _d, placeholder = _a.placeholder, _e = _a.renderOptions, OptionsComponent = _e === void 0 ? OptionsPaginated_1.OptionsPaginated : _e, endReached = _a.endReached, props = __rest(_a, ["withTitle", "value", "filter", "options", "error", "disabled", "anchor", "onChange", "placeholder", "renderOptions", "endReached"]);
|
|
11180
|
-
var
|
|
11169
|
+
var withTitle = _a.withTitle, value = _a.value, filter = _a.filter, _b = _a.options, options = _b === void 0 ? [] : _b, error = _a.error, disabled = _a.disabled, _c = _a.anchor, Anchor = _c === void 0 ? SelectFocus_1.default : _c, _d = _a.onChange, onChange = _d === void 0 ? function () { } : _d, placeholder = _a.placeholder, _e = _a.renderOptions, OptionsComponent = _e === void 0 ? OptionsPaginated_1.OptionsPaginated : _e, _f = _a.renderItem, renderItem = _f === void 0 ? Option_1.default : _f, endReached = _a.endReached, props = __rest(_a, ["withTitle", "value", "filter", "options", "error", "disabled", "anchor", "onChange", "placeholder", "renderOptions", "renderItem", "endReached"]);
|
|
11170
|
+
var _g = __read((0, react_1.useState)(value || []), 2), internalValue = _g[0], setInternalValue = _g[1];
|
|
11181
11171
|
var currentValue = value !== undefined ? value : internalValue;
|
|
11182
11172
|
var selectedOptions = options.filter(function (option) {
|
|
11183
11173
|
return currentValue.some(function (opt) { return opt.value === option.value; });
|
|
11184
11174
|
});
|
|
11185
|
-
var
|
|
11175
|
+
var _h = __read((0, useVisible_1.useVisible)(), 3), visible = _h[0], hide = _h[1], show = _h[2];
|
|
11186
11176
|
var ref = (0, react_1.useRef)(null);
|
|
11187
|
-
var
|
|
11177
|
+
var _j = (0, fuselage_hooks_1.useResizeObserver)(), containerRef = _j.ref, borderBoxSize = _j.borderBoxSize;
|
|
11188
11178
|
var handleClick = (0, fuselage_hooks_1.useMutableCallback)(function () {
|
|
11189
11179
|
if (visible === AnimatedVisibility_1.default.VISIBLE) {
|
|
11190
11180
|
return hide();
|
|
@@ -11237,7 +11227,7 @@ var PaginatedMultiSelect = function (_a) {
|
|
|
11237
11227
|
: 'chevron-down', size: 'x20' }) }))),
|
|
11238
11228
|
react_1.default.createElement(AnimatedVisibility_1.default, { visibility: visible },
|
|
11239
11229
|
react_1.default.createElement(Position_1.default, { anchor: containerRef },
|
|
11240
|
-
react_1.default.createElement(OptionsComponent, { width: borderBoxSize.inlineSize, onMouseDown: prevent_1.prevent, multiple: true, filter: filter, role: 'listbox', options: options, cursor: -1, endReached: endReached, onSelect: function (_a) {
|
|
11230
|
+
react_1.default.createElement(OptionsComponent, { width: borderBoxSize.inlineSize, onMouseDown: prevent_1.prevent, multiple: true, filter: filter, role: 'listbox', options: options, cursor: -1, endReached: endReached, renderItem: renderItem, onSelect: function (_a) {
|
|
11241
11231
|
var _b = __read(_a, 1), value = _b[0];
|
|
11242
11232
|
toggleOption(value);
|
|
11243
11233
|
} })))));
|
|
@@ -13556,7 +13546,7 @@ exports.SidebarBanner = void 0;
|
|
|
13556
13546
|
var react_1 = __importDefault(__webpack_require__(/*! react */ "react"));
|
|
13557
13547
|
var Button_1 = __webpack_require__(/*! ../Button */ "./src/components/Button/index.ts");
|
|
13558
13548
|
var SidebarBanner = function (_a) {
|
|
13559
|
-
var text = _a.text, description = _a.description, onClick = _a.onClick, _b = _a.variant, variant = _b === void 0 ? 'default' : _b, onClose = _a.onClose, children = _a.children;
|
|
13549
|
+
var text = _a.text, description = _a.description, onClick = _a.onClick, _b = _a.variant, variant = _b === void 0 ? 'default' : _b, addon = _a.addon, onClose = _a.onClose, children = _a.children;
|
|
13560
13550
|
return (react_1.default.createElement("div", { className: "rcx-box rcx-box--full rcx-sidebar-banner rcx-sidebar-banner--".concat(variant) },
|
|
13561
13551
|
react_1.default.createElement("div", null,
|
|
13562
13552
|
text && react_1.default.createElement("div", { className: 'rcx-sidebar-banner--text' }, text),
|
|
@@ -13567,7 +13557,9 @@ var SidebarBanner = function (_a) {
|
|
|
13567
13557
|
.filter(Boolean)
|
|
13568
13558
|
.join(' '), onClick: onClick }, description)),
|
|
13569
13559
|
children),
|
|
13570
|
-
|
|
13560
|
+
react_1.default.createElement("div", { className: 'rcx-sidebar-banner__actions' },
|
|
13561
|
+
addon,
|
|
13562
|
+
onClose && react_1.default.createElement(Button_1.IconButton, { onClick: onClose, tiny: true, icon: 'cross' }))));
|
|
13571
13563
|
};
|
|
13572
13564
|
exports.SidebarBanner = SidebarBanner;
|
|
13573
13565
|
|
|
@@ -15649,19 +15641,21 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
15649
15641
|
exports.Tag = void 0;
|
|
15650
15642
|
var react_1 = __importDefault(__webpack_require__(/*! react */ "react"));
|
|
15651
15643
|
var prependClassName_1 = __webpack_require__(/*! ../../helpers/prependClassName */ "./src/helpers/prependClassName.ts");
|
|
15644
|
+
var Box_1 = __importDefault(__webpack_require__(/*! ../Box/Box */ "./src/components/Box/Box.tsx"));
|
|
15652
15645
|
var Tag = function (_a) {
|
|
15653
|
-
var large = _a.large, medium = _a.medium, className = _a.className, disabled = _a.disabled, onClick = _a.onClick, variant = _a.variant, children = _a.children, icon = _a.icon, props = __rest(_a, ["large", "medium", "className", "disabled", "onClick", "variant", "children", "icon"]);
|
|
15646
|
+
var large = _a.large, medium = _a.medium, className = _a.className, disabled = _a.disabled, onClick = _a.onClick, variant = _a.variant, children = _a.children, icon = _a.icon, href = _a.href, props = __rest(_a, ["large", "medium", "className", "disabled", "onClick", "variant", "children", "icon", "href"]);
|
|
15654
15647
|
var modifiers = [
|
|
15655
15648
|
variant,
|
|
15656
15649
|
medium && 'medium',
|
|
15657
15650
|
large && 'large',
|
|
15658
15651
|
disabled && 'disabled',
|
|
15659
15652
|
onClick && 'clickable',
|
|
15653
|
+
href && 'clickable',
|
|
15660
15654
|
]
|
|
15661
15655
|
.filter(Boolean)
|
|
15662
15656
|
.map(function (modifier) { return "rcx-tag--".concat(modifier); })
|
|
15663
15657
|
.join(' ');
|
|
15664
|
-
return (react_1.default.createElement(
|
|
15658
|
+
return (react_1.default.createElement(Box_1.default, __assign({ is: href ? 'a' : 'span', className: (0, prependClassName_1.prependClassName)(className, "rcx-tag ".concat(modifiers)), onClick: onClick, href: href }, props),
|
|
15665
15659
|
icon,
|
|
15666
15660
|
react_1.default.createElement("span", { className: 'rcx-tag__inner' }, children)));
|
|
15667
15661
|
};
|
|
@@ -16658,11 +16652,12 @@ var isPaletteColorRef = function (ref) {
|
|
|
16658
16652
|
};
|
|
16659
16653
|
var mapTypeToPrefix = {
|
|
16660
16654
|
neutral: 'n',
|
|
16661
|
-
|
|
16662
|
-
|
|
16663
|
-
|
|
16664
|
-
|
|
16665
|
-
|
|
16655
|
+
blue: 'b',
|
|
16656
|
+
green: 'g',
|
|
16657
|
+
yellow: 'y',
|
|
16658
|
+
red: 'r',
|
|
16659
|
+
orange: 'o',
|
|
16660
|
+
purple: 'p',
|
|
16666
16661
|
};
|
|
16667
16662
|
var getPaletteColor = function (type, grade, alpha) {
|
|
16668
16663
|
var ref = "".concat(mapTypeToPrefix[type]).concat(grade);
|
|
@@ -17243,7 +17238,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
17243
17238
|
};
|
|
17244
17239
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
17245
17240
|
exports.fontScale = exports.fontFamily = exports.padding = exports.margin = exports.inset = exports.size = exports.color = exports.fontColor = exports.backgroundColor = exports.strokeColor = exports.borderRadius = exports.borderWidth = void 0;
|
|
17246
|
-
var colors_json_1 = __importDefault(__webpack_require__(/*! @rocket.chat/fuselage-tokens/colors.json */ "../fuselage-tokens/colors.json"));
|
|
17247
17241
|
var typography_json_1 = __importDefault(__webpack_require__(/*! @rocket.chat/fuselage-tokens/typography.json */ "../fuselage-tokens/typography.json"));
|
|
17248
17242
|
var memo_1 = __webpack_require__(/*! @rocket.chat/memo */ "@rocket.chat/memo");
|
|
17249
17243
|
var invariant_1 = __importDefault(__webpack_require__(/*! invariant */ "../../node_modules/invariant/browser.js"));
|
|
@@ -17291,11 +17285,12 @@ exports.borderRadius = measure(function (value) {
|
|
|
17291
17285
|
});
|
|
17292
17286
|
var mapTypeToPrefix = {
|
|
17293
17287
|
neutral: 'n',
|
|
17294
|
-
|
|
17295
|
-
|
|
17296
|
-
|
|
17297
|
-
|
|
17298
|
-
|
|
17288
|
+
blue: 'b',
|
|
17289
|
+
green: 'g',
|
|
17290
|
+
yellow: 'y',
|
|
17291
|
+
red: 'r',
|
|
17292
|
+
orange: 'o',
|
|
17293
|
+
purple: 'p',
|
|
17299
17294
|
};
|
|
17300
17295
|
var isPaletteColorType = function (type) {
|
|
17301
17296
|
return typeof type === 'string' && type in mapTypeToPrefix;
|
|
@@ -17310,29 +17305,7 @@ var isPaletteColorAlpha = function (alpha) {
|
|
|
17310
17305
|
return alpha === undefined ||
|
|
17311
17306
|
(typeof alpha === 'number' && alpha >= 0 && alpha <= 1);
|
|
17312
17307
|
};
|
|
17313
|
-
var
|
|
17314
|
-
'default': colors_json_1.default.n800,
|
|
17315
|
-
'info': colors_json_1.default.n700,
|
|
17316
|
-
'hint': colors_json_1.default.n600,
|
|
17317
|
-
'disabled': colors_json_1.default.n400,
|
|
17318
|
-
'alternative': 'white',
|
|
17319
|
-
'primary': colors_json_1.default.p500,
|
|
17320
|
-
'success': colors_json_1.default.s500,
|
|
17321
|
-
'danger': colors_json_1.default.d500,
|
|
17322
|
-
'warning': colors_json_1.default.w700,
|
|
17323
|
-
'link': colors_json_1.default.p500,
|
|
17324
|
-
'visited-link': colors_json_1.default['s2-500'],
|
|
17325
|
-
'active-link': colors_json_1.default.d500,
|
|
17326
|
-
};
|
|
17327
|
-
var isForegroundColorRef = function (ref) {
|
|
17328
|
-
return typeof ref === 'string' && ref in foregroundColors;
|
|
17329
|
-
};
|
|
17330
|
-
var getForegroundColor = function (type) {
|
|
17331
|
-
(0, invariant_1.default)(isForegroundColorRef(type), 'invalid foreground color');
|
|
17332
|
-
var color = foregroundColors[type];
|
|
17333
|
-
return ["--rcx-color-foreground-".concat(type), color];
|
|
17334
|
-
};
|
|
17335
|
-
var paletteColorRegex = /^(neutral|primary|info|success|warning|danger)-(\d+)(-(\d+))?$/;
|
|
17308
|
+
var paletteColorRegex = /^(neutral|blue|green|yellow|red|orange|purple)-(\d+)(-(\d+))?$/;
|
|
17336
17309
|
exports.strokeColor = (0, memo_1.memoize)(function (value) {
|
|
17337
17310
|
var colorName = "stroke-".concat(value);
|
|
17338
17311
|
if ((0, Theme_1.isStrokeColor)(colorName)) {
|
|
@@ -17399,35 +17372,28 @@ exports.color = (0, memo_1.memoize)(function (value) {
|
|
|
17399
17372
|
return Theme_1.surfaceColors['surface-light'].toString();
|
|
17400
17373
|
}
|
|
17401
17374
|
if (value === 'surface-tint') {
|
|
17402
|
-
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral
|
|
17375
|
+
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral[100]);
|
|
17403
17376
|
}
|
|
17404
17377
|
if (value === 'secondary-info') {
|
|
17405
|
-
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral
|
|
17378
|
+
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral[700]);
|
|
17406
17379
|
}
|
|
17407
17380
|
if (value === 'surface-neutral') {
|
|
17408
|
-
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral
|
|
17409
|
-
}
|
|
17410
|
-
if (isForegroundColorRef(value)) {
|
|
17411
|
-
var _a = __read(getForegroundColor(value), 2), customProperty = _a[0], color_1 = _a[1];
|
|
17412
|
-
if (customProperty) {
|
|
17413
|
-
return (0, toCSSValue_1.toCSSValue)(customProperty, color_1);
|
|
17414
|
-
}
|
|
17415
|
-
return color_1;
|
|
17381
|
+
return (0, toCSSValue_1.toCSSColorValue)(value, Theme_1.neutral[400]);
|
|
17416
17382
|
}
|
|
17417
17383
|
var paletteMatches = paletteColorRegex.exec(String(value));
|
|
17418
17384
|
if (typeof (paletteMatches === null || paletteMatches === void 0 ? void 0 : paletteMatches.length) === 'number' &&
|
|
17419
17385
|
(paletteMatches === null || paletteMatches === void 0 ? void 0 : paletteMatches.length) >= 5) {
|
|
17420
|
-
var
|
|
17386
|
+
var _a = __read(paletteMatches, 5), type = _a[1], gradeString = _a[2], alphaString = _a[4];
|
|
17421
17387
|
var grade = parseInt(gradeString, 10);
|
|
17422
17388
|
var alpha = alphaString !== undefined ? parseInt(alphaString, 10) / 100 : undefined;
|
|
17423
17389
|
(0, invariant_1.default)(isPaletteColorType(type), 'invalid color type');
|
|
17424
17390
|
(0, invariant_1.default)(isPaletteColorGrade(grade), 'invalid color grade');
|
|
17425
17391
|
(0, invariant_1.default)(isPaletteColorAlpha(alpha), 'invalid color alpha');
|
|
17426
|
-
var
|
|
17392
|
+
var _b = __read((0, getPaletteColor_1.getPaletteColor)(type, grade, alpha), 2), customProperty = _b[0], color_1 = _b[1];
|
|
17427
17393
|
if (customProperty) {
|
|
17428
|
-
return (0, toCSSValue_1.toCSSValue)(customProperty,
|
|
17394
|
+
return (0, toCSSValue_1.toCSSValue)(customProperty, color_1);
|
|
17429
17395
|
}
|
|
17430
|
-
return
|
|
17396
|
+
return color_1;
|
|
17431
17397
|
}
|
|
17432
17398
|
return value;
|
|
17433
17399
|
});
|
|
@@ -17601,7 +17567,7 @@ module.exports = __WEBPACK_EXTERNAL_MODULE_react__;
|
|
|
17601
17567
|
\**************************************/
|
|
17602
17568
|
/***/ (function(module) {
|
|
17603
17569
|
|
|
17604
|
-
module.exports = JSON.parse('{"
|
|
17570
|
+
module.exports = JSON.parse('{"white":"#FFFFFF","n100":"#F7F8FA","n200":"#F2F3F5","n250":"#EBECEF","n300":"#EEEFF1","n400":"#E4E7EA","n450":"#D7DBE0","n500":"#CBCED1","n600":"#9EA2A8","n700":"#6C737A","n800":"#2F343D","n900":"#1F2329","r100":"#FFE9EC","r200":"#FFC1C9","r300":"#F98F9D","r400":"#F5455C","r500":"#EC0D2A","r600":"#D40C26","r700":"#BB0B21","r800":"#9B1325","r900":"#8B0719","r1000":"#6B0513","o100":"#FDE8D7","o200":"#FAD1B0","o300":"#F7B27B","o400":"#F59B53","o500":"#F38C39","o600":"#E26D0E","o700":"#BD5A0B","o800":"#974809","o900":"#713607","o1000":"#5B2C06","p100":"#F9EFFC","p200":"#EDD0F7","p300":"#DCA0EF","p400":"#CA71E7","p500":"#9F22C7","p600":"#7F1B9F","p700":"#5F1477","p800":"#4A105D","p900":"#350B42","y100":"#FFF8E0","y200":"#FFECAD","y300":"#FFE383","y400":"#FFD95A","y500":"#FFD031","y600":"#F3BE08","y700":"#DFAC00","y800":"#AC892F","y900":"#8E6300","y1000":"#573D00","g100":"#E5FBF4","g200":"#C0F6E4","g300":"#96F0D2","g400":"#6CE9C0","g500":"#2DE0A5","g600":"#1ECB92","g700":"#19AC7C","g800":"#148660","g900":"#106D4F","g1000":"#0D5940","b100":"#E8F2FF","b200":"#D1EBFE","b300":"#76B7FC","b400":"#549DF9","b500":"#156FF5","b600":"#095AD2","b700":"#10529E","b800":"#01336B","b900":"#012247"}');
|
|
17605
17571
|
|
|
17606
17572
|
/***/ }),
|
|
17607
17573
|
|