chore: migrate to oxlint and oxfmt

Co-authored-by: Christoph Nakazawa <christoph.pojer@gmail.com>
This commit is contained in:
Peter Steinberger
2026-01-14 14:31:43 +00:00
parent 912ebffc63
commit c379191f80
1480 changed files with 28608 additions and 43547 deletions

View File

@@ -1,19 +1,13 @@
import {
colorize,
isRich as isRichTerminal,
theme,
} from "../../terminal/theme.js";
import { colorize, isRich as isRichTerminal, theme } from "../../terminal/theme.js";
export const isRich = (opts?: { json?: boolean; plain?: boolean }) =>
Boolean(isRichTerminal() && !opts?.json && !opts?.plain);
export const pad = (value: string, size: number) => value.padEnd(size);
export const formatKey = (key: string, rich: boolean) =>
colorize(rich, theme.warn, key);
export const formatKey = (key: string, rich: boolean) => colorize(rich, theme.warn, key);
export const formatValue = (value: string, rich: boolean) =>
colorize(rich, theme.info, value);
export const formatValue = (value: string, rich: boolean) => colorize(rich, theme.info, value);
export const formatKeyValue = (
key: string,
@@ -22,8 +16,7 @@ export const formatKeyValue = (
valueColor: (value: string) => string = theme.info,
) => `${formatKey(key, rich)}=${colorize(rich, valueColor, value)}`;
export const formatSeparator = (rich: boolean) =>
colorize(rich, theme.muted, " | ");
export const formatSeparator = (rich: boolean) => colorize(rich, theme.muted, " | ");
export const formatTag = (tag: string, rich: boolean) => {
if (!rich) return tag;