@novu/js 3.0.0-canary.2 → 3.0.1
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/cjs/{chunk-WFFKLN6Q.js → chunk-BD5JCEYL.js} +13 -1
- package/dist/cjs/index.d.ts +2 -2
- package/dist/cjs/index.js +14 -14
- package/dist/{esm/novu-C2hAbM3b.d.mts → cjs/novu-CalZFixf.d.ts} +3 -0
- package/dist/cjs/themes/index.d.ts +2 -2
- package/dist/cjs/themes/index.js +2 -1
- package/dist/{esm/types-Bi5NkU2g.d.mts → cjs/types-lO51eBKl.d.ts} +2 -1
- package/dist/cjs/ui/index.d.ts +4 -4
- package/dist/cjs/ui/index.js +133 -87
- package/dist/esm/{chunk-54BVY6WN.mjs → chunk-MT6EQHGN.mjs} +13 -1
- package/dist/esm/index.d.mts +2 -2
- package/dist/esm/index.mjs +1 -1
- package/dist/{cjs/novu-C2hAbM3b.d.ts → esm/novu-CalZFixf.d.mts} +3 -0
- package/dist/esm/themes/index.d.mts +2 -2
- package/dist/esm/themes/index.mjs +2 -1
- package/dist/{cjs/types-CKkldJh0.d.ts → esm/types-DC-kqier.d.mts} +2 -1
- package/dist/esm/ui/index.d.mts +4 -4
- package/dist/esm/ui/index.mjs +130 -84
- package/dist/index.css +1 -1
- package/dist/novu.min.js +6 -6
- package/dist/novu.min.js.gz +0 -0
- package/package.json +1 -1
|
@@ -91,7 +91,7 @@ var isSameFilter = (filter1, filter2) => {
|
|
|
91
91
|
// src/api/http-client.ts
|
|
92
92
|
var DEFAULT_API_VERSION = "v1";
|
|
93
93
|
var DEFAULT_BACKEND_URL = "https://api.novu.co";
|
|
94
|
-
var DEFAULT_USER_AGENT = `${"@novu/js"}@${"3.0.
|
|
94
|
+
var DEFAULT_USER_AGENT = `${"@novu/js"}@${"3.0.1"}`;
|
|
95
95
|
var HttpClient = class {
|
|
96
96
|
constructor(options = {}) {
|
|
97
97
|
const {
|
|
@@ -1522,6 +1522,12 @@ var Session = class {
|
|
|
1522
1522
|
chunk7B52C2XE_js.__privateSet(this, _inboxService2, inboxServiceInstance);
|
|
1523
1523
|
chunk7B52C2XE_js.__privateSet(this, _options, options);
|
|
1524
1524
|
}
|
|
1525
|
+
get applicationIdentifier() {
|
|
1526
|
+
return chunk7B52C2XE_js.__privateGet(this, _options).applicationIdentifier;
|
|
1527
|
+
}
|
|
1528
|
+
get subscriberId() {
|
|
1529
|
+
return chunk7B52C2XE_js.__privateGet(this, _options).subscriberId;
|
|
1530
|
+
}
|
|
1525
1531
|
initialize() {
|
|
1526
1532
|
return chunk7B52C2XE_js.__async(this, null, function* () {
|
|
1527
1533
|
try {
|
|
@@ -1775,6 +1781,12 @@ var Novu = class {
|
|
|
1775
1781
|
chunk7B52C2XE_js.__privateGet(this, _emitter7).off(eventName, listener);
|
|
1776
1782
|
};
|
|
1777
1783
|
}
|
|
1784
|
+
get applicationIdentifier() {
|
|
1785
|
+
return chunk7B52C2XE_js.__privateGet(this, _session).applicationIdentifier;
|
|
1786
|
+
}
|
|
1787
|
+
get subscriberId() {
|
|
1788
|
+
return chunk7B52C2XE_js.__privateGet(this, _session).subscriberId;
|
|
1789
|
+
}
|
|
1778
1790
|
};
|
|
1779
1791
|
_emitter7 = new WeakMap();
|
|
1780
1792
|
_session = new WeakMap();
|
package/dist/cjs/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { N as NotificationFilter } from './novu-
|
|
2
|
-
export { k as Action, A as ActionTypeEnum, m as ChannelPreference, f as ChannelType, C as CtaType, E as EventHandler, a as Events, F as FiltersCountResponse, q as IPreferenceOverride, I as InboxNotification, L as ListNotificationsResponse, i as MessageAction, M as MessageButton, u as Notification, e as NotificationActionStatus, d as NotificationButton, c as NotificationStatus, b as Novu, w as NovuError, s as NovuOptions, n as PaginatedResponse, v as Preference, P as PreferenceLevel, g as PreferenceOverrideSource, p as PreferenceOverrideSourceEnum, o as PreferencesResponse, t as Prettify, R as Redirect, r as Result, h as Session, S as SocketEventNames, j as Subscriber, T as TODO, W as WebSocketEvent, l as Workflow } from './novu-
|
|
1
|
+
import { N as NotificationFilter } from './novu-CalZFixf.js';
|
|
2
|
+
export { k as Action, A as ActionTypeEnum, m as ChannelPreference, f as ChannelType, C as CtaType, E as EventHandler, a as Events, F as FiltersCountResponse, q as IPreferenceOverride, I as InboxNotification, L as ListNotificationsResponse, i as MessageAction, M as MessageButton, u as Notification, e as NotificationActionStatus, d as NotificationButton, c as NotificationStatus, b as Novu, w as NovuError, s as NovuOptions, n as PaginatedResponse, v as Preference, P as PreferenceLevel, g as PreferenceOverrideSource, p as PreferenceOverrideSourceEnum, o as PreferencesResponse, t as Prettify, R as Redirect, r as Result, h as Session, S as SocketEventNames, j as Subscriber, T as TODO, W as WebSocketEvent, l as Workflow } from './novu-CalZFixf.js';
|
|
3
3
|
|
|
4
4
|
declare const areTagsEqual: (tags1?: string[], tags2?: string[]) => boolean;
|
|
5
5
|
declare const isSameFilter: (filter1: NotificationFilter, filter2: NotificationFilter) => boolean;
|
package/dist/cjs/index.js
CHANGED
|
@@ -1,59 +1,59 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkBD5JCEYL_js = require('./chunk-BD5JCEYL.js');
|
|
4
4
|
require('./chunk-7B52C2XE.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
Object.defineProperty(exports, "ActionTypeEnum", {
|
|
9
9
|
enumerable: true,
|
|
10
|
-
get: function () { return
|
|
10
|
+
get: function () { return chunkBD5JCEYL_js.ActionTypeEnum; }
|
|
11
11
|
});
|
|
12
12
|
Object.defineProperty(exports, "ChannelType", {
|
|
13
13
|
enumerable: true,
|
|
14
|
-
get: function () { return
|
|
14
|
+
get: function () { return chunkBD5JCEYL_js.ChannelType; }
|
|
15
15
|
});
|
|
16
16
|
Object.defineProperty(exports, "CtaType", {
|
|
17
17
|
enumerable: true,
|
|
18
|
-
get: function () { return
|
|
18
|
+
get: function () { return chunkBD5JCEYL_js.CtaType; }
|
|
19
19
|
});
|
|
20
20
|
Object.defineProperty(exports, "NotificationActionStatus", {
|
|
21
21
|
enumerable: true,
|
|
22
|
-
get: function () { return
|
|
22
|
+
get: function () { return chunkBD5JCEYL_js.NotificationActionStatus; }
|
|
23
23
|
});
|
|
24
24
|
Object.defineProperty(exports, "NotificationButton", {
|
|
25
25
|
enumerable: true,
|
|
26
|
-
get: function () { return
|
|
26
|
+
get: function () { return chunkBD5JCEYL_js.NotificationButton; }
|
|
27
27
|
});
|
|
28
28
|
Object.defineProperty(exports, "NotificationStatus", {
|
|
29
29
|
enumerable: true,
|
|
30
|
-
get: function () { return
|
|
30
|
+
get: function () { return chunkBD5JCEYL_js.NotificationStatus; }
|
|
31
31
|
});
|
|
32
32
|
Object.defineProperty(exports, "Novu", {
|
|
33
33
|
enumerable: true,
|
|
34
|
-
get: function () { return
|
|
34
|
+
get: function () { return chunkBD5JCEYL_js.Novu; }
|
|
35
35
|
});
|
|
36
36
|
Object.defineProperty(exports, "PreferenceLevel", {
|
|
37
37
|
enumerable: true,
|
|
38
|
-
get: function () { return
|
|
38
|
+
get: function () { return chunkBD5JCEYL_js.PreferenceLevel; }
|
|
39
39
|
});
|
|
40
40
|
Object.defineProperty(exports, "PreferenceOverrideSource", {
|
|
41
41
|
enumerable: true,
|
|
42
|
-
get: function () { return
|
|
42
|
+
get: function () { return chunkBD5JCEYL_js.PreferenceOverrideSource; }
|
|
43
43
|
});
|
|
44
44
|
Object.defineProperty(exports, "PreferenceOverrideSourceEnum", {
|
|
45
45
|
enumerable: true,
|
|
46
|
-
get: function () { return
|
|
46
|
+
get: function () { return chunkBD5JCEYL_js.PreferenceOverrideSourceEnum; }
|
|
47
47
|
});
|
|
48
48
|
Object.defineProperty(exports, "WebSocketEvent", {
|
|
49
49
|
enumerable: true,
|
|
50
|
-
get: function () { return
|
|
50
|
+
get: function () { return chunkBD5JCEYL_js.WebSocketEvent; }
|
|
51
51
|
});
|
|
52
52
|
Object.defineProperty(exports, "areTagsEqual", {
|
|
53
53
|
enumerable: true,
|
|
54
|
-
get: function () { return
|
|
54
|
+
get: function () { return chunkBD5JCEYL_js.areTagsEqual; }
|
|
55
55
|
});
|
|
56
56
|
Object.defineProperty(exports, "isSameFilter", {
|
|
57
57
|
enumerable: true,
|
|
58
|
-
get: function () { return
|
|
58
|
+
get: function () { return chunkBD5JCEYL_js.isSameFilter; }
|
|
59
59
|
});
|
|
@@ -96,6 +96,7 @@ type Session = {
|
|
|
96
96
|
token: string;
|
|
97
97
|
totalUnreadCount: number;
|
|
98
98
|
removeNovuBranding: boolean;
|
|
99
|
+
isDevelopmentMode: boolean;
|
|
99
100
|
};
|
|
100
101
|
type MessageButton = {
|
|
101
102
|
type: NotificationButton;
|
|
@@ -564,6 +565,8 @@ declare class Novu implements Pick<NovuEventEmitter, 'on'> {
|
|
|
564
565
|
* Use the cleanup function returned by the "on" method instead.
|
|
565
566
|
*/
|
|
566
567
|
off: <Key extends EventNames>(eventName: Key, listener: EventHandler<Events[Key]>) => void;
|
|
568
|
+
get applicationIdentifier(): string;
|
|
569
|
+
get subscriberId(): string;
|
|
567
570
|
constructor(options: NovuOptions);
|
|
568
571
|
}
|
|
569
572
|
|
package/dist/cjs/themes/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { u as Notification, N as NotificationFilter, s as NovuOptions, b as Novu } from './novu-
|
|
1
|
+
import { u as Notification, N as NotificationFilter, s as NovuOptions, b as Novu } from './novu-CalZFixf.js';
|
|
2
2
|
|
|
3
3
|
declare const appearanceKeys: readonly ["button", "icon", "popoverContent", "popoverTrigger", "dropdownContent", "dropdownTrigger", "dropdownItem", "dropdownItemLabel", "dropdownItemLabelContainer", "dropdownItemLeft__icon", "dropdownItemRight__icon", "dropdownItem__icon", "collapsible", "tooltipContent", "tooltipTrigger", "back__button", "skeletonText", "skeletonAvatar", "skeletonSwitch", "skeletonSwitchThumb", "tabsRoot", "tabsList", "tabsContent", "tabsTrigger", "dots", "root", "bellIcon", "bellContainer", "bellDot", "preferences__button", "preferencesContainer", "inboxHeader", "loading", "inboxContent", "inbox__popoverTrigger", "inbox__popoverContent", "notificationListContainer", "notificationList", "notificationListEmptyNoticeContainer", "notificationListEmptyNoticeOverlay", "notificationListEmptyNoticeIcon", "notificationListEmptyNotice", "notificationList__skeleton", "notificationList__skeletonContent", "notificationList__skeletonItem", "notificationList__skeletonAvatar", "notificationList__skeletonText", "notificationListNewNotificationsNotice__button", "notification", "notificationContent", "notificationTextContainer", "notificationDot", "notificationSubject", "notificationSubject__strong", "notificationBody", "notificationBody__strong", "notificationBodyContainer", "notificationImage", "notificationImageLoadingFallback", "notificationDate", "notificationDateActionsContainer", "notificationDefaultActions", "notificationCustomActions", "notificationPrimaryAction__button", "notificationSecondaryAction__button", "notificationRead__button", "notificationUnread__button", "notificationArchive__button", "notificationUnarchive__button", "notificationRead__icon", "notificationUnread__icon", "notificationArchive__icon", "notificationUnarchive__icon", "notificationsTabs__tabsRoot", "notificationsTabs__tabsList", "notificationsTabs__tabsContent", "notificationsTabs__tabsTrigger", "notificationsTabsTriggerLabel", "notificationsTabsTriggerCount", "inboxStatus__title", "inboxStatus__dropdownTrigger", "inboxStatus__dropdownContent", "inboxStatus__dropdownItem", "inboxStatus__dropdownItemLabel", "inboxStatus__dropdownItemLabelContainer", "inboxStatus__dropdownItemLeft__icon", "inboxStatus__dropdownItemRight__icon", "inboxStatus__dropdownItem__icon", "inboxStatus__dropdownItemCheck__icon", "moreActionsContainer", "moreActions__dropdownTrigger", "moreActions__dropdownContent", "moreActions__dropdownItem", "moreActions__dropdownItemLabel", "moreActions__dropdownItemLeft__icon", "moreActions__dots", "moreTabs__button", "moreTabs__icon", "moreTabs__dropdownTrigger", "moreTabs__dropdownContent", "moreTabs__dropdownItem", "moreTabs__dropdownItemLabel", "moreTabs__dropdownItemRight__icon", "workflowContainer", "workflowLabel", "workflowLabelHeader", "workflowLabelContainer", "workflowContainerDisabledNotice", "workflowLabelDisabled__icon", "workflowContainerRight__icon", "workflowArrow__icon", "workflowDescription", "channelContainer", "channelIconContainer", "channel__icon", "channelsContainerCollapsible", "channelsContainer", "channelLabel", "channelLabelContainer", "channelName", "channelSwitchContainer", "channelSwitch", "channelSwitchThumb", "preferencesHeader", "preferencesHeader__back__button", "preferencesHeader__back__button__icon", "preferencesHeader__title", "preferencesHeader__icon", "preferencesListEmptyNoticeContainer", "preferencesListEmptyNotice", "preferencesList__skeleton", "preferencesList__skeletonContent", "preferencesList__skeletonItem", "preferencesList__skeletonIcon", "preferencesList__skeletonSwitch", "preferencesList__skeletonSwitchThumb", "preferencesList__skeletonText", "strong"];
|
|
4
4
|
|
|
@@ -68,6 +68,7 @@ type Variables = {
|
|
|
68
68
|
colorRing?: string;
|
|
69
69
|
fontSize?: string;
|
|
70
70
|
borderRadius?: string;
|
|
71
|
+
colorStripes?: string;
|
|
71
72
|
};
|
|
72
73
|
type AppearanceKey = (typeof appearanceKeys)[number];
|
|
73
74
|
type Elements = Partial<Record<AppearanceKey, ElementStyles>>;
|
package/dist/cjs/ui/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { s as NovuOptions } from '../novu-
|
|
2
|
-
export { u as Notification } from '../novu-
|
|
3
|
-
import { B as BellRenderer, N as NotificationClickHandler, a as NotificationActionClickHandler, b as NotificationRenderer, S as SubjectRenderer, c as BodyRenderer, d as NovuProviderProps, e as BaseNovuProviderProps, A as Appearance, L as Localization, T as Tab, P as PreferencesFilter, R as RouterPush } from '../types-
|
|
4
|
-
export { f as AppearanceKey, C as CSSProperties, E as ElementStyles, g as Elements, j as LocalizationKey, i as NotificationStatus, h as Theme, V as Variables } from '../types-
|
|
1
|
+
import { s as NovuOptions } from '../novu-CalZFixf.js';
|
|
2
|
+
export { u as Notification } from '../novu-CalZFixf.js';
|
|
3
|
+
import { B as BellRenderer, N as NotificationClickHandler, a as NotificationActionClickHandler, b as NotificationRenderer, S as SubjectRenderer, c as BodyRenderer, d as NovuProviderProps, e as BaseNovuProviderProps, A as Appearance, L as Localization, T as Tab, P as PreferencesFilter, R as RouterPush } from '../types-lO51eBKl.js';
|
|
4
|
+
export { f as AppearanceKey, C as CSSProperties, E as ElementStyles, g as Elements, j as LocalizationKey, i as NotificationStatus, h as Theme, V as Variables } from '../types-lO51eBKl.js';
|
|
5
5
|
import { Placement, OffsetOptions } from '@floating-ui/dom';
|
|
6
6
|
import * as solid_js from 'solid-js';
|
|
7
7
|
import { ComponentProps } from 'solid-js';
|