chore(format): run prettier over src/ and scripts/

Formatting was configured but never enforced: `bun run format:check`
reported 199 unformatted files and ran in no workflow and in no git hook,
so .prettierrc (printWidth 100, trailing commas) described an intention
rather than the tree.

This is the one-time sweep that makes the check gateable. Whitespace and
token-reflow only -- no behavioural change: `bun run check` reports 0
errors and all 1053 frontend tests pass before and after.

Kept out of every other commit on purpose. A 199-file diff mixed with
real changes is unreviewable, and the next commit turns format:check
into a hard CI gate so this cannot silently accumulate again.
This commit is contained in:
2026-08-21 17:41:44 +02:00
parent d095e1f410
commit ad48d89dfe
199 changed files with 4698 additions and 3453 deletions
+7 -10
View File
@@ -136,7 +136,7 @@ async function seek(positionSeconds: number) {
async function seekVideo(
positionSeconds: number,
mediaSourceId: string | null,
audioTrackIndex: number | null
audioTrackIndex: number | null,
): Promise<void> {
const adapter = activeAdapter;
if (!adapter) {
@@ -148,7 +148,7 @@ async function seekVideo(
positionSeconds,
mediaSourceId,
audioTrackIndex,
adapter.kind === "html5"
adapter.kind === "html5",
)) as any;
// Serde keeps these snake_case (only the "strategy" tag is camelCase).
if (response.strategy === "reloadStream") {
@@ -169,7 +169,7 @@ async function switchAudioTrack(
streamIndex: number,
arrayIndex: number,
currentPosition: number | null,
mediaSourceId: string | null
mediaSourceId: string | null,
): Promise<void> {
const adapter = activeAdapter;
if (!adapter) return;
@@ -179,7 +179,7 @@ async function switchAudioTrack(
arrayIndex,
adapter.kind === "html5",
currentPosition,
mediaSourceId
mediaSourceId,
)) as any;
if (response.strategy === "reloadStream") {
await adapter.reloadSource(response.new_url!, response.position!);
@@ -198,7 +198,7 @@ async function setStreamQuality(
quality: StreamingQuality,
currentPosition: number | null,
mediaSourceId: string | null,
audioTrackIndex: number | null
audioTrackIndex: number | null,
): Promise<void> {
const adapter = activeAdapter;
if (!adapter) return;
@@ -208,7 +208,7 @@ async function setStreamQuality(
adapter.kind === "html5",
currentPosition,
mediaSourceId,
audioTrackIndex
audioTrackIndex,
)) as any;
// Serde keeps these snake_case (only the "strategy" tag is camelCase).
if (response.strategy === "reloadStream") {
@@ -305,10 +305,7 @@ async function addTrackById(trackId: string, position: "next" | "end" = "end") {
}
/** Add multiple tracks to the queue by ID. */
async function addTracksByIds(
trackIds: string[],
position: "next" | "end" = "end"
) {
async function addTracksByIds(trackIds: string[], position: "next" | "end" = "end") {
await commands.playerAddTracksByIds(requireHandle(), { trackIds, position });
}