@notificationapi/react 1.8.0 → 1.10.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/dist/assets/Badge.js +57 -62
- package/dist/assets/Button.js +4 -3
- package/dist/assets/ButtonBase.js +6 -6
- package/dist/assets/DefaultPropsProvider.js +1 -1
- package/dist/assets/Divider.js +22 -19
- package/dist/assets/Grow.js +1512 -114
- package/dist/assets/IconButton.js +1 -1
- package/dist/assets/Modal.js +2 -2
- package/dist/assets/Notification.js +1 -1
- package/dist/assets/Paper.js +4 -4
- package/dist/assets/Popover.js +1 -1
- package/dist/assets/Portal.js +2 -2
- package/dist/assets/Stack.js +1 -1
- package/dist/assets/createTheme.js +2 -2
- package/dist/assets/useControlled.js +49 -0
- package/dist/assets/usePreviousProps.js +10 -0
- package/dist/assets/useTheme.js +1 -1
- package/dist/assets/utils.js +3 -3
- package/dist/components/Notifications/Inbox.js +4 -4
- package/dist/components/Notifications/InboxHeader.js +359 -1754
- package/dist/components/Preferences/NotificationPreferencesPopup.js +1 -1
- package/dist/components/Preferences/PreferenceInput.js +3 -3
- package/dist/components/Preferences/Preferences.js +2 -2
- package/dist/components/Slack/SlackConnect.js +4664 -2028
- package/package.json +2 -2
- package/dist/assets/dividerClasses.js +0 -57
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as c from "react";
|
|
2
|
-
import { g as z, e as a,
|
|
2
|
+
import { g as z, e as a, b as g, P as e } from "./createTheme.js";
|
|
3
3
|
import { g as R, s as I, m as f, u as O, c as C, a as h } from "./DefaultPropsProvider.js";
|
|
4
4
|
import { c as y } from "./createSimplePaletteValueFilter.js";
|
|
5
5
|
import { jsx as T } from "react/jsx-runtime";
|
package/dist/assets/Modal.js
CHANGED
|
@@ -3,10 +3,10 @@ import { P as e, g as le } from "./createTheme.js";
|
|
|
3
3
|
import { g as de, s as J, u as ue, c as X, a as fe, m as ke } from "./DefaultPropsProvider.js";
|
|
4
4
|
import { o as j, e as Q, g as pe, P as Pe, H as Ne } from "./Portal.js";
|
|
5
5
|
import { u as Y, e as Ce } from "./resolveComponentProps.js";
|
|
6
|
-
import { u as Se,
|
|
6
|
+
import { u as Se, a as H, d as oe } from "./ButtonBase.js";
|
|
7
7
|
import { c as re } from "./Stack.js";
|
|
8
8
|
import { jsx as A, jsxs as be } from "react/jsx-runtime";
|
|
9
|
-
import { T as we,
|
|
9
|
+
import { T as we, a as Ie, g as se } from "./utils.js";
|
|
10
10
|
import { e as Oe } from "./exactProp.js";
|
|
11
11
|
function _(t) {
|
|
12
12
|
return j(t).defaultView || window;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _, jsxs as ut } from "react/jsx-runtime";
|
|
2
2
|
import { g as ai, s as $t, m as ui, u as li, c as ci, a as fi, n as hi } from "./DefaultPropsProvider.js";
|
|
3
3
|
import { getThemeColors as pi } from "../utils/theme.js";
|
|
4
|
-
import {
|
|
4
|
+
import { a as di, u as mi } from "./ButtonBase.js";
|
|
5
5
|
import * as mt from "react";
|
|
6
6
|
import De, { useMemo as ne, useCallback as gi, useRef as Kt, useState as yi, useEffect as er } from "react";
|
|
7
7
|
import { g as wi, P as p, v as dn, q as vi } from "./createTheme.js";
|
package/dist/assets/Paper.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import * as P from "react";
|
|
2
|
-
import { g as
|
|
3
|
-
import { g as
|
|
2
|
+
import { g as b, b as u, P as a, d as f } from "./createTheme.js";
|
|
3
|
+
import { g as h, s as g, m as w, u as T, c as $, a as x } from "./DefaultPropsProvider.js";
|
|
4
4
|
import { u as O, c as C } from "./ButtonBase.js";
|
|
5
5
|
import { jsx as N } from "react/jsx-runtime";
|
|
6
6
|
import { i as R } from "./integerPropType.js";
|
|
7
7
|
function j(e) {
|
|
8
|
-
return
|
|
8
|
+
return b("MuiPaper", e);
|
|
9
9
|
}
|
|
10
|
-
|
|
10
|
+
h("MuiPaper", ["root", "rounded", "outlined", "elevation", "elevation0", "elevation1", "elevation2", "elevation3", "elevation4", "elevation5", "elevation6", "elevation7", "elevation8", "elevation9", "elevation10", "elevation11", "elevation12", "elevation13", "elevation14", "elevation15", "elevation16", "elevation17", "elevation18", "elevation19", "elevation20", "elevation21", "elevation22", "elevation23", "elevation24"]);
|
|
11
11
|
const E = (e) => {
|
|
12
12
|
const {
|
|
13
13
|
square: o,
|
package/dist/assets/Popover.js
CHANGED
|
@@ -2,7 +2,7 @@ import * as c from "react";
|
|
|
2
2
|
import { g as Pe, P as e } from "./createTheme.js";
|
|
3
3
|
import { g as ve, s as te, u as ye, c as Y, a as be } from "./DefaultPropsProvider.js";
|
|
4
4
|
import { i as Te } from "./List.js";
|
|
5
|
-
import {
|
|
5
|
+
import { a as X, r as Ee, c as Oe, e as Re } from "./ButtonBase.js";
|
|
6
6
|
import { jsx as z } from "react/jsx-runtime";
|
|
7
7
|
import { M as we, o as J } from "./Modal.js";
|
|
8
8
|
import { P as xe } from "./Paper.js";
|
package/dist/assets/Portal.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { P as c } from "./createTheme.js";
|
|
2
|
-
import { c as m,
|
|
2
|
+
import { c as m, f } from "./ButtonBase.js";
|
|
3
3
|
import * as u from "react";
|
|
4
|
-
import {
|
|
4
|
+
import { r as P } from "./utils.js";
|
|
5
5
|
import { u as T, s as d } from "./resolveComponentProps.js";
|
|
6
6
|
import { e as h } from "./exactProp.js";
|
|
7
7
|
function R(e) {
|
package/dist/assets/Stack.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as l from "react";
|
|
2
|
-
import { P as e,
|
|
2
|
+
import { P as e, a as S, h as g, r as m, j as V, k as N, m as D, g as E, l as h } from "./createTheme.js";
|
|
3
3
|
import { e as R, c as B, a as M, s as w, u as G } from "./DefaultPropsProvider.js";
|
|
4
4
|
import { jsx as U } from "react/jsx-runtime";
|
|
5
5
|
import { e as _ } from "./Typography.js";
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import * as n from "react";
|
|
2
|
+
let l = 0;
|
|
3
|
+
function h(e) {
|
|
4
|
+
const [t, o] = n.useState(e), u = e || t;
|
|
5
|
+
return n.useEffect(() => {
|
|
6
|
+
t == null && (l += 1, o(`mui-${l}`));
|
|
7
|
+
}, [t]), u;
|
|
8
|
+
}
|
|
9
|
+
const I = {
|
|
10
|
+
...n
|
|
11
|
+
}, r = I.useId;
|
|
12
|
+
function g(e) {
|
|
13
|
+
if (r !== void 0) {
|
|
14
|
+
const t = r();
|
|
15
|
+
return e ?? t;
|
|
16
|
+
}
|
|
17
|
+
return h(e);
|
|
18
|
+
}
|
|
19
|
+
function m({
|
|
20
|
+
controlled: e,
|
|
21
|
+
default: t,
|
|
22
|
+
name: o,
|
|
23
|
+
state: u = "value"
|
|
24
|
+
}) {
|
|
25
|
+
const {
|
|
26
|
+
current: s
|
|
27
|
+
} = n.useRef(e !== void 0), [i, f] = n.useState(t), a = s ? e : i;
|
|
28
|
+
if (process.env.NODE_ENV !== "production") {
|
|
29
|
+
n.useEffect(() => {
|
|
30
|
+
s !== (e !== void 0) && console.error([`MUI: A component is changing the ${s ? "" : "un"}controlled ${u} state of ${o} to be ${s ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${o} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(`
|
|
31
|
+
`));
|
|
32
|
+
}, [u, o, e]);
|
|
33
|
+
const {
|
|
34
|
+
current: c
|
|
35
|
+
} = n.useRef(t);
|
|
36
|
+
n.useEffect(() => {
|
|
37
|
+
!s && !Object.is(c, t) && console.error([`MUI: A component is changing the default ${u} state of an uncontrolled ${o} after being initialized. To suppress this warning opt to use a controlled ${o}.`].join(`
|
|
38
|
+
`));
|
|
39
|
+
}, [JSON.stringify(t)]);
|
|
40
|
+
}
|
|
41
|
+
const d = n.useCallback((c) => {
|
|
42
|
+
s || f(c);
|
|
43
|
+
}, []);
|
|
44
|
+
return [a, d];
|
|
45
|
+
}
|
|
46
|
+
export {
|
|
47
|
+
g as a,
|
|
48
|
+
m as u
|
|
49
|
+
};
|
package/dist/assets/useTheme.js
CHANGED
package/dist/assets/utils.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as k, g as I,
|
|
1
|
+
import { _ as k, g as I, h as A } from "./ButtonBase.js";
|
|
2
2
|
import { q as U, P as c } from "./createTheme.js";
|
|
3
3
|
import T from "react";
|
|
4
4
|
var N = { exports: {} }, y = {};
|
|
@@ -737,7 +737,7 @@ function Y(p, g) {
|
|
|
737
737
|
export {
|
|
738
738
|
D as R,
|
|
739
739
|
E as T,
|
|
740
|
-
|
|
740
|
+
W as a,
|
|
741
741
|
Y as g,
|
|
742
|
-
|
|
742
|
+
G as r
|
|
743
743
|
};
|
|
@@ -7,13 +7,13 @@ import { Filter as Yt } from "./interface.js";
|
|
|
7
7
|
import { NotificationAPIContext as nn } from "../Provider/context.js";
|
|
8
8
|
import { DefaultEmptyComponent as on } from "./DefaultEmpty.js";
|
|
9
9
|
import { g as ze, s as he, u as Je, c as _e, a as Qe, m as et, _ as Ct } from "../../assets/DefaultPropsProvider.js";
|
|
10
|
-
import { c as an, e as sn, B as cn,
|
|
11
|
-
import { g as tt, P as c,
|
|
12
|
-
import { R as Gt,
|
|
10
|
+
import { c as an, e as sn, B as cn, a as We, g as ln, j as un, k as fn, u as dn } from "../../assets/ButtonBase.js";
|
|
11
|
+
import { g as tt, P as c, b as we, e as xe, q as vn } from "../../assets/createTheme.js";
|
|
12
|
+
import { R as Gt, r as Ut } from "../../assets/utils.js";
|
|
13
13
|
import { getThemeColors as pn } from "../../utils/theme.js";
|
|
14
14
|
import { b as Ge, a as vr, i as Xt, L as Kt } from "../../assets/List.js";
|
|
15
15
|
import { u as hn } from "../../assets/resolveComponentProps.js";
|
|
16
|
-
import {
|
|
16
|
+
import { u as mn } from "../../assets/useControlled.js";
|
|
17
17
|
import { i as Ae } from "../../assets/integerPropType.js";
|
|
18
18
|
import { u as gn } from "../../assets/index.js";
|
|
19
19
|
import { c as qt } from "../../assets/createSimplePaletteValueFilter.js";
|