SYMBOL INDEX (1990 symbols across 209 files) FILE: packages/baoyu-chrome-cdp/src/index.test.ts function useEnv (line 20) | function useEnv( function makeTempDir (line 45) | async function makeTempDir(prefix: string): Promise { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: packages/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record = { constant FONT_SIZE_OPTIONS (line 10) | const FONT_SIZE_OPTIONS = ["14px", "15px", "16px", "17px", "18px"]; constant COLOR_PRESETS (line 12) | const COLOR_PRESETS: Record = { constant CODE_BLOCK_THEMES (line 28) | const CODE_BLOCK_THEMES = [ constant DEFAULT_STYLE (line 48) | const DEFAULT_STYLE: StyleConfig = { constant THEME_STYLE_DEFAULTS (line 58) | const THEME_STYLE_DEFAULTS: Record> = { FILE: packages/baoyu-md/src/content.ts type FrontmatterFields (line 3) | type FrontmatterFields = Record; function parseFrontmatter (line 5) | function parseFrontmatter(content: string): { function serializeFrontmatter (line 28) | function serializeFrontmatter(frontmatter: FrontmatterFields): string { function stripWrappingQuotes (line 34) | function stripWrappingQuotes(value: string): string { function toFrontmatterString (line 49) | function toFrontmatterString(value: unknown): string | undefined { function pickFirstString (line 59) | function pickFirstString( function extractTitleFromMarkdown (line 70) | function extractTitleFromMarkdown(markdown: string): string { function extractSummaryFromBody (line 79) | function extractSummaryFromBody(body: string, maxLen: number): string { FILE: packages/baoyu-md/src/document.test.ts function useCwd (line 18) | function useCwd(t: TestContext, cwd: string): void { function makeTempDir (line 26) | async function makeTempDir(prefix: string): Promise { FILE: packages/baoyu-md/src/document.ts type RenderMarkdownDocumentOptions (line 32) | interface RenderMarkdownDocumentOptions { type RenderMarkdownDocumentResult (line 48) | interface RenderMarkdownDocumentResult { function resolveColorToken (line 57) | function resolveColorToken(value?: string): string | undefined { function resolveFontFamilyToken (line 62) | function resolveFontFamilyToken(value?: string): string | undefined { function formatTimestamp (line 67) | function formatTimestamp(date = new Date()): string { function buildMarkdownDocumentMeta (line 74) | function buildMarkdownDocumentMeta( function resolveMarkdownStyle (line 93) | function resolveMarkdownStyle(options: RenderMarkdownDocumentOptions = {... function resolveRenderOptions (line 106) | function resolveRenderOptions( function renderMarkdownDocument (line 128) | async function renderMarkdownDocument( function renderMarkdownFileToHtml (line 176) | async function renderMarkdownFileToHtml( FILE: packages/baoyu-md/src/extend-config.ts function extractYamlFrontMatter (line 6) | function extractYamlFrontMatter(content: string): string | null { function parseExtendYaml (line 11) | function parseExtendYaml(yaml: string): Partial { function loadExtendConfig (line 37) | function loadExtendConfig(): Partial { FILE: packages/baoyu-md/src/extensions/alert.ts type AlertOptions (line 3) | interface AlertOptions { type AlertVariantItem (line 9) | interface AlertVariantItem { function ucfirst (line 16) | function ucfirst(str: string) { function markedAlert (line 25) | function markedAlert(options: AlertOptions = {}): MarkedExtension { function resolveVariants (line 264) | function resolveVariants(variants: AlertVariantItem[]) { function createSyntaxPattern (line 282) | function createSyntaxPattern(type: string) { FILE: packages/baoyu-md/src/extensions/footnotes.ts type MapContent (line 11) | interface MapContent { function markedFootnotes (line 17) | function markedFootnotes(): MarkedExtension { FILE: packages/baoyu-md/src/extensions/infographic.ts type InfographicOptions (line 3) | interface InfographicOptions { function renderInfographic (line 7) | async function renderInfographic(containerId: string, code: string, opti... function markedInfographic (line 82) | function markedInfographic(options?: InfographicOptions): MarkedExtension { FILE: packages/baoyu-md/src/extensions/katex.ts type MarkedKatexOptions (line 3) | interface MarkedKatexOptions { function createRenderer (line 16) | function createRenderer(display: boolean, withStyle: boolean = true) { function inlineKatex (line 46) | function inlineKatex(options: MarkedKatexOptions | undefined, renderer: ... function blockKatex (line 88) | function blockKatex(_options: MarkedKatexOptions | undefined, renderer: ... function inlineLatexKatex (line 107) | function inlineLatexKatex(_options: MarkedKatexOptions | undefined, rend... function blockLatexKatex (line 130) | function blockLatexKatex(_options: MarkedKatexOptions | undefined, rende... function MDKatex (line 153) | function MDKatex(options: MarkedKatexOptions | undefined, withStyle: boo... FILE: packages/baoyu-md/src/extensions/markup.ts function markedMarkup (line 9) | function markedMarkup(): MarkedExtension { FILE: packages/baoyu-md/src/extensions/plantuml.ts type PlantUMLOptions (line 4) | interface PlantUMLOptions { function encode6bit (line 37) | function encode6bit(b: number): string { function append3bytes (line 63) | function append3bytes(b1: number, b2: number, b3: number): string { function encode64 (line 80) | function encode64(data: string): string { function performDeflate (line 100) | function performDeflate(input: string): string { function encodePlantUML (line 122) | function encodePlantUML(plantumlCode: string): string { function generatePlantUMLUrl (line 142) | function generatePlantUMLUrl(code: string, options: Required { function createPlantUMLHTML (line 216) | function createPlantUMLHTML(imageUrl: string, options: Required { function normalizeCssText (line 94) | function normalizeCssText(cssText: string, style: StyleConfig = DEFAULT_... function normalizeInlineCss (line 112) | function normalizeInlineCss(html: string, style: StyleConfig = DEFAULT_S... function modifyHtmlStructure (line 130) | function modifyHtmlStructure(htmlString: string): string { function removeFirstHeading (line 140) | function removeFirstHeading(html: string): string { FILE: packages/baoyu-md/src/images.test.ts function makeTempDir (line 14) | async function makeTempDir(prefix: string): Promise { FILE: packages/baoyu-md/src/images.ts type ImagePlaceholder (line 7) | interface ImagePlaceholder { type ResolvedImageInfo (line 13) | interface ResolvedImageInfo extends ImagePlaceholder { function replaceMarkdownImagesWithPlaceholders (line 17) | function replaceMarkdownImagesWithPlaceholders( function getImageExtension (line 40) | function getImageExtension(urlOrPath: string): string { function downloadFile (line 45) | async function downloadFile(url: string, destPath: string): Promise { function resolveImagePath (line 88) | async function resolveImagePath( function resolveContentImages (line 112) | async function resolveContentImages( function resolveLocalWithFallback (line 130) | function resolveLocalWithFallback(resolved: string, logLabel: string): s... FILE: packages/baoyu-md/src/render.ts function main (line 7) | async function main(): Promise { FILE: packages/baoyu-md/src/renderer.ts function escapeHtml (line 39) | function escapeHtml(text: string): string { function buildAddition (line 49) | function buildAddition(): string { function buildFootnoteArray (line 68) | function buildFootnoteArray(footnotes: [number, string, string][]): stri... function transform (line 78) | function transform(legend: string, text: string | null, title: string | ... function parseFrontMatterAndContent (line 91) | function parseFrontMatterAndContent(markdownText: string): ParseResult { function wrapInlineCode (line 112) | function wrapInlineCode(value: string): string { function initRenderer (line 119) | function initRenderer(opts: IOpts = {}): RendererAPI { function preprocessCjkEmphasis (line 372) | function preprocessCjkEmphasis(markdown: string): string { function renderMarkdown (line 407) | function renderMarkdown(raw: string, renderer: RendererAPI): { function postProcessHtml (line 418) | function postProcessHtml( FILE: packages/baoyu-md/src/themes.ts constant SCRIPT_DIR (line 6) | const SCRIPT_DIR = path.dirname(fileURLToPath(import.meta.url)); constant THEME_DIR (line 7) | const THEME_DIR = path.resolve(SCRIPT_DIR, "themes"); constant FALLBACK_THEMES (line 8) | const FALLBACK_THEMES: ThemeName[] = ["default", "grace", "simple"]; function stripOutputScope (line 10) | function stripOutputScope(cssContent: string): string { function discoverThemesFromDir (line 18) | function discoverThemesFromDir(dir: string): string[] { function resolveThemeNames (line 29) | function resolveThemeNames(): ThemeName[] { constant THEME_NAMES (line 37) | const THEME_NAMES: ThemeName[] = resolveThemeNames(); function loadThemeCss (line 39) | function loadThemeCss(theme: ThemeName): { function normalizeThemeCss (line 60) | function normalizeThemeCss(css: string): string { FILE: packages/baoyu-md/src/types.ts type ThemeName (line 3) | type ThemeName = string; type StyleConfig (line 5) | interface StyleConfig { type IOpts (line 15) | interface IOpts { type RendererAPI (line 24) | interface RendererAPI { type ParseResult (line 39) | interface ParseResult { type CliOptions (line 45) | interface CliOptions { type ExtendConfig (line 60) | interface ExtendConfig { type HtmlDocumentMeta (line 74) | interface HtmlDocumentMeta { FILE: packages/baoyu-md/src/utils/languages.ts constant COMMON_LANGUAGES (line 39) | const COMMON_LANGUAGES: Record = { constant HLJS_VERSION (line 79) | const HLJS_VERSION = `11.11.1` constant HLJS_CDN_BASE (line 80) | const HLJS_CDN_BASE = `https://cdn-doocs.oss-cn-shenzhen.aliyuncs.com/np... function grammarUrlFor (line 88) | function grammarUrlFor(language: string): string { function loadAndRegisterLanguage (line 97) | async function loadAndRegisterLanguage(language: string, hljs: any): Pro... function formatHighlightedCode (line 131) | function formatHighlightedCode(html: string, preserveNewlines = false): ... function highlightAndFormatCode (line 159) | function highlightAndFormatCode(text: string, language: string, hljs: an... function highlightCodeBlock (line 191) | function highlightCodeBlock(codeBlock: Element, language: string, hljs: ... function highlightPendingBlocks (line 214) | function highlightPendingBlocks(hljs: any, container: Document | Element... FILE: scripts/install-git-hooks.mjs function main (line 6) | async function main() { FILE: scripts/lib/release-files.mjs constant PACKAGE_DEPENDENCY_SECTIONS (line 4) | const PACKAGE_DEPENDENCY_SECTIONS = [ constant SKIPPED_DIRS (line 11) | const SKIPPED_DIRS = new Set([".git", ".clawhub", ".clawdhub", "node_mod... constant SKIPPED_FILES (line 12) | const SKIPPED_FILES = new Set([".DS_Store", "bun.lockb"]); function listReleaseFiles (line 14) | async function listReleaseFiles(root) { function validateSelfContainedRelease (line 42) | async function validateSelfContainedRelease(root) { function fromPosixRel (line 67) | function fromPosixRel(relPath) { function isWithinRoot (line 71) | function isWithinRoot(root, target) { FILE: scripts/lib/release-files.test.ts function makeTempDir (line 12) | async function makeTempDir(prefix: string): Promise { function writeFile (line 16) | async function writeFile(filePath: string, contents = ""): Promise { function writeJson (line 21) | async function writeJson(filePath: string, value: unknown): Promise { FILE: scripts/lib/shared-skill-packages.mjs constant PACKAGE_DEPENDENCY_SECTIONS (line 6) | const PACKAGE_DEPENDENCY_SECTIONS = [ constant SKIPPED_DIRS (line 13) | const SKIPPED_DIRS = new Set([".git", ".clawhub", ".clawdhub", "node_mod... constant SKIPPED_FILES (line 14) | const SKIPPED_FILES = new Set([".DS_Store"]); function syncSharedSkillPackages (line 16) | async function syncSharedSkillPackages(repoRoot, options = {}) { function normalizeTargetConsumerDirs (line 46) | function normalizeTargetConsumerDirs(repoRoot, targets) { function ensureManagedPathsClean (line 65) | function ensureManagedPathsClean(repoRoot, managedPaths) { function syncConsumerPackage (line 90) | async function syncConsumerPackage({ consumer, root, workspacePackages, ... function syncPackageTree (line 127) | async function syncPackageTree({ sourceDir, targetDir, workspacePackages... function copyDirectory (line 166) | async function copyDirectory(sourceDir, targetDir) { function discoverWorkspacePackages (line 186) | async function discoverWorkspacePackages(repoRoot) { function discoverSkillScriptPackages (line 205) | async function discoverSkillScriptPackages(repoRoot, targetConsumerDirs ... function collectLocalDependencies (line 220) | function collectLocalDependencies(packageJson, workspacePackages) { function rewriteLocalDependencySpecs (line 235) | function rewriteLocalDependencySpecs(packageJson, localDeps) { function writeJson (line 247) | async function writeJson(filePath, value) { function resolveBunRuntime (line 252) | function resolveBunRuntime() { function commandExists (line 264) | function commandExists(command) { function runInstall (line 271) | function runInstall(runtime, cwd) { FILE: scripts/lib/shared-skill-packages.test.ts function makeTempDir (line 9) | async function makeTempDir(prefix: string): Promise { function writeFile (line 13) | async function writeFile(filePath: string, contents = ""): Promise { function writeJson (line 18) | async function writeJson(filePath: string, value: unknown): Promise { FILE: scripts/publish-skill.mjs constant DEFAULT_REGISTRY (line 10) | const DEFAULT_REGISTRY = "https://clawhub.ai"; function main (line 12) | async function main() { function parseArgs (line 68) | function parseArgs(argv) { function printUsage (line 137) | function printUsage() { function buildSkillEntry (line 152) | function buildSkillEntry(folder, slugOverride, displayNameOverride) { function readClawhubConfig (line 161) | async function readClawhubConfig() { function getConfigPath (line 170) | function getConfigPath() { function pathForExistingConfig (line 202) | function pathForExistingConfig(primary, legacy) { function publishSkill (line 208) | async function publishSkill({ registry, token, skill, files, version, ch... function apiJson (line 244) | async function apiJson(registry, token, requestPath) { function sanitizeSlug (line 266) | function sanitizeSlug(value) { function titleCase (line 276) | function titleCase(value) { constant MIME_MAP (line 284) | const MIME_MAP = { function mimeType (line 299) | function mimeType(relPath) { function parseBoolean (line 304) | function parseBoolean(value) { FILE: scripts/sync-clawhub.mjs constant DEFAULT_REGISTRY (line 9) | const DEFAULT_REGISTRY = "https://clawhub.ai"; constant TEXT_EXTENSIONS (line 10) | const TEXT_EXTENSIONS = new Set([ function main (line 51) | async function main() { function parseArgs (line 177) | function parseArgs(argv) { function printUsage (line 245) | function printUsage() { function readClawhubConfig (line 259) | async function readClawhubConfig() { function getConfigPath (line 268) | function getConfigPath() { function pathForExistingConfig (line 300) | function pathForExistingConfig(primary, legacy) { function findSkills (line 306) | async function findSkills(roots) { function findSkillFolders (line 317) | async function findSkillFolders(root) { function buildSkillEntry (line 337) | function buildSkillEntry(folder) { function hasSkillMarker (line 346) | async function hasSkillMarker(folder) { function listTextFiles (line 353) | async function listTextFiles(root) { function buildFingerprint (line 384) | function buildFingerprint(files) { function sha256 (line 392) | function sha256(bytes) { function publishSkill (line 396) | async function publishSkill({ registry, token, skill, files, version, ch... function apiJson (line 432) | async function apiJson(registry, token, requestPath) { function apiJsonWithStatus (line 440) | async function apiJsonWithStatus(registry, token, requestPath) { function mapWithConcurrency (line 458) | async function mapWithConcurrency(items, limit, fn) { function formatCandidate (line 475) | function formatCandidate(candidate, bump) { function bumpSemver (line 485) | function bumpSemver(version, bump) { function sanitizeSlug (line 499) | function sanitizeSlug(value) { function titleCase (line 509) | function titleCase(value) { function safeStat (line 517) | async function safeStat(filePath) { FILE: scripts/sync-shared-skill-packages.mjs function main (line 10) | async function main() { function parseArgs (line 24) | function parseArgs(argv) { function printUsage (line 57) | function printUsage() { FILE: skills/baoyu-article-illustrator/scripts/build-batch.ts type CliArgs (line 5) | type CliArgs = { type OutlineEntry (line 18) | type OutlineEntry = { function printUsage (line 23) | function printUsage(): void { function parseArgs (line 40) | function parseArgs(argv: string[]): CliArgs { function parseOutline (line 74) | function parseOutline(content: string): OutlineEntry[] { function findPromptFile (line 91) | async function findPromptFile(promptsDir: string, entry: OutlineEntry): ... function main (line 98) | async function main(): Promise { FILE: skills/baoyu-comic/scripts/merge-to-pdf.ts type PageInfo (line 5) | interface PageInfo { function parseArgs (line 12) | function parseArgs(): { dir: string; output?: string } { function findComicPages (line 33) | function findComicPages(dir: string): PageInfo[] { function createPdf (line 69) | async function createPdf(pages: PageInfo[], outputPath: string) { function main (line 101) | async function main() { FILE: skills/baoyu-compress-image/scripts/main.ts type Compressor (line 6) | type Compressor = "sips" | "cwebp" | "imagemagick" | "sharp"; type Format (line 7) | type Format = "webp" | "png" | "jpeg"; type Options (line 9) | interface Options { type Result (line 19) | interface Result { constant SUPPORTED_EXTS (line 28) | const SUPPORTED_EXTS = [".png", ".jpg", ".jpeg", ".webp", ".gif", ".tiff"]; function commandExists (line 30) | async function commandExists(cmd: string): Promise { function detectCompressor (line 42) | async function detectCompressor(format: Format): Promise { function runCmd (line 53) | function runCmd(cmd: string, args: string[]): Promise<{ code: number; st... function compressWithSips (line 63) | async function compressWithSips(input: string, output: string, format: F... function compressWithCwebp (line 70) | async function compressWithCwebp(input: string, output: string, quality:... function compressWithImagemagick (line 76) | async function compressWithImagemagick(input: string, output: string, qu... function compressWithSharp (line 82) | async function compressWithSharp(input: string, output: string, format: ... function compress (line 91) | async function compress( function getOutputPath (line 118) | function getOutputPath(input: string, format: Format, keep: boolean, cus... function formatSize (line 129) | function formatSize(bytes: number): string { function processFile (line 135) | async function processFile( function collectFiles (line 166) | function collectFiles(dir: string, recursive: boolean): string[] { function printHelp (line 180) | function printHelp() { function parseArgs (line 193) | function parseArgs(args: string[]): Options | null { function main (line 245) | async function main() { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/client.ts type InitOptions (line 29) | type InitOptions = { type RequestKwargs (line 38) | type RequestKwargs = RequestInit & { timeout_ms?: number }; function normalize_headers (line 40) | function normalize_headers(h?: HeadersInit): Record { function collect_strings (line 53) | function collect_strings(root: unknown, accept: (s: string) => boolean, ... class GeminiClient (line 81) | class GeminiClient extends GemMixin { method constructor (line 96) | constructor( method init (line 112) | async init( method close (line 170) | async close(delay: number = 0): Promise { method reset_close_task (line 188) | async reset_close_task(): Promise { method start_auto_refresh (line 200) | async start_auto_refresh(signal: AbortSignal): Promise { method _run (line 223) | protected async _run(fn: () => Promise, retry: number): Promise<... method generate_content (line 252) | async generate_content( method generateContent (line 481) | async generateContent( method start_chat (line 492) | start_chat(opts?: ConstructorParameters[1]): ChatS... method startChat (line 496) | startChat(opts?: ConstructorParameters[1]): ChatSe... method _batch_execute (line 500) | protected async _batch_execute(payloads: RPCData[], opts: RequestInit ... class ChatSession (line 528) | class ChatSession { method constructor (line 535) | constructor( method toString (line 556) | toString(): string { method last_output (line 560) | get last_output(): ModelOutput | null { method last_output (line 564) | set last_output(v: ModelOutput | null) { method send_message (line 572) | async send_message(prompt: string, files: string[] | null = null, kwar... method sendMessage (line 576) | async sendMessage(prompt: string, files?: string[] | null, kwargs?: Re... method choose_candidate (line 580) | choose_candidate(index: number): ModelOutput { method chooseCandidate (line 590) | chooseCandidate(index: number): ModelOutput { method metadata (line 594) | get metadata(): Array { method metadata (line 598) | set metadata(v: Array) { method cid (line 604) | get cid(): string | null { method cid (line 608) | set cid(v: string | null) { method rid (line 612) | get rid(): string | null { method rid (line 616) | set rid(v: string | null) { method rcid (line 620) | get rcid(): string | null { method rcid (line 624) | set rcid(v: string | null) { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/components/gem-mixin.ts method gems (line 14) | get gems(): GemJar { method fetch_gems (line 23) | async fetch_gems(include_hidden: boolean = false, opts?: RequestInit): P... method create_gem (line 107) | async create_gem(name: string, prompt: string, description: string = '')... method update_gem (line 141) | async update_gem(gem: Gem | string, name: string, prompt: string, descri... method delete_gem (line 171) | async delete_gem(gem: Gem | string, opts?: RequestInit): Promise { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/constants.ts constant GRPC (line 11) | const GRPC = { class Model (line 46) | class Model { method constructor (line 69) | constructor( method from_name (line 75) | static from_name(name: string): Model { method from_dict (line 87) | static from_dict(model_dict: { model_name?: unknown; model_header?: un... FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/exceptions.ts class AuthError (line 1) | class AuthError extends Error { method constructor (line 2) | constructor(message = 'AuthError') { class APIError (line 8) | class APIError extends Error { method constructor (line 9) | constructor(message = 'APIError') { class ImageGenerationError (line 15) | class ImageGenerationError extends APIError { method constructor (line 16) | constructor(message = 'ImageGenerationError') { class GeminiError (line 22) | class GeminiError extends Error { method constructor (line 23) | constructor(message = 'GeminiError') { class TimeoutError (line 29) | class TimeoutError extends GeminiError { method constructor (line 30) | constructor(message = 'TimeoutError') { class UsageLimitExceeded (line 36) | class UsageLimitExceeded extends GeminiError { method constructor (line 37) | constructor(message = 'UsageLimitExceeded') { class ModelInvalid (line 43) | class ModelInvalid extends GeminiError { method constructor (line 44) | constructor(message = 'ModelInvalid') { class TemporarilyBlocked (line 50) | class TemporarilyBlocked extends GeminiError { method constructor (line 51) | constructor(message = 'TemporarilyBlocked') { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/types/candidate.ts function decode_html (line 3) | function decode_html(s: string | null | undefined): string | null | unde... class Candidate (line 17) | class Candidate { method constructor (line 24) | constructor(params: { method toString (line 38) | toString(): string { method images (line 42) | get images(): Image[] { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/types/gem.ts class Gem (line 1) | class Gem { method constructor (line 2) | constructor( method toString (line 10) | toString(): string { class GemJar (line 15) | class GemJar implements Iterable { method constructor (line 18) | constructor(entries?: Iterable<[string, Gem]>) { method entries (line 26) | entries(): IterableIterator<[string, Gem]> { method values (line 30) | values(): IterableIterator { method has (line 34) | has(id: string): boolean { method set (line 38) | set(id: string, gem: Gem): this { method get (line 43) | get(id?: string | null, name?: string | null, def: Gem | null = null):... method filter (line 65) | filter(predefined: boolean | null = null, name: string | null = null):... method [Symbol.iterator] (line 22) | [Symbol.iterator](): Iterator { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/types/grpc.ts class RPCData (line 1) | class RPCData { method constructor (line 2) | constructor( method toString (line 8) | toString(): string { method serialize (line 12) | serialize(): unknown[] { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/types/image.ts class Image (line 7) | class Image { method constructor (line 8) | constructor( method toString (line 15) | toString(): string { method save (line 20) | async save( class WebImage (line 85) | class WebImage extends Image {} class GeneratedImage (line 87) | class GeneratedImage extends Image { method constructor (line 88) | constructor( method save (line 101) | async save( FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/types/modeloutput.ts class ModelOutput (line 4) | class ModelOutput { method constructor (line 9) | constructor(params: { metadata: string[]; candidates: Candidate[]; cho... method toString (line 15) | toString(): string { method text (line 19) | get text(): string { method thoughts (line 23) | get thoughts(): string | null { method images (line 27) | get images(): Image[] { method rcid (line 31) | get rcid(): string { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/cookie-file.ts type CookieMap (line 7) | type CookieMap = Record; type CookieFileData (line 9) | type CookieFileData = function read_cookie_file (line 22) | async function read_cookie_file(p: string = resolveGeminiWebCookiePath()... function write_cookie_file (line 64) | async function write_cookie_file( FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/decorators.ts function running (line 4) | function running(retry: number = 0) { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/get-access-token.ts function send_request (line 13) | async function send_request(cookies: Record, verbose: bo... function merge_cookie_maps (line 29) | function merge_cookie_maps(...maps: Array | null ... function read_cached_1psidts_file (line 40) | function read_cached_1psidts_file(dir: string, sid: string): string | nu... function list_cached_1psidts (line 51) | function list_cached_1psidts(dir: string): Array<{ sid: string; sidts: s... function fetch_google_extra_cookies (line 66) | async function fetch_google_extra_cookies(proxy: string | null, verbose:... function get_access_token (line 79) | async function get_access_token( FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/http.ts function sleep (line 1) | function sleep(ms: number, signal?: AbortSignal): Promise { function cookie_header (line 24) | function cookie_header(cookies: Record): string { function extract_set_cookie_value (line 33) | function extract_set_cookie_value(setCookie: string | null, name: string... function fetch_with_timeout (line 41) | async function fetch_with_timeout( FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/load-browser-cookies.ts constant GEMINI_APP_URL (line 23) | const GEMINI_APP_URL = 'https://gemini.google.com/app'; constant CHROME_CANDIDATES_FULL (line 25) | const CHROME_CANDIDATES_FULL: PlatformCandidates = { function get_free_port (line 49) | async function get_free_port(): Promise { function find_chrome_executable (line 53) | function find_chrome_executable(): string | null { function find_existing_chrome_debug_port (line 60) | async function find_existing_chrome_debug_port(profileDir: string): Prom... function launch_chrome (line 64) | async function launch_chrome(profileDir: string, port: number) { function is_gemini_session_ready (line 77) | async function is_gemini_session_ready(cookies: CookieMap, verbose: bool... function fetch_cookies_from_existing_chrome (line 101) | async function fetch_cookies_from_existing_chrome( function fetch_google_cookies_via_cdp (line 182) | async function fetch_google_cookies_via_cdp( function load_browser_cookies (line 256) | async function load_browser_cookies(domain_name: string = '', verbose: b... FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/logger.ts type LogLevel (line 1) | type LogLevel = 'TRACE' | 'DEBUG' | 'INFO' | 'WARNING' | 'ERROR' | 'CRIT... function toNum (line 14) | function toNum(level: LogLevel): number { function set_log_level (line 19) | function set_log_level(level: LogLevel): void { function emit (line 25) | function emit(level: Exclude, args: unknown[]): void { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/parsing.ts function get_nested_value (line 3) | function get_nested_value(data: unknown, path: number[], de... function extract_json_from_response (line 22) | function extract_json_from_response(text: string): unknown { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/paths.ts constant APP_DATA_DIR (line 6) | const APP_DATA_DIR = 'baoyu-skills'; constant GEMINI_DATA_DIR (line 7) | const GEMINI_DATA_DIR = 'gemini-web'; constant COOKIE_FILE_NAME (line 8) | const COOKIE_FILE_NAME = 'cookies.json'; constant PROFILE_DIR_NAME (line 9) | const PROFILE_DIR_NAME = 'chrome-profile'; function resolveUserDataRoot (line 11) | function resolveUserDataRoot(): string { function resolveGeminiWebDataDir (line 21) | function resolveGeminiWebDataDir(): string { function resolveGeminiWebCookiePath (line 27) | function resolveGeminiWebCookiePath(): string { function getWslWindowsHome (line 34) | function getWslWindowsHome(): string | null { function resolveGeminiWebChromeProfileDir (line 44) | function resolveGeminiWebChromeProfileDir(): string { function resolveGeminiWebSessionsDir (line 52) | function resolveGeminiWebSessionsDir(): string { function resolveGeminiWebSessionPath (line 56) | function resolveGeminiWebSessionPath(name: string): string { FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/rotate-1psidts.ts function rotate_1psidts (line 10) | async function rotate_1psidts(cookies: Record, _proxy?: ... FILE: skills/baoyu-danger-gemini-web/scripts/gemini-webapi/utils/upload-file.ts function upload_file (line 7) | async function upload_file(file: string, _proxy?: string | null): Promis... function parse_file_name (line 32) | function parse_file_name(file: string): string { FILE: skills/baoyu-danger-gemini-web/scripts/main.ts type CliArgs (line 9) | type CliArgs = { type SessionRecord (line 24) | type SessionRecord = { type LegacySessionV1 (line 32) | type LegacySessionV1 = { function normalizeSessionMetadata (line 42) | function normalizeSessionMetadata(input: unknown): Array { function formatScriptCommand (line 62) | function formatScriptCommand(fallback: string): string { function printUsage (line 76) | function printUsage(cookiePath: string, profileDir: string): void { function parseArgs (line 112) | function parseArgs(argv: string[]): CliArgs { function resolveModel (line 246) | function resolveModel(id: string): Model { function readPromptFromFiles (line 258) | async function readPromptFromFiles(files: string[]): Promise { function readPromptFromStdin (line 266) | async function readPromptFromStdin(): Promise { function normalizeOutputImagePath (line 278) | function normalizeOutputImagePath(p: string): string { function loadSession (line 285) | async function loadSession(id: string): Promise { function saveSession (line 315) | async function saveSession(rec: SessionRecord): Promise { function listSessions (line 324) | async function listSessions(): Promise { function formatJson (line 370) | function formatJson(out: ModelOutput, extra?: Record): ... function main (line 397) | async function main(): Promise { FILE: skills/baoyu-danger-gemini-web/scripts/vendor/baoyu-chrome-cdp/src/index.test.ts function useEnv (line 20) | function useEnv( function makeTempDir (line 45) | async function makeTempDir(prefix: string): Promise { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-danger-gemini-web/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record = { constant FALLBACK_TWEET_DETAIL_FIELD_TOGGLES (line 138) | const FALLBACK_TWEET_DETAIL_FIELD_TOGGLES = [ FILE: skills/baoyu-danger-x-to-markdown/scripts/cookie-file.ts type CookieMap (line 7) | type CookieMap = Record; type CookieFileData (line 9) | type CookieFileData = function read_cookie_file (line 22) | async function read_cookie_file( function write_cookie_file (line 66) | async function write_cookie_file( FILE: skills/baoyu-danger-x-to-markdown/scripts/cookies.ts constant CHROME_CANDIDATES_FULL (line 21) | const CHROME_CANDIDATES_FULL: PlatformCandidates = { function findChromeExecutable (line 45) | function findChromeExecutable(): string | null { function launchChrome (line 52) | async function launchChrome(profileDir: string, port: number) { function fetchXCookiesViaCdp (line 64) | async function fetchXCookiesViaCdp( function resolveCookieDomain (line 137) | function resolveCookieDomain(cookie: CookieLike): string | null { function pickCookieValue (line 153) | function pickCookieValue(cookies: T[], name: strin... function buildXCookieMap (line 166) | function buildXCookieMap(cookies: T[]): Record): boolean { function filterXCookieMap (line 179) | function filterXCookieMap(cookieMap: Record): Record void): ... function loadXCookiesFromFile (line 228) | async function loadXCookiesFromFile(log?: (message: string) => void): Pr... function loadXCookiesFromCdp (line 237) | async function loadXCookiesFromCdp(log?: (message: string) => void): Pro... function loadXCookies (line 266) | async function loadXCookies(log?: (message: string) => void): Promise void): Promise... function buildCookieHeader (line 281) | function buildCookieHeader(cookieMap: Record): string | ... FILE: skills/baoyu-danger-x-to-markdown/scripts/graphql.ts function isNonEmptyObject (line 26) | function isNonEmptyObject(value: unknown): value is Record { function parseStringList (line 27) | function parseStringList(raw: string | undefined): string[] { function resolveFeatureValue (line 36) | function resolveFeatureValue(html: string, key: string): boolean | undef... function buildFeatureMap (line 45) | function buildFeatureMap( function buildFieldToggleMap (line 67) | function buildFieldToggleMap(keys: string[]): Record { function buildTweetFieldToggleMap (line 75) | function buildTweetFieldToggleMap(keys: string[]): Record { function isValidConsent (line 420) | function isValidConsent(value: unknown): value is ConsentRecord { function ensureConsent (line 431) | async function ensureConsent(log: (message: string) => void): Promise { FILE: skills/baoyu-danger-x-to-markdown/scripts/markdown.ts type ReferencedTweetInfo (line 9) | type ReferencedTweetInfo = { type FormatArticleOptions (line 17) | type FormatArticleOptions = { type ResolvedMediaAsset (line 21) | type ResolvedMediaAsset = function coerceArticleEntity (line 32) | function coerceArticleEntity(value: unknown): ArticleEntity | null { function escapeMarkdownAlt (line 46) | function escapeMarkdownAlt(text: string): string { function normalizeCaption (line 50) | function normalizeCaption(caption?: string): string { function summarizeTweetText (line 56) | function summarizeTweetText(text?: string): string { function buildTweetUrl (line 68) | function buildTweetUrl(tweetId?: string, username?: string): string | nu... type EntityLookup (line 76) | type EntityLookup = { function buildEntityLookup (line 81) | function buildEntityLookup( function resolveEntityEntry (line 106) | function resolveEntityEntry( function resolveVideoUrl (line 123) | function resolveVideoUrl(info?: ArticleMediaInfo): string | undefined { function resolveMediaAsset (line 132) | function resolveMediaAsset(info?: ArticleMediaInfo): ResolvedMediaAsset ... function resolveFallbackMediaAsset (line 156) | function resolveFallbackMediaAsset(rawUrl?: string): ResolvedMediaAsset ... function resolveCoverUrl (line 172) | function resolveCoverUrl(info?: ArticleMediaInfo): string | undefined { function buildMediaIdentity (line 177) | function buildMediaIdentity(asset: ResolvedMediaAsset): string { function renderMediaLines (line 183) | function renderMediaLines( function buildMediaById (line 209) | function buildMediaById(article: ArticleEntity): Map]+)(>)... constant IMAGE_EXTENSIONS (line 27) | const IMAGE_EXTENSIONS = new Set([ constant VIDEO_EXTENSIONS (line 40) | const VIDEO_EXTENSIONS = new Set(["mp4", "m4v", "mov", "webm", "mkv"]); constant MIME_EXTENSION_MAP (line 42) | const MIME_EXTENSION_MAP: Record = { constant DOWNLOAD_USER_AGENT (line 59) | const DOWNLOAD_USER_AGENT = function normalizeContentType (line 62) | function normalizeContentType(raw: string | null): string { function normalizeExtension (line 66) | function normalizeExtension(raw: string | undefined | null): string | un... function resolveExtensionFromUrl (line 75) | function resolveExtensionFromUrl(rawUrl: string): string | undefined { function resolveKindFromContentType (line 88) | function resolveKindFromContentType(contentType: string): MediaKind | un... function resolveKindFromExtension (line 95) | function resolveKindFromExtension(ext: string | undefined): MediaKind | ... function resolveKindFromHostname (line 102) | function resolveKindFromHostname(rawUrl: string): MediaKind | undefined { function resolveMediaKind (line 113) | function resolveMediaKind( function resolveOutputExtension (line 135) | function resolveOutputExtension( function safeDecodeURIComponent (line 149) | function safeDecodeURIComponent(value: string): string { function sanitizeFileSegment (line 157) | function sanitizeFileSegment(input: string): string { function resolveFileStem (line 165) | function resolveFileStem(rawUrl: string, extension: string): string { function buildFileName (line 180) | function buildFileName(kind: MediaKind, index: number, sourceUrl: string... constant FRONTMATTER_COVER_RE (line 188) | const FRONTMATTER_COVER_RE = /^(coverImage:\s*")(https?:\/\/[^"]+)(")/m; function toHighResUrl (line 190) | function toHighResUrl(rawUrl: string): string { function isPlausibleMediaUrl (line 205) | function isPlausibleMediaUrl(rawUrl: string): boolean { function collectMarkdownLinkCandidates (line 212) | function collectMarkdownLinkCandidates(markdown: string): MarkdownLinkCa... function rewriteMarkdownMediaLinks (line 243) | function rewriteMarkdownMediaLinks(markdown: string, replacements: Map { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-danger-x-to-markdown/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record = { function decodeHtmlEntities (line 34) | function decodeHtmlEntities(text: string): string { function formatFrontmatter (line 40) | function formatFrontmatter(value: string): string | null { function formatMarkdownContent (line 49) | function formatMarkdownContent( function formatMarkdown (line 87) | function formatMarkdown( function parseArgs (line 124) | function parseArgs(args: string[]): { filePath: string; options: FormatO... FILE: skills/baoyu-format-markdown/scripts/quotes.ts function replaceQuotes (line 1) | function replaceQuotes(content: string): string { FILE: skills/baoyu-image-gen/scripts/main.test.ts function makeArgs (line 22) | function makeArgs(overrides: Partial = {}): CliArgs { function useEnv (line 43) | function useEnv( function makeTempDir (line 68) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-image-gen/scripts/main.ts type ProviderModule (line 14) | type ProviderModule = { type PreparedTask (line 21) | type PreparedTask = { type TaskResult (line 31) | type TaskResult = { type ProviderRateLimit (line 41) | type ProviderRateLimit = { type LoadedBatchTasks (line 46) | type LoadedBatchTasks = { constant MAX_ATTEMPTS (line 52) | const MAX_ATTEMPTS = 3; constant DEFAULT_MAX_WORKERS (line 53) | const DEFAULT_MAX_WORKERS = 10; constant POLL_WAIT_MS (line 54) | const POLL_WAIT_MS = 250; constant DEFAULT_PROVIDER_RATE_LIMITS (line 55) | const DEFAULT_PROVIDER_RATE_LIMITS: Record = { function printUsage (line 65) | function printUsage(): void { function parseArgs (line 142) | function parseArgs(argv: string[]): CliArgs { function loadEnvFile (line 307) | async function loadEnvFile(p: string): Promise> { function loadEnv (line 329) | async function loadEnv(): Promise { function extractYamlFrontMatter (line 344) | function extractYamlFrontMatter(content: string): string | null { function parseSimpleYaml (line 349) | function parseSimpleYaml(yaml: string): Partial { function loadExtendConfig (line 456) | async function loadExtendConfig(): Promise> { function mergeConfig (line 479) | function mergeConfig(args: CliArgs, extend: Partial): CliA... function parsePositiveInt (line 489) | function parsePositiveInt(value: string | undefined): number | null { function parsePositiveBatchInt (line 495) | function parsePositiveBatchInt(value: unknown): number | null { function getConfiguredMaxWorkers (line 506) | function getConfiguredMaxWorkers(extendConfig: Partial): n... function getConfiguredProviderRateLimits (line 512) | function getConfiguredProviderRateLimits( function readPromptFromFiles (line 543) | async function readPromptFromFiles(files: string[]): Promise { function readPromptFromStdin (line 551) | async function readPromptFromStdin(): Promise { function normalizeOutputImagePath (line 565) | function normalizeOutputImagePath(p: string, defaultExtension = ".png"):... function inferProviderFromModel (line 572) | function inferProviderFromModel(model: string | null): Provider | null { function detectProvider (line 578) | function detectProvider(args: CliArgs): Provider { function validateReferenceImages (line 641) | async function validateReferenceImages(referenceImages: string[]): Promi... function isRetryableGenerationError (line 652) | function isRetryableGenerationError(error: unknown): boolean { function loadProviderModule (line 672) | async function loadProviderModule(provider: Provider): Promise { function getModelForProvider (line 690) | function getModelForProvider( function prepareSingleTask (line 711) | async function prepareSingleTask(args: CliArgs, extendConfig: Partial { function isDirectExecution (line 1037) | function isDirectExecution(metaUrl: string): boolean { FILE: skills/baoyu-image-gen/scripts/providers/dashscope.test.ts function useEnv (line 15) | function useEnv( FILE: skills/baoyu-image-gen/scripts/providers/dashscope.ts type DashScopeModelFamily (line 3) | type DashScopeModelFamily = "qwen2" | "qwenFixed" | "legacy"; type DashScopeModelSpec (line 5) | type DashScopeModelSpec = { constant DEFAULT_MODEL (line 10) | const DEFAULT_MODEL = "qwen-image-2.0-pro"; constant MIN_QWEN_2_TOTAL_PIXELS (line 11) | const MIN_QWEN_2_TOTAL_PIXELS = 512 * 512; constant MAX_QWEN_2_TOTAL_PIXELS (line 12) | const MAX_QWEN_2_TOTAL_PIXELS = 2048 * 2048; constant SIZE_STEP (line 13) | const SIZE_STEP = 16; constant QWEN_NEGATIVE_PROMPT (line 14) | const QWEN_NEGATIVE_PROMPT = constant QWEN_2_TARGET_PIXELS (line 17) | const QWEN_2_TARGET_PIXELS: Record = { constant QWEN_2_RECOMMENDED (line 22) | const QWEN_2_RECOMMENDED: Record> = { constant QWEN_FIXED_SIZES_BY_RATIO (line 33) | const QWEN_FIXED_SIZES_BY_RATIO: Record = { constant QWEN_FIXED_SIZES (line 41) | const QWEN_FIXED_SIZES = Object.values(QWEN_FIXED_SIZES_BY_RATIO); constant LEGACY_STANDARD_SIZES (line 43) | const LEGACY_STANDARD_SIZES: [number, number][] = [ constant LEGACY_STANDARD_SIZES_2K (line 55) | const LEGACY_STANDARD_SIZES_2K: [number, number][] = [ constant QWEN_2_SPEC (line 66) | const QWEN_2_SPEC: DashScopeModelSpec = { constant QWEN_FIXED_SPEC (line 71) | const QWEN_FIXED_SPEC: DashScopeModelSpec = { constant LEGACY_SPEC (line 76) | const LEGACY_SPEC: DashScopeModelSpec = { constant MODEL_SPEC_ALIASES (line 81) | const MODEL_SPEC_ALIASES: Record = { function getDefaultModel (line 93) | function getDefaultModel(): string { function getApiKey (line 97) | function getApiKey(): string | null { function getBaseUrl (line 101) | function getBaseUrl(): string { function getModelSpec (line 106) | function getModelSpec(model: string): DashScopeModelSpec { function getModelFamily (line 110) | function getModelFamily(model: string): DashScopeModelFamily { function normalizeQuality (line 114) | function normalizeQuality(quality: CliArgs["quality"]): Quality { function parseAspectRatio (line 118) | function parseAspectRatio(ar: string): { width: number; height: number }... function normalizeSize (line 127) | function normalizeSize(size: string): string { function parseSize (line 131) | function parseSize(size: string): { width: number; height: number } | nu... function formatSize (line 142) | function formatSize(width: number, height: number): string { function getRatioValue (line 146) | function getRatioValue(ar: string): number | null { function findKnownRatioKey (line 152) | function findKnownRatioKey(ar: string, candidates: string[], tolerance =... function roundToStep (line 172) | function roundToStep(value: number): number { function fitToPixelBudget (line 176) | function fitToPixelBudget( function getSizeFromAspectRatio (line 223) | function getSizeFromAspectRatio(ar: string | null, quality: CliArgs["qua... function getQwen2SizeFromAspectRatio (line 248) | function getQwen2SizeFromAspectRatio(ar: string | null, quality: CliArgs... function getQwenFixedSizeFromAspectRatio (line 279) | function getQwenFixedSizeFromAspectRatio(ar: string | null, quality: Cli... function validateSizeFormat (line 299) | function validateSizeFormat(size: string): { width: number; height: numb... function validateQwen2Size (line 307) | function validateQwen2Size(size: string): string { function validateQwenFixedSize (line 320) | function validateQwenFixedSize(size: string): string { function resolveSizeForModel (line 332) | function resolveSizeForModel( function buildParameters (line 356) | function buildParameters( type DashScopeResponse (line 373) | type DashScopeResponse = { function extractImageFromResponse (line 384) | async function extractImageFromResponse(result: DashScopeResponse): Prom... function generateImage (line 414) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/providers/google.test.ts function useEnv (line 17) | function useEnv( function makeArgs (line 42) | function makeArgs(overrides: Partial = {}): CliArgs { FILE: skills/baoyu-image-gen/scripts/providers/google.ts constant GOOGLE_MULTIMODAL_MODELS (line 6) | const GOOGLE_MULTIMODAL_MODELS = [ constant GOOGLE_IMAGEN_MODELS (line 11) | const GOOGLE_IMAGEN_MODELS = [ function getDefaultModel (line 16) | function getDefaultModel(): string { function normalizeGoogleModelId (line 20) | function normalizeGoogleModelId(model: string): string { function isGoogleMultimodal (line 24) | function isGoogleMultimodal(model: string): boolean { function isGoogleImagen (line 29) | function isGoogleImagen(model: string): boolean { function getGoogleApiKey (line 34) | function getGoogleApiKey(): string | null { function getGoogleImageSize (line 38) | function getGoogleImageSize(args: CliArgs): "1K" | "2K" | "4K" { function getGoogleBaseUrl (line 43) | function getGoogleBaseUrl(): string { function buildGoogleUrl (line 49) | function buildGoogleUrl(pathname: string): string { function toModelPath (line 56) | function toModelPath(model: string): string { function getHttpProxy (line 61) | function getHttpProxy(): string | null { function postGoogleJsonViaCurl (line 72) | async function postGoogleJsonViaCurl( function postGoogleJsonViaFetch (line 124) | async function postGoogleJsonViaFetch( function postGoogleJson (line 146) | async function postGoogleJson(pathname: string, body: unknown): Promi... function buildPromptWithAspect (line 165) | function buildPromptWithAspect( function addAspectRatioToPrompt (line 180) | function addAspectRatioToPrompt(prompt: string, ar: string | null): stri... function readImageAsBase64 (line 185) | async function readImageAsBase64( function extractInlineImageData (line 197) | function extractInlineImageData(response: { function extractPredictedImageData (line 211) | function extractPredictedImageData(response: { function generateWithGemini (line 236) | async function generateWithGemini( function generateWithImagen (line 281) | async function generateWithImagen( function generateImage (line 328) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/providers/jimeng.ts type JimengSizePreset (line 4) | type JimengSizePreset = "normal" | "2k" | "4k"; function getDefaultModel (line 6) | function getDefaultModel(): string { function getAccessKey (line 10) | function getAccessKey(): string | null { function getSecretKey (line 14) | function getSecretKey(): string | null { function getRegion (line 18) | function getRegion(): string { function getBaseUrl (line 22) | function getBaseUrl(): string { function resolveEndpoint (line 26) | function resolveEndpoint(query: Record): { function generateSignature (line 55) | function generateSignature( function parseAspectRatio (line 139) | function parseAspectRatio(ar: string): { width: number; height: number }... constant SIZE_PRESETS (line 152) | const SIZE_PRESETS: Record> = { function normalizeDimensions (line 176) | function normalizeDimensions(value: string): string | null { function getClosestPresetSize (line 182) | function getClosestPresetSize(ar: string | null, qualityLevel: JimengSiz... function normalizeImageSizePreset (line 208) | function normalizeImageSizePreset(imageSize: string, ar: string | null):... function getImageSize (line 216) | function getImageSize(ar: string | null, quality: CliArgs["quality"], im... function submitTask (line 230) | async function submitTask( function pollForResult (line 317) | async function pollForResult( function generateImage (line 435) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/providers/openai.ts function getDefaultModel (line 5) | function getDefaultModel(): string { type OpenAIImageResponse (line 9) | type OpenAIImageResponse = { data: Array<{ url?: string; b64_json?: stri... function parseAspectRatio (line 11) | function parseAspectRatio(ar: string): { width: number; height: number }... type SizeMapping (line 20) | type SizeMapping = { function getOpenAISize (line 26) | function getOpenAISize( function generateImage (line 63) | async function generateImage( function generateWithChatCompletions (line 95) | async function generateWithChatCompletions( function generateWithOpenAIGenerations (line 129) | async function generateWithOpenAIGenerations( function generateWithOpenAIEdits (line 161) | async function generateWithOpenAIEdits( function getMimeType (line 204) | function getMimeType(filename: string): string { function extractImageFromResponse (line 212) | async function extractImageFromResponse(result: OpenAIImageResponse): Pr... FILE: skills/baoyu-image-gen/scripts/providers/openrouter.ts constant DEFAULT_MODEL (line 5) | const DEFAULT_MODEL = "google/gemini-3.1-flash-image-preview"; type OpenRouterImageEntry (line 7) | type OpenRouterImageEntry = { type OpenRouterMessagePart (line 12) | type OpenRouterMessagePart = { type OpenRouterResponse (line 19) | type OpenRouterResponse = { function getDefaultModel (line 28) | function getDefaultModel(): string { function getApiKey (line 32) | function getApiKey(): string | null { function getBaseUrl (line 36) | function getBaseUrl(): string { function getHeaders (line 41) | function getHeaders(apiKey: string): Record { function parsePixelSize (line 61) | function parsePixelSize(value: string): { width: number; height: number ... function gcd (line 75) | function gcd(a: number, b: number): number { function inferAspectRatio (line 86) | function inferAspectRatio(size: string | null): string | null { function inferImageSize (line 95) | function inferImageSize(size: string | null): "1K" | "2K" | "4K" | null { function getImageSize (line 106) | function getImageSize(args: CliArgs): "1K" | "2K" | "4K" { function getAspectRatio (line 115) | function getAspectRatio(args: CliArgs): string | null { function getMimeType (line 119) | function getMimeType(filename: string): string { function readImageAsDataUrl (line 127) | async function readImageAsDataUrl(filePath: string): Promise { function buildContent (line 132) | function buildContent(prompt: string, referenceImages: string[]): Array<... function extractImageUrl (line 145) | function extractImageUrl(entry: OpenRouterImageEntry | OpenRouterMessage... function decodeDataUrl (line 152) | function decodeDataUrl(value: string): Uint8Array | null { function downloadImage (line 158) | async function downloadImage(value: string): Promise { function extractImageFromResponse (line 174) | async function extractImageFromResponse(result: OpenRouterResponse): Pro... function generateImage (line 200) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/providers/replicate.test.ts function makeArgs (line 11) | function makeArgs(overrides: Partial = {}): CliArgs { FILE: skills/baoyu-image-gen/scripts/providers/replicate.ts constant DEFAULT_MODEL (line 5) | const DEFAULT_MODEL = "google/nano-banana-pro"; constant SYNC_WAIT_SECONDS (line 6) | const SYNC_WAIT_SECONDS = 60; constant POLL_INTERVAL_MS (line 7) | const POLL_INTERVAL_MS = 2000; constant MAX_POLL_MS (line 8) | const MAX_POLL_MS = 300_000; function getDefaultModel (line 10) | function getDefaultModel(): string { function getApiToken (line 14) | function getApiToken(): string | null { function getBaseUrl (line 18) | function getBaseUrl(): string { function parseModelId (line 23) | function parseModelId(model: string): { owner: string; name: string; ver... function buildInput (line 34) | function buildInput(prompt: string, args: CliArgs, referenceImages: stri... function readImageAsDataUrl (line 62) | async function readImageAsDataUrl(p: string): Promise { type PredictionResponse (line 72) | type PredictionResponse = { function createPrediction (line 80) | async function createPrediction( function pollPrediction (line 121) | async function pollPrediction(apiToken: string, getUrl: string): Promise... function extractOutputUrl (line 147) | function extractOutputUrl(prediction: PredictionResponse): string { function downloadImage (line 165) | async function downloadImage(url: string): Promise { function generateImage (line 172) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/providers/seedream.test.ts function makeArgs (line 17) | function makeArgs(overrides: Partial = {}): CliArgs { function useEnv (line 38) | function useEnv( function makeTempPng (line 63) | async function makeTempPng(t: TestContext, name: string): Promise { FILE: skills/baoyu-image-gen/scripts/providers/seedream.ts type SeedreamModelFamily (line 6) | type SeedreamModelFamily = type SeedreamRequestImage (line 13) | type SeedreamRequestImage = string | string[]; type SeedreamRequestBody (line 15) | type SeedreamRequestBody = { type SeedreamImageResponse (line 25) | type SeedreamImageResponse = { function getDefaultModel (line 48) | function getDefaultModel(): string { function getApiKey (line 52) | function getApiKey(): string | null { function getBaseUrl (line 56) | function getBaseUrl(): string { function parsePixelSize (line 60) | function parsePixelSize(value: string): { width: number; height: number ... function normalizePixelSize (line 73) | function normalizePixelSize(value: string): string | null { function normalizeSizePreset (line 79) | function normalizeSizePreset(value: string): string | null { function normalizeSizeValue (line 86) | function normalizeSizeValue(value: string): string | null { function getMimeType (line 90) | function getMimeType(filename: string): string { function readImageAsDataUrl (line 100) | async function readImageAsDataUrl(filePath: string): Promise { function getModelFamily (line 105) | function getModelFamily(model: string): SeedreamModelFamily { function isRemovedSeededitModel (line 114) | function isRemovedSeededitModel(model: string): boolean { function assertSupportedModel (line 118) | function assertSupportedModel(model: string): void { function supportsReferenceImages (line 126) | function supportsReferenceImages(model: string): boolean { function supportsOutputFormat (line 131) | function supportsOutputFormat(model: string): boolean { function getDefaultOutputExtension (line 135) | function getDefaultOutputExtension(model: string): ".png" | ".jpg" { function getDefaultSeedreamSize (line 140) | function getDefaultSeedreamSize(model: string, args: CliArgs): string { function resolveSeedreamSize (line 151) | function resolveSeedreamSize(model: string, args: CliArgs): string { function validateArgs (line 203) | function validateArgs(model: string, args: CliArgs): void { function buildImageInput (line 230) | async function buildImageInput( function buildRequestBody (line 242) | function buildRequestBody( function downloadImage (line 269) | async function downloadImage(url: string): Promise { function extractImageFromResponse (line 279) | async function extractImageFromResponse(result: SeedreamImageResponse): ... function generateImage (line 302) | async function generateImage( FILE: skills/baoyu-image-gen/scripts/types.ts type Provider (line 1) | type Provider = "google" | "openai" | "openrouter" | "dashscope" | "repl... type Quality (line 2) | type Quality = "normal" | "2k"; type CliArgs (line 4) | type CliArgs = { type BatchTaskInput (line 22) | type BatchTaskInput = { type BatchFile (line 37) | type BatchFile = type ExtendConfig (line 44) | type ExtendConfig = { FILE: skills/baoyu-markdown-to-html/scripts/main.ts type ImageInfo (line 18) | interface ImageInfo { type ParsedResult (line 24) | interface ParsedResult { function convertMarkdown (line 33) | async function convertMarkdown( function printUsage (line 114) | function printUsage(): never { function main (line 150) | async function main(): Promise { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/cli.ts function printUsage (line 11) | function printUsage(): void { function parseArgValue (line 33) | function parseArgValue(argv: string[], i: number, flag: string): string ... function resolveFontFamily (line 42) | function resolveFontFamily(value: string): string { function resolveColor (line 46) | function resolveColor(value: string): string { function parseArgs (line 50) | function parseArgs(argv: string[]): CliOptions | null { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/constants.ts constant FONT_FAMILY_MAP (line 3) | const FONT_FAMILY_MAP: Record = { constant FONT_SIZE_OPTIONS (line 10) | const FONT_SIZE_OPTIONS = ["14px", "15px", "16px", "17px", "18px"]; constant COLOR_PRESETS (line 12) | const COLOR_PRESETS: Record = { constant CODE_BLOCK_THEMES (line 28) | const CODE_BLOCK_THEMES = [ constant DEFAULT_STYLE (line 48) | const DEFAULT_STYLE: StyleConfig = { constant THEME_STYLE_DEFAULTS (line 58) | const THEME_STYLE_DEFAULTS: Record> = { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/content.ts type FrontmatterFields (line 3) | type FrontmatterFields = Record; function parseFrontmatter (line 5) | function parseFrontmatter(content: string): { function serializeFrontmatter (line 28) | function serializeFrontmatter(frontmatter: FrontmatterFields): string { function stripWrappingQuotes (line 34) | function stripWrappingQuotes(value: string): string { function toFrontmatterString (line 49) | function toFrontmatterString(value: unknown): string | undefined { function pickFirstString (line 59) | function pickFirstString( function extractTitleFromMarkdown (line 70) | function extractTitleFromMarkdown(markdown: string): string { function extractSummaryFromBody (line 79) | function extractSummaryFromBody(body: string, maxLen: number): string { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/document.test.ts function useCwd (line 18) | function useCwd(t: TestContext, cwd: string): void { function makeTempDir (line 26) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/document.ts type RenderMarkdownDocumentOptions (line 32) | interface RenderMarkdownDocumentOptions { type RenderMarkdownDocumentResult (line 48) | interface RenderMarkdownDocumentResult { function resolveColorToken (line 57) | function resolveColorToken(value?: string): string | undefined { function resolveFontFamilyToken (line 62) | function resolveFontFamilyToken(value?: string): string | undefined { function formatTimestamp (line 67) | function formatTimestamp(date = new Date()): string { function buildMarkdownDocumentMeta (line 74) | function buildMarkdownDocumentMeta( function resolveMarkdownStyle (line 93) | function resolveMarkdownStyle(options: RenderMarkdownDocumentOptions = {... function resolveRenderOptions (line 106) | function resolveRenderOptions( function renderMarkdownDocument (line 128) | async function renderMarkdownDocument( function renderMarkdownFileToHtml (line 176) | async function renderMarkdownFileToHtml( FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extend-config.ts function extractYamlFrontMatter (line 6) | function extractYamlFrontMatter(content: string): string | null { function parseExtendYaml (line 11) | function parseExtendYaml(yaml: string): Partial { function loadExtendConfig (line 37) | function loadExtendConfig(): Partial { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/alert.ts type AlertOptions (line 3) | interface AlertOptions { type AlertVariantItem (line 9) | interface AlertVariantItem { function ucfirst (line 16) | function ucfirst(str: string) { function markedAlert (line 25) | function markedAlert(options: AlertOptions = {}): MarkedExtension { function resolveVariants (line 264) | function resolveVariants(variants: AlertVariantItem[]) { function createSyntaxPattern (line 282) | function createSyntaxPattern(type: string) { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/footnotes.ts type MapContent (line 11) | interface MapContent { function markedFootnotes (line 17) | function markedFootnotes(): MarkedExtension { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/infographic.ts type InfographicOptions (line 3) | interface InfographicOptions { function renderInfographic (line 7) | async function renderInfographic(containerId: string, code: string, opti... function markedInfographic (line 82) | function markedInfographic(options?: InfographicOptions): MarkedExtension { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/katex.ts type MarkedKatexOptions (line 3) | interface MarkedKatexOptions { function createRenderer (line 16) | function createRenderer(display: boolean, withStyle: boolean = true) { function inlineKatex (line 46) | function inlineKatex(options: MarkedKatexOptions | undefined, renderer: ... function blockKatex (line 88) | function blockKatex(_options: MarkedKatexOptions | undefined, renderer: ... function inlineLatexKatex (line 107) | function inlineLatexKatex(_options: MarkedKatexOptions | undefined, rend... function blockLatexKatex (line 130) | function blockLatexKatex(_options: MarkedKatexOptions | undefined, rende... function MDKatex (line 153) | function MDKatex(options: MarkedKatexOptions | undefined, withStyle: boo... FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/markup.ts function markedMarkup (line 9) | function markedMarkup(): MarkedExtension { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/extensions/plantuml.ts type PlantUMLOptions (line 4) | interface PlantUMLOptions { function encode6bit (line 37) | function encode6bit(b: number): string { function append3bytes (line 63) | function append3bytes(b1: number, b2: number, b3: number): string { function encode64 (line 80) | function encode64(data: string): string { function performDeflate (line 100) | function performDeflate(input: string): string { function encodePlantUML (line 122) | function encodePlantUML(plantumlCode: string): string { function generatePlantUMLUrl (line 142) | function generatePlantUMLUrl(code: string, options: Required { function createPlantUMLHTML (line 216) | function createPlantUMLHTML(imageUrl: string, options: Required { function normalizeCssText (line 94) | function normalizeCssText(cssText: string, style: StyleConfig = DEFAULT_... function normalizeInlineCss (line 112) | function normalizeInlineCss(html: string, style: StyleConfig = DEFAULT_S... function modifyHtmlStructure (line 130) | function modifyHtmlStructure(htmlString: string): string { function removeFirstHeading (line 140) | function removeFirstHeading(html: string): string { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/images.test.ts function makeTempDir (line 14) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/images.ts type ImagePlaceholder (line 7) | interface ImagePlaceholder { type ResolvedImageInfo (line 13) | interface ResolvedImageInfo extends ImagePlaceholder { function replaceMarkdownImagesWithPlaceholders (line 17) | function replaceMarkdownImagesWithPlaceholders( function getImageExtension (line 40) | function getImageExtension(urlOrPath: string): string { function downloadFile (line 45) | async function downloadFile(url: string, destPath: string): Promise { function resolveImagePath (line 88) | async function resolveImagePath( function resolveContentImages (line 112) | async function resolveContentImages( function resolveLocalWithFallback (line 130) | function resolveLocalWithFallback(resolved: string, logLabel: string): s... FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/render.ts function main (line 7) | async function main(): Promise { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/renderer.ts function escapeHtml (line 39) | function escapeHtml(text: string): string { function buildAddition (line 49) | function buildAddition(): string { function buildFootnoteArray (line 68) | function buildFootnoteArray(footnotes: [number, string, string][]): stri... function transform (line 78) | function transform(legend: string, text: string | null, title: string | ... function parseFrontMatterAndContent (line 91) | function parseFrontMatterAndContent(markdownText: string): ParseResult { function wrapInlineCode (line 112) | function wrapInlineCode(value: string): string { function initRenderer (line 119) | function initRenderer(opts: IOpts = {}): RendererAPI { function preprocessCjkEmphasis (line 372) | function preprocessCjkEmphasis(markdown: string): string { function renderMarkdown (line 407) | function renderMarkdown(raw: string, renderer: RendererAPI): { function postProcessHtml (line 418) | function postProcessHtml( FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/themes.ts constant SCRIPT_DIR (line 6) | const SCRIPT_DIR = path.dirname(fileURLToPath(import.meta.url)); constant THEME_DIR (line 7) | const THEME_DIR = path.resolve(SCRIPT_DIR, "themes"); constant FALLBACK_THEMES (line 8) | const FALLBACK_THEMES: ThemeName[] = ["default", "grace", "simple"]; function stripOutputScope (line 10) | function stripOutputScope(cssContent: string): string { function discoverThemesFromDir (line 18) | function discoverThemesFromDir(dir: string): string[] { function resolveThemeNames (line 29) | function resolveThemeNames(): ThemeName[] { constant THEME_NAMES (line 37) | const THEME_NAMES: ThemeName[] = resolveThemeNames(); function loadThemeCss (line 39) | function loadThemeCss(theme: ThemeName): { function normalizeThemeCss (line 60) | function normalizeThemeCss(css: string): string { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/types.ts type ThemeName (line 3) | type ThemeName = string; type StyleConfig (line 5) | interface StyleConfig { type IOpts (line 15) | interface IOpts { type RendererAPI (line 24) | interface RendererAPI { type ParseResult (line 39) | interface ParseResult { type CliOptions (line 45) | interface CliOptions { type ExtendConfig (line 60) | interface ExtendConfig { type HtmlDocumentMeta (line 74) | interface HtmlDocumentMeta { FILE: skills/baoyu-markdown-to-html/scripts/vendor/baoyu-md/src/utils/languages.ts constant COMMON_LANGUAGES (line 39) | const COMMON_LANGUAGES: Record = { constant HLJS_VERSION (line 79) | const HLJS_VERSION = `11.11.1` constant HLJS_CDN_BASE (line 80) | const HLJS_CDN_BASE = `https://cdn-doocs.oss-cn-shenzhen.aliyuncs.com/np... function grammarUrlFor (line 88) | function grammarUrlFor(language: string): string { function loadAndRegisterLanguage (line 97) | async function loadAndRegisterLanguage(language: string, hljs: any): Pro... function formatHighlightedCode (line 131) | function formatHighlightedCode(html: string, preserveNewlines = false): ... function highlightAndFormatCode (line 159) | function highlightAndFormatCode(text: string, language: string, hljs: an... function highlightCodeBlock (line 191) | function highlightCodeBlock(codeBlock: Element, language: string, hljs: ... function highlightPendingBlocks (line 214) | function highlightPendingBlocks(hljs: any, container: Document | Element... FILE: skills/baoyu-post-to-wechat/scripts/cdp.ts constant CHROME_CANDIDATES_FULL (line 19) | const CHROME_CANDIDATES_FULL: PlatformCandidates = { function getWslWindowsHome (line 44) | function getWslWindowsHome(): string | null { function getFreePort (line 65) | async function getFreePort(): Promise { function findChromeExecutable (line 69) | function findChromeExecutable(chromePathOverride?: string): string | und... function getDefaultProfileDir (line 77) | function getDefaultProfileDir(): string { function getAccountProfileDir (line 84) | function getAccountProfileDir(alias: string): string { type ChromeSession (line 89) | interface ChromeSession { function tryConnectExisting (line 95) | async function tryConnectExisting(port: number): Promise { function evaluate (line 249) | async function evaluate(session: ChromeSession, expression:... FILE: skills/baoyu-post-to-wechat/scripts/check-permissions.ts type CheckResult (line 9) | interface CheckResult { function log (line 17) | function log(label: string, ok: boolean, detail: string): void { function warn (line 23) | function warn(label: string, detail: string): void { function checkChrome (line 28) | async function checkChrome(): Promise { function checkProfileIsolation (line 37) | async function checkProfileIsolation(): Promise { function checkAccessibility (line 63) | async function checkAccessibility(): Promise { function checkClipboardCopy (line 90) | async function checkClipboardCopy(): Promise { function checkPasteKeystroke (line 149) | async function checkPasteKeystroke(): Promise { function checkBun (line 179) | async function checkBun(): Promise { function checkApiCredentials (line 188) | async function checkApiCredentials(): Promise { function checkRunningChromeConflict (line 210) | async function checkRunningChromeConflict(): Promise { function main (line 223) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/copy-to-clipboard.ts constant SUPPORTED_IMAGE_EXTS (line 8) | const SUPPORTED_IMAGE_EXTS = new Set(['.jpg', '.jpeg', '.png', '.gif', '... function printUsage (line 10) | function printUsage(exitCode = 0): never { function resolvePath (line 30) | function resolvePath(filePath: string): string { function inferImageMimeType (line 34) | function inferImageMimeType(imagePath: string): string { type RunResult (line 51) | type RunResult = { stdout: string; stderr: string; exitCode: number }; function runCommand (line 53) | async function runCommand( function commandExists (line 85) | async function commandExists(command: string): Promise { function runCommandWithFileStdin (line 94) | async function runCommandWithFileStdin(command: string, args: string[], ... function withTempDir (line 119) | async function withTempDir(prefix: string, fn: (tempDir: string) => P... function getMacSwiftClipboardSource (line 128) | function getMacSwiftClipboardSource(): string { function copyImageMac (line 189) | async function copyImageMac(imagePath: string): Promise { function copyHtmlMac (line 197) | async function copyHtmlMac(htmlFilePath: string): Promise { function copyImageLinux (line 205) | async function copyImageLinux(imagePath: string): Promise { function copyHtmlLinux (line 218) | async function copyHtmlLinux(htmlFilePath: string): Promise { function copyImageWindows (line 230) | async function copyImageWindows(imagePath: string): Promise { function copyHtmlWindows (line 242) | async function copyHtmlWindows(htmlFilePath: string): Promise { function copyImageToClipboard (line 252) | async function copyImageToClipboard(imagePathInput: string): Promise { function copyHtmlToClipboard (line 306) | async function copyHtmlToClipboard(args: string[]): Promise { function main (line 353) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/md-to-wechat.ts type ImageInfo (line 18) | interface ImageInfo { type ParsedResult (line 24) | interface ParsedResult { function convertMarkdown (line 32) | async function convertMarkdown( function printUsage (line 89) | function printUsage(): never { function main (line 124) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/paste-from-clipboard.ts function printUsage (line 4) | function printUsage(exitCode = 0): never { function sleepSync (line 31) | function sleepSync(ms: number): void { function activateApp (line 35) | function activateApp(appName: string): boolean { function pasteMac (line 58) | function pasteMac(retries: number, delayMs: number, targetApp?: string):... function pasteLinux (line 95) | function pasteLinux(retries: number, delayMs: number): boolean { function pasteWindows (line 123) | function pasteWindows(retries: number, delayMs: number): boolean { function paste (line 142) | function paste(retries: number, delayMs: number, targetApp?: string): bo... function main (line 156) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-chrome-cdp/src/index.test.ts function useEnv (line 20) | function useEnv( function makeTempDir (line 45) | async function makeTempDir(prefix: string): Promise { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record = { constant FONT_SIZE_OPTIONS (line 10) | const FONT_SIZE_OPTIONS = ["14px", "15px", "16px", "17px", "18px"]; constant COLOR_PRESETS (line 12) | const COLOR_PRESETS: Record = { constant CODE_BLOCK_THEMES (line 28) | const CODE_BLOCK_THEMES = [ constant DEFAULT_STYLE (line 48) | const DEFAULT_STYLE: StyleConfig = { constant THEME_STYLE_DEFAULTS (line 58) | const THEME_STYLE_DEFAULTS: Record> = { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/content.ts type FrontmatterFields (line 3) | type FrontmatterFields = Record; function parseFrontmatter (line 5) | function parseFrontmatter(content: string): { function serializeFrontmatter (line 28) | function serializeFrontmatter(frontmatter: FrontmatterFields): string { function stripWrappingQuotes (line 34) | function stripWrappingQuotes(value: string): string { function toFrontmatterString (line 49) | function toFrontmatterString(value: unknown): string | undefined { function pickFirstString (line 59) | function pickFirstString( function extractTitleFromMarkdown (line 70) | function extractTitleFromMarkdown(markdown: string): string { function extractSummaryFromBody (line 79) | function extractSummaryFromBody(body: string, maxLen: number): string { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/document.test.ts function useCwd (line 18) | function useCwd(t: TestContext, cwd: string): void { function makeTempDir (line 26) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/document.ts type RenderMarkdownDocumentOptions (line 32) | interface RenderMarkdownDocumentOptions { type RenderMarkdownDocumentResult (line 48) | interface RenderMarkdownDocumentResult { function resolveColorToken (line 57) | function resolveColorToken(value?: string): string | undefined { function resolveFontFamilyToken (line 62) | function resolveFontFamilyToken(value?: string): string | undefined { function formatTimestamp (line 67) | function formatTimestamp(date = new Date()): string { function buildMarkdownDocumentMeta (line 74) | function buildMarkdownDocumentMeta( function resolveMarkdownStyle (line 93) | function resolveMarkdownStyle(options: RenderMarkdownDocumentOptions = {... function resolveRenderOptions (line 106) | function resolveRenderOptions( function renderMarkdownDocument (line 128) | async function renderMarkdownDocument( function renderMarkdownFileToHtml (line 176) | async function renderMarkdownFileToHtml( FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extend-config.ts function extractYamlFrontMatter (line 6) | function extractYamlFrontMatter(content: string): string | null { function parseExtendYaml (line 11) | function parseExtendYaml(yaml: string): Partial { function loadExtendConfig (line 37) | function loadExtendConfig(): Partial { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/alert.ts type AlertOptions (line 3) | interface AlertOptions { type AlertVariantItem (line 9) | interface AlertVariantItem { function ucfirst (line 16) | function ucfirst(str: string) { function markedAlert (line 25) | function markedAlert(options: AlertOptions = {}): MarkedExtension { function resolveVariants (line 264) | function resolveVariants(variants: AlertVariantItem[]) { function createSyntaxPattern (line 282) | function createSyntaxPattern(type: string) { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/footnotes.ts type MapContent (line 11) | interface MapContent { function markedFootnotes (line 17) | function markedFootnotes(): MarkedExtension { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/infographic.ts type InfographicOptions (line 3) | interface InfographicOptions { function renderInfographic (line 7) | async function renderInfographic(containerId: string, code: string, opti... function markedInfographic (line 82) | function markedInfographic(options?: InfographicOptions): MarkedExtension { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/katex.ts type MarkedKatexOptions (line 3) | interface MarkedKatexOptions { function createRenderer (line 16) | function createRenderer(display: boolean, withStyle: boolean = true) { function inlineKatex (line 46) | function inlineKatex(options: MarkedKatexOptions | undefined, renderer: ... function blockKatex (line 88) | function blockKatex(_options: MarkedKatexOptions | undefined, renderer: ... function inlineLatexKatex (line 107) | function inlineLatexKatex(_options: MarkedKatexOptions | undefined, rend... function blockLatexKatex (line 130) | function blockLatexKatex(_options: MarkedKatexOptions | undefined, rende... function MDKatex (line 153) | function MDKatex(options: MarkedKatexOptions | undefined, withStyle: boo... FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/markup.ts function markedMarkup (line 9) | function markedMarkup(): MarkedExtension { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/extensions/plantuml.ts type PlantUMLOptions (line 4) | interface PlantUMLOptions { function encode6bit (line 37) | function encode6bit(b: number): string { function append3bytes (line 63) | function append3bytes(b1: number, b2: number, b3: number): string { function encode64 (line 80) | function encode64(data: string): string { function performDeflate (line 100) | function performDeflate(input: string): string { function encodePlantUML (line 122) | function encodePlantUML(plantumlCode: string): string { function generatePlantUMLUrl (line 142) | function generatePlantUMLUrl(code: string, options: Required { function createPlantUMLHTML (line 216) | function createPlantUMLHTML(imageUrl: string, options: Required { function normalizeCssText (line 94) | function normalizeCssText(cssText: string, style: StyleConfig = DEFAULT_... function normalizeInlineCss (line 112) | function normalizeInlineCss(html: string, style: StyleConfig = DEFAULT_S... function modifyHtmlStructure (line 130) | function modifyHtmlStructure(htmlString: string): string { function removeFirstHeading (line 140) | function removeFirstHeading(html: string): string { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/images.test.ts function makeTempDir (line 14) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/images.ts type ImagePlaceholder (line 7) | interface ImagePlaceholder { type ResolvedImageInfo (line 13) | interface ResolvedImageInfo extends ImagePlaceholder { function replaceMarkdownImagesWithPlaceholders (line 17) | function replaceMarkdownImagesWithPlaceholders( function getImageExtension (line 40) | function getImageExtension(urlOrPath: string): string { function downloadFile (line 45) | async function downloadFile(url: string, destPath: string): Promise { function resolveImagePath (line 88) | async function resolveImagePath( function resolveContentImages (line 112) | async function resolveContentImages( function resolveLocalWithFallback (line 130) | function resolveLocalWithFallback(resolved: string, logLabel: string): s... FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/render.ts function main (line 7) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/renderer.ts function escapeHtml (line 39) | function escapeHtml(text: string): string { function buildAddition (line 49) | function buildAddition(): string { function buildFootnoteArray (line 68) | function buildFootnoteArray(footnotes: [number, string, string][]): stri... function transform (line 78) | function transform(legend: string, text: string | null, title: string | ... function parseFrontMatterAndContent (line 91) | function parseFrontMatterAndContent(markdownText: string): ParseResult { function wrapInlineCode (line 112) | function wrapInlineCode(value: string): string { function initRenderer (line 119) | function initRenderer(opts: IOpts = {}): RendererAPI { function preprocessCjkEmphasis (line 372) | function preprocessCjkEmphasis(markdown: string): string { function renderMarkdown (line 407) | function renderMarkdown(raw: string, renderer: RendererAPI): { function postProcessHtml (line 418) | function postProcessHtml( FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/themes.ts constant SCRIPT_DIR (line 6) | const SCRIPT_DIR = path.dirname(fileURLToPath(import.meta.url)); constant THEME_DIR (line 7) | const THEME_DIR = path.resolve(SCRIPT_DIR, "themes"); constant FALLBACK_THEMES (line 8) | const FALLBACK_THEMES: ThemeName[] = ["default", "grace", "simple"]; function stripOutputScope (line 10) | function stripOutputScope(cssContent: string): string { function discoverThemesFromDir (line 18) | function discoverThemesFromDir(dir: string): string[] { function resolveThemeNames (line 29) | function resolveThemeNames(): ThemeName[] { constant THEME_NAMES (line 37) | const THEME_NAMES: ThemeName[] = resolveThemeNames(); function loadThemeCss (line 39) | function loadThemeCss(theme: ThemeName): { function normalizeThemeCss (line 60) | function normalizeThemeCss(css: string): string { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/types.ts type ThemeName (line 3) | type ThemeName = string; type StyleConfig (line 5) | interface StyleConfig { type IOpts (line 15) | interface IOpts { type RendererAPI (line 24) | interface RendererAPI { type ParseResult (line 39) | interface ParseResult { type CliOptions (line 45) | interface CliOptions { type ExtendConfig (line 60) | interface ExtendConfig { type HtmlDocumentMeta (line 74) | interface HtmlDocumentMeta { FILE: skills/baoyu-post-to-wechat/scripts/vendor/baoyu-md/src/utils/languages.ts constant COMMON_LANGUAGES (line 39) | const COMMON_LANGUAGES: Record = { constant HLJS_VERSION (line 79) | const HLJS_VERSION = `11.11.1` constant HLJS_CDN_BASE (line 80) | const HLJS_CDN_BASE = `https://cdn-doocs.oss-cn-shenzhen.aliyuncs.com/np... function grammarUrlFor (line 88) | function grammarUrlFor(language: string): string { function loadAndRegisterLanguage (line 97) | async function loadAndRegisterLanguage(language: string, hljs: any): Pro... function formatHighlightedCode (line 131) | function formatHighlightedCode(html: string, preserveNewlines = false): ... function highlightAndFormatCode (line 159) | function highlightAndFormatCode(text: string, language: string, hljs: an... function highlightCodeBlock (line 191) | function highlightCodeBlock(codeBlock: Element, language: string, hljs: ... function highlightPendingBlocks (line 214) | function highlightPendingBlocks(hljs: any, container: Document | Element... FILE: skills/baoyu-post-to-wechat/scripts/wechat-agent-browser.ts constant WECHAT_URL (line 6) | const WECHAT_URL = 'https://mp.weixin.qq.com/'; constant SESSION (line 7) | const SESSION = 'wechat-post'; function sleep (line 9) | function sleep(ms: number): Promise { function quoteForLog (line 13) | function quoteForLog(arg: string): string { function toSafeJsStringLiteral (line 17) | function toSafeJsStringLiteral(value: string): string { function runAgentBrowser (line 23) | function runAgentBrowser(args: string[]): { function ab (line 41) | function ab(args: string[], json = false): string { function abRaw (line 54) | function abRaw(args: string[]): { success: boolean; output: string } { type SnapshotElement (line 58) | interface SnapshotElement { function parseSnapshot (line 64) | function parseSnapshot(output: string): SnapshotElement[] { function findElementByText (line 85) | function findElementByText(snapshot: string, text: string): string | null { function findElementBySelector (line 98) | function findElementBySelector(snapshot: string, selector: string): stri... type WeChatOptions (line 102) | interface WeChatOptions { function postToWeChat (line 110) | async function postToWeChat(options: WeChatOptions): Promise { function printUsage (line 298) | function printUsage(): never { function main (line 319) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/wechat-api.ts type AccessTokenResponse (line 12) | interface AccessTokenResponse { type UploadResponse (line 18) | interface UploadResponse { type PublishResponse (line 25) | interface PublishResponse { type ImageInfo (line 31) | interface ImageInfo { type MarkdownRenderResult (line 37) | interface MarkdownRenderResult { type ArticleType (line 45) | type ArticleType = "news" | "newspic"; type ArticleOptions (line 47) | interface ArticleOptions { constant TOKEN_URL (line 59) | const TOKEN_URL = "https://api.weixin.qq.com/cgi-bin/token"; constant UPLOAD_BODY_IMG_URL (line 60) | const UPLOAD_BODY_IMG_URL = "https://api.weixin.qq.com/cgi-bin/media/upl... constant UPLOAD_MATERIAL_URL (line 61) | const UPLOAD_MATERIAL_URL = "https://api.weixin.qq.com/cgi-bin/material/... constant DRAFT_URL (line 62) | const DRAFT_URL = "https://api.weixin.qq.com/cgi-bin/draft/add"; function fetchAccessToken (line 64) | async function fetchAccessToken(appId: string, appSecret: string): Promi... function toHttpsUrl (line 80) | function toHttpsUrl(url: string | undefined): string { function loadUploadAsset (line 85) | async function loadUploadAsset( function uploadImage (line 150) | async function uploadImage( function uploadToWechat (line 194) | async function uploadToWechat( function uploadImagesInHtml (line 233) | async function uploadImagesInHtml( function publishToDraft (line 341) | async function publishToDraft( function parseFrontmatter (line 396) | function parseFrontmatter(content: string): { frontmatter: Record { FILE: skills/baoyu-post-to-wechat/scripts/wechat-article.ts constant WECHAT_URL (line 9) | const WECHAT_URL = 'https://mp.weixin.qq.com/'; type ImageInfo (line 11) | interface ImageInfo { type ArticleOptions (line 17) | interface ArticleOptions { function waitForLogin (line 34) | async function waitForLogin(session: ChromeSession, timeoutMs = 120_000)... function waitForElement (line 44) | async function waitForElement(session: ChromeSession, selector: string, ... function clickMenuByText (line 54) | async function clickMenuByText(session: ChromeSession, text: string, max... function copyImageToClipboard (line 92) | async function copyImageToClipboard(imagePath: string): Promise { function pasteInEditor (line 100) | async function pasteInEditor(session: ChromeSession): Promise { function sendCopy (line 107) | async function sendCopy(cdp?: CdpConnection, sessionId?: string): Promis... function sendPaste (line 119) | async function sendPaste(cdp?: CdpConnection, sessionId?: string): Promi... function copyHtmlFromBrowser (line 131) | async function copyHtmlFromBrowser(cdp: CdpConnection, htmlFilePath: str... function pasteFromClipboardInEditor (line 191) | async function pasteFromClipboardInEditor(session: ChromeSession): Promi... function parseMarkdownWithPlaceholders (line 197) | async function parseMarkdownWithPlaceholders( function parseHtmlMeta (line 221) | function parseHtmlMeta(htmlPath: string): { title: string; author: strin... function selectAndReplacePlaceholder (line 289) | async function selectAndReplacePlaceholder(session: ChromeSession, place... function pressDeleteKey (line 332) | async function pressDeleteKey(session: ChromeSession): Promise { function removeExtraEmptyLineAfterImage (line 338) | async function removeExtraEmptyLineAfterImage(session: ChromeSession): P... function postArticle (line 403) | async function postArticle(options: ArticleOptions): Promise { function printUsage (line 690) | function printUsage(): never { function main (line 728) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/wechat-browser.ts constant WECHAT_URL (line 16) | const WECHAT_URL = 'https://mp.weixin.qq.com/'; type MarkdownMeta (line 18) | interface MarkdownMeta { function parseMarkdownFile (line 24) | function parseMarkdownFile(filePath: string): MarkdownMeta { function compressTitle (line 62) | function compressTitle(title: string, maxLen = 20): string { function compressContent (line 85) | function compressContent(content: string, maxLen = 1000): string { function loadImagesFromDir (line 105) | async function loadImagesFromDir(dir: string): Promise { type WeChatBrowserOptions (line 114) | interface WeChatBrowserOptions { function postToWeChat (line 126) | async function postToWeChat(options: WeChatBrowserOptions): Promise { function printUsage (line 655) | function printUsage(): never { function main (line 680) | async function main(): Promise { FILE: skills/baoyu-post-to-wechat/scripts/wechat-extend-config.ts type WechatAccount (line 5) | interface WechatAccount { type WechatExtendConfig (line 18) | interface WechatExtendConfig { type ResolvedAccount (line 29) | interface ResolvedAccount { function stripQuotes (line 41) | function stripQuotes(s: string): string { function toBool01 (line 45) | function toBool01(v: string): number { function parseWechatExtend (line 49) | function parseWechatExtend(content: string): WechatExtendConfig { function loadWechatExtendConfig (line 132) | function loadWechatExtendConfig(): WechatExtendConfig { function selectAccount (line 152) | function selectAccount(config: WechatExtendConfig, alias?: string): Wech... function resolveAccount (line 159) | function resolveAccount(config: WechatExtendConfig, alias?: string): Res... function loadEnvFile (line 174) | function loadEnvFile(envPath: string): Record { function aliasToEnvKey (line 195) | function aliasToEnvKey(alias: string): string { function loadCredentials (line 199) | function loadCredentials(account?: ResolvedAccount): { appId: string; ap... function listAccounts (line 243) | function listAccounts(config: WechatExtendConfig): string[] { FILE: skills/baoyu-post-to-wechat/scripts/wechat-image-processor.ts type WechatUploadAsset (line 7) | interface WechatUploadAsset { type PreparedWechatUploadAsset (line 15) | interface PreparedWechatUploadAsset { constant WECHAT_BODY_IMAGE_MAX_SIZE (line 23) | const WECHAT_BODY_IMAGE_MAX_SIZE = 1024 * 1024; constant WECHAT_BODY_IMAGE_UNSUPPORTED_FORMATS (line 24) | const WECHAT_BODY_IMAGE_UNSUPPORTED_FORMATS = new Set([ constant BODY_UPLOAD_ALLOWED_MIME_TYPES (line 34) | const BODY_UPLOAD_ALLOWED_MIME_TYPES = new Set([ constant MIME_TO_EXT (line 39) | const MIME_TO_EXT: Record = { constant JPEG_QUALITY_STEPS (line 52) | const JPEG_QUALITY_STEPS = [82, 74, 66, 58, 50, 42, 34]; constant MAX_WIDTH_STEPS (line 53) | const MAX_WIDTH_STEPS = [2560, 2048, 1600, 1280, 1024, 800, 640, 480]; type JimpImage (line 57) | type JimpImage = Awaited>; function normalizeMimeType (line 59) | function normalizeMimeType(contentType: string): string { function extFromMimeType (line 63) | function extFromMimeType(contentType: string): string { function ensureFileExt (line 67) | function ensureFileExt(asset: WechatUploadAsset): string { function basenameWithoutExt (line 71) | function basenameWithoutExt(filename: string): string { function renameWithExt (line 76) | function renameWithExt(filename: string, ext: string): string { function needsWechatBodyImageProcessing (line 80) | function needsWechatBodyImageProcessing(asset: WechatUploadAsset): boole... function ensureWebpDecoder (line 94) | async function ensureWebpDecoder(): Promise { function loadImageForProcessing (line 108) | async function loadImageForProcessing(asset: WechatUploadAsset): Promise... function imageHasTransparency (line 129) | function imageHasTransparency(image: JimpImage): boolean { function buildCandidateWidths (line 139) | function buildCandidateWidths(width: number): number[] { function resizeToWidth (line 151) | function resizeToWidth(image: JimpImage, width: number): JimpImage { function flattenOnWhite (line 159) | function flattenOnWhite(image: JimpImage): JimpImage { function encodePng (line 169) | async function encodePng(image: JimpImage): Promise { function encodeJpeg (line 173) | async function encodeJpeg(image: JimpImage, quality: number): Promise { function runCommandWithFileStdin (line 94) | async function runCommandWithFileStdin(command: string, args: string[], ... function withTempDir (line 119) | async function withTempDir(prefix: string, fn: (tempDir: string) => P... function getMacSwiftClipboardSource (line 128) | function getMacSwiftClipboardSource(): string { function copyImageMac (line 189) | async function copyImageMac(imagePath: string): Promise { function copyHtmlMac (line 197) | async function copyHtmlMac(htmlFilePath: string): Promise { function copyImageLinux (line 205) | async function copyImageLinux(imagePath: string): Promise { function copyHtmlLinux (line 218) | async function copyHtmlLinux(htmlFilePath: string): Promise { function copyImageWindows (line 230) | async function copyImageWindows(imagePath: string): Promise { function copyHtmlWindows (line 242) | async function copyHtmlWindows(htmlFilePath: string): Promise { function copyImageToClipboard (line 252) | async function copyImageToClipboard(imagePathInput: string): Promise { function copyHtmlToClipboard (line 306) | async function copyHtmlToClipboard(args: string[]): Promise { function main (line 353) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/md-to-html.ts type ImageInfo (line 20) | interface ImageInfo { type ParsedMarkdown (line 27) | interface ParsedMarkdown { function parseMarkdown (line 36) | async function parseMarkdown( function main (line 103) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/paste-from-clipboard.ts function printUsage (line 4) | function printUsage(exitCode = 0): never { function sleepSync (line 31) | function sleepSync(ms: number): void { function activateApp (line 35) | function activateApp(appName: string): boolean { function pasteMac (line 58) | function pasteMac(retries: number, delayMs: number, targetApp?: string):... function pasteLinux (line 95) | function pasteLinux(retries: number, delayMs: number): boolean { function pasteWindows (line 123) | function pasteWindows(retries: number, delayMs: number): boolean { function paste (line 142) | function paste(retries: number, delayMs: number, targetApp?: string): bo... function main (line 156) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-chrome-cdp/src/index.test.ts function useEnv (line 20) | function useEnv( function makeTempDir (line 45) | async function makeTempDir(prefix: string): Promise { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record = { constant FONT_SIZE_OPTIONS (line 10) | const FONT_SIZE_OPTIONS = ["14px", "15px", "16px", "17px", "18px"]; constant COLOR_PRESETS (line 12) | const COLOR_PRESETS: Record = { constant CODE_BLOCK_THEMES (line 28) | const CODE_BLOCK_THEMES = [ constant DEFAULT_STYLE (line 48) | const DEFAULT_STYLE: StyleConfig = { constant THEME_STYLE_DEFAULTS (line 58) | const THEME_STYLE_DEFAULTS: Record> = { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/content.ts type FrontmatterFields (line 3) | type FrontmatterFields = Record; function parseFrontmatter (line 5) | function parseFrontmatter(content: string): { function serializeFrontmatter (line 28) | function serializeFrontmatter(frontmatter: FrontmatterFields): string { function stripWrappingQuotes (line 34) | function stripWrappingQuotes(value: string): string { function toFrontmatterString (line 49) | function toFrontmatterString(value: unknown): string | undefined { function pickFirstString (line 59) | function pickFirstString( function extractTitleFromMarkdown (line 70) | function extractTitleFromMarkdown(markdown: string): string { function extractSummaryFromBody (line 79) | function extractSummaryFromBody(body: string, maxLen: number): string { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/document.test.ts function useCwd (line 18) | function useCwd(t: TestContext, cwd: string): void { function makeTempDir (line 26) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/document.ts type RenderMarkdownDocumentOptions (line 32) | interface RenderMarkdownDocumentOptions { type RenderMarkdownDocumentResult (line 48) | interface RenderMarkdownDocumentResult { function resolveColorToken (line 57) | function resolveColorToken(value?: string): string | undefined { function resolveFontFamilyToken (line 62) | function resolveFontFamilyToken(value?: string): string | undefined { function formatTimestamp (line 67) | function formatTimestamp(date = new Date()): string { function buildMarkdownDocumentMeta (line 74) | function buildMarkdownDocumentMeta( function resolveMarkdownStyle (line 93) | function resolveMarkdownStyle(options: RenderMarkdownDocumentOptions = {... function resolveRenderOptions (line 106) | function resolveRenderOptions( function renderMarkdownDocument (line 128) | async function renderMarkdownDocument( function renderMarkdownFileToHtml (line 176) | async function renderMarkdownFileToHtml( FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extend-config.ts function extractYamlFrontMatter (line 6) | function extractYamlFrontMatter(content: string): string | null { function parseExtendYaml (line 11) | function parseExtendYaml(yaml: string): Partial { function loadExtendConfig (line 37) | function loadExtendConfig(): Partial { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/alert.ts type AlertOptions (line 3) | interface AlertOptions { type AlertVariantItem (line 9) | interface AlertVariantItem { function ucfirst (line 16) | function ucfirst(str: string) { function markedAlert (line 25) | function markedAlert(options: AlertOptions = {}): MarkedExtension { function resolveVariants (line 264) | function resolveVariants(variants: AlertVariantItem[]) { function createSyntaxPattern (line 282) | function createSyntaxPattern(type: string) { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/footnotes.ts type MapContent (line 11) | interface MapContent { function markedFootnotes (line 17) | function markedFootnotes(): MarkedExtension { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/infographic.ts type InfographicOptions (line 3) | interface InfographicOptions { function renderInfographic (line 7) | async function renderInfographic(containerId: string, code: string, opti... function markedInfographic (line 82) | function markedInfographic(options?: InfographicOptions): MarkedExtension { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/katex.ts type MarkedKatexOptions (line 3) | interface MarkedKatexOptions { function createRenderer (line 16) | function createRenderer(display: boolean, withStyle: boolean = true) { function inlineKatex (line 46) | function inlineKatex(options: MarkedKatexOptions | undefined, renderer: ... function blockKatex (line 88) | function blockKatex(_options: MarkedKatexOptions | undefined, renderer: ... function inlineLatexKatex (line 107) | function inlineLatexKatex(_options: MarkedKatexOptions | undefined, rend... function blockLatexKatex (line 130) | function blockLatexKatex(_options: MarkedKatexOptions | undefined, rende... function MDKatex (line 153) | function MDKatex(options: MarkedKatexOptions | undefined, withStyle: boo... FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/markup.ts function markedMarkup (line 9) | function markedMarkup(): MarkedExtension { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/extensions/plantuml.ts type PlantUMLOptions (line 4) | interface PlantUMLOptions { function encode6bit (line 37) | function encode6bit(b: number): string { function append3bytes (line 63) | function append3bytes(b1: number, b2: number, b3: number): string { function encode64 (line 80) | function encode64(data: string): string { function performDeflate (line 100) | function performDeflate(input: string): string { function encodePlantUML (line 122) | function encodePlantUML(plantumlCode: string): string { function generatePlantUMLUrl (line 142) | function generatePlantUMLUrl(code: string, options: Required { function createPlantUMLHTML (line 216) | function createPlantUMLHTML(imageUrl: string, options: Required { function normalizeCssText (line 94) | function normalizeCssText(cssText: string, style: StyleConfig = DEFAULT_... function normalizeInlineCss (line 112) | function normalizeInlineCss(html: string, style: StyleConfig = DEFAULT_S... function modifyHtmlStructure (line 130) | function modifyHtmlStructure(htmlString: string): string { function removeFirstHeading (line 140) | function removeFirstHeading(html: string): string { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/images.test.ts function makeTempDir (line 14) | async function makeTempDir(prefix: string): Promise { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/images.ts type ImagePlaceholder (line 7) | interface ImagePlaceholder { type ResolvedImageInfo (line 13) | interface ResolvedImageInfo extends ImagePlaceholder { function replaceMarkdownImagesWithPlaceholders (line 17) | function replaceMarkdownImagesWithPlaceholders( function getImageExtension (line 40) | function getImageExtension(urlOrPath: string): string { function downloadFile (line 45) | async function downloadFile(url: string, destPath: string): Promise { function resolveImagePath (line 88) | async function resolveImagePath( function resolveContentImages (line 112) | async function resolveContentImages( function resolveLocalWithFallback (line 130) | function resolveLocalWithFallback(resolved: string, logLabel: string): s... FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/render.ts function main (line 7) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/renderer.ts function escapeHtml (line 39) | function escapeHtml(text: string): string { function buildAddition (line 49) | function buildAddition(): string { function buildFootnoteArray (line 68) | function buildFootnoteArray(footnotes: [number, string, string][]): stri... function transform (line 78) | function transform(legend: string, text: string | null, title: string | ... function parseFrontMatterAndContent (line 91) | function parseFrontMatterAndContent(markdownText: string): ParseResult { function wrapInlineCode (line 112) | function wrapInlineCode(value: string): string { function initRenderer (line 119) | function initRenderer(opts: IOpts = {}): RendererAPI { function preprocessCjkEmphasis (line 372) | function preprocessCjkEmphasis(markdown: string): string { function renderMarkdown (line 407) | function renderMarkdown(raw: string, renderer: RendererAPI): { function postProcessHtml (line 418) | function postProcessHtml( FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/themes.ts constant SCRIPT_DIR (line 6) | const SCRIPT_DIR = path.dirname(fileURLToPath(import.meta.url)); constant THEME_DIR (line 7) | const THEME_DIR = path.resolve(SCRIPT_DIR, "themes"); constant FALLBACK_THEMES (line 8) | const FALLBACK_THEMES: ThemeName[] = ["default", "grace", "simple"]; function stripOutputScope (line 10) | function stripOutputScope(cssContent: string): string { function discoverThemesFromDir (line 18) | function discoverThemesFromDir(dir: string): string[] { function resolveThemeNames (line 29) | function resolveThemeNames(): ThemeName[] { constant THEME_NAMES (line 37) | const THEME_NAMES: ThemeName[] = resolveThemeNames(); function loadThemeCss (line 39) | function loadThemeCss(theme: ThemeName): { function normalizeThemeCss (line 60) | function normalizeThemeCss(css: string): string { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/types.ts type ThemeName (line 3) | type ThemeName = string; type StyleConfig (line 5) | interface StyleConfig { type IOpts (line 15) | interface IOpts { type RendererAPI (line 24) | interface RendererAPI { type ParseResult (line 39) | interface ParseResult { type CliOptions (line 45) | interface CliOptions { type ExtendConfig (line 60) | interface ExtendConfig { type HtmlDocumentMeta (line 74) | interface HtmlDocumentMeta { FILE: skills/baoyu-post-to-weibo/scripts/vendor/baoyu-md/src/utils/languages.ts constant COMMON_LANGUAGES (line 39) | const COMMON_LANGUAGES: Record = { constant HLJS_VERSION (line 79) | const HLJS_VERSION = `11.11.1` constant HLJS_CDN_BASE (line 80) | const HLJS_CDN_BASE = `https://cdn-doocs.oss-cn-shenzhen.aliyuncs.com/np... function grammarUrlFor (line 88) | function grammarUrlFor(language: string): string { function loadAndRegisterLanguage (line 97) | async function loadAndRegisterLanguage(language: string, hljs: any): Pro... function formatHighlightedCode (line 131) | function formatHighlightedCode(html: string, preserveNewlines = false): ... function highlightAndFormatCode (line 159) | function highlightAndFormatCode(text: string, language: string, hljs: an... function highlightCodeBlock (line 191) | function highlightCodeBlock(codeBlock: Element, language: string, hljs: ... function highlightPendingBlocks (line 214) | function highlightPendingBlocks(hljs: any, container: Document | Element... FILE: skills/baoyu-post-to-weibo/scripts/weibo-article.ts constant WEIBO_ARTICLE_URL (line 19) | const WEIBO_ARTICLE_URL = 'https://card.weibo.com/article/v3/editor'; constant TITLE_MAX_LENGTH (line 21) | const TITLE_MAX_LENGTH = 32; constant SUMMARY_MAX_LENGTH (line 22) | const SUMMARY_MAX_LENGTH = 44; type ArticleOptions (line 24) | interface ArticleOptions { function publishArticle (line 33) | async function publishArticle(options: ArticleOptions): Promise { function printUsage (line 1000) | function printUsage(): never { function main (line 1028) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/weibo-post.ts constant WEIBO_HOME_URL (line 16) | const WEIBO_HOME_URL = 'https://weibo.com/'; constant MAX_FILES (line 18) | const MAX_FILES = 18; type WeiboPostOptions (line 20) | interface WeiboPostOptions { function postToWeibo (line 29) | async function postToWeibo(options: WeiboPostOptions): Promise { function printUsage (line 214) | function printUsage(): never { function main (line 237) | async function main(): Promise { FILE: skills/baoyu-post-to-weibo/scripts/weibo-utils.ts constant CHROME_CANDIDATES (line 20) | const CHROME_CANDIDATES: PlatformCandidates = { function getWslWindowsHome (line 38) | function getWslWindowsHome(): string | null { function findChromeExecutable (line 59) | function findChromeExecutable(chromePathOverride?: string): string | und... function findExistingChromeDebugPort (line 67) | async function findExistingChromeDebugPort(profileDir: string): Promise<... function killChromeByProfile (line 71) | function killChromeByProfile(profileDir: string): void { function getDefaultProfileDir (line 87) | function getDefaultProfileDir(): string { function getFreePort (line 94) | async function getFreePort(): Promise { function launchChrome (line 98) | async function launchChrome(url: string, profileDir: string, chromePathO... function getScriptDir (line 114) | function getScriptDir(): string { function runBunScript (line 118) | function runBunScript(scriptPath: string, args: string[]): boolean { function copyImageToClipboard (line 123) | function copyImageToClipboard(imagePath: string): boolean { function copyHtmlToClipboard (line 128) | function copyHtmlToClipboard(htmlPath: string): boolean { function pasteFromClipboard (line 133) | function pasteFromClipboard(targetApp?: string, retries = 3, delayMs = 5... FILE: skills/baoyu-post-to-x/scripts/check-paste-permissions.ts type CheckResult (line 9) | interface CheckResult { function log (line 17) | function log(label: string, ok: boolean, detail: string): void { function warn (line 23) | function warn(label: string, detail: string): void { function checkChrome (line 28) | async function checkChrome(): Promise { function checkProfileIsolation (line 37) | async function checkProfileIsolation(): Promise { function checkAccessibility (line 63) | async function checkAccessibility(): Promise { function checkClipboardCopy (line 90) | async function checkClipboardCopy(): Promise { function checkPasteKeystroke (line 149) | async function checkPasteKeystroke(): Promise { function checkBun (line 180) | async function checkBun(): Promise { function checkRunningChromeConflict (line 189) | async function checkRunningChromeConflict(): Promise { function main (line 202) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/copy-to-clipboard.ts constant SUPPORTED_IMAGE_EXTS (line 8) | const SUPPORTED_IMAGE_EXTS = new Set(['.jpg', '.jpeg', '.png', '.gif', '... function printUsage (line 10) | function printUsage(exitCode = 0): never { function resolvePath (line 30) | function resolvePath(filePath: string): string { function inferImageMimeType (line 34) | function inferImageMimeType(imagePath: string): string { type RunResult (line 51) | type RunResult = { stdout: string; stderr: string; exitCode: number }; function runCommand (line 53) | async function runCommand( function commandExists (line 85) | async function commandExists(command: string): Promise { function runCommandWithFileStdin (line 94) | async function runCommandWithFileStdin(command: string, args: string[], ... function withTempDir (line 119) | async function withTempDir(prefix: string, fn: (tempDir: string) => P... function getMacSwiftClipboardSource (line 128) | function getMacSwiftClipboardSource(): string { function copyImageMac (line 189) | async function copyImageMac(imagePath: string): Promise { function copyHtmlMac (line 197) | async function copyHtmlMac(htmlFilePath: string): Promise { function copyImageLinux (line 205) | async function copyImageLinux(imagePath: string): Promise { function copyHtmlLinux (line 218) | async function copyHtmlLinux(htmlFilePath: string): Promise { function copyImageWindows (line 230) | async function copyImageWindows(imagePath: string): Promise { function copyHtmlWindows (line 242) | async function copyHtmlWindows(htmlFilePath: string): Promise { function copyImageToClipboard (line 252) | async function copyImageToClipboard(imagePathInput: string): Promise { function copyHtmlToClipboard (line 306) | async function copyHtmlToClipboard(args: string[]): Promise { function main (line 353) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/md-to-html.ts type ImageInfo (line 17) | interface ImageInfo { type ParsedMarkdown (line 24) | interface ParsedMarkdown { type FrontmatterFields (line 32) | type FrontmatterFields = Record; function parseFrontmatter (line 34) | function parseFrontmatter(content: string): { frontmatter: FrontmatterFi... function stripWrappingQuotes (line 46) | function stripWrappingQuotes(value: string): string { function toFrontmatterString (line 58) | function toFrontmatterString(value: unknown): string | undefined { function pickFirstString (line 68) | function pickFirstString(frontmatter: FrontmatterFields, keys: string[])... function findCoverImageNearMarkdown (line 76) | function findCoverImageNearMarkdown(baseDir: string): string | null { function extractTitleFromMarkdown (line 98) | function extractTitleFromMarkdown(markdown: string): string { function downloadFile (line 108) | function downloadFile(url: string, destPath: string, maxRedirects = 5): ... function getImageExtension (line 158) | function getImageExtension(urlOrPath: string): string { function resolveImagePath (line 163) | async function resolveImagePath(imagePath: string, baseDir: string, temp... function escapeHtml (line 187) | function escapeHtml(text: string): string { function highlightCode (line 196) | function highlightCode(code: string, lang: string): string { function preprocessCjkMarkdown (line 207) | function preprocessCjkMarkdown(markdown: string): string { function convertMarkdownToHtml (line 221) | function convertMarkdownToHtml(markdown: string, imageCallback: (src: st... function parseMarkdown (line 288) | async function parseMarkdown( function printUsage (line 378) | function printUsage(): never { function main (line 405) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/paste-from-clipboard.ts function printUsage (line 4) | function printUsage(exitCode = 0): never { function sleepSync (line 31) | function sleepSync(ms: number): void { function activateApp (line 35) | function activateApp(appName: string): boolean { function pasteMac (line 58) | function pasteMac(retries: number, delayMs: number, targetApp?: string):... function pasteLinux (line 95) | function pasteLinux(retries: number, delayMs: number): boolean { function pasteWindows (line 123) | function pasteWindows(retries: number, delayMs: number): boolean { function paste (line 142) | function paste(retries: number, delayMs: number, targetApp?: string): bo... function main (line 156) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/vendor/baoyu-chrome-cdp/src/index.test.ts function useEnv (line 20) | function useEnv( function makeTempDir (line 45) | async function makeTempDir(prefix: string): Promise { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-post-to-x/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record { function printUsage (line 724) | function printUsage(): never { function main (line 751) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/x-browser.ts constant X_COMPOSE_URL (line 17) | const X_COMPOSE_URL = 'https://x.com/compose/post'; type XBrowserOptions (line 19) | interface XBrowserOptions { function postToX (line 28) | async function postToX(options: XBrowserOptions): Promise { function printUsage (line 196) | function printUsage(): never { function main (line 216) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/x-quote.ts function extractTweetUrl (line 15) | function extractTweetUrl(urlOrId: string): string | null { type QuoteOptions (line 23) | interface QuoteOptions { function quotePost (line 32) | async function quotePost(options: QuoteOptions): Promise { function printUsage (line 187) | function printUsage(): never { function main (line 205) | async function main(): Promise { FILE: skills/baoyu-post-to-x/scripts/x-utils.ts constant CHROME_CANDIDATES_BASIC (line 23) | const CHROME_CANDIDATES_BASIC: PlatformCandidates = { constant CHROME_CANDIDATES_FULL (line 40) | const CHROME_CANDIDATES_FULL: PlatformCandidates = { function findChromeExecutable (line 64) | function findChromeExecutable(candidates: PlatformCandidates): string | ... function getWslWindowsHome (line 72) | function getWslWindowsHome(): string | null { function getDefaultProfileDir (line 82) | function getDefaultProfileDir(): string { function getFreePort (line 89) | async function getFreePort(): Promise { function findExistingChromeDebugPort (line 93) | async function findExistingChromeDebugPort(profileDir: string): Promise<... function launchChrome (line 97) | async function launchChrome( function getScriptDir (line 118) | function getScriptDir(): string { function runBunScript (line 122) | function runBunScript(scriptPath: string, args: string[]): boolean { function copyImageToClipboard (line 127) | function copyImageToClipboard(imagePath: string): boolean { function copyHtmlToClipboard (line 132) | function copyHtmlToClipboard(htmlPath: string): boolean { function pasteFromClipboard (line 137) | function pasteFromClipboard(targetApp?: string, retries = 3, delayMs = 5... FILE: skills/baoyu-post-to-x/scripts/x-video.ts constant X_COMPOSE_URL (line 17) | const X_COMPOSE_URL = 'https://x.com/compose/post'; type XVideoOptions (line 19) | interface XVideoOptions { function postVideoToX (line 28) | async function postVideoToX(options: XVideoOptions): Promise { function printUsage (line 192) | function printUsage(): never { function main (line 219) | async function main(): Promise { FILE: skills/baoyu-slide-deck/scripts/merge-to-pdf.ts type SlideInfo (line 5) | interface SlideInfo { function parseArgs (line 12) | function parseArgs(): { dir: string; output?: string } { function findSlideImages (line 33) | function findSlideImages(dir: string): SlideInfo[] { function createPdf (line 69) | async function createPdf(slides: SlideInfo[], outputPath: string) { function main (line 101) | async function main() { FILE: skills/baoyu-slide-deck/scripts/merge-to-pptx.ts type SlideInfo (line 5) | interface SlideInfo { function parseArgs (line 12) | function parseArgs(): { dir: string; output?: string } { function findSlideImages (line 33) | function findSlideImages(dir: string): SlideInfo[] { function findBasePrompt (line 69) | function findBasePrompt(): string | undefined { function createPptx (line 78) | async function createPptx(slides: SlideInfo[], outputPath: string) { function main (line 122) | async function main() { FILE: skills/baoyu-translate/scripts/chunk.ts type BlockKind (line 5) | type BlockKind = type Block (line 12) | interface Block { type Chunk (line 18) | interface Chunk { type ChunkCliOptions (line 23) | interface ChunkCliOptions { type ChunkResult (line 29) | interface ChunkResult { function formatChunkUsage (line 39) | function formatChunkUsage(command: string): string { function runChunkCli (line 43) | function runChunkCli(args: string[], command = "chunk.ts"): number { function chunkMarkdownFile (line 66) | function chunkMarkdownFile( function parseChunkCliArgs (line 98) | function parseChunkCliArgs(args: string[]): function parsePositiveInt (line 149) | function parsePositiveInt(value: string | undefined, fallback: number): ... function normalizeNewlines (line 155) | function normalizeNewlines(text: string): string { function trimBoundaryBlankLines (line 159) | function trimBoundaryBlankLines(text: string): string { function extractFrontmatter (line 163) | function extractFrontmatter(content: string): { frontmatter: string; bod... function parseMarkdown (line 181) | function parseMarkdown(content: string): Block[] { function tokenTypeToBlockKind (line 209) | function tokenTypeToBlockKind(tokenType: string): BlockKind { function makeBlock (line 217) | function makeBlock(kind: BlockKind, md: string): Block { function buildChunks (line 225) | function buildChunks(blocks: Block[], maxWordsPerChunk: number): Chunk[] { function splitIntoSections (line 264) | function splitIntoSections(blocks: Block[]): Block[][] { function splitOversizedBlock (line 285) | function splitOversizedBlock(block: Block, maxWordsPerChunk: number): Bl... function countWords (line 326) | function countWords(text: string): number { FILE: skills/baoyu-translate/scripts/main.ts function formatScriptCommand (line 6) | function formatScriptCommand(fallback: string): string { function printUsage (line 22) | function printUsage(exitCode: number): never { FILE: skills/baoyu-url-to-markdown/scripts/cdp.ts constant CHROME_CANDIDATES_FULL (line 16) | const CHROME_CANDIDATES_FULL: PlatformCandidates = { function findExistingChromePort (line 42) | async function findExistingChromePort(): Promise { function findChromeExecutable (line 48) | function findChromeExecutable(): string | null { function launchChrome (line 55) | async function launchChrome(url: string, port: number, headless = false) { function waitForNetworkIdle (line 69) | async function waitForNetworkIdle( function waitForPageLoad (line 97) | async function waitForPageLoad( function createTargetAndAttach (line 117) | async function createTargetAndAttach( function navigateAndWait (line 128) | async function navigateAndWait( function evaluateScript (line 150) | async function evaluateScript( function autoScroll (line 164) | async function autoScroll( FILE: skills/baoyu-url-to-markdown/scripts/constants.ts constant DEFAULT_USER_AGENT (line 3) | const DEFAULT_USER_AGENT = constant USER_DATA_DIR (line 6) | const USER_DATA_DIR = resolveUrlToMarkdownChromeProfileDir(); constant DEFAULT_TIMEOUT_MS (line 8) | const DEFAULT_TIMEOUT_MS = 30_000; constant CDP_CONNECT_TIMEOUT_MS (line 9) | const CDP_CONNECT_TIMEOUT_MS = 15_000; constant NETWORK_IDLE_TIMEOUT_MS (line 10) | const NETWORK_IDLE_TIMEOUT_MS = 1_500; constant POST_LOAD_DELAY_MS (line 11) | const POST_LOAD_DELAY_MS = 800; constant SCROLL_STEP_WAIT_MS (line 12) | const SCROLL_STEP_WAIT_MS = 600; constant SCROLL_MAX_STEPS (line 13) | const SCROLL_MAX_STEPS = 8; FILE: skills/baoyu-url-to-markdown/scripts/defuddle-converter.ts function tryDefuddleConversion (line 12) | async function tryDefuddleConversion( FILE: skills/baoyu-url-to-markdown/scripts/html-to-markdown.ts function shouldPreferDefuddle (line 91) | function shouldPreferDefuddle(result: ConversionResult): boolean { function extractContent (line 104) | async function extractContent(html: string, url: string): Promise { function fileExists (line 16) | async function fileExists(filePath: string): Promise { type Args (line 25) | interface Args { function parseArgs (line 34) | function parseArgs(argv: string[]): Args { function generateSlug (line 55) | function generateSlug(title: string, url: string): string { function formatTimestamp (line 66) | function formatTimestamp(): string { function deriveHtmlSnapshotPath (line 72) | function deriveHtmlSnapshotPath(markdownPath: string): string { function extractTitleFromMarkdownDocument (line 78) | function extractTitleFromMarkdownDocument(document: string): string { function buildDefuddleApiUrl (line 100) | function buildDefuddleApiUrl(targetUrl: string): string { function fetchDefuddleApiMarkdown (line 104) | async function fetchDefuddleApiMarkdown(targetUrl: string): Promise<{ ma... function generateOutputPath (line 127) | async function generateOutputPath(url: string, title: string, outputDir?... function waitForUserSignal (line 141) | async function waitForUserSignal(): Promise { function captureUrl (line 149) | async function captureUrl(args: Args): Promise { function main (line 219) | async function main(): Promise { FILE: skills/baoyu-url-to-markdown/scripts/markdown-conversion-shared.ts type PageMetadata (line 3) | interface PageMetadata { type ConversionResult (line 14) | interface ConversionResult { type AnyRecord (line 23) | type AnyRecord = Record; constant MIN_CONTENT_LENGTH (line 25) | const MIN_CONTENT_LENGTH = 120; constant GOOD_CONTENT_LENGTH (line 26) | const GOOD_CONTENT_LENGTH = 900; constant PUBLISHED_TIME_SELECTORS (line 28) | const PUBLISHED_TIME_SELECTORS = [ constant ARTICLE_TYPES (line 36) | const ARTICLE_TYPES = new Set([ function pickString (line 44) | function pickString(...values: unknown[]): string | null { function normalizeMarkdown (line 54) | function normalizeMarkdown(markdown: string): string { function parseDocument (line 62) | function parseDocument(html: string): Document { function sanitizeHtml (line 69) | function sanitizeHtml(html: string): string { function extractTextFromHtml (line 83) | function extractTextFromHtml(html: string): string { function getMetaContent (line 93) | function getMetaContent(document: Document, names: string[]): string | n... function normalizeLanguageTag (line 104) | function normalizeLanguageTag(value: string | null): string | null { function flattenJsonLdItems (line 116) | function flattenJsonLdItems(data: unknown): AnyRecord[] { function parseJsonLdScripts (line 128) | function parseJsonLdScripts(document: Document): AnyRecord[] { function isArticleType (line 144) | function isArticleType(item: AnyRecord): boolean { function extractAuthorFromJsonLd (line 149) | function extractAuthorFromJsonLd(authorData: unknown): string | null { function extractPrimaryJsonLdMeta (line 164) | function extractPrimaryJsonLdMeta(document: Document): Partial]+)(>)... constant FRONTMATTER_COVER_RE (line 26) | const FRONTMATTER_COVER_RE = /^(coverImage:\s*")(https?:\/\/[^"]+)(")/m; constant IMAGE_EXTENSIONS (line 28) | const IMAGE_EXTENSIONS = new Set([ constant VIDEO_EXTENSIONS (line 41) | const VIDEO_EXTENSIONS = new Set(["mp4", "m4v", "mov", "webm", "mkv"]); constant MIME_EXTENSION_MAP (line 43) | const MIME_EXTENSION_MAP: Record = { constant DOWNLOAD_USER_AGENT (line 60) | const DOWNLOAD_USER_AGENT = function normalizeContentType (line 63) | function normalizeContentType(raw: string | null): string { function normalizeExtension (line 67) | function normalizeExtension(raw: string | undefined | null): string | un... function resolveExtensionFromUrl (line 76) | function resolveExtensionFromUrl(rawUrl: string): string | undefined { function resolveKindFromContentType (line 89) | function resolveKindFromContentType(contentType: string): MediaKind | un... function resolveKindFromExtension (line 96) | function resolveKindFromExtension(ext: string | undefined): MediaKind | ... function resolveMediaKind (line 103) | function resolveMediaKind( function resolveOutputExtension (line 122) | function resolveOutputExtension( function safeDecodeURIComponent (line 136) | function safeDecodeURIComponent(value: string): string { function sanitizeFileSegment (line 144) | function sanitizeFileSegment(input: string): string { function resolveFileStem (line 152) | function resolveFileStem(rawUrl: string, extension: string): string { function buildFileName (line 167) | function buildFileName(kind: MediaKind, index: number, sourceUrl: string... function collectMarkdownLinkCandidates (line 175) | function collectMarkdownLinkCandidates(markdown: string): MarkdownLinkCa... function rewriteMarkdownMediaLinks (line 204) | function rewriteMarkdownMediaLinks(markdown: string, replacements: Map { function startDebugServer (line 49) | async function startDebugServer(port: number): Promise { function closeServer (line 71) | async function closeServer(server: http.Server): Promise { function shellPathForPlatform (line 80) | function shellPathForPlatform(): string | null { function startFakeChromiumProcess (line 85) | async function startFakeChromiumProcess(port: number): Promise { FILE: skills/baoyu-url-to-markdown/scripts/vendor/baoyu-chrome-cdp/src/index.ts type PlatformCandidates (line 8) | type PlatformCandidates = { type PendingRequest (line 14) | type PendingRequest = { type CdpSendOptions (line 20) | type CdpSendOptions = { type FetchJsonOptions (line 25) | type FetchJsonOptions = { type FindChromeExecutableOptions (line 29) | type FindChromeExecutableOptions = { type ResolveSharedChromeProfileDirOptions (line 34) | type ResolveSharedChromeProfileDirOptions = { type FindExistingChromeDebugPortOptions (line 41) | type FindExistingChromeDebugPortOptions = { type ChromeChannel (line 46) | type ChromeChannel = "stable" | "beta" | "canary" | "dev"; type DiscoveredChrome (line 48) | type DiscoveredChrome = { type DiscoverRunningChromeOptions (line 53) | type DiscoverRunningChromeOptions = { type LaunchChromeOptions (line 59) | type LaunchChromeOptions = { type ChromeTargetInfo (line 68) | type ChromeTargetInfo = { type OpenPageSessionOptions (line 74) | type OpenPageSessionOptions = { type PageSession (line 86) | type PageSession = { function sleep (line 92) | function sleep(ms: number): Promise { function getFreePort (line 96) | async function getFreePort(fixedEnvName?: string): Promise { function findChromeExecutable (line 119) | function findChromeExecutable(options: FindChromeExecutableOptions): str... function resolveSharedChromeProfileDir (line 137) | function resolveSharedChromeProfileDir(options: ResolveSharedChromeProfi... function fetchWithTimeout (line 158) | async function fetchWithTimeout(url: string, timeoutMs?: number): Promis... function fetchJson (line 170) | async function fetchJson(url: string, options: FetchJsonOpt... function isDebugPortReady (line 178) | async function isDebugPortReady(port: number, timeoutMs = 3_000): Promis... function isPortListening (line 190) | function isPortListening(port: number, timeoutMs = 3_000): Promise void): void { method off (line 428) | off(method: string, handler: (params: unknown) => void): void { method send (line 432) | async send(method: string, params?: Record