everest-npm-features 0.0.61 → 0.0.63
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/ArrowBack-DEJjwfp0.js +8 -0
- package/dist/{Cancel-4lT7GZUA.js → Cancel-pHQsCjtK.js} +1 -1
- package/dist/{Close-CNwiMz_O.js → Close-DSxLLo08.js} +1 -1
- package/dist/{ContentCopy-coPwrEuz.js → ContentCopy-D0C0zbQj.js} +1 -1
- package/dist/{Delete-jpMstGIF.js → Delete-Bj8zmXnh.js} +1 -1
- package/dist/{ErrorOutline-CPQcnl2b.js → ErrorOutline-Bt7P4ChN.js} +1 -1
- package/dist/{FileDownload-Bt3R_NBr.js → FileDownload-DqREXR3D.js} +1 -1
- package/dist/{Info-BVeUSPyk.js → Info-DOoRR7sR.js} +1 -1
- package/dist/PlayArrow-71FP5PzJ.js +13 -0
- package/dist/Portal-BeS9yJCZ.js +968 -0
- package/dist/assets/styles.css +1 -1
- package/dist/{auth-Cwq6nfwY.js → auth-BBeOw4mt.js} +11 -11
- package/dist/{bank-C4pmTe--.js → bank-HVb0GFsa.js} +1 -1
- package/dist/components/RocketRamp/MinimalKyc/form.js +46 -51
- package/dist/components/RocketRamp/MinimalKyc/index.js +6 -6
- package/dist/components/RocketRamp/Player/Buy/cardPayment.js +6 -8
- package/dist/components/RocketRamp/Player/Buy/confirmTransaction.js +5 -8
- package/dist/components/RocketRamp/Player/Buy/form.js +8 -17
- package/dist/components/RocketRamp/Player/Buy/index.js +6 -6
- package/dist/components/RocketRamp/Player/Dashboard/balance.js +20 -26
- package/dist/components/RocketRamp/Player/Dashboard/index.js +4 -4
- package/dist/components/RocketRamp/Player/Dashboard/transaction.js +13 -16
- package/dist/components/RocketRamp/Player/Sell/confirmTransaction.js +6 -11
- package/dist/components/RocketRamp/Player/Sell/form.js +8 -17
- package/dist/components/RocketRamp/Player/Sell/index.js +14 -13
- package/dist/components/RocketRamp/Player/SignIn/index.js +23 -25
- package/dist/components/RocketRamp/Player/SignIn/loginForm.js +33 -35
- package/dist/components/RocketRamp/Player/SignIn/otpForm.js +31 -33
- package/dist/components/RocketRamp/Player/SignUp/email.js +21 -23
- package/dist/components/RocketRamp/Player/SignUp/index.js +49 -52
- package/dist/components/RocketRamp/Player/SignUp/personalInfo.js +68 -74
- package/dist/components/RocketRamp/Player/SignUp/summary.js +23 -25
- package/dist/components/RocketRamp/Player/SignUp/validateEmail.js +23 -25
- package/dist/components/RocketRamp/ResetPassword/index.js +23 -25
- package/dist/components/RocketRamp/Shared/Button/index.js +16 -17
- package/dist/components/RocketRamp/Shared/Input/index.js +27 -30
- package/dist/components/RocketRamp/Shared/backBtn.js +10 -11
- package/dist/components/RocketRamp/Shared/transactionItem.js +40 -45
- package/dist/components/RocketRamp/Store/Dashboard/balance.js +12 -17
- package/dist/components/RocketRamp/Store/Dashboard/index.js +11 -12
- package/dist/components/RocketRamp/Store/Dashboard/stats.js +12 -17
- package/dist/components/RocketRamp/Store/Dashboard/transaction.js +13 -16
- package/dist/components/RocketRamp/Store/SignUp/index.js +53 -56
- package/dist/components/RocketRamp/Store/SignUp/personalInfo.js +48 -54
- package/dist/components/RocketRamp/Store/SignUp/storeInfo.js +33 -37
- package/dist/components/RocketRamp/Store/SignUp/summary.js +21 -23
- package/dist/components/RocketRamp/Store/SignUp/validateEmail.js +23 -25
- package/dist/components/RocketRamp/Transactions/index.js +23 -24
- package/dist/components/Shared/FullKyc/countryList.js +15 -17
- package/dist/components/Shared/FullKyc/edd.js +51 -53
- package/dist/components/Shared/FullKyc/index.js +13 -11
- package/dist/components/Shared/FullKyc/pep.js +35 -43
- package/dist/components/Shared/FullKyc/personalDetails.js +6 -6
- package/dist/components/Shared/FullKyc/userInfo.js +8 -13
- package/dist/components/Shared/HistoryItem/index.js +43 -48
- package/dist/components/Shared/Incode/index.js +31 -35
- package/dist/components/Shared/MinimalKyc/index.js +60 -65
- package/dist/components/Shared/Sumsub/index.js +75 -62
- package/dist/components/Shared/loader.js +4 -5
- package/dist/components/Shared/tooltip.js +2 -2
- package/dist/components/Shared/transition.js +4 -4
- package/dist/components/Wallet/Account/createIban.d.ts +1 -2
- package/dist/components/Wallet/Account/createIban.js +324 -102
- package/dist/components/Wallet/Account/eWallet.js +37 -43
- package/dist/components/Wallet/Account/iban.d.ts +1 -0
- package/dist/components/Wallet/Account/iban.js +41 -45
- package/dist/components/Wallet/Account/ibanItem.js +70 -75
- package/dist/components/Wallet/Account/index.d.ts +1 -0
- package/dist/components/Wallet/Account/index.js +113 -118
- package/dist/components/Wallet/Account/sendIban.js +79 -88
- package/dist/components/Wallet/Buy/confirmTransaction.js +9 -11
- package/dist/components/Wallet/Buy/form.js +8 -18
- package/dist/components/Wallet/Buy/index.js +6 -6
- package/dist/components/Wallet/Deposit/index.js +16 -18
- package/dist/components/Wallet/EnterpriseKyc/edd.js +32 -33
- package/dist/components/Wallet/EnterpriseKyc/index.js +73 -77
- package/dist/components/Wallet/EnterpriseKyc/individualKyc.js +23 -26
- package/dist/components/Wallet/EnterpriseKyc/kybIntro.js +5 -7
- package/dist/components/Wallet/EnterpriseKyc/kybTerms.js +1 -1
- package/dist/components/Wallet/EnterpriseKyc/kycType.js +23 -26
- package/dist/components/Wallet/EnterpriseKyc/orgDetails.js +33 -34
- package/dist/components/Wallet/EnterpriseKyc/orgInfo.js +3591 -1482
- package/dist/components/Wallet/EnterpriseKyc/success.js +3 -4
- package/dist/components/Wallet/EnterpriseKyc/verify.js +22 -22
- package/dist/components/Wallet/History/index.js +23 -797
- package/dist/components/Wallet/Home/index.js +13 -14
- package/dist/components/Wallet/MoveToEthereumOrEverChain/index.js +122 -126
- package/dist/components/Wallet/Portfolio/dropdown.js +25 -30
- package/dist/components/Wallet/Portfolio/index.js +48 -51
- package/dist/components/Wallet/Portfolio/tokenRow.js +3 -4
- package/dist/components/Wallet/Profile/documents.js +164 -176
- package/dist/components/Wallet/Profile/index.js +39 -44
- package/dist/components/Wallet/Profile/storage.js +39 -47
- package/dist/components/Wallet/Receive/index.js +32 -37
- package/dist/components/Wallet/Sell/confirmTransaction.js +8 -10
- package/dist/components/Wallet/Sell/form.js +8 -18
- package/dist/components/Wallet/Sell/index.js +6 -6
- package/dist/components/Wallet/Send/index.js +98 -107
- package/dist/components/Wallet/Shared/Auth/emailForm.js +13 -15
- package/dist/components/Wallet/Shared/Auth/otpForm.js +9 -356
- package/dist/components/Wallet/Shared/BankSelect/index.js +45 -49
- package/dist/components/Wallet/Shared/CardCorp/index.js +18 -19
- package/dist/components/Wallet/Shared/CardPayment/index.js +14 -16
- package/dist/components/Wallet/Shared/ConnectWallet/index.js +22 -28
- package/dist/components/Wallet/Shared/Container/index.d.ts +2 -1
- package/dist/components/Wallet/Shared/Container/index.js +11 -11
- package/dist/components/Wallet/Shared/Input/index.js +3 -3
- package/dist/components/Wallet/Shared/Keyboard/keyboard.js +29 -30
- package/dist/components/Wallet/Shared/Order/paymentButton.js +13 -14
- package/dist/components/Wallet/Shared/TokenModal/index.js +55 -63
- package/dist/components/Wallet/Shared/TokenModal/tokenGrid.js +11 -13
- package/dist/components/Wallet/Shared/addBank.js +41 -45
- package/dist/components/Wallet/Shared/appButton.js +11 -15
- package/dist/components/Wallet/Shared/backBtn.js +8 -9
- package/dist/components/Wallet/Shared/button.js +7 -7
- package/dist/components/Wallet/Shared/connectPlaidBank.js +16 -17
- package/dist/components/Wallet/Shared/inputField.js +5 -5
- package/dist/components/Wallet/Shared/manualSend.js +9 -13
- package/dist/components/Wallet/Shared/noData.js +4 -5
- package/dist/components/Wallet/Shared/pin.js +25 -27
- package/dist/components/Wallet/Shared/radioButton.js +39 -5
- package/dist/components/Wallet/Shared/step.js +12 -13
- package/dist/components/Wallet/Shared/timer.js +1 -1
- package/dist/components/Wallet/SignIn/index.js +17 -17
- package/dist/components/Wallet/SignUp/index.js +63 -153
- package/dist/components/Wallet/SignUp/terms.js +1 -1
- package/dist/components/Wallet/Stake/gems/index.js +71 -69
- package/dist/components/Wallet/Stake/id/index.js +77 -84
- package/dist/components/Wallet/Stake/index.js +65 -68
- package/dist/components/Wallet/Swap/form.js +11 -20
- package/dist/components/Wallet/Swap/index.js +5 -5
- package/dist/components/Wallet/SwapAndUniSwap/index.js +3 -5
- package/dist/components/Wallet/Withdraw/bankSelect.js +41 -45
- package/dist/components/Wallet/Withdraw/confirmTransaction.js +5 -8
- package/dist/components/Wallet/Withdraw/form.js +6 -17
- package/dist/components/Wallet/Withdraw/index.js +5 -5
- package/dist/{constants-DrmtdI1J.js → constants-DX0YBtP2.js} +19 -19
- package/dist/{createSvgIcon-Cuzqm90l.js → createSvgIcon-B28GrUxG.js} +41 -45
- package/dist/{cryptoAssets-DyGDknvq.js → cryptoAssets-B8rAI7pp.js} +1 -1
- package/dist/hoc/withThemeProvider.js +5 -732
- package/dist/hooks/useDialog/index.js +22 -23
- package/dist/hooks/useRrDialog/index.js +43 -46
- package/dist/hooks/useSnackBar.js +24 -696
- package/dist/icons/buyIcon.js +1 -1
- package/dist/icons/canceledBuyIcon.js +1 -1
- package/dist/icons/canceledRedeemIcon.js +1 -1
- package/dist/icons/failedBuyIcon.js +2 -2
- package/dist/icons/failedRedeemIcon.js +2 -2
- package/dist/icons/pendingBuyIcon.js +1 -1
- package/dist/icons/pendingRedeemIcon.js +1 -1
- package/dist/icons/redeemIcon.js +1 -1
- package/dist/{index-BbVpeed7.js → index-B4XvACQN.js} +89 -98
- package/dist/{index-BHG1bT4t.js → index-CTPMPwYK.js} +173 -182
- package/dist/{index-Dh_ahu-u.js → index-DkiQ8pRO.js} +95 -106
- package/dist/{index-C7Td5yoW.js → index-DuWW5roi.js} +175 -184
- package/dist/{index-eEBuSKOo.js → index-JY6-UKlX.js} +127 -137
- package/dist/{index-D2JWUPz8.js → index-_fiTunwZ.js} +154 -163
- package/dist/{index-B9oucF3r.js → index-bK14vCZw.js} +189 -198
- package/dist/{kyc-ksV3vBP_.js → kyc-BNMPoeHt.js} +1 -1
- package/dist/main.js +7 -7
- package/dist/memoTheme-DnE8lj0t.js +3481 -0
- package/dist/{order-DEp_Lmar.js → order-BXeCIvqC.js} +1 -1
- package/dist/otpForm-DeeegaX2.js +7378 -0
- package/dist/{stake-Ct7-_aWW.js → stake-BO2TYVJ7.js} +1 -1
- package/dist/styles.module-DFoezEqS.js +28 -0
- package/dist/{tokenRow-C-iMHhPj.js → tokenRow-BiNtHOKV.js} +20 -21
- package/dist/tooltip-BW0UyWw7.js +2129 -0
- package/dist/util/constants.d.ts +1 -0
- package/dist/util/constants.js +72 -71
- package/dist/{wallet-CauUBXou.js → wallet-BPXOp8UG.js} +1 -1
- package/package.json +6 -6
- package/dist/Alert-DzsbFW3-.js +0 -369
- package/dist/Autocomplete-CE-OI2t8.js +0 -2429
- package/dist/Avatar-1XklXr4O.js +0 -281
- package/dist/Backdrop-CioURPVG.js +0 -359
- package/dist/Box-B0YSYLco.js +0 -59
- package/dist/Button-Df4vgU24.js +0 -663
- package/dist/ButtonBase-DLF5c6wi.js +0 -870
- package/dist/CardContent-D9wTdpu-.js +0 -141
- package/dist/CircularProgress-xZA3lvba.js +0 -252
- package/dist/Close-CxzDL3J-.js +0 -9
- package/dist/Container-urNKV7hm.js +0 -181
- package/dist/DefaultPropsProvider-CeF7UYM9.js +0 -92
- package/dist/DefaultPropsProvider-oAu9El-f.js +0 -226
- package/dist/DialogContent-BMwlOnbW.js +0 -567
- package/dist/DialogTitle-CfS0bb2K.js +0 -70
- package/dist/Divider-BShhMFf4.js +0 -297
- package/dist/FilledInput-DuNqnPjc.js +0 -1292
- package/dist/FormControl-RtZDQMdA.js +0 -258
- package/dist/FormControlLabel-BliKW48y.js +0 -519
- package/dist/GlobalStyles-ChMhDfTS.js +0 -59
- package/dist/Grid-CFe3amXO.js +0 -410
- package/dist/Grow-CnGtel3u.js +0 -196
- package/dist/HTMLElementType-BrQSV2FE.js +0 -13
- package/dist/IconButton-DHm-hucF.js +0 -297
- package/dist/InputAdornment-DMiED3JH.js +0 -173
- package/dist/Link-DBA9Yifs.js +0 -266
- package/dist/ListItemIcon-CUcyTEEm.js +0 -84
- package/dist/Menu-DLYFFrEk.js +0 -1239
- package/dist/MenuItem-DUdYOJr4.js +0 -271
- package/dist/Modal-CFIQ_s3T.js +0 -743
- package/dist/Paper-Bgt2WXI6.js +0 -186
- package/dist/PlayArrow-Bjz9LxhD.js +0 -13
- package/dist/Popper-BBAoiZKn.js +0 -1409
- package/dist/Portal-BMAxiQwe.js +0 -69
- package/dist/RadioGroup-nvoSN0JN.js +0 -189
- package/dist/Select-CB5yWmyn.js +0 -1886
- package/dist/Slide-B9Nw0LZ4.js +0 -235
- package/dist/Stack-k55YTxET.js +0 -172
- package/dist/SwitchBase-C8zFyg_x.js +0 -318
- package/dist/TextField-DPpRUQe3.js +0 -978
- package/dist/TransitionGroupContext-CYRQkQ6k.js +0 -49
- package/dist/Typography-pAaje37G.js +0 -260
- package/dist/chainPropTypes-D9lkm76m.js +0 -8
- package/dist/clsx-BTaloaeC.js +0 -264
- package/dist/createChainedFunction-C0nujS3O.js +0 -9
- package/dist/createSimplePaletteValueFilter-B7--0ryQ.js +0 -17
- package/dist/createTheme-CD19zQB7.js +0 -3825
- package/dist/debounce-46wSf_lW.js +0 -15
- package/dist/defaultTheme-C35y5cLB.js +0 -5
- package/dist/dividerClasses-BDxa2gAa.js +0 -10
- package/dist/elementAcceptingRef-CqLvP78G.js +0 -391
- package/dist/elementTypeAcceptingRef-BdsMpCbS.js +0 -23
- package/dist/emotion-react.browser.esm-BIrDfk-B.js +0 -246
- package/dist/exactProp-C1Lmtwf_.js +0 -13
- package/dist/extendSxProp-B8UjbJ56.js +0 -37
- package/dist/generateUtilityClasses-BRiE4Guh.js +0 -10
- package/dist/index-B0Z-Gjno.js +0 -22
- package/dist/index-DUcLo3x5.js +0 -43
- package/dist/isFocusVisible-CPZqtjv2.js +0 -12
- package/dist/isHostComponent-kiaBvYVo.js +0 -6
- package/dist/isMuiElement-DnSE4qG4.js +0 -13
- package/dist/memoTheme-yHaPezod.js +0 -15
- package/dist/ownerWindow-CRgpWY6I.js +0 -7
- package/dist/radioButton-CzlYB0Lh.js +0 -402
- package/dist/refType-BsTH3qnM.js +0 -56
- package/dist/styles.module-CHPRGltL.js +0 -28
- package/dist/tooltip-3UvETWtS.js +0 -740
- package/dist/useControlled-nm4pBabJ.js +0 -31
- package/dist/useEnhancedEffect-CJGo-L3B.js +0 -5
- package/dist/useFormControl-CatNKXAi.js +0 -10
- package/dist/useId-CK6Kn3Tn.js +0 -21
- package/dist/useSlot-CW7SOYlh.js +0 -125
- package/dist/useSlotProps-BfEOwJvJ.js +0 -25
- package/dist/useTheme-BQJ5lp0i.js +0 -11
- package/dist/useTheme-S5_DHFsQ.js +0 -17
- package/dist/useThemeProps-DN9MjdTl.js +0 -29
|
@@ -1,716 +1,44 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import { e as G, u as L } from "../useSlot-CW7SOYlh.js";
|
|
7
|
-
import { u as ve } from "../useTheme-BQJ5lp0i.js";
|
|
8
|
-
import { s as A, u as K, c as Y } from "../DefaultPropsProvider-oAu9El-f.js";
|
|
9
|
-
import { m as J } from "../memoTheme-yHaPezod.js";
|
|
10
|
-
import { g as Q } from "../generateUtilityClasses-BRiE4Guh.js";
|
|
11
|
-
import { u as Ee } from "../TransitionGroupContext-CYRQkQ6k.js";
|
|
12
|
-
import { g as Te, e as Ce } from "../elementAcceptingRef-CqLvP78G.js";
|
|
13
|
-
import { o as H } from "../HTMLElementType-BrQSV2FE.js";
|
|
14
|
-
import { e as Se } from "../exactProp-C1Lmtwf_.js";
|
|
15
|
-
import { c as Pe } from "../clsx-BTaloaeC.js";
|
|
16
|
-
import { P as Oe } from "../Paper-Bgt2WXI6.js";
|
|
17
|
-
import { G as Re } from "../Grow-CnGtel3u.js";
|
|
18
|
-
import { A as Le } from "../Alert-DzsbFW3-.js";
|
|
19
|
-
import { S as D } from "../Slide-B9Nw0LZ4.js";
|
|
20
|
-
function V(t) {
|
|
21
|
-
return t.substring(2).toLowerCase();
|
|
22
|
-
}
|
|
23
|
-
function xe(t, n) {
|
|
24
|
-
return n.documentElement.clientWidth < t.clientX || n.documentElement.clientHeight < t.clientY;
|
|
25
|
-
}
|
|
26
|
-
function M(t) {
|
|
27
|
-
const {
|
|
28
|
-
children: n,
|
|
29
|
-
disableReactTree: l = !1,
|
|
30
|
-
mouseEvent: o = "onClick",
|
|
31
|
-
onClickAway: p,
|
|
32
|
-
touchEvent: f = "onTouchEnd"
|
|
33
|
-
} = t, h = y.useRef(!1), d = y.useRef(null), b = y.useRef(!1), k = y.useRef(!1);
|
|
34
|
-
y.useEffect(() => (setTimeout(() => {
|
|
35
|
-
b.current = !0;
|
|
36
|
-
}, 0), () => {
|
|
37
|
-
b.current = !1;
|
|
38
|
-
}), []);
|
|
39
|
-
const u = Ee(Te(n), d), m = N((i) => {
|
|
40
|
-
const a = k.current;
|
|
41
|
-
k.current = !1;
|
|
42
|
-
const g = H(d.current);
|
|
43
|
-
if (!b.current || !d.current || "clientX" in i && xe(i, g))
|
|
44
|
-
return;
|
|
45
|
-
if (h.current) {
|
|
46
|
-
h.current = !1;
|
|
47
|
-
return;
|
|
48
|
-
}
|
|
49
|
-
let r;
|
|
50
|
-
i.composedPath ? r = i.composedPath().includes(d.current) : r = !g.documentElement.contains(
|
|
51
|
-
// @ts-expect-error returns `false` as intended when not dispatched from a Node
|
|
52
|
-
i.target
|
|
53
|
-
) || d.current.contains(
|
|
54
|
-
// @ts-expect-error returns `false` as intended when not dispatched from a Node
|
|
55
|
-
i.target
|
|
56
|
-
), !r && (l || !a) && p(i);
|
|
57
|
-
}), S = (i) => (a) => {
|
|
58
|
-
k.current = !0;
|
|
59
|
-
const g = n.props[i];
|
|
60
|
-
g && g(a);
|
|
61
|
-
}, T = {
|
|
62
|
-
ref: u
|
|
63
|
-
};
|
|
64
|
-
return f !== !1 && (T[f] = S(f)), y.useEffect(() => {
|
|
65
|
-
if (f !== !1) {
|
|
66
|
-
const i = V(f), a = H(d.current), g = () => {
|
|
67
|
-
h.current = !0;
|
|
68
|
-
};
|
|
69
|
-
return a.addEventListener(i, m), a.addEventListener("touchmove", g), () => {
|
|
70
|
-
a.removeEventListener(i, m), a.removeEventListener("touchmove", g);
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
}, [m, f]), o !== !1 && (T[o] = S(o)), y.useEffect(() => {
|
|
74
|
-
if (o !== !1) {
|
|
75
|
-
const i = V(o), a = H(d.current);
|
|
76
|
-
return a.addEventListener(i, m), () => {
|
|
77
|
-
a.removeEventListener(i, m);
|
|
78
|
-
};
|
|
79
|
-
}
|
|
80
|
-
}, [m, o]), /* @__PURE__ */ y.cloneElement(n, T);
|
|
81
|
-
}
|
|
82
|
-
process.env.NODE_ENV !== "production" && (M.propTypes = {
|
|
83
|
-
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
84
|
-
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
85
|
-
// │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
|
|
86
|
-
// └─────────────────────────────────────────────────────────────────────┘
|
|
87
|
-
/**
|
|
88
|
-
* The wrapped element.
|
|
89
|
-
*/
|
|
90
|
-
children: Ce.isRequired,
|
|
91
|
-
/**
|
|
92
|
-
* If `true`, the React tree is ignored and only the DOM tree is considered.
|
|
93
|
-
* This prop changes how portaled elements are handled.
|
|
94
|
-
* @default false
|
|
95
|
-
*/
|
|
96
|
-
disableReactTree: e.bool,
|
|
97
|
-
/**
|
|
98
|
-
* The mouse event to listen to. You can disable the listener by providing `false`.
|
|
99
|
-
* @default 'onClick'
|
|
100
|
-
*/
|
|
101
|
-
mouseEvent: e.oneOf(["onClick", "onMouseDown", "onMouseUp", "onPointerDown", "onPointerUp", !1]),
|
|
102
|
-
/**
|
|
103
|
-
* Callback fired when a "click away" event is detected.
|
|
104
|
-
*/
|
|
105
|
-
onClickAway: e.func.isRequired,
|
|
106
|
-
/**
|
|
107
|
-
* The touch event to listen to. You can disable the listener by providing `false`.
|
|
108
|
-
* @default 'onTouchEnd'
|
|
109
|
-
*/
|
|
110
|
-
touchEvent: e.oneOf(["onTouchEnd", "onTouchStart", !1])
|
|
111
|
-
});
|
|
112
|
-
process.env.NODE_ENV !== "production" && (M.propTypes = Se(M.propTypes));
|
|
113
|
-
function Me(t = {}) {
|
|
114
|
-
const {
|
|
115
|
-
autoHideDuration: n = null,
|
|
116
|
-
disableWindowBlurListener: l = !1,
|
|
117
|
-
onClose: o,
|
|
118
|
-
open: p,
|
|
119
|
-
resumeHideDuration: f
|
|
120
|
-
} = t, h = we();
|
|
121
|
-
y.useEffect(() => {
|
|
122
|
-
if (!p)
|
|
123
|
-
return;
|
|
124
|
-
function r(s) {
|
|
125
|
-
s.defaultPrevented || s.key === "Escape" && (o == null || o(s, "escapeKeyDown"));
|
|
126
|
-
}
|
|
127
|
-
return document.addEventListener("keydown", r), () => {
|
|
128
|
-
document.removeEventListener("keydown", r);
|
|
129
|
-
};
|
|
130
|
-
}, [p, o]);
|
|
131
|
-
const d = N((r, s) => {
|
|
132
|
-
o == null || o(r, s);
|
|
133
|
-
}), b = N((r) => {
|
|
134
|
-
!o || r == null || h.start(r, () => {
|
|
135
|
-
d(null, "timeout");
|
|
136
|
-
});
|
|
137
|
-
});
|
|
138
|
-
y.useEffect(() => (p && b(n), h.clear), [p, n, b, h]);
|
|
139
|
-
const k = (r) => {
|
|
140
|
-
o == null || o(r, "clickaway");
|
|
141
|
-
}, u = h.clear, m = y.useCallback(() => {
|
|
142
|
-
n != null && b(f ?? n * 0.5);
|
|
143
|
-
}, [n, f, b]), S = (r) => (s) => {
|
|
144
|
-
const c = r.onBlur;
|
|
145
|
-
c == null || c(s), m();
|
|
146
|
-
}, T = (r) => (s) => {
|
|
147
|
-
const c = r.onFocus;
|
|
148
|
-
c == null || c(s), u();
|
|
149
|
-
}, i = (r) => (s) => {
|
|
150
|
-
const c = r.onMouseEnter;
|
|
151
|
-
c == null || c(s), u();
|
|
152
|
-
}, a = (r) => (s) => {
|
|
153
|
-
const c = r.onMouseLeave;
|
|
154
|
-
c == null || c(s), m();
|
|
155
|
-
};
|
|
156
|
-
return y.useEffect(() => {
|
|
157
|
-
if (!l && p)
|
|
158
|
-
return window.addEventListener("focus", m), window.addEventListener("blur", u), () => {
|
|
159
|
-
window.removeEventListener("focus", m), window.removeEventListener("blur", u);
|
|
160
|
-
};
|
|
161
|
-
}, [l, p, m, u]), {
|
|
162
|
-
getRootProps: (r = {}) => {
|
|
163
|
-
const s = {
|
|
164
|
-
...G(t),
|
|
165
|
-
...G(r)
|
|
166
|
-
};
|
|
167
|
-
return {
|
|
168
|
-
// ClickAwayListener adds an `onClick` prop which results in the alert not being announced.
|
|
169
|
-
// See https://github.com/mui/material-ui/issues/29080
|
|
170
|
-
role: "presentation",
|
|
171
|
-
...r,
|
|
172
|
-
...s,
|
|
173
|
-
onBlur: S(s),
|
|
174
|
-
onFocus: T(s),
|
|
175
|
-
onMouseEnter: i(s),
|
|
176
|
-
onMouseLeave: a(s)
|
|
177
|
-
};
|
|
178
|
-
},
|
|
179
|
-
onClickAway: k
|
|
180
|
-
};
|
|
181
|
-
}
|
|
182
|
-
function Ae(t) {
|
|
183
|
-
return X("MuiSnackbarContent", t);
|
|
184
|
-
}
|
|
185
|
-
Q("MuiSnackbarContent", ["root", "message", "action"]);
|
|
186
|
-
const De = (t) => {
|
|
187
|
-
const {
|
|
188
|
-
classes: n
|
|
189
|
-
} = t;
|
|
190
|
-
return Y({
|
|
191
|
-
root: ["root"],
|
|
192
|
-
action: ["action"],
|
|
193
|
-
message: ["message"]
|
|
194
|
-
}, Ae, n);
|
|
195
|
-
}, je = A(Oe, {
|
|
196
|
-
name: "MuiSnackbarContent",
|
|
197
|
-
slot: "Root"
|
|
198
|
-
})(J(({
|
|
199
|
-
theme: t
|
|
200
|
-
}) => {
|
|
201
|
-
const n = t.palette.mode === "light" ? 0.8 : 0.98;
|
|
202
|
-
return {
|
|
203
|
-
...t.typography.body2,
|
|
204
|
-
color: t.vars ? t.vars.palette.SnackbarContent.color : t.palette.getContrastText($(t.palette.background.default, n)),
|
|
205
|
-
backgroundColor: t.vars ? t.vars.palette.SnackbarContent.bg : $(t.palette.background.default, n),
|
|
206
|
-
display: "flex",
|
|
207
|
-
alignItems: "center",
|
|
208
|
-
flexWrap: "wrap",
|
|
209
|
-
padding: "6px 16px",
|
|
210
|
-
flexGrow: 1,
|
|
211
|
-
[t.breakpoints.up("sm")]: {
|
|
212
|
-
flexGrow: "initial",
|
|
213
|
-
minWidth: 288
|
|
214
|
-
}
|
|
215
|
-
};
|
|
216
|
-
})), He = A("div", {
|
|
217
|
-
name: "MuiSnackbarContent",
|
|
218
|
-
slot: "Message"
|
|
219
|
-
})({
|
|
220
|
-
padding: "8px 0"
|
|
221
|
-
}), Ne = A("div", {
|
|
222
|
-
name: "MuiSnackbarContent",
|
|
223
|
-
slot: "Action"
|
|
224
|
-
})({
|
|
225
|
-
display: "flex",
|
|
226
|
-
alignItems: "center",
|
|
227
|
-
marginLeft: "auto",
|
|
228
|
-
paddingLeft: 16,
|
|
229
|
-
marginRight: -8
|
|
230
|
-
}), Z = /* @__PURE__ */ y.forwardRef(function(n, l) {
|
|
231
|
-
const o = K({
|
|
232
|
-
props: n,
|
|
233
|
-
name: "MuiSnackbarContent"
|
|
234
|
-
}), {
|
|
235
|
-
action: p,
|
|
236
|
-
className: f,
|
|
237
|
-
message: h,
|
|
238
|
-
role: d = "alert",
|
|
239
|
-
...b
|
|
240
|
-
} = o, k = o, u = De(k);
|
|
241
|
-
return /* @__PURE__ */ ke(je, {
|
|
242
|
-
role: d,
|
|
243
|
-
elevation: 6,
|
|
244
|
-
className: Pe(u.root, f),
|
|
245
|
-
ownerState: k,
|
|
246
|
-
ref: l,
|
|
247
|
-
...b,
|
|
248
|
-
children: [/* @__PURE__ */ v(He, {
|
|
249
|
-
className: u.message,
|
|
250
|
-
ownerState: k,
|
|
251
|
-
children: h
|
|
252
|
-
}), p ? /* @__PURE__ */ v(Ne, {
|
|
253
|
-
className: u.action,
|
|
254
|
-
ownerState: k,
|
|
255
|
-
children: p
|
|
256
|
-
}) : null]
|
|
257
|
-
});
|
|
258
|
-
});
|
|
259
|
-
process.env.NODE_ENV !== "production" && (Z.propTypes = {
|
|
260
|
-
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
261
|
-
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
262
|
-
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
263
|
-
// └─────────────────────────────────────────────────────────────────────┘
|
|
264
|
-
/**
|
|
265
|
-
* The action to display. It renders after the message, at the end of the snackbar.
|
|
266
|
-
*/
|
|
267
|
-
action: e.node,
|
|
268
|
-
/**
|
|
269
|
-
* Override or extend the styles applied to the component.
|
|
270
|
-
*/
|
|
271
|
-
classes: e.object,
|
|
272
|
-
/**
|
|
273
|
-
* @ignore
|
|
274
|
-
*/
|
|
275
|
-
className: e.string,
|
|
276
|
-
/**
|
|
277
|
-
* The message to display.
|
|
278
|
-
*/
|
|
279
|
-
message: e.node,
|
|
280
|
-
/**
|
|
281
|
-
* The ARIA role attribute of the element.
|
|
282
|
-
* @default 'alert'
|
|
283
|
-
*/
|
|
284
|
-
role: e.string,
|
|
285
|
-
/**
|
|
286
|
-
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
287
|
-
*/
|
|
288
|
-
sx: e.oneOfType([e.arrayOf(e.oneOfType([e.func, e.object, e.bool])), e.func, e.object])
|
|
289
|
-
});
|
|
290
|
-
function ze(t) {
|
|
291
|
-
return X("MuiSnackbar", t);
|
|
292
|
-
}
|
|
293
|
-
Q("MuiSnackbar", ["root", "anchorOriginTopCenter", "anchorOriginBottomCenter", "anchorOriginTopRight", "anchorOriginBottomRight", "anchorOriginTopLeft", "anchorOriginBottomLeft"]);
|
|
294
|
-
const Be = (t) => {
|
|
295
|
-
const {
|
|
296
|
-
classes: n,
|
|
297
|
-
anchorOrigin: l
|
|
298
|
-
} = t, o = {
|
|
299
|
-
root: ["root", `anchorOrigin${x(l.vertical)}${x(l.horizontal)}`]
|
|
300
|
-
};
|
|
301
|
-
return Y(o, ze, n);
|
|
302
|
-
}, Ue = A("div", {
|
|
303
|
-
name: "MuiSnackbar",
|
|
304
|
-
slot: "Root",
|
|
305
|
-
overridesResolver: (t, n) => {
|
|
306
|
-
const {
|
|
307
|
-
ownerState: l
|
|
308
|
-
} = t;
|
|
309
|
-
return [n.root, n[`anchorOrigin${x(l.anchorOrigin.vertical)}${x(l.anchorOrigin.horizontal)}`]];
|
|
310
|
-
}
|
|
311
|
-
})(J(({
|
|
312
|
-
theme: t
|
|
313
|
-
}) => ({
|
|
314
|
-
zIndex: (t.vars || t).zIndex.snackbar,
|
|
315
|
-
position: "fixed",
|
|
316
|
-
display: "flex",
|
|
317
|
-
left: 8,
|
|
318
|
-
right: 8,
|
|
319
|
-
justifyContent: "center",
|
|
320
|
-
alignItems: "center",
|
|
321
|
-
variants: [{
|
|
322
|
-
props: ({
|
|
323
|
-
ownerState: n
|
|
324
|
-
}) => n.anchorOrigin.vertical === "top",
|
|
325
|
-
style: {
|
|
326
|
-
top: 8,
|
|
327
|
-
[t.breakpoints.up("sm")]: {
|
|
328
|
-
top: 24
|
|
329
|
-
}
|
|
330
|
-
}
|
|
331
|
-
}, {
|
|
332
|
-
props: ({
|
|
333
|
-
ownerState: n
|
|
334
|
-
}) => n.anchorOrigin.vertical !== "top",
|
|
335
|
-
style: {
|
|
336
|
-
bottom: 8,
|
|
337
|
-
[t.breakpoints.up("sm")]: {
|
|
338
|
-
bottom: 24
|
|
339
|
-
}
|
|
340
|
-
}
|
|
341
|
-
}, {
|
|
342
|
-
props: ({
|
|
343
|
-
ownerState: n
|
|
344
|
-
}) => n.anchorOrigin.horizontal === "left",
|
|
345
|
-
style: {
|
|
346
|
-
justifyContent: "flex-start",
|
|
347
|
-
[t.breakpoints.up("sm")]: {
|
|
348
|
-
left: 24,
|
|
349
|
-
right: "auto"
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
}, {
|
|
353
|
-
props: ({
|
|
354
|
-
ownerState: n
|
|
355
|
-
}) => n.anchorOrigin.horizontal === "right",
|
|
356
|
-
style: {
|
|
357
|
-
justifyContent: "flex-end",
|
|
358
|
-
[t.breakpoints.up("sm")]: {
|
|
359
|
-
right: 24,
|
|
360
|
-
left: "auto"
|
|
361
|
-
}
|
|
362
|
-
}
|
|
363
|
-
}, {
|
|
364
|
-
props: ({
|
|
365
|
-
ownerState: n
|
|
366
|
-
}) => n.anchorOrigin.horizontal === "center",
|
|
367
|
-
style: {
|
|
368
|
-
[t.breakpoints.up("sm")]: {
|
|
369
|
-
left: "50%",
|
|
370
|
-
right: "auto",
|
|
371
|
-
transform: "translateX(-50%)"
|
|
372
|
-
}
|
|
373
|
-
}
|
|
374
|
-
}]
|
|
375
|
-
}))), ee = /* @__PURE__ */ y.forwardRef(function(n, l) {
|
|
376
|
-
const o = K({
|
|
377
|
-
props: n,
|
|
378
|
-
name: "MuiSnackbar"
|
|
379
|
-
}), p = ve(), f = {
|
|
380
|
-
enter: p.transitions.duration.enteringScreen,
|
|
381
|
-
exit: p.transitions.duration.leavingScreen
|
|
382
|
-
}, {
|
|
383
|
-
action: h,
|
|
384
|
-
anchorOrigin: {
|
|
385
|
-
vertical: d,
|
|
386
|
-
horizontal: b
|
|
387
|
-
} = {
|
|
388
|
-
vertical: "bottom",
|
|
389
|
-
horizontal: "left"
|
|
390
|
-
},
|
|
391
|
-
autoHideDuration: k = null,
|
|
392
|
-
children: u,
|
|
393
|
-
className: m,
|
|
394
|
-
ClickAwayListenerProps: S,
|
|
395
|
-
ContentProps: T,
|
|
396
|
-
disableWindowBlurListener: i = !1,
|
|
397
|
-
message: a,
|
|
398
|
-
onBlur: g,
|
|
399
|
-
onClose: r,
|
|
400
|
-
onFocus: s,
|
|
401
|
-
onMouseEnter: c,
|
|
402
|
-
onMouseLeave: qe,
|
|
403
|
-
open: z,
|
|
404
|
-
resumeHideDuration: $e,
|
|
405
|
-
slots: B = {},
|
|
406
|
-
slotProps: te = {},
|
|
407
|
-
TransitionComponent: U,
|
|
408
|
-
transitionDuration: F = f,
|
|
409
|
-
TransitionProps: {
|
|
410
|
-
onEnter: _,
|
|
411
|
-
onExited: I,
|
|
412
|
-
...ne
|
|
413
|
-
} = {},
|
|
414
|
-
...oe
|
|
415
|
-
} = o, P = {
|
|
416
|
-
...o,
|
|
417
|
-
anchorOrigin: {
|
|
418
|
-
vertical: d,
|
|
419
|
-
horizontal: b
|
|
420
|
-
},
|
|
421
|
-
autoHideDuration: k,
|
|
422
|
-
disableWindowBlurListener: i,
|
|
423
|
-
TransitionComponent: U,
|
|
424
|
-
transitionDuration: F
|
|
425
|
-
}, re = Be(P), {
|
|
426
|
-
getRootProps: se,
|
|
427
|
-
onClickAway: ie
|
|
428
|
-
} = Me({
|
|
429
|
-
...P
|
|
430
|
-
}), [ae, W] = y.useState(!0), ce = (w) => {
|
|
431
|
-
W(!0), I && I(w);
|
|
432
|
-
}, le = (w, E) => {
|
|
433
|
-
W(!1), _ && _(w, E);
|
|
434
|
-
}, R = {
|
|
435
|
-
slots: {
|
|
436
|
-
transition: U,
|
|
437
|
-
...B
|
|
438
|
-
},
|
|
439
|
-
slotProps: {
|
|
440
|
-
content: T,
|
|
441
|
-
clickAwayListener: S,
|
|
442
|
-
transition: ne,
|
|
443
|
-
...te
|
|
444
|
-
}
|
|
445
|
-
}, [ue, pe] = L("root", {
|
|
446
|
-
ref: l,
|
|
447
|
-
className: [re.root, m],
|
|
448
|
-
elementType: Ue,
|
|
449
|
-
getSlotProps: se,
|
|
450
|
-
externalForwardedProps: {
|
|
451
|
-
...R,
|
|
452
|
-
...oe
|
|
453
|
-
},
|
|
454
|
-
ownerState: P
|
|
455
|
-
}), [fe, {
|
|
456
|
-
ownerState: de,
|
|
457
|
-
...me
|
|
458
|
-
}] = L("clickAwayListener", {
|
|
459
|
-
elementType: M,
|
|
460
|
-
externalForwardedProps: R,
|
|
461
|
-
getSlotProps: (w) => ({
|
|
462
|
-
onClickAway: (...E) => {
|
|
463
|
-
var q;
|
|
464
|
-
const C = E[0];
|
|
465
|
-
(q = w.onClickAway) == null || q.call(w, ...E), !(C != null && C.defaultMuiPrevented) && ie(...E);
|
|
466
|
-
}
|
|
467
|
-
}),
|
|
468
|
-
ownerState: P
|
|
469
|
-
}), [ge, ye] = L("content", {
|
|
470
|
-
elementType: Z,
|
|
471
|
-
shouldForwardComponentProp: !0,
|
|
472
|
-
externalForwardedProps: R,
|
|
473
|
-
additionalProps: {
|
|
474
|
-
message: a,
|
|
475
|
-
action: h
|
|
476
|
-
},
|
|
477
|
-
ownerState: P
|
|
478
|
-
}), [he, be] = L("transition", {
|
|
479
|
-
elementType: Re,
|
|
480
|
-
externalForwardedProps: R,
|
|
481
|
-
getSlotProps: (w) => ({
|
|
482
|
-
onEnter: (...E) => {
|
|
483
|
-
var C;
|
|
484
|
-
(C = w.onEnter) == null || C.call(w, ...E), le(...E);
|
|
485
|
-
},
|
|
486
|
-
onExited: (...E) => {
|
|
487
|
-
var C;
|
|
488
|
-
(C = w.onExited) == null || C.call(w, ...E), ce(...E);
|
|
489
|
-
}
|
|
490
|
-
}),
|
|
491
|
-
additionalProps: {
|
|
492
|
-
appear: !0,
|
|
493
|
-
in: z,
|
|
494
|
-
timeout: F,
|
|
495
|
-
direction: d === "top" ? "down" : "up"
|
|
496
|
-
},
|
|
497
|
-
ownerState: P
|
|
498
|
-
});
|
|
499
|
-
return !z && ae ? null : /* @__PURE__ */ v(fe, {
|
|
500
|
-
...me,
|
|
501
|
-
...B.clickAwayListener && {
|
|
502
|
-
ownerState: de
|
|
503
|
-
},
|
|
504
|
-
children: /* @__PURE__ */ v(ue, {
|
|
505
|
-
...pe,
|
|
506
|
-
children: /* @__PURE__ */ v(he, {
|
|
507
|
-
...be,
|
|
508
|
-
children: u || /* @__PURE__ */ v(ge, {
|
|
509
|
-
...ye
|
|
510
|
-
})
|
|
511
|
-
})
|
|
512
|
-
})
|
|
513
|
-
});
|
|
514
|
-
});
|
|
515
|
-
process.env.NODE_ENV !== "production" && (ee.propTypes = {
|
|
516
|
-
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
517
|
-
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
518
|
-
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
519
|
-
// └─────────────────────────────────────────────────────────────────────┘
|
|
520
|
-
/**
|
|
521
|
-
* The action to display. It renders after the message, at the end of the snackbar.
|
|
522
|
-
*/
|
|
523
|
-
action: e.node,
|
|
524
|
-
/**
|
|
525
|
-
* The anchor of the `Snackbar`.
|
|
526
|
-
* On smaller screens, the component grows to occupy all the available width,
|
|
527
|
-
* the horizontal alignment is ignored.
|
|
528
|
-
* @default { vertical: 'bottom', horizontal: 'left' }
|
|
529
|
-
*/
|
|
530
|
-
anchorOrigin: e.shape({
|
|
531
|
-
horizontal: e.oneOf(["center", "left", "right"]).isRequired,
|
|
532
|
-
vertical: e.oneOf(["bottom", "top"]).isRequired
|
|
533
|
-
}),
|
|
534
|
-
/**
|
|
535
|
-
* The number of milliseconds to wait before automatically calling the
|
|
536
|
-
* `onClose` function. `onClose` should then set the state of the `open`
|
|
537
|
-
* prop to hide the Snackbar. This behavior is disabled by default with
|
|
538
|
-
* the `null` value.
|
|
539
|
-
* @default null
|
|
540
|
-
*/
|
|
541
|
-
autoHideDuration: e.number,
|
|
542
|
-
/**
|
|
543
|
-
* Replace the `SnackbarContent` component.
|
|
544
|
-
*/
|
|
545
|
-
children: e.element,
|
|
546
|
-
/**
|
|
547
|
-
* Override or extend the styles applied to the component.
|
|
548
|
-
*/
|
|
549
|
-
classes: e.object,
|
|
550
|
-
/**
|
|
551
|
-
* @ignore
|
|
552
|
-
*/
|
|
553
|
-
className: e.string,
|
|
554
|
-
/**
|
|
555
|
-
* Props applied to the `ClickAwayListener` element.
|
|
556
|
-
* @deprecated Use `slotProps.clickAwayListener` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
557
|
-
*/
|
|
558
|
-
ClickAwayListenerProps: e.object,
|
|
559
|
-
/**
|
|
560
|
-
* Props applied to the [`SnackbarContent`](https://mui.com/material-ui/api/snackbar-content/) element.
|
|
561
|
-
* @deprecated Use `slotProps.content` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
562
|
-
*/
|
|
563
|
-
ContentProps: e.object,
|
|
564
|
-
/**
|
|
565
|
-
* If `true`, the `autoHideDuration` timer will expire even if the window is not focused.
|
|
566
|
-
* @default false
|
|
567
|
-
*/
|
|
568
|
-
disableWindowBlurListener: e.bool,
|
|
569
|
-
/**
|
|
570
|
-
* When displaying multiple consecutive snackbars using a single parent-rendered
|
|
571
|
-
* `<Snackbar/>`, add the `key` prop to ensure independent treatment of each message.
|
|
572
|
-
* For instance, use `<Snackbar key={message} />`. Otherwise, messages might update
|
|
573
|
-
* in place, and features like `autoHideDuration` could be affected.
|
|
574
|
-
*/
|
|
575
|
-
key: () => null,
|
|
576
|
-
/**
|
|
577
|
-
* The message to display.
|
|
578
|
-
*/
|
|
579
|
-
message: e.node,
|
|
580
|
-
/**
|
|
581
|
-
* @ignore
|
|
582
|
-
*/
|
|
583
|
-
onBlur: e.func,
|
|
584
|
-
/**
|
|
585
|
-
* Callback fired when the component requests to be closed.
|
|
586
|
-
* Typically `onClose` is used to set state in the parent component,
|
|
587
|
-
* which is used to control the `Snackbar` `open` prop.
|
|
588
|
-
* The `reason` parameter can optionally be used to control the response to `onClose`,
|
|
589
|
-
* for example ignoring `clickaway`.
|
|
590
|
-
*
|
|
591
|
-
* @param {React.SyntheticEvent<any> | Event} event The event source of the callback.
|
|
592
|
-
* @param {string} reason Can be: `"timeout"` (`autoHideDuration` expired), `"clickaway"`, or `"escapeKeyDown"`.
|
|
593
|
-
*/
|
|
594
|
-
onClose: e.func,
|
|
595
|
-
/**
|
|
596
|
-
* @ignore
|
|
597
|
-
*/
|
|
598
|
-
onFocus: e.func,
|
|
599
|
-
/**
|
|
600
|
-
* @ignore
|
|
601
|
-
*/
|
|
602
|
-
onMouseEnter: e.func,
|
|
603
|
-
/**
|
|
604
|
-
* @ignore
|
|
605
|
-
*/
|
|
606
|
-
onMouseLeave: e.func,
|
|
607
|
-
/**
|
|
608
|
-
* If `true`, the component is shown.
|
|
609
|
-
*/
|
|
610
|
-
open: e.bool,
|
|
611
|
-
/**
|
|
612
|
-
* The number of milliseconds to wait before dismissing after user interaction.
|
|
613
|
-
* If `autoHideDuration` prop isn't specified, it does nothing.
|
|
614
|
-
* If `autoHideDuration` prop is specified but `resumeHideDuration` isn't,
|
|
615
|
-
* we default to `autoHideDuration / 2` ms.
|
|
616
|
-
*/
|
|
617
|
-
resumeHideDuration: e.number,
|
|
618
|
-
/**
|
|
619
|
-
* The props used for each slot inside.
|
|
620
|
-
* @default {}
|
|
621
|
-
*/
|
|
622
|
-
slotProps: e.shape({
|
|
623
|
-
clickAwayListener: e.oneOfType([e.func, e.shape({
|
|
624
|
-
children: e.element.isRequired,
|
|
625
|
-
disableReactTree: e.bool,
|
|
626
|
-
mouseEvent: e.oneOf(["onClick", "onMouseDown", "onMouseUp", "onPointerDown", "onPointerUp", !1]),
|
|
627
|
-
onClickAway: e.func,
|
|
628
|
-
touchEvent: e.oneOf(["onTouchEnd", "onTouchStart", !1])
|
|
629
|
-
})]),
|
|
630
|
-
content: e.oneOfType([e.func, e.object]),
|
|
631
|
-
root: e.oneOfType([e.func, e.object]),
|
|
632
|
-
transition: e.oneOfType([e.func, e.object])
|
|
633
|
-
}),
|
|
634
|
-
/**
|
|
635
|
-
* The components used for each slot inside.
|
|
636
|
-
* @default {}
|
|
637
|
-
*/
|
|
638
|
-
slots: e.shape({
|
|
639
|
-
clickAwayListener: e.elementType,
|
|
640
|
-
content: e.elementType,
|
|
641
|
-
root: e.elementType,
|
|
642
|
-
transition: e.elementType
|
|
643
|
-
}),
|
|
644
|
-
/**
|
|
645
|
-
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
646
|
-
*/
|
|
647
|
-
sx: e.oneOfType([e.arrayOf(e.oneOfType([e.func, e.object, e.bool])), e.func, e.object]),
|
|
648
|
-
/**
|
|
649
|
-
* The component used for the transition.
|
|
650
|
-
* [Follow this guide](https://mui.com/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.
|
|
651
|
-
* @deprecated Use `slots.transition` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
652
|
-
* @default Grow
|
|
653
|
-
*/
|
|
654
|
-
TransitionComponent: e.elementType,
|
|
655
|
-
/**
|
|
656
|
-
* The duration for the transition, in milliseconds.
|
|
657
|
-
* You may specify a single timeout for all transitions, or individually with an object.
|
|
658
|
-
* @default {
|
|
659
|
-
* enter: theme.transitions.duration.enteringScreen,
|
|
660
|
-
* exit: theme.transitions.duration.leavingScreen,
|
|
661
|
-
* }
|
|
662
|
-
*/
|
|
663
|
-
transitionDuration: e.oneOfType([e.number, e.shape({
|
|
664
|
-
appear: e.number,
|
|
665
|
-
enter: e.number,
|
|
666
|
-
exit: e.number
|
|
667
|
-
})]),
|
|
668
|
-
/**
|
|
669
|
-
* Props applied to the transition element.
|
|
670
|
-
* By default, the element is based on this [`Transition`](https://reactcommunity.org/react-transition-group/transition/) component.
|
|
671
|
-
* @deprecated Use `slotProps.transition` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
672
|
-
* @default {}
|
|
673
|
-
*/
|
|
674
|
-
TransitionProps: e.object
|
|
675
|
-
});
|
|
676
|
-
const Fe = (t) => /* @__PURE__ */ v(D, { ...t, direction: "left" }), _e = (t) => /* @__PURE__ */ v(D, { ...t, direction: "right" }), Ie = (t) => /* @__PURE__ */ v(D, { ...t, direction: "up" }), We = (t) => /* @__PURE__ */ v(D, { ...t, direction: "down" }), ut = () => {
|
|
677
|
-
const [t, n] = O(!1), [l, o] = O(""), [p, f] = O(2e3), [h, d] = O("error"), [b, k] = O({ vertical: "top", horizontal: "right" }), [u, m] = O("left"), S = j(
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { useState as o, useCallback as c } from "react";
|
|
3
|
+
import { Snackbar as y, Alert as _, Slide as i } from "@mui/material";
|
|
4
|
+
const A = (t) => /* @__PURE__ */ n(i, { ...t, direction: "left" }), M = (t) => /* @__PURE__ */ n(i, { ...t, direction: "right" }), b = (t) => /* @__PURE__ */ n(i, { ...t, direction: "up" }), x = (t) => /* @__PURE__ */ n(i, { ...t, direction: "down" }), L = () => {
|
|
5
|
+
const [t, r] = o(!1), [l, d] = o(""), [u, f] = o(2e3), [h, p] = o("error"), [m, g] = o({ vertical: "top", horizontal: "right" }), [s, k] = o("left"), S = c(
|
|
678
6
|
({
|
|
679
7
|
message: a,
|
|
680
|
-
type:
|
|
681
|
-
duration:
|
|
682
|
-
animationDirection:
|
|
683
|
-
position:
|
|
8
|
+
type: e = "error",
|
|
9
|
+
duration: D = 3e3,
|
|
10
|
+
animationDirection: T = "left",
|
|
11
|
+
position: w = { vertical: "top", horizontal: "right" }
|
|
684
12
|
}) => {
|
|
685
|
-
|
|
13
|
+
d(a), p(e), f(D), g(w), k(T), r(!0);
|
|
686
14
|
},
|
|
687
15
|
[]
|
|
688
|
-
),
|
|
689
|
-
(a,
|
|
690
|
-
|
|
16
|
+
), v = c(
|
|
17
|
+
(a, e) => {
|
|
18
|
+
e !== "clickaway" && r(!1);
|
|
691
19
|
},
|
|
692
20
|
[]
|
|
693
|
-
),
|
|
694
|
-
(a,
|
|
695
|
-
|
|
21
|
+
), C = c(
|
|
22
|
+
(a, e) => {
|
|
23
|
+
e !== "clickaway" && r(!1);
|
|
696
24
|
},
|
|
697
25
|
[]
|
|
698
26
|
);
|
|
699
27
|
return {
|
|
700
28
|
showAlertMessage: S,
|
|
701
|
-
snackBar: /* @__PURE__ */
|
|
702
|
-
|
|
29
|
+
snackBar: /* @__PURE__ */ n(
|
|
30
|
+
y,
|
|
703
31
|
{
|
|
704
|
-
anchorOrigin:
|
|
705
|
-
autoHideDuration:
|
|
32
|
+
anchorOrigin: m,
|
|
33
|
+
autoHideDuration: u,
|
|
706
34
|
open: t,
|
|
707
|
-
onClose:
|
|
708
|
-
TransitionComponent:
|
|
709
|
-
children: /* @__PURE__ */
|
|
35
|
+
onClose: C,
|
|
36
|
+
TransitionComponent: s === "left" ? A : s === "right" ? M : s === "up" ? b : x,
|
|
37
|
+
children: /* @__PURE__ */ n(_, { variant: "filled", onClose: v, severity: h, children: /* @__PURE__ */ n("div", { dangerouslySetInnerHTML: { __html: l } }) })
|
|
710
38
|
}
|
|
711
39
|
)
|
|
712
40
|
};
|
|
713
41
|
};
|
|
714
42
|
export {
|
|
715
|
-
|
|
43
|
+
L as useSnackBar
|
|
716
44
|
};
|