Restore UI functionalities and clean up dependencies

This commit is contained in:
streaper2
2026-05-08 08:32:58 +02:00
parent 8946955f76
commit 0895b7d5bc
26751 changed files with 4207476 additions and 158 deletions

View File

@@ -0,0 +1,19 @@
export type RequestErrorContext = {
routerKind: 'Pages Router' | 'App Router';
routePath: string;
routeType: 'render' | 'route' | 'action' | 'proxy';
renderSource?: 'react-server-components' | 'react-server-components-payload' | 'server-rendering';
revalidateReason: 'on-demand' | 'stale' | undefined;
};
export type InstrumentationOnRequestError = (error: unknown, errorRequest: Readonly<{
path: string;
method: string;
headers: NodeJS.Dict<string | string[]>;
}>, errorContext: Readonly<RequestErrorContext>) => void | Promise<void>;
export type InstrumentationModule = {
register?(): void;
onRequestError?: InstrumentationOnRequestError;
};
export declare namespace Instrumentation {
type onRequestError = InstrumentationOnRequestError;
}

View File

@@ -0,0 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
//# sourceMappingURL=types.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","ignoreList":[]}

View File

@@ -0,0 +1,4 @@
export declare function getRevalidateReason(params: {
isOnDemandRevalidate?: boolean;
isStaticGeneration?: boolean;
}): 'on-demand' | 'stale' | undefined;

View File

@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "getRevalidateReason", {
enumerable: true,
get: function() {
return getRevalidateReason;
}
});
function getRevalidateReason(params) {
if (params.isOnDemandRevalidate) {
return 'on-demand';
}
if (params.isStaticGeneration) {
return 'stale';
}
return undefined;
}
//# sourceMappingURL=utils.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../src/server/instrumentation/utils.ts"],"sourcesContent":["export function getRevalidateReason(params: {\n isOnDemandRevalidate?: boolean\n isStaticGeneration?: boolean\n}): 'on-demand' | 'stale' | undefined {\n if (params.isOnDemandRevalidate) {\n return 'on-demand'\n }\n if (params.isStaticGeneration) {\n return 'stale'\n }\n return undefined\n}\n"],"names":["getRevalidateReason","params","isOnDemandRevalidate","isStaticGeneration","undefined"],"mappings":";;;;+BAAgBA;;;eAAAA;;;AAAT,SAASA,oBAAoBC,MAGnC;IACC,IAAIA,OAAOC,oBAAoB,EAAE;QAC/B,OAAO;IACT;IACA,IAAID,OAAOE,kBAAkB,EAAE;QAC7B,OAAO;IACT;IACA,OAAOC;AACT","ignoreList":[0]}