@canonical/react-components 0.50.4 → 0.50.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/NotificationProvider/NotificationProvider.js +1 -1
- package/dist/components/NotificationProvider/messageBuilder.d.ts +1 -1
- package/dist/components/NotificationProvider/messageBuilder.js +2 -1
- package/dist/components/NotificationProvider/types.d.ts +1 -1
- package/package.json +1 -1
|
@@ -49,7 +49,7 @@ const NotificationProvider = _ref => {
|
|
|
49
49
|
queue: _messageBuilder.queue,
|
|
50
50
|
failure: (title, error, message, actions) => setDeduplicated((0, _messageBuilder.failure)(title, error, message, actions)),
|
|
51
51
|
info: (message, title) => setDeduplicated((0, _messageBuilder.info)(message, title)),
|
|
52
|
-
success: message => setDeduplicated((0, _messageBuilder.success)(message)),
|
|
52
|
+
success: (message, title) => setDeduplicated((0, _messageBuilder.success)(message, title)),
|
|
53
53
|
setDeduplicated
|
|
54
54
|
};
|
|
55
55
|
return /*#__PURE__*/_react.default.createElement(NotifyContext.Provider, {
|
|
@@ -2,5 +2,5 @@ import { NotificationAction, NotificationType, QueuedNotification } from "./type
|
|
|
2
2
|
import { ReactNode } from "react";
|
|
3
3
|
export declare const queue: (notification: NotificationType) => QueuedNotification;
|
|
4
4
|
export declare const info: (message: ReactNode, title?: string) => NotificationType;
|
|
5
|
-
export declare const success: (message: ReactNode) => NotificationType;
|
|
5
|
+
export declare const success: (message: ReactNode, title?: string) => NotificationType;
|
|
6
6
|
export declare const failure: (title: string, error: unknown, message?: ReactNode, actions?: NotificationAction[]) => NotificationType;
|
|
@@ -29,7 +29,7 @@ export interface NotificationHelper {
|
|
|
29
29
|
clear: () => void;
|
|
30
30
|
failure: (title: string, error: unknown, message?: ReactNode, actions?: NotificationAction[]) => NotificationType;
|
|
31
31
|
info: (message: ReactNode, title?: string) => NotificationType;
|
|
32
|
-
success: (message: ReactNode) => NotificationType;
|
|
32
|
+
success: (message: ReactNode, title?: string) => NotificationType;
|
|
33
33
|
queue: (notification: NotificationType) => QueuedNotification;
|
|
34
34
|
setDeduplicated: (value: NotificationType) => NotificationType;
|
|
35
35
|
}
|