Commit Graph

4 Commits

Author SHA1 Message Date
Claude a21dfe1ef0 feat: Agent Plugins Phase 4 — CLI --plugin flag + verified bundle installer
- New cli-tool/src/plugin-installer.js: installs bundles from the
  aitmpl.com registry (CCT_PLUGIN_REGISTRY_URL override for testing).
  Downloads file-by-file from files.json with sha256 verification,
  3-retry exponential backoff, and a zip-slip path guard; unpacks the
  pure spec layout into .agent-plugins/{name}/ and activates into the
  familiar destinations: skills -> .claude/skills/, mcp.json merged into
  .mcp.json, agents/commands/loops flat into .claude/ (same layout the
  individual installers produce). Hooks/settings in a bundle are unpacked
  but deliberately not auto-activated (their interactive multi-location
  merge stays with --hook/--setting). Spec failure model: invalid
  plugin.json rejects the plugin; an invalid skill is skipped with a
  warning. Tracked as type 'plugin' with batchId/durationMs.
- bin/create-claude-config.js: new --plugin <names> (comma-separated) and
  --plugin-raw (unpack-only) options; help text disambiguates from the
  --plugins dashboard.
- src/index.js: --plugin wired into routing and installMultipleComponents;
  installIndividualMCP's merge body extracted into the shared
  mergeMcpServers() helper (same semantics: description stripped, existing
  servers preserved, 2-space output) so bundle activation and --mcp share
  one code path. merged_with_existing telemetry now reports the real value
  instead of always-true.
- cli-tool/tests/plugin/installer.test.js: 11 tests over a stubbed fetch
  serving a packer-built bundle — activation placement, existing-server
  preservation, --plugin-raw, spec rejection, path traversal, sha256
  mismatch cleanup, dry run, and mergeMcpServers regression.

Verified end-to-end: real CLI install of both pilot bundles from a local
HTTP registry produced the expected .agent-plugins/ + .claude/ + .mcp.json.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NPhPzxiW2q2wgQQLS8Bn9w
2026-08-18 13:51:21 +00:00
Claude 55ca339627 feat: Agent Plugins Phase 1 — single-source bundle packer + curated bundles
- cli-tool/src/plugin/: packer module (normalize.js, packer.js, validate.js)
  emitting spec-conformant Agent Plugins v1.0.0 bundles: skills and mcp.json
  first-class; agents/commands/hooks/settings/loops byte-exact under the
  com.aitmpl.claude-code extensions namespace; dual .claude-plugin/plugin.json
  so the same directory installs as a native Claude Code plugin
- Skill copies get frontmatter normalized (name := dir, extra keys folded
  into the spec metadata map); source tree stays untouched
- MCP merge strips non-standard per-server description (preserved under
  extensions.mcpDescriptions), infers stdio/streamable-http transport
- Loops auto-inline their referenced components (spec self-containment)
- cli-tool/agent-plugins/bundles.yaml: curated bundle definitions
  (pilots: postgres-toolkit, docs-automation)
- scripts/build_agent_plugins.js: builds + validates all bundles
  (--check mode for CI); output in gitignored build/agent-plugins/
- cli-tool/tests/plugin/packer.test.js: 9 hermetic jest tests (frontmatter
  normalization, mcp merge, loop inlining, dual manifest, path traversal
  guard, validateBundle failure model)

Both pilot bundles validate against the vendored official JSON schemas.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NPhPzxiW2q2wgQQLS8Bn9w
2026-08-18 13:43:11 +00:00
Daniel Avila 5cba740dde Improve validation modal text display and UX enhancements (#112)
## Changes Made:

### 1. Modal Text Display Improvements
- Increased error/warning message font size from 14px to 16px for better readability
- Improved line height from 1.5 to 1.6 for better spacing
- Increased margin-bottom from 4px to 8px for better visual separation

### 2. Code Preview Text Wrapping
- Removed horizontal scroll (`overflow-x: auto`) from code previews
- Added `white-space: normal` to prevent excessive whitespace at line start
- Added `word-wrap: break-word` and `overflow-wrap: break-word` for proper text wrapping
- Applied to all code preview sections:
  - Error line text previews
  - Warning line text previews
  - Example line text in errors
  - Example line text in warnings

### 3. Line Number Scroll Synchronization
- Added `position: relative` to `.code-body` for better layout control
- Added `overflow: hidden` and `max-height: 600px` to `.code-line-numbers`
- Added `max-height: 600px` to `.code-content`
- Implemented JavaScript scroll sync between line numbers and code content
- Line numbers now scroll perfectly in sync with code content

### 4. Clickable Error Line Numbers
- Added `cursor: pointer` to error/warning line numbers
- Added "Click to see details" tooltip on error/warning lines
- Implemented click event listeners on all error/warning lines
- Click handler searches through validators to find matching error
- Opens validation modal with correct validator details when clicked
- Added hover effects with `transform: translateX(-2px)` and `cursor: help`

## User Experience Improvements:
- ✅ Error messages are now larger and easier to read (16px)
- ✅ Code snippets wrap naturally without horizontal scroll
- ✅ No excessive whitespace at the beginning of code lines
- ✅ Line numbers stay synchronized during scroll
- ✅ Error line numbers are interactive and open detailed validation modals
- ✅ Better visual hierarchy with improved spacing and sizing

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude <noreply@anthropic.com>
2025-10-16 15:34:11 -04:00
Dani 8e23f08d6d Add unit tests for StateCalculator, StateService, and WebSocketServer
- Implement comprehensive unit tests for StateCalculator to validate conversation status detection and state management.
- Create unit tests for StateService covering state management, subscriber notifications, and error handling.
- Develop unit tests for WebSocketServer to ensure proper handling of WebSocket connections, message broadcasting, and heartbeat mechanisms.
- Include edge case handling and validation for all components to enhance robustness and reliability.
2025-07-15 19:04:01 -04:00