@interfere/types 10.1.2 → 10.2.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/dist/data/frame.cjs +1 -1
- package/dist/data/frame.d.cts +6 -7
- package/dist/data/frame.d.mts +6 -7
- package/dist/data/frame.mjs +1 -1
- package/dist/data/session.cjs +1 -1
- package/dist/data/session.d.cts +3 -4
- package/dist/data/session.d.mts +3 -4
- package/dist/data/session.mjs +1 -1
- package/dist/data/source-map-batch.cjs +1 -0
- package/dist/data/source-map-batch.d.cts +4 -0
- package/dist/data/source-map-batch.d.mts +4 -0
- package/dist/data/source-map-batch.mjs +1 -0
- package/dist/data/source-map-diagnostics.cjs +1 -0
- package/dist/data/source-map-diagnostics.d.cts +49 -0
- package/dist/data/source-map-diagnostics.d.mts +49 -0
- package/dist/data/source-map-diagnostics.mjs +1 -0
- package/dist/data/source-map-status.cjs +1 -0
- package/dist/data/source-map-status.d.cts +65 -0
- package/dist/data/source-map-status.d.mts +65 -0
- package/dist/data/source-map-status.mjs +1 -0
- package/dist/data/source-map-upload-batch.cjs +1 -0
- package/dist/data/source-map-upload-batch.d.cts +22 -0
- package/dist/data/source-map-upload-batch.d.mts +22 -0
- package/dist/data/source-map-upload-batch.mjs +1 -0
- package/dist/data/source-maps.cjs +1 -1
- package/dist/data/source-maps.d.cts +73 -63
- package/dist/data/source-maps.d.mts +73 -63
- package/dist/data/source-maps.mjs +1 -1
- package/dist/events/error.cjs +1 -1
- package/dist/events/error.d.cts +118 -111
- package/dist/events/error.d.mts +118 -111
- package/dist/events/error.mjs +1 -1
- package/dist/events/pageleave.cjs +1 -1
- package/dist/events/pageleave.d.cts +5 -6
- package/dist/events/pageleave.d.mts +5 -6
- package/dist/events/pageleave.mjs +1 -1
- package/dist/events/pageview.cjs +1 -1
- package/dist/events/pageview.d.cts +6 -7
- package/dist/events/pageview.d.mts +6 -7
- package/dist/events/pageview.mjs +1 -1
- package/dist/integrations/index.cjs +1 -1
- package/dist/integrations/index.d.cts +62 -63
- package/dist/integrations/index.d.mts +62 -63
- package/dist/integrations/index.mjs +1 -1
- package/dist/integrations/platforms/cli.cjs +1 -1
- package/dist/integrations/platforms/cli.d.cts +3 -4
- package/dist/integrations/platforms/cli.d.mts +3 -4
- package/dist/integrations/platforms/cli.mjs +1 -1
- package/dist/integrations/platforms/cloudflare.cjs +1 -1
- package/dist/integrations/platforms/cloudflare.d.cts +12 -13
- package/dist/integrations/platforms/cloudflare.d.mts +12 -13
- package/dist/integrations/platforms/cloudflare.mjs +1 -1
- package/dist/integrations/platforms/github.cjs +1 -1
- package/dist/integrations/platforms/github.d.cts +30 -31
- package/dist/integrations/platforms/github.d.mts +30 -31
- package/dist/integrations/platforms/github.mjs +1 -1
- package/dist/integrations/platforms/slack.cjs +1 -1
- package/dist/integrations/platforms/slack.d.cts +7 -8
- package/dist/integrations/platforms/slack.d.mts +7 -8
- package/dist/integrations/platforms/slack.mjs +1 -1
- package/dist/integrations/platforms/vercel.cjs +1 -1
- package/dist/integrations/platforms/vercel.d.cts +12 -13
- package/dist/integrations/platforms/vercel.d.mts +12 -13
- package/dist/integrations/platforms/vercel.mjs +1 -1
- package/dist/releases/build-telemetry.d.cts +8 -9
- package/dist/releases/build-telemetry.d.mts +8 -9
- package/dist/releases/definition.cjs +1 -1
- package/dist/releases/definition.d.cts +48 -49
- package/dist/releases/definition.d.mts +48 -49
- package/dist/releases/definition.mjs +1 -1
- package/dist/releases/slug.d.cts +5 -6
- package/dist/releases/slug.d.mts +5 -6
- package/dist/sdk/build-config.cjs +1 -0
- package/dist/sdk/build-config.d.cts +22 -0
- package/dist/sdk/build-config.d.mts +22 -0
- package/dist/sdk/build-config.mjs +1 -0
- package/dist/sdk/build-diagnostics.cjs +1 -1
- package/dist/sdk/build-diagnostics.d.cts +11 -12
- package/dist/sdk/build-diagnostics.d.mts +11 -12
- package/dist/sdk/build-diagnostics.mjs +1 -1
- package/dist/sdk/cli-destination.cjs +1 -1
- package/dist/sdk/cli-destination.d.cts +7 -4
- package/dist/sdk/cli-destination.d.mts +7 -4
- package/dist/sdk/cli-destination.mjs +1 -1
- package/dist/sdk/deploy-environment.cjs +1 -1
- package/dist/sdk/deploy-environment.d.cts +28 -6
- package/dist/sdk/deploy-environment.d.mts +28 -6
- package/dist/sdk/deploy-environment.mjs +1 -1
- package/dist/sdk/env.d.cts +3 -4
- package/dist/sdk/env.d.mts +3 -4
- package/dist/sdk/envelope.cjs +1 -1
- package/dist/sdk/envelope.d.cts +129 -130
- package/dist/sdk/envelope.d.mts +129 -130
- package/dist/sdk/envelope.mjs +1 -1
- package/dist/sdk/errors.cjs +2 -2
- package/dist/sdk/errors.d.cts +70 -28
- package/dist/sdk/errors.d.mts +70 -28
- package/dist/sdk/errors.mjs +2 -2
- package/dist/sdk/geo.cjs +1 -1
- package/dist/sdk/geo.d.cts +4 -5
- package/dist/sdk/geo.d.mts +4 -5
- package/dist/sdk/geo.mjs +1 -1
- package/dist/sdk/github-source.cjs +1 -1
- package/dist/sdk/github-source.d.cts +9 -9
- package/dist/sdk/github-source.d.mts +9 -9
- package/dist/sdk/github-source.mjs +1 -1
- package/dist/sdk/identify.cjs +1 -1
- package/dist/sdk/identify.d.cts +13 -14
- package/dist/sdk/identify.d.mts +13 -14
- package/dist/sdk/identify.mjs +1 -1
- package/dist/sdk/injected-globals.d.cts +9 -10
- package/dist/sdk/injected-globals.d.mts +9 -10
- package/dist/sdk/log-sourcing.cjs +1 -1
- package/dist/sdk/log-sourcing.d.cts +9 -10
- package/dist/sdk/log-sourcing.d.mts +9 -10
- package/dist/sdk/log-sourcing.mjs +1 -1
- package/dist/sdk/plugins/context/browser.cjs +1 -1
- package/dist/sdk/plugins/context/browser.d.cts +17 -18
- package/dist/sdk/plugins/context/browser.d.mts +17 -18
- package/dist/sdk/plugins/context/browser.mjs +1 -1
- package/dist/sdk/plugins/context/edge.cjs +1 -1
- package/dist/sdk/plugins/context/edge.d.cts +3 -4
- package/dist/sdk/plugins/context/edge.d.mts +3 -4
- package/dist/sdk/plugins/context/edge.mjs +1 -1
- package/dist/sdk/plugins/context/next.cjs +1 -1
- package/dist/sdk/plugins/context/next.d.cts +8 -9
- package/dist/sdk/plugins/context/next.d.mts +8 -9
- package/dist/sdk/plugins/context/next.mjs +1 -1
- package/dist/sdk/plugins/context/node.cjs +1 -1
- package/dist/sdk/plugins/context/node.d.cts +3 -4
- package/dist/sdk/plugins/context/node.d.mts +3 -4
- package/dist/sdk/plugins/context/node.mjs +1 -1
- package/dist/sdk/plugins/manifest.d.cts +8 -9
- package/dist/sdk/plugins/manifest.d.mts +8 -9
- package/dist/sdk/plugins/payload/errors.cjs +1 -1
- package/dist/sdk/plugins/payload/errors.d.cts +23 -24
- package/dist/sdk/plugins/payload/errors.d.mts +23 -24
- package/dist/sdk/plugins/payload/errors.mjs +1 -1
- package/dist/sdk/plugins/payload/page-events.cjs +1 -1
- package/dist/sdk/plugins/payload/page-events.d.cts +9 -10
- package/dist/sdk/plugins/payload/page-events.d.mts +9 -10
- package/dist/sdk/plugins/payload/page-events.mjs +1 -1
- package/dist/sdk/plugins/payload/rage-click.cjs +1 -1
- package/dist/sdk/plugins/payload/rage-click.d.cts +5 -6
- package/dist/sdk/plugins/payload/rage-click.d.mts +5 -6
- package/dist/sdk/plugins/payload/rage-click.mjs +1 -1
- package/dist/sdk/plugins/payload/replay.cjs +1 -1
- package/dist/sdk/plugins/payload/replay.d.cts +4 -5
- package/dist/sdk/plugins/payload/replay.d.mts +4 -5
- package/dist/sdk/plugins/payload/replay.mjs +1 -1
- package/dist/sdk/remote-config.cjs +1 -1
- package/dist/sdk/remote-config.d.cts +43 -20
- package/dist/sdk/remote-config.d.mts +43 -20
- package/dist/sdk/remote-config.mjs +1 -1
- package/dist/sdk/runtime.cjs +1 -1
- package/dist/sdk/runtime.d.cts +11 -12
- package/dist/sdk/runtime.d.mts +11 -12
- package/dist/sdk/runtime.mjs +1 -1
- package/dist/sdk/server-tracing.cjs +1 -1
- package/dist/sdk/server-tracing.d.cts +9 -10
- package/dist/sdk/server-tracing.d.mts +9 -10
- package/dist/sdk/server-tracing.mjs +1 -1
- package/dist/sdk/source-map-richness.cjs +1 -0
- package/dist/sdk/source-map-richness.d.cts +9 -0
- package/dist/sdk/source-map-richness.d.mts +9 -0
- package/dist/sdk/source-map-richness.mjs +1 -0
- package/dist/sdk/trace-freshness.cjs +1 -0
- package/dist/sdk/trace-freshness.d.cts +6 -0
- package/dist/sdk/trace-freshness.d.mts +6 -0
- package/dist/sdk/trace-freshness.mjs +1 -0
- package/package.json +11 -11
package/dist/sdk/identify.d.mts
CHANGED
|
@@ -1,39 +1,38 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/identify.d.ts
|
|
3
|
-
declare const identifySourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
4
|
-
type: z.ZodLiteral<"clerk">;
|
|
3
|
+
export declare const identifySourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
5
4
|
name: z.ZodLiteral<"Clerk">;
|
|
5
|
+
type: z.ZodLiteral<"clerk">;
|
|
6
6
|
}, z.core.$strip>, z.ZodObject<{
|
|
7
|
-
type: z.ZodLiteral<"auth0">;
|
|
8
7
|
name: z.ZodLiteral<"Auth0">;
|
|
8
|
+
type: z.ZodLiteral<"auth0">;
|
|
9
9
|
}, z.core.$strip>, z.ZodObject<{
|
|
10
|
-
type: z.ZodLiteral<"workos">;
|
|
11
10
|
name: z.ZodLiteral<"WorkOS">;
|
|
11
|
+
type: z.ZodLiteral<"workos">;
|
|
12
12
|
}, z.core.$strip>, z.ZodObject<{
|
|
13
|
-
type: z.ZodLiteral<"custom">;
|
|
14
13
|
name: z.ZodString;
|
|
14
|
+
type: z.ZodLiteral<"custom">;
|
|
15
15
|
}, z.core.$strip>], "type">;
|
|
16
|
-
type IdentifySource = z.infer<typeof identifySourceSchema>;
|
|
17
|
-
declare const identifyParamsSchema: z.ZodObject<{
|
|
16
|
+
export type IdentifySource = z.infer<typeof identifySourceSchema>;
|
|
17
|
+
export declare const identifyParamsSchema: z.ZodObject<{
|
|
18
18
|
avatar: z.ZodOptional<z.ZodString>;
|
|
19
19
|
email: z.ZodOptional<z.ZodEmail>;
|
|
20
20
|
identifier: z.ZodString;
|
|
21
21
|
name: z.ZodOptional<z.ZodString>;
|
|
22
22
|
source: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
23
|
-
type: z.ZodLiteral<"clerk">;
|
|
24
23
|
name: z.ZodLiteral<"Clerk">;
|
|
24
|
+
type: z.ZodLiteral<"clerk">;
|
|
25
25
|
}, z.core.$strip>, z.ZodObject<{
|
|
26
|
-
type: z.ZodLiteral<"auth0">;
|
|
27
26
|
name: z.ZodLiteral<"Auth0">;
|
|
27
|
+
type: z.ZodLiteral<"auth0">;
|
|
28
28
|
}, z.core.$strip>, z.ZodObject<{
|
|
29
|
-
type: z.ZodLiteral<"workos">;
|
|
30
29
|
name: z.ZodLiteral<"WorkOS">;
|
|
30
|
+
type: z.ZodLiteral<"workos">;
|
|
31
31
|
}, z.core.$strip>, z.ZodObject<{
|
|
32
|
-
type: z.ZodLiteral<"custom">;
|
|
33
32
|
name: z.ZodString;
|
|
33
|
+
type: z.ZodLiteral<"custom">;
|
|
34
34
|
}, z.core.$strip>], "type">;
|
|
35
35
|
traits: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
36
36
|
}, z.core.$strip>;
|
|
37
|
-
type IdentifyParams = z.infer<typeof identifyParamsSchema>;
|
|
38
|
-
//#endregion
|
|
39
|
-
export { IdentifyParams, IdentifySource, identifyParamsSchema, identifySourceSchema };
|
|
37
|
+
export type IdentifyParams = z.infer<typeof identifyParamsSchema>;
|
|
38
|
+
//#endregion
|
package/dist/sdk/identify.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"zod";const identifySourceSchema=z.discriminatedUnion(`type`,[z.object({
|
|
1
|
+
import{z}from"zod";const identifySourceSchema=z.discriminatedUnion(`type`,[z.object({name:z.literal(`Clerk`),type:z.literal(`clerk`)}).meta({id:`ClerkIdentifySource`,title:`ClerkIdentifySource`}),z.object({name:z.literal(`Auth0`),type:z.literal(`auth0`)}).meta({id:`Auth0IdentifySource`,title:`Auth0IdentifySource`}),z.object({name:z.literal(`WorkOS`),type:z.literal(`workos`)}).meta({id:`WorkOSIdentifySource`,title:`WorkOSIdentifySource`}),z.object({name:z.string(),type:z.literal(`custom`)}).meta({id:`CustomIdentifySource`,title:`CustomIdentifySource`})]).meta({description:`Auth provider that surfaced this identification.`,id:`IdentifySource`,title:`IdentifySource`}),traitsSchema=z.record(z.string(),z.unknown()).meta({description:`Free-form key/value bag of user attributes attached when identifying a session.`,id:`IdentifyTraits`,title:`IdentifyTraits`}),identifyParamsSchema=z.object({avatar:z.string().optional(),email:z.email().optional(),identifier:z.string(),name:z.string().optional(),source:identifySourceSchema,traits:traitsSchema.optional()}).superRefine((params,ctx)=>{params.source.type===`clerk`&&!params.identifier.startsWith(`user_`)&&ctx.addIssue({code:`custom`,message:`Clerk identifiers must be raw Clerk user ids starting with user_.`,path:[`identifier`]})}).meta({description:`User attributes attached when identifying a session.`,id:`IdentifyParams`,title:`IdentifyParams`});export{identifyParamsSchema,identifySourceSchema};
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
//#region src/sdk/injected-globals.d.ts
|
|
2
|
-
declare const API_URL_GLOBAL = "__INTERFERE_API_URL__";
|
|
3
|
-
declare const BUILD_MARKER_GLOBAL = "__INTERFERE_BUILD__";
|
|
4
|
-
declare const ENVIRONMENT_GLOBAL = "__INTERFERE_ENVIRONMENT__";
|
|
5
|
-
declare const FORCE_ENABLE_GLOBAL = "__INTERFERE_FORCE_ENABLE__";
|
|
6
|
-
declare const INGEST_URL_GLOBAL = "__INTERFERE_INGEST_URL__";
|
|
7
|
-
declare const PUBLIC_KEY_GLOBAL = "__INTERFERE_PUBLIC_KEY__";
|
|
8
|
-
declare const RELEASE_SLUG_GLOBAL = "__INTERFERE_RELEASE_SLUG__";
|
|
9
|
-
declare const SDK_STACK_GLOBAL = "__INTERFERE_SDK_STACK__";
|
|
10
|
-
//#endregion
|
|
11
|
-
export { API_URL_GLOBAL, BUILD_MARKER_GLOBAL, ENVIRONMENT_GLOBAL, FORCE_ENABLE_GLOBAL, INGEST_URL_GLOBAL, PUBLIC_KEY_GLOBAL, RELEASE_SLUG_GLOBAL, SDK_STACK_GLOBAL };
|
|
2
|
+
export declare const API_URL_GLOBAL = "__INTERFERE_API_URL__";
|
|
3
|
+
export declare const BUILD_MARKER_GLOBAL = "__INTERFERE_BUILD__";
|
|
4
|
+
export declare const ENVIRONMENT_GLOBAL = "__INTERFERE_ENVIRONMENT__";
|
|
5
|
+
export declare const FORCE_ENABLE_GLOBAL = "__INTERFERE_FORCE_ENABLE__";
|
|
6
|
+
export declare const INGEST_URL_GLOBAL = "__INTERFERE_INGEST_URL__";
|
|
7
|
+
export declare const PUBLIC_KEY_GLOBAL = "__INTERFERE_PUBLIC_KEY__";
|
|
8
|
+
export declare const RELEASE_SLUG_GLOBAL = "__INTERFERE_RELEASE_SLUG__";
|
|
9
|
+
export declare const SDK_STACK_GLOBAL = "__INTERFERE_SDK_STACK__";
|
|
10
|
+
//#endregion
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
//#region src/sdk/injected-globals.d.ts
|
|
2
|
-
declare const API_URL_GLOBAL = "__INTERFERE_API_URL__";
|
|
3
|
-
declare const BUILD_MARKER_GLOBAL = "__INTERFERE_BUILD__";
|
|
4
|
-
declare const ENVIRONMENT_GLOBAL = "__INTERFERE_ENVIRONMENT__";
|
|
5
|
-
declare const FORCE_ENABLE_GLOBAL = "__INTERFERE_FORCE_ENABLE__";
|
|
6
|
-
declare const INGEST_URL_GLOBAL = "__INTERFERE_INGEST_URL__";
|
|
7
|
-
declare const PUBLIC_KEY_GLOBAL = "__INTERFERE_PUBLIC_KEY__";
|
|
8
|
-
declare const RELEASE_SLUG_GLOBAL = "__INTERFERE_RELEASE_SLUG__";
|
|
9
|
-
declare const SDK_STACK_GLOBAL = "__INTERFERE_SDK_STACK__";
|
|
10
|
-
//#endregion
|
|
11
|
-
export { API_URL_GLOBAL, BUILD_MARKER_GLOBAL, ENVIRONMENT_GLOBAL, FORCE_ENABLE_GLOBAL, INGEST_URL_GLOBAL, PUBLIC_KEY_GLOBAL, RELEASE_SLUG_GLOBAL, SDK_STACK_GLOBAL };
|
|
2
|
+
export declare const API_URL_GLOBAL = "__INTERFERE_API_URL__";
|
|
3
|
+
export declare const BUILD_MARKER_GLOBAL = "__INTERFERE_BUILD__";
|
|
4
|
+
export declare const ENVIRONMENT_GLOBAL = "__INTERFERE_ENVIRONMENT__";
|
|
5
|
+
export declare const FORCE_ENABLE_GLOBAL = "__INTERFERE_FORCE_ENABLE__";
|
|
6
|
+
export declare const INGEST_URL_GLOBAL = "__INTERFERE_INGEST_URL__";
|
|
7
|
+
export declare const PUBLIC_KEY_GLOBAL = "__INTERFERE_PUBLIC_KEY__";
|
|
8
|
+
export declare const RELEASE_SLUG_GLOBAL = "__INTERFERE_RELEASE_SLUG__";
|
|
9
|
+
export declare const SDK_STACK_GLOBAL = "__INTERFERE_SDK_STACK__";
|
|
10
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const require_sdk_runtime=require("./runtime.cjs");let zod=require("zod");const LOG_SOURCING_ENV_VAR=`INTERFERE_LOG_SOURCING`,LOG_SOURCING_GLOBAL=`__INTERFERE_LOG_SOURCING__`,logSourcingModeSchema=zod.z.enum([`sdk`,`drain`]);function resolveLogSourcingMode(opts){let injected=logSourcingModeSchema.safeParse(require_sdk_runtime.normalizeEnv(opts?.injected));if(injected.success)return injected.data;let fromEnv=logSourcingModeSchema.safeParse(require_sdk_runtime.normalizeEnv(opts?.env?.[LOG_SOURCING_ENV_VAR]));return fromEnv.success?fromEnv.data:`sdk`}function readLogSourcingMode(env=require_sdk_runtime.readProcessEnv()){let
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const require_sdk_runtime=require("./runtime.cjs");let zod=require("zod");const LOG_SOURCING_ENV_VAR=`INTERFERE_LOG_SOURCING`,LOG_SOURCING_GLOBAL=`__INTERFERE_LOG_SOURCING__`,logSourcingModeSchema=zod.z.enum([`sdk`,`drain`]);function resolveLogSourcingMode(opts){let injected=logSourcingModeSchema.safeParse(require_sdk_runtime.normalizeEnv(opts?.injected));if(injected.success)return injected.data;let fromEnv=logSourcingModeSchema.safeParse(require_sdk_runtime.normalizeEnv(opts?.env?.[LOG_SOURCING_ENV_VAR]));return fromEnv.success?fromEnv.data:`sdk`}function readLogSourcingMode(env=require_sdk_runtime.readProcessEnv()){let scope=globalThis,injected=`__INTERFERE_LOG_SOURCING__`in scope?scope[LOG_SOURCING_GLOBAL]:void 0;return resolveLogSourcingMode({env,injected:typeof injected==`string`?injected:void 0})}exports.DEFAULT_LOG_SOURCING_MODE=`sdk`,exports.LOG_SOURCING_ENV_VAR=LOG_SOURCING_ENV_VAR,exports.LOG_SOURCING_GLOBAL=LOG_SOURCING_GLOBAL,exports.logSourcingModeSchema=logSourcingModeSchema,exports.readLogSourcingMode=readLogSourcingMode,exports.resolveLogSourcingMode=resolveLogSourcingMode;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/log-sourcing.d.ts
|
|
3
|
-
declare const LOG_SOURCING_ENV_VAR = "INTERFERE_LOG_SOURCING";
|
|
3
|
+
export declare const LOG_SOURCING_ENV_VAR = "INTERFERE_LOG_SOURCING";
|
|
4
4
|
/**
|
|
5
5
|
* Global stamped into the server bundle at build time (via `withInterfere`'s
|
|
6
6
|
* value-injection loader) from the surface's remote config. Read at cold
|
|
7
7
|
* start so the mode is known synchronously, before the console bridge and
|
|
8
8
|
* logger provider register.
|
|
9
9
|
*/
|
|
10
|
-
declare const LOG_SOURCING_GLOBAL = "__INTERFERE_LOG_SOURCING__";
|
|
11
|
-
declare const logSourcingModeSchema: z.ZodEnum<{
|
|
10
|
+
export declare const LOG_SOURCING_GLOBAL = "__INTERFERE_LOG_SOURCING__";
|
|
11
|
+
export declare const logSourcingModeSchema: z.ZodEnum<{
|
|
12
12
|
drain: "drain";
|
|
13
13
|
sdk: "sdk";
|
|
14
14
|
}>;
|
|
@@ -21,12 +21,11 @@ declare const logSourcingModeSchema: z.ZodEnum<{
|
|
|
21
21
|
* logger provider; a platform log drain (e.g. Vercel) captures stdout
|
|
22
22
|
* out-of-process and posts records to the collector directly.
|
|
23
23
|
*/
|
|
24
|
-
type LogSourcingMode = z.infer<typeof logSourcingModeSchema>;
|
|
25
|
-
declare const DEFAULT_LOG_SOURCING_MODE = "sdk";
|
|
26
|
-
declare function resolveLogSourcingMode(opts?: {
|
|
24
|
+
export type LogSourcingMode = z.infer<typeof logSourcingModeSchema>;
|
|
25
|
+
export declare const DEFAULT_LOG_SOURCING_MODE = "sdk";
|
|
26
|
+
export declare function resolveLogSourcingMode(opts?: {
|
|
27
27
|
readonly injected?: string | null | undefined;
|
|
28
28
|
readonly env?: Record<string, string | undefined> | undefined;
|
|
29
|
-
}):
|
|
30
|
-
declare function readLogSourcingMode(env?: Record<string, string | undefined> | undefined):
|
|
31
|
-
//#endregion
|
|
32
|
-
export { DEFAULT_LOG_SOURCING_MODE, LOG_SOURCING_ENV_VAR, LOG_SOURCING_GLOBAL, LogSourcingMode, logSourcingModeSchema, readLogSourcingMode, resolveLogSourcingMode };
|
|
29
|
+
}): "drain" | "sdk";
|
|
30
|
+
export declare function readLogSourcingMode(env?: Record<string, string | undefined> | undefined): "drain" | "sdk";
|
|
31
|
+
//#endregion
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/log-sourcing.d.ts
|
|
3
|
-
declare const LOG_SOURCING_ENV_VAR = "INTERFERE_LOG_SOURCING";
|
|
3
|
+
export declare const LOG_SOURCING_ENV_VAR = "INTERFERE_LOG_SOURCING";
|
|
4
4
|
/**
|
|
5
5
|
* Global stamped into the server bundle at build time (via `withInterfere`'s
|
|
6
6
|
* value-injection loader) from the surface's remote config. Read at cold
|
|
7
7
|
* start so the mode is known synchronously, before the console bridge and
|
|
8
8
|
* logger provider register.
|
|
9
9
|
*/
|
|
10
|
-
declare const LOG_SOURCING_GLOBAL = "__INTERFERE_LOG_SOURCING__";
|
|
11
|
-
declare const logSourcingModeSchema: z.ZodEnum<{
|
|
10
|
+
export declare const LOG_SOURCING_GLOBAL = "__INTERFERE_LOG_SOURCING__";
|
|
11
|
+
export declare const logSourcingModeSchema: z.ZodEnum<{
|
|
12
12
|
drain: "drain";
|
|
13
13
|
sdk: "sdk";
|
|
14
14
|
}>;
|
|
@@ -21,12 +21,11 @@ declare const logSourcingModeSchema: z.ZodEnum<{
|
|
|
21
21
|
* logger provider; a platform log drain (e.g. Vercel) captures stdout
|
|
22
22
|
* out-of-process and posts records to the collector directly.
|
|
23
23
|
*/
|
|
24
|
-
type LogSourcingMode = z.infer<typeof logSourcingModeSchema>;
|
|
25
|
-
declare const DEFAULT_LOG_SOURCING_MODE = "sdk";
|
|
26
|
-
declare function resolveLogSourcingMode(opts?: {
|
|
24
|
+
export type LogSourcingMode = z.infer<typeof logSourcingModeSchema>;
|
|
25
|
+
export declare const DEFAULT_LOG_SOURCING_MODE = "sdk";
|
|
26
|
+
export declare function resolveLogSourcingMode(opts?: {
|
|
27
27
|
readonly injected?: string | null | undefined;
|
|
28
28
|
readonly env?: Record<string, string | undefined> | undefined;
|
|
29
|
-
}):
|
|
30
|
-
declare function readLogSourcingMode(env?: Record<string, string | undefined> | undefined):
|
|
31
|
-
//#endregion
|
|
32
|
-
export { DEFAULT_LOG_SOURCING_MODE, LOG_SOURCING_ENV_VAR, LOG_SOURCING_GLOBAL, LogSourcingMode, logSourcingModeSchema, readLogSourcingMode, resolveLogSourcingMode };
|
|
29
|
+
}): "drain" | "sdk";
|
|
30
|
+
export declare function readLogSourcingMode(env?: Record<string, string | undefined> | undefined): "drain" | "sdk";
|
|
31
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{normalizeEnv,readProcessEnv}from"./runtime.mjs";import{z}from"zod";const LOG_SOURCING_ENV_VAR=`INTERFERE_LOG_SOURCING`,LOG_SOURCING_GLOBAL=`__INTERFERE_LOG_SOURCING__`,logSourcingModeSchema=z.enum([`sdk`,`drain`]),DEFAULT_LOG_SOURCING_MODE=`sdk`;function resolveLogSourcingMode(opts){let injected=logSourcingModeSchema.safeParse(normalizeEnv(opts?.injected));if(injected.success)return injected.data;let fromEnv=logSourcingModeSchema.safeParse(normalizeEnv(opts?.env?.[LOG_SOURCING_ENV_VAR]));return fromEnv.success?fromEnv.data:`sdk`}function readLogSourcingMode(env=readProcessEnv()){let
|
|
1
|
+
import{normalizeEnv,readProcessEnv}from"./runtime.mjs";import{z}from"zod";const LOG_SOURCING_ENV_VAR=`INTERFERE_LOG_SOURCING`,LOG_SOURCING_GLOBAL=`__INTERFERE_LOG_SOURCING__`,logSourcingModeSchema=z.enum([`sdk`,`drain`]),DEFAULT_LOG_SOURCING_MODE=`sdk`;function resolveLogSourcingMode(opts){let injected=logSourcingModeSchema.safeParse(normalizeEnv(opts?.injected));if(injected.success)return injected.data;let fromEnv=logSourcingModeSchema.safeParse(normalizeEnv(opts?.env?.[LOG_SOURCING_ENV_VAR]));return fromEnv.success?fromEnv.data:`sdk`}function readLogSourcingMode(env=readProcessEnv()){let scope=globalThis,injected=`__INTERFERE_LOG_SOURCING__`in scope?scope[LOG_SOURCING_GLOBAL]:void 0;return resolveLogSourcingMode({env,injected:typeof injected==`string`?injected:void 0})}export{DEFAULT_LOG_SOURCING_MODE,LOG_SOURCING_ENV_VAR,LOG_SOURCING_GLOBAL,logSourcingModeSchema,readLogSourcingMode,resolveLogSourcingMode};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const deviceBrowserSchema=zod.z.object({
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const deviceBrowserSchema=zod.z.object({fullVersion:zod.z.string().optional(),major:zod.z.string().optional(),name:zod.z.string().optional(),type:zod.z.string().optional(),version:zod.z.string().optional()}).meta({id:`DeviceBrowser`,title:`DeviceBrowser`}),deviceCpuSchema=zod.z.object({architecture:zod.z.string().optional(),bitness:zod.z.string().optional()}).meta({id:`DeviceCpu`,title:`DeviceCpu`}),deviceInfoSchema=zod.z.object({model:zod.z.string().optional(),type:zod.z.string().optional(),vendor:zod.z.string().optional()}).meta({id:`DeviceInfo`,title:`DeviceInfo`}),deviceEngineSchema=zod.z.object({name:zod.z.string().optional(),version:zod.z.string().optional()}).meta({id:`DeviceEngine`,title:`DeviceEngine`}),deviceOsSchema=zod.z.object({name:zod.z.string().optional(),version:zod.z.string().optional(),versionFull:zod.z.string().optional()}).meta({id:`DeviceOs`,title:`DeviceOs`}),deviceMetadataSchema=zod.z.object({browser:deviceBrowserSchema,cpu:deviceCpuSchema,device:deviceInfoSchema,engine:deviceEngineSchema,frozenUa:zod.z.boolean().optional(),os:deviceOsSchema,ua:zod.z.string()}).meta({description:`Device/browser metadata extracted from the user agent.`,id:`DeviceMetadata`,title:`DeviceMetadata`}),displayScreenSchema=zod.z.object({height:zod.z.number(),orientation:zod.z.string().optional(),width:zod.z.number()}).meta({id:`Screen`,title:`Screen`}),displaySchema=zod.z.object({screen:displayScreenSchema}).meta({id:`Display`,title:`Display`}),browserMetadataSchema=zod.z.object({display:displaySchema,language:zod.z.string().optional(),timezone:zod.z.string().optional()}).meta({description:`Browser locale and display metadata.`,id:`BrowserMetadata`,title:`BrowserMetadata`}),browserContextSchema=zod.z.object({browser:browserMetadataSchema.nullable(),device:deviceMetadataSchema.nullable(),runtime:zod.z.literal(`browser`)}).meta({description:`Request context for the browser runtime.`,id:`BrowserContext`,title:`BrowserContext`});exports.browserContextSchema=browserContextSchema,exports.deviceMetadataSchema=deviceMetadataSchema;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/browser.d.ts
|
|
3
|
-
declare const deviceMetadataSchema: z.ZodObject<{
|
|
3
|
+
export declare const deviceMetadataSchema: z.ZodObject<{
|
|
4
4
|
browser: z.ZodObject<{
|
|
5
|
+
fullVersion: z.ZodOptional<z.ZodString>;
|
|
5
6
|
major: z.ZodOptional<z.ZodString>;
|
|
6
7
|
name: z.ZodOptional<z.ZodString>;
|
|
7
8
|
type: z.ZodOptional<z.ZodString>;
|
|
8
9
|
version: z.ZodOptional<z.ZodString>;
|
|
9
|
-
fullVersion: z.ZodOptional<z.ZodString>;
|
|
10
10
|
}, z.core.$strip>;
|
|
11
11
|
cpu: z.ZodObject<{
|
|
12
12
|
architecture: z.ZodOptional<z.ZodString>;
|
|
@@ -21,47 +21,46 @@ declare const deviceMetadataSchema: z.ZodObject<{
|
|
|
21
21
|
name: z.ZodOptional<z.ZodString>;
|
|
22
22
|
version: z.ZodOptional<z.ZodString>;
|
|
23
23
|
}, z.core.$strip>;
|
|
24
|
+
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
24
25
|
os: z.ZodObject<{
|
|
25
26
|
name: z.ZodOptional<z.ZodString>;
|
|
26
27
|
version: z.ZodOptional<z.ZodString>;
|
|
27
28
|
versionFull: z.ZodOptional<z.ZodString>;
|
|
28
29
|
}, z.core.$strip>;
|
|
29
30
|
ua: z.ZodString;
|
|
30
|
-
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
31
31
|
}, z.core.$strip>;
|
|
32
|
-
type DeviceMetadata = z.infer<typeof deviceMetadataSchema>;
|
|
32
|
+
export type DeviceMetadata = z.infer<typeof deviceMetadataSchema>;
|
|
33
33
|
declare const browserMetadataSchema: z.ZodObject<{
|
|
34
|
-
language: z.ZodOptional<z.ZodString>;
|
|
35
|
-
timezone: z.ZodOptional<z.ZodString>;
|
|
36
34
|
display: z.ZodObject<{
|
|
37
35
|
screen: z.ZodObject<{
|
|
38
36
|
height: z.ZodNumber;
|
|
39
|
-
width: z.ZodNumber;
|
|
40
37
|
orientation: z.ZodOptional<z.ZodString>;
|
|
38
|
+
width: z.ZodNumber;
|
|
41
39
|
}, z.core.$strip>;
|
|
42
40
|
}, z.core.$strip>;
|
|
41
|
+
language: z.ZodOptional<z.ZodString>;
|
|
42
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
43
43
|
}, z.core.$strip>;
|
|
44
|
-
type BrowserMetadata = z.infer<typeof browserMetadataSchema>;
|
|
45
|
-
declare const browserContextSchema: z.ZodObject<{
|
|
46
|
-
runtime: z.ZodLiteral<"browser">;
|
|
44
|
+
export type BrowserMetadata = z.infer<typeof browserMetadataSchema>;
|
|
45
|
+
export declare const browserContextSchema: z.ZodObject<{
|
|
47
46
|
browser: z.ZodNullable<z.ZodObject<{
|
|
48
|
-
language: z.ZodOptional<z.ZodString>;
|
|
49
|
-
timezone: z.ZodOptional<z.ZodString>;
|
|
50
47
|
display: z.ZodObject<{
|
|
51
48
|
screen: z.ZodObject<{
|
|
52
49
|
height: z.ZodNumber;
|
|
53
|
-
width: z.ZodNumber;
|
|
54
50
|
orientation: z.ZodOptional<z.ZodString>;
|
|
51
|
+
width: z.ZodNumber;
|
|
55
52
|
}, z.core.$strip>;
|
|
56
53
|
}, z.core.$strip>;
|
|
54
|
+
language: z.ZodOptional<z.ZodString>;
|
|
55
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
57
56
|
}, z.core.$strip>>;
|
|
58
57
|
device: z.ZodNullable<z.ZodObject<{
|
|
59
58
|
browser: z.ZodObject<{
|
|
59
|
+
fullVersion: z.ZodOptional<z.ZodString>;
|
|
60
60
|
major: z.ZodOptional<z.ZodString>;
|
|
61
61
|
name: z.ZodOptional<z.ZodString>;
|
|
62
62
|
type: z.ZodOptional<z.ZodString>;
|
|
63
63
|
version: z.ZodOptional<z.ZodString>;
|
|
64
|
-
fullVersion: z.ZodOptional<z.ZodString>;
|
|
65
64
|
}, z.core.$strip>;
|
|
66
65
|
cpu: z.ZodObject<{
|
|
67
66
|
architecture: z.ZodOptional<z.ZodString>;
|
|
@@ -76,15 +75,15 @@ declare const browserContextSchema: z.ZodObject<{
|
|
|
76
75
|
name: z.ZodOptional<z.ZodString>;
|
|
77
76
|
version: z.ZodOptional<z.ZodString>;
|
|
78
77
|
}, z.core.$strip>;
|
|
78
|
+
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
79
79
|
os: z.ZodObject<{
|
|
80
80
|
name: z.ZodOptional<z.ZodString>;
|
|
81
81
|
version: z.ZodOptional<z.ZodString>;
|
|
82
82
|
versionFull: z.ZodOptional<z.ZodString>;
|
|
83
83
|
}, z.core.$strip>;
|
|
84
84
|
ua: z.ZodString;
|
|
85
|
-
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
86
85
|
}, z.core.$strip>>;
|
|
86
|
+
runtime: z.ZodLiteral<"browser">;
|
|
87
87
|
}, z.core.$strip>;
|
|
88
|
-
type BrowserContext = z.infer<typeof browserContextSchema>;
|
|
89
|
-
//#endregion
|
|
90
|
-
export { BrowserContext, BrowserMetadata, DeviceMetadata, browserContextSchema, deviceMetadataSchema };
|
|
88
|
+
export type BrowserContext = z.infer<typeof browserContextSchema>;
|
|
89
|
+
//#endregion
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/browser.d.ts
|
|
3
|
-
declare const deviceMetadataSchema: z.ZodObject<{
|
|
3
|
+
export declare const deviceMetadataSchema: z.ZodObject<{
|
|
4
4
|
browser: z.ZodObject<{
|
|
5
|
+
fullVersion: z.ZodOptional<z.ZodString>;
|
|
5
6
|
major: z.ZodOptional<z.ZodString>;
|
|
6
7
|
name: z.ZodOptional<z.ZodString>;
|
|
7
8
|
type: z.ZodOptional<z.ZodString>;
|
|
8
9
|
version: z.ZodOptional<z.ZodString>;
|
|
9
|
-
fullVersion: z.ZodOptional<z.ZodString>;
|
|
10
10
|
}, z.core.$strip>;
|
|
11
11
|
cpu: z.ZodObject<{
|
|
12
12
|
architecture: z.ZodOptional<z.ZodString>;
|
|
@@ -21,47 +21,46 @@ declare const deviceMetadataSchema: z.ZodObject<{
|
|
|
21
21
|
name: z.ZodOptional<z.ZodString>;
|
|
22
22
|
version: z.ZodOptional<z.ZodString>;
|
|
23
23
|
}, z.core.$strip>;
|
|
24
|
+
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
24
25
|
os: z.ZodObject<{
|
|
25
26
|
name: z.ZodOptional<z.ZodString>;
|
|
26
27
|
version: z.ZodOptional<z.ZodString>;
|
|
27
28
|
versionFull: z.ZodOptional<z.ZodString>;
|
|
28
29
|
}, z.core.$strip>;
|
|
29
30
|
ua: z.ZodString;
|
|
30
|
-
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
31
31
|
}, z.core.$strip>;
|
|
32
|
-
type DeviceMetadata = z.infer<typeof deviceMetadataSchema>;
|
|
32
|
+
export type DeviceMetadata = z.infer<typeof deviceMetadataSchema>;
|
|
33
33
|
declare const browserMetadataSchema: z.ZodObject<{
|
|
34
|
-
language: z.ZodOptional<z.ZodString>;
|
|
35
|
-
timezone: z.ZodOptional<z.ZodString>;
|
|
36
34
|
display: z.ZodObject<{
|
|
37
35
|
screen: z.ZodObject<{
|
|
38
36
|
height: z.ZodNumber;
|
|
39
|
-
width: z.ZodNumber;
|
|
40
37
|
orientation: z.ZodOptional<z.ZodString>;
|
|
38
|
+
width: z.ZodNumber;
|
|
41
39
|
}, z.core.$strip>;
|
|
42
40
|
}, z.core.$strip>;
|
|
41
|
+
language: z.ZodOptional<z.ZodString>;
|
|
42
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
43
43
|
}, z.core.$strip>;
|
|
44
|
-
type BrowserMetadata = z.infer<typeof browserMetadataSchema>;
|
|
45
|
-
declare const browserContextSchema: z.ZodObject<{
|
|
46
|
-
runtime: z.ZodLiteral<"browser">;
|
|
44
|
+
export type BrowserMetadata = z.infer<typeof browserMetadataSchema>;
|
|
45
|
+
export declare const browserContextSchema: z.ZodObject<{
|
|
47
46
|
browser: z.ZodNullable<z.ZodObject<{
|
|
48
|
-
language: z.ZodOptional<z.ZodString>;
|
|
49
|
-
timezone: z.ZodOptional<z.ZodString>;
|
|
50
47
|
display: z.ZodObject<{
|
|
51
48
|
screen: z.ZodObject<{
|
|
52
49
|
height: z.ZodNumber;
|
|
53
|
-
width: z.ZodNumber;
|
|
54
50
|
orientation: z.ZodOptional<z.ZodString>;
|
|
51
|
+
width: z.ZodNumber;
|
|
55
52
|
}, z.core.$strip>;
|
|
56
53
|
}, z.core.$strip>;
|
|
54
|
+
language: z.ZodOptional<z.ZodString>;
|
|
55
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
57
56
|
}, z.core.$strip>>;
|
|
58
57
|
device: z.ZodNullable<z.ZodObject<{
|
|
59
58
|
browser: z.ZodObject<{
|
|
59
|
+
fullVersion: z.ZodOptional<z.ZodString>;
|
|
60
60
|
major: z.ZodOptional<z.ZodString>;
|
|
61
61
|
name: z.ZodOptional<z.ZodString>;
|
|
62
62
|
type: z.ZodOptional<z.ZodString>;
|
|
63
63
|
version: z.ZodOptional<z.ZodString>;
|
|
64
|
-
fullVersion: z.ZodOptional<z.ZodString>;
|
|
65
64
|
}, z.core.$strip>;
|
|
66
65
|
cpu: z.ZodObject<{
|
|
67
66
|
architecture: z.ZodOptional<z.ZodString>;
|
|
@@ -76,15 +75,15 @@ declare const browserContextSchema: z.ZodObject<{
|
|
|
76
75
|
name: z.ZodOptional<z.ZodString>;
|
|
77
76
|
version: z.ZodOptional<z.ZodString>;
|
|
78
77
|
}, z.core.$strip>;
|
|
78
|
+
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
79
79
|
os: z.ZodObject<{
|
|
80
80
|
name: z.ZodOptional<z.ZodString>;
|
|
81
81
|
version: z.ZodOptional<z.ZodString>;
|
|
82
82
|
versionFull: z.ZodOptional<z.ZodString>;
|
|
83
83
|
}, z.core.$strip>;
|
|
84
84
|
ua: z.ZodString;
|
|
85
|
-
frozenUa: z.ZodOptional<z.ZodBoolean>;
|
|
86
85
|
}, z.core.$strip>>;
|
|
86
|
+
runtime: z.ZodLiteral<"browser">;
|
|
87
87
|
}, z.core.$strip>;
|
|
88
|
-
type BrowserContext = z.infer<typeof browserContextSchema>;
|
|
89
|
-
//#endregion
|
|
90
|
-
export { BrowserContext, BrowserMetadata, DeviceMetadata, browserContextSchema, deviceMetadataSchema };
|
|
88
|
+
export type BrowserContext = z.infer<typeof browserContextSchema>;
|
|
89
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"zod";const deviceBrowserSchema=z.object({
|
|
1
|
+
import{z}from"zod";const deviceBrowserSchema=z.object({fullVersion:z.string().optional(),major:z.string().optional(),name:z.string().optional(),type:z.string().optional(),version:z.string().optional()}).meta({id:`DeviceBrowser`,title:`DeviceBrowser`}),deviceCpuSchema=z.object({architecture:z.string().optional(),bitness:z.string().optional()}).meta({id:`DeviceCpu`,title:`DeviceCpu`}),deviceInfoSchema=z.object({model:z.string().optional(),type:z.string().optional(),vendor:z.string().optional()}).meta({id:`DeviceInfo`,title:`DeviceInfo`}),deviceEngineSchema=z.object({name:z.string().optional(),version:z.string().optional()}).meta({id:`DeviceEngine`,title:`DeviceEngine`}),deviceOsSchema=z.object({name:z.string().optional(),version:z.string().optional(),versionFull:z.string().optional()}).meta({id:`DeviceOs`,title:`DeviceOs`}),deviceMetadataSchema=z.object({browser:deviceBrowserSchema,cpu:deviceCpuSchema,device:deviceInfoSchema,engine:deviceEngineSchema,frozenUa:z.boolean().optional(),os:deviceOsSchema,ua:z.string()}).meta({description:`Device/browser metadata extracted from the user agent.`,id:`DeviceMetadata`,title:`DeviceMetadata`}),displayScreenSchema=z.object({height:z.number(),orientation:z.string().optional(),width:z.number()}).meta({id:`Screen`,title:`Screen`}),displaySchema=z.object({screen:displayScreenSchema}).meta({id:`Display`,title:`Display`}),browserMetadataSchema=z.object({display:displaySchema,language:z.string().optional(),timezone:z.string().optional()}).meta({description:`Browser locale and display metadata.`,id:`BrowserMetadata`,title:`BrowserMetadata`}),browserContextSchema=z.object({browser:browserMetadataSchema.nullable(),device:deviceMetadataSchema.nullable(),runtime:z.literal(`browser`)}).meta({description:`Request context for the browser runtime.`,id:`BrowserContext`,title:`BrowserContext`});export{browserContextSchema,deviceMetadataSchema};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const edgeContextSchema=zod.z.object({runtime:zod.z.literal(`edge`)}).meta({
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const edgeContextSchema=zod.z.object({runtime:zod.z.literal(`edge`)}).meta({description:`Request context for the Edge runtime.`,id:`EdgeContext`,title:`EdgeContext`});exports.edgeContextSchema=edgeContextSchema;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/edge.d.ts
|
|
3
|
-
declare const edgeContextSchema: z.ZodObject<{
|
|
3
|
+
export declare const edgeContextSchema: z.ZodObject<{
|
|
4
4
|
runtime: z.ZodLiteral<"edge">;
|
|
5
5
|
}, z.core.$strip>;
|
|
6
|
-
type EdgeContext = z.infer<typeof edgeContextSchema>;
|
|
7
|
-
//#endregion
|
|
8
|
-
export { EdgeContext, edgeContextSchema };
|
|
6
|
+
export type EdgeContext = z.infer<typeof edgeContextSchema>;
|
|
7
|
+
//#endregion
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/edge.d.ts
|
|
3
|
-
declare const edgeContextSchema: z.ZodObject<{
|
|
3
|
+
export declare const edgeContextSchema: z.ZodObject<{
|
|
4
4
|
runtime: z.ZodLiteral<"edge">;
|
|
5
5
|
}, z.core.$strip>;
|
|
6
|
-
type EdgeContext = z.infer<typeof edgeContextSchema>;
|
|
7
|
-
//#endregion
|
|
8
|
-
export { EdgeContext, edgeContextSchema };
|
|
6
|
+
export type EdgeContext = z.infer<typeof edgeContextSchema>;
|
|
7
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"zod";const edgeContextSchema=z.object({runtime:z.literal(`edge`)}).meta({
|
|
1
|
+
import{z}from"zod";const edgeContextSchema=z.object({runtime:z.literal(`edge`)}).meta({description:`Request context for the Edge runtime.`,id:`EdgeContext`,title:`EdgeContext`});export{edgeContextSchema};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const renderSourceSchema=zod.z.enum([`react-server-components`,`react-server-components-payload`,`server-rendering`]).meta({id:`RenderSource`,title:`RenderSource`}),renderTypeSchema=zod.z.enum([`dynamic`,`dynamic-resume`]).meta({id:`RenderType`,title:`RenderType`}),revalidateReasonSchema=zod.z.enum([`on-demand`,`stale`]).meta({id:`RevalidateReason`,title:`RevalidateReason`}),routeTypeSchema=zod.z.enum([`render`,`route`,`action`,`middleware`,`proxy`]).meta({id:`RouteType`,title:`RouteType`}),routerKindSchema=zod.z.enum([`Pages Router`,`App Router`]).meta({id:`RouterKind`,title:`RouterKind`}),nextjsContextSchema=zod.z.object({errorDigest:zod.z.string().optional(),renderSource:renderSourceSchema.optional(),renderType:renderTypeSchema.optional(),requestMethod:zod.z.string().optional(),requestPath:zod.z.string().optional(),revalidateReason:revalidateReasonSchema.optional(),routePath:zod.z.string().optional(),routeType:routeTypeSchema.optional(),routerKind:routerKindSchema.optional(),runtime:zod.z.literal(`nextjs`)}).meta({
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const renderSourceSchema=zod.z.enum([`react-server-components`,`react-server-components-payload`,`server-rendering`]).meta({id:`RenderSource`,title:`RenderSource`}),renderTypeSchema=zod.z.enum([`dynamic`,`dynamic-resume`]).meta({id:`RenderType`,title:`RenderType`}),revalidateReasonSchema=zod.z.enum([`on-demand`,`stale`]).meta({id:`RevalidateReason`,title:`RevalidateReason`}),routeTypeSchema=zod.z.enum([`render`,`route`,`action`,`middleware`,`proxy`]).meta({id:`RouteType`,title:`RouteType`}),routerKindSchema=zod.z.enum([`Pages Router`,`App Router`]).meta({id:`RouterKind`,title:`RouterKind`}),nextjsContextSchema=zod.z.object({errorDigest:zod.z.string().optional(),renderSource:renderSourceSchema.optional(),renderType:renderTypeSchema.optional(),requestMethod:zod.z.string().optional(),requestPath:zod.z.string().optional(),revalidateReason:revalidateReasonSchema.optional(),routePath:zod.z.string().optional(),routeType:routeTypeSchema.optional(),routerKind:routerKindSchema.optional(),runtime:zod.z.literal(`nextjs`)}).meta({description:`Request context for the Next.js runtime.`,id:`NextjsContext`,title:`NextjsContext`});exports.nextjsContextSchema=nextjsContextSchema,exports.renderSourceSchema=renderSourceSchema,exports.renderTypeSchema=renderTypeSchema,exports.revalidateReasonSchema=revalidateReasonSchema,exports.routeTypeSchema=routeTypeSchema,exports.routerKindSchema=routerKindSchema;
|
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/next.d.ts
|
|
3
|
-
declare const renderSourceSchema: z.ZodEnum<{
|
|
3
|
+
export declare const renderSourceSchema: z.ZodEnum<{
|
|
4
4
|
"react-server-components": "react-server-components";
|
|
5
5
|
"react-server-components-payload": "react-server-components-payload";
|
|
6
6
|
"server-rendering": "server-rendering";
|
|
7
7
|
}>;
|
|
8
|
-
declare const renderTypeSchema: z.ZodEnum<{
|
|
8
|
+
export declare const renderTypeSchema: z.ZodEnum<{
|
|
9
9
|
dynamic: "dynamic";
|
|
10
10
|
"dynamic-resume": "dynamic-resume";
|
|
11
11
|
}>;
|
|
12
|
-
declare const revalidateReasonSchema: z.ZodEnum<{
|
|
12
|
+
export declare const revalidateReasonSchema: z.ZodEnum<{
|
|
13
13
|
"on-demand": "on-demand";
|
|
14
14
|
stale: "stale";
|
|
15
15
|
}>;
|
|
16
|
-
declare const routeTypeSchema: z.ZodEnum<{
|
|
16
|
+
export declare const routeTypeSchema: z.ZodEnum<{
|
|
17
17
|
action: "action";
|
|
18
18
|
middleware: "middleware";
|
|
19
19
|
proxy: "proxy";
|
|
20
20
|
render: "render";
|
|
21
21
|
route: "route";
|
|
22
22
|
}>;
|
|
23
|
-
declare const routerKindSchema: z.ZodEnum<{
|
|
23
|
+
export declare const routerKindSchema: z.ZodEnum<{
|
|
24
24
|
"App Router": "App Router";
|
|
25
25
|
"Pages Router": "Pages Router";
|
|
26
26
|
}>;
|
|
27
|
-
declare const nextjsContextSchema: z.ZodObject<{
|
|
27
|
+
export declare const nextjsContextSchema: z.ZodObject<{
|
|
28
28
|
errorDigest: z.ZodOptional<z.ZodString>;
|
|
29
29
|
renderSource: z.ZodOptional<z.ZodEnum<{
|
|
30
30
|
"react-server-components": "react-server-components";
|
|
@@ -55,6 +55,5 @@ declare const nextjsContextSchema: z.ZodObject<{
|
|
|
55
55
|
}>>;
|
|
56
56
|
runtime: z.ZodLiteral<"nextjs">;
|
|
57
57
|
}, z.core.$strip>;
|
|
58
|
-
type NextjsContext = z.infer<typeof nextjsContextSchema>;
|
|
59
|
-
//#endregion
|
|
60
|
-
export { NextjsContext, nextjsContextSchema, renderSourceSchema, renderTypeSchema, revalidateReasonSchema, routeTypeSchema, routerKindSchema };
|
|
58
|
+
export type NextjsContext = z.infer<typeof nextjsContextSchema>;
|
|
59
|
+
//#endregion
|
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/next.d.ts
|
|
3
|
-
declare const renderSourceSchema: z.ZodEnum<{
|
|
3
|
+
export declare const renderSourceSchema: z.ZodEnum<{
|
|
4
4
|
"react-server-components": "react-server-components";
|
|
5
5
|
"react-server-components-payload": "react-server-components-payload";
|
|
6
6
|
"server-rendering": "server-rendering";
|
|
7
7
|
}>;
|
|
8
|
-
declare const renderTypeSchema: z.ZodEnum<{
|
|
8
|
+
export declare const renderTypeSchema: z.ZodEnum<{
|
|
9
9
|
dynamic: "dynamic";
|
|
10
10
|
"dynamic-resume": "dynamic-resume";
|
|
11
11
|
}>;
|
|
12
|
-
declare const revalidateReasonSchema: z.ZodEnum<{
|
|
12
|
+
export declare const revalidateReasonSchema: z.ZodEnum<{
|
|
13
13
|
"on-demand": "on-demand";
|
|
14
14
|
stale: "stale";
|
|
15
15
|
}>;
|
|
16
|
-
declare const routeTypeSchema: z.ZodEnum<{
|
|
16
|
+
export declare const routeTypeSchema: z.ZodEnum<{
|
|
17
17
|
action: "action";
|
|
18
18
|
middleware: "middleware";
|
|
19
19
|
proxy: "proxy";
|
|
20
20
|
render: "render";
|
|
21
21
|
route: "route";
|
|
22
22
|
}>;
|
|
23
|
-
declare const routerKindSchema: z.ZodEnum<{
|
|
23
|
+
export declare const routerKindSchema: z.ZodEnum<{
|
|
24
24
|
"App Router": "App Router";
|
|
25
25
|
"Pages Router": "Pages Router";
|
|
26
26
|
}>;
|
|
27
|
-
declare const nextjsContextSchema: z.ZodObject<{
|
|
27
|
+
export declare const nextjsContextSchema: z.ZodObject<{
|
|
28
28
|
errorDigest: z.ZodOptional<z.ZodString>;
|
|
29
29
|
renderSource: z.ZodOptional<z.ZodEnum<{
|
|
30
30
|
"react-server-components": "react-server-components";
|
|
@@ -55,6 +55,5 @@ declare const nextjsContextSchema: z.ZodObject<{
|
|
|
55
55
|
}>>;
|
|
56
56
|
runtime: z.ZodLiteral<"nextjs">;
|
|
57
57
|
}, z.core.$strip>;
|
|
58
|
-
type NextjsContext = z.infer<typeof nextjsContextSchema>;
|
|
59
|
-
//#endregion
|
|
60
|
-
export { NextjsContext, nextjsContextSchema, renderSourceSchema, renderTypeSchema, revalidateReasonSchema, routeTypeSchema, routerKindSchema };
|
|
58
|
+
export type NextjsContext = z.infer<typeof nextjsContextSchema>;
|
|
59
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"zod";const renderSourceSchema=z.enum([`react-server-components`,`react-server-components-payload`,`server-rendering`]).meta({id:`RenderSource`,title:`RenderSource`}),renderTypeSchema=z.enum([`dynamic`,`dynamic-resume`]).meta({id:`RenderType`,title:`RenderType`}),revalidateReasonSchema=z.enum([`on-demand`,`stale`]).meta({id:`RevalidateReason`,title:`RevalidateReason`}),routeTypeSchema=z.enum([`render`,`route`,`action`,`middleware`,`proxy`]).meta({id:`RouteType`,title:`RouteType`}),routerKindSchema=z.enum([`Pages Router`,`App Router`]).meta({id:`RouterKind`,title:`RouterKind`}),nextjsContextSchema=z.object({errorDigest:z.string().optional(),renderSource:renderSourceSchema.optional(),renderType:renderTypeSchema.optional(),requestMethod:z.string().optional(),requestPath:z.string().optional(),revalidateReason:revalidateReasonSchema.optional(),routePath:z.string().optional(),routeType:routeTypeSchema.optional(),routerKind:routerKindSchema.optional(),runtime:z.literal(`nextjs`)}).meta({
|
|
1
|
+
import{z}from"zod";const renderSourceSchema=z.enum([`react-server-components`,`react-server-components-payload`,`server-rendering`]).meta({id:`RenderSource`,title:`RenderSource`}),renderTypeSchema=z.enum([`dynamic`,`dynamic-resume`]).meta({id:`RenderType`,title:`RenderType`}),revalidateReasonSchema=z.enum([`on-demand`,`stale`]).meta({id:`RevalidateReason`,title:`RevalidateReason`}),routeTypeSchema=z.enum([`render`,`route`,`action`,`middleware`,`proxy`]).meta({id:`RouteType`,title:`RouteType`}),routerKindSchema=z.enum([`Pages Router`,`App Router`]).meta({id:`RouterKind`,title:`RouterKind`}),nextjsContextSchema=z.object({errorDigest:z.string().optional(),renderSource:renderSourceSchema.optional(),renderType:renderTypeSchema.optional(),requestMethod:z.string().optional(),requestPath:z.string().optional(),revalidateReason:revalidateReasonSchema.optional(),routePath:z.string().optional(),routeType:routeTypeSchema.optional(),routerKind:routerKindSchema.optional(),runtime:z.literal(`nextjs`)}).meta({description:`Request context for the Next.js runtime.`,id:`NextjsContext`,title:`NextjsContext`});export{nextjsContextSchema,renderSourceSchema,renderTypeSchema,revalidateReasonSchema,routeTypeSchema,routerKindSchema};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const nodeContextSchema=zod.z.object({errorDigest:zod.z.string().optional(),requestMethod:zod.z.string().optional(),requestPath:zod.z.string().optional(),runtime:zod.z.literal(`node`)}).meta({
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let zod=require("zod");const nodeContextSchema=zod.z.object({errorDigest:zod.z.string().optional(),requestMethod:zod.z.string().optional(),requestPath:zod.z.string().optional(),runtime:zod.z.literal(`node`)}).meta({description:`Request context for the Node.js runtime.`,id:`NodeContext`,title:`NodeContext`});exports.nodeContextSchema=nodeContextSchema;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/node.d.ts
|
|
3
|
-
declare const nodeContextSchema: z.ZodObject<{
|
|
3
|
+
export declare const nodeContextSchema: z.ZodObject<{
|
|
4
4
|
errorDigest: z.ZodOptional<z.ZodString>;
|
|
5
5
|
requestMethod: z.ZodOptional<z.ZodString>;
|
|
6
6
|
requestPath: z.ZodOptional<z.ZodString>;
|
|
7
7
|
runtime: z.ZodLiteral<"node">;
|
|
8
8
|
}, z.core.$strip>;
|
|
9
|
-
type NodeContext = z.infer<typeof nodeContextSchema>;
|
|
10
|
-
//#endregion
|
|
11
|
-
export { NodeContext, nodeContextSchema };
|
|
9
|
+
export type NodeContext = z.infer<typeof nodeContextSchema>;
|
|
10
|
+
//#endregion
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
//#region src/sdk/plugins/context/node.d.ts
|
|
3
|
-
declare const nodeContextSchema: z.ZodObject<{
|
|
3
|
+
export declare const nodeContextSchema: z.ZodObject<{
|
|
4
4
|
errorDigest: z.ZodOptional<z.ZodString>;
|
|
5
5
|
requestMethod: z.ZodOptional<z.ZodString>;
|
|
6
6
|
requestPath: z.ZodOptional<z.ZodString>;
|
|
7
7
|
runtime: z.ZodLiteral<"node">;
|
|
8
8
|
}, z.core.$strip>;
|
|
9
|
-
type NodeContext = z.infer<typeof nodeContextSchema>;
|
|
10
|
-
//#endregion
|
|
11
|
-
export { NodeContext, nodeContextSchema };
|
|
9
|
+
export type NodeContext = z.infer<typeof nodeContextSchema>;
|
|
10
|
+
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"zod";const nodeContextSchema=z.object({errorDigest:z.string().optional(),requestMethod:z.string().optional(),requestPath:z.string().optional(),runtime:z.literal(`node`)}).meta({
|
|
1
|
+
import{z}from"zod";const nodeContextSchema=z.object({errorDigest:z.string().optional(),requestMethod:z.string().optional(),requestPath:z.string().optional(),runtime:z.literal(`node`)}).meta({description:`Request context for the Node.js runtime.`,id:`NodeContext`,title:`NodeContext`});export{nodeContextSchema};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
//#region src/sdk/plugins/manifest.d.ts
|
|
2
|
-
declare const CONSENT_CATEGORIES: readonly ["necessary", "analytics", "replay"];
|
|
2
|
+
export declare const CONSENT_CATEGORIES: readonly ["necessary", "analytics", "replay"];
|
|
3
3
|
type AtLeastOne<T> = { [K in keyof T]-?: Required<Pick<T, K>> & Partial<T>; }[keyof T];
|
|
4
|
-
declare const PLUGIN_MANIFEST: readonly [{
|
|
4
|
+
export declare const PLUGIN_MANIFEST: readonly [{
|
|
5
5
|
readonly consentCategory: "necessary";
|
|
6
6
|
readonly defaultEnabled: true;
|
|
7
7
|
readonly events: readonly [{
|
|
@@ -50,10 +50,9 @@ declare const PLUGIN_MANIFEST: readonly [{
|
|
|
50
50
|
readonly events: readonly [];
|
|
51
51
|
readonly name: "logs";
|
|
52
52
|
}];
|
|
53
|
-
type PluginManifest = typeof PLUGIN_MANIFEST;
|
|
54
|
-
type ConsentCategory = (typeof CONSENT_CATEGORIES)[number];
|
|
55
|
-
type PluginKey = PluginManifest[number]["name"];
|
|
56
|
-
type GateableCategory = Exclude<ConsentCategory, "necessary">;
|
|
57
|
-
type ConsentState = AtLeastOne<Record<GateableCategory, boolean>>;
|
|
58
|
-
//#endregion
|
|
59
|
-
export { CONSENT_CATEGORIES, ConsentCategory, ConsentState, GateableCategory, PLUGIN_MANIFEST, PluginKey, PluginManifest };
|
|
53
|
+
export type PluginManifest = typeof PLUGIN_MANIFEST;
|
|
54
|
+
export type ConsentCategory = (typeof CONSENT_CATEGORIES)[number];
|
|
55
|
+
export type PluginKey = PluginManifest[number]["name"];
|
|
56
|
+
export type GateableCategory = Exclude<ConsentCategory, "necessary">;
|
|
57
|
+
export type ConsentState = AtLeastOne<Record<GateableCategory, boolean>>;
|
|
58
|
+
//#endregion
|