@burdenoff/microfe-store 2026.625.3 → 2026.625.4
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/StoreRoutes.js +3 -3
- package/dist/StoreRoutes.js.map +1 -1
- package/dist/components/AccessDenied.js +3 -3
- package/dist/components/AccessDenied.js.map +1 -1
- package/dist/components/InstallAppModal.js +120 -107
- package/dist/components/InstallAppModal.js.map +1 -1
- package/dist/components/cart/CartDrawer.js +10 -10
- package/dist/components/cart/CartDrawer.js.map +1 -1
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/errors/CombinedGraphQLErrors.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/errors/CombinedGraphQLErrors.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/errors/utils.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/errors/utils.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/link/core/ApolloLink.js +2 -2
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/link/core/ApolloLink.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/link/subscriptions/index.js +2 -2
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/link/subscriptions/index.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/link/utils/createOperation.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/link/utils/createOperation.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/caching/sizes.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/graphql/print.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/graphql/print.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/caches.js +2 -2
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/caches.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/checkDocument.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/checkDocument.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/getMainDefinition.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getMainDefinition.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js +9 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/getOperationDefinition.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getOperationDefinition.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getOperationName.js +8 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getOperationName.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/globals/global.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/globals/global.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/globals/maybe.js +10 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/globals/maybe.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/isNonNullObject.js +8 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/isNonNullObject.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/makeUniqueId.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/makeUniqueId.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/memoize.js +2 -2
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/memoize.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/internal/stringifyForDisplay.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/stringifyForDisplay.js.map +1 -0
- package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/invariant/index.js +1 -1
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/invariant/index.js.map +1 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/version.js +6 -0
- package/dist/node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/version.js.map +1 -0
- package/dist/node_modules/{@wry → .bun/@wry_caches@1.0.1/node_modules/@wry}/caches/lib/weak.js +1 -1
- package/dist/node_modules/.bun/@wry_caches@1.0.1/node_modules/@wry/caches/lib/weak.js.map +1 -0
- package/dist/node_modules/{@wry → .bun/@wry_trie@0.5.0/node_modules/@wry}/trie/lib/index.js +1 -1
- package/dist/node_modules/.bun/@wry_trie@0.5.0/node_modules/@wry/trie/lib/index.js.map +1 -0
- package/dist/node_modules/{graphql-ws → .bun/graphql-ws@6.0.8_796ebe57c2b0ffe0/node_modules/graphql-ws}/dist/client.js +1 -1
- package/dist/node_modules/.bun/graphql-ws@6.0.8_796ebe57c2b0ffe0/node_modules/graphql-ws/dist/client.js.map +1 -0
- package/dist/node_modules/{graphql-ws → .bun/graphql-ws@6.0.8_796ebe57c2b0ffe0/node_modules/graphql-ws}/dist/common-CGW11Fyb.js +1 -1
- package/dist/node_modules/.bun/graphql-ws@6.0.8_796ebe57c2b0ffe0/node_modules/graphql-ws/dist/common-CGW11Fyb.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/NotificationFactories.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/NotificationFactories.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/Observable.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/Observable.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/Subscriber.js +2 -2
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/Subscriber.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/Subscription.js +2 -2
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/Subscription.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/config.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/config.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/observable/empty.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/observable/empty.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/scheduler/timeoutProvider.js +2 -2
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/scheduler/timeoutProvider.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/symbol/observable.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/symbol/observable.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/util/UnsubscriptionError.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/UnsubscriptionError.js.map +1 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js +11 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/util/createErrorClass.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/createErrorClass.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/util/errorContext.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/errorContext.js.map +1 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/identity.js +8 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/identity.js.map +1 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/isFunction.js +8 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/isFunction.js.map +1 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/noop.js +6 -0
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/noop.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/util/pipe.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/pipe.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/rxjs@7.8.2/node_modules/rxjs}/dist/esm5/internal/util/reportUnhandledError.js +1 -1
- package/dist/node_modules/.bun/rxjs@7.8.2/node_modules/rxjs/dist/esm5/internal/util/reportUnhandledError.js.map +1 -0
- package/dist/node_modules/{rxjs → .bun/tslib@2.8.1}/node_modules/tslib/tslib.es6.js +1 -1
- package/dist/node_modules/.bun/tslib@2.8.1/node_modules/tslib/tslib.es6.js.map +1 -0
- package/dist/pages/AdminDashboardPage.js +89 -90
- package/dist/pages/AdminDashboardPage.js.map +1 -1
- package/dist/pages/AdminReviewModerationPage.js +56 -58
- package/dist/pages/AdminReviewModerationPage.js.map +1 -1
- package/dist/pages/AdminStoresPage.js +372 -391
- package/dist/pages/AdminStoresPage.js.map +1 -1
- package/dist/pages/AdminSubmissionsQueuePage.js +148 -134
- package/dist/pages/AdminSubmissionsQueuePage.js.map +1 -1
- package/dist/pages/AppDetailPage.js +120 -123
- package/dist/pages/AppDetailPage.js.map +1 -1
- package/dist/pages/AppSettingsPage.js +297 -70
- package/dist/pages/AppSettingsPage.js.map +1 -1
- package/dist/pages/CartPage.js +76 -65
- package/dist/pages/CartPage.js.map +1 -1
- package/dist/pages/InstalledAppsPage.js +100 -71
- package/dist/pages/InstalledAppsPage.js.map +1 -1
- package/dist/pages/MarketplaceHomePage.js +378 -368
- package/dist/pages/MarketplaceHomePage.js.map +1 -1
- package/dist/pages/MyLicensesPage.js +75 -67
- package/dist/pages/MyLicensesPage.js.map +1 -1
- package/dist/pages/OrderConfirmationPage.js +37 -38
- package/dist/pages/OrderConfirmationPage.js.map +1 -1
- package/dist/pages/OrdersPage.js +64 -53
- package/dist/pages/OrdersPage.js.map +1 -1
- package/dist/pages/ProductDetailPage.js +98 -101
- package/dist/pages/ProductDetailPage.js.map +1 -1
- package/dist/pages/ProductReviewsPage.js +2 -2
- package/dist/pages/ProductReviewsPage.js.map +1 -1
- package/dist/pages/PublisherDashboardPage.js +92 -93
- package/dist/pages/PublisherDashboardPage.js.map +1 -1
- package/dist/pages/PublisherRevenuePage.js +60 -61
- package/dist/pages/PublisherRevenuePage.js.map +1 -1
- package/dist/pages/PublisherSubmissionsPage.js +96 -97
- package/dist/pages/PublisherSubmissionsPage.js.map +1 -1
- package/dist/pages/PublisherSubmitPage.js +184 -189
- package/dist/pages/PublisherSubmitPage.js.map +1 -1
- package/dist/providers/StoreProvider.js +3 -3
- package/package.json +2 -2
- package/dist/node_modules/@apollo/client/errors/CombinedGraphQLErrors.js.map +0 -1
- package/dist/node_modules/@apollo/client/errors/utils.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/core/ApolloLink.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/subscriptions/index.js.map +0 -1
- package/dist/node_modules/@apollo/client/link/utils/createOperation.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/caching/sizes.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/graphql/print.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/caches.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/checkDocument.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getMainDefinition.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js +0 -9
- package/dist/node_modules/@apollo/client/utilities/internal/getMemoryInternals.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationDefinition.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationName.js +0 -8
- package/dist/node_modules/@apollo/client/utilities/internal/getOperationName.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/globals/global.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/globals/maybe.js +0 -10
- package/dist/node_modules/@apollo/client/utilities/internal/globals/maybe.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/isNonNullObject.js +0 -8
- package/dist/node_modules/@apollo/client/utilities/internal/isNonNullObject.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/makeUniqueId.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/memoize.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/internal/stringifyForDisplay.js.map +0 -1
- package/dist/node_modules/@apollo/client/utilities/invariant/index.js.map +0 -1
- package/dist/node_modules/@apollo/client/version.js +0 -6
- package/dist/node_modules/@apollo/client/version.js.map +0 -1
- package/dist/node_modules/@wry/caches/lib/weak.js.map +0 -1
- package/dist/node_modules/@wry/trie/lib/index.js.map +0 -1
- package/dist/node_modules/graphql-ws/dist/client.js.map +0 -1
- package/dist/node_modules/graphql-ws/dist/common-CGW11Fyb.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/NotificationFactories.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Observable.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscriber.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/Subscription.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/config.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/observable/empty.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/scheduler/timeoutProvider.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/symbol/observable.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/UnsubscriptionError.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js +0 -11
- package/dist/node_modules/rxjs/dist/esm5/internal/util/arrRemove.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/createErrorClass.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/errorContext.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/identity.js +0 -8
- package/dist/node_modules/rxjs/dist/esm5/internal/util/identity.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/isFunction.js +0 -8
- package/dist/node_modules/rxjs/dist/esm5/internal/util/isFunction.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/noop.js +0 -6
- package/dist/node_modules/rxjs/dist/esm5/internal/util/noop.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/pipe.js.map +0 -1
- package/dist/node_modules/rxjs/dist/esm5/internal/util/reportUnhandledError.js.map +0 -1
- package/dist/node_modules/rxjs/node_modules/tslib/tslib.es6.js.map +0 -1
- /package/dist/node_modules/{@apollo → .bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo}/client/utilities/caching/sizes.js +0 -0
|
@@ -2,9 +2,8 @@ import { CreateProductForPublisherDocument as e } from "../generated/global-oper
|
|
|
2
2
|
import { useMemo as t, useState as n } from "react";
|
|
3
3
|
import { useApolloClient as r } from "@apollo/client/react";
|
|
4
4
|
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
5
|
-
import { GlassCard as o } from "@burdenoff/fe-libs/ui";
|
|
6
5
|
//#region src/pages/PublisherSubmitPage.tsx
|
|
7
|
-
var
|
|
6
|
+
var o = JSON.stringify({
|
|
8
7
|
schemaVersion: "1.0.0",
|
|
9
8
|
itemType: "app",
|
|
10
9
|
author: { name: "Publisher Team" },
|
|
@@ -14,11 +13,11 @@ var s = JSON.stringify({
|
|
|
14
13
|
},
|
|
15
14
|
permissions: ["workspace:read"],
|
|
16
15
|
dependencies: { integrations: [] }
|
|
17
|
-
}, null, 2),
|
|
18
|
-
let
|
|
16
|
+
}, null, 2), s = () => {
|
|
17
|
+
let s = r(), [c, l] = n(""), [u, d] = n(""), [f, p] = n(""), [m, h] = n("APP"), [g, _] = n("0"), [v, y] = n(o), [b, x] = n(!1), [S, C] = n(null), [w, T] = n(null), E = t(() => {
|
|
19
18
|
try {
|
|
20
19
|
return {
|
|
21
|
-
value: JSON.parse(
|
|
20
|
+
value: JSON.parse(v),
|
|
22
21
|
error: null
|
|
23
22
|
};
|
|
24
23
|
} catch {
|
|
@@ -27,7 +26,7 @@ var s = JSON.stringify({
|
|
|
27
26
|
error: "Manifest JSON is invalid."
|
|
28
27
|
};
|
|
29
28
|
}
|
|
30
|
-
}, [
|
|
29
|
+
}, [v]);
|
|
31
30
|
return /* @__PURE__ */ a("main", {
|
|
32
31
|
className: "mx-auto max-w-4xl p-6",
|
|
33
32
|
children: [/* @__PURE__ */ a("header", {
|
|
@@ -39,197 +38,193 @@ var s = JSON.stringify({
|
|
|
39
38
|
className: "mt-1 text-sm text-text-muted",
|
|
40
39
|
children: "Create a store product with manifest JSON (raw mode)."
|
|
41
40
|
})]
|
|
42
|
-
}), /* @__PURE__ */
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
41
|
+
}), /* @__PURE__ */ a("form", {
|
|
42
|
+
onSubmit: async (t) => {
|
|
43
|
+
if (t.preventDefault(), C(null), T(null), !c.trim()) {
|
|
44
|
+
C("Product name is required.");
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
if (!u.trim()) {
|
|
48
|
+
C("Product slug is required.");
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
if (E.error || !E.value) {
|
|
52
|
+
C(E.error || "Manifest JSON is required.");
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
let n = Number(g);
|
|
56
|
+
if (!Number.isFinite(n) || n < 0) {
|
|
57
|
+
C("Price must be a valid non-negative number.");
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
x(!0);
|
|
61
|
+
try {
|
|
62
|
+
let t = (await s.mutate({
|
|
63
|
+
mutation: e,
|
|
64
|
+
variables: { input: {
|
|
65
|
+
name: c.trim(),
|
|
66
|
+
slug: u.trim(),
|
|
67
|
+
type: m,
|
|
68
|
+
price: n,
|
|
69
|
+
pricingModel: n === 0 ? "FREE" : "PAID_ONETIME",
|
|
70
|
+
description: f.trim() || void 0,
|
|
71
|
+
manifest: E.value
|
|
72
|
+
} }
|
|
73
|
+
})).data?.createProduct;
|
|
74
|
+
if (!t) {
|
|
75
|
+
C("Product creation failed: no product returned by API.");
|
|
49
76
|
return;
|
|
50
77
|
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
E(`Created ${t.slug} (${t.status})`), u(""), f(""), m("");
|
|
83
|
-
} catch (e) {
|
|
84
|
-
w(e instanceof Error ? e.message : "Unknown error");
|
|
85
|
-
} finally {
|
|
86
|
-
S(!1);
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
className: "space-y-4",
|
|
90
|
-
"aria-label": "Submit Product",
|
|
91
|
-
children: [
|
|
92
|
-
/* @__PURE__ */ a("div", {
|
|
93
|
-
className: "grid gap-4 md:grid-cols-2",
|
|
94
|
-
children: [
|
|
95
|
-
/* @__PURE__ */ a("label", {
|
|
96
|
-
className: "space-y-1",
|
|
97
|
-
children: [/* @__PURE__ */ i("span", {
|
|
98
|
-
className: "text-sm text-text-secondary",
|
|
99
|
-
children: "Product Name"
|
|
100
|
-
}), /* @__PURE__ */ i("input", {
|
|
101
|
-
"aria-label": "Product Name",
|
|
102
|
-
value: l,
|
|
103
|
-
onChange: (e) => u(e.target.value),
|
|
104
|
-
required: !0,
|
|
105
|
-
"aria-required": "true",
|
|
106
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
107
|
-
placeholder: "Acme Automation"
|
|
108
|
-
})]
|
|
109
|
-
}),
|
|
110
|
-
/* @__PURE__ */ a("label", {
|
|
111
|
-
className: "space-y-1",
|
|
112
|
-
children: [/* @__PURE__ */ i("span", {
|
|
113
|
-
className: "text-sm text-text-secondary",
|
|
114
|
-
children: "Slug"
|
|
115
|
-
}), /* @__PURE__ */ i("input", {
|
|
116
|
-
"aria-label": "Slug",
|
|
117
|
-
value: d,
|
|
118
|
-
onChange: (e) => f(e.target.value),
|
|
119
|
-
required: !0,
|
|
120
|
-
"aria-required": "true",
|
|
121
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
122
|
-
placeholder: "acme-automation"
|
|
123
|
-
})]
|
|
124
|
-
}),
|
|
125
|
-
/* @__PURE__ */ a("label", {
|
|
126
|
-
className: "space-y-1",
|
|
127
|
-
children: [/* @__PURE__ */ i("span", {
|
|
128
|
-
className: "text-sm text-text-secondary",
|
|
129
|
-
children: "Type"
|
|
130
|
-
}), /* @__PURE__ */ a("select", {
|
|
131
|
-
"aria-label": "Product type",
|
|
132
|
-
value: h,
|
|
133
|
-
onChange: (e) => g(e.target.value),
|
|
134
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
135
|
-
children: [
|
|
136
|
-
/* @__PURE__ */ i("option", {
|
|
137
|
-
value: "APP",
|
|
138
|
-
children: "APP"
|
|
139
|
-
}),
|
|
140
|
-
/* @__PURE__ */ i("option", {
|
|
141
|
-
value: "AGENT",
|
|
142
|
-
children: "AGENT"
|
|
143
|
-
}),
|
|
144
|
-
/* @__PURE__ */ i("option", {
|
|
145
|
-
value: "NODE",
|
|
146
|
-
children: "NODE"
|
|
147
|
-
}),
|
|
148
|
-
/* @__PURE__ */ i("option", {
|
|
149
|
-
value: "WIDGET",
|
|
150
|
-
children: "WIDGET"
|
|
151
|
-
}),
|
|
152
|
-
/* @__PURE__ */ i("option", {
|
|
153
|
-
value: "WORKFLOW",
|
|
154
|
-
children: "WORKFLOW"
|
|
155
|
-
})
|
|
156
|
-
]
|
|
157
|
-
})]
|
|
158
|
-
}),
|
|
159
|
-
/* @__PURE__ */ a("label", {
|
|
160
|
-
className: "space-y-1",
|
|
161
|
-
children: [/* @__PURE__ */ i("span", {
|
|
162
|
-
className: "text-sm text-text-secondary",
|
|
163
|
-
children: "Price"
|
|
164
|
-
}), /* @__PURE__ */ i("input", {
|
|
165
|
-
type: "number",
|
|
166
|
-
"aria-label": "Price",
|
|
167
|
-
min: "0",
|
|
168
|
-
step: "0.01",
|
|
169
|
-
value: _,
|
|
170
|
-
onChange: (e) => v(e.target.value),
|
|
171
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary"
|
|
172
|
-
})]
|
|
173
|
-
})
|
|
174
|
-
]
|
|
175
|
-
}),
|
|
176
|
-
/* @__PURE__ */ a("label", {
|
|
177
|
-
className: "block space-y-1",
|
|
178
|
-
children: [/* @__PURE__ */ i("span", {
|
|
179
|
-
className: "text-sm text-text-secondary",
|
|
180
|
-
children: "Description"
|
|
181
|
-
}), /* @__PURE__ */ i("textarea", {
|
|
182
|
-
"aria-label": "Description",
|
|
183
|
-
value: p,
|
|
184
|
-
onChange: (e) => m(e.target.value),
|
|
185
|
-
rows: 3,
|
|
186
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary"
|
|
187
|
-
})]
|
|
188
|
-
}),
|
|
189
|
-
/* @__PURE__ */ a("label", {
|
|
190
|
-
className: "block space-y-1",
|
|
191
|
-
children: [
|
|
192
|
-
/* @__PURE__ */ i("span", {
|
|
78
|
+
T(`Created ${t.slug} (${t.status})`), l(""), d(""), p("");
|
|
79
|
+
} catch (e) {
|
|
80
|
+
C(e instanceof Error ? e.message : "Unknown error");
|
|
81
|
+
} finally {
|
|
82
|
+
x(!1);
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
className: "space-y-4",
|
|
86
|
+
"aria-label": "Submit Product",
|
|
87
|
+
children: [
|
|
88
|
+
/* @__PURE__ */ a("div", {
|
|
89
|
+
className: "grid gap-4 md:grid-cols-2",
|
|
90
|
+
children: [
|
|
91
|
+
/* @__PURE__ */ a("label", {
|
|
92
|
+
className: "space-y-1",
|
|
93
|
+
children: [/* @__PURE__ */ i("span", {
|
|
94
|
+
className: "text-sm text-text-secondary",
|
|
95
|
+
children: "Product Name"
|
|
96
|
+
}), /* @__PURE__ */ i("input", {
|
|
97
|
+
"aria-label": "Product Name",
|
|
98
|
+
value: c,
|
|
99
|
+
onChange: (e) => l(e.target.value),
|
|
100
|
+
required: !0,
|
|
101
|
+
"aria-required": "true",
|
|
102
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
103
|
+
placeholder: "Acme Automation"
|
|
104
|
+
})]
|
|
105
|
+
}),
|
|
106
|
+
/* @__PURE__ */ a("label", {
|
|
107
|
+
className: "space-y-1",
|
|
108
|
+
children: [/* @__PURE__ */ i("span", {
|
|
193
109
|
className: "text-sm text-text-secondary",
|
|
194
|
-
children: "
|
|
195
|
-
}),
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
onChange: (e) => b(e.target.value),
|
|
200
|
-
rows: 16,
|
|
110
|
+
children: "Slug"
|
|
111
|
+
}), /* @__PURE__ */ i("input", {
|
|
112
|
+
"aria-label": "Slug",
|
|
113
|
+
value: u,
|
|
114
|
+
onChange: (e) => d(e.target.value),
|
|
201
115
|
required: !0,
|
|
202
116
|
"aria-required": "true",
|
|
203
|
-
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
117
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
118
|
+
placeholder: "acme-automation"
|
|
119
|
+
})]
|
|
120
|
+
}),
|
|
121
|
+
/* @__PURE__ */ a("label", {
|
|
122
|
+
className: "space-y-1",
|
|
123
|
+
children: [/* @__PURE__ */ i("span", {
|
|
124
|
+
className: "text-sm text-text-secondary",
|
|
125
|
+
children: "Type"
|
|
126
|
+
}), /* @__PURE__ */ a("select", {
|
|
127
|
+
"aria-label": "Product type",
|
|
128
|
+
value: m,
|
|
129
|
+
onChange: (e) => h(e.target.value),
|
|
130
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary",
|
|
131
|
+
children: [
|
|
132
|
+
/* @__PURE__ */ i("option", {
|
|
133
|
+
value: "APP",
|
|
134
|
+
children: "APP"
|
|
135
|
+
}),
|
|
136
|
+
/* @__PURE__ */ i("option", {
|
|
137
|
+
value: "AGENT",
|
|
138
|
+
children: "AGENT"
|
|
139
|
+
}),
|
|
140
|
+
/* @__PURE__ */ i("option", {
|
|
141
|
+
value: "NODE",
|
|
142
|
+
children: "NODE"
|
|
143
|
+
}),
|
|
144
|
+
/* @__PURE__ */ i("option", {
|
|
145
|
+
value: "WIDGET",
|
|
146
|
+
children: "WIDGET"
|
|
147
|
+
}),
|
|
148
|
+
/* @__PURE__ */ i("option", {
|
|
149
|
+
value: "WORKFLOW",
|
|
150
|
+
children: "WORKFLOW"
|
|
151
|
+
})
|
|
152
|
+
]
|
|
153
|
+
})]
|
|
154
|
+
}),
|
|
155
|
+
/* @__PURE__ */ a("label", {
|
|
156
|
+
className: "space-y-1",
|
|
157
|
+
children: [/* @__PURE__ */ i("span", {
|
|
158
|
+
className: "text-sm text-text-secondary",
|
|
159
|
+
children: "Price"
|
|
160
|
+
}), /* @__PURE__ */ i("input", {
|
|
161
|
+
type: "number",
|
|
162
|
+
"aria-label": "Price",
|
|
163
|
+
min: "0",
|
|
164
|
+
step: "0.01",
|
|
165
|
+
value: g,
|
|
166
|
+
onChange: (e) => _(e.target.value),
|
|
167
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary"
|
|
168
|
+
})]
|
|
169
|
+
})
|
|
170
|
+
]
|
|
171
|
+
}),
|
|
172
|
+
/* @__PURE__ */ a("label", {
|
|
173
|
+
className: "block space-y-1",
|
|
174
|
+
children: [/* @__PURE__ */ i("span", {
|
|
175
|
+
className: "text-sm text-text-secondary",
|
|
176
|
+
children: "Description"
|
|
177
|
+
}), /* @__PURE__ */ i("textarea", {
|
|
178
|
+
"aria-label": "Description",
|
|
179
|
+
value: f,
|
|
180
|
+
onChange: (e) => p(e.target.value),
|
|
181
|
+
rows: 3,
|
|
182
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary"
|
|
183
|
+
})]
|
|
184
|
+
}),
|
|
185
|
+
/* @__PURE__ */ a("label", {
|
|
186
|
+
className: "block space-y-1",
|
|
187
|
+
children: [
|
|
188
|
+
/* @__PURE__ */ i("span", {
|
|
189
|
+
className: "text-sm text-text-secondary",
|
|
190
|
+
children: "Manifest (JSON)"
|
|
191
|
+
}),
|
|
192
|
+
/* @__PURE__ */ i("textarea", {
|
|
193
|
+
"aria-label": "Manifest JSON",
|
|
194
|
+
value: v,
|
|
195
|
+
onChange: (e) => y(e.target.value),
|
|
196
|
+
rows: 16,
|
|
197
|
+
required: !0,
|
|
198
|
+
"aria-required": "true",
|
|
199
|
+
className: "w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 font-mono text-xs text-text-primary"
|
|
200
|
+
}),
|
|
201
|
+
E.error && /* @__PURE__ */ i("p", {
|
|
202
|
+
className: "text-xs text-status-error-text",
|
|
203
|
+
children: E.error
|
|
204
|
+
})
|
|
205
|
+
]
|
|
206
|
+
}),
|
|
207
|
+
S && /* @__PURE__ */ i("p", {
|
|
208
|
+
role: "alert",
|
|
209
|
+
className: "rounded-md bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text",
|
|
210
|
+
children: S
|
|
211
|
+
}),
|
|
212
|
+
w && /* @__PURE__ */ i("p", {
|
|
213
|
+
role: "status",
|
|
214
|
+
className: "rounded-md bg-status-success-bg-subtle px-3 py-2 text-sm text-status-success-text",
|
|
215
|
+
children: w
|
|
216
|
+
}),
|
|
217
|
+
/* @__PURE__ */ i("button", {
|
|
218
|
+
type: "submit",
|
|
219
|
+
disabled: b,
|
|
220
|
+
className: "rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text disabled:cursor-not-allowed disabled:opacity-60",
|
|
221
|
+
children: b ? "Submitting..." : "Submit Product"
|
|
222
|
+
})
|
|
223
|
+
]
|
|
229
224
|
})]
|
|
230
225
|
});
|
|
231
226
|
};
|
|
232
227
|
//#endregion
|
|
233
|
-
export {
|
|
228
|
+
export { s as PublisherSubmitPage };
|
|
234
229
|
|
|
235
230
|
//# sourceMappingURL=PublisherSubmitPage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PublisherSubmitPage.js","names":[],"sources":["../../src/pages/PublisherSubmitPage.tsx"],"sourcesContent":["import { useApolloClient } from '@apollo/client/react';\nimport { useMemo, useState, type FC, type FormEvent } from 'react';\n\nimport { GlassCard } from '@burdenoff/fe-libs/ui';\nimport { CreateProductForPublisherDocument } from '../generated/global-operations';\n\nconst DEFAULT_MANIFEST = JSON.stringify(\n {\n schemaVersion: '1.0.0',\n itemType: 'app',\n author: { name: 'Publisher Team' },\n compatibility: {\n minVersion: '2026.1.0',\n products: ['workspaces'],\n },\n permissions: ['workspace:read'],\n dependencies: {\n integrations: [],\n },\n },\n null,\n 2\n);\n\nexport const PublisherSubmitPage: FC = () => {\n const client = useApolloClient();\n\n const [name, setName] = useState('');\n const [slug, setSlug] = useState('');\n const [description, setDescription] = useState('');\n const [type, setType] = useState('APP');\n const [price, setPrice] = useState('0');\n const [manifestText, setManifestText] = useState(DEFAULT_MANIFEST);\n const [submitting, setSubmitting] = useState(false);\n const [error, setError] = useState<string | null>(null);\n const [success, setSuccess] = useState<string | null>(null);\n\n const parsedManifest = useMemo(() => {\n try {\n return { value: JSON.parse(manifestText), error: null as string | null };\n } catch {\n return { value: null, error: 'Manifest JSON is invalid.' };\n }\n }, [manifestText]);\n\n const submitProduct = async (event: FormEvent) => {\n event.preventDefault();\n setError(null);\n setSuccess(null);\n\n if (!name.trim()) {\n setError('Product name is required.');\n return;\n }\n if (!slug.trim()) {\n setError('Product slug is required.');\n return;\n }\n if (parsedManifest.error || !parsedManifest.value) {\n setError(parsedManifest.error || 'Manifest JSON is required.');\n return;\n }\n\n const numericPrice = Number(price);\n if (!Number.isFinite(numericPrice) || numericPrice < 0) {\n setError('Price must be a valid non-negative number.');\n return;\n }\n\n setSubmitting(true);\n try {\n const result = await client.mutate<{\n createProduct?: { id: string; slug: string; status: string };\n }>({\n mutation: CreateProductForPublisherDocument,\n variables: {\n input: {\n name: name.trim(),\n slug: slug.trim(),\n type,\n price: numericPrice,\n pricingModel: numericPrice === 0 ? 'FREE' : 'PAID_ONETIME',\n description: description.trim() || undefined,\n manifest: parsedManifest.value,\n },\n },\n });\n\n const created = result.data?.createProduct;\n if (!created) {\n setError('Product creation failed: no product returned by API.');\n return;\n }\n\n setSuccess(`Created ${created.slug} (${created.status})`);\n setName('');\n setSlug('');\n setDescription('');\n } catch (mutationError) {\n const message = mutationError instanceof Error ? mutationError.message : 'Unknown error';\n setError(message);\n } finally {\n setSubmitting(false);\n }\n };\n\n return (\n <main className=\"mx-auto max-w-4xl p-6\">\n <header className=\"mb-6\">\n <h1 className=\"text-2xl font-semibold text-text-primary\">Submit Product</h1>\n <p className=\"mt-1 text-sm text-text-muted\">\n Create a store product with manifest JSON (raw mode).\n </p>\n </header>\n\n <GlassCard treatment=\"plain\" className=\"p-5\">\n <form onSubmit={submitProduct} className=\"space-y-4\" aria-label=\"Submit Product\">\n <div className=\"grid gap-4 md:grid-cols-2\">\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Product Name</span>\n <input\n aria-label=\"Product Name\"\n value={name}\n onChange={(event) => setName(event.target.value)}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n placeholder=\"Acme Automation\"\n />\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Slug</span>\n <input\n aria-label=\"Slug\"\n value={slug}\n onChange={(event) => setSlug(event.target.value)}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n placeholder=\"acme-automation\"\n />\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Type</span>\n <select\n aria-label=\"Product type\"\n value={type}\n onChange={(event) => setType(event.target.value)}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n >\n <option value=\"APP\">APP</option>\n <option value=\"AGENT\">AGENT</option>\n <option value=\"NODE\">NODE</option>\n <option value=\"WIDGET\">WIDGET</option>\n <option value=\"WORKFLOW\">WORKFLOW</option>\n </select>\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Price</span>\n <input\n type=\"number\"\n aria-label=\"Price\"\n min=\"0\"\n step=\"0.01\"\n value={price}\n onChange={(event) => setPrice(event.target.value)}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n />\n </label>\n </div>\n\n <label className=\"block space-y-1\">\n <span className=\"text-sm text-text-secondary\">Description</span>\n <textarea\n aria-label=\"Description\"\n value={description}\n onChange={(event) => setDescription(event.target.value)}\n rows={3}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n />\n </label>\n\n <label className=\"block space-y-1\">\n <span className=\"text-sm text-text-secondary\">Manifest (JSON)</span>\n <textarea\n aria-label=\"Manifest JSON\"\n value={manifestText}\n onChange={(event) => setManifestText(event.target.value)}\n rows={16}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 font-mono text-xs text-text-primary\"\n />\n {parsedManifest.error && (\n <p className=\"text-xs text-status-error-text\">{parsedManifest.error}</p>\n )}\n </label>\n\n {error && (\n <p\n role=\"alert\"\n className=\"rounded-md bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text\"\n >\n {error}\n </p>\n )}\n {success && (\n <p\n role=\"status\"\n className=\"rounded-md bg-status-success-bg-subtle px-3 py-2 text-sm text-status-success-text\"\n >\n {success}\n </p>\n )}\n\n <button\n type=\"submit\"\n disabled={submitting}\n className=\"rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text disabled:cursor-not-allowed disabled:opacity-60\"\n >\n {submitting ? 'Submitting...' : 'Submit Product'}\n </button>\n </form>\n </GlassCard>\n </main>\n );\n};\n"],"mappings":";;;;;;AAMA,IAAM,IAAmB,KAAK,UAC5B;CACE,eAAe;CACf,UAAU;CACV,QAAQ,EAAE,MAAM,kBAAkB;CAClC,eAAe;EACb,YAAY;EACZ,UAAU,CAAC,aAAa;EACzB;CACD,aAAa,CAAC,iBAAiB;CAC/B,cAAc,EACZ,cAAc,EAAE,EACjB;CACF,EACD,MACA,EACD,EAEY,UAAgC;CAC3C,IAAM,IAAS,GAAiB,EAE1B,CAAC,GAAM,KAAW,EAAS,GAAG,EAC9B,CAAC,GAAM,KAAW,EAAS,GAAG,EAC9B,CAAC,GAAa,KAAkB,EAAS,GAAG,EAC5C,CAAC,GAAM,KAAW,EAAS,MAAM,EACjC,CAAC,GAAO,KAAY,EAAS,IAAI,EACjC,CAAC,GAAc,KAAmB,EAAS,EAAiB,EAC5D,CAAC,GAAY,KAAiB,EAAS,GAAM,EAC7C,CAAC,GAAO,KAAY,EAAwB,KAAK,EACjD,CAAC,GAAS,KAAc,EAAwB,KAAK,EAErD,IAAiB,QAAc;AACnC,MAAI;AACF,UAAO;IAAE,OAAO,KAAK,MAAM,EAAa;IAAE,OAAO;IAAuB;UAClE;AACN,UAAO;IAAE,OAAO;IAAM,OAAO;IAA6B;;IAE3D,CAAC,EAAa,CAAC;AA+DlB,QACE,kBAAC,QAAD;EAAM,WAAU;YAAhB,CACE,kBAAC,UAAD;GAAQ,WAAU;aAAlB,CACE,kBAAC,MAAD;IAAI,WAAU;c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ACP,WAAW,MAAU,EAAe,EAAM,OAAO,MAAM;OACvD,MAAM;OACN,WAAU;OACV,CAAA,CACI;;KAER,kBAAC,SAAD;MAAO,WAAU;gBAAjB;OACE,kBAAC,QAAD;QAAM,WAAU;kBAA8B;QAAsB,CAAA;OACpE,kBAAC,YAAD;QACE,cAAW;QACX,OAAO;QACP,WAAW,MAAU,EAAgB,EAAM,OAAO,MAAM;QACxD,MAAM;QACN,UAAA;QACA,iBAAc;QACd,WAAU;QACV,CAAA;OACD,EAAe,SACd,kBAAC,KAAD;QAAG,WAAU;kBAAkC,EAAe;QAAU,CAAA;OAEpE;;KAEP,KACC,kBAAC,KAAD;MACE,MAAK;MACL,WAAU;gBAET;MACC,CAAA;KAEL,KACC,kBAAC,KAAD;MACE,MAAK;MACL,WAAU;gBAET;MACC,CAAA;KAGN,kBAAC,UAAD;MACE,MAAK;MACL,UAAU;MACV,WAAU;gBAET,IAAa,kBAAkB;MACzB,CAAA;KACJ;;GACG,CAAA,CACP"}
|
|
1
|
+
{"version":3,"file":"PublisherSubmitPage.js","names":[],"sources":["../../src/pages/PublisherSubmitPage.tsx"],"sourcesContent":["import { useApolloClient } from '@apollo/client/react';\nimport { useMemo, useState, type FC, type FormEvent } from 'react';\n\nimport { CreateProductForPublisherDocument } from '../generated/global-operations';\n\nconst DEFAULT_MANIFEST = JSON.stringify(\n {\n schemaVersion: '1.0.0',\n itemType: 'app',\n author: { name: 'Publisher Team' },\n compatibility: {\n minVersion: '2026.1.0',\n products: ['workspaces'],\n },\n permissions: ['workspace:read'],\n dependencies: {\n integrations: [],\n },\n },\n null,\n 2\n);\n\nexport const PublisherSubmitPage: FC = () => {\n const client = useApolloClient();\n\n const [name, setName] = useState('');\n const [slug, setSlug] = useState('');\n const [description, setDescription] = useState('');\n const [type, setType] = useState('APP');\n const [price, setPrice] = useState('0');\n const [manifestText, setManifestText] = useState(DEFAULT_MANIFEST);\n const [submitting, setSubmitting] = useState(false);\n const [error, setError] = useState<string | null>(null);\n const [success, setSuccess] = useState<string | null>(null);\n\n const parsedManifest = useMemo(() => {\n try {\n return { value: JSON.parse(manifestText), error: null as string | null };\n } catch {\n return { value: null, error: 'Manifest JSON is invalid.' };\n }\n }, [manifestText]);\n\n const submitProduct = async (event: FormEvent) => {\n event.preventDefault();\n setError(null);\n setSuccess(null);\n\n if (!name.trim()) {\n setError('Product name is required.');\n return;\n }\n if (!slug.trim()) {\n setError('Product slug is required.');\n return;\n }\n if (parsedManifest.error || !parsedManifest.value) {\n setError(parsedManifest.error || 'Manifest JSON is required.');\n return;\n }\n\n const numericPrice = Number(price);\n if (!Number.isFinite(numericPrice) || numericPrice < 0) {\n setError('Price must be a valid non-negative number.');\n return;\n }\n\n setSubmitting(true);\n try {\n const result = await client.mutate<{\n createProduct?: { id: string; slug: string; status: string };\n }>({\n mutation: CreateProductForPublisherDocument,\n variables: {\n input: {\n name: name.trim(),\n slug: slug.trim(),\n type,\n price: numericPrice,\n pricingModel: numericPrice === 0 ? 'FREE' : 'PAID_ONETIME',\n description: description.trim() || undefined,\n manifest: parsedManifest.value,\n },\n },\n });\n\n const created = result.data?.createProduct;\n if (!created) {\n setError('Product creation failed: no product returned by API.');\n return;\n }\n\n setSuccess(`Created ${created.slug} (${created.status})`);\n setName('');\n setSlug('');\n setDescription('');\n } catch (mutationError) {\n const message = mutationError instanceof Error ? mutationError.message : 'Unknown error';\n setError(message);\n } finally {\n setSubmitting(false);\n }\n };\n\n return (\n <main className=\"mx-auto max-w-4xl p-6\">\n <header className=\"mb-6\">\n <h1 className=\"text-2xl font-semibold text-text-primary\">Submit Product</h1>\n <p className=\"mt-1 text-sm text-text-muted\">\n Create a store product with manifest JSON (raw mode).\n </p>\n </header>\n\n <form onSubmit={submitProduct} className=\"space-y-4\" aria-label=\"Submit Product\">\n <div className=\"grid gap-4 md:grid-cols-2\">\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Product Name</span>\n <input\n aria-label=\"Product Name\"\n value={name}\n onChange={(event) => setName(event.target.value)}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n placeholder=\"Acme Automation\"\n />\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Slug</span>\n <input\n aria-label=\"Slug\"\n value={slug}\n onChange={(event) => setSlug(event.target.value)}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n placeholder=\"acme-automation\"\n />\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Type</span>\n <select\n aria-label=\"Product type\"\n value={type}\n onChange={(event) => setType(event.target.value)}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n >\n <option value=\"APP\">APP</option>\n <option value=\"AGENT\">AGENT</option>\n <option value=\"NODE\">NODE</option>\n <option value=\"WIDGET\">WIDGET</option>\n <option value=\"WORKFLOW\">WORKFLOW</option>\n </select>\n </label>\n\n <label className=\"space-y-1\">\n <span className=\"text-sm text-text-secondary\">Price</span>\n <input\n type=\"number\"\n aria-label=\"Price\"\n min=\"0\"\n step=\"0.01\"\n value={price}\n onChange={(event) => setPrice(event.target.value)}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n />\n </label>\n </div>\n\n <label className=\"block space-y-1\">\n <span className=\"text-sm text-text-secondary\">Description</span>\n <textarea\n aria-label=\"Description\"\n value={description}\n onChange={(event) => setDescription(event.target.value)}\n rows={3}\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm text-text-primary\"\n />\n </label>\n\n <label className=\"block space-y-1\">\n <span className=\"text-sm text-text-secondary\">Manifest (JSON)</span>\n <textarea\n aria-label=\"Manifest JSON\"\n value={manifestText}\n onChange={(event) => setManifestText(event.target.value)}\n rows={16}\n required\n aria-required=\"true\"\n className=\"w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 font-mono text-xs text-text-primary\"\n />\n {parsedManifest.error && (\n <p className=\"text-xs text-status-error-text\">{parsedManifest.error}</p>\n )}\n </label>\n\n {error && (\n <p\n role=\"alert\"\n className=\"rounded-md bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text\"\n >\n {error}\n </p>\n )}\n {success && (\n <p\n role=\"status\"\n className=\"rounded-md bg-status-success-bg-subtle px-3 py-2 text-sm text-status-success-text\"\n >\n {success}\n </p>\n )}\n\n <button\n type=\"submit\"\n disabled={submitting}\n className=\"rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text disabled:cursor-not-allowed disabled:opacity-60\"\n >\n {submitting ? 'Submitting...' : 'Submit Product'}\n </button>\n </form>\n </main>\n );\n};\n"],"mappings":";;;;;AAKA,IAAM,IAAmB,KAAK,UAC5B;CACE,eAAe;CACf,UAAU;CACV,QAAQ,EAAE,MAAM,kBAAkB;CAClC,eAAe;EACb,YAAY;EACZ,UAAU,CAAC,aAAa;EACzB;CACD,aAAa,CAAC,iBAAiB;CAC/B,cAAc,EACZ,cAAc,EAAE,EACjB;CACF,EACD,MACA,EACD,EAEY,UAAgC;CAC3C,IAAM,IAAS,GAAiB,EAE1B,CAAC,GAAM,KAAW,EAAS,GAAG,EAC9B,CAAC,GAAM,KAAW,EAAS,GAAG,EAC9B,CAAC,GAAa,KAAkB,EAAS,GAAG,EAC5C,CAAC,GAAM,KAAW,EAAS,MAAM,EACjC,CAAC,GAAO,KAAY,EAAS,IAAI,EACjC,CAAC,GAAc,KAAmB,EAAS,EAAiB,EAC5D,CAAC,GAAY,KAAiB,EAAS,GAAM,EAC7C,CAAC,GAAO,KAAY,EAAwB,KAAK,EACjD,CAAC,GAAS,KAAc,EAAwB,KAAK,EAErD,IAAiB,QAAc;AACnC,MAAI;AACF,UAAO;IAAE,OAAO,KAAK,MAAM,EAAa;IAAE,OAAO;IAAuB;UAClE;AACN,UAAO;IAAE,OAAO;IAAM,OAAO;IAA6B;;IAE3D,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BAAC,QAAD;MAAM,WAAU;gBAA8B;MAAkB,CAAA,EAChE,kBAAC,YAAD;MACE,cAAW;MACX,OAAO;MACP,WAAW,MAAU,EAAe,EAAM,OAAO,MAAM;MACvD,MAAM;MACN,WAAU;MACV,CAAA,CACI;;IAER,kBAAC,SAAD;KAAO,WAAU;eAAjB;MACE,kBAAC,QAAD;OAAM,WAAU;iBAA8B;OAAsB,CAAA;MACpE,kBAAC,YAAD;OACE,cAAW;OACX,OAAO;OACP,WAAW,MAAU,EAAgB,EAAM,OAAO,MAAM;OACxD,MAAM;OACN,UAAA;OACA,iBAAc;OACd,WAAU;OACV,CAAA;MACD,EAAe,SACd,kBAAC,KAAD;OAAG,WAAU;iBAAkC,EAAe;OAAU,CAAA;MAEpE;;IAEP,KACC,kBAAC,KAAD;KACE,MAAK;KACL,WAAU;eAET;KACC,CAAA;IAEL,KACC,kBAAC,KAAD;KACE,MAAK;KACL,WAAU;eAET;KACC,CAAA;IAGN,kBAAC,UAAD;KACE,MAAK;KACL,UAAU;KACV,WAAU;eAET,IAAa,kBAAkB;KACzB,CAAA;IACJ;KACF"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getMainDefinition as e } from "../node_modules/@apollo/client/utilities/internal/getMainDefinition.js";
|
|
2
|
-
import { GraphQLWsLink as t } from "../node_modules/@apollo/client/link/subscriptions/index.js";
|
|
3
|
-
import { createClient as n } from "../node_modules/graphql-ws/dist/client.js";
|
|
1
|
+
import { getMainDefinition as e } from "../node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/utilities/internal/getMainDefinition.js";
|
|
2
|
+
import { GraphQLWsLink as t } from "../node_modules/.bun/@apollo_client@4.1.9_e571b0b00fd00a97/node_modules/@apollo/client/link/subscriptions/index.js";
|
|
3
|
+
import { createClient as n } from "../node_modules/.bun/graphql-ws@6.0.8_796ebe57c2b0ffe0/node_modules/graphql-ws/dist/client.js";
|
|
4
4
|
import { createContext as r, use as i, useMemo as a } from "react";
|
|
5
5
|
import { ApolloClient as o, InMemoryCache as s, createHttpLink as c, from as l, split as u } from "@apollo/client/core";
|
|
6
6
|
import { ApolloProvider as d } from "@apollo/client/react";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@burdenoff/microfe-store",
|
|
3
|
-
"version": "2026.625.
|
|
3
|
+
"version": "2026.625.4",
|
|
4
4
|
"description": "Store microfrontend for Burdenoff products",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@apollo/client": "^4.0.11",
|
|
43
|
-
"@burdenoff/fe-libs": "
|
|
43
|
+
"@burdenoff/fe-libs": "workspace:*",
|
|
44
44
|
"@tanstack/react-query": "^5.90.16",
|
|
45
45
|
"clsx": "^2.1.1",
|
|
46
46
|
"graphql": "^16.10.0",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CombinedGraphQLErrors.js","names":[],"sources":["../../../../../node_modules/@apollo/client/errors/CombinedGraphQLErrors.js"],"sourcesContent":["import { brand, isBranded } from \"./utils.js\";\nfunction defaultFormatMessage(errors) {\n return (errors\n // Handle non-spec-compliant servers: See #1185\n .filter((e) => e)\n .map((e) => e.message || \"Error message not found.\")\n .join(\"\\n\"));\n}\n/**\n * Represents the combined list of GraphQL errors returned from the server in a\n * GraphQL response. This error type is used when your GraphQL operation returns\n * errors in the `errors` field of the response.\n *\n * @remarks\n *\n * When your GraphQL operation encounters errors on the server side (such as\n * resolver errors, validation errors, or syntax errors), the server returns\n * these errors in the `errors` array of the GraphQL response. Apollo Client\n * wraps these errors in a `CombinedGraphQLErrors` object, which provides access\n * to the individual errors while maintaining additional context about the\n * response.\n *\n * @example\n *\n * ```ts\n * import { CombinedGraphQLErrors } from \"@apollo/client/errors\";\n *\n * // Check if an error is a CombinedGraphQLErrors object\n * if (CombinedGraphQLErrors.is(error)) {\n * // Access individual GraphQL errors\n * error.errors.forEach((graphQLError) => {\n * console.log(graphQLError.message);\n * console.log(graphQLError.path);\n * console.log(graphQLError.locations);\n * });\n *\n * // Access the original GraphQL result\n * console.log(error.result);\n * }\n * ```\n */\nexport class CombinedGraphQLErrors extends Error {\n /**\n * A method that determines whether an error is a `CombinedGraphQLErrors`\n * object. This method enables TypeScript to narrow the error type.\n * \n * @example\n * \n * ```ts\n * if (CombinedGraphQLErrors.is(error)) {\n * // TypeScript now knows `error` is a `CombinedGraphQLErrors` object\n * console.log(error.errors);\n * }\n * ```\n */\n static is(error) {\n return isBranded(error, \"CombinedGraphQLErrors\");\n }\n /**\n * A function that formats the error message used for the error's `message`\n * property. Override this method to provide your own formatting.\n * \n * @remarks\n * \n * The `formatMessage` function is called by the `CombinedGraphQLErrors`\n * constructor to provide a formatted message as the `message` property of the\n * `CombinedGraphQLErrors` object. Follow the [\"Providing a custom message\n * formatter\"](https://www.apollographql.com/docs/react/api/errors/CombinedGraphQLErrors#providing-a-custom-message-formatter) guide to learn how to modify the message format.\n * \n * @param errors - The array of GraphQL errors returned from the server in\n * the `errors` field of the response.\n * @param options - Additional context that could be useful when formatting\n * the message.\n */\n static formatMessage = defaultFormatMessage;\n /**\n * The raw list of GraphQL errors returned by the `errors` field in the GraphQL response.\n */\n errors;\n /**\n * Partial data returned in the `data` field of the GraphQL response.\n */\n data;\n /**\n * Extensions returned by the `extensions` field in the GraphQL response.\n */\n extensions;\n constructor(result, errors = result.errors || []) {\n super(CombinedGraphQLErrors.formatMessage(errors, {\n result,\n defaultFormatMessage,\n }));\n this.errors = errors;\n this.data = result.data;\n this.extensions = result.extensions;\n this.name = \"CombinedGraphQLErrors\";\n brand(this);\n Object.setPrototypeOf(this, CombinedGraphQLErrors.prototype);\n }\n}\n//# sourceMappingURL=CombinedGraphQLErrors.js.map\n"],"x_google_ignoreList":[0],"mappings":";;AACA,SAAS,EAAqB,GAAQ;AAClC,QAAQ,EAEH,QAAQ,MAAM,EAAE,CAChB,KAAK,MAAM,EAAE,WAAW,2BAA2B,CACnD,KAAK,KAAK;;AAmCnB,IAAa,IAAb,MAAa,UAA8B,MAAM;CAc7C,OAAO,GAAG,GAAO;AACb,SAAO,EAAU,GAAO,wBAAwB;;CAkBpD,OAAO,gBAAgB;CAIvB;CAIA;CAIA;CACA,YAAY,GAAQ,IAAS,EAAO,UAAU,EAAE,EAAE;AAU9C,EATA,MAAM,EAAsB,cAAc,GAAQ;GAC9C;GACA;GACH,CAAC,CAAC,EACH,KAAK,SAAS,GACd,KAAK,OAAO,EAAO,MACnB,KAAK,aAAa,EAAO,YACzB,KAAK,OAAO,yBACZ,EAAM,KAAK,EACX,OAAO,eAAe,MAAM,EAAsB,UAAU"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","names":[],"sources":["../../../../../node_modules/@apollo/client/errors/utils.js"],"sourcesContent":["export function isBranded(error, name) {\n return (typeof error === \"object\" &&\n error !== null &&\n error[Symbol.for(\"apollo.error\")] === name);\n}\nexport function brand(error) {\n Object.defineProperty(error, Symbol.for(\"apollo.error\"), {\n value: error.name,\n enumerable: false,\n writable: false,\n configurable: false,\n });\n}\n//# sourceMappingURL=utils.js.map"],"x_google_ignoreList":[0],"mappings":";AAAA,SAAgB,EAAU,GAAO,GAAM;AACnC,QAAQ,OAAO,KAAU,cACrB,KACA,EAAM,OAAO,IAAI,eAAe,MAAM;;AAE9C,SAAgB,EAAM,GAAO;AACzB,QAAO,eAAe,GAAO,OAAO,IAAI,eAAe,EAAE;EACrD,OAAO,EAAM;EACb,YAAY;EACZ,UAAU;EACV,cAAc;EACjB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ApolloLink.js","names":[],"sources":["../../../../../../node_modules/@apollo/client/link/core/ApolloLink.js"],"sourcesContent":["import { EMPTY } from \"rxjs\";\nimport { createOperation } from \"@apollo/client/link/utils\";\nimport { __DEV__ } from \"@apollo/client/utilities/environment\";\nimport { invariant, newInvariantError, } from \"@apollo/client/utilities/invariant\";\n/**\n * The base class for all links in Apollo Client. A link represents either a\n * self-contained modification to a GraphQL operation or a side effect (such as\n * logging).\n *\n * @remarks\n *\n * Links enable you to customize Apollo Client's request flow by composing\n * together different pieces of functionality into a chain of links. Each\n * link represents a specific capability, such as adding authentication headers,\n * retrying failed requests, batching operations, or sending requests to a\n * GraphQL server.\n *\n * Every link must define a request handler via its constructor or by extending\n * this class and implementing the `request` method.\n *\n * @example\n *\n * ```ts\n * import { ApolloLink } from \"@apollo/client\";\n *\n * const link = new ApolloLink((operation, forward) => {\n * console.log(\"Operation:\", operation.operationName);\n * return forward(operation);\n * });\n * ```\n */\nexport class ApolloLink {\n /**\n * Creates a link that completes immediately and does not emit a result.\n *\n * @example\n *\n * ```ts\n * const link = ApolloLink.empty();\n * ```\n */\n static empty() {\n return new ApolloLink(() => EMPTY);\n }\n /**\n * Composes multiple links into a single composed link that executes each\n * provided link in serial order.\n *\n * @example\n *\n * ```ts\n * import { from, HttpLink, ApolloLink } from \"@apollo/client\";\n * import { RetryLink } from \"@apollo/client/link/retry\";\n * import MyAuthLink from \"../auth\";\n *\n * const link = ApolloLink.from([\n * new RetryLink(),\n * new MyAuthLink(),\n * new HttpLink({ uri: \"http://localhost:4000/graphql\" }),\n * ]);\n * ```\n *\n * @param links - An array of `ApolloLink` instances or request handlers that\n * are executed in serial order.\n */\n static from(links) {\n if (links.length === 0)\n return ApolloLink.empty();\n const [first, ...rest] = links;\n return first.concat(...rest);\n }\n /**\n * Creates a link that conditionally routes a request to different links.\n *\n * @example\n *\n * ```ts\n * import { ApolloLink, HttpLink } from \"@apollo/client\";\n *\n * const link = ApolloLink.split(\n * (operation) => operation.getContext().version === 1,\n * new HttpLink({ uri: \"http://localhost:4000/v1/graphql\" }),\n * new HttpLink({ uri: \"http://localhost:4000/v2/graphql\" })\n * );\n * ```\n *\n * @param test - A predicate function that receives the current `operation`\n * and returns a boolean indicating which link to execute. Returning `true`\n * executes the `left` link. Returning `false` executes the `right` link.\n *\n * @param left - The link that executes when the `test` function returns\n * `true`.\n *\n * @param right - The link that executes when the `test` function returns\n * `false`. If the `right` link is not provided, the request is forwarded to\n * the next link in the chain.\n */\n static split(test, left, right = new ApolloLink((op, forward) => forward(op))) {\n const link = new ApolloLink((operation, forward) => {\n const result = test(operation);\n if (__DEV__) {\n if (typeof result !== \"boolean\") {\n __DEV__ && invariant.warn(63, result);\n }\n }\n return result ?\n left.request(operation, forward)\n : right.request(operation, forward);\n });\n return Object.assign(link, { left, right });\n }\n /**\n * Executes a GraphQL request against a link. The `execute` function begins\n * the request by calling the request handler of the link.\n *\n * @example\n *\n * ```ts\n * const observable = ApolloLink.execute(link, { query, variables }, { client });\n *\n * observable.subscribe({\n * next(value) {\n * console.log(\"Received\", value);\n * },\n * error(error) {\n * console.error(\"Oops got error\", error);\n * },\n * complete() {\n * console.log(\"Request complete\");\n * },\n * });\n * ```\n *\n * @param link - The `ApolloLink` instance to execute the request.\n *\n * @param request - The GraphQL request details, such as the `query` and\n * `variables`.\n *\n * @param context - The execution context for the request, such as the\n * `client` making the request.\n */\n static execute(link, request, context) {\n return link.request(createOperation(request, context), () => {\n if (__DEV__) {\n __DEV__ && invariant.warn(64);\n }\n return EMPTY;\n });\n }\n /**\n * Combines multiple links into a single composed link.\n *\n * @example\n *\n * ```ts\n * const link = ApolloLink.concat(firstLink, secondLink, thirdLink);\n * ```\n *\n * @param links - The links to concatenate into a single link. Each link will\n * execute in serial order.\n *\n * @deprecated Use `ApolloLink.from` instead. `ApolloLink.concat` will be\n * removed in a future major version.\n */\n static concat(...links) {\n return ApolloLink.from(links);\n }\n constructor(request) {\n if (request)\n this.request = request;\n }\n /**\n * Concatenates a link that conditionally routes a request to different links.\n *\n * @example\n *\n * ```ts\n * import { ApolloLink, HttpLink } from \"@apollo/client\";\n *\n * const previousLink = new ApolloLink((operation, forward) => {\n * // Handle the request\n *\n * return forward(operation);\n * });\n *\n * const link = previousLink.split(\n * (operation) => operation.getContext().version === 1,\n * new HttpLink({ uri: \"http://localhost:4000/v1/graphql\" }),\n * new HttpLink({ uri: \"http://localhost:4000/v2/graphql\" })\n * );\n * ```\n *\n * @param test - A predicate function that receives the current `operation`\n * and returns a boolean indicating which link to execute. Returning `true`\n * executes the `left` link. Returning `false` executes the `right` link.\n *\n * @param left - The link that executes when the `test` function returns\n * `true`.\n *\n * @param right - The link that executes when the `test` function returns\n * `false`. If the `right` link is not provided, the request is forwarded to\n * the next link in the chain.\n */\n split(test, left, right) {\n return this.concat(ApolloLink.split(test, left, right));\n }\n /**\n * Combines the link with other links into a single composed link.\n *\n * @example\n *\n * ```ts\n * import { ApolloLink, HttpLink } from \"@apollo/client\";\n *\n * const previousLink = new ApolloLink((operation, forward) => {\n * // Handle the request\n *\n * return forward(operation);\n * });\n *\n * const link = previousLink.concat(\n * link1,\n * link2,\n * new HttpLink({ uri: \"http://localhost:4000/graphql\" })\n * );\n * ```\n */\n concat(...links) {\n if (links.length === 0) {\n return this;\n }\n return links.reduce(this.combine.bind(this), this);\n }\n combine(left, right) {\n const link = new ApolloLink((operation, forward) => {\n return left.request(operation, (op) => right.request(op, forward));\n });\n return Object.assign(link, { left, right });\n }\n /**\n * Runs the request handler for the provided operation.\n *\n * > [!NOTE]\n * > This is called by the `ApolloLink.execute` function for you and should\n * > not be called directly. Prefer using `ApolloLink.execute` to make the\n * > request instead.\n */\n request(operation, forward) {\n throw newInvariantError(65);\n }\n /**\n * @internal\n * Used to iterate through all links that are concatenations or `split` links.\n * \n * @deprecated This is an internal API and should not be used directly. This can be removed or changed at any time.\n */\n left;\n /**\n * @internal\n * Used to iterate through all links that are concatenations or `split` links.\n * \n * @deprecated This is an internal API and should not be used directly. This can be removed or changed at any time.\n */\n right;\n}\n//# sourceMappingURL=ApolloLink.js.map\n"],"x_google_ignoreList":[0],"mappings":";;;;AA+BA,IAAa,IAAb,MAAa,EAAW;CAUpB,OAAO,QAAQ;AACX,SAAO,IAA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ted from the graphql-ws npm package:\n// https://github.com/enisdenjo/graphql-ws\n//\n// Most of the file comes from that package's README; some other parts (such as\n// isLikeCloseEvent) come from its source.\n//\n// Here's the license of the original code:\n//\n// The MIT License (MIT)\n//\n// Copyright (c) 2020-2021 Denis Badurina\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\nimport { Observable } from \"rxjs\";\nimport { CombinedGraphQLErrors } from \"@apollo/client/errors\";\nimport { ApolloLink } from \"@apollo/client/link\";\nimport { print } from \"@apollo/client/utilities\";\nimport { isNonNullObject } from \"@apollo/client/utilities/internal\";\n// https://developer.mozilla.org/en-US/docs/Web/API/WebSocket/close_event\nfunction isLikeCloseEvent(val) {\n return isNonNullObject(val) && \"code\" in val && \"reason\" in val;\n}\n// https://developer.mozilla.org/en-US/docs/Web/API/WebSocket/error_event\nfunction isLikeErrorEvent(err) {\n return isNonNullObject(err) && err.target?.readyState === WebSocket.CLOSED;\n}\n/**\n * The `GraphQLWsLink` is a terminating link sends GraphQL operations over a\n * WebSocket connection using the [`graphql-ws`](https://www.npmjs.com/package/graphql-ws) library. It's used most\n * commonly with GraphQL [subscriptions](https://apollographql.com/docs/react/data/subscriptions/),\n *\n * > [!NOTE]\n * > This link works with the `graphql-ws` library. If your server uses\n * > the deprecated `subscriptions-transport-ws` library, use the deprecated\n * > [`WebSocketLink`](https://apollographql.com/docs/react/api/link/apollo-link-ws) link instead.\n *\n * @example\n *\n * ```ts\n * import { GraphQLWsLink } from \"@apollo/client/link/subscriptions\";\n * import { createClient } from \"graphql-ws\";\n *\n * const link = new GraphQLWsLink(\n * createClient({\n * url: \"ws://localhost:3000/subscriptions\",\n * })\n * );\n * ```\n */\nexport class GraphQLWsLink extends ApolloLink {\n client;\n constructor(client) {\n super();\n this.client = client;\n }\n request(operation) {\n return new Observable((observer) => {\n const { query, variables, operationName, extensions } = operation;\n return this.client.subscribe({ variables, operationName, extensions, query: print(query) }, {\n next: observer.next.bind(observer),\n complete: observer.complete.bind(observer),\n error: (err) => {\n if (err instanceof Error) {\n return observer.error(err);\n }\n const likeClose = isLikeCloseEvent(err);\n if (likeClose || isLikeErrorEvent(err)) {\n return observer.error(\n // reason will be available on clean closes\n new Error(`Socket closed${likeClose ? ` with event ${err.code}` : \"\"}${likeClose ? ` ${err.reason}` : \"\"}`));\n }\n return observer.error(new CombinedGraphQLErrors({\n errors: Array.isArray(err) ? err : [err],\n }));\n },\n // casting around a wrong type in graphql-ws, which incorrectly expects `Sink<ExecutionResult>`\n });\n });\n }\n}\n//# sourceMappingURL=index.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;;AAmCA,SAAS,EAAiB,GAAK;AAC3B,QAAO,EAAgB,EAAI,IAAI,UAAU,KAAO,YAAY;;AAGhE,SAAS,EAAiB,GAAK;AAC3B,QAAO,EAAgB,EAAI,IAAI,EAAI,QAAQ,eAAe,UAAU;;AAyBxE,IAAa,IAAb,cAAmC,EAAW;CAC1C;CACA,YAAY,GAAQ;AAEhB,EADA,OAAO,EACP,KAAK,SAAS;;CAElB,QAAQ,GAAW;AACf,SAAO,IAAI,GAAY,MAAa;GAChC,IAAM,EAAE,UAAO,cAAW,kBAAe,kBAAe;AACxD,UAAO,KAAK,OAAO,UAAU;IAAE;IAAW;IAAe;IAAY,OAAO,EAAM,EAAM;IAAE,EAAE;IACxF,MAAM,EAAS,KAAK,KAAK,EAAS;IAClC,UAAU,EAAS,SAAS,KAAK,EAAS;IAC1C,QAAQ,MAAQ;AACZ,SAAI,aAAe,MACf,QAAO,EAAS,MAAM,EAAI;KAE9B,IAAM,IAAY,EAAiB,EAAI;AAMvC,YALI,KAAa,EAAiB,EAAI,GAC3B,EAAS,MAEhB,gBAAI,MAAM,gBAAgB,IAAY,eAAe,EAAI,SAAS,KAAK,IAAY,IAAI,EAAI,WAAW,KAAK,CAAC,GAEzG,EAAS,MAAM,IAAI,EAAsB,EAC5C,QAAQ,MAAM,QAAQ,EAAI,GAAG,IAAM,CAAC,EAAI,EAC3C,CAAC,CAAC;;IAGV,CAAC;IACJ"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"createOperation.js","names":[],"sources":["../../../../../../node_modules/@apollo/client/link/utils/createOperation.js"],"sourcesContent":["import { getOperationDefinition, getOperationName, } from \"@apollo/client/utilities/internal\";\nexport function createOperation(request, { client }) {\n const operation = {\n query: request.query,\n variables: request.variables || {},\n extensions: request.extensions || {},\n operationName: getOperationName(request.query),\n operationType: getOperationDefinition(request.query).operation,\n };\n let context = { ...request.context };\n const setContext = (next) => {\n if (typeof next === \"function\") {\n context = { ...context, ...next(getContext()) };\n }\n else {\n context = { ...context, ...next };\n }\n };\n const getContext = () => Object.freeze({ ...context });\n Object.defineProperty(operation, \"setContext\", {\n enumerable: false,\n value: setContext,\n });\n Object.defineProperty(operation, \"getContext\", {\n enumerable: false,\n value: getContext,\n });\n Object.defineProperty(operation, \"client\", {\n enumerable: false,\n value: client,\n });\n return operation;\n}\n//# sourceMappingURL=createOperation.js.map"],"x_google_ignoreList":[0],"mappings":";;;AACA,SAAgB,EAAgB,GAAS,EAAE,aAAU;CACjD,IAAM,IAAY;EACd,OAAO,EAAQ;EACf,WAAW,EAAQ,aAAa,EAAE;EAClC,YAAY,EAAQ,cAAc,EAAE;EACpC,eAAe,EAAiB,EAAQ,MAAM;EAC9C,eAAe,EAAuB,EAAQ,MAAM,CAAC;EACxD,EACG,IAAU,EAAE,GAAG,EAAQ,SAAS,EAC9B,KAAc,MAAS;AACzB,EAII,IAJA,OAAO,KAAS,aACN;GAAE,GAAG;GAAS,GAAG,EAAK,GAAY,CAAC;GAAE,GAGrC;GAAE,GAAG;GAAS,GAAG;GAAM;IAGnC,UAAmB,OAAO,OAAO,EAAE,GAAG,GAAS,CAAC;AAatD,QAZA,OAAO,eAAe,GAAW,cAAc;EAC3C,YAAY;EACZ,OAAO;EACV,CAAC,EACF,OAAO,eAAe,GAAW,cAAc;EAC3C,YAAY;EACZ,OAAO;EACV,CAAC,EACF,OAAO,eAAe,GAAW,UAAU;EACvC,YAAY;EACZ,OAAO;EACV,CAAC,EACK"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sizes.js","names":["global"],"sources":["../../../../../../node_modules/@apollo/client/utilities/caching/sizes.js"],"sourcesContent":["import { global } from \"@apollo/client/utilities/internal/globals\";\nconst cacheSizeSymbol = Symbol.for(\"apollo.cacheSize\");\n/**\n * The global cache size configuration for Apollo Client.\n *\n * @remarks\n *\n * You can directly modify this object, but any modification will\n * only have an effect on caches that are created after the modification.\n *\n * So for global caches, such as `canonicalStringify` and `print`,\n * you might need to call `.reset` on them, which will essentially re-create them.\n *\n * Alternatively, you can set `globalThis[Symbol.for(\"apollo.cacheSize\")]` before\n * you load the Apollo Client package:\n *\n * @example\n *\n * ```ts\n * globalThis[Symbol.for(\"apollo.cacheSize\")] = {\n * print: 100,\n * } satisfies Partial<CacheSizes>; // the `satisfies` is optional if using TypeScript\n * ```\n */\nexport const cacheSizes = { ...global[cacheSizeSymbol] };\n//# sourceMappingURL=sizes.js.map"],"x_google_ignoreList":[0],"mappings":";AAwBA,IAAa,IAAa,EAAE,GAAGA,EAvBP,OAAO,IAAI,mBAAmB,GAuBE"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"print.js","names":["print","origPrint"],"sources":["../../../../../../node_modules/@apollo/client/utilities/graphql/print.js"],"sourcesContent":["import { print as origPrint } from \"graphql\";\nimport { __DEV__ } from \"@apollo/client/utilities/environment\";\nimport { AutoCleanedWeakCache, registerGlobalCache, } from \"@apollo/client/utilities/internal\";\nimport { cacheSizes } from \"../caching/index.js\";\nlet printCache;\n/**\n * Converts an AST into a string, using one set of reasonable\n * formatting rules.\n *\n * @remarks This is the same function as the GraphQL.js `print` function but\n * with an added cache to avoid recomputation when encountering the same\n * `ASTNode` more than once.\n */\nexport const print = Object.assign((ast) => {\n let result = printCache.get(ast);\n if (!result) {\n result = origPrint(ast);\n printCache.set(ast, result);\n }\n return result;\n}, {\n reset() {\n printCache = new AutoCleanedWeakCache(cacheSizes.print || 2000 /* defaultCacheSizes.print */);\n },\n});\nprint.reset();\nif (__DEV__) {\n registerGlobalCache(\"print\", () => (printCache ? printCache.size : 0));\n}\n//# sourceMappingURL=print.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;AAIA,IAAI,GASSA,IAAQ,OAAO,QAAQ,MAAQ;CACxC,IAAI,IAAS,EAAW,IAAI,EAAI;AAKhC,QAJK,MACD,IAASC,EAAU,EAAI,EACvB,EAAW,IAAI,GAAK,EAAO,GAExB;GACR,EACC,QAAQ;AACJ,KAAa,IAAI,EAAqB,EAAW,SAAS,IAAmC;GAEpG,CAAC;AACFD,EAAM,OAAO"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"caches.js","names":[],"sources":["../../../../../../node_modules/@apollo/client/utilities/internal/caches.js"],"sourcesContent":["import { StrongCache, WeakCache } from \"@wry/caches\";\nconst scheduledCleanup = new WeakSet();\nfunction schedule(cache) {\n if (cache.size <= (cache.max || -1)) {\n return;\n }\n if (!scheduledCleanup.has(cache)) {\n scheduledCleanup.add(cache);\n setTimeout(() => {\n cache.clean();\n scheduledCleanup.delete(cache);\n }, 100);\n }\n}\n/**\n* @internal\n* A version of WeakCache that will auto-schedule a cleanup of the cache when\n* a new item is added and the cache reached maximum size.\n* Throttled to once per 100ms.\n*\n* @privateRemarks\n* Should be used throughout the rest of the codebase instead of WeakCache,\n* with the notable exception of usage in `wrap` from `optimism` - that one\n* already handles cleanup and should remain a `WeakCache`.\n* \n* @deprecated This is an internal API and should not be used directly. This can be removed or changed at any time.\n*/\nexport const AutoCleanedWeakCache = function (max, dispose) {\n /*\n Some builds of `WeakCache` are function prototypes, some are classes.\n This library still builds with an ES5 target, so we can't extend the\n real classes.\n Instead, we have to use this workaround until we switch to a newer build\n target.\n */\n const cache = new WeakCache(max, dispose);\n cache.set = function (key, value) {\n const ret = WeakCache.prototype.set.call(this, key, value);\n schedule(this);\n return ret;\n };\n return cache;\n};\n/**\n* @internal\n* A version of StrongCache that will auto-schedule a cleanup of the cache when\n* a new item is added and the cache reached maximum size.\n* Throttled to once per 100ms.\n*\n* @privateRemarks\n* Should be used throughout the rest of the codebase instead of StrongCache,\n* with the notable exception of usage in `wrap` from `optimism` - that one\n* already handles cleanup and should remain a `StrongCache`.\n* \n* @deprecated This is an internal API and should not be used directly. This can be removed or changed at any time.\n*/\nexport const AutoCleanedStrongCache = function (max, dispose) {\n /*\n Some builds of `StrongCache` are function prototypes, some are classes.\n This library still builds with an ES5 target, so we can't extend the\n real classes.\n Instead, we have to use this workaround until we switch to a newer build\n target.\n */\n const cache = new StrongCache(max, dispose);\n cache.set = function (key, value) {\n const ret = StrongCache.prototype.set.call(this, key, value);\n schedule(this);\n return ret;\n };\n return cache;\n};\n//# sourceMappingURL=caches.js.map\n"],"x_google_ignoreList":[0],"mappings":";;AACA,IAAM,oBAAmB,IAAI,SAAS;AACtC,SAAS,EAAS,GAAO;AACjB,GAAM,SAAS,EAAM,OAAO,OAG3B,EAAiB,IAAI,EAAM,KAC5B,EAAiB,IAAI,EAAM,EAC3B,iBAAiB;AAEb,EADA,EAAM,OAAO,EACb,EAAiB,OAAO,EAAM;IAC/B,IAAI;;AAgBf,IAAa,IAAuB,SAAU,GAAK,GAAS;CAQxD,IAAM,IAAQ,IAAI,EAAU,GAAK,EAAQ;AAMzC,QALA,EAAM,MAAM,SAAU,GAAK,GAAO;EAC9B,IAAM,IAAM,EAAU,UAAU,IAAI,KAAK,MAAM,GAAK,EAAM;AAE1D,SADA,EAAS,KAAK,EACP;IAEJ"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"checkDocument.js","names":[],"sources":["../../../../../../node_modules/@apollo/client/utilities/internal/checkDocument.js"],"sourcesContent":["// Checks the document for errors and throws an exception if there is an error.\nimport { Kind, visit } from \"graphql\";\nimport { __DEV__ } from \"@apollo/client/utilities/environment\";\nimport { invariant, newInvariantError, } from \"@apollo/client/utilities/invariant\";\nimport { cacheSizes } from \"../caching/sizes.js\";\nimport { getOperationName } from \"./getOperationName.js\";\nimport { memoize } from \"./memoize.js\";\n/**\n* Checks the document for errors and throws an exception if there is an error.\n*\n* @internal\n* \n* @deprecated This is an internal API and should not be used directly. This can be removed or changed at any time.\n*/\nexport const checkDocument = memoize((doc, expectedType) => {\n invariant(doc && doc.kind === \"Document\", 1);\n const operations = doc.definitions.filter((d) => d.kind === \"OperationDefinition\");\n if (__DEV__) {\n doc.definitions.forEach((definition) => {\n if (definition.kind !== \"OperationDefinition\" &&\n definition.kind !== \"FragmentDefinition\") {\n throw newInvariantError(2, definition.kind);\n }\n });\n invariant(operations.length <= 1, 3, operations.length);\n }\n if (expectedType) {\n invariant(\n operations.length == 1 && operations[0].operation === expectedType,\n 4,\n expectedType,\n expectedType,\n operations[0].operation\n );\n }\n visit(doc, {\n Field(field, _, __, path) {\n if (field.alias &&\n (field.alias.value === \"__typename\" ||\n field.alias.value.startsWith(\"__ac_\")) &&\n field.alias.value !== field.name.value) {\n // not using `invariant` so path calculation only happens in error case\n let current = doc, fieldPath = [];\n for (const key of path) {\n current = current[key];\n if (current.kind === Kind.FIELD) {\n fieldPath.push(current.alias?.value || current.name.value);\n }\n }\n fieldPath.splice(-1, 1, field.name.value);\n throw newInvariantError(\n 5,\n field.alias.value,\n fieldPath.join(\".\"),\n operations[0].operation,\n getOperationName(doc, \"(anonymous)\")\n );\n }\n },\n });\n}, {\n max: cacheSizes[\"checkDocument\"] || 2000 /* defaultCacheSizes[\"checkDocument\"] */,\n});\n//# sourceMappingURL=checkDocument.js.map\n"],"x_google_ignoreList":[0],"mappings":";;;;;;AAcA,IAAa,IAAgB,GAAS,GAAK,MAAiB;AACxD,GAAU,KAAO,EAAI,SAAS,YAAY,EAAE;CAC5C,IAAM,IAAa,EAAI,YAAY,QAAQ,MAAM,EAAE,SAAS,sBAAsB;AAmBlF,CATI,KACA,EACI,EAAW,UAAU,KAAK,EAAW,GAAG,cAAc,GACtD,GACA,GACA,GACA,EAAW,GAAG,UACjB,EAEL,EAAM,GAAK,EACP,MAAM,GAAO,GAAG,GAAI,GAAM;AACtB,MAAI,EAAM,UACL,EAAM,MAAM,UAAU,gBACnB,EAAM,MAAM,MAAM,WAAW,QAAQ,KACzC,EAAM,MAAM,UAAU,EAAM,KAAK,OAAO;GAExC,IAAI,IAAU,GAAK,IAAY,EAAE;AACjC,QAAK,IAAM,KAAO,EAEd,CADA,IAAU,EAAQ,IACd,EAAQ,SAAS,EAAK,SACtB,EAAU,KAAK,EAAQ,OAAO,SAAS,EAAQ,KAAK,MAAM;AAIlE,SADA,EAAU,OAAO,IAAI,GAAG,EAAM,KAAK,MAAM,EACnC,EACF,GACA,EAAM,MAAM,OACZ,EAAU,KAAK,IAAI,EACnB,EAAW,GAAG,WACd,EAAiB,GAAK,cAAc,CACvC;;IAGZ,CAAC;GACH,EACC,KAAK,EAAW,iBAAoB,KACvC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"getMainDefinition.js","names":[],"sources":["../../../../../../node_modules/@apollo/client/utilities/internal/getMainDefinition.js"],"sourcesContent":["import { newInvariantError } from \"@apollo/client/utilities/invariant\";\nimport { checkDocument } from \"./checkDocument.js\";\n/**\n * Returns the first operation definition from a GraphQL document. The function\n * prioritizes operation definitions over fragment definitions, which makes it\n * suitable for documents that may contain both. If no operation definition is\n * found, the first fragment definition will be returned. If no definitions are\n * found, an error is thrown.\n *\n * @remarks\n *\n * Use this function when you need to perform more advanced tasks with the main\n * definition AST node. If you want to determine when a document is a specific\n * operation type, prefer the `isQueryOperation`, `isMutationOperation`, and\n * `isSubscriptionOperation` utility functions instead.\n *\n * @param queryDoc - The GraphQL document to extract the definition from\n * @returns The main operation or fragment definition AST node\n *\n * @example\n *\n * ```ts\n * import { gql } from \"@apollo/client\";\n * import { getMainDefinition } from \"@apollo/client/utilities\";\n *\n * const query = gql`\n * query GetUser($id: ID!) {\n * user(id: $id) {\n * name\n * email\n * }\n * }\n * `;\n *\n * const definition = getMainDefinition(query);\n * ```\n *\n * @throws When the document contains no operation or fragment definitions\n */\nexport function getMainDefinition(queryDoc) {\n checkDocument(queryDoc);\n let fragmentDefinition;\n for (let definition of queryDoc.definitions) {\n if (definition.kind === \"OperationDefinition\") {\n return definition;\n }\n if (definition.kind === \"FragmentDefinition\" && !fragmentDefinition) {\n // we do this because we want to allow multiple fragment definitions\n // to precede an operation definition.\n fragmentDefinition = definition;\n }\n }\n if (fragmentDefinition) {\n return fragmentDefinition;\n }\n throw newInvariantError(12);\n}\n//# sourceMappingURL=getMainDefinition.js.map\n"],"x_google_ignoreList":[0],"mappings":";;;AAuCA,SAAgB,EAAkB,GAAU;AACxC,GAAc,EAAS;CACvB,IAAI;AACJ,MAAK,IAAI,KAAc,EAAS,aAAa;AACzC,MAAI,EAAW,SAAS,sBACpB,QAAO;AAEX,EAAI,EAAW,SAAS,wBAAwB,CAAC,MAG7C,IAAqB;;AAG7B,KAAI,EACA,QAAO;AAEX,OAAM,EAAkB,GAAG"}
|