@hexclave/next 1.0.55 → 1.0.57

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.
Files changed (78) hide show
  1. package/dist/{admin-app-impl-Bga0o6cL.d.ts → admin-app-impl-zKsW1R4h.d.ts} +4 -4
  2. package/dist/{admin-app-impl-Bga0o6cL.d.ts.map → admin-app-impl-zKsW1R4h.d.ts.map} +1 -1
  3. package/dist/clickmap/clickmap-core.d.ts +1 -1
  4. package/dist/clickmap/index.d.ts +1 -1
  5. package/dist/{client-app-B0kBC67Z.d.ts → client-app-oSumAWx3.d.ts} +2 -1
  6. package/dist/{client-app-B0kBC67Z.d.ts.map → client-app-oSumAWx3.d.ts.map} +1 -1
  7. package/dist/components/selected-team-switcher.d.ts +1 -1
  8. package/dist/components/team-icon.d.ts +1 -1
  9. package/dist/components/team-switcher.d.ts +1 -1
  10. package/dist/components-page/account-settings/payments/payments-page.d.ts +1 -1
  11. package/dist/components-page/account-settings/teams/leave-team-section.d.ts +1 -1
  12. package/dist/components-page/account-settings/teams/team-api-keys-section.d.ts +1 -1
  13. package/dist/components-page/account-settings/teams/team-display-name-section.d.ts +1 -1
  14. package/dist/components-page/account-settings/teams/team-member-invitation-section.d.ts +1 -1
  15. package/dist/components-page/account-settings/teams/team-member-list-section.d.ts +1 -1
  16. package/dist/components-page/account-settings/teams/team-page.d.ts +1 -1
  17. package/dist/components-page/account-settings/teams/team-profile-image-section.d.ts +1 -1
  18. package/dist/components-page/account-settings/teams/team-profile-user-section.d.ts +1 -1
  19. package/dist/components-page/hexclave-handler-client.d.ts +1 -1
  20. package/dist/components-page/hexclave-handler.d.ts +1 -1
  21. package/dist/dev-tool/dev-tool-core.d.ts +1 -1
  22. package/dist/dev-tool/index.d.ts +1 -1
  23. package/dist/dev-tool/index.d.ts.map +1 -1
  24. package/dist/dev-tool/index.js +18 -1
  25. package/dist/dev-tool/index.js.map +1 -1
  26. package/dist/dev-tool/index.test.d.ts +1 -0
  27. package/dist/dev-tool/index.test.js +40 -0
  28. package/dist/dev-tool/index.test.js.map +1 -0
  29. package/dist/esm/dev-tool/index.d.ts.map +1 -1
  30. package/dist/esm/dev-tool/index.js +18 -1
  31. package/dist/esm/dev-tool/index.js.map +1 -1
  32. package/dist/esm/dev-tool/index.test.d.ts +1 -0
  33. package/dist/esm/dev-tool/index.test.js +41 -0
  34. package/dist/esm/dev-tool/index.test.js.map +1 -0
  35. package/dist/esm/lib/hexclave-app/apps/implementations/admin-app-impl.d.ts +2 -2
  36. package/dist/esm/lib/hexclave-app/apps/implementations/admin-app-impl.d.ts.map +1 -1
  37. package/dist/esm/lib/hexclave-app/apps/implementations/client-app-impl.d.ts.map +1 -1
  38. package/dist/esm/lib/hexclave-app/apps/implementations/client-app-impl.js +1 -0
  39. package/dist/esm/lib/hexclave-app/apps/implementations/client-app-impl.js.map +1 -1
  40. package/dist/esm/lib/hexclave-app/apps/implementations/common.js +2 -2
  41. package/dist/esm/lib/hexclave-app/projects/index.d.ts +1 -0
  42. package/dist/esm/lib/hexclave-app/projects/index.d.ts.map +1 -1
  43. package/dist/esm/lib/hexclave-app/projects/index.js.map +1 -1
  44. package/dist/esm/pushed-config-error-overlay/index.test.js +1 -1
  45. package/dist/{hexclave-provider-BQ9wrtBt.d.ts → hexclave-provider-DnIE6JQ7.d.ts} +2 -2
  46. package/dist/{hexclave-provider-BQ9wrtBt.d.ts.map → hexclave-provider-DnIE6JQ7.d.ts.map} +1 -1
  47. package/dist/{hooks-ykQ7Wsco.d.ts → hooks-Ds3yoNo-.d.ts} +2 -2
  48. package/dist/{hooks-ykQ7Wsco.d.ts.map → hooks-Ds3yoNo-.d.ts.map} +1 -1
  49. package/dist/{index-DwE1cNLH.d.ts → index-DE-_vkL4.d.ts} +2 -2
  50. package/dist/{index-DwE1cNLH.d.ts.map → index-DE-_vkL4.d.ts.map} +1 -1
  51. package/dist/index.d.ts +4 -4
  52. package/dist/lib/hexclave-app/apps/implementations/admin-app-impl.d.ts +1 -1
  53. package/dist/lib/hexclave-app/apps/implementations/client-app-impl.d.ts +1 -1
  54. package/dist/lib/hexclave-app/apps/implementations/client-app-impl.js +1 -0
  55. package/dist/lib/hexclave-app/apps/implementations/client-app-impl.js.map +1 -1
  56. package/dist/lib/hexclave-app/apps/implementations/common.js +2 -2
  57. package/dist/lib/hexclave-app/apps/implementations/index.d.ts +1 -1
  58. package/dist/lib/hexclave-app/apps/implementations/server-app-impl.d.ts +1 -1
  59. package/dist/lib/hexclave-app/apps/index.d.ts +1 -1
  60. package/dist/lib/hexclave-app/apps/interfaces/admin-app.d.ts +1 -1
  61. package/dist/lib/hexclave-app/apps/interfaces/client-app.d.ts +1 -1
  62. package/dist/lib/hexclave-app/apps/interfaces/server-app.d.ts +1 -1
  63. package/dist/lib/hexclave-app/index.d.ts +1 -1
  64. package/dist/lib/hexclave-app/projects/index.d.ts +1 -1
  65. package/dist/lib/hexclave-app/projects/index.js.map +1 -1
  66. package/dist/lib/hexclave-app/teams/index.d.ts +1 -1
  67. package/dist/lib/hexclave-app/users/index.d.ts +1 -1
  68. package/dist/lib/hooks.d.ts +1 -1
  69. package/dist/providers/hexclave-context.d.ts +1 -1
  70. package/dist/providers/hexclave-provider-client.d.ts +1 -1
  71. package/dist/providers/hexclave-provider.d.ts +1 -1
  72. package/dist/pushed-config-error-overlay/index.d.ts +1 -1
  73. package/dist/pushed-config-error-overlay/index.test.js +1 -1
  74. package/package.json +4 -4
  75. package/src/dev-tool/index.test.ts +58 -0
  76. package/src/dev-tool/index.ts +27 -1
  77. package/src/lib/hexclave-app/apps/implementations/client-app-impl.ts +1 -0
  78. package/src/lib/hexclave-app/projects/index.ts +1 -0
