@xyo-network/react-error 2.64.0-rc.2 → 2.64.0-rc.4
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.d.mts.map +1 -0
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.d.ts.map +1 -0
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.js +39 -0
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.js.map +1 -0
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.stories.js +26 -0
- package/dist/browser/components/ErrorBoundary/ThrownErrorBoundary.stories.js.map +1 -0
- package/dist/browser/components/ErrorBoundary/index.d.mts.map +1 -0
- package/dist/browser/components/ErrorBoundary/index.d.ts.map +1 -0
- package/dist/browser/components/ErrorBoundary/index.js +2 -0
- package/dist/browser/components/ErrorBoundary/index.js.map +1 -0
- package/dist/browser/components/ErrorRender/ErrorAlert.d.mts.map +1 -0
- package/dist/browser/components/ErrorRender/ErrorAlert.d.ts.map +1 -0
- package/dist/browser/components/ErrorRender/ErrorAlert.js +17 -0
- package/dist/browser/components/ErrorRender/ErrorAlert.js.map +1 -0
- package/dist/browser/components/ErrorRender/Props.d.mts.map +1 -0
- package/dist/browser/components/ErrorRender/Props.d.ts.map +1 -0
- package/dist/browser/components/ErrorRender/Props.js +1 -0
- package/dist/browser/components/ErrorRender/Props.js.map +1 -0
- package/dist/browser/components/ErrorRender/Render.d.mts.map +1 -0
- package/dist/browser/components/ErrorRender/Render.d.ts.map +1 -0
- package/dist/browser/components/ErrorRender/Render.js +32 -0
- package/dist/browser/components/ErrorRender/Render.js.map +1 -0
- package/dist/browser/components/ErrorRender/index.d.mts.map +1 -0
- package/dist/browser/components/ErrorRender/index.d.ts.map +1 -0
- package/dist/browser/components/ErrorRender/index.js +4 -0
- package/dist/browser/components/ErrorRender/index.js.map +1 -0
- package/dist/browser/components/index.d.mts.map +1 -0
- package/dist/browser/components/index.d.ts.map +1 -0
- package/dist/browser/components/index.js +3 -0
- package/dist/browser/components/index.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Context.d.mts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Context.d.ts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Context.js +6 -0
- package/dist/browser/contexts/ErrorReporter/Context.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Provider.d.mts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Provider.d.ts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Provider.js +16 -0
- package/dist/browser/contexts/ErrorReporter/Provider.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/Provider.stories.js +35 -0
- package/dist/browser/contexts/ErrorReporter/Provider.stories.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/State.d.mts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/State.d.ts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/State.js +1 -0
- package/dist/browser/contexts/ErrorReporter/State.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/index.d.mts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/index.d.ts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/index.js +4 -0
- package/dist/browser/contexts/ErrorReporter/index.js.map +1 -0
- package/dist/browser/contexts/ErrorReporter/useRollbar.d.mts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/useRollbar.d.ts.map +1 -0
- package/dist/browser/contexts/ErrorReporter/useRollbar.js +13 -0
- package/dist/browser/contexts/ErrorReporter/useRollbar.js.map +1 -0
- package/dist/browser/contexts/index.d.mts.map +1 -0
- package/dist/browser/contexts/index.d.ts.map +1 -0
- package/dist/browser/contexts/index.js +2 -0
- package/dist/browser/contexts/index.js.map +1 -0
- package/dist/browser/index.d.mts.map +1 -0
- package/dist/browser/index.d.ts.map +1 -0
- package/dist/browser/index.js +3 -0
- package/dist/browser/index.js.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.d.mts +21 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.d.mts.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.d.ts +21 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.d.ts.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.js +63 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.js.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.mjs +39 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.mjs.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.stories.js +51 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.stories.js.map +1 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.stories.mjs +26 -0
- package/dist/node/components/ErrorBoundary/ThrownErrorBoundary.stories.mjs.map +1 -0
- package/dist/node/components/ErrorBoundary/index.d.mts +2 -0
- package/dist/node/components/ErrorBoundary/index.d.mts.map +1 -0
- package/dist/node/components/ErrorBoundary/index.d.ts +2 -0
- package/dist/node/components/ErrorBoundary/index.d.ts.map +1 -0
- package/dist/node/components/ErrorBoundary/index.js +23 -0
- package/dist/node/components/ErrorBoundary/index.js.map +1 -0
- package/dist/node/components/ErrorBoundary/index.mjs +2 -0
- package/dist/node/components/ErrorBoundary/index.mjs.map +1 -0
- package/dist/node/components/ErrorRender/ErrorAlert.d.mts +10 -0
- package/dist/node/components/ErrorRender/ErrorAlert.d.mts.map +1 -0
- package/dist/node/components/ErrorRender/ErrorAlert.d.ts +10 -0
- package/dist/node/components/ErrorRender/ErrorAlert.d.ts.map +1 -0
- package/dist/node/components/ErrorRender/ErrorAlert.js +41 -0
- package/dist/node/components/ErrorRender/ErrorAlert.js.map +1 -0
- package/dist/node/components/ErrorRender/ErrorAlert.mjs +17 -0
- package/dist/node/components/ErrorRender/ErrorAlert.mjs.map +1 -0
- package/dist/node/components/ErrorRender/Props.d.mts +12 -0
- package/dist/node/components/ErrorRender/Props.d.mts.map +1 -0
- package/dist/node/components/ErrorRender/Props.d.ts +12 -0
- package/dist/node/components/ErrorRender/Props.d.ts.map +1 -0
- package/dist/node/components/ErrorRender/Props.js +17 -0
- package/dist/node/components/ErrorRender/Props.js.map +1 -0
- package/dist/node/components/ErrorRender/Props.mjs +1 -0
- package/dist/node/components/ErrorRender/Props.mjs.map +1 -0
- package/dist/node/components/ErrorRender/Render.d.mts +4 -0
- package/dist/node/components/ErrorRender/Render.d.mts.map +1 -0
- package/dist/node/components/ErrorRender/Render.d.ts +4 -0
- package/dist/node/components/ErrorRender/Render.d.ts.map +1 -0
- package/dist/node/components/ErrorRender/Render.js +56 -0
- package/dist/node/components/ErrorRender/Render.js.map +1 -0
- package/dist/node/components/ErrorRender/Render.mjs +32 -0
- package/dist/node/components/ErrorRender/Render.mjs.map +1 -0
- package/dist/node/components/ErrorRender/index.d.mts +4 -0
- package/dist/node/components/ErrorRender/index.d.mts.map +1 -0
- package/dist/node/components/ErrorRender/index.d.ts +4 -0
- package/dist/node/components/ErrorRender/index.d.ts.map +1 -0
- package/dist/node/components/ErrorRender/index.js +27 -0
- package/dist/node/components/ErrorRender/index.js.map +1 -0
- package/dist/node/components/ErrorRender/index.mjs +4 -0
- package/dist/node/components/ErrorRender/index.mjs.map +1 -0
- package/dist/node/components/index.d.mts +3 -0
- package/dist/node/components/index.d.mts.map +1 -0
- package/dist/node/components/index.d.ts +3 -0
- package/dist/node/components/index.d.ts.map +1 -0
- package/dist/node/components/index.js +25 -0
- package/dist/node/components/index.js.map +1 -0
- package/dist/node/components/index.mjs +3 -0
- package/dist/node/components/index.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/Context.d.mts +4 -0
- package/dist/node/contexts/ErrorReporter/Context.d.mts.map +1 -0
- package/dist/node/contexts/ErrorReporter/Context.d.ts +4 -0
- package/dist/node/contexts/ErrorReporter/Context.d.ts.map +1 -0
- package/dist/node/contexts/ErrorReporter/Context.js +30 -0
- package/dist/node/contexts/ErrorReporter/Context.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/Context.mjs +6 -0
- package/dist/node/contexts/ErrorReporter/Context.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.d.mts +9 -0
- package/dist/node/contexts/ErrorReporter/Provider.d.mts.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.d.ts +9 -0
- package/dist/node/contexts/ErrorReporter/Provider.d.ts.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.js +40 -0
- package/dist/node/contexts/ErrorReporter/Provider.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.mjs +16 -0
- package/dist/node/contexts/ErrorReporter/Provider.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.stories.js +69 -0
- package/dist/node/contexts/ErrorReporter/Provider.stories.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/Provider.stories.mjs +35 -0
- package/dist/node/contexts/ErrorReporter/Provider.stories.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/State.d.mts +5 -0
- package/dist/node/contexts/ErrorReporter/State.d.mts.map +1 -0
- package/dist/node/contexts/ErrorReporter/State.d.ts +5 -0
- package/dist/node/contexts/ErrorReporter/State.d.ts.map +1 -0
- package/dist/node/contexts/ErrorReporter/State.js +17 -0
- package/dist/node/contexts/ErrorReporter/State.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/State.mjs +1 -0
- package/dist/node/contexts/ErrorReporter/State.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/index.d.mts +4 -0
- package/dist/node/contexts/ErrorReporter/index.d.mts.map +1 -0
- package/dist/node/contexts/ErrorReporter/index.d.ts +4 -0
- package/dist/node/contexts/ErrorReporter/index.d.ts.map +1 -0
- package/dist/node/contexts/ErrorReporter/index.js +27 -0
- package/dist/node/contexts/ErrorReporter/index.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/index.mjs +4 -0
- package/dist/node/contexts/ErrorReporter/index.mjs.map +1 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.d.mts +3 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.d.mts.map +1 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.d.ts +3 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.d.ts.map +1 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.js +37 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.js.map +1 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.mjs +13 -0
- package/dist/node/contexts/ErrorReporter/useRollbar.mjs.map +1 -0
- package/dist/node/contexts/index.d.mts +2 -0
- package/dist/node/contexts/index.d.mts.map +1 -0
- package/dist/node/contexts/index.d.ts +2 -0
- package/dist/node/contexts/index.d.ts.map +1 -0
- package/dist/node/contexts/index.js +23 -0
- package/dist/node/contexts/index.js.map +1 -0
- package/dist/node/contexts/index.mjs +2 -0
- package/dist/node/contexts/index.mjs.map +1 -0
- package/dist/node/index.d.mts +3 -0
- package/dist/node/index.d.mts.map +1 -0
- package/dist/node/index.d.ts +3 -0
- package/dist/node/index.d.ts.map +1 -0
- package/dist/node/index.js +25 -0
- package/dist/node/index.js.map +1 -0
- package/dist/node/index.mjs +3 -0
- package/dist/node/index.mjs.map +1 -0
- package/package.json +19 -19
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.d.mts.map +0 -1
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.d.ts.map +0 -1
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.stories.d.mts +0 -7
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.stories.d.mts.map +0 -1
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.stories.d.ts +0 -7
- package/dist/components/ErrorBoundary/ThrownErrorBoundary.stories.d.ts.map +0 -1
- package/dist/components/ErrorBoundary/index.d.mts.map +0 -1
- package/dist/components/ErrorBoundary/index.d.ts.map +0 -1
- package/dist/components/ErrorRender/ErrorAlert.d.mts.map +0 -1
- package/dist/components/ErrorRender/ErrorAlert.d.ts.map +0 -1
- package/dist/components/ErrorRender/Props.d.mts.map +0 -1
- package/dist/components/ErrorRender/Props.d.ts.map +0 -1
- package/dist/components/ErrorRender/Render.d.mts.map +0 -1
- package/dist/components/ErrorRender/Render.d.ts.map +0 -1
- package/dist/components/ErrorRender/index.d.mts.map +0 -1
- package/dist/components/ErrorRender/index.d.ts.map +0 -1
- package/dist/components/index.d.mts.map +0 -1
- package/dist/components/index.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/Context.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/Context.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/Provider.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/Provider.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/Provider.stories.d.mts +0 -10
- package/dist/contexts/ErrorReporter/Provider.stories.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/Provider.stories.d.ts +0 -10
- package/dist/contexts/ErrorReporter/Provider.stories.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/State.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/State.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/index.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/index.d.ts.map +0 -1
- package/dist/contexts/ErrorReporter/useRollbar.d.mts.map +0 -1
- package/dist/contexts/ErrorReporter/useRollbar.d.ts.map +0 -1
- package/dist/contexts/index.d.mts.map +0 -1
- package/dist/contexts/index.d.ts.map +0 -1
- package/dist/index.d.mts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -149
- package/dist/index.js.map +0 -1
- package/dist/index.mjs +0 -118
- package/dist/index.mjs.map +0 -1
- /package/dist/{components → browser/components}/ErrorBoundary/ThrownErrorBoundary.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorBoundary/ThrownErrorBoundary.d.ts +0 -0
- /package/dist/{components → browser/components}/ErrorBoundary/index.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorBoundary/index.d.ts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/ErrorAlert.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/ErrorAlert.d.ts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/Props.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/Props.d.ts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/Render.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/Render.d.ts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/index.d.mts +0 -0
- /package/dist/{components → browser/components}/ErrorRender/index.d.ts +0 -0
- /package/dist/{components → browser/components}/index.d.mts +0 -0
- /package/dist/{components → browser/components}/index.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/Context.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/Context.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/Provider.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/Provider.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/State.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/State.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/index.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/index.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/useRollbar.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/ErrorReporter/useRollbar.d.ts +0 -0
- /package/dist/{contexts → browser/contexts}/index.d.mts +0 -0
- /package/dist/{contexts → browser/contexts}/index.d.ts +0 -0
- /package/dist/{index.d.mts → browser/index.d.mts} +0 -0
- /package/dist/{index.d.ts → browser/index.d.ts} +0 -0
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Context.ts"],"sourcesContent":["import { createContext } from 'react'\n\nimport { ErrorReporterContextState } from './State'\n\nexport const ErrorReporterContext = createContext<ErrorReporterContextState>({})\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA8B;AAIvB,MAAM,2BAAuB,4BAAyC,CAAC,CAAC;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Context.ts"],"sourcesContent":["import { createContext } from 'react'\n\nimport { ErrorReporterContextState } from './State'\n\nexport const ErrorReporterContext = createContext<ErrorReporterContextState>({})\n"],"mappings":"AAAA,SAAS,qBAAqB;AAIvB,MAAM,uBAAuB,cAAyC,CAAC,CAAC;","names":[]}
|
@@ -0,0 +1,9 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { WithChildren } from '@xylabs/react-shared';
|
3
|
+
import Rollbar from 'rollbar';
|
4
|
+
export interface ErrorReporterProviderProps {
|
5
|
+
rollbar: Rollbar;
|
6
|
+
}
|
7
|
+
declare const ErrorReporterProvider: React.FC<WithChildren<ErrorReporterProviderProps>>;
|
8
|
+
export { ErrorReporterProvider };
|
9
|
+
//# sourceMappingURL=Provider.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Provider.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/Provider.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAEnD,OAAO,OAAO,MAAM,SAAS,CAAA;AAI7B,MAAM,WAAW,0BAA0B;IACzC,OAAO,EAAE,OAAO,CAAA;CACjB;AAED,QAAA,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,0BAA0B,CAAC,CAU7E,CAAA;AAED,OAAO,EAAE,qBAAqB,EAAE,CAAA"}
|
@@ -0,0 +1,9 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { WithChildren } from '@xylabs/react-shared';
|
3
|
+
import Rollbar from 'rollbar';
|
4
|
+
export interface ErrorReporterProviderProps {
|
5
|
+
rollbar: Rollbar;
|
6
|
+
}
|
7
|
+
declare const ErrorReporterProvider: React.FC<WithChildren<ErrorReporterProviderProps>>;
|
8
|
+
export { ErrorReporterProvider };
|
9
|
+
//# sourceMappingURL=Provider.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Provider.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/Provider.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAEnD,OAAO,OAAO,MAAM,SAAS,CAAA;AAI7B,MAAM,WAAW,0BAA0B;IACzC,OAAO,EAAE,OAAO,CAAA;CACjB;AAED,QAAA,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,0BAA0B,CAAC,CAU7E,CAAA;AAED,OAAO,EAAE,qBAAqB,EAAE,CAAA"}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
9
|
+
};
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
12
|
+
for (let key of __getOwnPropNames(from))
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
15
|
+
}
|
16
|
+
return to;
|
17
|
+
};
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
19
|
+
var Provider_exports = {};
|
20
|
+
__export(Provider_exports, {
|
21
|
+
ErrorReporterProvider: () => ErrorReporterProvider
|
22
|
+
});
|
23
|
+
module.exports = __toCommonJS(Provider_exports);
|
24
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
25
|
+
var import_react = require("react");
|
26
|
+
var import_Context = require("./Context");
|
27
|
+
const ErrorReporterProvider = ({ children, rollbar }) => {
|
28
|
+
const [rollbarInstance, setRollBarInstance] = (0, import_react.useState)();
|
29
|
+
(0, import_react.useEffect)(() => {
|
30
|
+
if (rollbarInstance) {
|
31
|
+
setRollBarInstance(rollbarInstance);
|
32
|
+
}
|
33
|
+
}, [rollbar, rollbarInstance]);
|
34
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Context.ErrorReporterContext.Provider, { value: { rollbar }, children });
|
35
|
+
};
|
36
|
+
// Annotate the CommonJS export names for ESM import in node:
|
37
|
+
0 && (module.exports = {
|
38
|
+
ErrorReporterProvider
|
39
|
+
});
|
40
|
+
//# sourceMappingURL=Provider.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Provider.tsx"],"sourcesContent":["import { WithChildren } from '@xylabs/react-shared'\nimport { useEffect, useState } from 'react'\nimport Rollbar from 'rollbar'\n\nimport { ErrorReporterContext } from './Context'\n\nexport interface ErrorReporterProviderProps {\n rollbar: Rollbar\n}\n\nconst ErrorReporterProvider: React.FC<WithChildren<ErrorReporterProviderProps>> = ({ children, rollbar }) => {\n const [rollbarInstance, setRollBarInstance] = useState<Rollbar>()\n\n useEffect(() => {\n if (rollbarInstance) {\n setRollBarInstance(rollbarInstance)\n }\n }, [rollbar, rollbarInstance])\n\n return <ErrorReporterContext.Provider value={{ rollbar }}>{children}</ErrorReporterContext.Provider>\n}\n\nexport { ErrorReporterProvider }\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBS;AAlBT,mBAAoC;AAGpC,qBAAqC;AAMrC,MAAM,wBAA4E,CAAC,EAAE,UAAU,QAAQ,MAAM;AAC3G,QAAM,CAAC,iBAAiB,kBAAkB,QAAI,uBAAkB;AAEhE,8BAAU,MAAM;AACd,QAAI,iBAAiB;AACnB,yBAAmB,eAAe;AAAA,IACpC;AAAA,EACF,GAAG,CAAC,SAAS,eAAe,CAAC;AAE7B,SAAO,4CAAC,oCAAqB,UAArB,EAA8B,OAAO,EAAE,QAAQ,GAAI,UAAS;AACtE;","names":[]}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
2
|
+
import { useEffect, useState } from "react";
|
3
|
+
import { ErrorReporterContext } from "./Context";
|
4
|
+
const ErrorReporterProvider = ({ children, rollbar }) => {
|
5
|
+
const [rollbarInstance, setRollBarInstance] = useState();
|
6
|
+
useEffect(() => {
|
7
|
+
if (rollbarInstance) {
|
8
|
+
setRollBarInstance(rollbarInstance);
|
9
|
+
}
|
10
|
+
}, [rollbar, rollbarInstance]);
|
11
|
+
return /* @__PURE__ */ jsx(ErrorReporterContext.Provider, { value: { rollbar }, children });
|
12
|
+
};
|
13
|
+
export {
|
14
|
+
ErrorReporterProvider
|
15
|
+
};
|
16
|
+
//# sourceMappingURL=Provider.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Provider.tsx"],"sourcesContent":["import { WithChildren } from '@xylabs/react-shared'\nimport { useEffect, useState } from 'react'\nimport Rollbar from 'rollbar'\n\nimport { ErrorReporterContext } from './Context'\n\nexport interface ErrorReporterProviderProps {\n rollbar: Rollbar\n}\n\nconst ErrorReporterProvider: React.FC<WithChildren<ErrorReporterProviderProps>> = ({ children, rollbar }) => {\n const [rollbarInstance, setRollBarInstance] = useState<Rollbar>()\n\n useEffect(() => {\n if (rollbarInstance) {\n setRollBarInstance(rollbarInstance)\n }\n }, [rollbar, rollbarInstance])\n\n return <ErrorReporterContext.Provider value={{ rollbar }}>{children}</ErrorReporterContext.Provider>\n}\n\nexport { ErrorReporterProvider }\n"],"mappings":"AAmBS;AAlBT,SAAS,WAAW,gBAAgB;AAGpC,SAAS,4BAA4B;AAMrC,MAAM,wBAA4E,CAAC,EAAE,UAAU,QAAQ,MAAM;AAC3G,QAAM,CAAC,iBAAiB,kBAAkB,IAAI,SAAkB;AAEhE,YAAU,MAAM;AACd,QAAI,iBAAiB;AACnB,yBAAmB,eAAe;AAAA,IACpC;AAAA,EACF,GAAG,CAAC,SAAS,eAAe,CAAC;AAE7B,SAAO,oBAAC,qBAAqB,UAArB,EAA8B,OAAO,EAAE,QAAQ,GAAI,UAAS;AACtE;","names":[]}
|
@@ -0,0 +1,69 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __create = Object.create;
|
3
|
+
var __defProp = Object.defineProperty;
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
8
|
+
var __export = (target, all) => {
|
9
|
+
for (var name in all)
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
11
|
+
};
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
14
|
+
for (let key of __getOwnPropNames(from))
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
17
|
+
}
|
18
|
+
return to;
|
19
|
+
};
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
26
|
+
mod
|
27
|
+
));
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
29
|
+
var Provider_stories_exports = {};
|
30
|
+
__export(Provider_stories_exports, {
|
31
|
+
Default: () => Default,
|
32
|
+
default: () => Provider_stories_default
|
33
|
+
});
|
34
|
+
module.exports = __toCommonJS(Provider_stories_exports);
|
35
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
36
|
+
var import_material = require("@mui/material");
|
37
|
+
var import_rollbar = __toESM(require("rollbar"));
|
38
|
+
var import_Provider = require("./Provider");
|
39
|
+
var import_useRollbar = require("./useRollbar");
|
40
|
+
const StorybookEntry = {
|
41
|
+
argTypes: {},
|
42
|
+
component: import_Provider.ErrorReporterProvider,
|
43
|
+
parameters: {
|
44
|
+
docs: {
|
45
|
+
page: null
|
46
|
+
}
|
47
|
+
},
|
48
|
+
title: "auth-service/ErrorReporterProvider"
|
49
|
+
};
|
50
|
+
const RollbarComponent = () => {
|
51
|
+
const { rollbar } = (0, import_useRollbar.useRollbar)();
|
52
|
+
const rollbarFound = typeof rollbar?.error === "function";
|
53
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_material.Typography, { color: rollbarFound ? "green" : "red", children: [
|
54
|
+
"Rollbar instance ",
|
55
|
+
rollbarFound ? "" : "NOT",
|
56
|
+
" found from context!"
|
57
|
+
] });
|
58
|
+
};
|
59
|
+
const Template = () => {
|
60
|
+
const rollbar = new import_rollbar.default();
|
61
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Provider.ErrorReporterProvider, { rollbar, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(RollbarComponent, {}) });
|
62
|
+
};
|
63
|
+
const Default = Template.bind({});
|
64
|
+
var Provider_stories_default = StorybookEntry;
|
65
|
+
// Annotate the CommonJS export names for ESM import in node:
|
66
|
+
0 && (module.exports = {
|
67
|
+
Default
|
68
|
+
});
|
69
|
+
//# sourceMappingURL=Provider.stories.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Provider.stories.tsx"],"sourcesContent":["import { Typography } from '@mui/material'\nimport { Meta, StoryFn } from '@storybook/react'\nimport Rollbar from 'rollbar'\n\nimport { ErrorReporterProvider } from './Provider'\nimport { useRollbar } from './useRollbar'\n\nconst StorybookEntry = {\n argTypes: {},\n component: ErrorReporterProvider,\n parameters: {\n docs: {\n page: null,\n },\n },\n title: 'auth-service/ErrorReporterProvider',\n} as Meta<typeof ErrorReporterProvider>\n\nconst RollbarComponent = () => {\n const { rollbar } = useRollbar()\n const rollbarFound = typeof rollbar?.error === 'function'\n\n return <Typography color={rollbarFound ? 'green' : 'red'}>Rollbar instance {rollbarFound ? '' : 'NOT'} found from context!</Typography>\n}\n\nconst Template: StoryFn<typeof ErrorReporterProvider> = () => {\n const rollbar = new Rollbar()\n return (\n <ErrorReporterProvider rollbar={rollbar}>\n <RollbarComponent />\n </ErrorReporterProvider>\n )\n}\n\nconst Default = Template.bind({})\n\nexport { Default }\n\n// eslint-disable-next-line import/no-default-export\nexport default StorybookEntry\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAsBS;AAtBT,sBAA2B;AAE3B,qBAAoB;AAEpB,sBAAsC;AACtC,wBAA2B;AAE3B,MAAM,iBAAiB;AAAA,EACrB,UAAU,CAAC;AAAA,EACX,WAAW;AAAA,EACX,YAAY;AAAA,IACV,MAAM;AAAA,MACJ,MAAM;AAAA,IACR;AAAA,EACF;AAAA,EACA,OAAO;AACT;AAEA,MAAM,mBAAmB,MAAM;AAC7B,QAAM,EAAE,QAAQ,QAAI,8BAAW;AAC/B,QAAM,eAAe,OAAO,SAAS,UAAU;AAE/C,SAAO,6CAAC,8BAAW,OAAO,eAAe,UAAU,OAAO;AAAA;AAAA,IAAkB,eAAe,KAAK;AAAA,IAAM;AAAA,KAAoB;AAC5H;AAEA,MAAM,WAAkD,MAAM;AAC5D,QAAM,UAAU,IAAI,eAAAA,QAAQ;AAC5B,SACE,4CAAC,yCAAsB,SACrB,sDAAC,oBAAiB,GACpB;AAEJ;AAEA,MAAM,UAAU,SAAS,KAAK,CAAC,CAAC;AAKhC,IAAO,2BAAQ;","names":["Rollbar"]}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
2
|
+
import { Typography } from "@mui/material";
|
3
|
+
import Rollbar from "rollbar";
|
4
|
+
import { ErrorReporterProvider } from "./Provider";
|
5
|
+
import { useRollbar } from "./useRollbar";
|
6
|
+
const StorybookEntry = {
|
7
|
+
argTypes: {},
|
8
|
+
component: ErrorReporterProvider,
|
9
|
+
parameters: {
|
10
|
+
docs: {
|
11
|
+
page: null
|
12
|
+
}
|
13
|
+
},
|
14
|
+
title: "auth-service/ErrorReporterProvider"
|
15
|
+
};
|
16
|
+
const RollbarComponent = () => {
|
17
|
+
const { rollbar } = useRollbar();
|
18
|
+
const rollbarFound = typeof rollbar?.error === "function";
|
19
|
+
return /* @__PURE__ */ jsxs(Typography, { color: rollbarFound ? "green" : "red", children: [
|
20
|
+
"Rollbar instance ",
|
21
|
+
rollbarFound ? "" : "NOT",
|
22
|
+
" found from context!"
|
23
|
+
] });
|
24
|
+
};
|
25
|
+
const Template = () => {
|
26
|
+
const rollbar = new Rollbar();
|
27
|
+
return /* @__PURE__ */ jsx(ErrorReporterProvider, { rollbar, children: /* @__PURE__ */ jsx(RollbarComponent, {}) });
|
28
|
+
};
|
29
|
+
const Default = Template.bind({});
|
30
|
+
var Provider_stories_default = StorybookEntry;
|
31
|
+
export {
|
32
|
+
Default,
|
33
|
+
Provider_stories_default as default
|
34
|
+
};
|
35
|
+
//# sourceMappingURL=Provider.stories.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/Provider.stories.tsx"],"sourcesContent":["import { Typography } from '@mui/material'\nimport { Meta, StoryFn } from '@storybook/react'\nimport Rollbar from 'rollbar'\n\nimport { ErrorReporterProvider } from './Provider'\nimport { useRollbar } from './useRollbar'\n\nconst StorybookEntry = {\n argTypes: {},\n component: ErrorReporterProvider,\n parameters: {\n docs: {\n page: null,\n },\n },\n title: 'auth-service/ErrorReporterProvider',\n} as Meta<typeof ErrorReporterProvider>\n\nconst RollbarComponent = () => {\n const { rollbar } = useRollbar()\n const rollbarFound = typeof rollbar?.error === 'function'\n\n return <Typography color={rollbarFound ? 'green' : 'red'}>Rollbar instance {rollbarFound ? '' : 'NOT'} found from context!</Typography>\n}\n\nconst Template: StoryFn<typeof ErrorReporterProvider> = () => {\n const rollbar = new Rollbar()\n return (\n <ErrorReporterProvider rollbar={rollbar}>\n <RollbarComponent />\n </ErrorReporterProvider>\n )\n}\n\nconst Default = Template.bind({})\n\nexport { Default }\n\n// eslint-disable-next-line import/no-default-export\nexport default StorybookEntry\n"],"mappings":"AAsBS,SAOH,KAPG;AAtBT,SAAS,kBAAkB;AAE3B,OAAO,aAAa;AAEpB,SAAS,6BAA6B;AACtC,SAAS,kBAAkB;AAE3B,MAAM,iBAAiB;AAAA,EACrB,UAAU,CAAC;AAAA,EACX,WAAW;AAAA,EACX,YAAY;AAAA,IACV,MAAM;AAAA,MACJ,MAAM;AAAA,IACR;AAAA,EACF;AAAA,EACA,OAAO;AACT;AAEA,MAAM,mBAAmB,MAAM;AAC7B,QAAM,EAAE,QAAQ,IAAI,WAAW;AAC/B,QAAM,eAAe,OAAO,SAAS,UAAU;AAE/C,SAAO,qBAAC,cAAW,OAAO,eAAe,UAAU,OAAO;AAAA;AAAA,IAAkB,eAAe,KAAK;AAAA,IAAM;AAAA,KAAoB;AAC5H;AAEA,MAAM,WAAkD,MAAM;AAC5D,QAAM,UAAU,IAAI,QAAQ;AAC5B,SACE,oBAAC,yBAAsB,SACrB,8BAAC,oBAAiB,GACpB;AAEJ;AAEA,MAAM,UAAU,SAAS,KAAK,CAAC,CAAC;AAKhC,IAAO,2BAAQ;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"State.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/State.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,SAAS,CAAA;AAE7B,MAAM,WAAW,yBAAyB;IACxC,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"State.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/State.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,SAAS,CAAA;AAE7B,MAAM,WAAW,yBAAyB;IACxC,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB"}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
8
|
+
for (let key of __getOwnPropNames(from))
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
11
|
+
}
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
15
|
+
var State_exports = {};
|
16
|
+
module.exports = __toCommonJS(State_exports);
|
17
|
+
//# sourceMappingURL=State.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/State.ts"],"sourcesContent":["import Rollbar from 'rollbar'\n\nexport interface ErrorReporterContextState {\n rollbar?: Rollbar\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
//# sourceMappingURL=State.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,SAAS,CAAA;AACvB,cAAc,cAAc,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,SAAS,CAAA;AACvB,cAAc,cAAc,CAAA"}
|
@@ -0,0 +1,27 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
8
|
+
for (let key of __getOwnPropNames(from))
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
11
|
+
}
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
16
|
+
var ErrorReporter_exports = {};
|
17
|
+
module.exports = __toCommonJS(ErrorReporter_exports);
|
18
|
+
__reExport(ErrorReporter_exports, require("./Provider"), module.exports);
|
19
|
+
__reExport(ErrorReporter_exports, require("./State"), module.exports);
|
20
|
+
__reExport(ErrorReporter_exports, require("./useRollbar"), module.exports);
|
21
|
+
// Annotate the CommonJS export names for ESM import in node:
|
22
|
+
0 && (module.exports = {
|
23
|
+
...require("./Provider"),
|
24
|
+
...require("./State"),
|
25
|
+
...require("./useRollbar")
|
26
|
+
});
|
27
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/index.ts"],"sourcesContent":["export * from './Provider'\nexport * from './State'\nexport * from './useRollbar'\n"],"mappings":";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,kCAAc,uBAAd;AACA,kCAAc,oBADd;AAEA,kCAAc,yBAFd;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/index.ts"],"sourcesContent":["export * from './Provider'\nexport * from './State'\nexport * from './useRollbar'\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useRollbar.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/useRollbar.tsx"],"names":[],"mappings":"AAIA,QAAA,MAAM,UAAU,mDAOf,CAAA;AAED,OAAO,EAAE,UAAU,EAAE,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useRollbar.d.ts","sourceRoot":"","sources":["../../../../src/contexts/ErrorReporter/useRollbar.tsx"],"names":[],"mappings":"AAIA,QAAA,MAAM,UAAU,mDAOf,CAAA;AAED,OAAO,EAAE,UAAU,EAAE,CAAA"}
|
@@ -0,0 +1,37 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
9
|
+
};
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
12
|
+
for (let key of __getOwnPropNames(from))
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
15
|
+
}
|
16
|
+
return to;
|
17
|
+
};
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
19
|
+
var useRollbar_exports = {};
|
20
|
+
__export(useRollbar_exports, {
|
21
|
+
useRollbar: () => useRollbar
|
22
|
+
});
|
23
|
+
module.exports = __toCommonJS(useRollbar_exports);
|
24
|
+
var import_react = require("react");
|
25
|
+
var import_Context = require("./Context");
|
26
|
+
const useRollbar = () => {
|
27
|
+
const context = (0, import_react.useContext)(import_Context.ErrorReporterContext);
|
28
|
+
if (context === void 0) {
|
29
|
+
console.warn("useRollbar must be used within a ErrorReporterContext");
|
30
|
+
}
|
31
|
+
return context ?? {};
|
32
|
+
};
|
33
|
+
// Annotate the CommonJS export names for ESM import in node:
|
34
|
+
0 && (module.exports = {
|
35
|
+
useRollbar
|
36
|
+
});
|
37
|
+
//# sourceMappingURL=useRollbar.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/useRollbar.tsx"],"sourcesContent":["import { useContext } from 'react'\n\nimport { ErrorReporterContext } from './Context'\n\nconst useRollbar = () => {\n const context = useContext(ErrorReporterContext)\n if (context === undefined) {\n console.warn('useRollbar must be used within a ErrorReporterContext')\n }\n\n return context ?? {}\n}\n\nexport { useRollbar }\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA2B;AAE3B,qBAAqC;AAErC,MAAM,aAAa,MAAM;AACvB,QAAM,cAAU,yBAAW,mCAAoB;AAC/C,MAAI,YAAY,QAAW;AACzB,YAAQ,KAAK,uDAAuD;AAAA,EACtE;AAEA,SAAO,WAAW,CAAC;AACrB;","names":[]}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import { useContext } from "react";
|
2
|
+
import { ErrorReporterContext } from "./Context";
|
3
|
+
const useRollbar = () => {
|
4
|
+
const context = useContext(ErrorReporterContext);
|
5
|
+
if (context === void 0) {
|
6
|
+
console.warn("useRollbar must be used within a ErrorReporterContext");
|
7
|
+
}
|
8
|
+
return context ?? {};
|
9
|
+
};
|
10
|
+
export {
|
11
|
+
useRollbar
|
12
|
+
};
|
13
|
+
//# sourceMappingURL=useRollbar.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../../src/contexts/ErrorReporter/useRollbar.tsx"],"sourcesContent":["import { useContext } from 'react'\n\nimport { ErrorReporterContext } from './Context'\n\nconst useRollbar = () => {\n const context = useContext(ErrorReporterContext)\n if (context === undefined) {\n console.warn('useRollbar must be used within a ErrorReporterContext')\n }\n\n return context ?? {}\n}\n\nexport { useRollbar }\n"],"mappings":"AAAA,SAAS,kBAAkB;AAE3B,SAAS,4BAA4B;AAErC,MAAM,aAAa,MAAM;AACvB,QAAM,UAAU,WAAW,oBAAoB;AAC/C,MAAI,YAAY,QAAW;AACzB,YAAQ,KAAK,uDAAuD;AAAA,EACtE;AAEA,SAAO,WAAW,CAAC;AACrB;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/contexts/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/contexts/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA"}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
8
|
+
for (let key of __getOwnPropNames(from))
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
11
|
+
}
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
16
|
+
var contexts_exports = {};
|
17
|
+
module.exports = __toCommonJS(contexts_exports);
|
18
|
+
__reExport(contexts_exports, require("./ErrorReporter"), module.exports);
|
19
|
+
// Annotate the CommonJS export names for ESM import in node:
|
20
|
+
0 && (module.exports = {
|
21
|
+
...require("./ErrorReporter")
|
22
|
+
});
|
23
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/contexts/index.ts"],"sourcesContent":["export * from './ErrorReporter'\n"],"mappings":";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,6BAAc,4BAAd;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/contexts/index.ts"],"sourcesContent":["export * from './ErrorReporter'\n"],"mappings":"AAAA,cAAc;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA"}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
8
|
+
for (let key of __getOwnPropNames(from))
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
11
|
+
}
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
16
|
+
var src_exports = {};
|
17
|
+
module.exports = __toCommonJS(src_exports);
|
18
|
+
__reExport(src_exports, require("./components"), module.exports);
|
19
|
+
__reExport(src_exports, require("./contexts"), module.exports);
|
20
|
+
// Annotate the CommonJS export names for ESM import in node:
|
21
|
+
0 && (module.exports = {
|
22
|
+
...require("./components"),
|
23
|
+
...require("./contexts")
|
24
|
+
});
|
25
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../src/index.ts"],"sourcesContent":["export * from './components'\nexport * from './contexts'\n"],"mappings":";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,wBAAc,yBAAd;AACA,wBAAc,uBADd;","names":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../src/index.ts"],"sourcesContent":["export * from './components'\nexport * from './contexts'\n"],"mappings":"AAAA,cAAc;AACd,cAAc;","names":[]}
|
package/package.json
CHANGED
@@ -10,10 +10,10 @@
|
|
10
10
|
"url": "https://github.com/XYOracleNetwork/sdk-xyo-react-js/issues"
|
11
11
|
},
|
12
12
|
"dependencies": {
|
13
|
-
"@xylabs/react-button": "^3.1.0-rc.
|
14
|
-
"@xylabs/react-flexbox": "^3.1.0-rc.
|
15
|
-
"@xylabs/react-shared": "^3.1.0-rc.
|
16
|
-
"@xyo-network/payload-model": "^2.74.
|
13
|
+
"@xylabs/react-button": "^3.1.0-rc.6",
|
14
|
+
"@xylabs/react-flexbox": "^3.1.0-rc.6",
|
15
|
+
"@xylabs/react-shared": "^3.1.0-rc.6",
|
16
|
+
"@xyo-network/payload-model": "^2.74.5"
|
17
17
|
},
|
18
18
|
"peerDependencies": {
|
19
19
|
"@mui/icons-material": "^5",
|
@@ -26,8 +26,8 @@
|
|
26
26
|
},
|
27
27
|
"devDependencies": {
|
28
28
|
"@storybook/react": "^7.4.3",
|
29
|
-
"@xylabs/ts-scripts-yarn3": "^3.0.
|
30
|
-
"@xylabs/tsconfig-react": "^3.0.
|
29
|
+
"@xylabs/ts-scripts-yarn3": "^3.0.55",
|
30
|
+
"@xylabs/tsconfig-react": "^3.0.55",
|
31
31
|
"typescript": "^5.2.2"
|
32
32
|
},
|
33
33
|
"peerDependenciesMeta": {
|
@@ -41,30 +41,30 @@
|
|
41
41
|
".": {
|
42
42
|
"node": {
|
43
43
|
"import": {
|
44
|
-
"types": "./dist/index.d.mts",
|
45
|
-
"default": "./dist/index.mjs"
|
44
|
+
"types": "./dist/node/index.d.mts",
|
45
|
+
"default": "./dist/node/index.mjs"
|
46
46
|
},
|
47
47
|
"require": {
|
48
|
-
"types": "./dist/index.d.ts",
|
49
|
-
"default": "./dist/index.js"
|
48
|
+
"types": "./dist/node/index.d.ts",
|
49
|
+
"default": "./dist/node/index.js"
|
50
50
|
}
|
51
51
|
},
|
52
52
|
"browser": {
|
53
53
|
"import": {
|
54
|
-
"types": "./dist/index.d.
|
55
|
-
"default": "./dist/index.
|
54
|
+
"types": "./dist/browser/index.d.ts",
|
55
|
+
"default": "./dist/browser/index.js"
|
56
56
|
},
|
57
57
|
"require": {
|
58
|
-
"types": "./dist/index.d.ts",
|
59
|
-
"default": "./dist/index.js"
|
58
|
+
"types": "./dist/browser/index.d.ts",
|
59
|
+
"default": "./dist/browser/index.js"
|
60
60
|
}
|
61
61
|
},
|
62
|
-
"default": "./dist/index.mjs"
|
62
|
+
"default": "./dist/browser/index.mjs"
|
63
63
|
},
|
64
64
|
"./package.json": "./package.json"
|
65
65
|
},
|
66
|
-
"main": "dist/index.js",
|
67
|
-
"module": "dist/index.
|
66
|
+
"main": "dist/browser/index.js",
|
67
|
+
"module": "dist/browser/index.js",
|
68
68
|
"homepage": "https://xyo.network",
|
69
69
|
"keywords": [
|
70
70
|
"xyo",
|
@@ -85,7 +85,7 @@
|
|
85
85
|
"license": "yarn license-checker --exclude \"MIT, ISC, Apache-2.0, BSD, BSD-2-Clause, CC-BY-4.0, Unlicense, CC-BY-3.0, CC0-1.0\""
|
86
86
|
},
|
87
87
|
"sideEffects": false,
|
88
|
-
"types": "dist/index.d.ts",
|
89
|
-
"version": "2.64.0-rc.
|
88
|
+
"types": "dist/browser/index.d.ts",
|
89
|
+
"version": "2.64.0-rc.4",
|
90
90
|
"stableVersion": "2.63.1"
|
91
91
|
}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"ThrownErrorBoundary.d.ts","sourceRoot":"","sources":["../../../src/components/ErrorBoundary/ThrownErrorBoundary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAqB,MAAM,4BAA4B,CAAA;AAC3E,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACvD,OAAO,OAAO,MAAM,SAAS,CAAA;AAI7B,MAAM,WAAW,wBAAwB;IACvC,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,EAAE,SAAS,CAAA;IACnB,cAAc,CAAC,EAAE,CAAC,CAAC,EAAE,WAAW,EAAE,YAAY,CAAC,EAAE,MAAM,KAAK,SAAS,CAAA;IACrE,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,EAAE,WAAW,CAAA;CACvB;AAED,qBAAa,mBAAoB,SAAQ,SAAS,CAAC,wBAAwB,EAAE,wBAAwB,CAAC;IACpF,KAAK,EAAE,wBAAwB,CAE9C;IAED,MAAM,CAAC,wBAAwB,CAAC,KAAK,EAAE,KAAK;WAI9B,cAAc,CAAC,KAAK,EAAE,KAAK,GAAG,WAAW,GAAG,WAAW;IAMrD,iBAAiB,CAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,SAAS;IAYpD,MAAM;CAYvB"}
|