@zendeskgarden/react-notifications 9.0.0-next.7 → 9.0.0-next.9

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.
Files changed (49) hide show
  1. package/dist/esm/elements/Alert.js +56 -0
  2. package/dist/esm/elements/Notification.js +56 -0
  3. package/dist/esm/elements/Well.js +38 -0
  4. package/dist/esm/elements/content/Close.js +37 -0
  5. package/dist/esm/elements/content/Paragraph.js +28 -0
  6. package/dist/esm/elements/content/Title.js +28 -0
  7. package/dist/esm/elements/global-alert/GlobalAlert.js +65 -0
  8. package/dist/esm/elements/global-alert/GlobalAlertButton.js +46 -0
  9. package/dist/esm/elements/global-alert/GlobalAlertClose.js +41 -0
  10. package/dist/esm/elements/global-alert/GlobalAlertContent.js +30 -0
  11. package/dist/esm/elements/global-alert/GlobalAlertTitle.js +39 -0
  12. package/dist/esm/elements/global-alert/utility.js +14 -0
  13. package/dist/esm/elements/toaster/Toast.js +62 -0
  14. package/dist/esm/elements/toaster/ToastContext.js +11 -0
  15. package/dist/esm/elements/toaster/ToastProvider.js +51 -0
  16. package/dist/esm/elements/toaster/ToastSlot.js +82 -0
  17. package/dist/esm/elements/toaster/reducer.js +66 -0
  18. package/dist/esm/elements/toaster/styled.js +71 -0
  19. package/dist/esm/elements/toaster/useToast.js +70 -0
  20. package/dist/esm/index.js +15 -0
  21. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/12/x-stroke.svg.js +26 -0
  22. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/alert-error-stroke.svg.js +37 -0
  23. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/alert-warning-stroke.svg.js +32 -0
  24. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/check-circle-stroke.svg.js +33 -0
  25. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/info-stroke.svg.js +37 -0
  26. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/x-stroke.svg.js +26 -0
  27. package/dist/esm/styled/StyledAlert.js +25 -0
  28. package/dist/esm/styled/StyledBase.js +54 -0
  29. package/dist/esm/styled/StyledIcon.js +18 -0
  30. package/dist/esm/styled/StyledNotification.js +62 -0
  31. package/dist/esm/styled/StyledWell.js +23 -0
  32. package/dist/esm/styled/content/StyledClose.js +25 -0
  33. package/dist/esm/styled/content/StyledParagraph.js +22 -0
  34. package/dist/esm/styled/content/StyledTitle.js +22 -0
  35. package/dist/esm/styled/global-alert/StyledGlobalAlert.js +85 -0
  36. package/dist/esm/styled/global-alert/StyledGlobalAlertButton.js +75 -0
  37. package/dist/esm/styled/global-alert/StyledGlobalAlertClose.js +74 -0
  38. package/dist/esm/styled/global-alert/StyledGlobalAlertContent.js +22 -0
  39. package/dist/esm/styled/global-alert/StyledGlobalAlertIcon.js +29 -0
  40. package/dist/esm/styled/global-alert/StyledGlobalAlertTitle.js +38 -0
  41. package/dist/esm/types/index.js +9 -0
  42. package/dist/esm/utils/icons.js +25 -0
  43. package/dist/esm/utils/useNotificationsContext.js +14 -0
  44. package/dist/index.cjs.js +63 -84
  45. package/dist/typings/styled/StyledIcon.d.ts +2 -2
  46. package/dist/typings/styled/global-alert/StyledGlobalAlertButton.d.ts +2 -2
  47. package/dist/typings/styled/global-alert/StyledGlobalAlertIcon.d.ts +2 -2
  48. package/package.json +6 -6
  49. package/dist/index.esm.js +0 -1134
package/dist/index.cjs.js CHANGED
@@ -1,10 +1,9 @@
1
1
  /**
2
- * Copyright Zendesk, Inc.
3
- *
4
- * Use of this source code is governed under the Apache License, Version 2.0
5
- * found at http://www.apache.org/licenses/LICENSE-2.0.
6
- */
7
-
2
+ * Copyright Zendesk, Inc.
3
+ *
4
+ * Use of this source code is governed under the Apache License, Version 2.0
5
+ * found at http://www.apache.org/licenses/LICENSE-2.0.
6
+ */
8
7
  'use strict';
