@burdenoff/fe-libs 2026.601.6 → 2026.601.8
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/chrome/ProductSideNav.d.ts.map +1 -1
- package/dist/chrome/SideNavigation.d.ts.map +1 -1
- package/dist/chrome/sideNavigation/NavItemRenderer.d.ts.map +1 -1
- package/dist/shared/components/PWAInstallBanner.d.ts.map +1 -1
- package/dist/shared/graphql/client.d.ts.map +1 -1
- package/dist/shared/graphql/client.js +61 -61
- package/dist/shared/graphql/fetch.d.ts.map +1 -1
- package/dist/shared/graphql/fetch.js +120 -120
- package/dist/shared/providers/AppShellProvider.d.ts.map +1 -1
- package/dist/shared/providers/AppShellProvider.js +204 -169
- package/dist/shared/providers/shell/ProfileStorageManager.d.ts +1 -1
- package/dist/shared/providers/shell/ProfileStorageManager.d.ts.map +1 -1
- package/dist/shared/providers/shell/ProfileStorageManager.js +110 -102
- package/dist/shared/providers/shell/authProvider/useAuthActions.d.ts.map +1 -1
- package/dist/shared/providers/shell/authProvider/useAuthActions.js +12 -10
- package/dist/shared/providers/shell/authProvider/useTokenExpiryTimer.d.ts.map +1 -1
- package/dist/shared/providers/shell/authProvider/useTokenExpiryTimer.js +8 -8
- package/dist/shared/utils/apollo.js +1 -1
- package/dist/shared/utils/authCookie.d.ts.map +1 -1
- package/dist/shared/utils/authCookie.js +1 -1
- package/dist/shared/utils/authErrorHandling.d.ts.map +1 -1
- package/dist/shared/utils/authErrorHandling.js +23 -8
- package/dist/shared/utils/backendErrors.d.ts +23 -0
- package/dist/shared/utils/backendErrors.d.ts.map +1 -1
- package/dist/shared/utils/backendErrors.js +113 -39
- package/dist/shared/utils/index.d.ts +2 -2
- package/dist/shared/utils/index.d.ts.map +1 -1
- package/dist/shared-utils.js +12 -12
- package/dist/shared.js +97 -97
- package/package.json +1 -1
|
@@ -1,44 +1,44 @@
|
|
|
1
1
|
import { isShellLessRoute as e } from "../config/shellRoutes.js";
|
|
2
2
|
import { readActiveContextValueWithUrlPrecedence as t } from "./shell/ActiveContextStorage.js";
|
|
3
|
-
import { BACKEND_ERROR_EVENT as n,
|
|
4
|
-
import { graphqlFetch as
|
|
5
|
-
import { attemptTokenRefresh as
|
|
6
|
-
import { AuthProvider as
|
|
7
|
-
import { ActiveContextProvider as
|
|
8
|
-
import { LogManager as
|
|
3
|
+
import { BACKEND_ERROR_EVENT as n, CONNECTION_STATUS_EVENT as r, dispatchBackendErrorEvent as i, isBackendErrorDisplay as a, shouldToastBackendError as o } from "../utils/backendErrors.js";
|
|
4
|
+
import { graphqlFetch as s } from "../graphql/fetch.js";
|
|
5
|
+
import { attemptTokenRefresh as c, clearAuthSessionStorage as l, isAuthNetworkError as ee } from "../utils/authErrorHandling.js";
|
|
6
|
+
import { AuthProvider as te } from "./shell/AuthProvider.js";
|
|
7
|
+
import { ActiveContextProvider as ne } from "./shell/ActiveContextProvider.js";
|
|
8
|
+
import { LogManager as u } from "../logger/LogManager.js";
|
|
9
9
|
import { ConsoleTransport as d } from "../logger/ConsoleTransport.js";
|
|
10
10
|
import { ThemeProvider as f } from "./shell/ThemeProvider.js";
|
|
11
|
-
import { ErrorFallback as
|
|
12
|
-
import { m } from "../../node_modules/react-error-boundary/dist/react-error-boundary.js";
|
|
13
|
-
import { PWAInstallBanner as
|
|
14
|
-
import { FeatureFlagsProvider as
|
|
15
|
-
import { FeatureFlagProvider as
|
|
16
|
-
import { GlobalUiProvider as
|
|
17
|
-
import { ShellUiProvider as
|
|
18
|
-
import { ContextManagerProvider as
|
|
19
|
-
import { AuthTokenProvider as
|
|
20
|
-
import { MultiGatewayProvider as
|
|
11
|
+
import { ErrorFallback as re } from "../components/ErrorFallback.js";
|
|
12
|
+
import { m as p } from "../../node_modules/react-error-boundary/dist/react-error-boundary.js";
|
|
13
|
+
import { PWAInstallBanner as m } from "../components/PWAInstallBanner.js";
|
|
14
|
+
import { FeatureFlagsProvider as h } from "./shell/FeatureFlagsProvider.js";
|
|
15
|
+
import { FeatureFlagProvider as g } from "../feature-flags/FeatureFlagProvider.js";
|
|
16
|
+
import { GlobalUiProvider as _ } from "./shell/GlobalUiProvider.js";
|
|
17
|
+
import { ShellUiProvider as v } from "./shell/ShellUiProvider.js";
|
|
18
|
+
import { ContextManagerProvider as y } from "./shell/ContextManagerProvider.js";
|
|
19
|
+
import { AuthTokenProvider as ie } from "./shell/AuthTokenProvider.js";
|
|
20
|
+
import { MultiGatewayProvider as ae } from "./shell/MultiGatewayProvider.js";
|
|
21
21
|
import { G as b, j as x, w as S } from "../../node_modules/web-vitals/dist/web-vitals.js";
|
|
22
22
|
import { ProfileI18nBridge as C } from "./shell/ProfileI18nBridge.js";
|
|
23
23
|
import { ProfileGeographyBridge as w } from "./shell/ProfileGeographyBridge.js";
|
|
24
|
-
import { AppShellContextProvider as
|
|
25
|
-
import { DevtoolsSink as
|
|
26
|
-
import { BroadcastChannelSink as
|
|
27
|
-
import { BackendAuditSink as
|
|
28
|
-
import { RybbitSink as
|
|
29
|
-
import { OtelBrowserSink as
|
|
30
|
-
import { EventBusProvider as
|
|
31
|
-
import { useReferralAttribution as
|
|
32
|
-
import { TourPlayerProvider as
|
|
33
|
-
import { ToursProvider as
|
|
34
|
-
import { TourInitializer as
|
|
35
|
-
import { Suspense as
|
|
36
|
-
import { Fragment as
|
|
37
|
-
import { BrowserRouter as
|
|
38
|
-
import { Toaster as
|
|
39
|
-
import { MutationCache as
|
|
24
|
+
import { AppShellContextProvider as oe } from "./shell/AppShellContext.js";
|
|
25
|
+
import { DevtoolsSink as T } from "../events/sinks/DevtoolsSink.js";
|
|
26
|
+
import { BroadcastChannelSink as E } from "../events/sinks/BroadcastChannelSink.js";
|
|
27
|
+
import { BackendAuditSink as D } from "../events/sinks/BackendAuditSink.js";
|
|
28
|
+
import { RybbitSink as O } from "../events/sinks/RybbitSink.js";
|
|
29
|
+
import { OtelBrowserSink as k } from "../events/sinks/OtelBrowserSink.js";
|
|
30
|
+
import { EventBusProvider as A, useEventBus as j } from "../../shared-events.js";
|
|
31
|
+
import { useReferralAttribution as M } from "../hooks/useReferralAttribution.js";
|
|
32
|
+
import { TourPlayerProvider as N } from "../tours/TourPlayerProvider.js";
|
|
33
|
+
import { ToursProvider as P, useToursContext as F } from "../tours/ToursContext.js";
|
|
34
|
+
import { TourInitializer as I } from "../tours/TourInitializer.js";
|
|
35
|
+
import { Suspense as L, useCallback as R, useEffect as z, useMemo as B, useRef as V } from "react";
|
|
36
|
+
import { Fragment as H, jsx as U, jsxs as W } from "react/jsx-runtime";
|
|
37
|
+
import { BrowserRouter as G, useLocation as K } from "react-router-dom";
|
|
38
|
+
import { Toaster as q, toast as J } from "sonner";
|
|
39
|
+
import { MutationCache as se, QueryCache as ce, QueryClient as le, QueryClientProvider as ue } from "@tanstack/react-query";
|
|
40
40
|
//#region src/shared/providers/AppShellProvider.tsx
|
|
41
|
-
var
|
|
41
|
+
var Y = {
|
|
42
42
|
bigconsole: {
|
|
43
43
|
prod: "292459a3e86c",
|
|
44
44
|
nonProd: "a7e7362b0de3"
|
|
@@ -57,8 +57,8 @@ var X = {
|
|
|
57
57
|
},
|
|
58
58
|
vibecontrols: { prod: "8a46449d9c07" },
|
|
59
59
|
workspaces: { prod: "da0c142f4b2e" }
|
|
60
|
-
},
|
|
61
|
-
function
|
|
60
|
+
}, X = /* @__PURE__ */ "nav.route.changed,auth.signed_in,auth.signed_out,support.ticket.created,support.ticket.closed,support.ticket.reopened,support.kb.article_rated,conversations.conversation.created,conversations.conversation.archived,notification.item.opened,notification.preference.updated,notification.admin.sent,notification.template.saved,notification.schedule.updated,vibecontrols.agent.registered,vibecontrols.agent.gateway_auth_setup,vibecontrols.session.created,vibecontrols.session.started,vibecontrols.session.terminal_opened_in_browser,vibecontrols.session.share_link_created,vibecontrols.session.joined_shared,vibecontrols.tunnel.created,vibecontrols.tunnel.started,vibecontrols.vibedeck.button_executed,vibecontrols.quota.agent_limit_hit,vibecontrols.quota.session_limit_hit,vibecontrols.quota.tunnel_limit_hit,vibecontrols.billing.upgrade_clicked".split(","), de = 4e3;
|
|
61
|
+
function fe(e) {
|
|
62
62
|
let t = e.technicalMessage ?? e.extensions?.technicalMessage, n = {
|
|
63
63
|
code: e.code,
|
|
64
64
|
operationName: e.operationName,
|
|
@@ -70,13 +70,13 @@ function le(e) {
|
|
|
70
70
|
};
|
|
71
71
|
console.error("[Burdenoff backend error]", e.message, n);
|
|
72
72
|
}
|
|
73
|
-
function
|
|
73
|
+
function pe(e) {
|
|
74
74
|
return e === "prod" || e === "production" ? "prod" : e === "alpha" || e === "staging" ? "alpha" : "dev";
|
|
75
75
|
}
|
|
76
|
-
function
|
|
76
|
+
function me(e, t) {
|
|
77
77
|
return e.VITE_DISABLE_ANALYTICS === "true" ? !1 : e.VITE_ENABLE_ANALYTICS === "true" || e.PROD || t !== "dev" ? !0 : e.VITE_ENABLE_ANALYTICS !== "false";
|
|
78
78
|
}
|
|
79
|
-
function
|
|
79
|
+
function he() {
|
|
80
80
|
return {
|
|
81
81
|
BASE_URL: "/",
|
|
82
82
|
DEV: !1,
|
|
@@ -85,8 +85,8 @@ function fe() {
|
|
|
85
85
|
SSR: !1
|
|
86
86
|
};
|
|
87
87
|
}
|
|
88
|
-
function
|
|
89
|
-
let n =
|
|
88
|
+
function Z(e, t) {
|
|
89
|
+
let n = pe(t.VITE_DEPLOY_ENV ?? t.MODE), r = me(t, n), i = Y[e], a = n === "prod" ? i?.prod : i?.nonProd, o = t.VITE_RYBBIT_SITE_ID || a, s = t.VITE_BACKEND_AUDIT_ENDPOINT || (t.PROD ? "/api/fe-events" : void 0);
|
|
90
90
|
return {
|
|
91
91
|
enabled: r,
|
|
92
92
|
appVersion: t.VITE_APP_VERSION || "0.0.0",
|
|
@@ -97,7 +97,7 @@ function $(e, t) {
|
|
|
97
97
|
enabled: r && !!o,
|
|
98
98
|
siteId: o,
|
|
99
99
|
scriptUrl: t.VITE_RYBBIT_SCRIPT_URL,
|
|
100
|
-
allowlist:
|
|
100
|
+
allowlist: X,
|
|
101
101
|
identifyOn: "auth.signed_in",
|
|
102
102
|
rename: { "nav.route.changed": "pageview" }
|
|
103
103
|
},
|
|
@@ -112,16 +112,16 @@ function $(e, t) {
|
|
|
112
112
|
}
|
|
113
113
|
};
|
|
114
114
|
}
|
|
115
|
-
function
|
|
116
|
-
let { trackProgress: a, recordStepCompletion: o, trackEvent: s } =
|
|
117
|
-
return /* @__PURE__ */
|
|
118
|
-
onTourStart:
|
|
115
|
+
function ge({ children: e, enablePWA: t, toasterPosition: n, productName: r, brandInitial: i }) {
|
|
116
|
+
let { trackProgress: a, recordStepCompletion: o, trackEvent: s } = F(), c = R((e, t) => e.steps?.[t], []);
|
|
117
|
+
return /* @__PURE__ */ W(N, {
|
|
118
|
+
onTourStart: R((e) => {
|
|
119
119
|
a(e.id, "started"), s("TOUR_STARTED", e.id);
|
|
120
120
|
}, [s, a]),
|
|
121
|
-
onTourComplete:
|
|
121
|
+
onTourComplete: R((e) => {
|
|
122
122
|
a(e.id, "completed"), s("TOUR_COMPLETED", e.id);
|
|
123
123
|
}, [s, a]),
|
|
124
|
-
onTourSkip:
|
|
124
|
+
onTourSkip: R((e, t) => {
|
|
125
125
|
let n = c(e, t);
|
|
126
126
|
a(e.id, "skipped"), s("TOUR_SKIPPED", e.id, {
|
|
127
127
|
stepId: n?.id,
|
|
@@ -132,14 +132,14 @@ function pe({ children: e, enablePWA: t, toasterPosition: n, productName: r, bra
|
|
|
132
132
|
s,
|
|
133
133
|
a
|
|
134
134
|
]),
|
|
135
|
-
onStepChange:
|
|
135
|
+
onStepChange: R((e, t) => {
|
|
136
136
|
let n = c(e, t);
|
|
137
137
|
n && s("STEP_VIEWED", e.id, {
|
|
138
138
|
stepId: n.id,
|
|
139
139
|
stepOrder: n.stepOrder
|
|
140
140
|
});
|
|
141
141
|
}, [c, s]),
|
|
142
|
-
onStepComplete:
|
|
142
|
+
onStepComplete: R((e, t) => {
|
|
143
143
|
let n = c(e, t);
|
|
144
144
|
n && (o(e.id, n.id), s("STEP_COMPLETED", e.id, {
|
|
145
145
|
stepId: n.id,
|
|
@@ -151,17 +151,18 @@ function pe({ children: e, enablePWA: t, toasterPosition: n, productName: r, bra
|
|
|
151
151
|
s
|
|
152
152
|
]),
|
|
153
153
|
children: [
|
|
154
|
-
/* @__PURE__ */
|
|
154
|
+
/* @__PURE__ */ U(I, {}),
|
|
155
155
|
e,
|
|
156
|
-
/* @__PURE__ */
|
|
157
|
-
/* @__PURE__ */
|
|
156
|
+
/* @__PURE__ */ U(_e, {}),
|
|
157
|
+
/* @__PURE__ */ U(ve, {}),
|
|
158
|
+
/* @__PURE__ */ U(q, {
|
|
158
159
|
position: n,
|
|
159
160
|
richColors: !0,
|
|
160
161
|
closeButton: !0
|
|
161
162
|
}),
|
|
162
|
-
t && /* @__PURE__ */
|
|
163
|
+
t && /* @__PURE__ */ U(L, {
|
|
163
164
|
fallback: null,
|
|
164
|
-
children: /* @__PURE__ */
|
|
165
|
+
children: /* @__PURE__ */ U(m, {
|
|
165
166
|
productName: r,
|
|
166
167
|
brandInitial: i
|
|
167
168
|
})
|
|
@@ -169,34 +170,68 @@ function pe({ children: e, enablePWA: t, toasterPosition: n, productName: r, bra
|
|
|
169
170
|
]
|
|
170
171
|
});
|
|
171
172
|
}
|
|
172
|
-
function
|
|
173
|
-
let e =
|
|
174
|
-
return
|
|
173
|
+
function _e() {
|
|
174
|
+
let e = V(null);
|
|
175
|
+
return z(() => {
|
|
175
176
|
let t = (t) => {
|
|
176
|
-
let n = t instanceof CustomEvent &&
|
|
177
|
-
if (!
|
|
178
|
-
|
|
179
|
-
let r = `${n.code ?? ""}|${n.message}`,
|
|
180
|
-
s?.key === r &&
|
|
177
|
+
let n = t instanceof CustomEvent && a(t.detail) ? t.detail : null;
|
|
178
|
+
if (!o(n)) return;
|
|
179
|
+
fe(n);
|
|
180
|
+
let r = `${n.code ?? ""}|${n.message}`, i = Date.now(), s = e.current;
|
|
181
|
+
s?.key === r && i - s.shownAt < de || (e.current = {
|
|
181
182
|
key: r,
|
|
182
|
-
shownAt:
|
|
183
|
-
},
|
|
183
|
+
shownAt: i
|
|
184
|
+
}, J.error(n.message, { duration: 7e3 }));
|
|
184
185
|
};
|
|
185
186
|
return window.addEventListener(n, t), () => window.removeEventListener(n, t);
|
|
186
187
|
}, []), null;
|
|
187
188
|
}
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
189
|
+
var Q = "burdenoff-connection-status", $ = 1500;
|
|
190
|
+
function ve() {
|
|
191
|
+
let e = V(null), t = V(!1);
|
|
192
|
+
return z(() => {
|
|
193
|
+
let n = () => {
|
|
194
|
+
t.current || (t.current = !0, J.error("Connection lost. Trying to reconnect…", {
|
|
195
|
+
id: Q,
|
|
196
|
+
duration: Infinity
|
|
197
|
+
}));
|
|
198
|
+
}, i = () => {
|
|
199
|
+
t.current || e.current || (e.current = setTimeout(() => {
|
|
200
|
+
e.current = null, n();
|
|
201
|
+
}, $));
|
|
202
|
+
}, a = (n) => {
|
|
203
|
+
if (e.current &&= (clearTimeout(e.current), null), !t.current) {
|
|
204
|
+
J.dismiss(Q);
|
|
205
|
+
return;
|
|
206
|
+
}
|
|
207
|
+
t.current = !1, n ? J.success("Back online", {
|
|
208
|
+
id: Q,
|
|
209
|
+
duration: 2500
|
|
210
|
+
}) : J.dismiss(Q);
|
|
211
|
+
}, o = (e) => {
|
|
212
|
+
if (!(e instanceof CustomEvent)) return;
|
|
213
|
+
let t = e.detail;
|
|
214
|
+
t && (t.online ? a(!0) : i());
|
|
215
|
+
}, s = () => i(), c = () => {
|
|
216
|
+
e.current &&= (clearTimeout(e.current), null);
|
|
217
|
+
};
|
|
218
|
+
return window.addEventListener(r, o), window.addEventListener("offline", s), window.addEventListener("online", c), () => {
|
|
219
|
+
window.removeEventListener(r, o), window.removeEventListener("offline", s), window.removeEventListener("online", c), e.current && clearTimeout(e.current);
|
|
220
|
+
};
|
|
221
|
+
}, []), null;
|
|
222
|
+
}
|
|
223
|
+
function ye({ children: e, i18nProductId: t, fallbackTranslations: n, defaultBrand: r, productName: i, brandInitial: a, enablePWA: o, toasterPosition: s }) {
|
|
224
|
+
let c = K();
|
|
225
|
+
M();
|
|
226
|
+
let l = /* @__PURE__ */ U(w, { children: /* @__PURE__ */ U(h, { children: /* @__PURE__ */ U(g, {
|
|
192
227
|
workspaceId: null,
|
|
193
228
|
gateway: "global",
|
|
194
229
|
defaultEnabled: !0,
|
|
195
|
-
children: /* @__PURE__ */
|
|
230
|
+
children: /* @__PURE__ */ U(_, { children: /* @__PURE__ */ U(v, { children: /* @__PURE__ */ U(p, {
|
|
196
231
|
fallback: null,
|
|
197
|
-
children: /* @__PURE__ */
|
|
232
|
+
children: /* @__PURE__ */ U(P, {
|
|
198
233
|
disabled: c.pathname.startsWith("/devportal") || c.pathname.startsWith("/organizations") || c.pathname.startsWith("/workspaces"),
|
|
199
|
-
children: /* @__PURE__ */
|
|
234
|
+
children: /* @__PURE__ */ U(ge, {
|
|
200
235
|
enablePWA: o,
|
|
201
236
|
toasterPosition: s,
|
|
202
237
|
productName: i,
|
|
@@ -206,18 +241,18 @@ function he({ children: e, i18nProductId: t, fallbackTranslations: n, defaultBra
|
|
|
206
241
|
})
|
|
207
242
|
}) }) })
|
|
208
243
|
}) }) });
|
|
209
|
-
return /* @__PURE__ */
|
|
244
|
+
return /* @__PURE__ */ W(f, {
|
|
210
245
|
defaultBrand: r,
|
|
211
|
-
children: [/* @__PURE__ */
|
|
246
|
+
children: [/* @__PURE__ */ U(be, {}), /* @__PURE__ */ U(C, {
|
|
212
247
|
i18nProductId: t,
|
|
213
248
|
fallbackTranslations: n,
|
|
214
249
|
children: l
|
|
215
250
|
})]
|
|
216
251
|
});
|
|
217
252
|
}
|
|
218
|
-
function
|
|
219
|
-
let e =
|
|
220
|
-
return
|
|
253
|
+
function be() {
|
|
254
|
+
let e = K();
|
|
255
|
+
return z(() => {
|
|
221
256
|
e.hash || requestAnimationFrame(() => {
|
|
222
257
|
window.scrollTo({
|
|
223
258
|
top: 0,
|
|
@@ -235,7 +270,7 @@ function ge() {
|
|
|
235
270
|
e.hash
|
|
236
271
|
]), null;
|
|
237
272
|
}
|
|
238
|
-
function
|
|
273
|
+
function xe(e) {
|
|
239
274
|
if (e instanceof Error) return e.message;
|
|
240
275
|
if (typeof e == "string") return e;
|
|
241
276
|
try {
|
|
@@ -244,9 +279,9 @@ function _e(e) {
|
|
|
244
279
|
return String(e);
|
|
245
280
|
}
|
|
246
281
|
}
|
|
247
|
-
function
|
|
248
|
-
let e =
|
|
249
|
-
return
|
|
282
|
+
function Se() {
|
|
283
|
+
let e = j(), t = K(), n = V(void 0), r = V(void 0);
|
|
284
|
+
return z(() => {
|
|
250
285
|
let i = `${t.pathname}${t.search}${t.hash}`;
|
|
251
286
|
r.current !== i && (e.emit("nav.route.changed", {
|
|
252
287
|
pathname: t.pathname,
|
|
@@ -260,7 +295,7 @@ function ve() {
|
|
|
260
295
|
t.hash,
|
|
261
296
|
t.pathname,
|
|
262
297
|
t.search
|
|
263
|
-
]),
|
|
298
|
+
]), z(() => {
|
|
264
299
|
let t = (t) => {
|
|
265
300
|
e.emit("error.runtime.caught", {
|
|
266
301
|
message: t.message || "Runtime error",
|
|
@@ -270,12 +305,12 @@ function ve() {
|
|
|
270
305
|
errorName: t.error instanceof Error ? t.error.name : void 0
|
|
271
306
|
});
|
|
272
307
|
}, n = (t) => {
|
|
273
|
-
e.emit("error.unhandledrejection", { reason:
|
|
308
|
+
e.emit("error.unhandledrejection", { reason: xe(t.reason) });
|
|
274
309
|
};
|
|
275
310
|
return window.addEventListener("error", t), window.addEventListener("unhandledrejection", n), () => {
|
|
276
311
|
window.removeEventListener("error", t), window.removeEventListener("unhandledrejection", n);
|
|
277
312
|
};
|
|
278
|
-
}, [e]),
|
|
313
|
+
}, [e]), z(() => {
|
|
279
314
|
b((t) => {
|
|
280
315
|
e.emit("perf.lcp.measured", {
|
|
281
316
|
metric: "LCP",
|
|
@@ -300,39 +335,39 @@ function ve() {
|
|
|
300
335
|
});
|
|
301
336
|
}, [e]), null;
|
|
302
337
|
}
|
|
303
|
-
function
|
|
304
|
-
return /* @__PURE__ */
|
|
305
|
-
e.devtools ? /* @__PURE__ */
|
|
306
|
-
e.broadcast === !1 ? null : /* @__PURE__ */
|
|
307
|
-
e.backendAudit?.enabled && e.backendAudit.endpoint ? /* @__PURE__ */
|
|
308
|
-
e.rybbit?.enabled && e.rybbit.siteId ? /* @__PURE__ */
|
|
338
|
+
function Ce({ config: e, productSlug: t }) {
|
|
339
|
+
return /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(Se, {}), e.enabled === !1 ? null : /* @__PURE__ */ W(H, { children: [
|
|
340
|
+
e.devtools ? /* @__PURE__ */ U(T, { enabled: !0 }) : null,
|
|
341
|
+
e.broadcast === !1 ? null : /* @__PURE__ */ U(E, {}),
|
|
342
|
+
e.backendAudit?.enabled && e.backendAudit.endpoint ? /* @__PURE__ */ U(D, { endpoint: e.backendAudit.endpoint }) : null,
|
|
343
|
+
e.rybbit?.enabled && e.rybbit.siteId ? /* @__PURE__ */ U(O, {
|
|
309
344
|
siteId: e.rybbit.siteId,
|
|
310
345
|
scriptUrl: e.rybbit.scriptUrl,
|
|
311
346
|
allowlist: e.rybbit.allowlist,
|
|
312
347
|
identifyOn: e.rybbit.identifyOn,
|
|
313
348
|
rename: e.rybbit.rename
|
|
314
349
|
}) : null,
|
|
315
|
-
e.otel?.enabled && e.otel.endpoint ? /* @__PURE__ */
|
|
350
|
+
e.otel?.enabled && e.otel.endpoint ? /* @__PURE__ */ U(k, {
|
|
316
351
|
endpoint: e.otel.endpoint,
|
|
317
352
|
serviceName: e.otel.serviceName ?? `${t}-app`,
|
|
318
353
|
flushInterval: e.otel.flushInterval
|
|
319
354
|
}) : null
|
|
320
355
|
] })] });
|
|
321
356
|
}
|
|
322
|
-
function
|
|
323
|
-
let { productName:
|
|
324
|
-
productName:
|
|
325
|
-
productSlug:
|
|
326
|
-
brandInitial:
|
|
327
|
-
tagline:
|
|
328
|
-
domain:
|
|
357
|
+
function we({ config: n, children: r, clearAuthStore: a }) {
|
|
358
|
+
let { productName: o, productSlug: f = o.toLowerCase().replace(/\s+/g, ""), tagline: m = "", domain: h, i18nProductId: g, gatewayUrls: _, authBridge: v, defaultBrand: b = "default", enablePWA: x = !0, brandInitial: S = o.charAt(0), defaultGateway: C = "workspace", enableSubscriptions: w = !0, fallbackTranslations: T, queryClientOptions: E, toasterPosition: D = "bottom-right", observability: O } = n, k = O ?? Z(f, he()), j = B(() => ({
|
|
359
|
+
productName: o,
|
|
360
|
+
productSlug: f,
|
|
361
|
+
brandInitial: S,
|
|
362
|
+
tagline: m,
|
|
363
|
+
domain: h
|
|
329
364
|
}), [
|
|
365
|
+
o,
|
|
330
366
|
f,
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
]), P = H(!1), F = H(!1), I = H(null), L = H(!!b?.url), R = z(() => {
|
|
367
|
+
S,
|
|
368
|
+
m,
|
|
369
|
+
h
|
|
370
|
+
]), M = V(!1), N = V(!1), P = V(null), F = V(!!v?.url), I = R(() => {
|
|
336
371
|
if ((() => {
|
|
337
372
|
try {
|
|
338
373
|
let e = sessionStorage.getItem("bf-active-profile");
|
|
@@ -342,26 +377,26 @@ function be({ config: n, children: i, clearAuthStore: a }) {
|
|
|
342
377
|
} catch {
|
|
343
378
|
return !1;
|
|
344
379
|
}
|
|
345
|
-
})() ||
|
|
346
|
-
|
|
380
|
+
})() || F.current || M.current) return;
|
|
381
|
+
M.current = !0, l(a);
|
|
347
382
|
let t = `${window.location.pathname}${window.location.search}`, n = `/auth/login?reason=session-expired&returnTo=${encodeURIComponent(t)}`, r = /^\/vibecontrols\/(share|deck)\//.test(window.location.pathname);
|
|
348
383
|
if (window.location.pathname.startsWith("/auth/") || e(window.location.pathname) || r) {
|
|
349
|
-
|
|
384
|
+
M.current = !1;
|
|
350
385
|
return;
|
|
351
386
|
}
|
|
352
387
|
window.location.replace(n);
|
|
353
|
-
}, [a]),
|
|
354
|
-
globalBaseUrl:
|
|
355
|
-
isRefreshing:
|
|
356
|
-
refreshPromise:
|
|
357
|
-
}), [
|
|
358
|
-
window.location.pathname.startsWith("/auth/") || await
|
|
359
|
-
}, [
|
|
360
|
-
|
|
361
|
-
}, [
|
|
362
|
-
let t = await
|
|
388
|
+
}, [a]), L = B(() => ({
|
|
389
|
+
globalBaseUrl: _.globalBaseUrl,
|
|
390
|
+
isRefreshing: N,
|
|
391
|
+
refreshPromise: P
|
|
392
|
+
}), [_.globalBaseUrl]), H = R(async () => c(L), [L]), K = R(async () => {
|
|
393
|
+
window.location.pathname.startsWith("/auth/") || await H() || I();
|
|
394
|
+
}, [H, I]), q = R(async (e) => {
|
|
395
|
+
ee(e) ? await H() || I() : console.error("[Network] Backend unreachable:", e.message);
|
|
396
|
+
}, [H, I]), J = R(async (e) => {
|
|
397
|
+
let t = await s({
|
|
363
398
|
gateway: "global",
|
|
364
|
-
baseUrl:
|
|
399
|
+
baseUrl: _.globalBaseUrl,
|
|
365
400
|
authToken: "",
|
|
366
401
|
query: "mutation RefreshToken($token: String!) {\n refreshToken(token: $token) {\n accessToken\n refreshToken\n expiresIn\n }\n }",
|
|
367
402
|
variables: { token: e }
|
|
@@ -373,78 +408,78 @@ function be({ config: n, children: i, clearAuthStore: a }) {
|
|
|
373
408
|
refreshToken: n.refreshToken,
|
|
374
409
|
expiresAt: n.expiresIn ? Date.now() + n.expiresIn * 1e3 : void 0
|
|
375
410
|
};
|
|
376
|
-
}, [
|
|
377
|
-
let e = new
|
|
378
|
-
queryCache: new
|
|
379
|
-
|
|
411
|
+
}, [_.globalBaseUrl]), Y = R(() => t("organization"), []), X = B(() => {
|
|
412
|
+
let e = new le({
|
|
413
|
+
queryCache: new ce({ onError: (e) => {
|
|
414
|
+
i(e);
|
|
380
415
|
} }),
|
|
381
|
-
mutationCache: new
|
|
416
|
+
mutationCache: new se({
|
|
382
417
|
onSuccess: () => {
|
|
383
418
|
e.invalidateQueries();
|
|
384
419
|
},
|
|
385
420
|
onError: (e) => {
|
|
386
|
-
|
|
421
|
+
i(e);
|
|
387
422
|
}
|
|
388
423
|
}),
|
|
389
424
|
defaultOptions: { queries: {
|
|
390
|
-
staleTime:
|
|
391
|
-
retry:
|
|
392
|
-
refetchOnWindowFocus:
|
|
425
|
+
staleTime: E?.staleTime ?? 300 * 1e3,
|
|
426
|
+
retry: E?.retry ?? 1,
|
|
427
|
+
refetchOnWindowFocus: E?.refetchOnWindowFocus ?? !1
|
|
393
428
|
} }
|
|
394
429
|
});
|
|
395
430
|
return e;
|
|
396
|
-
}, [
|
|
397
|
-
return
|
|
398
|
-
let e =
|
|
431
|
+
}, [E]);
|
|
432
|
+
return z(() => {
|
|
433
|
+
let e = u.getInstance();
|
|
399
434
|
e.getLogger("shell") || e.getLogger("shell").addTransport(new d());
|
|
400
|
-
}, []), /* @__PURE__ */
|
|
401
|
-
value:
|
|
402
|
-
children: /* @__PURE__ */
|
|
403
|
-
appName:
|
|
404
|
-
appVersion:
|
|
405
|
-
appEnv:
|
|
406
|
-
sourceMfe:
|
|
407
|
-
children: /* @__PURE__ */
|
|
408
|
-
FallbackComponent:
|
|
409
|
-
children: /* @__PURE__ */ G
|
|
410
|
-
config:
|
|
411
|
-
productSlug:
|
|
412
|
-
}), /* @__PURE__ */
|
|
413
|
-
client:
|
|
414
|
-
children: /* @__PURE__ */
|
|
415
|
-
workspaceBaseUrl:
|
|
416
|
-
globalBaseUrl:
|
|
417
|
-
organizationId:
|
|
418
|
-
defaultGateway:
|
|
419
|
-
enableSubscriptions:
|
|
420
|
-
onAuthError:
|
|
421
|
-
onNetworkError:
|
|
422
|
-
onRefreshToken:
|
|
423
|
-
children: /* @__PURE__ */
|
|
424
|
-
bridgeUrl:
|
|
425
|
-
bridgeAllowedOrigins:
|
|
426
|
-
bridgeDebug:
|
|
427
|
-
onRefreshToken:
|
|
435
|
+
}, []), /* @__PURE__ */ U(oe, {
|
|
436
|
+
value: j,
|
|
437
|
+
children: /* @__PURE__ */ U(A, {
|
|
438
|
+
appName: f,
|
|
439
|
+
appVersion: k.appVersion,
|
|
440
|
+
appEnv: k.appEnv,
|
|
441
|
+
sourceMfe: f,
|
|
442
|
+
children: /* @__PURE__ */ U(p, {
|
|
443
|
+
FallbackComponent: re,
|
|
444
|
+
children: /* @__PURE__ */ W(G, { children: [/* @__PURE__ */ U(Ce, {
|
|
445
|
+
config: k,
|
|
446
|
+
productSlug: f
|
|
447
|
+
}), /* @__PURE__ */ U(ue, {
|
|
448
|
+
client: X,
|
|
449
|
+
children: /* @__PURE__ */ U(ie, { children: /* @__PURE__ */ U(ae, {
|
|
450
|
+
workspaceBaseUrl: _.workspaceBaseUrl,
|
|
451
|
+
globalBaseUrl: _.globalBaseUrl,
|
|
452
|
+
organizationId: Y,
|
|
453
|
+
defaultGateway: C,
|
|
454
|
+
enableSubscriptions: w,
|
|
455
|
+
onAuthError: K,
|
|
456
|
+
onNetworkError: q,
|
|
457
|
+
onRefreshToken: H,
|
|
458
|
+
children: /* @__PURE__ */ U(te, {
|
|
459
|
+
bridgeUrl: v?.url,
|
|
460
|
+
bridgeAllowedOrigins: v?.allowedOrigins,
|
|
461
|
+
bridgeDebug: v?.debug,
|
|
462
|
+
onRefreshToken: J,
|
|
428
463
|
onBridgeReady: () => {
|
|
429
|
-
|
|
464
|
+
F.current = !1;
|
|
430
465
|
},
|
|
431
466
|
onSessionExpiringSoon: () => {
|
|
432
467
|
console.warn("[Auth] Session will expire in 5 minutes");
|
|
433
468
|
},
|
|
434
469
|
onTokenExpired: () => {
|
|
435
|
-
|
|
470
|
+
I();
|
|
436
471
|
},
|
|
437
|
-
children: /* @__PURE__ */
|
|
472
|
+
children: /* @__PURE__ */ U(ne, {
|
|
438
473
|
syncToUrl: !0,
|
|
439
|
-
children: /* @__PURE__ */
|
|
440
|
-
i18nProductId:
|
|
441
|
-
fallbackTranslations:
|
|
442
|
-
defaultBrand:
|
|
443
|
-
productName:
|
|
444
|
-
brandInitial:
|
|
445
|
-
enablePWA:
|
|
446
|
-
toasterPosition:
|
|
447
|
-
children:
|
|
474
|
+
children: /* @__PURE__ */ U(y, { children: /* @__PURE__ */ U(ye, {
|
|
475
|
+
i18nProductId: g,
|
|
476
|
+
fallbackTranslations: T,
|
|
477
|
+
defaultBrand: b,
|
|
478
|
+
productName: o,
|
|
479
|
+
brandInitial: S,
|
|
480
|
+
enablePWA: x,
|
|
481
|
+
toasterPosition: D,
|
|
482
|
+
children: r
|
|
448
483
|
}) })
|
|
449
484
|
})
|
|
450
485
|
})
|
|
@@ -455,4 +490,4 @@ function be({ config: n, children: i, clearAuthStore: a }) {
|
|
|
455
490
|
});
|
|
456
491
|
}
|
|
457
492
|
//#endregion
|
|
458
|
-
export {
|
|
493
|
+
export { we as AppShellProvider, Z as resolveAppShellObservabilityConfig };
|
|
@@ -67,7 +67,7 @@ export declare function setActiveProfileId(profileId: string): void;
|
|
|
67
67
|
export declare function clearActiveProfileId(): void;
|
|
68
68
|
/**
|
|
69
69
|
* Get or initialize active profile.
|
|
70
|
-
*
|
|
70
|
+
* Resolution order: per-tab pointer → durable last-active hint → first profile.
|
|
71
71
|
*/
|
|
72
72
|
export declare function resolveActiveProfileId(): string | null;
|
|
73
73
|
export declare function getProfileUser(profileId: string): ProfileUser | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProfileStorageManager.d.ts","sourceRoot":"","sources":["../../../../src/shared/providers/shell/ProfileStorageManager.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,UAAU;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC1B;AAED,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;
|
|
1
|
+
{"version":3,"file":"ProfileStorageManager.d.ts","sourceRoot":"","sources":["../../../../src/shared/providers/shell/ProfileStorageManager.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,UAAU;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,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