@hexclave/shared 1.0.0
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/LICENSE +7 -0
- package/dist/ai/image-limits.d.ts +24 -0
- package/dist/ai/image-limits.d.ts.map +1 -0
- package/dist/ai/image-limits.js +61 -0
- package/dist/ai/image-limits.js.map +1 -0
- package/dist/ai/unified-prompts/reminders.d.ts +5 -0
- package/dist/ai/unified-prompts/reminders.d.ts.map +1 -0
- package/dist/ai/unified-prompts/reminders.js +33 -0
- package/dist/ai/unified-prompts/reminders.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts +11 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +851 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/brain.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/brain.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/brain.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/brain.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/cli-help.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/cli-help.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/cli-help.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/cli-help.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/config-docs.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/config-docs.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/config-docs.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/config-docs.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-index.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-index.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-index.js +64 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-index.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.js +12 -0
- package/dist/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.js.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt.d.ts +5 -0
- package/dist/ai/unified-prompts/skill-site-prompt.d.ts.map +1 -0
- package/dist/ai/unified-prompts/skill-site-prompt.js +75 -0
- package/dist/ai/unified-prompts/skill-site-prompt.js.map +1 -0
- package/dist/apps/apps-config.d.ts +168 -0
- package/dist/apps/apps-config.d.ts.map +1 -0
- package/dist/apps/apps-config.js +157 -0
- package/dist/apps/apps-config.js.map +1 -0
- package/dist/apps/apps-ui.d.ts +45 -0
- package/dist/apps/apps-ui.d.ts.map +1 -0
- package/dist/apps/apps-ui.js +109 -0
- package/dist/apps/apps-ui.js.map +1 -0
- package/dist/chunk-BE-pF4vm.js +34 -0
- package/dist/config/db-sync-mappings.d.ts +193 -0
- package/dist/config/db-sync-mappings.d.ts.map +1 -0
- package/dist/config/db-sync-mappings.js +2255 -0
- package/dist/config/db-sync-mappings.js.map +1 -0
- package/dist/config/format.d.ts +61 -0
- package/dist/config/format.d.ts.map +1 -0
- package/dist/config/format.js +337 -0
- package/dist/config/format.js.map +1 -0
- package/dist/config/migrate-catalogs-to-product-lines.d.ts +14 -0
- package/dist/config/migrate-catalogs-to-product-lines.d.ts.map +1 -0
- package/dist/config/migrate-catalogs-to-product-lines.js +379 -0
- package/dist/config/migrate-catalogs-to-product-lines.js.map +1 -0
- package/dist/config/schema-fuzzer.test.d.ts +1 -0
- package/dist/config/schema-fuzzer.test.js +401 -0
- package/dist/config/schema-fuzzer.test.js.map +1 -0
- package/dist/config/schema.d.ts +2315 -0
- package/dist/config/schema.d.ts.map +1 -0
- package/dist/config/schema.js +1085 -0
- package/dist/config/schema.js.map +1 -0
- package/dist/config-authoring.d.ts +12 -0
- package/dist/config-authoring.d.ts.map +1 -0
- package/dist/config-authoring.js +12 -0
- package/dist/config-authoring.js.map +1 -0
- package/dist/config-authoring.test.d.ts +1 -0
- package/dist/config-authoring.test.js +29 -0
- package/dist/config-authoring.test.js.map +1 -0
- package/dist/config-rendering.d.ts +17 -0
- package/dist/config-rendering.d.ts.map +1 -0
- package/dist/config-rendering.js +114 -0
- package/dist/config-rendering.js.map +1 -0
- package/dist/crud.d.ts +98 -0
- package/dist/crud.d.ts.map +1 -0
- package/dist/crud.js +129 -0
- package/dist/crud.js.map +1 -0
- package/dist/esm/ai/image-limits.d.ts +24 -0
- package/dist/esm/ai/image-limits.d.ts.map +1 -0
- package/dist/esm/ai/image-limits.js +53 -0
- package/dist/esm/ai/image-limits.js.map +1 -0
- package/dist/esm/ai/unified-prompts/reminders.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/reminders.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/reminders.js +31 -0
- package/dist/esm/ai/unified-prompts/reminders.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts +11 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +843 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/brain.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/brain.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/brain.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/brain.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/cli-help.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/cli-help.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/cli-help.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/cli-help.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/config-docs.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/config-docs.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/config-docs.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/config-docs.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/custom-components-instructions.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/dashboard-instructions.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-index.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-index.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-index.js +61 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-index.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/openapi-specs.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.js +10 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/sdk-interface-source.js.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt.d.ts +5 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt.d.ts.map +1 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt.js +73 -0
- package/dist/esm/ai/unified-prompts/skill-site-prompt.js.map +1 -0
- package/dist/esm/apps/apps-config.d.ts +168 -0
- package/dist/esm/apps/apps-config.d.ts.map +1 -0
- package/dist/esm/apps/apps-config.js +154 -0
- package/dist/esm/apps/apps-config.js.map +1 -0
- package/dist/esm/apps/apps-ui.d.ts +45 -0
- package/dist/esm/apps/apps-ui.d.ts.map +1 -0
- package/dist/esm/apps/apps-ui.js +104 -0
- package/dist/esm/apps/apps-ui.js.map +1 -0
- package/dist/esm/config/db-sync-mappings.d.ts +193 -0
- package/dist/esm/config/db-sync-mappings.d.ts.map +1 -0
- package/dist/esm/config/db-sync-mappings.js +2253 -0
- package/dist/esm/config/db-sync-mappings.js.map +1 -0
- package/dist/esm/config/format.d.ts +61 -0
- package/dist/esm/config/format.d.ts.map +1 -0
- package/dist/esm/config/format.js +327 -0
- package/dist/esm/config/format.js.map +1 -0
- package/dist/esm/config/migrate-catalogs-to-product-lines.d.ts +14 -0
- package/dist/esm/config/migrate-catalogs-to-product-lines.d.ts.map +1 -0
- package/dist/esm/config/migrate-catalogs-to-product-lines.js +377 -0
- package/dist/esm/config/migrate-catalogs-to-product-lines.js.map +1 -0
- package/dist/esm/config/schema-fuzzer.test.d.ts +1 -0
- package/dist/esm/config/schema-fuzzer.test.js +401 -0
- package/dist/esm/config/schema-fuzzer.test.js.map +1 -0
- package/dist/esm/config/schema.d.ts +2315 -0
- package/dist/esm/config/schema.d.ts.map +1 -0
- package/dist/esm/config/schema.js +1065 -0
- package/dist/esm/config/schema.js.map +1 -0
- package/dist/esm/config-authoring.d.ts +12 -0
- package/dist/esm/config-authoring.d.ts.map +1 -0
- package/dist/esm/config-authoring.js +9 -0
- package/dist/esm/config-authoring.js.map +1 -0
- package/dist/esm/config-authoring.test.d.ts +1 -0
- package/dist/esm/config-authoring.test.js +29 -0
- package/dist/esm/config-authoring.test.js.map +1 -0
- package/dist/esm/config-rendering.d.ts +17 -0
- package/dist/esm/config-rendering.d.ts.map +1 -0
- package/dist/esm/config-rendering.js +108 -0
- package/dist/esm/config-rendering.js.map +1 -0
- package/dist/esm/crud.d.ts +98 -0
- package/dist/esm/crud.d.ts.map +1 -0
- package/dist/esm/crud.js +127 -0
- package/dist/esm/crud.js.map +1 -0
- package/dist/esm/global.d.ts +1 -0
- package/dist/esm/helpers/emails.d.ts +69 -0
- package/dist/esm/helpers/emails.d.ts.map +1 -0
- package/dist/esm/helpers/emails.js +243 -0
- package/dist/esm/helpers/emails.js.map +1 -0
- package/dist/esm/helpers/init-prompt.d.ts +5 -0
- package/dist/esm/helpers/init-prompt.d.ts.map +1 -0
- package/dist/esm/helpers/init-prompt.js +40 -0
- package/dist/esm/helpers/init-prompt.js.map +1 -0
- package/dist/esm/helpers/password.d.ts +7 -0
- package/dist/esm/helpers/password.d.ts.map +1 -0
- package/dist/esm/helpers/password.js +13 -0
- package/dist/esm/helpers/password.js.map +1 -0
- package/dist/esm/helpers/production-mode.d.ts +11 -0
- package/dist/esm/helpers/production-mode.d.ts.map +1 -0
- package/dist/esm/helpers/production-mode.js +46 -0
- package/dist/esm/helpers/production-mode.js.map +1 -0
- package/dist/esm/helpers/support-sla.d.ts +48 -0
- package/dist/esm/helpers/support-sla.d.ts.map +1 -0
- package/dist/esm/helpers/support-sla.js +65 -0
- package/dist/esm/helpers/support-sla.js.map +1 -0
- package/dist/esm/helpers/support-sla.test.d.ts +1 -0
- package/dist/esm/helpers/support-sla.test.js +102 -0
- package/dist/esm/helpers/support-sla.test.js.map +1 -0
- package/dist/esm/helpers/vault/client-side.d.ts +16 -0
- package/dist/esm/helpers/vault/client-side.d.ts.map +1 -0
- package/dist/esm/helpers/vault/client-side.js +69 -0
- package/dist/esm/helpers/vault/client-side.js.map +1 -0
- package/dist/esm/helpers/vault/server-side.d.ts +9 -0
- package/dist/esm/helpers/vault/server-side.d.ts.map +1 -0
- package/dist/esm/helpers/vault/server-side.js +123 -0
- package/dist/esm/helpers/vault/server-side.js.map +1 -0
- package/dist/esm/hooks/use-async-callback.d.ts +8 -0
- package/dist/esm/hooks/use-async-callback.d.ts.map +1 -0
- package/dist/esm/hooks/use-async-callback.js +38 -0
- package/dist/esm/hooks/use-async-callback.js.map +1 -0
- package/dist/esm/hooks/use-async-external-store.d.ts +9 -0
- package/dist/esm/hooks/use-async-external-store.d.ts.map +1 -0
- package/dist/esm/hooks/use-async-external-store.js +20 -0
- package/dist/esm/hooks/use-async-external-store.js.map +1 -0
- package/dist/esm/hooks/use-hash.d.ts +5 -0
- package/dist/esm/hooks/use-hash.d.ts.map +1 -0
- package/dist/esm/hooks/use-hash.js +15 -0
- package/dist/esm/hooks/use-hash.js.map +1 -0
- package/dist/esm/hooks/use-hover.d.ts +8 -0
- package/dist/esm/hooks/use-hover.d.ts.map +1 -0
- package/dist/esm/hooks/use-hover.js +59 -0
- package/dist/esm/hooks/use-hover.js.map +1 -0
- package/dist/esm/hooks/use-strict-memo.d.ts +10 -0
- package/dist/esm/hooks/use-strict-memo.d.ts.map +1 -0
- package/dist/esm/hooks/use-strict-memo.js +119 -0
- package/dist/esm/hooks/use-strict-memo.js.map +1 -0
- package/dist/esm/index.d.ts +5 -0
- package/dist/esm/index.js +6 -0
- package/dist/esm/interface/admin-interface.d.ts +308 -0
- package/dist/esm/interface/admin-interface.d.ts.map +1 -0
- package/dist/esm/interface/admin-interface.js +463 -0
- package/dist/esm/interface/admin-interface.js.map +1 -0
- package/dist/esm/interface/admin-metrics.d.ts +597 -0
- package/dist/esm/interface/admin-metrics.d.ts.map +1 -0
- package/dist/esm/interface/admin-metrics.js +134 -0
- package/dist/esm/interface/admin-metrics.js.map +1 -0
- package/dist/esm/interface/client-interface.d.ts +447 -0
- package/dist/esm/interface/client-interface.d.ts.map +1 -0
- package/dist/esm/interface/client-interface.js +1946 -0
- package/dist/esm/interface/client-interface.js.map +1 -0
- package/dist/esm/interface/client-interface.test.d.ts +1 -0
- package/dist/esm/interface/client-interface.test.js +559 -0
- package/dist/esm/interface/client-interface.test.js.map +1 -0
- package/dist/esm/interface/conversations.d.ts +314 -0
- package/dist/esm/interface/conversations.d.ts.map +1 -0
- package/dist/esm/interface/conversations.js +108 -0
- package/dist/esm/interface/conversations.js.map +1 -0
- package/dist/esm/interface/crud/analytics.d.ts +14 -0
- package/dist/esm/interface/crud/analytics.d.ts.map +1 -0
- package/dist/esm/interface/crud/analytics.js +1 -0
- package/dist/esm/interface/crud/connected-accounts.d.ts +69 -0
- package/dist/esm/interface/crud/connected-accounts.d.ts.map +1 -0
- package/dist/esm/interface/crud/connected-accounts.js +35 -0
- package/dist/esm/interface/crud/connected-accounts.js.map +1 -0
- package/dist/esm/interface/crud/contact-channels.d.ts +182 -0
- package/dist/esm/interface/crud/contact-channels.d.ts.map +1 -0
- package/dist/esm/interface/crud/contact-channels.js +68 -0
- package/dist/esm/interface/crud/contact-channels.js.map +1 -0
- package/dist/esm/interface/crud/current-user.d.ts +286 -0
- package/dist/esm/interface/crud/current-user.d.ts.map +1 -0
- package/dist/esm/interface/crud/current-user.js +69 -0
- package/dist/esm/interface/crud/current-user.js.map +1 -0
- package/dist/esm/interface/crud/email-outbox.d.ts +1466 -0
- package/dist/esm/interface/crud/email-outbox.d.ts.map +1 -0
- package/dist/esm/interface/crud/email-outbox.js +190 -0
- package/dist/esm/interface/crud/email-outbox.js.map +1 -0
- package/dist/esm/interface/crud/email-templates.d.ts +86 -0
- package/dist/esm/interface/crud/email-templates.d.ts.map +1 -0
- package/dist/esm/interface/crud/email-templates.js +46 -0
- package/dist/esm/interface/crud/email-templates.js.map +1 -0
- package/dist/esm/interface/crud/emails.d.ts +42 -0
- package/dist/esm/interface/crud/emails.d.ts.map +1 -0
- package/dist/esm/interface/crud/emails.js +19 -0
- package/dist/esm/interface/crud/emails.js.map +1 -0
- package/dist/esm/interface/crud/internal-api-keys.d.ts +141 -0
- package/dist/esm/interface/crud/internal-api-keys.d.ts.map +1 -0
- package/dist/esm/interface/crud/internal-api-keys.js +49 -0
- package/dist/esm/interface/crud/internal-api-keys.js.map +1 -0
- package/dist/esm/interface/crud/invoices.d.ts +43 -0
- package/dist/esm/interface/crud/invoices.d.ts.map +1 -0
- package/dist/esm/interface/crud/invoices.js +25 -0
- package/dist/esm/interface/crud/invoices.js.map +1 -0
- package/dist/esm/interface/crud/items.d.ts +31 -0
- package/dist/esm/interface/crud/items.d.ts.map +1 -0
- package/dist/esm/interface/crud/items.js +23 -0
- package/dist/esm/interface/crud/items.js.map +1 -0
- package/dist/esm/interface/crud/notification-preferences.d.ts +39 -0
- package/dist/esm/interface/crud/notification-preferences.d.ts.map +1 -0
- package/dist/esm/interface/crud/notification-preferences.js +31 -0
- package/dist/esm/interface/crud/notification-preferences.js.map +1 -0
- package/dist/esm/interface/crud/oauth-providers.d.ts +187 -0
- package/dist/esm/interface/crud/oauth-providers.d.ts.map +1 -0
- package/dist/esm/interface/crud/oauth-providers.js +75 -0
- package/dist/esm/interface/crud/oauth-providers.js.map +1 -0
- package/dist/esm/interface/crud/products.d.ts +182 -0
- package/dist/esm/interface/crud/products.d.ts.map +1 -0
- package/dist/esm/interface/crud/products.js +29 -0
- package/dist/esm/interface/crud/products.js.map +1 -0
- package/dist/esm/interface/crud/project-api-keys.d.ts +204 -0
- package/dist/esm/interface/crud/project-api-keys.d.ts.map +1 -0
- package/dist/esm/interface/crud/project-api-keys.js +72 -0
- package/dist/esm/interface/crud/project-api-keys.js.map +1 -0
- package/dist/esm/interface/crud/project-permissions.d.ts +162 -0
- package/dist/esm/interface/crud/project-permissions.d.ts.map +1 -0
- package/dist/esm/interface/crud/project-permissions.js +104 -0
- package/dist/esm/interface/crud/project-permissions.js.map +1 -0
- package/dist/esm/interface/crud/projects.d.ts +852 -0
- package/dist/esm/interface/crud/projects.d.ts.map +1 -0
- package/dist/esm/interface/crud/projects.js +193 -0
- package/dist/esm/interface/crud/projects.js.map +1 -0
- package/dist/esm/interface/crud/session-replays.d.ts +83 -0
- package/dist/esm/interface/crud/session-replays.d.ts.map +1 -0
- package/dist/esm/interface/crud/session-replays.js +1 -0
- package/dist/esm/interface/crud/sessions.d.ts +151 -0
- package/dist/esm/interface/crud/sessions.d.ts.map +1 -0
- package/dist/esm/interface/crud/sessions.js +56 -0
- package/dist/esm/interface/crud/sessions.js.map +1 -0
- package/dist/esm/interface/crud/sign-up-rules.d.ts +15 -0
- package/dist/esm/interface/crud/sign-up-rules.d.ts.map +1 -0
- package/dist/esm/interface/crud/sign-up-rules.js +1 -0
- package/dist/esm/interface/crud/svix-token.d.ts +32 -0
- package/dist/esm/interface/crud/svix-token.d.ts.map +1 -0
- package/dist/esm/interface/crud/svix-token.js +18 -0
- package/dist/esm/interface/crud/svix-token.js.map +1 -0
- package/dist/esm/interface/crud/team-invitation-details.d.ts +32 -0
- package/dist/esm/interface/crud/team-invitation-details.d.ts.map +1 -0
- package/dist/esm/interface/crud/team-invitation-details.js +21 -0
- package/dist/esm/interface/crud/team-invitation-details.js.map +1 -0
- package/dist/esm/interface/crud/team-invitation.d.ts +55 -0
- package/dist/esm/interface/crud/team-invitation.d.ts.map +1 -0
- package/dist/esm/interface/crud/team-invitation.js +37 -0
- package/dist/esm/interface/crud/team-invitation.js.map +1 -0
- package/dist/esm/interface/crud/team-member-profiles.d.ts +287 -0
- package/dist/esm/interface/crud/team-member-profiles.d.ts.map +1 -0
- package/dist/esm/interface/crud/team-member-profiles.js +58 -0
- package/dist/esm/interface/crud/team-member-profiles.js.map +1 -0
- package/dist/esm/interface/crud/team-memberships.d.ts +76 -0
- package/dist/esm/interface/crud/team-memberships.d.ts.map +1 -0
- package/dist/esm/interface/crud/team-memberships.js +54 -0
- package/dist/esm/interface/crud/team-memberships.js.map +1 -0
- package/dist/esm/interface/crud/team-permissions.d.ts +170 -0
- package/dist/esm/interface/crud/team-permissions.d.ts.map +1 -0
- package/dist/esm/interface/crud/team-permissions.js +105 -0
- package/dist/esm/interface/crud/team-permissions.js.map +1 -0
- package/dist/esm/interface/crud/teams.d.ts +300 -0
- package/dist/esm/interface/crud/teams.d.ts.map +1 -0
- package/dist/esm/interface/crud/teams.js +129 -0
- package/dist/esm/interface/crud/teams.js.map +1 -0
- package/dist/esm/interface/crud/transactions.d.ts +183 -0
- package/dist/esm/interface/crud/transactions.d.ts.map +1 -0
- package/dist/esm/interface/crud/transactions.js +85 -0
- package/dist/esm/interface/crud/transactions.js.map +1 -0
- package/dist/esm/interface/crud/users.d.ts +654 -0
- package/dist/esm/interface/crud/users.d.ts.map +1 -0
- package/dist/esm/interface/crud/users.js +181 -0
- package/dist/esm/interface/crud/users.js.map +1 -0
- package/dist/esm/interface/handler-urls.d.ts +51 -0
- package/dist/esm/interface/handler-urls.d.ts.map +1 -0
- package/dist/esm/interface/handler-urls.js +3 -0
- package/dist/esm/interface/page-component-versions.d.ts +25 -0
- package/dist/esm/interface/page-component-versions.d.ts.map +1 -0
- package/dist/esm/interface/page-component-versions.js +1661 -0
- package/dist/esm/interface/page-component-versions.js.map +1 -0
- package/dist/esm/interface/server-interface.d.ts +255 -0
- package/dist/esm/interface/server-interface.d.ts.map +1 -0
- package/dist/esm/interface/server-interface.js +459 -0
- package/dist/esm/interface/server-interface.js.map +1 -0
- package/dist/esm/interface/webhooks.d.ts +326 -0
- package/dist/esm/interface/webhooks.d.ts.map +1 -0
- package/dist/esm/interface/webhooks.js +22 -0
- package/dist/esm/interface/webhooks.js.map +1 -0
- package/dist/esm/known-errors.d.ts +575 -0
- package/dist/esm/known-errors.d.ts.map +1 -0
- package/dist/esm/known-errors.js +791 -0
- package/dist/esm/known-errors.js.map +1 -0
- package/dist/esm/local-emulator.d.ts +6 -0
- package/dist/esm/local-emulator.d.ts.map +1 -0
- package/dist/esm/local-emulator.js +7 -0
- package/dist/esm/local-emulator.js.map +1 -0
- package/dist/esm/payments/payment-methods.d.ts +64 -0
- package/dist/esm/payments/payment-methods.d.ts.map +1 -0
- package/dist/esm/payments/payment-methods.js +205 -0
- package/dist/esm/payments/payment-methods.js.map +1 -0
- package/dist/esm/payments/stripe-limits.d.ts +17 -0
- package/dist/esm/payments/stripe-limits.d.ts.map +1 -0
- package/dist/esm/payments/stripe-limits.js +17 -0
- package/dist/esm/payments/stripe-limits.js.map +1 -0
- package/dist/esm/plans.d.ts +72 -0
- package/dist/esm/plans.d.ts.map +1 -0
- package/dist/esm/plans.js +81 -0
- package/dist/esm/plans.js.map +1 -0
- package/dist/esm/schema-fields.d.ts +472 -0
- package/dist/esm/schema-fields.d.ts.map +1 -0
- package/dist/esm/schema-fields.js +1009 -0
- package/dist/esm/schema-fields.js.map +1 -0
- package/dist/esm/sessions.d.ts +165 -0
- package/dist/esm/sessions.d.ts.map +1 -0
- package/dist/esm/sessions.js +226 -0
- package/dist/esm/sessions.js.map +1 -0
- package/dist/esm/stack-config-file.d.ts +15 -0
- package/dist/esm/stack-config-file.d.ts.map +1 -0
- package/dist/esm/stack-config-file.js +76 -0
- package/dist/esm/stack-config-file.js.map +1 -0
- package/dist/esm/utils/api-keys.d.ts +26 -0
- package/dist/esm/utils/api-keys.d.ts.map +1 -0
- package/dist/esm/utils/api-keys.js +77 -0
- package/dist/esm/utils/api-keys.js.map +1 -0
- package/dist/esm/utils/arrays.d.ts +25 -0
- package/dist/esm/utils/arrays.d.ts.map +1 -0
- package/dist/esm/utils/arrays.js +552 -0
- package/dist/esm/utils/arrays.js.map +1 -0
- package/dist/esm/utils/auth-methods.d.ts +6 -0
- package/dist/esm/utils/auth-methods.d.ts.map +1 -0
- package/dist/esm/utils/auth-methods.js +11 -0
- package/dist/esm/utils/auth-methods.js.map +1 -0
- package/dist/esm/utils/base64.d.ts +6 -0
- package/dist/esm/utils/base64.d.ts.map +1 -0
- package/dist/esm/utils/base64.js +25 -0
- package/dist/esm/utils/base64.js.map +1 -0
- package/dist/esm/utils/booleans.d.ts +8 -0
- package/dist/esm/utils/booleans.d.ts.map +1 -0
- package/dist/esm/utils/booleans.js +35 -0
- package/dist/esm/utils/booleans.js.map +1 -0
- package/dist/esm/utils/browser-compat.d.ts +10 -0
- package/dist/esm/utils/browser-compat.d.ts.map +1 -0
- package/dist/esm/utils/browser-compat.js +21 -0
- package/dist/esm/utils/browser-compat.js.map +1 -0
- package/dist/esm/utils/bytes.d.ts +17 -0
- package/dist/esm/utils/bytes.d.ts.map +1 -0
- package/dist/esm/utils/bytes.js +290 -0
- package/dist/esm/utils/bytes.js.map +1 -0
- package/dist/esm/utils/caches.d.ts +102 -0
- package/dist/esm/utils/caches.d.ts.map +1 -0
- package/dist/esm/utils/caches.js +185 -0
- package/dist/esm/utils/caches.js.map +1 -0
- package/dist/esm/utils/cel-fields.d.ts +23 -0
- package/dist/esm/utils/cel-fields.d.ts.map +1 -0
- package/dist/esm/utils/cel-fields.js +99 -0
- package/dist/esm/utils/cel-fields.js.map +1 -0
- package/dist/esm/utils/compile-time.d.ts +10 -0
- package/dist/esm/utils/compile-time.d.ts.map +1 -0
- package/dist/esm/utils/compile-time.js +14 -0
- package/dist/esm/utils/compile-time.js.map +1 -0
- package/dist/esm/utils/country-codes.d.ts +11 -0
- package/dist/esm/utils/country-codes.d.ts.map +1 -0
- package/dist/esm/utils/country-codes.js +36 -0
- package/dist/esm/utils/country-codes.js.map +1 -0
- package/dist/esm/utils/crypto.d.ts +48 -0
- package/dist/esm/utils/crypto.d.ts.map +1 -0
- package/dist/esm/utils/crypto.js +208 -0
- package/dist/esm/utils/crypto.js.map +1 -0
- package/dist/esm/utils/currencies.d.ts +8 -0
- package/dist/esm/utils/currencies.d.ts.map +1 -0
- package/dist/esm/utils/currencies.js +50 -0
- package/dist/esm/utils/currencies.js.map +1 -0
- package/dist/esm/utils/currency-constants.d.ts +39 -0
- package/dist/esm/utils/currency-constants.d.ts.map +1 -0
- package/dist/esm/utils/currency-constants.js +42 -0
- package/dist/esm/utils/currency-constants.js.map +1 -0
- package/dist/esm/utils/dates.d.ts +23 -0
- package/dist/esm/utils/dates.d.ts.map +1 -0
- package/dist/esm/utils/dates.js +167 -0
- package/dist/esm/utils/dates.js.map +1 -0
- package/dist/esm/utils/dev-env-state-path.d.ts +6 -0
- package/dist/esm/utils/dev-env-state-path.d.ts.map +1 -0
- package/dist/esm/utils/dev-env-state-path.js +15 -0
- package/dist/esm/utils/dev-env-state-path.js.map +1 -0
- package/dist/esm/utils/dom.d.ts +5 -0
- package/dist/esm/utils/dom.d.ts.map +1 -0
- package/dist/esm/utils/dom.js +11 -0
- package/dist/esm/utils/dom.js.map +1 -0
- package/dist/esm/utils/env.d.ts +25 -0
- package/dist/esm/utils/env.d.ts.map +1 -0
- package/dist/esm/utils/env.js +78 -0
- package/dist/esm/utils/env.js.map +1 -0
- package/dist/esm/utils/errors.d.ts +231 -0
- package/dist/esm/utils/errors.d.ts.map +1 -0
- package/dist/esm/utils/errors.js +385 -0
- package/dist/esm/utils/errors.js.map +1 -0
- package/dist/esm/utils/esbuild.d.ts +16 -0
- package/dist/esm/utils/esbuild.d.ts.map +1 -0
- package/dist/esm/utils/esbuild.js +182 -0
- package/dist/esm/utils/esbuild.js.map +1 -0
- package/dist/esm/utils/featurebase.d.ts +30 -0
- package/dist/esm/utils/featurebase.d.ts.map +1 -0
- package/dist/esm/utils/featurebase.js +166 -0
- package/dist/esm/utils/featurebase.js.map +1 -0
- package/dist/esm/utils/fs.d.ts +9 -0
- package/dist/esm/utils/fs.d.ts.map +1 -0
- package/dist/esm/utils/fs.js +25 -0
- package/dist/esm/utils/fs.js.map +1 -0
- package/dist/esm/utils/functions.d.ts +6 -0
- package/dist/esm/utils/functions.d.ts.map +1 -0
- package/dist/esm/utils/functions.js +34 -0
- package/dist/esm/utils/functions.js.map +1 -0
- package/dist/esm/utils/geo.d.ts +24 -0
- package/dist/esm/utils/geo.d.ts.map +1 -0
- package/dist/esm/utils/geo.js +16 -0
- package/dist/esm/utils/geo.js.map +1 -0
- package/dist/esm/utils/globals.d.ts +13 -0
- package/dist/esm/utils/globals.d.ts.map +1 -0
- package/dist/esm/utils/globals.js +34 -0
- package/dist/esm/utils/globals.js.map +1 -0
- package/dist/esm/utils/hashes.d.ts +9 -0
- package/dist/esm/utils/hashes.d.ts.map +1 -0
- package/dist/esm/utils/hashes.js +40 -0
- package/dist/esm/utils/hashes.js.map +1 -0
- package/dist/esm/utils/html.d.ts +7 -0
- package/dist/esm/utils/html.d.ts.map +1 -0
- package/dist/esm/utils/html.js +33 -0
- package/dist/esm/utils/html.js.map +1 -0
- package/dist/esm/utils/http.d.ts +45 -0
- package/dist/esm/utils/http.d.ts.map +1 -0
- package/dist/esm/utils/http.js +75 -0
- package/dist/esm/utils/http.js.map +1 -0
- package/dist/esm/utils/ips.d.ts +8 -0
- package/dist/esm/utils/ips.d.ts.map +1 -0
- package/dist/esm/utils/ips.js +36 -0
- package/dist/esm/utils/ips.js.map +1 -0
- package/dist/esm/utils/json.d.ts +15 -0
- package/dist/esm/utils/json.d.ts.map +1 -0
- package/dist/esm/utils/json.js +178 -0
- package/dist/esm/utils/json.js.map +1 -0
- package/dist/esm/utils/jsx-editable-transpiler.d.ts +68 -0
- package/dist/esm/utils/jsx-editable-transpiler.d.ts.map +1 -0
- package/dist/esm/utils/jsx-editable-transpiler.js +216 -0
- package/dist/esm/utils/jsx-editable-transpiler.js.map +1 -0
- package/dist/esm/utils/jsx-editable-transpiler.test.d.ts +1 -0
- package/dist/esm/utils/jsx-editable-transpiler.test.js +122 -0
- package/dist/esm/utils/jsx-editable-transpiler.test.js.map +1 -0
- package/dist/esm/utils/jwt.d.ts +79 -0
- package/dist/esm/utils/jwt.d.ts.map +1 -0
- package/dist/esm/utils/jwt.js +102 -0
- package/dist/esm/utils/jwt.js.map +1 -0
- package/dist/esm/utils/locks.d.ts +17 -0
- package/dist/esm/utils/locks.d.ts.map +1 -0
- package/dist/esm/utils/locks.js +54 -0
- package/dist/esm/utils/locks.js.map +1 -0
- package/dist/esm/utils/maps.d.ts +61 -0
- package/dist/esm/utils/maps.d.ts.map +1 -0
- package/dist/esm/utils/maps.js +297 -0
- package/dist/esm/utils/maps.js.map +1 -0
- package/dist/esm/utils/math.d.ts +8 -0
- package/dist/esm/utils/math.d.ts.map +1 -0
- package/dist/esm/utils/math.js +21 -0
- package/dist/esm/utils/math.js.map +1 -0
- package/dist/esm/utils/monkey-patch.d.ts +7 -0
- package/dist/esm/utils/monkey-patch.d.ts.map +1 -0
- package/dist/esm/utils/monkey-patch.js +21 -0
- package/dist/esm/utils/monkey-patch.js.map +1 -0
- package/dist/esm/utils/node-http.d.ts +17 -0
- package/dist/esm/utils/node-http.d.ts.map +1 -0
- package/dist/esm/utils/node-http.js +38 -0
- package/dist/esm/utils/node-http.js.map +1 -0
- package/dist/esm/utils/numbers.d.ts +7 -0
- package/dist/esm/utils/numbers.d.ts.map +1 -0
- package/dist/esm/utils/numbers.js +75 -0
- package/dist/esm/utils/numbers.js.map +1 -0
- package/dist/esm/utils/oauth.d.ts +11 -0
- package/dist/esm/utils/oauth.d.ts.map +1 -0
- package/dist/esm/utils/oauth.js +27 -0
- package/dist/esm/utils/oauth.js.map +1 -0
- package/dist/esm/utils/objects.d.ts +59 -0
- package/dist/esm/utils/objects.d.ts.map +1 -0
- package/dist/esm/utils/objects.js +818 -0
- package/dist/esm/utils/objects.js.map +1 -0
- package/dist/esm/utils/paginated-lists.d.ts +442 -0
- package/dist/esm/utils/paginated-lists.d.ts.map +1 -0
- package/dist/esm/utils/paginated-lists.js +411 -0
- package/dist/esm/utils/paginated-lists.js.map +1 -0
- package/dist/esm/utils/paginated-lists.test.d.ts +1 -0
- package/dist/esm/utils/paginated-lists.test.js +1304 -0
- package/dist/esm/utils/paginated-lists.test.js.map +1 -0
- package/dist/esm/utils/passkey.d.ts +2 -0
- package/dist/esm/utils/passkey.js +1 -0
- package/dist/esm/utils/promises.d.ts +80 -0
- package/dist/esm/utils/promises.d.ts.map +1 -0
- package/dist/esm/utils/promises.js +333 -0
- package/dist/esm/utils/promises.js.map +1 -0
- package/dist/esm/utils/proxies.d.ts +13 -0
- package/dist/esm/utils/proxies.d.ts.map +1 -0
- package/dist/esm/utils/proxies.js +197 -0
- package/dist/esm/utils/proxies.js.map +1 -0
- package/dist/esm/utils/react.d.ts +61 -0
- package/dist/esm/utils/react.d.ts.map +1 -0
- package/dist/esm/utils/react.js +229 -0
- package/dist/esm/utils/react.js.map +1 -0
- package/dist/esm/utils/redirect-urls.d.ts +30 -0
- package/dist/esm/utils/redirect-urls.d.ts.map +1 -0
- package/dist/esm/utils/redirect-urls.js +215 -0
- package/dist/esm/utils/redirect-urls.js.map +1 -0
- package/dist/esm/utils/regex.d.ts +5 -0
- package/dist/esm/utils/regex.d.ts.map +1 -0
- package/dist/esm/utils/regex.js +13 -0
- package/dist/esm/utils/regex.js.map +1 -0
- package/dist/esm/utils/results.d.ts +70 -0
- package/dist/esm/utils/results.d.ts.map +1 -0
- package/dist/esm/utils/results.js +339 -0
- package/dist/esm/utils/results.js.map +1 -0
- package/dist/esm/utils/sentry.d.ts +13 -0
- package/dist/esm/utils/sentry.d.ts.map +1 -0
- package/dist/esm/utils/sentry.js +14 -0
- package/dist/esm/utils/sentry.js.map +1 -0
- package/dist/esm/utils/stores.d.ts +104 -0
- package/dist/esm/utils/stores.d.ts.map +1 -0
- package/dist/esm/utils/stores.js +175 -0
- package/dist/esm/utils/stores.js.map +1 -0
- package/dist/esm/utils/strings.d.ts +76 -0
- package/dist/esm/utils/strings.d.ts.map +1 -0
- package/dist/esm/utils/strings.js +530 -0
- package/dist/esm/utils/strings.js.map +1 -0
- package/dist/esm/utils/strings.nicify.test.d.ts +1 -0
- package/dist/esm/utils/strings.nicify.test.js +243 -0
- package/dist/esm/utils/strings.nicify.test.js.map +1 -0
- package/dist/esm/utils/telemetry.d.ts +15 -0
- package/dist/esm/utils/telemetry.d.ts.map +1 -0
- package/dist/esm/utils/telemetry.js +31 -0
- package/dist/esm/utils/telemetry.js.map +1 -0
- package/dist/esm/utils/turnstile-browser.d.ts +32 -0
- package/dist/esm/utils/turnstile-browser.d.ts.map +1 -0
- package/dist/esm/utils/turnstile-browser.js +61 -0
- package/dist/esm/utils/turnstile-browser.js.map +1 -0
- package/dist/esm/utils/turnstile-flow.d.ts +29 -0
- package/dist/esm/utils/turnstile-flow.d.ts.map +1 -0
- package/dist/esm/utils/turnstile-flow.js +219 -0
- package/dist/esm/utils/turnstile-flow.js.map +1 -0
- package/dist/esm/utils/turnstile-flow.test.d.ts +1 -0
- package/dist/esm/utils/turnstile-flow.test.js +75 -0
- package/dist/esm/utils/turnstile-flow.test.js.map +1 -0
- package/dist/esm/utils/turnstile.d.ts +17 -0
- package/dist/esm/utils/turnstile.d.ts.map +1 -0
- package/dist/esm/utils/turnstile.js +25 -0
- package/dist/esm/utils/turnstile.js.map +1 -0
- package/dist/esm/utils/typed-arrays.d.ts +14 -0
- package/dist/esm/utils/typed-arrays.d.ts.map +1 -0
- package/dist/esm/utils/typed-arrays.js +20 -0
- package/dist/esm/utils/typed-arrays.js.map +1 -0
- package/dist/esm/utils/types.d.ts +77 -0
- package/dist/esm/utils/types.d.ts.map +1 -0
- package/dist/esm/utils/types.js +55 -0
- package/dist/esm/utils/types.js.map +1 -0
- package/dist/esm/utils/unicode.d.ts +5 -0
- package/dist/esm/utils/unicode.d.ts.map +1 -0
- package/dist/esm/utils/unicode.js +24 -0
- package/dist/esm/utils/unicode.js.map +1 -0
- package/dist/esm/utils/urls.d.ts +28 -0
- package/dist/esm/utils/urls.d.ts.map +1 -0
- package/dist/esm/utils/urls.js +259 -0
- package/dist/esm/utils/urls.js.map +1 -0
- package/dist/esm/utils/uuids.d.ts +6 -0
- package/dist/esm/utils/uuids.d.ts.map +1 -0
- package/dist/esm/utils/uuids.js +36 -0
- package/dist/esm/utils/uuids.js.map +1 -0
- package/dist/global.d.d.ts +0 -0
- package/dist/global.d.ts +1 -0
- package/dist/helpers/emails.d.ts +69 -0
- package/dist/helpers/emails.d.ts.map +1 -0
- package/dist/helpers/emails.js +252 -0
- package/dist/helpers/emails.js.map +1 -0
- package/dist/helpers/init-prompt.d.ts +5 -0
- package/dist/helpers/init-prompt.d.ts.map +1 -0
- package/dist/helpers/init-prompt.js +42 -0
- package/dist/helpers/init-prompt.js.map +1 -0
- package/dist/helpers/password.d.ts +6 -0
- package/dist/helpers/password.d.ts.map +1 -0
- package/dist/helpers/password.js +15 -0
- package/dist/helpers/password.js.map +1 -0
- package/dist/helpers/production-mode.d.ts +11 -0
- package/dist/helpers/production-mode.d.ts.map +1 -0
- package/dist/helpers/production-mode.js +48 -0
- package/dist/helpers/production-mode.js.map +1 -0
- package/dist/helpers/support-sla.d.ts +48 -0
- package/dist/helpers/support-sla.d.ts.map +1 -0
- package/dist/helpers/support-sla.js +72 -0
- package/dist/helpers/support-sla.js.map +1 -0
- package/dist/helpers/support-sla.test.d.ts +1 -0
- package/dist/helpers/support-sla.test.js +102 -0
- package/dist/helpers/support-sla.test.js.map +1 -0
- package/dist/helpers/vault/client-side.d.ts +16 -0
- package/dist/helpers/vault/client-side.d.ts.map +1 -0
- package/dist/helpers/vault/client-side.js +73 -0
- package/dist/helpers/vault/client-side.js.map +1 -0
- package/dist/helpers/vault/server-side.d.ts +9 -0
- package/dist/helpers/vault/server-side.d.ts.map +1 -0
- package/dist/helpers/vault/server-side.js +126 -0
- package/dist/helpers/vault/server-side.js.map +1 -0
- package/dist/hooks/use-async-callback.d.ts +8 -0
- package/dist/hooks/use-async-callback.d.ts.map +1 -0
- package/dist/hooks/use-async-callback.js +42 -0
- package/dist/hooks/use-async-callback.js.map +1 -0
- package/dist/hooks/use-async-external-store.d.ts +9 -0
- package/dist/hooks/use-async-external-store.d.ts.map +1 -0
- package/dist/hooks/use-async-external-store.js +22 -0
- package/dist/hooks/use-async-external-store.js.map +1 -0
- package/dist/hooks/use-hash.d.ts +5 -0
- package/dist/hooks/use-hash.d.ts.map +1 -0
- package/dist/hooks/use-hash.js +17 -0
- package/dist/hooks/use-hash.js.map +1 -0
- package/dist/hooks/use-hover.d.ts +8 -0
- package/dist/hooks/use-hover.d.ts.map +1 -0
- package/dist/hooks/use-hover.js +61 -0
- package/dist/hooks/use-hover.js.map +1 -0
- package/dist/hooks/use-strict-memo.d.ts +10 -0
- package/dist/hooks/use-strict-memo.d.ts.map +1 -0
- package/dist/hooks/use-strict-memo.js +121 -0
- package/dist/hooks/use-strict-memo.js.map +1 -0
- package/dist/index-D9ysacya.d.ts +153 -0
- package/dist/index-D9ysacya.d.ts.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +37 -0
- package/dist/interface/admin-interface.d.ts +308 -0
- package/dist/interface/admin-interface.d.ts.map +1 -0
- package/dist/interface/admin-interface.js +465 -0
- package/dist/interface/admin-interface.js.map +1 -0
- package/dist/interface/admin-metrics.d.ts +597 -0
- package/dist/interface/admin-metrics.d.ts.map +1 -0
- package/dist/interface/admin-metrics.js +153 -0
- package/dist/interface/admin-metrics.js.map +1 -0
- package/dist/interface/client-interface.d.ts +447 -0
- package/dist/interface/client-interface.d.ts.map +1 -0
- package/dist/interface/client-interface.js +1948 -0
- package/dist/interface/client-interface.js.map +1 -0
- package/dist/interface/client-interface.test.d.ts +1 -0
- package/dist/interface/client-interface.test.js +559 -0
- package/dist/interface/client-interface.test.js.map +1 -0
- package/dist/interface/conversations.d.ts +314 -0
- package/dist/interface/conversations.d.ts.map +1 -0
- package/dist/interface/conversations.js +121 -0
- package/dist/interface/conversations.js.map +1 -0
- package/dist/interface/crud/analytics.d.ts +14 -0
- package/dist/interface/crud/analytics.d.ts.map +1 -0
- package/dist/interface/crud/analytics.js +0 -0
- package/dist/interface/crud/connected-accounts.d.ts +68 -0
- package/dist/interface/crud/connected-accounts.d.ts.map +1 -0
- package/dist/interface/crud/connected-accounts.js +41 -0
- package/dist/interface/crud/connected-accounts.js.map +1 -0
- package/dist/interface/crud/contact-channels.d.ts +181 -0
- package/dist/interface/crud/contact-channels.d.ts.map +1 -0
- package/dist/interface/crud/contact-channels.js +76 -0
- package/dist/interface/crud/contact-channels.js.map +1 -0
- package/dist/interface/crud/current-user.d.ts +285 -0
- package/dist/interface/crud/current-user.d.ts.map +1 -0
- package/dist/interface/crud/current-user.js +71 -0
- package/dist/interface/crud/current-user.js.map +1 -0
- package/dist/interface/crud/email-outbox.d.ts +1465 -0
- package/dist/interface/crud/email-outbox.d.ts.map +1 -0
- package/dist/interface/crud/email-outbox.js +195 -0
- package/dist/interface/crud/email-outbox.js.map +1 -0
- package/dist/interface/crud/email-templates.d.ts +85 -0
- package/dist/interface/crud/email-templates.d.ts.map +1 -0
- package/dist/interface/crud/email-templates.js +53 -0
- package/dist/interface/crud/email-templates.js.map +1 -0
- package/dist/interface/crud/emails.d.ts +41 -0
- package/dist/interface/crud/emails.d.ts.map +1 -0
- package/dist/interface/crud/emails.js +23 -0
- package/dist/interface/crud/emails.js.map +1 -0
- package/dist/interface/crud/internal-api-keys.d.ts +140 -0
- package/dist/interface/crud/internal-api-keys.d.ts.map +1 -0
- package/dist/interface/crud/internal-api-keys.js +56 -0
- package/dist/interface/crud/internal-api-keys.js.map +1 -0
- package/dist/interface/crud/invoices.d.ts +43 -0
- package/dist/interface/crud/invoices.d.ts.map +1 -0
- package/dist/interface/crud/invoices.js +28 -0
- package/dist/interface/crud/invoices.js.map +1 -0
- package/dist/interface/crud/items.d.ts +30 -0
- package/dist/interface/crud/items.d.ts.map +1 -0
- package/dist/interface/crud/items.js +25 -0
- package/dist/interface/crud/items.js.map +1 -0
- package/dist/interface/crud/notification-preferences.d.ts +38 -0
- package/dist/interface/crud/notification-preferences.d.ts.map +1 -0
- package/dist/interface/crud/notification-preferences.js +33 -0
- package/dist/interface/crud/notification-preferences.js.map +1 -0
- package/dist/interface/crud/oauth-providers.d.ts +186 -0
- package/dist/interface/crud/oauth-providers.d.ts.map +1 -0
- package/dist/interface/crud/oauth-providers.js +83 -0
- package/dist/interface/crud/oauth-providers.js.map +1 -0
- package/dist/interface/crud/products.d.ts +182 -0
- package/dist/interface/crud/products.d.ts.map +1 -0
- package/dist/interface/crud/products.js +32 -0
- package/dist/interface/crud/products.js.map +1 -0
- package/dist/interface/crud/project-api-keys.d.ts +203 -0
- package/dist/interface/crud/project-api-keys.d.ts.map +1 -0
- package/dist/interface/crud/project-api-keys.js +79 -0
- package/dist/interface/crud/project-api-keys.js.map +1 -0
- package/dist/interface/crud/project-permissions.d.ts +161 -0
- package/dist/interface/crud/project-permissions.d.ts.map +1 -0
- package/dist/interface/crud/project-permissions.js +116 -0
- package/dist/interface/crud/project-permissions.js.map +1 -0
- package/dist/interface/crud/projects.d.ts +851 -0
- package/dist/interface/crud/projects.d.ts.map +1 -0
- package/dist/interface/crud/projects.js +204 -0
- package/dist/interface/crud/projects.js.map +1 -0
- package/dist/interface/crud/session-replays.d.ts +83 -0
- package/dist/interface/crud/session-replays.d.ts.map +1 -0
- package/dist/interface/crud/session-replays.js +0 -0
- package/dist/interface/crud/sessions.d.ts +150 -0
- package/dist/interface/crud/sessions.d.ts.map +1 -0
- package/dist/interface/crud/sessions.js +62 -0
- package/dist/interface/crud/sessions.js.map +1 -0
- package/dist/interface/crud/sign-up-rules.d.ts +15 -0
- package/dist/interface/crud/sign-up-rules.d.ts.map +1 -0
- package/dist/interface/crud/sign-up-rules.js +0 -0
- package/dist/interface/crud/svix-token.d.ts +31 -0
- package/dist/interface/crud/svix-token.d.ts.map +1 -0
- package/dist/interface/crud/svix-token.js +22 -0
- package/dist/interface/crud/svix-token.js.map +1 -0
- package/dist/interface/crud/team-invitation-details.d.ts +31 -0
- package/dist/interface/crud/team-invitation-details.d.ts.map +1 -0
- package/dist/interface/crud/team-invitation-details.js +24 -0
- package/dist/interface/crud/team-invitation-details.js.map +1 -0
- package/dist/interface/crud/team-invitation.d.ts +54 -0
- package/dist/interface/crud/team-invitation.d.ts.map +1 -0
- package/dist/interface/crud/team-invitation.js +40 -0
- package/dist/interface/crud/team-invitation.js.map +1 -0
- package/dist/interface/crud/team-member-profiles.d.ts +286 -0
- package/dist/interface/crud/team-member-profiles.d.ts.map +1 -0
- package/dist/interface/crud/team-member-profiles.js +63 -0
- package/dist/interface/crud/team-member-profiles.js.map +1 -0
- package/dist/interface/crud/team-memberships.d.ts +75 -0
- package/dist/interface/crud/team-memberships.d.ts.map +1 -0
- package/dist/interface/crud/team-memberships.js +61 -0
- package/dist/interface/crud/team-memberships.js.map +1 -0
- package/dist/interface/crud/team-permissions.d.ts +169 -0
- package/dist/interface/crud/team-permissions.d.ts.map +1 -0
- package/dist/interface/crud/team-permissions.js +117 -0
- package/dist/interface/crud/team-permissions.js.map +1 -0
- package/dist/interface/crud/teams.d.ts +299 -0
- package/dist/interface/crud/teams.d.ts.map +1 -0
- package/dist/interface/crud/teams.js +142 -0
- package/dist/interface/crud/teams.js.map +1 -0
- package/dist/interface/crud/transactions.d.ts +183 -0
- package/dist/interface/crud/transactions.d.ts.map +1 -0
- package/dist/interface/crud/transactions.js +89 -0
- package/dist/interface/crud/transactions.js.map +1 -0
- package/dist/interface/crud/users.d.ts +653 -0
- package/dist/interface/crud/users.d.ts.map +1 -0
- package/dist/interface/crud/users.js +193 -0
- package/dist/interface/crud/users.js.map +1 -0
- package/dist/interface/handler-urls.d.ts +51 -0
- package/dist/interface/handler-urls.d.ts.map +1 -0
- package/dist/interface/handler-urls.js +16 -0
- package/dist/interface/page-component-versions.d.ts +25 -0
- package/dist/interface/page-component-versions.d.ts.map +1 -0
- package/dist/interface/page-component-versions.js +1664 -0
- package/dist/interface/page-component-versions.js.map +1 -0
- package/dist/interface/server-interface.d.ts +255 -0
- package/dist/interface/server-interface.d.ts.map +1 -0
- package/dist/interface/server-interface.js +461 -0
- package/dist/interface/server-interface.js.map +1 -0
- package/dist/interface/webhooks.d.ts +326 -0
- package/dist/interface/webhooks.d.ts.map +1 -0
- package/dist/interface/webhooks.js +24 -0
- package/dist/interface/webhooks.js.map +1 -0
- package/dist/known-errors.d.ts +575 -0
- package/dist/known-errors.d.ts.map +1 -0
- package/dist/known-errors.js +794 -0
- package/dist/known-errors.js.map +1 -0
- package/dist/local-emulator.d.ts +6 -0
- package/dist/local-emulator.d.ts.map +1 -0
- package/dist/local-emulator.js +10 -0
- package/dist/local-emulator.js.map +1 -0
- package/dist/payments/payment-methods.d.ts +64 -0
- package/dist/payments/payment-methods.d.ts.map +1 -0
- package/dist/payments/payment-methods.js +216 -0
- package/dist/payments/payment-methods.js.map +1 -0
- package/dist/payments/stripe-limits.d.ts +17 -0
- package/dist/payments/stripe-limits.d.ts.map +1 -0
- package/dist/payments/stripe-limits.js +20 -0
- package/dist/payments/stripe-limits.js.map +1 -0
- package/dist/plans.d.ts +72 -0
- package/dist/plans.d.ts.map +1 -0
- package/dist/plans.js +88 -0
- package/dist/plans.js.map +1 -0
- package/dist/schema-fields.d.ts +472 -0
- package/dist/schema-fields.d.ts.map +1 -0
- package/dist/schema-fields.js +1188 -0
- package/dist/schema-fields.js.map +1 -0
- package/dist/sessions.d.ts +165 -0
- package/dist/sessions.d.ts.map +1 -0
- package/dist/sessions.js +231 -0
- package/dist/sessions.js.map +1 -0
- package/dist/stack-config-file.d.ts +15 -0
- package/dist/stack-config-file.d.ts.map +1 -0
- package/dist/stack-config-file.js +82 -0
- package/dist/stack-config-file.js.map +1 -0
- package/dist/utils/api-keys.d.ts +26 -0
- package/dist/utils/api-keys.d.ts.map +1 -0
- package/dist/utils/api-keys.js +82 -0
- package/dist/utils/api-keys.js.map +1 -0
- package/dist/utils/arrays.d.ts +25 -0
- package/dist/utils/arrays.d.ts.map +1 -0
- package/dist/utils/arrays.js +569 -0
- package/dist/utils/arrays.js.map +1 -0
- package/dist/utils/auth-methods.d.ts +6 -0
- package/dist/utils/auth-methods.d.ts.map +1 -0
- package/dist/utils/auth-methods.js +13 -0
- package/dist/utils/auth-methods.js.map +1 -0
- package/dist/utils/base64.d.ts +6 -0
- package/dist/utils/base64.d.ts.map +1 -0
- package/dist/utils/base64.js +28 -0
- package/dist/utils/base64.js.map +1 -0
- package/dist/utils/booleans.d.ts +8 -0
- package/dist/utils/booleans.d.ts.map +1 -0
- package/dist/utils/booleans.js +38 -0
- package/dist/utils/booleans.js.map +1 -0
- package/dist/utils/browser-compat.d.ts +10 -0
- package/dist/utils/browser-compat.d.ts.map +1 -0
- package/dist/utils/browser-compat.js +23 -0
- package/dist/utils/browser-compat.js.map +1 -0
- package/dist/utils/bytes.d.ts +17 -0
- package/dist/utils/bytes.d.ts.map +1 -0
- package/dist/utils/bytes.js +304 -0
- package/dist/utils/bytes.js.map +1 -0
- package/dist/utils/caches.d.ts +102 -0
- package/dist/utils/caches.d.ts.map +1 -0
- package/dist/utils/caches.js +188 -0
- package/dist/utils/caches.js.map +1 -0
- package/dist/utils/cel-fields.d.ts +23 -0
- package/dist/utils/cel-fields.d.ts.map +1 -0
- package/dist/utils/cel-fields.js +108 -0
- package/dist/utils/cel-fields.js.map +1 -0
- package/dist/utils/compile-time.d.ts +10 -0
- package/dist/utils/compile-time.d.ts.map +1 -0
- package/dist/utils/compile-time.js +16 -0
- package/dist/utils/compile-time.js.map +1 -0
- package/dist/utils/country-codes.d.ts +11 -0
- package/dist/utils/country-codes.d.ts.map +1 -0
- package/dist/utils/country-codes.js +40 -0
- package/dist/utils/country-codes.js.map +1 -0
- package/dist/utils/crypto.d.ts +48 -0
- package/dist/utils/crypto.d.ts.map +1 -0
- package/dist/utils/crypto.js +215 -0
- package/dist/utils/crypto.js.map +1 -0
- package/dist/utils/currencies.d.ts +8 -0
- package/dist/utils/currencies.d.ts.map +1 -0
- package/dist/utils/currencies.js +52 -0
- package/dist/utils/currencies.js.map +1 -0
- package/dist/utils/currency-constants.d.ts +39 -0
- package/dist/utils/currency-constants.d.ts.map +1 -0
- package/dist/utils/currency-constants.js +44 -0
- package/dist/utils/currency-constants.js.map +1 -0
- package/dist/utils/dates.d.ts +23 -0
- package/dist/utils/dates.d.ts.map +1 -0
- package/dist/utils/dates.js +176 -0
- package/dist/utils/dates.js.map +1 -0
- package/dist/utils/dev-env-state-path.d.ts +6 -0
- package/dist/utils/dev-env-state-path.d.ts.map +1 -0
- package/dist/utils/dev-env-state-path.js +18 -0
- package/dist/utils/dev-env-state-path.js.map +1 -0
- package/dist/utils/dom.d.ts +5 -0
- package/dist/utils/dom.d.ts.map +1 -0
- package/dist/utils/dom.js +13 -0
- package/dist/utils/dom.js.map +1 -0
- package/dist/utils/env.d.ts +25 -0
- package/dist/utils/env.d.ts.map +1 -0
- package/dist/utils/env.js +85 -0
- package/dist/utils/env.js.map +1 -0
- package/dist/utils/errors.d.ts +231 -0
- package/dist/utils/errors.d.ts.map +1 -0
- package/dist/utils/errors.js +393 -0
- package/dist/utils/errors.js.map +1 -0
- package/dist/utils/esbuild.d.ts +16 -0
- package/dist/utils/esbuild.d.ts.map +1 -0
- package/dist/utils/esbuild.js +186 -0
- package/dist/utils/esbuild.js.map +1 -0
- package/dist/utils/featurebase.d.ts +30 -0
- package/dist/utils/featurebase.d.ts.map +1 -0
- package/dist/utils/featurebase.js +168 -0
- package/dist/utils/featurebase.js.map +1 -0
- package/dist/utils/fs.d.ts +9 -0
- package/dist/utils/fs.d.ts.map +1 -0
- package/dist/utils/fs.js +31 -0
- package/dist/utils/fs.js.map +1 -0
- package/dist/utils/functions.d.ts +6 -0
- package/dist/utils/functions.d.ts.map +1 -0
- package/dist/utils/functions.js +37 -0
- package/dist/utils/functions.js.map +1 -0
- package/dist/utils/geo.d.ts +24 -0
- package/dist/utils/geo.d.ts.map +1 -0
- package/dist/utils/geo.js +18 -0
- package/dist/utils/geo.js.map +1 -0
- package/dist/utils/globals.d.ts +13 -0
- package/dist/utils/globals.d.ts.map +1 -0
- package/dist/utils/globals.js +40 -0
- package/dist/utils/globals.js.map +1 -0
- package/dist/utils/hashes.d.ts +9 -0
- package/dist/utils/hashes.d.ts.map +1 -0
- package/dist/utils/hashes.js +47 -0
- package/dist/utils/hashes.js.map +1 -0
- package/dist/utils/html.d.ts +7 -0
- package/dist/utils/html.d.ts.map +1 -0
- package/dist/utils/html.js +37 -0
- package/dist/utils/html.js.map +1 -0
- package/dist/utils/http.d.ts +45 -0
- package/dist/utils/http.d.ts.map +1 -0
- package/dist/utils/http.js +79 -0
- package/dist/utils/http.js.map +1 -0
- package/dist/utils/ips.d.ts +8 -0
- package/dist/utils/ips.d.ts.map +1 -0
- package/dist/utils/ips.js +40 -0
- package/dist/utils/ips.js.map +1 -0
- package/dist/utils/json.d.ts +15 -0
- package/dist/utils/json.d.ts.map +1 -0
- package/dist/utils/json.js +182 -0
- package/dist/utils/json.js.map +1 -0
- package/dist/utils/jsx-editable-transpiler.d.ts +68 -0
- package/dist/utils/jsx-editable-transpiler.d.ts.map +1 -0
- package/dist/utils/jsx-editable-transpiler.js +223 -0
- package/dist/utils/jsx-editable-transpiler.js.map +1 -0
- package/dist/utils/jsx-editable-transpiler.test.d.ts +1 -0
- package/dist/utils/jsx-editable-transpiler.test.js +122 -0
- package/dist/utils/jsx-editable-transpiler.test.js.map +1 -0
- package/dist/utils/jwt.d.ts +79 -0
- package/dist/utils/jwt.d.ts.map +1 -0
- package/dist/utils/jwt.js +112 -0
- package/dist/utils/jwt.js.map +1 -0
- package/dist/utils/locks.d.ts +17 -0
- package/dist/utils/locks.d.ts.map +1 -0
- package/dist/utils/locks.js +56 -0
- package/dist/utils/locks.js.map +1 -0
- package/dist/utils/maps.d.ts +61 -0
- package/dist/utils/maps.d.ts.map +1 -0
- package/dist/utils/maps.js +302 -0
- package/dist/utils/maps.js.map +1 -0
- package/dist/utils/math.d.ts +8 -0
- package/dist/utils/math.d.ts.map +1 -0
- package/dist/utils/math.js +23 -0
- package/dist/utils/math.js.map +1 -0
- package/dist/utils/monkey-patch.d.ts +7 -0
- package/dist/utils/monkey-patch.d.ts.map +1 -0
- package/dist/utils/monkey-patch.js +25 -0
- package/dist/utils/monkey-patch.js.map +1 -0
- package/dist/utils/node-http.d.ts +17 -0
- package/dist/utils/node-http.d.ts.map +1 -0
- package/dist/utils/node-http.js +40 -0
- package/dist/utils/node-http.js.map +1 -0
- package/dist/utils/numbers.d.ts +7 -0
- package/dist/utils/numbers.d.ts.map +1 -0
- package/dist/utils/numbers.js +79 -0
- package/dist/utils/numbers.js.map +1 -0
- package/dist/utils/oauth.d.ts +11 -0
- package/dist/utils/oauth.d.ts.map +1 -0
- package/dist/utils/oauth.js +32 -0
- package/dist/utils/oauth.js.map +1 -0
- package/dist/utils/objects.d.ts +59 -0
- package/dist/utils/objects.d.ts.map +1 -0
- package/dist/utils/objects.js +846 -0
- package/dist/utils/objects.js.map +1 -0
- package/dist/utils/paginated-lists.d.ts +442 -0
- package/dist/utils/paginated-lists.d.ts.map +1 -0
- package/dist/utils/paginated-lists.js +414 -0
- package/dist/utils/paginated-lists.js.map +1 -0
- package/dist/utils/paginated-lists.test.d.ts +1 -0
- package/dist/utils/paginated-lists.test.js +1304 -0
- package/dist/utils/paginated-lists.test.js.map +1 -0
- package/dist/utils/passkey.d.ts +2 -0
- package/dist/utils/passkey.js +0 -0
- package/dist/utils/promises.d.ts +80 -0
- package/dist/utils/promises.d.ts.map +1 -0
- package/dist/utils/promises.js +349 -0
- package/dist/utils/promises.js.map +1 -0
- package/dist/utils/proxies.d.ts +13 -0
- package/dist/utils/proxies.d.ts.map +1 -0
- package/dist/utils/proxies.js +201 -0
- package/dist/utils/proxies.js.map +1 -0
- package/dist/utils/react.d.ts +61 -0
- package/dist/utils/react.d.ts.map +1 -0
- package/dist/utils/react.js +243 -0
- package/dist/utils/react.js.map +1 -0
- package/dist/utils/redirect-urls.d.ts +30 -0
- package/dist/utils/redirect-urls.d.ts.map +1 -0
- package/dist/utils/redirect-urls.js +222 -0
- package/dist/utils/redirect-urls.js.map +1 -0
- package/dist/utils/regex.d.ts +5 -0
- package/dist/utils/regex.d.ts.map +1 -0
- package/dist/utils/regex.js +15 -0
- package/dist/utils/regex.js.map +1 -0
- package/dist/utils/results.d.ts +70 -0
- package/dist/utils/results.d.ts.map +1 -0
- package/dist/utils/results.js +342 -0
- package/dist/utils/results.js.map +1 -0
- package/dist/utils/sentry.d.ts +13 -0
- package/dist/utils/sentry.d.ts.map +1 -0
- package/dist/utils/sentry.js +16 -0
- package/dist/utils/sentry.js.map +1 -0
- package/dist/utils/stores.d.ts +104 -0
- package/dist/utils/stores.d.ts.map +1 -0
- package/dist/utils/stores.js +179 -0
- package/dist/utils/stores.js.map +1 -0
- package/dist/utils/strings.d.ts +76 -0
- package/dist/utils/strings.d.ts.map +1 -0
- package/dist/utils/strings.js +549 -0
- package/dist/utils/strings.js.map +1 -0
- package/dist/utils/strings.nicify.test.d.ts +1 -0
- package/dist/utils/strings.nicify.test.js +243 -0
- package/dist/utils/strings.nicify.test.js.map +1 -0
- package/dist/utils/telemetry.d.ts +15 -0
- package/dist/utils/telemetry.d.ts.map +1 -0
- package/dist/utils/telemetry.js +35 -0
- package/dist/utils/telemetry.js.map +1 -0
- package/dist/utils/turnstile-browser.d.ts +32 -0
- package/dist/utils/turnstile-browser.d.ts.map +1 -0
- package/dist/utils/turnstile-browser.js +65 -0
- package/dist/utils/turnstile-browser.js.map +1 -0
- package/dist/utils/turnstile-flow.d.ts +29 -0
- package/dist/utils/turnstile-flow.d.ts.map +1 -0
- package/dist/utils/turnstile-flow.js +225 -0
- package/dist/utils/turnstile-flow.js.map +1 -0
- package/dist/utils/turnstile-flow.test.d.ts +1 -0
- package/dist/utils/turnstile-flow.test.js +75 -0
- package/dist/utils/turnstile-flow.test.js.map +1 -0
- package/dist/utils/turnstile.d.ts +17 -0
- package/dist/utils/turnstile.d.ts.map +1 -0
- package/dist/utils/turnstile.js +31 -0
- package/dist/utils/turnstile.js.map +1 -0
- package/dist/utils/typed-arrays.d.ts +14 -0
- package/dist/utils/typed-arrays.d.ts.map +1 -0
- package/dist/utils/typed-arrays.js +22 -0
- package/dist/utils/typed-arrays.js.map +1 -0
- package/dist/utils/types.d.ts +77 -0
- package/dist/utils/types.d.ts.map +1 -0
- package/dist/utils/types.js +59 -0
- package/dist/utils/types.js.map +1 -0
- package/dist/utils/unicode.d.ts +5 -0
- package/dist/utils/unicode.d.ts.map +1 -0
- package/dist/utils/unicode.js +26 -0
- package/dist/utils/unicode.js.map +1 -0
- package/dist/utils/urls.d.ts +28 -0
- package/dist/utils/urls.d.ts.map +1 -0
- package/dist/utils/urls.js +274 -0
- package/dist/utils/urls.js.map +1 -0
- package/dist/utils/uuids.d.ts +6 -0
- package/dist/utils/uuids.d.ts.map +1 -0
- package/dist/utils/uuids.js +39 -0
- package/dist/utils/uuids.js.map +1 -0
- package/package.json +99 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
//#region src/utils/featurebase.d.ts
|
|
2
|
+
type FeaturebaseUser = {
|
|
3
|
+
userId: string;
|
|
4
|
+
email: string;
|
|
5
|
+
name?: string;
|
|
6
|
+
profilePicture?: string;
|
|
7
|
+
};
|
|
8
|
+
type StackAuthUser = {
|
|
9
|
+
id: string;
|
|
10
|
+
primaryEmail: string | null;
|
|
11
|
+
displayName?: string | null;
|
|
12
|
+
profileImageUrl?: string | null;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Get or create a Featurebase user based on Hexclave user data.
|
|
16
|
+
* This function ensures that:
|
|
17
|
+
* 1. We never change a user's email address on Featurebase
|
|
18
|
+
* 2. We use Hexclave user ID as the primary identifier
|
|
19
|
+
* 3. We handle email conflicts by using fallback emails
|
|
20
|
+
* 4. We update profile information when needed
|
|
21
|
+
*/
|
|
22
|
+
declare function getOrCreateFeaturebaseUser(stackAuthUser: StackAuthUser, options?: {
|
|
23
|
+
apiKey?: string;
|
|
24
|
+
}): Promise<{
|
|
25
|
+
userId: string;
|
|
26
|
+
email: string;
|
|
27
|
+
}>;
|
|
28
|
+
//#endregion
|
|
29
|
+
export { FeaturebaseUser, StackAuthUser, getOrCreateFeaturebaseUser };
|
|
30
|
+
//# sourceMappingURL=featurebase.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"featurebase.d.ts","names":[],"sources":["../../src/utils/featurebase.tsx"],"mappings":";KAGY,eAAA;EACV,MAAA;EACA,KAAA;EACA,IAAA;EACA,cAAA;AAAA;AAAA,KAGU,aAAA;EACV,EAAA;EACA,YAAA;EACA,WAAA;EACA,eAAA;AAAA;;;;;;;;;iBAgKoB,0BAAA,CACpB,aAAA,EAAe,aAAA,EACf,OAAA;EAAY,MAAA;AAAA,IACX,OAAA;EAAU,MAAA;EAAgB,KAAA;AAAA"}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_chunk = require('../chunk-BE-pF4vm.js');
|
|
3
|
+
let __errors_js = require("./errors.js");
|
|
4
|
+
let __env_js = require("./env.js");
|
|
5
|
+
|
|
6
|
+
//#region src/utils/featurebase.tsx
|
|
7
|
+
/**
|
|
8
|
+
* Find a Featurebase user by their Hexclave user ID
|
|
9
|
+
*/
|
|
10
|
+
async function findFeaturebaseUserById(stackAuthUserId, apiKey) {
|
|
11
|
+
try {
|
|
12
|
+
const response = await fetch(`https://do.featurebase.app/v2/organization/identifyUser?id=${stackAuthUserId}`, {
|
|
13
|
+
method: "GET",
|
|
14
|
+
headers: { "X-API-Key": apiKey }
|
|
15
|
+
});
|
|
16
|
+
if (response.status === 404) return null;
|
|
17
|
+
if (!response.ok) throw new __errors_js.HexclaveAssertionError(`Failed to find Featurebase user by ID: ${response.statusText}`);
|
|
18
|
+
const data = await response.json();
|
|
19
|
+
const user = data.user;
|
|
20
|
+
if (!user) throw new __errors_js.HexclaveAssertionError(`Featurebase API returned success but no user data for ID: ${stackAuthUserId}`, { data });
|
|
21
|
+
return {
|
|
22
|
+
userId: user.externalUserId || user.userId || stackAuthUserId,
|
|
23
|
+
email: user.email,
|
|
24
|
+
name: user.name,
|
|
25
|
+
profilePicture: user.profilePicture
|
|
26
|
+
};
|
|
27
|
+
} catch (error) {
|
|
28
|
+
if (error instanceof __errors_js.HexclaveAssertionError) throw error;
|
|
29
|
+
throw new __errors_js.HexclaveAssertionError("Failed to find Featurebase user by ID", { cause: error });
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Find a Featurebase user by their email address
|
|
34
|
+
*/
|
|
35
|
+
async function findFeaturebaseUserByEmail(email, apiKey) {
|
|
36
|
+
try {
|
|
37
|
+
const response = await fetch(`https://do.featurebase.app/v2/organization/identifyUser?email=${encodeURIComponent(email)}`, {
|
|
38
|
+
method: "GET",
|
|
39
|
+
headers: { "X-API-Key": apiKey }
|
|
40
|
+
});
|
|
41
|
+
if (response.status === 404) return null;
|
|
42
|
+
if (!response.ok) throw new __errors_js.HexclaveAssertionError(`Failed to find Featurebase user by email: ${response.statusText}`);
|
|
43
|
+
const data = await response.json();
|
|
44
|
+
const user = data.user;
|
|
45
|
+
if (!user) throw new __errors_js.HexclaveAssertionError(`Featurebase API returned success but no user data for email: ${email}`, { data });
|
|
46
|
+
return {
|
|
47
|
+
userId: user.externalUserId || user.userId,
|
|
48
|
+
email: user.email,
|
|
49
|
+
name: user.name,
|
|
50
|
+
profilePicture: user.profilePicture
|
|
51
|
+
};
|
|
52
|
+
} catch (error) {
|
|
53
|
+
console.error("Error finding Featurebase user by email:", error);
|
|
54
|
+
return null;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Create a new Featurebase user using the identifyUser endpoint
|
|
59
|
+
*/
|
|
60
|
+
async function createFeaturebaseUser(user, apiKey) {
|
|
61
|
+
try {
|
|
62
|
+
const response = await fetch("https://do.featurebase.app/v2/organization/identifyUser", {
|
|
63
|
+
method: "POST",
|
|
64
|
+
headers: {
|
|
65
|
+
"Content-Type": "application/json",
|
|
66
|
+
"X-API-Key": apiKey
|
|
67
|
+
},
|
|
68
|
+
body: JSON.stringify({
|
|
69
|
+
userId: user.userId,
|
|
70
|
+
email: user.email,
|
|
71
|
+
name: user.name,
|
|
72
|
+
profilePicture: user.profilePicture
|
|
73
|
+
})
|
|
74
|
+
});
|
|
75
|
+
if (!response.ok) {
|
|
76
|
+
const errorData = await response.json().catch(() => ({}));
|
|
77
|
+
throw new __errors_js.HexclaveAssertionError(`Failed to create Featurebase user: ${errorData.error || response.statusText}`, { errorData });
|
|
78
|
+
}
|
|
79
|
+
return user;
|
|
80
|
+
} catch (error) {
|
|
81
|
+
if (error instanceof __errors_js.HexclaveAssertionError) throw error;
|
|
82
|
+
throw new __errors_js.HexclaveAssertionError("Failed to create Featurebase user", { cause: error });
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* Update an existing Featurebase user (excluding email)
|
|
87
|
+
*/
|
|
88
|
+
async function updateFeaturebaseUser(userId, updates, apiKey) {
|
|
89
|
+
try {
|
|
90
|
+
const response = await fetch(`https://do.featurebase.app/v2/users/${userId}`, {
|
|
91
|
+
method: "PATCH",
|
|
92
|
+
headers: {
|
|
93
|
+
"Content-Type": "application/json",
|
|
94
|
+
"X-API-Key": apiKey
|
|
95
|
+
},
|
|
96
|
+
body: JSON.stringify(updates)
|
|
97
|
+
});
|
|
98
|
+
if (!response.ok) {
|
|
99
|
+
const errorData = await response.json().catch(() => ({}));
|
|
100
|
+
throw new __errors_js.HexclaveAssertionError(`Failed to update Featurebase user: ${errorData.error || response.statusText}`, { errorData });
|
|
101
|
+
}
|
|
102
|
+
const data = await response.json();
|
|
103
|
+
return {
|
|
104
|
+
userId: data.userId || userId,
|
|
105
|
+
email: data.email,
|
|
106
|
+
name: data.name,
|
|
107
|
+
profilePicture: data.profilePicture
|
|
108
|
+
};
|
|
109
|
+
} catch (error) {
|
|
110
|
+
if (error instanceof __errors_js.HexclaveAssertionError) throw error;
|
|
111
|
+
throw new __errors_js.HexclaveAssertionError("Failed to update Featurebase user", { cause: error });
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* Get or create a Featurebase user based on Hexclave user data.
|
|
116
|
+
* This function ensures that:
|
|
117
|
+
* 1. We never change a user's email address on Featurebase
|
|
118
|
+
* 2. We use Hexclave user ID as the primary identifier
|
|
119
|
+
* 3. We handle email conflicts by using fallback emails
|
|
120
|
+
* 4. We update profile information when needed
|
|
121
|
+
*/
|
|
122
|
+
async function getOrCreateFeaturebaseUser(stackAuthUser, options) {
|
|
123
|
+
const apiKey = options?.apiKey || (0, __env_js.getEnvVariable)("STACK_FEATUREBASE_API_KEY");
|
|
124
|
+
const fallbackEmail = `${stackAuthUser.id}@featurebase-user.stack-auth-app.com`;
|
|
125
|
+
const existingById = await findFeaturebaseUserById(stackAuthUser.id, apiKey);
|
|
126
|
+
if (existingById) {
|
|
127
|
+
let ensuredEmail = existingById.email;
|
|
128
|
+
if (!ensuredEmail) try {
|
|
129
|
+
await createFeaturebaseUser({
|
|
130
|
+
userId: existingById.userId,
|
|
131
|
+
email: fallbackEmail,
|
|
132
|
+
name: stackAuthUser.displayName || void 0,
|
|
133
|
+
profilePicture: stackAuthUser.profileImageUrl || void 0
|
|
134
|
+
}, apiKey);
|
|
135
|
+
ensuredEmail = fallbackEmail;
|
|
136
|
+
} catch (e) {
|
|
137
|
+
throw new __errors_js.HexclaveAssertionError(`Failed to set fallback email for existing Featurebase user ${existingById.userId}`, { cause: e });
|
|
138
|
+
}
|
|
139
|
+
try {
|
|
140
|
+
const updates = {};
|
|
141
|
+
if (stackAuthUser.displayName && stackAuthUser.displayName !== existingById.name) updates.name = stackAuthUser.displayName;
|
|
142
|
+
if (stackAuthUser.profileImageUrl && stackAuthUser.profileImageUrl !== existingById.profilePicture) updates.profilePicture = stackAuthUser.profileImageUrl;
|
|
143
|
+
if (Object.keys(updates).length > 0) await updateFeaturebaseUser(existingById.userId, updates, apiKey);
|
|
144
|
+
} catch (error) {
|
|
145
|
+
console.error("Failed to update existing Featurebase user profile:", error);
|
|
146
|
+
}
|
|
147
|
+
return {
|
|
148
|
+
userId: existingById.userId,
|
|
149
|
+
email: ensuredEmail
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
const candidateEmail = stackAuthUser.primaryEmail ?? fallbackEmail;
|
|
153
|
+
const safeEmail = await findFeaturebaseUserByEmail(candidateEmail, apiKey) ? fallbackEmail : candidateEmail;
|
|
154
|
+
const created = await createFeaturebaseUser({
|
|
155
|
+
userId: stackAuthUser.id,
|
|
156
|
+
email: safeEmail,
|
|
157
|
+
name: stackAuthUser.displayName || stackAuthUser.primaryEmail?.split("@")[0] || "User",
|
|
158
|
+
profilePicture: stackAuthUser.profileImageUrl || void 0
|
|
159
|
+
}, apiKey);
|
|
160
|
+
return {
|
|
161
|
+
userId: created.userId,
|
|
162
|
+
email: created.email
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
//#endregion
|
|
167
|
+
exports.getOrCreateFeaturebaseUser = getOrCreateFeaturebaseUser;
|
|
168
|
+
//# sourceMappingURL=featurebase.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"featurebase.js","names":["HexclaveAssertionError"],"sources":["../../src/utils/featurebase.tsx"],"sourcesContent":["import { getEnvVariable } from \"./env\";\nimport { HexclaveAssertionError } from \"./errors\";\n\nexport type FeaturebaseUser = {\n userId: string,\n email: string,\n name?: string,\n profilePicture?: string,\n};\n\nexport type StackAuthUser = {\n id: string,\n primaryEmail: string | null,\n displayName?: string | null,\n profileImageUrl?: string | null,\n};\n\n/**\n * Find a Featurebase user by their Hexclave user ID\n */\nasync function findFeaturebaseUserById(stackAuthUserId: string, apiKey: string): Promise<FeaturebaseUser | null> {\n try {\n const response = await fetch(`https://do.featurebase.app/v2/organization/identifyUser?id=${stackAuthUserId}`, {\n method: 'GET',\n headers: {\n 'X-API-Key': apiKey,\n },\n });\n\n if (response.status === 404) {\n return null;\n }\n\n if (!response.ok) {\n throw new HexclaveAssertionError(`Failed to find Featurebase user by ID: ${response.statusText}`);\n }\n\n const data = await response.json();\n const user = data.user;\n\n if (!user) {\n throw new HexclaveAssertionError(`Featurebase API returned success but no user data for ID: ${stackAuthUserId}`, { data });\n }\n\n return {\n userId: user.externalUserId || user.userId || stackAuthUserId,\n email: user.email,\n name: user.name,\n profilePicture: user.profilePicture,\n };\n } catch (error) {\n if (error instanceof HexclaveAssertionError) {\n throw error;\n }\n throw new HexclaveAssertionError(\"Failed to find Featurebase user by ID\", { cause: error });\n }\n}\n\n/**\n * Find a Featurebase user by their email address\n */\nasync function findFeaturebaseUserByEmail(email: string, apiKey: string): Promise<FeaturebaseUser | null> {\n try {\n const response = await fetch(`https://do.featurebase.app/v2/organization/identifyUser?email=${encodeURIComponent(email)}`, {\n method: 'GET',\n headers: {\n 'X-API-Key': apiKey,\n },\n });\n\n if (response.status === 404) {\n return null;\n }\n\n if (!response.ok) {\n throw new HexclaveAssertionError(`Failed to find Featurebase user by email: ${response.statusText}`);\n }\n\n const data = await response.json();\n const user = data.user;\n\n if (!user) {\n throw new HexclaveAssertionError(`Featurebase API returned success but no user data for email: ${email}`, { data });\n }\n\n return {\n userId: user.externalUserId || user.userId,\n email: user.email,\n name: user.name,\n profilePicture: user.profilePicture,\n };\n } catch (error) {\n console.error('Error finding Featurebase user by email:', error);\n return null;\n }\n}\n\n/**\n * Create a new Featurebase user using the identifyUser endpoint\n */\nasync function createFeaturebaseUser(user: FeaturebaseUser, apiKey: string): Promise<FeaturebaseUser> {\n try {\n const response = await fetch('https://do.featurebase.app/v2/organization/identifyUser', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json',\n 'X-API-Key': apiKey,\n },\n body: JSON.stringify({\n userId: user.userId,\n email: user.email,\n name: user.name,\n profilePicture: user.profilePicture,\n }),\n });\n\n if (!response.ok) {\n const errorData = await response.json().catch(() => ({}));\n throw new HexclaveAssertionError(`Failed to create Featurebase user: ${errorData.error || response.statusText}`, { errorData });\n }\n\n // The identifyUser endpoint just returns { \"success\": true }, so we return the input data\n return user;\n } catch (error) {\n if (error instanceof HexclaveAssertionError) {\n throw error;\n }\n throw new HexclaveAssertionError(\"Failed to create Featurebase user\", { cause: error });\n\n }\n}\n\n/**\n * Update an existing Featurebase user (excluding email)\n */\nasync function updateFeaturebaseUser(userId: string, updates: Partial<Omit<FeaturebaseUser, 'userId' | 'email'>>, apiKey: string): Promise<FeaturebaseUser> {\n try {\n const response = await fetch(`https://do.featurebase.app/v2/users/${userId}`, {\n method: 'PATCH',\n headers: {\n 'Content-Type': 'application/json',\n 'X-API-Key': apiKey,\n },\n body: JSON.stringify(updates),\n });\n\n if (!response.ok) {\n const errorData = await response.json().catch(() => ({}));\n throw new HexclaveAssertionError(`Failed to update Featurebase user: ${errorData.error || response.statusText}`, { errorData });\n }\n\n const data = await response.json();\n return {\n userId: data.userId || userId,\n email: data.email,\n name: data.name,\n profilePicture: data.profilePicture,\n };\n } catch (error) {\n if (error instanceof HexclaveAssertionError) {\n throw error;\n }\n throw new HexclaveAssertionError(\"Failed to update Featurebase user\", { cause: error });\n }\n}\n\n/**\n * Get or create a Featurebase user based on Hexclave user data.\n * This function ensures that:\n * 1. We never change a user's email address on Featurebase\n * 2. We use Hexclave user ID as the primary identifier\n * 3. We handle email conflicts by using fallback emails\n * 4. We update profile information when needed\n */\nexport async function getOrCreateFeaturebaseUser(\n stackAuthUser: StackAuthUser,\n options?: { apiKey?: string }\n): Promise<{ userId: string, email: string }> {\n const apiKey = options?.apiKey || getEnvVariable(\"STACK_FEATUREBASE_API_KEY\");\n const fallbackEmail = `${stackAuthUser.id}@featurebase-user.stack-auth-app.com`;\n\n // First, try to find existing user by Hexclave user ID\n const existingById = await findFeaturebaseUserById(stackAuthUser.id, apiKey);\n if (existingById) {\n // Ensure the user has an email on Featurebase.\n let ensuredEmail = existingById.email;\n if (!ensuredEmail) {\n try {\n await createFeaturebaseUser({\n userId: existingById.userId,\n email: fallbackEmail,\n name: stackAuthUser.displayName || undefined,\n profilePicture: stackAuthUser.profileImageUrl || undefined,\n }, apiKey);\n ensuredEmail = fallbackEmail;\n } catch (e) {\n // If setting fallback email failed, keep ensuredEmail as-is (undefined) and let callers handle\n throw new HexclaveAssertionError(`Failed to set fallback email for existing Featurebase user ${existingById.userId}`, { cause: e });\n }\n }\n\n // Update profile information if needed (but not email)\n try {\n const updates: Partial<Omit<FeaturebaseUser, 'userId' | 'email'>> = {};\n\n if (stackAuthUser.displayName && stackAuthUser.displayName !== existingById.name) {\n updates.name = stackAuthUser.displayName;\n }\n\n if (stackAuthUser.profileImageUrl && stackAuthUser.profileImageUrl !== existingById.profilePicture) {\n updates.profilePicture = stackAuthUser.profileImageUrl;\n }\n\n if (Object.keys(updates).length > 0) {\n await updateFeaturebaseUser(existingById.userId, updates, apiKey);\n }\n } catch (error) {\n console.error('Failed to update existing Featurebase user profile:', error);\n // Continue with existing user data even if update fails\n }\n\n return {\n userId: existingById.userId,\n email: ensuredEmail,\n };\n }\n\n // No existing user found by ID, need to create one\n const candidateEmail = stackAuthUser.primaryEmail ?? fallbackEmail;\n\n // Check if someone already has this email on Featurebase\n const existingByEmail = await findFeaturebaseUserByEmail(candidateEmail, apiKey);\n const safeEmail = existingByEmail ? fallbackEmail : candidateEmail;\n\n // Create new user\n const created = await createFeaturebaseUser({\n userId: stackAuthUser.id,\n email: safeEmail,\n name: stackAuthUser.displayName || stackAuthUser.primaryEmail?.split('@')[0] || 'User',\n profilePicture: stackAuthUser.profileImageUrl || undefined,\n }, apiKey);\n\n return {\n userId: created.userId,\n email: created.email,\n };\n}\n"],"mappings":";;;;;;;;;AAoBA,eAAe,wBAAwB,iBAAyB,QAAiD;AAC/G,KAAI;EACF,MAAM,WAAW,MAAM,MAAM,8DAA8D,mBAAmB;GAC5G,QAAQ;GACR,SAAS,EACP,aAAa,QACd;GACF,CAAC;AAEF,MAAI,SAAS,WAAW,IACtB,QAAO;AAGT,MAAI,CAAC,SAAS,GACZ,OAAM,IAAIA,mCAAuB,0CAA0C,SAAS,aAAa;EAGnG,MAAM,OAAO,MAAM,SAAS,MAAM;EAClC,MAAM,OAAO,KAAK;AAElB,MAAI,CAAC,KACH,OAAM,IAAIA,mCAAuB,6DAA6D,mBAAmB,EAAE,MAAM,CAAC;AAG5H,SAAO;GACL,QAAQ,KAAK,kBAAkB,KAAK,UAAU;GAC9C,OAAO,KAAK;GACZ,MAAM,KAAK;GACX,gBAAgB,KAAK;GACtB;UACM,OAAO;AACd,MAAI,iBAAiBA,mCACnB,OAAM;AAER,QAAM,IAAIA,mCAAuB,yCAAyC,EAAE,OAAO,OAAO,CAAC;;;;;;AAO/F,eAAe,2BAA2B,OAAe,QAAiD;AACxG,KAAI;EACF,MAAM,WAAW,MAAM,MAAM,iEAAiE,mBAAmB,MAAM,IAAI;GACzH,QAAQ;GACR,SAAS,EACP,aAAa,QACd;GACF,CAAC;AAEF,MAAI,SAAS,WAAW,IACtB,QAAO;AAGT,MAAI,CAAC,SAAS,GACZ,OAAM,IAAIA,mCAAuB,6CAA6C,SAAS,aAAa;EAGtG,MAAM,OAAO,MAAM,SAAS,MAAM;EAClC,MAAM,OAAO,KAAK;AAElB,MAAI,CAAC,KACH,OAAM,IAAIA,mCAAuB,gEAAgE,SAAS,EAAE,MAAM,CAAC;AAGrH,SAAO;GACL,QAAQ,KAAK,kBAAkB,KAAK;GACpC,OAAO,KAAK;GACZ,MAAM,KAAK;GACX,gBAAgB,KAAK;GACtB;UACM,OAAO;AACd,UAAQ,MAAM,4CAA4C,MAAM;AAChE,SAAO;;;;;;AAOX,eAAe,sBAAsB,MAAuB,QAA0C;AACpG,KAAI;EACF,MAAM,WAAW,MAAM,MAAM,2DAA2D;GACtF,QAAQ;GACR,SAAS;IACP,gBAAgB;IAChB,aAAa;IACd;GACD,MAAM,KAAK,UAAU;IACnB,QAAQ,KAAK;IACb,OAAO,KAAK;IACZ,MAAM,KAAK;IACX,gBAAgB,KAAK;IACtB,CAAC;GACH,CAAC;AAEF,MAAI,CAAC,SAAS,IAAI;GAChB,MAAM,YAAY,MAAM,SAAS,MAAM,CAAC,aAAa,EAAE,EAAE;AACzD,SAAM,IAAIA,mCAAuB,sCAAsC,UAAU,SAAS,SAAS,cAAc,EAAE,WAAW,CAAC;;AAIjI,SAAO;UACA,OAAO;AACd,MAAI,iBAAiBA,mCACnB,OAAM;AAER,QAAM,IAAIA,mCAAuB,qCAAqC,EAAE,OAAO,OAAO,CAAC;;;;;;AAQ3F,eAAe,sBAAsB,QAAgB,SAA6D,QAA0C;AAC1J,KAAI;EACF,MAAM,WAAW,MAAM,MAAM,uCAAuC,UAAU;GAC5E,QAAQ;GACR,SAAS;IACP,gBAAgB;IAChB,aAAa;IACd;GACD,MAAM,KAAK,UAAU,QAAQ;GAC9B,CAAC;AAEF,MAAI,CAAC,SAAS,IAAI;GAChB,MAAM,YAAY,MAAM,SAAS,MAAM,CAAC,aAAa,EAAE,EAAE;AACzD,SAAM,IAAIA,mCAAuB,sCAAsC,UAAU,SAAS,SAAS,cAAc,EAAE,WAAW,CAAC;;EAGjI,MAAM,OAAO,MAAM,SAAS,MAAM;AAClC,SAAO;GACL,QAAQ,KAAK,UAAU;GACvB,OAAO,KAAK;GACZ,MAAM,KAAK;GACX,gBAAgB,KAAK;GACtB;UACM,OAAO;AACd,MAAI,iBAAiBA,mCACnB,OAAM;AAER,QAAM,IAAIA,mCAAuB,qCAAqC,EAAE,OAAO,OAAO,CAAC;;;;;;;;;;;AAY3F,eAAsB,2BACpB,eACA,SAC4C;CAC5C,MAAM,SAAS,SAAS,uCAAyB,4BAA4B;CAC7E,MAAM,gBAAgB,GAAG,cAAc,GAAG;CAG1C,MAAM,eAAe,MAAM,wBAAwB,cAAc,IAAI,OAAO;AAC5E,KAAI,cAAc;EAEhB,IAAI,eAAe,aAAa;AAChC,MAAI,CAAC,aACH,KAAI;AACF,SAAM,sBAAsB;IAC1B,QAAQ,aAAa;IACrB,OAAO;IACP,MAAM,cAAc,eAAe;IACnC,gBAAgB,cAAc,mBAAmB;IAClD,EAAE,OAAO;AACV,kBAAe;WACR,GAAG;AAEV,SAAM,IAAIA,mCAAuB,8DAA8D,aAAa,UAAU,EAAE,OAAO,GAAG,CAAC;;AAKvI,MAAI;GACF,MAAM,UAA8D,EAAE;AAEtE,OAAI,cAAc,eAAe,cAAc,gBAAgB,aAAa,KAC1E,SAAQ,OAAO,cAAc;AAG/B,OAAI,cAAc,mBAAmB,cAAc,oBAAoB,aAAa,eAClF,SAAQ,iBAAiB,cAAc;AAGzC,OAAI,OAAO,KAAK,QAAQ,CAAC,SAAS,EAChC,OAAM,sBAAsB,aAAa,QAAQ,SAAS,OAAO;WAE5D,OAAO;AACd,WAAQ,MAAM,uDAAuD,MAAM;;AAI7E,SAAO;GACL,QAAQ,aAAa;GACrB,OAAO;GACR;;CAIH,MAAM,iBAAiB,cAAc,gBAAgB;CAIrD,MAAM,YADkB,MAAM,2BAA2B,gBAAgB,OAAO,GAC5C,gBAAgB;CAGpD,MAAM,UAAU,MAAM,sBAAsB;EAC1C,QAAQ,cAAc;EACtB,OAAO;EACP,MAAM,cAAc,eAAe,cAAc,cAAc,MAAM,IAAI,CAAC,MAAM;EAChF,gBAAgB,cAAc,mBAAmB;EAClD,EAAE,OAAO;AAEV,QAAO;EACL,QAAQ,QAAQ;EAChB,OAAO,QAAQ;EAChB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
//#region src/utils/fs.d.ts
|
|
2
|
+
declare function list(path: string): Promise<string[]>;
|
|
3
|
+
declare function listRecursively(p: string, options?: {
|
|
4
|
+
excludeDirectories?: boolean;
|
|
5
|
+
}): Promise<string[]>;
|
|
6
|
+
declare function writeFileSyncIfChanged(path: string, content: string): void;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { list, listRecursively, writeFileSyncIfChanged };
|
|
9
|
+
//# sourceMappingURL=fs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fs.d.ts","names":[],"sources":["../../src/utils/fs.tsx"],"mappings":";iBAGsB,IAAA,CAAK,IAAA,WAAY,OAAA;AAAA,iBAIjB,eAAA,CAAgB,CAAA,UAAW,OAAA;EAAW,kBAAA;AAAA,IAAsC,OAAA;AAAA,iBAiBlF,sBAAA,CAAuB,IAAA,UAAc,OAAA"}
|
package/dist/utils/fs.js
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_chunk = require('../chunk-BE-pF4vm.js');
|
|
3
|
+
let fs = require("fs");
|
|
4
|
+
fs = require_chunk.__toESM(fs);
|
|
5
|
+
let path = require("path");
|
|
6
|
+
path = require_chunk.__toESM(path);
|
|
7
|
+
|
|
8
|
+
//#region src/utils/fs.tsx
|
|
9
|
+
async function list(path$1) {
|
|
10
|
+
return await fs.promises.readdir(path$1);
|
|
11
|
+
}
|
|
12
|
+
async function listRecursively(p, options = {}) {
|
|
13
|
+
const files = await list(p);
|
|
14
|
+
return [...(await Promise.all(files.map(async (fileName) => {
|
|
15
|
+
const filePath = path.join(p, fileName);
|
|
16
|
+
if ((await fs.promises.stat(filePath)).isDirectory()) return [...await listRecursively(filePath, options), ...options.excludeDirectories ? [] : [filePath]];
|
|
17
|
+
else return [filePath];
|
|
18
|
+
}))).flat()];
|
|
19
|
+
}
|
|
20
|
+
function writeFileSyncIfChanged(path$2, content) {
|
|
21
|
+
if (fs.existsSync(path$2)) {
|
|
22
|
+
if (fs.readFileSync(path$2, "utf-8") === content) return;
|
|
23
|
+
}
|
|
24
|
+
fs.writeFileSync(path$2, content);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
//#endregion
|
|
28
|
+
exports.list = list;
|
|
29
|
+
exports.listRecursively = listRecursively;
|
|
30
|
+
exports.writeFileSyncIfChanged = writeFileSyncIfChanged;
|
|
31
|
+
//# sourceMappingURL=fs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fs.js","names":["stackFs","path"],"sources":["../../src/utils/fs.tsx"],"sourcesContent":["import * as stackFs from \"fs\";\nimport * as path from \"path\";\n\nexport async function list(path: string) {\n return await stackFs.promises.readdir(path);\n}\n\nexport async function listRecursively(p: string, options: { excludeDirectories?: boolean } = {}): Promise<string[]> {\n const files = await list(p);\n return [\n ...(await Promise.all(files.map(async (fileName) => {\n const filePath = path.join(p, fileName);\n if ((await stackFs.promises.stat(filePath)).isDirectory()) {\n return [\n ...(await listRecursively(filePath, options)),\n ...(options.excludeDirectories ? [] : [filePath]),\n ];\n } else {\n return [filePath];\n }\n }))).flat(),\n ];\n}\n\nexport function writeFileSyncIfChanged(path: string, content: string): void {\n if (stackFs.existsSync(path)) {\n const existingContent = stackFs.readFileSync(path, \"utf-8\");\n if (existingContent === content) {\n return;\n }\n }\n stackFs.writeFileSync(path, content);\n}\n"],"mappings":";;;;;;;;AAGA,eAAsB,KAAK,QAAc;AACvC,QAAO,MAAMA,GAAQ,SAAS,QAAQC,OAAK;;AAG7C,eAAsB,gBAAgB,GAAW,UAA4C,EAAE,EAAqB;CAClH,MAAM,QAAQ,MAAM,KAAK,EAAE;AAC3B,QAAO,CACL,IAAI,MAAM,QAAQ,IAAI,MAAM,IAAI,OAAO,aAAa;EAClD,MAAM,WAAW,KAAK,KAAK,GAAG,SAAS;AACvC,OAAK,MAAMD,GAAQ,SAAS,KAAK,SAAS,EAAE,aAAa,CACvD,QAAO,CACL,GAAI,MAAM,gBAAgB,UAAU,QAAQ,EAC5C,GAAI,QAAQ,qBAAqB,EAAE,GAAG,CAAC,SAAS,CACjD;MAED,QAAO,CAAC,SAAS;GAEnB,CAAC,EAAE,MAAM,CACZ;;AAGH,SAAgB,uBAAuB,QAAc,SAAuB;AAC1E,KAAIA,GAAQ,WAAWC,OAAK,EAE1B;MADwBD,GAAQ,aAAaC,QAAM,QAAQ,KACnC,QACtB;;AAGJ,IAAQ,cAAcA,QAAM,QAAQ"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"functions.d.ts","names":[],"sources":["../../src/utils/functions.tsx"],"mappings":";iBAAgB,QAAA,GAAA,CAAY,CAAA,EAAG,CAAA,GAAI,CAAA;AAAA,iBAYnB,YAAA,iBAAA,CAAA,GAAiC,IAAA,EAAM,CAAA,GAAI,CAAA"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
|
|
3
|
+
//#region src/utils/functions.tsx
|
|
4
|
+
function identity(t) {
|
|
5
|
+
return t;
|
|
6
|
+
}
|
|
7
|
+
(void 0)?.test("identity", ({ expect }) => {
|
|
8
|
+
expect(identity(1)).toBe(1);
|
|
9
|
+
expect(identity("test")).toBe("test");
|
|
10
|
+
expect(identity(null)).toBe(null);
|
|
11
|
+
expect(identity(void 0)).toBe(void 0);
|
|
12
|
+
const obj = { a: 1 };
|
|
13
|
+
expect(identity(obj)).toBe(obj);
|
|
14
|
+
});
|
|
15
|
+
function identityArgs(...args) {
|
|
16
|
+
return args;
|
|
17
|
+
}
|
|
18
|
+
(void 0)?.test("identityArgs", ({ expect }) => {
|
|
19
|
+
expect(identityArgs()).toEqual([]);
|
|
20
|
+
expect(identityArgs(1)).toEqual([1]);
|
|
21
|
+
expect(identityArgs(1, 2, 3)).toEqual([
|
|
22
|
+
1,
|
|
23
|
+
2,
|
|
24
|
+
3
|
|
25
|
+
]);
|
|
26
|
+
expect(identityArgs("a", "b", "c")).toEqual([
|
|
27
|
+
"a",
|
|
28
|
+
"b",
|
|
29
|
+
"c"
|
|
30
|
+
]);
|
|
31
|
+
expect(identityArgs(null, void 0)).toEqual([null, void 0]);
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
//#endregion
|
|
35
|
+
exports.identity = identity;
|
|
36
|
+
exports.identityArgs = identityArgs;
|
|
37
|
+
//# sourceMappingURL=functions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"functions.js","names":[],"sources":["../../src/utils/functions.tsx"],"sourcesContent":["export function identity<T>(t: T): T {\n return t;\n}\nimport.meta.vitest?.test(\"identity\", ({ expect }) => {\n expect(identity(1)).toBe(1);\n expect(identity(\"test\")).toBe(\"test\");\n expect(identity(null)).toBe(null);\n expect(identity(undefined)).toBe(undefined);\n const obj = { a: 1 };\n expect(identity(obj)).toBe(obj);\n});\n\nexport function identityArgs<T extends any[]>(...args: T): T {\n return args;\n}\nimport.meta.vitest?.test(\"identityArgs\", ({ expect }) => {\n expect(identityArgs()).toEqual([]);\n expect(identityArgs(1)).toEqual([1]);\n expect(identityArgs(1, 2, 3)).toEqual([1, 2, 3]);\n expect(identityArgs(\"a\", \"b\", \"c\")).toEqual([\"a\", \"b\", \"c\"]);\n expect(identityArgs(null, undefined)).toEqual([null, undefined]);\n});\n"],"mappings":";;;AAAA,SAAgB,SAAY,GAAS;AACnC,QAAO;;CAET,SAAW,KAAC,aAAc,EAAA,aAAc;AACtC,QAAO,SAAS,EAAE,CAAC,CAAC,KAAK,EAAE;AAC3B,QAAO,SAAS,OAAO,CAAC,CAAC,KAAK,OAAO;AACrC,QAAO,SAAS,KAAK,CAAC,CAAC,KAAK,KAAK;AACjC,QAAO,SAAS,OAAU,CAAC,CAAC,KAAK,OAAU;CAC3C,MAAM,MAAM,EAAE,GAAG,GAAG;AACpB,QAAO,SAAS,IAAI,CAAC,CAAC,KAAK,IAAI;EAC/B;AAEF,SAAgB,aAA8B,GAAG,MAAY;AAC3D,QAAO;;CAET,SAAW,KAAC,iBAAc,EAAA,aAAkB;AAC1C,QAAO,cAAc,CAAC,CAAC,QAAQ,EAAE,CAAC;AAClC,QAAO,aAAa,EAAE,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC;AACpC,QAAO,aAAa,GAAG,GAAG,EAAE,CAAC,CAAC,QAAQ;EAAC;EAAG;EAAG;EAAE,CAAC;AAChD,QAAO,aAAa,KAAK,KAAK,IAAI,CAAC,CAAC,QAAQ;EAAC;EAAK;EAAK;EAAI,CAAC;AAC5D,QAAO,aAAa,MAAM,OAAU,CAAC,CAAC,QAAQ,CAAC,MAAM,OAAU,CAAC;EAChE"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import * as yup$1 from "yup";
|
|
2
|
+
|
|
3
|
+
//#region src/utils/geo.d.ts
|
|
4
|
+
declare const geoInfoSchema: yup$1.ObjectSchema<{
|
|
5
|
+
ip: string;
|
|
6
|
+
countryCode: string | null | undefined;
|
|
7
|
+
regionCode: string | null | undefined;
|
|
8
|
+
cityName: string | null | undefined;
|
|
9
|
+
latitude: number | null | undefined;
|
|
10
|
+
longitude: number | null | undefined;
|
|
11
|
+
tzIdentifier: string | null | undefined;
|
|
12
|
+
}, yup$1.AnyObject, {
|
|
13
|
+
ip: undefined;
|
|
14
|
+
countryCode: undefined;
|
|
15
|
+
regionCode: undefined;
|
|
16
|
+
cityName: undefined;
|
|
17
|
+
latitude: undefined;
|
|
18
|
+
longitude: undefined;
|
|
19
|
+
tzIdentifier: undefined;
|
|
20
|
+
}, "">;
|
|
21
|
+
type GeoInfo = yup$1.InferType<typeof geoInfoSchema>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { GeoInfo, geoInfoSchema };
|
|
24
|
+
//# sourceMappingURL=geo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geo.d.ts","names":[],"sources":["../../src/utils/geo.tsx"],"mappings":";;;cAIa,aAAA,EAAa,KAAA,CAAA,YAAA;;;;;;;;GAQxB,KAAA,CAAA,SAAA;;;;;;;;;KAEU,OAAA,GAAU,KAAA,CAAI,SAAA,QAAiB,aAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_chunk = require('../chunk-BE-pF4vm.js');
|
|
3
|
+
let ___schema_fields_js = require("../schema-fields.js");
|
|
4
|
+
|
|
5
|
+
//#region src/utils/geo.tsx
|
|
6
|
+
const geoInfoSchema = (0, ___schema_fields_js.yupObject)({
|
|
7
|
+
ip: (0, ___schema_fields_js.yupString)().defined(),
|
|
8
|
+
countryCode: (0, ___schema_fields_js.yupString)().nullable(),
|
|
9
|
+
regionCode: (0, ___schema_fields_js.yupString)().nullable(),
|
|
10
|
+
cityName: (0, ___schema_fields_js.yupString)().nullable(),
|
|
11
|
+
latitude: (0, ___schema_fields_js.yupNumber)().nullable(),
|
|
12
|
+
longitude: (0, ___schema_fields_js.yupNumber)().nullable(),
|
|
13
|
+
tzIdentifier: (0, ___schema_fields_js.yupString)().nullable()
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
//#endregion
|
|
17
|
+
exports.geoInfoSchema = geoInfoSchema;
|
|
18
|
+
//# sourceMappingURL=geo.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geo.js","names":[],"sources":["../../src/utils/geo.tsx"],"sourcesContent":["\nimport * as yup from \"yup\";\nimport { yupNumber, yupObject, yupString } from \"../schema-fields\";\n\nexport const geoInfoSchema = yupObject({\n ip: yupString().defined(),\n countryCode: yupString().nullable(),\n regionCode: yupString().nullable(),\n cityName: yupString().nullable(),\n latitude: yupNumber().nullable(),\n longitude: yupNumber().nullable(),\n tzIdentifier: yupString().nullable(),\n});\n\nexport type GeoInfo = yup.InferType<typeof geoInfoSchema>;\n\n"],"mappings":";;;;;AAIA,MAAa,mDAA0B;CACrC,wCAAe,CAAC,SAAS;CACzB,iDAAwB,CAAC,UAAU;CACnC,gDAAuB,CAAC,UAAU;CAClC,8CAAqB,CAAC,UAAU;CAChC,8CAAqB,CAAC,UAAU;CAChC,+CAAsB,CAAC,UAAU;CACjC,kDAAyB,CAAC,UAAU;CACrC,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
//#region src/utils/globals.d.ts
|
|
2
|
+
declare const globalVar: any;
|
|
3
|
+
declare function createGlobal<T>(key: string, init: () => T): T;
|
|
4
|
+
/**
|
|
5
|
+
* Like createGlobal, but if the asynchronous initialization fails, the global will be reset and recomputed on the next
|
|
6
|
+
* invocation.
|
|
7
|
+
*/
|
|
8
|
+
declare function createGlobalAsync<T>(key: string, init: () => Promise<T>): Promise<T>;
|
|
9
|
+
declare function getGlobal(key: string): any;
|
|
10
|
+
declare function setGlobal(key: string, value: any): void;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { createGlobal, createGlobalAsync, getGlobal, globalVar, setGlobal };
|
|
13
|
+
//# sourceMappingURL=globals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"globals.d.ts","names":[],"sources":["../../src/utils/globals.tsx"],"mappings":";cAAM,SAAA;AAAA,iBAkBU,YAAA,GAAA,CAAgB,GAAA,UAAa,IAAA,QAAY,CAAA,GAIV,CAAA;;;;AAJ/C;iBAWgB,iBAAA,GAAA,CAAqB,GAAA,UAAa,IAAA,QAAY,OAAA,CAAQ,CAAA,IAAK,OAAA,CAAQ,CAAA;AAAA,iBAYnE,SAAA,CAAU,GAAA;AAAA,iBAIV,SAAA,CAAU,GAAA,UAAa,KAAA"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
|
|
3
|
+
//#region src/utils/globals.tsx
|
|
4
|
+
const globalVar = typeof globalThis !== "undefined" ? globalThis : typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : {};
|
|
5
|
+
if (typeof globalThis === "undefined") globalVar.globalThis = globalVar;
|
|
6
|
+
const stackGlobalsSymbol = Symbol.for("__hexclave-globals");
|
|
7
|
+
globalVar[stackGlobalsSymbol] ??= {};
|
|
8
|
+
function createGlobal(key, init) {
|
|
9
|
+
if (!globalVar[stackGlobalsSymbol][key]) globalVar[stackGlobalsSymbol][key] = init();
|
|
10
|
+
return globalVar[stackGlobalsSymbol][key];
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Like createGlobal, but if the asynchronous initialization fails, the global will be reset and recomputed on the next
|
|
14
|
+
* invocation.
|
|
15
|
+
*/
|
|
16
|
+
function createGlobalAsync(key, init) {
|
|
17
|
+
let promise = null;
|
|
18
|
+
if (!globalVar[stackGlobalsSymbol][key]) {
|
|
19
|
+
promise = init().catch((e) => {
|
|
20
|
+
delete globalVar[stackGlobalsSymbol][key];
|
|
21
|
+
throw e;
|
|
22
|
+
});
|
|
23
|
+
globalVar[stackGlobalsSymbol][key] = promise;
|
|
24
|
+
}
|
|
25
|
+
return promise ?? globalVar[stackGlobalsSymbol][key];
|
|
26
|
+
}
|
|
27
|
+
function getGlobal(key) {
|
|
28
|
+
return globalVar[stackGlobalsSymbol][key];
|
|
29
|
+
}
|
|
30
|
+
function setGlobal(key, value) {
|
|
31
|
+
globalVar[stackGlobalsSymbol][key] = value;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
//#endregion
|
|
35
|
+
exports.createGlobal = createGlobal;
|
|
36
|
+
exports.createGlobalAsync = createGlobalAsync;
|
|
37
|
+
exports.getGlobal = getGlobal;
|
|
38
|
+
exports.globalVar = globalVar;
|
|
39
|
+
exports.setGlobal = setGlobal;
|
|
40
|
+
//# sourceMappingURL=globals.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"globals.js","names":[],"sources":["../../src/utils/globals.tsx"],"sourcesContent":["const globalVar: any =\n typeof globalThis !== 'undefined' ? globalThis :\n typeof global !== 'undefined' ? global :\n typeof window !== 'undefined' ? window :\n typeof self !== 'undefined' ? self :\n {};\nexport {\n globalVar\n};\n\nif (typeof globalThis === 'undefined') {\n (globalVar as any).globalThis = globalVar;\n}\n\n// Hexclave rebrand: file-private symbol key, renamed outright (no cross-version compat needed).\nconst stackGlobalsSymbol = Symbol.for('__hexclave-globals');\nglobalVar[stackGlobalsSymbol] ??= {};\n\nexport function createGlobal<T>(key: string, init: () => T) {\n if (!globalVar[stackGlobalsSymbol][key]) {\n globalVar[stackGlobalsSymbol][key] = init();\n }\n return globalVar[stackGlobalsSymbol][key] as T;\n}\n\n/**\n * Like createGlobal, but if the asynchronous initialization fails, the global will be reset and recomputed on the next\n * invocation.\n */\nexport function createGlobalAsync<T>(key: string, init: () => Promise<T>): Promise<T> {\n let promise: Promise<T> | null = null;\n if (!globalVar[stackGlobalsSymbol][key]) {\n promise = init().catch((e) => {\n delete globalVar[stackGlobalsSymbol][key];\n throw e;\n });\n globalVar[stackGlobalsSymbol][key] = promise;\n }\n return promise ?? globalVar[stackGlobalsSymbol][key] as Promise<T>;\n}\n\nexport function getGlobal(key: string): any {\n return globalVar[stackGlobalsSymbol][key];\n}\n\nexport function setGlobal(key: string, value: any) {\n globalVar[stackGlobalsSymbol][key] = value;\n}\n"],"mappings":";;;AAAA,MAAM,YACJ,OAAO,eAAe,cAAc,aAClC,OAAO,WAAW,cAAc,SAC9B,OAAO,WAAW,cAAc,SAC9B,OAAO,SAAS,cAAc,OAC5B,EAAE;AAKZ,IAAI,OAAO,eAAe,YACxB,CAAC,UAAkB,aAAa;AAIlC,MAAM,qBAAqB,OAAO,IAAI,qBAAqB;AAC3D,UAAU,wBAAwB,EAAE;AAEpC,SAAgB,aAAgB,KAAa,MAAe;AAC1D,KAAI,CAAC,UAAU,oBAAoB,KACjC,WAAU,oBAAoB,OAAO,MAAM;AAE7C,QAAO,UAAU,oBAAoB;;;;;;AAOvC,SAAgB,kBAAqB,KAAa,MAAoC;CACpF,IAAI,UAA6B;AACjC,KAAI,CAAC,UAAU,oBAAoB,MAAM;AACvC,YAAU,MAAM,CAAC,OAAO,MAAM;AAC5B,UAAO,UAAU,oBAAoB;AACrC,SAAM;IACN;AACF,YAAU,oBAAoB,OAAO;;AAEvC,QAAO,WAAW,UAAU,oBAAoB;;AAGlD,SAAgB,UAAU,KAAkB;AAC1C,QAAO,UAAU,oBAAoB;;AAGvC,SAAgB,UAAU,KAAa,OAAY;AACjD,WAAU,oBAAoB,OAAO"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
//#region src/utils/hashes.d.ts
|
|
2
|
+
declare function sha512(input: Uint8Array | string): Promise<Uint8Array>;
|
|
3
|
+
declare function hashPassword(password: string): Promise<string>;
|
|
4
|
+
declare function comparePassword(password: string, hash: string): Promise<boolean>;
|
|
5
|
+
declare function isPasswordHashValid(hash: string): Promise<boolean>;
|
|
6
|
+
declare function getPasswordHashAlgorithm(hash: string): Promise<"bcrypt" | undefined>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { comparePassword, getPasswordHashAlgorithm, hashPassword, isPasswordHashValid, sha512 };
|
|
9
|
+
//# sourceMappingURL=hashes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hashes.d.ts","names":[],"sources":["../../src/utils/hashes.tsx"],"mappings":";iBAIsB,MAAA,CAAO,KAAA,EAAO,UAAA,YAAsB,OAAA,CAAQ,UAAA;AAAA,iBAK5C,YAAA,CAAa,QAAA,WAAgB,OAAA;AAAA,iBAS7B,eAAA,CAAgB,QAAA,UAAkB,IAAA,WAAe,OAAA;AAAA,iBAWjD,mBAAA,CAAoB,IAAA,WAAY,OAAA;AAAA,iBAIhC,wBAAA,CAAyB,IAAA,WAAe,OAAA"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_chunk = require('../chunk-BE-pF4vm.js');
|
|
3
|
+
let __errors_js = require("./errors.js");
|
|
4
|
+
let __typed_arrays_js = require("./typed-arrays.js");
|
|
5
|
+
let bcryptjs = require("bcryptjs");
|
|
6
|
+
bcryptjs = require_chunk.__toESM(bcryptjs);
|
|
7
|
+
|
|
8
|
+
//#region src/utils/hashes.tsx
|
|
9
|
+
async function sha512(input) {
|
|
10
|
+
const bytes = typeof input === "string" ? new TextEncoder().encode(input) : (0, __typed_arrays_js.toArrayBufferBacked)(input);
|
|
11
|
+
return new Uint8Array(await crypto.subtle.digest("SHA-512", bytes));
|
|
12
|
+
}
|
|
13
|
+
async function hashPassword(password) {
|
|
14
|
+
const passwordBytes = new TextEncoder().encode(password);
|
|
15
|
+
if (passwordBytes.length >= 72) throw new __errors_js.HexclaveAssertionError(`Password is too long for bcrypt`, { len: passwordBytes.length });
|
|
16
|
+
const salt = await bcryptjs.default.genSalt(10);
|
|
17
|
+
return await bcryptjs.default.hash(password, salt);
|
|
18
|
+
}
|
|
19
|
+
async function comparePassword(password, hash) {
|
|
20
|
+
switch (await getPasswordHashAlgorithm(hash)) {
|
|
21
|
+
case "bcrypt": return await bcryptjs.default.compare(password, hash);
|
|
22
|
+
default: return false;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
async function isPasswordHashValid(hash) {
|
|
26
|
+
return !!await getPasswordHashAlgorithm(hash);
|
|
27
|
+
}
|
|
28
|
+
async function getPasswordHashAlgorithm(hash) {
|
|
29
|
+
if (typeof hash !== "string") throw new __errors_js.HexclaveAssertionError(`Passed non-string value to getPasswordHashAlgorithm`, { hash });
|
|
30
|
+
if (hash.match(/^\$2[ayb]\$.{56}$/)) try {
|
|
31
|
+
if (bcryptjs.default.getRounds(hash) > 16) return;
|
|
32
|
+
await bcryptjs.default.compare("any string", hash);
|
|
33
|
+
return "bcrypt";
|
|
34
|
+
} catch (e) {
|
|
35
|
+
console.warn(`Error while checking bcrypt password hash. Assuming the hash is invalid`, e);
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
else return;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
//#endregion
|
|
42
|
+
exports.comparePassword = comparePassword;
|
|
43
|
+
exports.getPasswordHashAlgorithm = getPasswordHashAlgorithm;
|
|
44
|
+
exports.hashPassword = hashPassword;
|
|
45
|
+
exports.isPasswordHashValid = isPasswordHashValid;
|
|
46
|
+
exports.sha512 = sha512;
|
|
47
|
+
//# sourceMappingURL=hashes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hashes.js","names":["HexclaveAssertionError","bcrypt"],"sources":["../../src/utils/hashes.tsx"],"sourcesContent":["import bcrypt from 'bcryptjs';\nimport { HexclaveAssertionError } from './errors';\nimport { toArrayBufferBacked } from './typed-arrays';\n\nexport async function sha512(input: Uint8Array | string): Promise<Uint8Array> {\n const bytes = typeof input === \"string\" ? new TextEncoder().encode(input) : toArrayBufferBacked(input);\n return new Uint8Array(await crypto.subtle.digest(\"SHA-512\", bytes));\n}\n\nexport async function hashPassword(password: string) {\n const passwordBytes = new TextEncoder().encode(password);\n if (passwordBytes.length >= 72) {\n throw new HexclaveAssertionError(`Password is too long for bcrypt`, { len: passwordBytes.length });\n }\n const salt = await bcrypt.genSalt(10);\n return await bcrypt.hash(password, salt);\n}\n\nexport async function comparePassword(password: string, hash: string): Promise<boolean> {\n switch (await getPasswordHashAlgorithm(hash)) {\n case \"bcrypt\": {\n return await bcrypt.compare(password, hash);\n }\n default: {\n return false;\n }\n }\n}\n\nexport async function isPasswordHashValid(hash: string) {\n return !!(await getPasswordHashAlgorithm(hash));\n}\n\nexport async function getPasswordHashAlgorithm(hash: string): Promise<\"bcrypt\" | undefined> {\n if (typeof hash !== \"string\") {\n throw new HexclaveAssertionError(`Passed non-string value to getPasswordHashAlgorithm`, { hash });\n }\n if (hash.match(/^\\$2[ayb]\\$.{56}$/)) {\n try {\n if (bcrypt.getRounds(hash) > 16) {\n return undefined;\n }\n await bcrypt.compare(\"any string\", hash);\n return \"bcrypt\";\n } catch (e) {\n console.warn(`Error while checking bcrypt password hash. Assuming the hash is invalid`, e);\n return undefined;\n }\n } else {\n return undefined;\n }\n}\n"],"mappings":";;;;;;;;AAIA,eAAsB,OAAO,OAAiD;CAC5E,MAAM,QAAQ,OAAO,UAAU,WAAW,IAAI,aAAa,CAAC,OAAO,MAAM,8CAAuB,MAAM;AACtG,QAAO,IAAI,WAAW,MAAM,OAAO,OAAO,OAAO,WAAW,MAAM,CAAC;;AAGrE,eAAsB,aAAa,UAAkB;CACnD,MAAM,gBAAgB,IAAI,aAAa,CAAC,OAAO,SAAS;AACxD,KAAI,cAAc,UAAU,GAC1B,OAAM,IAAIA,mCAAuB,mCAAmC,EAAE,KAAK,cAAc,QAAQ,CAAC;CAEpG,MAAM,OAAO,MAAMC,iBAAO,QAAQ,GAAG;AACrC,QAAO,MAAMA,iBAAO,KAAK,UAAU,KAAK;;AAG1C,eAAsB,gBAAgB,UAAkB,MAAgC;AACtF,SAAQ,MAAM,yBAAyB,KAAK,EAA5C;EACE,KAAK,SACH,QAAO,MAAMA,iBAAO,QAAQ,UAAU,KAAK;EAE7C,QACE,QAAO;;;AAKb,eAAsB,oBAAoB,MAAc;AACtD,QAAO,CAAC,CAAE,MAAM,yBAAyB,KAAK;;AAGhD,eAAsB,yBAAyB,MAA6C;AAC1F,KAAI,OAAO,SAAS,SAClB,OAAM,IAAID,mCAAuB,uDAAuD,EAAE,MAAM,CAAC;AAEnG,KAAI,KAAK,MAAM,oBAAoB,CACjC,KAAI;AACF,MAAIC,iBAAO,UAAU,KAAK,GAAG,GAC3B;AAEF,QAAMA,iBAAO,QAAQ,cAAc,KAAK;AACxC,SAAO;UACA,GAAG;AACV,UAAQ,KAAK,2EAA2E,EAAE;AAC1F;;KAGF"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
//#region src/utils/html.d.ts
|
|
2
|
+
declare function escapeHtml(unsafe: string): string;
|
|
3
|
+
declare function html(strings: TemplateStringsArray, ...values: any[]): string;
|
|
4
|
+
declare function htmlToText(untrustedHtml: string): string;
|
|
5
|
+
//#endregion
|
|
6
|
+
export { escapeHtml, html, htmlToText };
|
|
7
|
+
//# sourceMappingURL=html.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"html.d.ts","names":[],"sources":["../../src/utils/html.tsx"],"mappings":";iBAEgB,UAAA,CAAW,MAAA;AAAA,iBA2BX,IAAA,CAAK,OAAA,EAAS,oBAAA,KAAyB,MAAA;AAAA,iBAwBvC,UAAA,CAAW,aAAA"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_chunk = require('../chunk-BE-pF4vm.js');
|
|
3
|
+
let __strings_js = require("./strings.js");
|
|
4
|
+
|
|
5
|
+
//#region src/utils/html.tsx
|
|
6
|
+
function escapeHtml(unsafe) {
|
|
7
|
+
return `${unsafe}`.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
8
|
+
}
|
|
9
|
+
(void 0)?.test("escapeHtml", ({ expect }) => {
|
|
10
|
+
expect(escapeHtml("")).toBe("");
|
|
11
|
+
expect(escapeHtml("hello world")).toBe("hello world");
|
|
12
|
+
expect(escapeHtml("<div>")).toBe("<div>");
|
|
13
|
+
expect(escapeHtml("a & b")).toBe("a & b");
|
|
14
|
+
expect(escapeHtml("a \"quoted\" string")).toBe("a "quoted" string");
|
|
15
|
+
expect(escapeHtml("it's a test")).toBe("it's a test");
|
|
16
|
+
expect(escapeHtml("<a href=\"test\">It's a link</a>")).toBe("<a href="test">It's a link</a>");
|
|
17
|
+
});
|
|
18
|
+
function html(strings, ...values) {
|
|
19
|
+
return (0, __strings_js.templateIdentity)(strings, ...values.map((v) => escapeHtml(`${v}`)));
|
|
20
|
+
}
|
|
21
|
+
(void 0)?.test("html", ({ expect }) => {
|
|
22
|
+
expect(html`simple string`).toBe("simple string");
|
|
23
|
+
expect(html`Hello, ${"world"}!`).toBe("Hello, world!");
|
|
24
|
+
expect(html`Count: ${42}`).toBe("Count: 42");
|
|
25
|
+
expect(html`<div>${"<script>"}</div>`).toBe("<div><script></div>");
|
|
26
|
+
expect(html`${1} + ${2} = ${"<3"}`).toBe("1 + 2 = <3");
|
|
27
|
+
expect(html`Object: ${{ toString: () => "<object>" }}`).toBe("Object: <object>");
|
|
28
|
+
});
|
|
29
|
+
function htmlToText(untrustedHtml) {
|
|
30
|
+
return new DOMParser().parseFromString(untrustedHtml, "text/html").body.textContent;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
//#endregion
|
|
34
|
+
exports.escapeHtml = escapeHtml;
|
|
35
|
+
exports.html = html;
|
|
36
|
+
exports.htmlToText = htmlToText;
|
|
37
|
+
//# sourceMappingURL=html.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"html.js","names":[],"sources":["../../src/utils/html.tsx"],"sourcesContent":["import { templateIdentity } from \"./strings\";\n\nexport function escapeHtml(unsafe: string): string {\n return `${unsafe}`\n .replace(/&/g, '&')\n .replace(/</g, '<')\n .replace(/>/g, '>')\n .replace(/\"/g, \""\")\n .replace(/'/g, \"'\");\n}\nimport.meta.vitest?.test(\"escapeHtml\", ({ expect }) => {\n // Test with empty string\n expect(escapeHtml(\"\")).toBe(\"\");\n\n // Test with string without special characters\n expect(escapeHtml(\"hello world\")).toBe(\"hello world\");\n\n // Test with special characters\n expect(escapeHtml(\"<div>\")).toBe(\"<div>\");\n expect(escapeHtml(\"a & b\")).toBe(\"a & b\");\n expect(escapeHtml('a \"quoted\" string')).toBe(\"a "quoted" string\");\n expect(escapeHtml(\"it's a test\")).toBe(\"it's a test\");\n\n // Test with multiple special characters\n expect(escapeHtml(\"<a href=\\\"test\\\">It's a link</a>\")).toBe(\n \"<a href="test">It's a link</a>\"\n );\n});\n\nexport function html(strings: TemplateStringsArray, ...values: any[]): string {\n return templateIdentity(strings, ...values.map(v => escapeHtml(`${v}`)));\n}\nimport.meta.vitest?.test(\"html\", ({ expect }) => {\n // Test with no interpolation\n expect(html`simple string`).toBe(\"simple string\");\n\n // Test with string interpolation\n expect(html`Hello, ${\"world\"}!`).toBe(\"Hello, world!\");\n\n // Test with number interpolation\n expect(html`Count: ${42}`).toBe(\"Count: 42\");\n\n // Test with HTML special characters in interpolated values\n expect(html`<div>${\"<script>\"}</div>`).toBe(\"<div><script></div>\");\n\n // Test with multiple interpolations\n expect(html`${1} + ${2} = ${\"<3\"}`).toBe(\"1 + 2 = <3\");\n\n // Test with object interpolation\n const obj = { toString: () => \"<object>\" };\n expect(html`Object: ${obj}`).toBe(\"Object: <object>\");\n});\n\nexport function htmlToText(untrustedHtml: string): string {\n\n const doc = new DOMParser().parseFromString(untrustedHtml, 'text/html');\n\n return doc.body.textContent;\n\n}\n"],"mappings":";;;;;AAEA,SAAgB,WAAW,QAAwB;AACjD,QAAO,GAAG,SACP,QAAQ,MAAM,QAAO,CACrB,QAAQ,MAAM,OAAM,CACpB,QAAQ,MAAM,OAAM,CACpB,QAAQ,MAAM,SAAQ,CACtB,QAAQ,MAAM,SAAS;;CAE5B,SAAW,KAAC,eAAc,EAAA,aAAgB;AAExC,QAAO,WAAW,GAAG,CAAC,CAAC,KAAK,GAAG;AAG/B,QAAO,WAAW,cAAc,CAAC,CAAC,KAAK,cAAc;AAGrD,QAAO,WAAW,QAAQ,CAAC,CAAC,KAAK,cAAc;AAC/C,QAAO,WAAW,QAAQ,CAAC,CAAC,KAAK,YAAY;AAC7C,QAAO,WAAW,sBAAoB,CAAC,CAAC,KAAK,8BAA8B;AAC3E,QAAO,WAAW,cAAc,CAAC,CAAC,KAAK,mBAAmB;AAG1D,QAAO,WAAW,mCAAmC,CAAC,CAAC,KACrD,4DACD;EACD;AAEF,SAAgB,KAAK,SAA+B,GAAG,QAAuB;AAC5E,2CAAwB,SAAS,GAAG,OAAO,KAAI,MAAK,WAAW,GAAG,IAAI,CAAC,CAAC;;CAE1E,SAAW,KAAC,SAAa,EAAC,aAAU;AAElC,QAAO,IAAI,gBAAgB,CAAC,KAAK,gBAAgB;AAGjD,QAAO,IAAI,UAAU,QAAQ,GAAG,CAAC,KAAK,gBAAgB;AAGtD,QAAO,IAAI,UAAU,KAAK,CAAC,KAAK,YAAY;AAG5C,QAAO,IAAI,QAAQ,WAAW,QAAQ,CAAC,KAAK,4BAA4B;AAGxE,QAAO,IAAI,GAAG,EAAE,KAAK,EAAE,KAAK,OAAO,CAAC,KAAK,gBAAgB;AAIzD,QAAO,IAAI,WADC,EAAE,gBAAgB,YAAY,GACd,CAAC,KAAK,yBAAyB;EAC3D;AAEF,SAAgB,WAAW,eAA+B;AAIxD,QAFY,IAAI,WAAW,CAAC,gBAAgB,eAAe,YAAY,CAE5D,KAAK"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
//#region src/utils/http.d.ts
|
|
2
|
+
declare const HTTP_METHODS: {
|
|
3
|
+
readonly GET: {
|
|
4
|
+
readonly safe: true;
|
|
5
|
+
readonly idempotent: true;
|
|
6
|
+
};
|
|
7
|
+
readonly POST: {
|
|
8
|
+
readonly safe: false;
|
|
9
|
+
readonly idempotent: false;
|
|
10
|
+
};
|
|
11
|
+
readonly PUT: {
|
|
12
|
+
readonly safe: false;
|
|
13
|
+
readonly idempotent: true;
|
|
14
|
+
};
|
|
15
|
+
readonly DELETE: {
|
|
16
|
+
readonly safe: false;
|
|
17
|
+
readonly idempotent: true;
|
|
18
|
+
};
|
|
19
|
+
readonly PATCH: {
|
|
20
|
+
readonly safe: false;
|
|
21
|
+
readonly idempotent: false;
|
|
22
|
+
};
|
|
23
|
+
readonly OPTIONS: {
|
|
24
|
+
readonly safe: true;
|
|
25
|
+
readonly idempotent: true;
|
|
26
|
+
};
|
|
27
|
+
readonly HEAD: {
|
|
28
|
+
readonly safe: true;
|
|
29
|
+
readonly idempotent: true;
|
|
30
|
+
};
|
|
31
|
+
readonly TRACE: {
|
|
32
|
+
readonly safe: true;
|
|
33
|
+
readonly idempotent: true;
|
|
34
|
+
};
|
|
35
|
+
readonly CONNECT: {
|
|
36
|
+
readonly safe: false;
|
|
37
|
+
readonly idempotent: false;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
type HttpMethod = keyof typeof HTTP_METHODS;
|
|
41
|
+
declare function decodeBasicAuthorizationHeader(value: string): [string, string] | null;
|
|
42
|
+
declare function encodeBasicAuthorizationHeader(id: string, password: string): string;
|
|
43
|
+
//#endregion
|
|
44
|
+
export { HTTP_METHODS, HttpMethod, decodeBasicAuthorizationHeader, encodeBasicAuthorizationHeader };
|
|
45
|
+
//# sourceMappingURL=http.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.d.ts","names":[],"sources":["../../src/utils/http.tsx"],"mappings":";cAEa,YAAA;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAsCD,UAAA,gBAA0B,YAAA;AAAA,iBAEtB,8BAAA,CAA+B,KAAA;AAAA,iBA6B/B,8BAAA,CAA+B,EAAA,UAAY,QAAA"}
|