9
8
 
10
9
  var React = require('react');
@@ -40,27 +39,12 @@ var React__namespace = /*#__PURE__*/_interopNamespace(React);
40
39
  var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);
41
40
  var styled__default = /*#__PURE__*/_interopDefault(styled);
42
41
 
43
- function _extends$6() {
44
- _extends$6 = Object.assign ? Object.assign.bind() : function (target) {
45
- for (var i = 1; i < arguments.length; i++) {
46
- var source = arguments[i];
47
- for (var key in source) {
48
- if (Object.prototype.hasOwnProperty.call(source, key)) {
49
- target[key] = source[key];
50
- }
51
- }
52
- }
53
- return target;
54
- };
55
- return _extends$6.apply(this, arguments);
56
- }
57
-
58
42
  const TYPE = ['success', 'warning', 'error', 'info'];
59
43
 
60
44
  const COMPONENT_ID$b = 'notifications.close';
61
45
  const StyledClose = styled__default.default.button.attrs({
62
46
  'data-garden-id': COMPONENT_ID$b,
63
- 'data-garden-version': '9.0.0-next.7'
47
+ 'data-garden-version': '9.0.0-next.9'
64
48
  }).withConfig({
65
49
  displayName: "StyledClose",
66
50
  componentId: "sc-1mr9nx1-0"
@@ -75,7 +59,7 @@ StyledClose.defaultProps = {
75
59
  const COMPONENT_ID$a = 'notifications.paragraph';
76
60
  const StyledParagraph = styled__default.default.p.attrs({
77
61
  'data-garden-id': COMPONENT_ID$a,
78
- 'data-garden-version': '9.0.0-next.7'
62
+ 'data-garden-version': '9.0.0-next.9'
79
63
  }).withConfig({
80
64
  displayName: "StyledParagraph",
81
65
  componentId: "sc-12tmd6p-0"
@@ -87,7 +71,7 @@ StyledParagraph.defaultProps = {
87
71
  const COMPONENT_ID$9 = 'notifications.title';
88
72
  const StyledTitle = styled__default.default.div.attrs({
89
73
  'data-garden-id': COMPONENT_ID$9,
90
- 'data-garden-version': '9.0.0-next.7'
74
+ 'data-garden-version': '9.0.0-next.9'
91
75
  }).withConfig({
92
76
  displayName: "StyledTitle",
93
77
  componentId: "sc-xx4jsv-0"
@@ -144,7 +128,7 @@ const COMPONENT_ID$8 = 'notifications.alert';
144
128
  const colorStyles$5 = props => styled.css(["", "{color:", ";}"], StyledTitle, props.hue && reactTheming.getColorV8(props.hue, 800, props.theme));
145
129
  const StyledAlert = styled__default.default(StyledBase).attrs({
146
130
  'data-garden-id': COMPONENT_ID$8,
147
- 'data-garden-version': '9.0.0-next.7'
131
+ 'data-garden-version': '9.0.0-next.9'
148
132
  }).withConfig({
149
133
  displayName: "StyledAlert",
150
134
  componentId: "sc-fyn8jp-0"
@@ -189,7 +173,7 @@ const colorStyles$4 = props => {
189
173
  };
190
174
  const StyledNotification = styled__default.default(StyledBase).attrs({
191
175
  'data-garden-id': COMPONENT_ID$7,
192
- 'data-garden-version': '9.0.0-next.7'
176
+ 'data-garden-version': '9.0.0-next.9'
193
177
  }).withConfig({
194
178
  displayName: "StyledNotification",
195
179
  componentId: "sc-uf6jh-0"
@@ -204,7 +188,7 @@ StyledNotification.defaultProps = {
204
188
  const COMPONENT_ID$6 = 'notifications.well';
205
189
  const StyledWell = styled__default.default(StyledBase).attrs({
206
190
  'data-garden-id': COMPONENT_ID$6,
207
- 'data-garden-version': '9.0.0-next.7'
191
+ 'data-garden-version': '9.0.0-next.9'
208
192
  }).withConfig({
209
193
  displayName: "StyledWell",
210
194
  componentId: "sc-a5831c-0"
@@ -213,16 +197,10 @@ StyledWell.defaultProps = {
213
197
  theme: reactTheming.DEFAULT_THEME
214
198
  };
215
199
 
216
- const StyledIcon = styled__default.default(_ref => {
217
- let {
218
- children,
219
- ...props
220
- } = _ref;
221
- return React__namespace.default.cloneElement(React.Children.only(children), props);
222
- }).withConfig({
200
+ const StyledIcon = styled__default.default(reactTheming.StyledBaseIcon).withConfig({
223
201
  displayName: "StyledIcon",
224
202
  componentId: "sc-msklws-0"
225
- })(["position:absolute;right:", ";left:", ";margin-top:", "px;color:", ";"], props => props.theme.rtl && `${props.theme.space.base * 4}px`, props => !props.theme.rtl && `${props.theme.space.base * 4}px`, props => props.theme.space.base / 2, props => props.hue && reactTheming.getColorV8(props.hue, props.hue === 'warningHue' ? 700 : 600, props.theme));
203
+ })(["position:absolute;right:", ";left:", ";margin-top:", "px;color:", ";"], props => props.theme.rtl && `${props.theme.space.base * 4}px`, props => !props.theme.rtl && `${props.theme.space.base * 4}px`, props => props.theme.space.base / 2, props => props.$hue && reactTheming.getColorV8(props.$hue, props.$hue === 'warningHue' ? 700 : 600, props.theme));
226
204
  StyledIcon.defaultProps = {
227
205
  theme: reactTheming.DEFAULT_THEME
228
206
  };
@@ -272,8 +250,10 @@ const colorStyles$3 = props => {
272
250
  const boxShadow = `0 ${props.theme.borderWidths.sm} ${props.theme.borderWidths.sm} ${borderColor}`;
273
251
  return styled.css(["box-shadow:", ";background-color:", ";color:", ";& a{color:inherit;", " &:hover{color:", ";}&:active{color:", ";}}"], boxShadow, backgroundColor, foregroundColor, reactTheming.focusStyles({
274
252
  theme: props.theme,
275
- hue: focusColor,
276
- shade: props.alertType === 'info' ? 600 : 800,
253
+ color: {
254
+ hue: focusColor,
255
+ shade: props.alertType === 'info' ? 600 : 800
256
+ },
277
257
  styles: {
278
258
  color: 'inherit'
279
259
  }
@@ -291,7 +271,7 @@ const sizeStyles$3 = props => {
291
271
  };
292
272
  const StyledGlobalAlert = styled__default.default.div.attrs({
293
273
  'data-garden-id': COMPONENT_ID$5,
294
- 'data-garden-version': '9.0.0-next.7'
274
+ 'data-garden-version': '9.0.0-next.9'
295
275
  }).withConfig({
296
276
  displayName: "StyledGlobalAlert",
297
277
  componentId: "sc-k6rimt-0"
@@ -339,8 +319,10 @@ const colorStyles$2 = props => {
339
319
  }
340
320
  return styled.css(["color:inherit;&:hover{background-color:", ";color:", ";}", " &:active{background-color:", ";color:", ";}"], hoverBackgroundColor, hoverForegroundColor, reactTheming.focusStyles({
341
321
  theme: props.theme,
342
- hue: focusColor,
343
- shade: props.alertType === 'info' ? 600 : 800
322
+ color: {
323
+ hue: focusColor,
324
+ shade: props.alertType === 'info' ? 600 : 800
325
+ }
344
326
  }), activeBackgroundColor, activeForegroundColor);
345
327
  };
346
328
  const sizeStyles$2 = props => {
@@ -351,7 +333,7 @@ const sizeStyles$2 = props => {
351
333
  };
352
334
  const StyledGlobalAlertClose = styled__default.default(reactButtons.IconButton).attrs({
353
335
  'data-garden-id': COMPONENT_ID$4,
354
- 'data-garden-version': '9.0.0-next.7',
336
+ 'data-garden-version': '9.0.0-next.9',
355
337
  size: 'small'
356
338
  }).withConfig({
357
339
  displayName: "StyledGlobalAlertClose",
@@ -395,8 +377,10 @@ function colorStyles$1(props) {
395
377
  }
396
378
  return styled.css(["background-color:", ";&:hover{background-color:", ";}", " &:active{background-color:", ";}"], backgroundColor, hoverBackgroundColor, reactTheming.focusStyles({
397
379
  theme: props.theme,
398
- hue: focusColor,
399
- shade: props.alertType === 'info' ? 600 : 800
380
+ color: {
381
+ hue: focusColor,
382
+ shade: props.alertType === 'info' ? 600 : 800
383
+ }
400
384
  }), activeBackgroundColor);
401
385
  }
402
386
  function sizeStyles$1(props) {
@@ -406,7 +390,7 @@ function sizeStyles$1(props) {
406
390
  }
407
391
  const StyledGlobalAlertButton = styled__default.default(reactButtons.Button).attrs({
408
392
  'data-garden-id': COMPONENT_ID$3,
409
- 'data-garden-version': '9.0.0-next.7',
393
+ 'data-garden-version': '9.0.0-next.9',
410
394
  focusInset: false,
411
395
  isDanger: false,
412
396
  isLink: false,
@@ -425,7 +409,7 @@ StyledGlobalAlertButton.defaultProps = {
425
409
  const COMPONENT_ID$2 = 'notifications.global-alert.content';
426
410
  const StyledGlobalAlertContent = styled__default.default.div.attrs({
427
411
  'data-garden-id': COMPONENT_ID$2,
428
- 'data-garden-version': '9.0.0-next.7'
412
+ 'data-garden-version': '9.0.0-next.9'
429
413
  }).withConfig({
430
414
  displayName: "StyledGlobalAlertContent",
431
415
  componentId: "sc-rept0u-0"
@@ -441,15 +425,9 @@ const sizeStyles = props => {
441
425
  const marginHorizontal = `${props.theme.space.base * 2}px`;
442
426
  return styled.css(["margin-top:", ";margin-", ":", ";width:", ";height:", ";"], marginTop, props.theme.rtl ? 'left' : 'right', marginHorizontal, size, size);
443
427
  };
444
- const StyledGlobalAlertIcon = styled__default.default(_ref => {
445
- let {
446
- children,
447
- ...props
448
- } = _ref;
449
- return React__namespace.default.cloneElement(React.Children.only(children), props);
450
- }).attrs({
428
+ const StyledGlobalAlertIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
451
429
  'data-garden-id': COMPONENT_ID$1,
452
- 'data-garden-version': '9.0.0-next.7'
430
+ 'data-garden-version': '9.0.0-next.9'
453
431
  }).withConfig({
454
432
  displayName: "StyledGlobalAlertIcon",
455
433
  componentId: "sc-84ne9k-0"
@@ -477,7 +455,7 @@ const colorStyles = props => {
477
455
  };
478
456
  const StyledGlobalAlertTitle = styled__default.default.div.attrs({
479
457
  'data-garden-id': COMPONENT_ID,
480
- 'data-garden-version': '9.0.0-next.7'
458
+ 'data-garden-version': '9.0.0-next.9'
481
459
  }).withConfig({
482
460
  displayName: "StyledGlobalAlertTitle",
483
461
  componentId: "sc-10clqbo-0"
@@ -607,12 +585,12 @@ const useNotificationsContext = () => {
607
585
  return React.useContext(NotificationsContext);
608
586
  };
609
587
 
610
- const Title = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledTitle, _extends$6({
588
+ const Title = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledTitle, Object.assign({
611
589
  ref: ref
612
590
  }, props)));
613
591
  Title.displayName = 'Title';
614
592
 
615
- const Paragraph = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledParagraph, _extends$6({
593
+ const Paragraph = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledParagraph, Object.assign({
616
594
  ref: ref
617
595
  }, props)));
618
596
  Paragraph.displayName = 'Paragraph';
@@ -637,7 +615,7 @@ var SvgXStroke$1 = function SvgXStroke(props) {
637
615
  const Close = React__namespace.default.forwardRef((props, ref) => {
638
616
  const ariaLabel = reactTheming.useText(Close, props, 'aria-label', 'Close');
639
617
  const hue = useNotificationsContext();
640
- return React__namespace.default.createElement(StyledClose, _extends$6({
618
+ return React__namespace.default.createElement(StyledClose, Object.assign({
641
619
  ref: ref,
642
620
  hue: hue,
643
621
  "aria-label": ariaLabel
@@ -654,12 +632,12 @@ const AlertComponent = React__namespace.default.forwardRef((_ref, ref) => {
654
632
  const Icon = validationIcons[props.type];
655
633
  return React__namespace.default.createElement(NotificationsContext.Provider, {
656
634
  value: hue
657
- }, React__namespace.default.createElement(StyledAlert, _extends$6({
635
+ }, React__namespace.default.createElement(StyledAlert, Object.assign({
658
636
  ref: ref,
659
637
  hue: hue,
660
638
  role: role === undefined ? 'alert' : role
661
639
  }, props), React__namespace.default.createElement(StyledIcon, {
662
- hue: hue
640
+ $hue: hue
663
641
  }, React__namespace.default.createElement(Icon, null)), props.children));
664
642
  });
665
643
  AlertComponent.displayName = 'Alert';
@@ -673,20 +651,20 @@ Alert.Title = Title;
673
651
 
674
652
  const NotificationComponent = React.forwardRef((_ref, ref) => {
675
653
  let {
676
- role,
654
+ children,
655
+ type,
677
656
  ...props
678
657
  } = _ref;
679
- const Icon = props.type ? validationIcons[props.type] : SvgInfoStroke;
680
- const hue = props.type && validationHues[props.type];
681
- return React__namespace.default.createElement(StyledNotification, _extends$6({
658
+ const Icon = type ? validationIcons[type] : SvgInfoStroke;
659
+ const hue = type && validationHues[type];
660
+ return React__namespace.default.createElement(StyledNotification, Object.assign({
682
661
  ref: ref,
683
- type: props.type,
684
- isFloating: true
685
- }, props, {
686
- role: role === undefined ? 'status' : role
687
- }), props.type && React__namespace.default.createElement(StyledIcon, {
688
- hue: hue
689
- }, React__namespace.default.createElement(Icon, null)), props.children);
662
+ type: type,
663
+ isFloating: true,
664
+ role: "alert"
665
+ }, props), type && React__namespace.default.createElement(StyledIcon, {
666
+ $hue: hue
667
+ }, React__namespace.default.createElement(Icon, null)), children);
690
668
  });
691
669
  NotificationComponent.displayName = 'Notification';
692
670
  NotificationComponent.propTypes = {
@@ -697,7 +675,7 @@ Notification.Close = Close;
697
675
  Notification.Paragraph = Paragraph;
698
676
  Notification.Title = Title;
699
677
 
700
- const WellComponent = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledWell, _extends$6({
678
+ const WellComponent = React__namespace.default.forwardRef((props, ref) => React__namespace.default.createElement(StyledWell, Object.assign({
701
679
  ref: ref
702
680
  }, props)));
703
681
  WellComponent.displayName = 'Well';
@@ -981,7 +959,7 @@ const ToastSlot = _ref => {
981
959
  }
982
960
  return index >= limit;
983
961
  }, [limit, placement, toasts.length]);
984
- return React__namespace.default.createElement(StyledTransitionContainer, _extends$6({
962
+ return React__namespace.default.createElement(StyledTransitionContainer, Object.assign({
985
963
  key: placement,
986
964
  toastPlacement: placement,
987
965
  toastZIndex: zIndex,
@@ -1026,7 +1004,7 @@ const ToastProvider = _ref => {
1026
1004
  if (placement === 'bottom' || placement === 'bottom-start' || placement === 'bottom-end') {
1027
1005
  matchingToasts = matchingToasts.reverse();
1028
1006
  }
1029
- return React__namespace.default.createElement(ToastSlot, _extends$6({
1007
+ return React__namespace.default.createElement(ToastSlot, Object.assign({
1030
1008
  placement: placement,
1031
1009
  toasts: matchingToasts,
1032
1010
  zIndex: zIndex,
@@ -1060,7 +1038,7 @@ const GlobalAlertButton = React.forwardRef((_ref, ref) => {
1060
1038
  const {
1061
1039
  type
1062
1040
  } = useGlobalAlertContext();
1063
- return React__namespace.default.createElement(StyledGlobalAlertButton, _extends$6({
1041
+ return React__namespace.default.createElement(StyledGlobalAlertButton, Object.assign({
1064
1042
  ref: ref,
1065
1043
  alertType: type
1066
1044
  }, props, {
@@ -1095,7 +1073,7 @@ const GlobalAlertClose = React.forwardRef((props, ref) => {
1095
1073
  type
1096
1074
  } = useGlobalAlertContext();
1097
1075
  const label = reactTheming.useText(GlobalAlertClose, props, 'aria-label', 'Close');
1098
- return React__namespace.default.createElement(StyledGlobalAlertClose, _extends$6({
1076
+ return React__namespace.default.createElement(StyledGlobalAlertClose, Object.assign({
1099
1077
  ref: ref,
1100
1078
  alertType: type
1101
1079
  }, props), React__namespace.default.createElement(SvgXStroke, {
@@ -1106,7 +1084,7 @@ const GlobalAlertClose = React.forwardRef((props, ref) => {
1106
1084
  GlobalAlertClose.displayName = 'GlobalAlert.Close';
1107
1085
 
1108
1086
  const GlobalAlertContent = React.forwardRef((props, ref) => {
1109
- return React__namespace.default.createElement(StyledGlobalAlertContent, _extends$6({
1087
+ return React__namespace.default.createElement(StyledGlobalAlertContent, Object.assign({
1110
1088
  ref: ref
1111
1089
  }, props));
1112
1090
  });
@@ -1116,7 +1094,7 @@ const GlobalAlertTitle = React.forwardRef((props, ref) => {
1116
1094
  const {
1117
1095
  type
1118
1096
  } = useGlobalAlertContext();
1119
- return React__namespace.default.createElement(StyledGlobalAlertTitle, _extends$6({
1097
+ return React__namespace.default.createElement(StyledGlobalAlertTitle, Object.assign({
1120
1098
  alertType: type,
1121
1099
  ref: ref
1122
1100
  }, props));
@@ -1131,20 +1109,21 @@ const GlobalAlertComponent = React.forwardRef((_ref, ref) => {
1131
1109
  type,
1132
1110
  ...props
1133
1111
  } = _ref;
1112
+ const icon = {
1113
+ success: React__namespace.default.createElement(SvgCheckCircleStroke, null),
1114
+ error: React__namespace.default.createElement(SvgAlertErrorStroke, null),
1115
+ warning: React__namespace.default.createElement(SvgAlertWarningStroke, null),
1116
+ info: React__namespace.default.createElement(SvgInfoStroke, null)
1117
+ }[type];
1134
1118
  return React__namespace.default.createElement(GlobalAlertContext.Provider, {
1135
1119
  value: React.useMemo(() => ({
1136
1120
  type
1137
1121
  }), [type])
1138
- }, React__namespace.default.createElement(StyledGlobalAlert, _extends$6({
1122
+ }, React__namespace.default.createElement(StyledGlobalAlert, Object.assign({
1139
1123
  ref: ref,
1140
1124
  role: "status",
1141
1125
  alertType: type
1142
- }, props), {
1143
- success: React__namespace.default.createElement(StyledGlobalAlertIcon, null, React__namespace.default.createElement(SvgCheckCircleStroke, null)),
1144
- error: React__namespace.default.createElement(StyledGlobalAlertIcon, null, React__namespace.default.createElement(SvgAlertErrorStroke, null)),
1145
- warning: React__namespace.default.createElement(StyledGlobalAlertIcon, null, React__namespace.default.createElement(SvgAlertWarningStroke, null)),
1146
- info: React__namespace.default.createElement(StyledGlobalAlertIcon, null, React__namespace.default.createElement(SvgInfoStroke, null))
1147
- }[type], props.children));
1126
+ }, props), React__namespace.default.createElement(StyledGlobalAlertIcon, null, icon), props.children));
1148
1127
  });
1149
1128
  GlobalAlertComponent.displayName = 'GlobalAlert';
1150
1129
  const GlobalAlert = GlobalAlertComponent;
@@ -4,5 +4,5 @@
4
4
  * Use of this source code is governed under the Apache License, Version 2.0
5
5
  * found at http://www.apache.org/licenses/LICENSE-2.0.
6
6
  */
7
- import React from 'react';
8
- export declare const StyledIcon: import("styled-components").StyledComponent<({ children, ...props }: any) => React.DetailedReactHTMLElement<any, HTMLElement>, import("styled-components").DefaultTheme, {}, never>;
7
+ /// <reference types="react" />
8
+ export declare const StyledIcon: import("styled-components").StyledComponent<({ children, theme, ...props }: any) => import("react").DetailedReactHTMLElement<any, HTMLElement>, import("styled-components").DefaultTheme, {}, never>;
@@ -13,11 +13,11 @@ interface IStyledGlobalAlertButtonProps {
13
13
  }
14
14
  export declare const StyledGlobalAlertButton: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@zendeskgarden/react-buttons").IButtonProps & import("react").RefAttributes<HTMLButtonElement>> & {
15
15
  EndIcon: {
16
- (props: import("@zendeskgarden/react-buttons").IButtonEndIconProps): import("react").JSX.Element;
16
+ ({ isRotated, ...props }: import("@zendeskgarden/react-buttons").IButtonEndIconProps): import("react").JSX.Element;
17
17
  displayName: string;
18
18
  };
19
19
  StartIcon: {
20
- (props: import("@zendeskgarden/react-buttons").IButtonEndIconProps): import("react").JSX.Element;
20
+ ({ isRotated, ...props }: import("@zendeskgarden/react-buttons").IButtonEndIconProps): import("react").JSX.Element;
21
21
  displayName: string;
22
22
  };
23
23
  }, DefaultTheme, {
@@ -4,9 +4,9 @@
4
4
  * Use of this source code is governed under the Apache License, Version 2.0
5
5
  * found at http://www.apache.org/licenses/LICENSE-2.0.
6
6
  */
7
- import React from 'react';
7
+ /// <reference types="react" />
8
8
  import { DefaultTheme } from 'styled-components';
9
- export declare const StyledGlobalAlertIcon: import("styled-components").StyledComponent<({ children, ...props }: any) => React.DetailedReactHTMLElement<any, HTMLElement>, DefaultTheme, {
9
+ export declare const StyledGlobalAlertIcon: import("styled-components").StyledComponent<({ children, theme, ...props }: any) => import("react").DetailedReactHTMLElement<any, HTMLElement>, DefaultTheme, {
10
10
  'data-garden-id': string;
11
11
  'data-garden-version': string;
12
12
  }, "data-garden-id" | "data-garden-version">;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zendeskgarden/react-notifications",
3
- "version": "9.0.0-next.7",
3
+ "version": "9.0.0-next.9",
4
4
  "description": "Notification and Well components within the Garden Design System",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Zendesk Garden <garden@zendesk.com>",
@@ -10,7 +10,7 @@
10
10
  "url": "https://github.com/zendeskgarden/react-components/issues"
11
11
  },
12
12
  "main": "dist/index.cjs.js",
13
- "module": "dist/index.esm.js",
13
+ "module": "dist/esm/index.js",
14
14
  "files": [
15
15
  "dist"
16
16
  ],
@@ -21,21 +21,21 @@
21
21
  "sideEffects": false,
22
22
  "types": "dist/typings/index.d.ts",
23
23
  "dependencies": {
24
- "@zendeskgarden/react-buttons": "^9.0.0-next.7",
24
+ "@zendeskgarden/react-buttons": "^9.0.0-next.9",
25
25
  "polished": "^4.1.1",
26
26
  "prop-types": "^15.5.7",
27
27
  "react-transition-group": "^4.4.2",
28
28
  "react-uid": "^2.3.1"
29
29
  },
30
30
  "peerDependencies": {
31
- "@zendeskgarden/react-theming": "^9.0.0",
31
+ "@zendeskgarden/react-theming": ">=9.0.0-next",
32
32
  "react": ">=16.8.0",
33
33
  "react-dom": ">=16.8.0",
34
34
  "styled-components": "^5.3.1"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@types/react-transition-group": "4.4.10",
38
- "@zendeskgarden/react-theming": "^9.0.0-next.7",
38
+ "@zendeskgarden/react-theming": "^9.0.0-next.9",
39
39
  "@zendeskgarden/svg-icons": "7.0.0"
40
40
  },
41
41
  "keywords": [
@@ -48,5 +48,5 @@
48
48
  "access": "public"
49
49
  },
50
50
  "zendeskgarden:src": "src/index.ts",
51
- "gitHead": "50a2b45b2e237a490a6d460818d33498b92479ec"
51
+ "gitHead": "771281b562d376a6aee04b0cd71dd888b3ae4a1d"
52
52
  }