chore(ts): use source import extensions
This commit is contained in:
@@ -96,4 +96,4 @@ export function getNewEntries(entries: ChangelogEntry[], lastVersion: string): C
|
||||
}
|
||||
|
||||
// Re-export getChangelogPath from paths.ts for convenience
|
||||
export { getChangelogPath } from "../config.js";
|
||||
export { getChangelogPath } from "../config.ts";
|
||||
|
||||
@@ -4,8 +4,8 @@ import { readFileSync, unlinkSync } from "fs";
|
||||
import { tmpdir } from "os";
|
||||
import { join } from "path";
|
||||
|
||||
import { clipboard } from "./clipboard-native.js";
|
||||
import { loadPhoton } from "./photon.js";
|
||||
import { clipboard } from "./clipboard-native.ts";
|
||||
import { loadPhoton } from "./photon.ts";
|
||||
|
||||
export type ClipboardImage = {
|
||||
bytes: Uint8Array;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { execSync, spawn } from "child_process";
|
||||
import { platform } from "os";
|
||||
import { isWaylandSession } from "./clipboard-image.js";
|
||||
import { clipboard } from "./clipboard-native.js";
|
||||
import { isWaylandSession } from "./clipboard-image.ts";
|
||||
import { clipboard } from "./clipboard-native.ts";
|
||||
|
||||
type NativeClipboardExecOptions = {
|
||||
input: string;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PhotonImageType } from "./photon.js";
|
||||
import type { PhotonImageType } from "./photon.ts";
|
||||
|
||||
type Photon = typeof import("@silvia-odwyer/photon-node");
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { applyExifOrientation } from "./exif-orientation.js";
|
||||
import { loadPhoton } from "./photon.js";
|
||||
import { applyExifOrientation } from "./exif-orientation.ts";
|
||||
import { loadPhoton } from "./photon.ts";
|
||||
|
||||
/**
|
||||
* Convert image to PNG format for terminal display.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { ImageContent } from "@earendil-works/pi-ai";
|
||||
import { applyExifOrientation } from "./exif-orientation.js";
|
||||
import { loadPhoton } from "./photon.js";
|
||||
import { applyExifOrientation } from "./exif-orientation.ts";
|
||||
import { loadPhoton } from "./photon.ts";
|
||||
|
||||
export interface ImageResizeOptions {
|
||||
maxWidth?: number; // Default: 2000
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { existsSync } from "node:fs";
|
||||
import { delimiter } from "node:path";
|
||||
import { spawn, spawnSync } from "child_process";
|
||||
import { getBinDir } from "../config.js";
|
||||
import { getBinDir } from "../config.ts";
|
||||
|
||||
export interface ShellConfig {
|
||||
shell: string;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import hljs from "highlight.js/lib/index.js";
|
||||
import { decodeHtmlEntityAt } from "./html.js";
|
||||
import { decodeHtmlEntityAt } from "./html.ts";
|
||||
|
||||
export type HighlightFormatter = (text: string) => string;
|
||||
export type HighlightTheme = Partial<Record<string, HighlightFormatter>>;
|
||||
|
||||
@@ -5,7 +5,7 @@ import { arch, platform } from "os";
|
||||
import { join } from "path";
|
||||
import { Readable } from "stream";
|
||||
import { pipeline } from "stream/promises";
|
||||
import { APP_NAME, getBinDir } from "../config.js";
|
||||
import { APP_NAME, getBinDir } from "../config.ts";
|
||||
|
||||
const TOOLS_DIR = getBinDir();
|
||||
const NETWORK_TIMEOUT_MS = 10_000;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { getPiUserAgent } from "./pi-user-agent.js";
|
||||
import { getPiUserAgent } from "./pi-user-agent.ts";
|
||||
|
||||
const LATEST_VERSION_URL = "https://pi.dev/api/latest-version";
|
||||
const DEFAULT_VERSION_CHECK_TIMEOUT_MS = 10000;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { randomUUID } from "node:crypto";
|
||||
import { copyFileSync, existsSync, mkdirSync, renameSync, rmSync } from "node:fs";
|
||||
import { basename, dirname, join, relative, resolve, toNamespacedPath } from "node:path";
|
||||
import { getCwdRelativePath } from "./paths.js";
|
||||
import { getCwdRelativePath } from "./paths.ts";
|
||||
|
||||
const QUARANTINE_DIR_NAME = ".pi-native-quarantine";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user