{"id":44976219,"url":"https://github.com/moonshine-software/forty-five","last_synced_at":"2026-02-18T17:05:26.507Z","repository":{"id":323290483,"uuid":"1075902080","full_name":"moonshine-software/forty-five","owner":"moonshine-software","description":"FortyFive accelerates AI-assisted development by providing the essential context and structure that AI needs to generate high-quality, MoonShine-specific code.","archived":false,"fork":false,"pushed_at":"2026-01-28T09:52:34.000Z","size":174,"stargazers_count":27,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-29T00:30:46.747Z","etag":null,"topics":["ai","guidelines","moonshine"],"latest_commit_sha":null,"homepage":"https://getmoonshine.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/moonshine-software.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-14T06:29:33.000Z","updated_at":"2026-01-28T22:23:41.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/moonshine-software/forty-five","commit_stats":null,"previous_names":["moonshine-software/forty-five"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/moonshine-software/forty-five","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moonshine-software%2Fforty-five","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moonshine-software%2Fforty-five/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moonshine-software%2Fforty-five/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moonshine-software%2Fforty-five/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/moonshine-software","download_url":"https://codeload.github.com/moonshine-software/forty-five/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moonshine-software%2Fforty-five/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29587066,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T16:55:40.614Z","status":"ssl_error","status_checked_at":"2026-02-18T16:55:37.558Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","guidelines","moonshine"],"created_at":"2026-02-18T17:05:25.634Z","updated_at":"2026-02-18T17:05:26.499Z","avatar_url":"https://github.com/moonshine-software.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌙 Forty-Five\n\n\u003e AI-powered development toolkit for MoonShine - Inspired by GitHub Speckit\n\nForty-Five is a CLI tool that brings AI-powered development assistance to your MoonShine projects. Install guidelines and slash commands that help AI agents (like Claude) understand MoonShine components and generate production-ready code.\n\n## ✨ Features\n\n- 🤖 **AI Agent Integration** - Works with Claude Code (more agents coming soon)\n- 📚 **Comprehensive Guidelines** - Complete MoonShine component documentation\n- ⚡ **Slash Commands** - Easy-to-use commands for common tasks\n- 🎯 **Production Ready** - Generates code following best practices\n- 🔄 **Auto-sync** - Keep guidelines and commands up-to-date\n\n## 🚀 Quick Start\n\n### Installation\n\nInstall globally via npm:\n\n```bash\nnpm install -g @moonshine-software/forty-five\n```\n\n### Initialize in Your Project\n\nNavigate to your MoonShine project and run:\n\n```bash\ncd your-moonshine-project\nforty-five init\n```\nNote: The folder must be owned by the current user.\n\nFollow the prompts to:\n1. Select your AI agent (Claude, Cursor, etc.)\n2. Download commands and guidelines\n3. Set up configuration\n\n### Project Structure After Init\n\n```\nyour-moonshine-project/\n├── .claude/                    # Claude-specific files\n│   └── commands/\n│       ├── forty-five.components.md\n│       ├── forty-five.layout.md\n│       ├── forty-five.palettes.md\n│       ├── forty-five.field.md\n│       └── forty-five.component.md\n└── .guidelines/                # Shared guidelines\n    ├── blade-components.md\n    ├── palettes.md\n    ├── fields-development.md\n    └── components-development.md\n```\n\n## 📖 Usage\n\n### Available Commands\n\nAfter initialization, you can use these slash commands in Claude:\n\n#### `/forty-five.components` - Work with Components\n\nCreate any MoonShine component with proper structure:\n\n```\n/forty-five.components create a user table with name, email, status badges, and action buttons\n```\n\n```\n/forty-five.components create a modal form for adding new products\n```\n\n#### `/forty-five.layout` - Create Layouts\n\nGenerate complete layouts with navigation:\n\n```\n/forty-five.layout create a sidebar layout with logo, menu, and theme switcher\n```\n\n```\n/forty-five.layout create a top navigation bar with horizontal menu\n```\n\n#### `/forty-five.palettes` - Create Color Palettes\n\nCreate and modify custom color palettes using OKLCH color space:\n\n```\n/forty-five.palettes create a blue ocean theme with hue 240\n```\n\n```\n/forty-five.palettes create a purple palette for dark and light themes\n```\n\n#### `/forty-five.field` - Create Custom Fields\n\nCreate custom MoonShine fields with proper structure and methods:\n\n```\n/forty-five.field create a rating field with stars from 1 to 5\n```\n\n```\n/forty-five.field create a color picker field with preview\n```\n\n#### `/forty-five.component` - Create Custom Components\n\nCreate custom MoonShine components for UI decoration:\n\n```\n/forty-five.component create an alert component with different types\n```\n\n```\n/forty-five.component create a stats card with icon and value\n```\n\n## 🎯 What Gets Generated\n\nForty-Five ensures AI agents generate code that follows MoonShine best practices:\n\n✅ **Correct HTML Structure** - No duplicate HTML tags, proper component nesting\n✅ **Required Wrappers** - All CSS classes and wrappers in place\n✅ **Assets Included** - Vite assets properly configured\n✅ **Responsive Design** - Mobile-friendly with proper burger menus\n✅ **Production Ready** - Following all MoonShine conventions\n\n## 📚 Guidelines\n\nThe guidelines provide comprehensive documentation for:\n\n### `blade-components.md`\n- Complete component library\n- Critical usage rules\n- Required wrappers and attributes\n- Slot-based vs array-based patterns\n- Best practices and examples\n\n### `palettes.md`\n- OKLCH color space format\n- Complete palette structure\n- Light and dark theme implementation\n- Contrast requirements and best practices\n\n### `fields-development.md`\n- Custom field creation guide\n- Field class anatomy and methods\n- View templates with Alpine.js\n- Fluent methods and field modes\n- Relationship fields handling\n- Complete examples (Rating, JSON, File Upload)\n\n### `components-development.md`\n- Custom component creation guide\n- Components vs Fields comparison\n- Fluent methods and viewData()\n- Slots and nested components\n- Complete examples (Alert, StatsCard, Breadcrumbs)\n\n## 🔧 CLI Commands\n\n### `forty-five init`\n\nInitialize Forty-Five in your project.\n\n**Options:**\n- Interactive agent selection\n- Automatic directory creation\n- Downloads latest commands and guidelines\n\n### `forty-five update` (Coming Soon)\n\nUpdate commands and guidelines to the latest version.\n\n### `forty-five status` (Coming Soon)\n\nCheck initialization status and versions.\n\n## 🤝 Supported AI Agents\n\n- ✅ **Claude Code** - Full support\n- 🚧 **Cursor** - Coming soon\n- 🚧 **GitHub Copilot** - Coming soon\n\n## 📝 Examples\n\n### Creating a User Management Interface\n\n```\n/forty-five.components create a users table with:\n- Avatars and name columns\n- Status badges (active/inactive)\n- Role badges with different colors\n- Action buttons (view, edit, delete)\n```\n\nThe AI will generate a complete, working table with:\n- Proper slot-based structure\n- MoonShine badge components\n- Icon buttons with proper wrappers\n- All required CSS classes\n\n### Building a Custom Color Palette\n\n```\n/forty-five.palettes create a professional teal palette with:\n- Hue angle 180 (teal/cyan)\n- Both light and dark themes\n- Proper contrast ratios\n- All semantic colors (success, warning, error, info)\n```\n\n### Creating a Custom Field\n\n```\n/forty-five.field create a JSON editor field that:\n- Displays formatted JSON in a textarea\n- Has syntax highlighting\n- Validates JSON on input\n- Saves as JSON string to database\n```\n\nThe AI will generate:\n- PHP class in `app/MoonShine/Fields/JsonEditor.php`\n- Blade view in `resources/views/admin/fields/json-editor.blade.php`\n- Proper `viewData()` method\n- Correct `resolveValue()` and `resolveOnApply()` methods\n- Alpine.js integration for interactivity\n\n### Creating a Custom Component\n\n```\n/forty-five.component create a stats card component that:\n- Shows an icon, value, and label\n- Supports different colors\n- Value can be dynamic (closure)\n- Used for dashboard widgets\n```\n\nThe AI will generate:\n- PHP class in `app/MoonShine/Components/StatsCard.php`\n- Blade view in `resources/views/admin/components/stats-card.blade.php`\n- Fluent methods for configuration\n- Support for closures in values\n- Proper attribute handling\n\n## 🏗️ Architecture\n\n```\n┌─────────────────────────────────────────┐\n│         User's MoonShine Project        │\n├─────────────────────────────────────────┤\n│  .claude/commands/                      │\n│  ├── forty-five.components.md          │\n│  │   → Reads .guidelines/              │\n│  ├── forty-five.layout.md              │\n│  │   → Reads .guidelines/              │\n│  ├── forty-five.palettes.md            │\n│  │   → Reads .guidelines/              │\n│  ├── forty-five.field.md               │\n│  │   → Reads .guidelines/              │\n│  └── forty-five.component.md           │\n│      → Reads .guidelines/              │\n│                                         │\n│  .guidelines/                           │\n│  ├── blade-components.md               │\n│  ├── palettes.md                       │\n│  ├── fields-development.md             │\n│  └── components-development.md         │\n└─────────────────────────────────────────┘\n```\n\n## 🔄 Update Process\n\nGuidelines and commands are downloaded from the official repository:\n```\nhttps://github.com/moonshine-software/forty-five\n```\n\nWhen you run `forty-five init`, it fetches:\n- Latest command files for your selected agent\n- Latest guideline files\n- Ensures you have the most up-to-date documentation\n\n## 🐛 Troubleshooting\n\n### \"composer.json not found\"\nMake sure you're in your Laravel/MoonShine project root directory.\n\n### Commands not appearing in Claude\n1. Restart Claude Code\n2. Check that files were created in `.claude/commands/`\n3. Verify slash commands with `/` in Claude\n\n### Guidelines not being followed\nMake sure the AI agent can access `.guidelines/` directory. Commands are configured to read from this location.\n\n## 📦 Package Development\n\n### Building from Source\n\n```bash\n# Clone repository\ngit clone https://github.com/moonshine-software/forty-five.git\ncd forty-five\n\n# Install dependencies\nnpm install\n\n# Build\nnpm run build\n\n# Test locally\nnpm link\ncd /path/to/your-project\nforty-five init\n```\n\n## 🤝 Contributing\n\nContributions are welcome! Please read our contributing guidelines before submitting PRs.\n\n## 📄 License\n\nMIT License - see LICENSE file for details.\n\n## 🙏 Acknowledgments\n\n- Inspired by GitHub Speckit\n- Built for the MoonShine Laravel admin panel\n- Powered by AI agents like Claude\n\n## 🔗 Links\n\n- [MoonShine Documentation](https://moonshine-laravel.com)\n- [GitHub Repository](https://github.com/moonshine-software/forty-five)\n- [Report Issues](https://github.com/moonshine-software/forty-five/issues)\n\n---\n\nMade with 🌙 by the MoonShine team\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoonshine-software%2Fforty-five","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmoonshine-software%2Fforty-five","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoonshine-software%2Fforty-five/lists"}