@@ -17,8 +17,8 @@ let _hexclave_shared_dist_utils_stores = require("@hexclave/shared/dist/utils/st
17
17
  let ____________generated_env_js = require("../../../../generated/env.js");
18
18
  let ______url_targets_js = require("../../url-targets.js");
19
19
  //#region src/lib/hexclave-app/apps/implementations/common.ts
20
- const clientVersion = "js @hexclave/next@1.0.55";
21
- if ("js @hexclave/next@1.0.55".startsWith("STACK_COMPILE_TIME"));
20
+ const clientVersion = "js @hexclave/next@1.0.57";
21
+ if ("js @hexclave/next@1.0.57".startsWith("STACK_COMPILE_TIME"));
22
22
  const replaceHexclavePortPrefix = (input) => {
23
23
  if (!input) return input;
24
24
  const prefix = ____________generated_env_js.envVars.HEXCLAVE_PORT_PREFIX;
@@ -1,4 +1,4 @@
1
- import { n as _HexclaveServerAppImplIncomplete, r as _HexclaveClientAppImplIncomplete, t as _HexclaveAdminAppImplIncomplete } from "../../../../admin-app-impl-Bga0o6cL.js";
1
+ import { n as _HexclaveServerAppImplIncomplete, r as _HexclaveClientAppImplIncomplete, t as _HexclaveAdminAppImplIncomplete } from "../../../../admin-app-impl-zKsW1R4h.js";
2
2
 
3
3
  //#region src/lib/hexclave-app/apps/implementations/index.d.ts
4
4
  declare const _HexclaveAdminAppImpl: typeof _HexclaveAdminAppImplIncomplete, _HexclaveClientAppImpl: typeof _HexclaveClientAppImplIncomplete, _HexclaveServerAppImpl: typeof _HexclaveServerAppImplIncomplete;
@@ -1,2 +1,2 @@
1
- import { n as _HexclaveServerAppImplIncomplete } from "../../../../admin-app-impl-Bga0o6cL.js";
1
+ import { n as _HexclaveServerAppImplIncomplete } from "../../../../admin-app-impl-zKsW1R4h.js";
2
2
  export { _HexclaveServerAppImplIncomplete };
@@ -1,2 +1,2 @@
1
- import { A as HexclaveServerApp, C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, F as StackServerAppConstructorOptions, M as HexclaveServerAppConstructorOptions, N as StackServerApp, O as StackAdminAppConstructor, P as StackServerAppConstructor, S as HexclaveAdminAppConstructor, a as StackClientApp, c as StackClientAppJson, i as HexclaveClientAppJson, j as HexclaveServerAppConstructor, k as StackAdminAppConstructorOptions, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, t as HexclaveClientApp, x as HexclaveAdminApp } from "../../../client-app-B0kBC67Z.js";
1
+ import { A as HexclaveServerApp, C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, F as StackServerAppConstructorOptions, M as HexclaveServerAppConstructorOptions, N as StackServerApp, O as StackAdminAppConstructor, P as StackServerAppConstructor, S as HexclaveAdminAppConstructor, a as StackClientApp, c as StackClientAppJson, i as HexclaveClientAppJson, j as HexclaveServerAppConstructor, k as StackAdminAppConstructorOptions, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, t as HexclaveClientApp, x as HexclaveAdminApp } from "../../../client-app-oSumAWx3.js";
2
2
  export { HexclaveAdminApp, type HexclaveAdminAppConstructor, type HexclaveAdminAppConstructorOptions, HexclaveClientApp, type HexclaveClientAppConstructor, type HexclaveClientAppConstructorOptions, type HexclaveClientAppJson, HexclaveServerApp, type HexclaveServerAppConstructor, type HexclaveServerAppConstructorOptions, StackAdminApp, type StackAdminAppConstructor, type StackAdminAppConstructorOptions, StackClientApp, type StackClientAppConstructor, type StackClientAppConstructorOptions, type StackClientAppJson, StackServerApp, type StackServerAppConstructor, type StackServerAppConstructorOptions };
@@ -1,3 +1,3 @@
1
- import { C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, E as ManagedEmailProviderStatus, O as StackAdminAppConstructor, S as HexclaveAdminAppConstructor, T as ManagedEmailProviderSetupResult, b as EmailOutboxUpdateOptions, k as StackAdminAppConstructorOptions, v as EmailOutboxListOptions, w as ManagedEmailProviderListItem, x as HexclaveAdminApp, y as EmailOutboxListResult } from "../../../../client-app-B0kBC67Z.js";
1
+ import { C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, E as ManagedEmailProviderStatus, O as StackAdminAppConstructor, S as HexclaveAdminAppConstructor, T as ManagedEmailProviderSetupResult, b as EmailOutboxUpdateOptions, k as StackAdminAppConstructorOptions, v as EmailOutboxListOptions, w as ManagedEmailProviderListItem, x as HexclaveAdminApp, y as EmailOutboxListResult } from "../../../../client-app-oSumAWx3.js";
2
2
  import { a as ListSessionReplaysOptions, i as ListSessionReplayChunksResult, n as AdminSessionReplayChunk, o as ListSessionReplaysResult, r as ListSessionReplayChunksOptions, s as SessionReplayAllEventsResult, t as AdminSessionReplay } from "../../../../index-hYjsGKNc.js";
3
3
  export { type AdminSessionReplay, type AdminSessionReplayChunk, EmailOutboxListOptions, EmailOutboxListResult, EmailOutboxUpdateOptions, HexclaveAdminApp, HexclaveAdminAppConstructor, HexclaveAdminAppConstructorOptions, type ListSessionReplayChunksOptions, type ListSessionReplayChunksResult, type ListSessionReplaysOptions, type ListSessionReplaysResult, ManagedEmailProviderListItem, ManagedEmailProviderSetupResult, ManagedEmailProviderStatus, type SessionReplayAllEventsResult, StackAdminApp, StackAdminAppConstructor, StackAdminAppConstructorOptions };
@@ -1,2 +1,2 @@
1
- import { a as StackClientApp, c as StackClientAppJson, i as HexclaveClientAppJson, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, t as HexclaveClientApp } from "../../../../client-app-B0kBC67Z.js";
1
+ import { a as StackClientApp, c as StackClientAppJson, i as HexclaveClientAppJson, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, t as HexclaveClientApp } from "../../../../client-app-oSumAWx3.js";
2
2
  export { HexclaveClientApp, HexclaveClientAppConstructor, HexclaveClientAppConstructorOptions, HexclaveClientAppJson, StackClientApp, StackClientAppConstructor, StackClientAppConstructorOptions, StackClientAppJson };
@@ -1,2 +1,2 @@
1
- import { A as HexclaveServerApp, F as StackServerAppConstructorOptions, M as HexclaveServerAppConstructorOptions, N as StackServerApp, P as StackServerAppConstructor, j as HexclaveServerAppConstructor } from "../../../../client-app-B0kBC67Z.js";
1
+ import { A as HexclaveServerApp, F as StackServerAppConstructorOptions, M as HexclaveServerAppConstructorOptions, N as StackServerApp, P as StackServerAppConstructor, j as HexclaveServerAppConstructor } from "../../../../client-app-oSumAWx3.js";
2
2
  export { HexclaveServerApp, HexclaveServerAppConstructor, HexclaveServerAppConstructorOptions, StackServerApp, StackServerAppConstructor, StackServerAppConstructorOptions };
@@ -5,7 +5,7 @@ import { a as AdminTeamPermission, c as AdminTeamPermissionDefinitionUpdateOptio
5
5
  import { a as PlanUsageRow, i as PlanUsagePlanId, n as PlanUsageKind, r as PlanUsageNextPlanId, t as PlanUsage } from "../../index-B594jg4e.js";
6
6
  import { r as OAuthConnection, t as Connection } from "../../index-C_kxyHao.js";
7
7
  import { i as ServerContactChannel, t as ContactChannel } from "../../index-DN04TjLM.js";
8
- import { A as HexclaveServerApp, B as ServerListUsersOptions, C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, F as StackServerAppConstructorOptions, G as ServerTeamUser, H as ServerTeamCreateOptions, I as EditableTeamMemberProfile, J as TeamInvitation, K as Team, L as ReceivedTeamInvitation, M as HexclaveServerAppConstructorOptions, N as StackServerApp, O as StackAdminAppConstructor, P as StackServerAppConstructor, Q as TeamUser, R as SentTeamInvitation, S as HexclaveAdminAppConstructor, St as User, U as ServerTeamMemberProfile, V as ServerTeam, W as ServerTeamUpdateOptions, Y as TeamMemberProfile, Z as TeamUpdateOptions, a as StackClientApp, b as EmailOutboxUpdateOptions, c as StackClientAppJson, ct as CurrentServerUser, d as AdminProjectCreateOptions, dt as OAuthProvider, f as AdminProjectUpdateOptions, gt as ServerUser, h as PushedConfigSource, ht as ServerOAuthProvider, i as HexclaveClientAppJson, it as Auth, j as HexclaveServerAppConstructor, k as StackAdminAppConstructorOptions, l as AdminOwnedProject, lt as CurrentUser, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, ot as CurrentInternalServerUser, p as Project, q as TeamCreateOptions, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, st as CurrentInternalUser, t as HexclaveClientApp, u as AdminProject, v as EmailOutboxListOptions, x as HexclaveAdminApp, y as EmailOutboxListResult } from "../../client-app-B0kBC67Z.js";
8
+ import { A as HexclaveServerApp, B as ServerListUsersOptions, C as HexclaveAdminAppConstructorOptions, D as StackAdminApp, F as StackServerAppConstructorOptions, G as ServerTeamUser, H as ServerTeamCreateOptions, I as EditableTeamMemberProfile, J as TeamInvitation, K as Team, L as ReceivedTeamInvitation, M as HexclaveServerAppConstructorOptions, N as StackServerApp, O as StackAdminAppConstructor, P as StackServerAppConstructor, Q as TeamUser, R as SentTeamInvitation, S as HexclaveAdminAppConstructor, St as User, U as ServerTeamMemberProfile, V as ServerTeam, W as ServerTeamUpdateOptions, Y as TeamMemberProfile, Z as TeamUpdateOptions, a as StackClientApp, b as EmailOutboxUpdateOptions, c as StackClientAppJson, ct as CurrentServerUser, d as AdminProjectCreateOptions, dt as OAuthProvider, f as AdminProjectUpdateOptions, gt as ServerUser, h as PushedConfigSource, ht as ServerOAuthProvider, i as HexclaveClientAppJson, it as Auth, j as HexclaveServerAppConstructor, k as StackAdminAppConstructorOptions, l as AdminOwnedProject, lt as CurrentUser, n as HexclaveClientAppConstructor, o as StackClientAppConstructor, ot as CurrentInternalServerUser, p as Project, q as TeamCreateOptions, r as HexclaveClientAppConstructorOptions, s as StackClientAppConstructorOptions, st as CurrentInternalUser, t as HexclaveClientApp, u as AdminProject, v as EmailOutboxListOptions, x as HexclaveAdminApp, y as EmailOutboxListResult } from "../../client-app-oSumAWx3.js";
9
9
  import { a as AdminProjectConfigUpdateOptions, i as AdminProjectConfig, n as AdminEmailConfig, o as OAuthProviderConfig, r as AdminOAuthProviderConfig, s as ProjectConfig, t as AdminDomainConfig } from "../../index-Dq4xsW7_.js";
10
10
  import { r as getPagePrompt } from "../../url-targets-CWO0mjTr.js";
11
11
  export { type AdminDomainConfig, type AdminEmailConfig, type AdminEmailOutbox, type AdminEmailOutboxRecipient, type AdminEmailOutboxSimpleStatus, type AdminEmailOutboxStatus, type AdminOAuthProviderConfig, type AdminOwnedProject, type AdminProject, type AdminProjectConfig, type AdminProjectConfigUpdateOptions, type AdminProjectCreateOptions, type AdminProjectPermission, type AdminProjectPermissionDefinition, type AdminProjectPermissionDefinitionCreateOptions, type AdminProjectPermissionDefinitionUpdateOptions, type AdminProjectUpdateOptions, type AdminSendAttemptError, type AdminSentEmail, type AdminTeamPermission, type AdminTeamPermissionDefinition, type AdminTeamPermissionDefinitionCreateOptions, type AdminTeamPermissionDefinitionUpdateOptions, type Auth, type Connection, type ContactChannel, type CurrentInternalServerUser, type CurrentInternalUser, type CurrentServerUser, type CurrentUser, type EditableTeamMemberProfile, type EmailOutboxListOptions, type EmailOutboxListResult, type EmailOutboxUpdateOptions, type GetCurrentUserOptions, type GetCurrentUserOptions as GetUserOptions, type HandlerUrlOptions, type HandlerUrls, HexclaveAdminApp, type HexclaveAdminAppConstructor, type HexclaveAdminAppConstructorOptions, HexclaveClientApp, type HexclaveClientAppConstructor, type HexclaveClientAppConstructorOptions, type HexclaveClientAppJson, HexclaveServerApp, type HexclaveServerAppConstructor, type HexclaveServerAppConstructorOptions, type InternalApiKey, type InternalApiKeyBase, type InternalApiKeyBaseCrudRead, type InternalApiKeyCreateOptions, type InternalApiKeyFirstView, type OAuthConnection, type OAuthProvider, type OAuthProviderConfig, type OAuthScopesOnSignIn, type PlanUsage, type PlanUsageKind, type PlanUsageNextPlanId, type PlanUsagePlanId, type PlanUsageRow, type Project, type ProjectConfig, type PushedConfigSource, type ReceivedTeamInvitation, type ResolvedHandlerUrls, type SentTeamInvitation, type ServerContactChannel, type ServerListUsersOptions, type ServerOAuthProvider, type ServerTeam, type ServerTeamCreateOptions, type ServerTeamMemberProfile, type ServerTeamUpdateOptions, type ServerTeamUser, type ServerUser, StackAdminApp, type StackAdminAppConstructor, type StackAdminAppConstructorOptions, StackClientApp, type StackClientAppConstructor, type StackClientAppConstructorOptions, type StackClientAppJson, StackServerApp, type StackServerAppConstructor, type StackServerAppConstructorOptions, type Team, type TeamCreateOptions, type TeamInvitation, type TeamMemberProfile, type TeamUpdateOptions, type TeamUser, type User, getPagePrompt, hexclaveAppInternalsSymbol };
@@ -1,2 +1,2 @@
1
- import { _ as adminProjectUpdateOptionsToCrud, d as AdminProjectCreateOptions, f as AdminProjectUpdateOptions, g as adminProjectCreateOptionsToCrud, h as PushedConfigSource, l as AdminOwnedProject, m as PushConfigOptions, p as Project, u as AdminProject } from "../../../client-app-B0kBC67Z.js";
1
+ import { _ as adminProjectUpdateOptionsToCrud, d as AdminProjectCreateOptions, f as AdminProjectUpdateOptions, g as adminProjectCreateOptionsToCrud, h as PushedConfigSource, l as AdminOwnedProject, m as PushConfigOptions, p as Project, u as AdminProject } from "../../../client-app-oSumAWx3.js";
2
2
  export { AdminOwnedProject, AdminProject, AdminProjectCreateOptions, AdminProjectUpdateOptions, Project, PushConfigOptions, PushedConfigSource, adminProjectCreateOptionsToCrud, adminProjectUpdateOptionsToCrud };
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../../../src/lib/hexclave-app/projects/index.ts"],"sourcesContent":["\n//===========================================\n// THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY UNLESS YOU ALSO EDIT THE CORRESPONDING FILE IN packages/template\n//===========================================\nimport { ProductionModeError } from \"@hexclave/shared/dist/helpers/production-mode\";\nimport { AdminUserProjectsCrud, ProjectsCrud } from \"@hexclave/shared/dist/interface/crud/projects\";\nimport { ProjectOnboardingStatus } from \"@hexclave/shared/dist/schema-fields\";\n\nimport { CompleteConfig, EnvironmentConfigNormalizedOverride, EnvironmentConfigOverrideOverride } from \"@hexclave/shared/dist/config/schema\";\nimport { StackAdminApp } from \"../apps/interfaces/admin-app\";\nimport { AdminProjectConfig, AdminProjectConfigUpdateOptions, ProjectConfig } from \"../project-configs\";\n\n/**\n * SDK type for pushed config source (camelCase for SDK).\n * Represents where the branch config was pushed from.\n */\nexport type PushedConfigSource =\n | { type: \"pushed-from-github\", owner: string, repo: string, branch: string, commitHash: string, configFilePath: string, workflowPath?: string }\n | { type: \"pushed-from-unknown\" }\n | { type: \"unlinked\" };\n\nexport type PushConfigOptions = {\n /**\n * The source of this config push.\n */\n source: PushedConfigSource,\n};\n\n\nexport type Project = {\n readonly id: string,\n readonly displayName: string,\n readonly pushedConfigError: { message: string } | null,\n readonly configWarnings: { message: string }[],\n readonly config: ProjectConfig,\n};\n\nexport type AdminProject = {\n readonly id: string,\n readonly displayName: string,\n readonly description: string | null,\n readonly createdAt: Date,\n readonly isProductionMode: boolean,\n readonly isDevelopmentEnvironment: boolean,\n readonly ownerTeamId: string | null,\n readonly onboardingStatus: ProjectOnboardingStatus,\n readonly onboardingState: NonNullable<ProjectsCrud[\"Admin\"][\"Read\"][\"onboarding_state\"]> | null,\n readonly logoUrl: string | null | undefined,\n readonly logoFullUrl: string | null | undefined,\n readonly logoDarkModeUrl: string | null | undefined,\n readonly logoFullDarkModeUrl: string | null | undefined,\n\n readonly config: AdminProjectConfig,\n\n update(this: AdminProject, update: AdminProjectUpdateOptions): Promise<void>,\n delete(this: AdminProject): Promise<void>,\n\n getConfig(this: AdminProject): Promise<CompleteConfig>,\n useConfig(this: AdminProject): CompleteConfig,\n\n /**\n * Updates the environment's config by merging the provided config into the existing config.\n *\n * Changes made with `updateConfig` always take precedence over those made with `pushConfig`, even if the `pushConfig`\n * config was pushed after the changes were made with `updateConfig`. This is best for environment-specific\n * configuration like secrets, API keys, and other values that you wouldn't push into a source repository.\n */\n // We have some strict types here in order to prevent accidental overwriting of a top-level property of a config object\n updateConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride,\n ): Promise<void>,\n\n /**\n * Pushes a config, replacing any previous config pushed with `pushConfig`.\n *\n * **Note:** This function does **not** replace any changes made with `updateConfig`. Changes made with\n * `updateConfig` always take precedence over those made with `pushConfig`, even if the `pushConfig`\n * config was pushed after the changes were made with `updateConfig`.\n *\n * This is useful for programmatically deploying configuration. More often than not, you'll want to use\n * `updateConfig` instead.\n */\n pushConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride,\n options: PushConfigOptions,\n ): Promise<void>,\n\n /**\n * Updates the pushed config by merging the provided config into the existing pushed config.\n *\n * **Warning:** This is almost always **not** the function you want to call. Changes made with\n * `updatePushedConfig` will be replaced entirely the next time `pushConfig` is called. Consider using\n * `pushConfig` to set the full pushed config, or `updateConfig` for environment-specific values that\n * should persist across pushes.\n *\n * This function is useful for making temporary modifications to the pushed config before the next push.\n */\n updatePushedConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride\n ): Promise<void>,\n\n /**\n * Gets the source metadata for the pushed config, indicating where it was pushed from.\n *\n * The source can be:\n * - `pushed-from-github`: Config was pushed from a GitHub repository\n * - `pushed-from-unknown`: Config was pushed via CLI but source details unknown\n * - `unlinked`: Config can be edited directly on the dashboard\n */\n getPushedConfigSource(this: AdminProject): Promise<PushedConfigSource>,\n\n /**\n * Unlinks the pushed config source, setting it to \"unlinked\".\n * This allows the config to be edited directly on the dashboard without external push restrictions.\n */\n unlinkPushedConfigSource(this: AdminProject): Promise<void>,\n\n /**\n * Resets (removes) specific keys from the config override at the specified level.\n * Uses the same nested key logic as the override algorithm: resetting key \"a.b\" also resets \"a.b.c\".\n *\n * This is useful when updating the pushed config (branch level) and wanting to remove the same keys\n * from the environment config override so that the branch config values take precedence.\n */\n resetConfigOverrideKeys(this: AdminProject, level: \"branch\" | \"environment\", keys: string[]): Promise<void>,\n\n /**\n * Gets the raw config override at the specified level (before merging/defaults).\n * Useful for inspecting exactly what's been set at each level.\n */\n getConfigOverride(this: AdminProject, level: \"branch\" | \"environment\"): Promise<Record<string, unknown>>,\n\n /**\n * Replaces the entire config override at the specified level.\n * For branch level, preserves the existing source metadata.\n */\n replaceConfigOverride(this: AdminProject, level: \"branch\" | \"environment\", config: Record<string, unknown>): Promise<void>,\n\n getProductionModeErrors(this: AdminProject): Promise<ProductionModeError[]>,\n useProductionModeErrors(this: AdminProject): ProductionModeError[],\n} & Project;\n\nexport type AdminOwnedProject = {\n readonly app: StackAdminApp<false>,\n} & AdminProject;\n\nexport type AdminProjectUpdateOptions = {\n displayName?: string,\n description?: string,\n isProductionMode?: boolean,\n onboardingStatus?: ProjectOnboardingStatus,\n /**\n * Updates `project.requirePublishableClientKey` in the project-level config override.\n */\n requirePublishableClientKey?: boolean,\n logoUrl?: string | null,\n logoFullUrl?: string | null,\n logoDarkModeUrl?: string | null,\n logoFullDarkModeUrl?: string | null,\n config?: AdminProjectConfigUpdateOptions,\n};\nexport function adminProjectUpdateOptionsToCrud(options: AdminProjectUpdateOptions): ProjectsCrud[\"Admin\"][\"Update\"] {\n return {\n display_name: options.displayName,\n description: options.description,\n is_production_mode: options.isProductionMode,\n onboarding_status: options.onboardingStatus,\n logo_url: options.logoUrl,\n logo_full_url: options.logoFullUrl,\n logo_dark_mode_url: options.logoDarkModeUrl,\n logo_full_dark_mode_url: options.logoFullDarkModeUrl,\n /**\n * NOTE: Do not update this config anymore. It's been superseded by the new config in schema.ts.\n * @deprecated\n */\n config: {\n domains: options.config?.domains?.map((d) => ({\n domain: d.domain,\n handler_path: d.handlerPath\n })),\n oauth_providers: options.config?.oauthProviders\n ?.filter((p): p is Exclude<typeof p, { type: 'custom_oidc' }> => p.type !== 'custom_oidc')\n .map((p) => ({\n id: p.id as any,\n type: p.type,\n ...(p.type === 'standard' && {\n client_id: p.clientId,\n client_secret: p.clientSecret,\n facebook_config_id: p.facebookConfigId,\n microsoft_tenant_id: p.microsoftTenantId,\n apple_bundle_ids: p.appleBundleIds,\n }),\n })),\n email_config: options.config?.emailConfig && (\n options.config.emailConfig.type === 'shared' ? {\n type: 'shared',\n } : {\n type: 'standard',\n host: options.config.emailConfig.host,\n port: options.config.emailConfig.port,\n username: options.config.emailConfig.username,\n password: options.config.emailConfig.password,\n sender_name: options.config.emailConfig.senderName,\n sender_email: options.config.emailConfig.senderEmail,\n }\n ),\n email_theme: options.config?.emailTheme,\n sign_up_enabled: options.config?.signUpEnabled,\n credential_enabled: options.config?.credentialEnabled,\n magic_link_enabled: options.config?.magicLinkEnabled,\n passkey_enabled: options.config?.passkeyEnabled,\n allow_localhost: options.config?.allowLocalhost,\n create_team_on_sign_up: options.config?.createTeamOnSignUp,\n client_team_creation_enabled: options.config?.clientTeamCreationEnabled,\n client_user_deletion_enabled: options.config?.clientUserDeletionEnabled,\n team_creator_default_permissions: options.config?.teamCreatorDefaultPermissions,\n team_member_default_permissions: options.config?.teamMemberDefaultPermissions,\n user_default_permissions: options.config?.userDefaultPermissions,\n oauth_account_merge_strategy: options.config?.oauthAccountMergeStrategy,\n allow_user_api_keys: options.config?.allowUserApiKeys,\n allow_team_api_keys: options.config?.allowTeamApiKeys,\n },\n };\n}\n\nexport type AdminProjectCreateOptions = Omit<AdminProjectUpdateOptions, 'displayName'> & {\n displayName: string,\n teamId: string,\n isDevelopmentEnvironment?: boolean,\n};\nexport function adminProjectCreateOptionsToCrud(options: AdminProjectCreateOptions): AdminUserProjectsCrud[\"Server\"][\"Create\"] {\n return {\n ...adminProjectUpdateOptionsToCrud(options),\n display_name: options.displayName,\n is_development_environment: options.isDevelopmentEnvironment,\n owner_team_id: options.teamId,\n };\n}\n"],"mappings":";;AAoKA,SAAgB,gCAAgC,SAAqE;CACnH,OAAO;EACL,cAAc,QAAQ;EACtB,aAAa,QAAQ;EACrB,oBAAoB,QAAQ;EAC5B,mBAAmB,QAAQ;EAC3B,UAAU,QAAQ;EAClB,eAAe,QAAQ;EACvB,oBAAoB,QAAQ;EAC5B,yBAAyB,QAAQ;;;;;EAKjC,QAAQ;GACN,SAAS,QAAQ,QAAQ,SAAS,KAAK,OAAO;IAC5C,QAAQ,EAAE;IACV,cAAc,EAAE;GAClB,EAAE;GACF,iBAAiB,QAAQ,QAAQ,gBAC7B,QAAQ,MAAuD,EAAE,SAAS,aAAa,CAAC,CACzF,KAAK,OAAO;IACX,IAAI,EAAE;IACN,MAAM,EAAE;IACR,GAAI,EAAE,SAAS,cAAc;KAC3B,WAAW,EAAE;KACb,eAAe,EAAE;KACjB,oBAAoB,EAAE;KACtB,qBAAqB,EAAE;KACvB,kBAAkB,EAAE;IACtB;GACF,EAAE;GACJ,cAAc,QAAQ,QAAQ,gBAC5B,QAAQ,OAAO,YAAY,SAAS,WAAW,EAC7C,MAAM,SACR,IAAI;IACF,MAAM;IACN,MAAM,QAAQ,OAAO,YAAY;IACjC,MAAM,QAAQ,OAAO,YAAY;IACjC,UAAU,QAAQ,OAAO,YAAY;IACrC,UAAU,QAAQ,OAAO,YAAY;IACrC,aAAa,QAAQ,OAAO,YAAY;IACxC,cAAc,QAAQ,OAAO,YAAY;GAC3C;GAEF,aAAa,QAAQ,QAAQ;GAC7B,iBAAiB,QAAQ,QAAQ;GACjC,oBAAoB,QAAQ,QAAQ;GACpC,oBAAoB,QAAQ,QAAQ;GACpC,iBAAiB,QAAQ,QAAQ;GACjC,iBAAiB,QAAQ,QAAQ;GACjC,wBAAwB,QAAQ,QAAQ;GACxC,8BAA8B,QAAQ,QAAQ;GAC9C,8BAA8B,QAAQ,QAAQ;GAC9C,kCAAkC,QAAQ,QAAQ;GAClD,iCAAiC,QAAQ,QAAQ;GACjD,0BAA0B,QAAQ,QAAQ;GAC1C,8BAA8B,QAAQ,QAAQ;GAC9C,qBAAqB,QAAQ,QAAQ;GACrC,qBAAqB,QAAQ,QAAQ;EACvC;CACF;AACF;AAOA,SAAgB,gCAAgC,SAA+E;CAC7H,OAAO;EACL,GAAG,gCAAgC,OAAO;EAC1C,cAAc,QAAQ;EACtB,4BAA4B,QAAQ;EACpC,eAAe,QAAQ;CACzB;AACF"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../../../src/lib/hexclave-app/projects/index.ts"],"sourcesContent":["\n//===========================================\n// THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY UNLESS YOU ALSO EDIT THE CORRESPONDING FILE IN packages/template\n//===========================================\nimport { ProductionModeError } from \"@hexclave/shared/dist/helpers/production-mode\";\nimport { AdminUserProjectsCrud, ProjectsCrud } from \"@hexclave/shared/dist/interface/crud/projects\";\nimport { ProjectOnboardingStatus } from \"@hexclave/shared/dist/schema-fields\";\n\nimport { CompleteConfig, EnvironmentConfigNormalizedOverride, EnvironmentConfigOverrideOverride } from \"@hexclave/shared/dist/config/schema\";\nimport { StackAdminApp } from \"../apps/interfaces/admin-app\";\nimport { AdminProjectConfig, AdminProjectConfigUpdateOptions, ProjectConfig } from \"../project-configs\";\n\n/**\n * SDK type for pushed config source (camelCase for SDK).\n * Represents where the branch config was pushed from.\n */\nexport type PushedConfigSource =\n | { type: \"pushed-from-github\", owner: string, repo: string, branch: string, commitHash: string, configFilePath: string, workflowPath?: string }\n | { type: \"pushed-from-unknown\" }\n | { type: \"unlinked\" };\n\nexport type PushConfigOptions = {\n /**\n * The source of this config push.\n */\n source: PushedConfigSource,\n};\n\n\nexport type Project = {\n readonly id: string,\n readonly displayName: string,\n readonly isDevelopmentEnvironment: boolean,\n readonly pushedConfigError: { message: string } | null,\n readonly configWarnings: { message: string }[],\n readonly config: ProjectConfig,\n};\n\nexport type AdminProject = {\n readonly id: string,\n readonly displayName: string,\n readonly description: string | null,\n readonly createdAt: Date,\n readonly isProductionMode: boolean,\n readonly isDevelopmentEnvironment: boolean,\n readonly ownerTeamId: string | null,\n readonly onboardingStatus: ProjectOnboardingStatus,\n readonly onboardingState: NonNullable<ProjectsCrud[\"Admin\"][\"Read\"][\"onboarding_state\"]> | null,\n readonly logoUrl: string | null | undefined,\n readonly logoFullUrl: string | null | undefined,\n readonly logoDarkModeUrl: string | null | undefined,\n readonly logoFullDarkModeUrl: string | null | undefined,\n\n readonly config: AdminProjectConfig,\n\n update(this: AdminProject, update: AdminProjectUpdateOptions): Promise<void>,\n delete(this: AdminProject): Promise<void>,\n\n getConfig(this: AdminProject): Promise<CompleteConfig>,\n useConfig(this: AdminProject): CompleteConfig,\n\n /**\n * Updates the environment's config by merging the provided config into the existing config.\n *\n * Changes made with `updateConfig` always take precedence over those made with `pushConfig`, even if the `pushConfig`\n * config was pushed after the changes were made with `updateConfig`. This is best for environment-specific\n * configuration like secrets, API keys, and other values that you wouldn't push into a source repository.\n */\n // We have some strict types here in order to prevent accidental overwriting of a top-level property of a config object\n updateConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride,\n ): Promise<void>,\n\n /**\n * Pushes a config, replacing any previous config pushed with `pushConfig`.\n *\n * **Note:** This function does **not** replace any changes made with `updateConfig`. Changes made with\n * `updateConfig` always take precedence over those made with `pushConfig`, even if the `pushConfig`\n * config was pushed after the changes were made with `updateConfig`.\n *\n * This is useful for programmatically deploying configuration. More often than not, you'll want to use\n * `updateConfig` instead.\n */\n pushConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride,\n options: PushConfigOptions,\n ): Promise<void>,\n\n /**\n * Updates the pushed config by merging the provided config into the existing pushed config.\n *\n * **Warning:** This is almost always **not** the function you want to call. Changes made with\n * `updatePushedConfig` will be replaced entirely the next time `pushConfig` is called. Consider using\n * `pushConfig` to set the full pushed config, or `updateConfig` for environment-specific values that\n * should persist across pushes.\n *\n * This function is useful for making temporary modifications to the pushed config before the next push.\n */\n updatePushedConfig(\n this: AdminProject,\n config: EnvironmentConfigOverrideOverride\n ): Promise<void>,\n\n /**\n * Gets the source metadata for the pushed config, indicating where it was pushed from.\n *\n * The source can be:\n * - `pushed-from-github`: Config was pushed from a GitHub repository\n * - `pushed-from-unknown`: Config was pushed via CLI but source details unknown\n * - `unlinked`: Config can be edited directly on the dashboard\n */\n getPushedConfigSource(this: AdminProject): Promise<PushedConfigSource>,\n\n /**\n * Unlinks the pushed config source, setting it to \"unlinked\".\n * This allows the config to be edited directly on the dashboard without external push restrictions.\n */\n unlinkPushedConfigSource(this: AdminProject): Promise<void>,\n\n /**\n * Resets (removes) specific keys from the config override at the specified level.\n * Uses the same nested key logic as the override algorithm: resetting key \"a.b\" also resets \"a.b.c\".\n *\n * This is useful when updating the pushed config (branch level) and wanting to remove the same keys\n * from the environment config override so that the branch config values take precedence.\n */\n resetConfigOverrideKeys(this: AdminProject, level: \"branch\" | \"environment\", keys: string[]): Promise<void>,\n\n /**\n * Gets the raw config override at the specified level (before merging/defaults).\n * Useful for inspecting exactly what's been set at each level.\n */\n getConfigOverride(this: AdminProject, level: \"branch\" | \"environment\"): Promise<Record<string, unknown>>,\n\n /**\n * Replaces the entire config override at the specified level.\n * For branch level, preserves the existing source metadata.\n */\n replaceConfigOverride(this: AdminProject, level: \"branch\" | \"environment\", config: Record<string, unknown>): Promise<void>,\n\n getProductionModeErrors(this: AdminProject): Promise<ProductionModeError[]>,\n useProductionModeErrors(this: AdminProject): ProductionModeError[],\n} & Project;\n\nexport type AdminOwnedProject = {\n readonly app: StackAdminApp<false>,\n} & AdminProject;\n\nexport type AdminProjectUpdateOptions = {\n displayName?: string,\n description?: string,\n isProductionMode?: boolean,\n onboardingStatus?: ProjectOnboardingStatus,\n /**\n * Updates `project.requirePublishableClientKey` in the project-level config override.\n */\n requirePublishableClientKey?: boolean,\n logoUrl?: string | null,\n logoFullUrl?: string | null,\n logoDarkModeUrl?: string | null,\n logoFullDarkModeUrl?: string | null,\n config?: AdminProjectConfigUpdateOptions,\n};\nexport function adminProjectUpdateOptionsToCrud(options: AdminProjectUpdateOptions): ProjectsCrud[\"Admin\"][\"Update\"] {\n return {\n display_name: options.displayName,\n description: options.description,\n is_production_mode: options.isProductionMode,\n onboarding_status: options.onboardingStatus,\n logo_url: options.logoUrl,\n logo_full_url: options.logoFullUrl,\n logo_dark_mode_url: options.logoDarkModeUrl,\n logo_full_dark_mode_url: options.logoFullDarkModeUrl,\n /**\n * NOTE: Do not update this config anymore. It's been superseded by the new config in schema.ts.\n * @deprecated\n */\n config: {\n domains: options.config?.domains?.map((d) => ({\n domain: d.domain,\n handler_path: d.handlerPath\n })),\n oauth_providers: options.config?.oauthProviders\n ?.filter((p): p is Exclude<typeof p, { type: 'custom_oidc' }> => p.type !== 'custom_oidc')\n .map((p) => ({\n id: p.id as any,\n type: p.type,\n ...(p.type === 'standard' && {\n client_id: p.clientId,\n client_secret: p.clientSecret,\n facebook_config_id: p.facebookConfigId,\n microsoft_tenant_id: p.microsoftTenantId,\n apple_bundle_ids: p.appleBundleIds,\n }),\n })),\n email_config: options.config?.emailConfig && (\n options.config.emailConfig.type === 'shared' ? {\n type: 'shared',\n } : {\n type: 'standard',\n host: options.config.emailConfig.host,\n port: options.config.emailConfig.port,\n username: options.config.emailConfig.username,\n password: options.config.emailConfig.password,\n sender_name: options.config.emailConfig.senderName,\n sender_email: options.config.emailConfig.senderEmail,\n }\n ),\n email_theme: options.config?.emailTheme,\n sign_up_enabled: options.config?.signUpEnabled,\n credential_enabled: options.config?.credentialEnabled,\n magic_link_enabled: options.config?.magicLinkEnabled,\n passkey_enabled: options.config?.passkeyEnabled,\n allow_localhost: options.config?.allowLocalhost,\n create_team_on_sign_up: options.config?.createTeamOnSignUp,\n client_team_creation_enabled: options.config?.clientTeamCreationEnabled,\n client_user_deletion_enabled: options.config?.clientUserDeletionEnabled,\n team_creator_default_permissions: options.config?.teamCreatorDefaultPermissions,\n team_member_default_permissions: options.config?.teamMemberDefaultPermissions,\n user_default_permissions: options.config?.userDefaultPermissions,\n oauth_account_merge_strategy: options.config?.oauthAccountMergeStrategy,\n allow_user_api_keys: options.config?.allowUserApiKeys,\n allow_team_api_keys: options.config?.allowTeamApiKeys,\n },\n };\n}\n\nexport type AdminProjectCreateOptions = Omit<AdminProjectUpdateOptions, 'displayName'> & {\n displayName: string,\n teamId: string,\n isDevelopmentEnvironment?: boolean,\n};\nexport function adminProjectCreateOptionsToCrud(options: AdminProjectCreateOptions): AdminUserProjectsCrud[\"Server\"][\"Create\"] {\n return {\n ...adminProjectUpdateOptionsToCrud(options),\n display_name: options.displayName,\n is_development_environment: options.isDevelopmentEnvironment,\n owner_team_id: options.teamId,\n };\n}\n"],"mappings":";;AAqKA,SAAgB,gCAAgC,SAAqE;CACnH,OAAO;EACL,cAAc,QAAQ;EACtB,aAAa,QAAQ;EACrB,oBAAoB,QAAQ;EAC5B,mBAAmB,QAAQ;EAC3B,UAAU,QAAQ;EAClB,eAAe,QAAQ;EACvB,oBAAoB,QAAQ;EAC5B,yBAAyB,QAAQ;;;;;EAKjC,QAAQ;GACN,SAAS,QAAQ,QAAQ,SAAS,KAAK,OAAO;IAC5C,QAAQ,EAAE;IACV,cAAc,EAAE;GAClB,EAAE;GACF,iBAAiB,QAAQ,QAAQ,gBAC7B,QAAQ,MAAuD,EAAE,SAAS,aAAa,CAAC,CACzF,KAAK,OAAO;IACX,IAAI,EAAE;IACN,MAAM,EAAE;IACR,GAAI,EAAE,SAAS,cAAc;KAC3B,WAAW,EAAE;KACb,eAAe,EAAE;KACjB,oBAAoB,EAAE;KACtB,qBAAqB,EAAE;KACvB,kBAAkB,EAAE;IACtB;GACF,EAAE;GACJ,cAAc,QAAQ,QAAQ,gBAC5B,QAAQ,OAAO,YAAY,SAAS,WAAW,EAC7C,MAAM,SACR,IAAI;IACF,MAAM;IACN,MAAM,QAAQ,OAAO,YAAY;IACjC,MAAM,QAAQ,OAAO,YAAY;IACjC,UAAU,QAAQ,OAAO,YAAY;IACrC,UAAU,QAAQ,OAAO,YAAY;IACrC,aAAa,QAAQ,OAAO,YAAY;IACxC,cAAc,QAAQ,OAAO,YAAY;GAC3C;GAEF,aAAa,QAAQ,QAAQ;GAC7B,iBAAiB,QAAQ,QAAQ;GACjC,oBAAoB,QAAQ,QAAQ;GACpC,oBAAoB,QAAQ,QAAQ;GACpC,iBAAiB,QAAQ,QAAQ;GACjC,iBAAiB,QAAQ,QAAQ;GACjC,wBAAwB,QAAQ,QAAQ;GACxC,8BAA8B,QAAQ,QAAQ;GAC9C,8BAA8B,QAAQ,QAAQ;GAC9C,kCAAkC,QAAQ,QAAQ;GAClD,iCAAiC,QAAQ,QAAQ;GACjD,0BAA0B,QAAQ,QAAQ;GAC1C,8BAA8B,QAAQ,QAAQ;GAC9C,qBAAqB,QAAQ,QAAQ;GACrC,qBAAqB,QAAQ,QAAQ;EACvC;CACF;AACF;AAOA,SAAgB,gCAAgC,SAA+E;CAC7H,OAAO;EACL,GAAG,gCAAgC,OAAO;EAC1C,cAAc,QAAQ;EACtB,4BAA4B,QAAQ;EACpC,eAAe,QAAQ;CACzB;AACF"}
@@ -1,2 +1,2 @@
1
- import { $ as serverTeamCreateOptionsToCrud, B as ServerListUsersOptions, G as ServerTeamUser, H as ServerTeamCreateOptions, I as EditableTeamMemberProfile, J as TeamInvitation, K as Team, L as ReceivedTeamInvitation, Q as TeamUser, R as SentTeamInvitation, U as ServerTeamMemberProfile, V as ServerTeam, W as ServerTeamUpdateOptions, X as TeamMemberProfileUpdateOptions, Y as TeamMemberProfile, Z as TeamUpdateOptions, et as serverTeamUpdateOptionsToCrud, nt as teamUpdateOptionsToCrud, q as TeamCreateOptions, tt as teamCreateOptionsToCrud, z as ServerListTeamsOptions } from "../../../client-app-B0kBC67Z.js";
1
+ import { $ as serverTeamCreateOptionsToCrud, B as ServerListUsersOptions, G as ServerTeamUser, H as ServerTeamCreateOptions, I as EditableTeamMemberProfile, J as TeamInvitation, K as Team, L as ReceivedTeamInvitation, Q as TeamUser, R as SentTeamInvitation, U as ServerTeamMemberProfile, V as ServerTeam, W as ServerTeamUpdateOptions, X as TeamMemberProfileUpdateOptions, Y as TeamMemberProfile, Z as TeamUpdateOptions, et as serverTeamUpdateOptionsToCrud, nt as teamUpdateOptionsToCrud, q as TeamCreateOptions, tt as teamCreateOptionsToCrud, z as ServerListTeamsOptions } from "../../../client-app-oSumAWx3.js";
2
2
  export { EditableTeamMemberProfile, ReceivedTeamInvitation, SentTeamInvitation, ServerListTeamsOptions, ServerListUsersOptions, ServerTeam, ServerTeamCreateOptions, ServerTeamMemberProfile, ServerTeamUpdateOptions, ServerTeamUser, Team, TeamCreateOptions, TeamInvitation, TeamMemberProfile, TeamMemberProfileUpdateOptions, TeamUpdateOptions, TeamUser, serverTeamCreateOptionsToCrud, serverTeamUpdateOptionsToCrud, teamCreateOptionsToCrud, teamUpdateOptionsToCrud };
@@ -1,2 +1,2 @@
1
- import { Ct as UserExtra, Dt as userUpdateOptionsToCrud, Et as serverUserUpdateOptionsToCrud, Ot as withUserDestructureGuard, St as User, Tt as serverUserCreateOptionsToCrud, _t as ServerUserCreateOptions, at as BaseUser, bt as SyncedPartialUser, ct as CurrentServerUser, dt as OAuthProvider, ft as ProjectCurrentServerUser, gt as ServerUser, ht as ServerOAuthProvider, it as Auth, lt as CurrentUser, mt as ServerBaseUser, ot as CurrentInternalServerUser, pt as ProjectCurrentUser, rt as ActiveSession, st as CurrentInternalUser, ut as InternalUserExtra, vt as ServerUserUpdateOptions, wt as UserUpdateOptions, xt as TokenPartialUser, yt as SyncedPartialServerUser } from "../../../client-app-B0kBC67Z.js";
1
+ import { Ct as UserExtra, Dt as userUpdateOptionsToCrud, Et as serverUserUpdateOptionsToCrud, Ot as withUserDestructureGuard, St as User, Tt as serverUserCreateOptionsToCrud, _t as ServerUserCreateOptions, at as BaseUser, bt as SyncedPartialUser, ct as CurrentServerUser, dt as OAuthProvider, ft as ProjectCurrentServerUser, gt as ServerUser, ht as ServerOAuthProvider, it as Auth, lt as CurrentUser, mt as ServerBaseUser, ot as CurrentInternalServerUser, pt as ProjectCurrentUser, rt as ActiveSession, st as CurrentInternalUser, ut as InternalUserExtra, vt as ServerUserUpdateOptions, wt as UserUpdateOptions, xt as TokenPartialUser, yt as SyncedPartialServerUser } from "../../../client-app-oSumAWx3.js";
2
2
  export { ActiveSession, Auth, BaseUser, CurrentInternalServerUser, CurrentInternalUser, CurrentServerUser, CurrentUser, InternalUserExtra, OAuthProvider, ProjectCurrentServerUser, ProjectCurrentUser, ServerBaseUser, ServerOAuthProvider, ServerUser, ServerUserCreateOptions, ServerUserUpdateOptions, SyncedPartialServerUser, SyncedPartialUser, TokenPartialUser, User, UserExtra, UserUpdateOptions, serverUserCreateOptionsToCrud, serverUserUpdateOptionsToCrud, userUpdateOptionsToCrud, withUserDestructureGuard };
@@ -1,2 +1,2 @@
1
- import { n as useStackApp, r as useUser, t as useHexclaveApp } from "../hooks-ykQ7Wsco.js";
1
+ import { n as useStackApp, r as useUser, t as useHexclaveApp } from "../hooks-Ds3yoNo-.js";
2
2
  export { useHexclaveApp, useStackApp, useUser };
@@ -1,4 +1,4 @@
1
- import { a as StackClientApp } from "../client-app-B0kBC67Z.js";
1
+ import { a as StackClientApp } from "../client-app-oSumAWx3.js";
2
2
  import React from "react";
3
3
 
4
4
  //#region src/providers/hexclave-context.d.ts
@@ -1,4 +1,4 @@
1
- import { a as StackClientApp, c as StackClientAppJson } from "../client-app-B0kBC67Z.js";
1
+ import { a as StackClientApp, c as StackClientAppJson } from "../client-app-oSumAWx3.js";
2
2
  import { CurrentUserCrud } from "@hexclave/shared/dist/interface/crud/current-user";
3
3
  import React from "react";
4
4
 
@@ -1,2 +1,2 @@
1
- import { n as HexclaveProvider, r as StackProvider, t as ActiveProvider } from "../hexclave-provider-BQ9wrtBt.js";
1
+ import { n as HexclaveProvider, r as StackProvider, t as ActiveProvider } from "../hexclave-provider-DnIE6JQ7.js";
2
2
  export { HexclaveProvider, StackProvider, ActiveProvider as default };
@@ -1,4 +1,4 @@
1
- import { a as StackClientApp } from "../client-app-B0kBC67Z.js";
1
+ import { a as StackClientApp } from "../client-app-oSumAWx3.js";
2
2
  //#region src/pushed-config-error-overlay/index.d.ts
3
3
  declare function mountPushedConfigErrorOverlay(app: StackClientApp<true>): () => void;
4
4
  //#endregion
@@ -1,7 +1,7 @@
1
1
  let vitest = require("vitest");
2
2
  let ___lib_hexclave_app_index_js = require("../lib/hexclave-app/index.js");
3
- let ___generated_env_js = require("../generated/env.js");
4
3
  let __index_js = require("./index.js");
4
+ let ___generated_env_js = require("../generated/env.js");
5
5
  //#region src/pushed-config-error-overlay/index.test.ts
6
6
  function createMockElement() {
7
7
  return {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "//": "THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY UNLESS YOU ALSO EDIT THE CORRESPONDING FILE IN packages/template (FOR package.json FILES, PLEASE EDIT package-template.json)",
3
3
  "name": "@hexclave/next",
4
- "version": "1.0.55",
4
+ "version": "1.0.57",
5
5
  "repository": "https://github.com/hexclave/hexclave",
6
6
  "sideEffects": false,
7
7
  "main": "./dist/index.js",
@@ -74,9 +74,9 @@
74
74
  "tailwindcss-animate": "^1.0.7",
75
75
  "rrweb": "^1.1.3",
76
76
  "yup": "^1.7.1",
77
- "@hexclave/sc": "1.0.55",
78
- "@hexclave/ui": "1.0.55",
79
- "@hexclave/shared": "1.0.55"
77
+ "@hexclave/sc": "1.0.57",
78
+ "@hexclave/ui": "1.0.57",
79
+ "@hexclave/shared": "1.0.57"
80
80
  },
81
81
  "peerDependencies": {
82
82
  "@types/react": ">=18.0.0",
@@ -0,0 +1,58 @@
1
+
2
+ //===========================================
3
+ // THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY UNLESS YOU ALSO EDIT THE CORRESPONDING FILE IN packages/template
4
+ //===========================================
5
+ import { afterEach, describe, expect, it, vi } from "vitest";
6
+ import { StackClientApp } from "../lib/hexclave-app";
7
+ import { createDevTool } from "./dev-tool-core";
8
+ import { mountDevTool } from ".";
9
+
10
+ vi.mock("./dev-tool-core", () => ({
11
+ createDevTool: vi.fn(() => () => {}),
12
+ }));
13
+
14
+ describe("dev tool visibility", () => {
15
+ afterEach(() => {
16
+ vi.unstubAllEnvs();
17
+ vi.unstubAllGlobals();
18
+ vi.clearAllMocks();
19
+ });
20
+
21
+ it("shows for a development environment project in a production-hosted app", async () => {
22
+ const app = new StackClientApp({
23
+ baseUrl: "https://api.example.com",
24
+ projectId: "00000000-0000-4000-8000-000000000000",
25
+ publishableClientKey: "stack-pk-test",
26
+ tokenStore: "memory",
27
+ redirectMethod: "none",
28
+ devTool: false,
29
+ });
30
+ const getProject = vi.fn(async () => ({
31
+ isDevelopmentEnvironment: true,
32
+ }));
33
+ Reflect.set(app, "getProject", getProject);
34
+
35
+ vi.stubEnv("NODE_ENV", "production");
36
+ vi.stubGlobal("window", {
37
+ location: {
38
+ href: "https://example.com",
39
+ },
40
+ });
41
+ vi.stubGlobal("document", {
42
+ body: {
43
+ appendChild: () => {},
44
+ },
45
+ createElement: () => ({}),
46
+ });
47
+ vi.stubGlobal("localStorage", {
48
+ getItem: () => null,
49
+ });
50
+
51
+ mountDevTool(app);
52
+
53
+ await vi.waitFor(() => {
54
+ expect(getProject).toHaveBeenCalledOnce();
55
+ expect(createDevTool).toHaveBeenCalledOnce();
56
+ });
57
+ });
58
+ });
@@ -24,6 +24,7 @@ function getOverride(): boolean | null {
24
24
  }
25
25
 
26
26
  let activeDevToolOption: true | "auto" | undefined = undefined;
27
+ let activeProjectIsDevelopmentEnvironment = false;
27
28
 
28
29
  function shouldShow(): boolean {
29
30
  const override = getOverride();
@@ -33,6 +34,10 @@ function shouldShow(): boolean {
33
34
  // If devTool was explicitly set to true, always show
34
35
  if (activeDevToolOption === true) return true;
35
36
 
37
+ // Development environment projects should expose the tool even when the
38
+ // consuming app itself was built or hosted as production.
39
+ if (activeProjectIsDevelopmentEnvironment) return true;
40
+
36
41
  // "auto" behavior (the default):
37
42
  const nodeEnv = envVars.NODE_ENV;
38
43
  if (nodeEnv !== undefined) {
@@ -103,8 +108,28 @@ function tryMount() {
103
108
  export function mountDevTool(app: StackClientApp<true>, devToolOption?: boolean | "auto"): () => void {
104
109
  activeApp = app;
105
110
  activeDevToolOption = devToolOption === false ? undefined : devToolOption ?? undefined;
111
+ activeProjectIsDevelopmentEnvironment = false;
106
112
  tryMount();
107
113
 
114
+ // The project endpoint is also the source of config warnings, so this uses
115
+ // the backend's development-environment flag instead of inferring it from
116
+ // the SDK's build or the current page's origin.
117
+ queueMicrotask(() => {
118
+ runAsynchronously(async () => {
119
+ const project = await app.getProject();
120
+ if (activeApp !== app) return;
121
+ activeProjectIsDevelopmentEnvironment = project.isDevelopmentEnvironment;
122
+ if (activeProjectIsDevelopmentEnvironment && activeCleanup === null) {
123
+ tryMount();
124
+ }
125
+ }, {
126
+ noErrorLogging: true,
127
+ onError: (error) => {
128
+ captureError("dev-tool-project-detection", error);
129
+ },
130
+ });
131
+ });
132
+
108
133
  // Capture the cleanup created by THIS specific mount call so that React
109
134
  // StrictMode's double-invoke doesn't let the first effect's cleanup tear
110
135
  // down the second mount (which would cause the tool to disappear silently).
@@ -112,6 +137,7 @@ export function mountDevTool(app: StackClientApp<true>, devToolOption?: boolean
112
137
 
113
138
  return () => {
114
139
  activeApp = null;
140
+ activeProjectIsDevelopmentEnvironment = false;
115
141
  if (activeCleanup === myCleanup && myCleanup != null) {
116
142
  activeCleanup = null;
117
143
  myCleanup();
@@ -150,7 +176,7 @@ if (typeof window !== 'undefined') {
150
176
  activeCleanup();
151
177
  activeCleanup = null;
152
178
  }
153
- console.log('[Stack DevTool] Reset to default (auto-detect based on NODE_ENV or localhost/file: origin).');
179
+ console.log('[Stack DevTool] Reset to default (auto-detect based on project, NODE_ENV, or localhost/file: origin).');
154
180
  },
155
181
  };
156
182
  }
@@ -1638,6 +1638,7 @@ export class _HexclaveClientAppImplIncomplete<HasTokenStore extends boolean, Pro
1638
1638
  return {
1639
1639
  id: crud.id,
1640
1640
  displayName: crud.display_name,
1641
+ isDevelopmentEnvironment: crud.is_development_environment,
1641
1642
  pushedConfigError: crud.pushed_config_error == null ? null : {
1642
1643
  message: crud.pushed_config_error.message,
1643
1644
  },
@@ -30,6 +30,7 @@ export type PushConfigOptions = {
30
30
  export type Project = {
31
31
  readonly id: string,
32
32
  readonly displayName: string,
33
+ readonly isDevelopmentEnvironment: boolean,
33
34
  readonly pushedConfigError: { message: string } | null,
34
35
  readonly configWarnings: { message: string }[],
35
36
  readonly config: ProjectConfig,