Version: 0.0.2 Status: Active Development
PictoForge is a semantic SVG editor designed as a companion tool for generative AI models, specifically for PictoNet. It provides a precise workspace for inspecting, editing, and curating SVG pictograms for Augmentative and Alternative Communication (AAC) workflows.
- Bidirectional sync between visual canvas and SVG code
- Real-time updates across hierarchy, canvas, and code views
- Undo/redo history for all modifications
- Select Tool - Move, scale, rotate with bounding box
- Node Tool - Edit path nodes and Bézier handles
- Pen Tool - Add/remove nodes (in development)
- 4 languages: English, Español, Māori, Mapuzugun
- 250+ translations with auto-detection
- Persistent language preference
- IndexedDB-based persistent storage
- Three data stores: Pictograms, Vocabulary, Settings
- Export/Import workspace functionality
- Storage quota management
- Coordinate system reconciliation (screen → viewport → SVG)
- Style management with CSS class editor
- Entity editing with property modification
- Draggable modals with position persistence
- Performance metrics monitoring
- Node.js 18+
- pnpm 10.4.1+ (recommended) or npm
# Clone repository
git clone https://github.com/hspencer/pictoforge.git
cd pictoforge
# Install dependencies
pnpm install
# Start development server
pnpm run devApplication runs at http://localhost:5173
# Development
pnpm run dev # Start dev server
pnpm run build # Production build
pnpm run preview # Preview production build
pnpm run lint # Lint code
# Testing
pnpm test # Run tests (watch mode)
pnpm test:run # Run tests once
pnpm test:ui # Interactive test UI
pnpm test:coverage # Generate coverage report- React 19.1.0 - UI framework
- Vite 6.3.5 - Build tool
- Tailwind CSS 4.1.7 - Styling
- @svgdotjs/svg.js 3.2.5 - SVG manipulation
- @panzoom/panzoom 4.6.0 - Viewport control
- react-moveable 0.56.0 - Interactive transforms
- Radix UI - Accessible primitives
- react-draggable 4.4.6 - Draggable modals
- Lucide React 0.510.0 - Icons
- IndexedDB - Local persistence
- ajv 8.17.1 - JSON Schema validation
- Storage Overview - Start here
- Data Structures
- API Methods
- Usage Examples
Core Functionality
- SVG file loading (drag & drop, file button)
- SVG hierarchy parsing and visualization
- Bidirectional selection (canvas ↔ hierarchy)
- CSS style panel with live editing
- Canvas pan/zoom with smooth trackpad support
- Light/dark theme
- History system (undo/redo)
- Entity editing (ID, CSS class)
Editing Tools
- Select tool (move, scale, rotate)
- Node tool (path node visualization)
- Bounding box with transformation handles
- Entity property modification
User Interface
- Three-panel layout (input, hierarchy, canvas)
- Draggable, responsive modals
- Code view with syntax highlighting
- Performance metrics display
- Storage quota management
- Node editing (drag nodes, adjust Bézier handles)
- Pen tool (add/remove nodes)
- Transform accumulation system
- Element duplication/deletion
- Enhanced undo/redo integration
- PictoNet API integration
- Vocabulary management UI
- Multi-language NLU schema support
- Collaborative editing
- Advanced export formats
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Run tests (
pnpm test) - Commit your changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow existing patterns in the codebase
- Use ESLint configuration
- Write meaningful commit messages
- Add tests for new features
- Update documentation
- Editing Tools - Implement visual editing features
- Storage System - Enhance IndexedDB operations
- Testing - Improve test coverage
- Documentation - Expand guides and examples
- Internationalisation - Add more languages
PictoForge uses a unified coordinate transformation system (SVGWorld) that reconciles:
- Screen coordinates - Browser mouse events
- Viewport coordinates - After pan/zoom transformations
- SVG coordinates - Internal SVG space (viewBox)
All editing tools operate through this single source of truth, ensuring mathematical correctness.
SVG as Source of Truth - Each SVG contains complete metadata:
- NLU Schema in
<metadata>tag - Semantic roles in
data-*attributes - Embedded CSS in
<style>tag - Localized descriptions in
<title>and<desc>
IndexedDB stores only indexed fields for fast querying, never duplicating data.
App.jsx (root)
├── TextInput (top panel)
├── SVGHierarchy (left panel)
│ └── StylePanel (modal)
└── SVGViewer (main canvas)
├── SVGWorld (coordinate system)
├── Panzoom (viewport control)
├── NodeEditor (path editing)
└── EntityEditDialog (property editor)
MIT License - See LICENSE file for details
- 0.0.2 (Current) - Storage system, entity editing, improved UX
- 0.0.1 - Initial release with core editing features
Built with ❤️ for AAC workflows