HK-hub/AgentSkills / archify
archify
FlaggedCreate polished, validated architecture, workflow, sequence, data-flow, and lifecycle/state diagrams as explorable standalone HTML with inline SVG, dark/light themes, semantic navigation, optional trace motion, an optional 1200×630 Share Card PNG, and PNG/JPEG/WebP/SVG/WebM export. Accept plain-language requirements or pasted Mermaid flowchart, sequenceDiagram, and stateDiagram input; inspect repository evidence when the diagram must reflect real code. Use when the user asks to visualize system architecture, infrastructure, cloud/security/network topology, technical workflows, approval or CI/CD flows, API call sequences, request lifecycles, data pipelines, ETL/ELT, data lineage, state machines, or to convert/beautify Mermaid. Prefer typed JSON IR renderers and deterministic validation; deliver static output by default, enable motion only when requested, and use optional post-commit opening only for an interactive local handoff.
test/grid.test.mjs
View on GitHubimport { test } from 'node:test';
import assert from 'node:assert/strict';
import { gridLayout, resolveComponentPos, validateGridPlacement } from '../renderers/architecture/grid.mjs';
test('gridLayout returns null for free placement', () => {
assert.equal(gridLayout({}), null);
assert.equal(gridLayout({ layout: undefined }), null);
});
test('resolveComponentPos prefers explicit pos over row/col', () => {
const grid = gridLayout({ layout: { mode: 'grid' } });
assert.deepEqual(resolveComponentPos({ pos: [9, 8], row: 0, col: 0 }, grid), [9, 8]);
});
test('resolveComponentPos maps row/col to pixel origin', () => {
const grid = gridLayout({
layout: { mode: 'grid', origin: [40, 80], gapX: 30, gapY: 40, cellW: 130, cellH: 64 },
});
assert.deepEqual(resolveComponentPos({ row: 0, col: 0 }, grid), [40, 80]);
assert.deepEqual(resolveComponentPos({ row: 1, col: 2 }, grid), [40 + 2 * 160, 80 + 104]);
});
test('validateGridPlacement rejects duplicate cells and missing row/col', () => {
const grid = gridLayout({ layout: { mode: 'grid', cols: 4 } });
const problems = [];
validateGridPlacement({
components: [
{ id: 'a', row: 0, col: 0 },
{ id: 'b', row: 0, col: 0 },
{ id: 'c' },
],
}, grid, problems);
assert.ok(problems.some((p) => p.includes('share grid cell')));
assert.ok(problems.some((p) => p.includes('"c" needs pos')));
});
test('validateGridPlacement ignores explicit pos overrides without row/col', () => {
const grid = gridLayout({ layout: { mode: 'grid', cols: 4 } });
const problems = [];
validateGridPlacement({
components: [
{ id: 'a', pos: [40, 80] },
{ id: 'b', pos: [200, 80] },
],
}, grid, problems);
assert.deepEqual(problems, []);
});
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit. | Stars: 471k | Updated | Claude CodeCodex | Verified | Install |
| rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure. | Stars: 471k | Updated | Claude CodeCodex | Verified | Install |
| rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics. | Stars: 471k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |