Merge branch 'release/0.15' into feat/jsonv-refactor

# Conflicts:
#	app/build.ts
#	app/package.json
#	app/src/App.ts
#	app/src/adapter/cloudflare/storage/StorageR2Adapter.ts
#	app/src/auth/authenticate/Authenticator.ts
#	app/src/auth/authenticate/strategies/PasswordStrategy.ts
#	app/src/data/entities/Entity.ts
#	app/src/data/fields/DateField.ts
#	app/src/data/server/query.ts
#	app/src/flows/flows/triggers/EventTrigger.ts
#	app/src/flows/tasks/presets/LogTask.ts
#	app/src/media/AppMedia.ts
#	app/src/modules/server/AppServer.ts
#	app/src/modules/server/SystemController.ts
#	app/vite.dev.ts
#	bun.lock
This commit is contained in:
dswbx
2025-07-02 17:18:12 +02:00
84 changed files with 1027 additions and 626 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
import { type Event, type EventClass, InvalidEventReturn } from "./Event";
import { EventListener, type ListenerHandler, type ListenerMode } from "./EventListener";
import { $console } from "core";
import { $console } from "core/utils";
export type RegisterListenerConfig =
| ListenerMode
-1
View File
@@ -38,7 +38,6 @@ export { getFlashMessage } from "./server/flash";
} from "./object/schema"; */
export * from "./drivers";
export * from "./console";
export * from "./events";
// compatibility
+6 -1
View File
@@ -1,3 +1,5 @@
import type { MaybePromise } from "core/types";
export type Matcher<T = unknown> = {
toEqual: (expected: T, failMsg?: string) => void;
toBe: (expected: T, failMsg?: string) => void;
@@ -16,7 +18,7 @@ export interface Test {
skipIf: (condition: boolean) => (label: string, fn: TestFn) => void;
}
export type TestRunner = {
describe: (label: string, asyncFn: () => Promise<void>) => void;
describe: (label: string, asyncFn: () => MaybePromise<void>) => void;
test: Test;
mock: <T extends (...args: any[]) => any>(fn: T) => T | any;
expect: <T = unknown>(
@@ -26,6 +28,9 @@ export type TestRunner = {
resolves: Matcher<Awaited<T>>;
rejects: Matcher<Awaited<T>>;
};
beforeEach: (fn: () => MaybePromise<void>) => void;
afterEach: (fn: () => MaybePromise<void>) => void;
afterAll: (fn: () => MaybePromise<void>) => void;
};
export async function retry<T>(
+1 -1
View File
@@ -2,7 +2,7 @@ import { extension, guess, isMimeType } from "media/storage/mime-types-tiny";
import { randomString } from "core/utils/strings";
import type { Context } from "hono";
import { invariant } from "core/utils/runtime";
import { $console } from "../console";
import { $console } from "./console";
export function getContentName(request: Request): string | undefined;
export function getContentName(contentDisposition: string): string | undefined;
+1
View File
@@ -1,3 +1,4 @@
export * from "./console";
export * from "./browser";
export * from "./objects";
export * from "./strings";
+3 -3
View File
@@ -1,4 +1,4 @@
import { $console } from "core";
import { $console } from "./console";
type ConsoleSeverity = "log" | "warn" | "error";
const _oldConsoles = {
@@ -36,14 +36,14 @@ export function disableConsoleLog(severities: ConsoleSeverity[] = ["log", "warn"
severities.forEach((severity) => {
console[severity] = () => null;
});
$console.setLevel("critical");
$console?.setLevel("critical");
}
export function enableConsoleLog() {
Object.entries(_oldConsoles).forEach(([severity, fn]) => {
console[severity as ConsoleSeverity] = fn;
});
$console.resetLevel();
$console?.resetLevel();
}
export function formatMemoryUsage() {