stark-ai-de/agent-skills / plugins/stark-ai-developer/skills/visual-reports
visual-reports
VerifiedCreate and update visual reports with optional native interaction, one guided topic at a time, useful diagrams, concise points, joint comparisons and complete offline HTML/Markdown/JSON exports. Use when richer output helps an authorized answer or the user asks for a visual report; keep small answers in chat. Not production application UI or clinical advice.
scripts/lib/export-path.mjs
View on GitHub// SPDX-License-Identifier: Apache-2.0
import { lstat, mkdir, realpath } from "node:fs/promises";
import path from "node:path";
/** Resolve a bundle output without traversing symlinked directories or files. */
export async function resolveExportTarget(destination, relativePath, { create = false } = {}) {
if (
typeof relativePath !== "string" ||
path.isAbsolute(relativePath) ||
relativePath.split(/[\\/]/).some((part) => !part || part === "." || part === "..")
) {
throw new Error("Invalid bundle output path");
}
const root = await realpath(destination);
const parts = relativePath.split(/[\\/]/);
let parent = root;
for (const part of parts.slice(0, -1)) {
const next = path.join(parent, part);
try {
const info = await lstat(next);
if (info.isSymbolicLink() || !info.isDirectory())
throw new Error(`Unsafe bundle directory: ${part}`);
} catch (error) {
if (error.code !== "ENOENT" || !create) throw error;
await mkdir(next);
const info = await lstat(next);
if (info.isSymbolicLink() || !info.isDirectory())
throw new Error(`Unsafe bundle directory: ${part}`);
}
parent = next;
}
const target = path.join(parent, parts.at(-1));
const relative = path.relative(root, target);
if (!relative || relative.startsWith(`..${path.sep}`) || path.isAbsolute(relative))
throw new Error("Bundle path escapes destination");
try {
const info = await lstat(target);
if (info.isSymbolicLink() || !info.isFile())
throw new Error(`Not a regular bundle output: ${relativePath}`);
} catch (error) {
if (error.code !== "ENOENT") throw error;
}
return target;
}
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| brainstormingobra/superpowersYou MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation). | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| brand-guidelinesanthropics/skillsApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| frontend-designanthropics/skillsGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| mcp-builderanthropics/skillsGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK). | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |