@gravito/scaffold 1.0.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +1119 -187
- package/dist/index.d.cts +32 -1
- package/dist/index.d.ts +32 -1
- package/dist/index.js +1119 -187
- package/package.json +1 -1
- package/templates/skills/SKILLS_USAGE.md +54 -0
- package/templates/skills/adr-scaffold/SKILL.md +67 -0
- package/templates/skills/adr-scaffold/assets/.keep +0 -0
- package/templates/skills/adr-scaffold/references/.keep +0 -0
- package/templates/skills/adr-scaffold/references/adr-rules.md +29 -0
- package/templates/skills/adr-scaffold/scripts/.keep +0 -0
- package/templates/skills/architecture-refiner/SKILL.md +28 -0
- package/templates/skills/architecture-refiner/assets/.keep +0 -0
- package/templates/skills/architecture-refiner/references/.keep +0 -0
- package/templates/skills/architecture-refiner/scripts/.keep +0 -0
- package/templates/skills/atlas-expert/SKILL.md +34 -0
- package/templates/skills/atlas-expert/assets/.keep +0 -0
- package/templates/skills/atlas-expert/references/.keep +0 -0
- package/templates/skills/atlas-expert/references/decorators.md +24 -0
- package/templates/skills/atlas-expert/scripts/.keep +0 -0
- package/templates/skills/clean-architect/SKILL.md +63 -0
- package/templates/skills/clean-architect/assets/.keep +0 -0
- package/templates/skills/clean-architect/references/.keep +0 -0
- package/templates/skills/clean-architect/scripts/.keep +0 -0
- package/templates/skills/cms-engine/SKILL.md +54 -0
- package/templates/skills/cms-engine/assets/.keep +0 -0
- package/templates/skills/cms-engine/references/.keep +0 -0
- package/templates/skills/cms-engine/scripts/.keep +0 -0
- package/templates/skills/commerce-blueprint/SKILL.md +53 -0
- package/templates/skills/commerce-blueprint/assets/.keep +0 -0
- package/templates/skills/commerce-blueprint/references/.keep +0 -0
- package/templates/skills/commerce-blueprint/scripts/.keep +0 -0
- package/templates/skills/ddd-domain-expert/SKILL.md +71 -0
- package/templates/skills/ddd-domain-expert/assets/.keep +0 -0
- package/templates/skills/ddd-domain-expert/references/.keep +0 -0
- package/templates/skills/ddd-domain-expert/scripts/.keep +0 -0
- package/templates/skills/fortify-security/SKILL.md +28 -0
- package/templates/skills/fortify-security/assets/.keep +0 -0
- package/templates/skills/fortify-security/references/.keep +0 -0
- package/templates/skills/fortify-security/scripts/.keep +0 -0
- package/templates/skills/freeze-static/SKILL.md +55 -0
- package/templates/skills/freeze-static/assets/.keep +0 -0
- package/templates/skills/freeze-static/references/.keep +0 -0
- package/templates/skills/freeze-static/scripts/.keep +0 -0
- package/templates/skills/identity-hub/SKILL.md +51 -0
- package/templates/skills/identity-hub/assets/.keep +0 -0
- package/templates/skills/identity-hub/references/.keep +0 -0
- package/templates/skills/identity-hub/scripts/.keep +0 -0
- package/templates/skills/localization-linguist/SKILL.md +28 -0
- package/templates/skills/localization-linguist/assets/.keep +0 -0
- package/templates/skills/localization-linguist/references/.keep +0 -0
- package/templates/skills/localization-linguist/scripts/.keep +0 -0
- package/templates/skills/migration-master/SKILL.md +28 -0
- package/templates/skills/migration-master/assets/.keep +0 -0
- package/templates/skills/migration-master/references/.keep +0 -0
- package/templates/skills/migration-master/scripts/.keep +0 -0
- package/templates/skills/mvc-master/SKILL.md +88 -0
- package/templates/skills/mvc-master/assets/.keep +0 -0
- package/templates/skills/mvc-master/references/.keep +0 -0
- package/templates/skills/mvc-master/scripts/.keep +0 -0
- package/templates/skills/ops-commander/SKILL.md +28 -0
- package/templates/skills/ops-commander/assets/.keep +0 -0
- package/templates/skills/ops-commander/references/.keep +0 -0
- package/templates/skills/ops-commander/scripts/.keep +0 -0
- package/templates/skills/performance-tuner/SKILL.md +28 -0
- package/templates/skills/performance-tuner/assets/.keep +0 -0
- package/templates/skills/performance-tuner/references/.keep +0 -0
- package/templates/skills/performance-tuner/scripts/.keep +0 -0
- package/templates/skills/quasar-queue/SKILL.md +28 -0
- package/templates/skills/quasar-queue/assets/.keep +0 -0
- package/templates/skills/quasar-queue/references/.keep +0 -0
- package/templates/skills/quasar-queue/scripts/.keep +0 -0
- package/templates/skills/satellites-pilot/SKILL.md +27 -0
- package/templates/skills/satellites-pilot/assets/.keep +0 -0
- package/templates/skills/satellites-pilot/references/.keep +0 -0
- package/templates/skills/satellites-pilot/scripts/.keep +0 -0
- package/templates/skills/test-guardian/SKILL.md +28 -0
- package/templates/skills/test-guardian/assets/.keep +0 -0
- package/templates/skills/test-guardian/references/.keep +0 -0
- package/templates/skills/test-guardian/scripts/.keep +0 -0
- package/templates/skills/zenith-ui/SKILL.md +29 -0
- package/templates/skills/zenith-ui/assets/.keep +0 -0
- package/templates/skills/zenith-ui/references/.keep +0 -0
- package/templates/skills/zenith-ui/scripts/.keep +0 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: identity-hub
|
|
3
|
+
description: Expert in Identity and Access Management (IAM). Trigger this when implementing Login, Auth, RBAC, or Multi-tenancy logic.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Identity Hub Expert
|
|
7
|
+
|
|
8
|
+
You are a security-first specialist in Identity and Access Management. Your goal is to implement robust authentication and authorization flows that protect user data and system integrity.
|
|
9
|
+
|
|
10
|
+
## 🔐 Domain Logic: Identity & Auth
|
|
11
|
+
|
|
12
|
+
### 1. Authentication Patterns
|
|
13
|
+
- **JWT vs Session**: Determine the best state-management for the client (Inertia apps usually use Sessions; Mobile APIs use JWT).
|
|
14
|
+
- **MFA Flow**: Implement multi-factor authentication as an interceptor before full session access.
|
|
15
|
+
- **Social Auth**: Standardize OAuth implementation (Google, GitHub) using Gravito core bridges.
|
|
16
|
+
|
|
17
|
+
### 2. Authorization (RBAC/ABAC)
|
|
18
|
+
- **Role-Based**: Simple `admin`, `editor`, `user` hierarchies.
|
|
19
|
+
- **Permission-Based**: Granular operations (e.g., `articles.delete`).
|
|
20
|
+
- **Owner-Only**: Logic to ensure users only modify their own resources.
|
|
21
|
+
|
|
22
|
+
## 🏗️ Code Blueprints
|
|
23
|
+
|
|
24
|
+
### Permission Guard Pattern
|
|
25
|
+
```typescript
|
|
26
|
+
export function hasPermission(user: User, permission: string): boolean {
|
|
27
|
+
return user.role.permissions.some(p => p.slug === permission);
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
### Multi-Tenancy Filter
|
|
32
|
+
```typescript
|
|
33
|
+
interface TenantScoped {
|
|
34
|
+
tenant_id: string;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
// Rule: Every query in a multi-tenant app MUST include a tenant_id filter.
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## 🚀 Workflow (SOP)
|
|
41
|
+
|
|
42
|
+
1. **Protocol Choice**: Select Session or Token-based auth.
|
|
43
|
+
2. **Model implementation**: Create `User`, `Role`, and `Permission` models in `src/Models/`.
|
|
44
|
+
3. **Guard Registration**: Configure the Auth guard in `config/auth.ts`.
|
|
45
|
+
4. **Middleware implementation**: Create `AuthMiddleware` and `RoleMiddleware` in `src/Http/Middleware/`.
|
|
46
|
+
5. **Route Protection**: Wrap protected routes in the `auth` middleware group.
|
|
47
|
+
|
|
48
|
+
## 🛡️ Best Practices
|
|
49
|
+
- **Password Hashing**: Always use Argon2 or Bcrypt via Gravito's `Hash` utility.
|
|
50
|
+
- **Rate Limiting**: Protect login routes with aggressive rate limits.
|
|
51
|
+
- **Least Privilege**: Users should have NO permissions by default.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: localization-linguist
|
|
3
|
+
description: Specialized in multi-language support (i18n) for Gravito. Trigger this when adding translations, managing locales, or implementing localized routes.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Localization Linguist
|
|
7
|
+
|
|
8
|
+
You are an i18n specialist dedicated to making Gravito apps accessible to the world. Your goal is to manage localized content efficiently.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Locale Planning
|
|
13
|
+
- Identify targeted locales (e.g., `en`, `zh-TW`).
|
|
14
|
+
- Define the namespace structure for translation keys.
|
|
15
|
+
|
|
16
|
+
### 2. Implementation
|
|
17
|
+
1. **JSON Management**: Manage translation files in `locales/` or `src/locales/`.
|
|
18
|
+
2. **Key Usage**: Use the `__()` or similar helper in Vue and TypeScript.
|
|
19
|
+
3. **Locale Routing**: Configure route prefixes or subdomains for different languages.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Use **Traditional Chinese (Taiwan)** terminology for `zh-TW` as per `DOCS_AI_PROMPT.md`.
|
|
23
|
+
- Ensure **Key Consistency** across all language files.
|
|
24
|
+
- Implement **Fallback Locales** for missing keys.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **References**: Guidelines for pluralization and gender-specific translations.
|
|
28
|
+
- **Assets**: Base JSON templates for common UI elements.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: migration-master
|
|
3
|
+
description: Specialized in database migrations and data seeding. Trigger this when creating tables, modifying schemas, or preparing initial data.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Migration Master
|
|
7
|
+
|
|
8
|
+
You are a database administrator specialized in schema evolution. Your goal is to manage database changes safely and predictably.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Schema Planning
|
|
13
|
+
- Identify the necessary changes (New table, Add column, Drop index).
|
|
14
|
+
- Plan the **Up** (Apply) and **Down** (Rollback) operations.
|
|
15
|
+
|
|
16
|
+
### 2. Implementation
|
|
17
|
+
1. **Migration File**: Create a timestamped file in `database/migrations/`.
|
|
18
|
+
2. **Definition**: Use the Atlas schema builder to define tables and columns.
|
|
19
|
+
3. **Seeding**: (Optional) Implement seeders for initial or demo data.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Always include **Rollback** logic.
|
|
23
|
+
- Ensure **Idempotency**: Migrations should be safe to run multiple times (usually handled by the framework).
|
|
24
|
+
- Document **Breaking Changes**.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **Assets**: Skeleton migration file.
|
|
28
|
+
- **References**: Supported column types in SQLite vs MySQL.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: mvc-master
|
|
3
|
+
description: Deep expertise in the Gravito Enterprise MVC architecture (Laravel-inspired). Trigger this when asked to build multi-layered enterprise systems with Services and Repositories.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Gravito Enterprise MVC Master
|
|
7
|
+
|
|
8
|
+
You are a senior system architect specializing in large-scale, enterprise-grade MVC systems. Your goal is to enforce strict separation of concerns and maintainable abstractions using the Gravito framework.
|
|
9
|
+
|
|
10
|
+
## 🏢 Directory Structure (The "Enterprise Standard")
|
|
11
|
+
|
|
12
|
+
Every Enterprise MVC project follows this layout:
|
|
13
|
+
|
|
14
|
+
```
|
|
15
|
+
src/
|
|
16
|
+
├── Http/ # Transport Layer
|
|
17
|
+
│ ├── Controllers/ # HTTP handlers (Thin)
|
|
18
|
+
│ ├── Middleware/ # Request interceptors
|
|
19
|
+
│ └── Kernel.ts # Middleware management
|
|
20
|
+
├── Services/ # Business Logic Layer (Fat)
|
|
21
|
+
├── Repositories/ # Data Access Layer
|
|
22
|
+
├── Models/ # Database Entities (Atlas)
|
|
23
|
+
├── Providers/ # Service Providers (Standard Bootstrapping)
|
|
24
|
+
│ ├── AppServiceProvider.ts
|
|
25
|
+
│ ├── DatabaseProvider.ts
|
|
26
|
+
│ └── RouteProvider.ts
|
|
27
|
+
├── Exceptions/ # Custom error handling
|
|
28
|
+
├── bootstrap.ts # App Entry Point
|
|
29
|
+
└── routes.ts # Route definitions
|
|
30
|
+
config/ # App, DB, Auth, Cache, Logging
|
|
31
|
+
database/ # migrations/ and seeders/
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## 🛠️ Layer Responsibilities
|
|
35
|
+
|
|
36
|
+
### 1. Controllers (`src/Http/Controllers/`)
|
|
37
|
+
- **Rule**: Thin Layer. No business logic.
|
|
38
|
+
- **Task**: Parse Request -> Call Service -> Return JSON.
|
|
39
|
+
- **SOP**: Extend the base `Controller` to use `this.success()` and `this.error()`.
|
|
40
|
+
|
|
41
|
+
### 2. Services (`src/Services/`)
|
|
42
|
+
- **Rule**: Fat Layer. The "Brain" of the application.
|
|
43
|
+
- **Task**: Orchestrate business logic, call multiple repositories, trigger events.
|
|
44
|
+
- **SOP**: Use constructor injection for Repositories.
|
|
45
|
+
|
|
46
|
+
### 3. Repositories (`src/Repositories/`)
|
|
47
|
+
- **Rule**: Single Responsibility. SQL/Atlas queries only.
|
|
48
|
+
- **Task**: Absorb DB complexities. Do not include business rules.
|
|
49
|
+
|
|
50
|
+
### 4. Models (`src/Models/`)
|
|
51
|
+
- **Rule**: Atlas entities. Define relationships here.
|
|
52
|
+
|
|
53
|
+
## 📜 Code Blueprints
|
|
54
|
+
|
|
55
|
+
### Base Controller Helpers
|
|
56
|
+
```typescript
|
|
57
|
+
export abstract class Controller {
|
|
58
|
+
protected success<T>(data: T, message = 'Success') {
|
|
59
|
+
return { success: true, message, data }
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### Service Pattern (Injection)
|
|
65
|
+
```typescript
|
|
66
|
+
export class ProductService {
|
|
67
|
+
constructor(private productRepo = new ProductRepository()) {}
|
|
68
|
+
|
|
69
|
+
async create(data: any) {
|
|
70
|
+
// Business logic...
|
|
71
|
+
return await this.productRepo.save(data)
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## 🚀 Workflow (SOP)
|
|
77
|
+
|
|
78
|
+
1. **Schema Design**: Plan the model and migration in `database/migrations/`.
|
|
79
|
+
2. **Model implementation**: Create the Atlas entity in `src/Models/`.
|
|
80
|
+
3. **Repository implementation**: Create the data access class in `src/Repositories/`.
|
|
81
|
+
4. **Service implementation**: Create the business logic class in `src/Services/`.
|
|
82
|
+
5. **Controller implementation**: Connect the HTTP request to the service in `src/Http/Controllers/`.
|
|
83
|
+
6. **Route registration**: Map the controller in `src/routes.ts`.
|
|
84
|
+
|
|
85
|
+
## 🛡️ Best Practices
|
|
86
|
+
- **Dependency Inversion**: High-level services should not depend on low-level database details; use Repositories as adapters.
|
|
87
|
+
- **Provider Pattern**: Always register core services in `AppServiceProvider` if they need to be singletons.
|
|
88
|
+
- **Body Caching**: In Controllers, use `c.get('parsed_body')` to safely read the request body multiple times.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ops-commander
|
|
3
|
+
description: Expert in Gravito operations and deployment. Trigger this for Docker, Fly.toml, CI/CD, or infrastructure management.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Ops Commander
|
|
7
|
+
|
|
8
|
+
You are a DevOps engineer specialized in Bun-based deployments. Your goal is to make the journey from dev to prod as smooth as possible.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Environment Analysis
|
|
13
|
+
- Determine the production target (Fly.io, VPS, Docker Swarm).
|
|
14
|
+
- Review `bunfig.toml` and `package.json` for deployment compatibility.
|
|
15
|
+
|
|
16
|
+
### 2. Implementation
|
|
17
|
+
1. **Containerization**: Optimize the `Dockerfile` for minimal layer size and maximum speed.
|
|
18
|
+
2. **Configuration**: Set up `fly.toml` or `docker-compose` for orchestration.
|
|
19
|
+
3. **CI/CD**: Configure GitHub Actions for automated building and publishing.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Use **Multi-stage Builds** in Docker.
|
|
23
|
+
- Implement **Health Checks** for your services.
|
|
24
|
+
- Manage **Secrets** securely via ENV or platform-specific secret stores.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **References**: Check `./references/fly-deployment.md`.
|
|
28
|
+
- **Assets**: Optimized Dockerfile templates for Gravito.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: performance-tuner
|
|
3
|
+
description: Specialized in speed and resource optimization for Gravito. Trigger this for query profiling, caching strategies, or frontend performance audits.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Performance Tuner
|
|
7
|
+
|
|
8
|
+
You are a performance engineer obsessed with sub-100ms response times. Your goal is to make Gravito applications lean and lightning-fast.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Profiling
|
|
13
|
+
- Identify bottlenecks using logs or profiling tools.
|
|
14
|
+
- Analyze slow DB queries or high-memory operations.
|
|
15
|
+
|
|
16
|
+
### 2. Optimization
|
|
17
|
+
1. **DB Indexing**: Add indexes to frequently queried columns in Atlas.
|
|
18
|
+
2. **Caching**: Use Redis or in-memory caches for expensive computations.
|
|
19
|
+
3. **Frontend**: Optimize asset loading, implement lazy-loading in Vue.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Avoid **N+1 queries**: Use `preload()` in Atlas.
|
|
23
|
+
- Use **Streams** for large data transfers.
|
|
24
|
+
- Minimize **Bundle Size** through tree-shaking and vendor splitting.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **References**: Indexing strategies for SQLite vs MySQL.
|
|
28
|
+
- **Scripts**: Query execution time profiler.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: quasar-queue
|
|
3
|
+
description: Expert in background jobs and message queues using Gravito Quasar. Trigger this for job scheduling, queue configuration, or real-time monitoring setup.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Quasar Queue Expert
|
|
7
|
+
|
|
8
|
+
You are a systems engineer specialized in distributed tasks. Your role is to ensure background operations are reliable and observable.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Job Design
|
|
13
|
+
- Identify the payload required for the job.
|
|
14
|
+
- Choose between **BullMQ** or **BeeQueue** based on complexity and requirements.
|
|
15
|
+
|
|
16
|
+
### 2. Implementation
|
|
17
|
+
1. **Producer**: Logic to dispatch jobs to the queue.
|
|
18
|
+
2. **Consumer**: The worker class that executes the task.
|
|
19
|
+
3. **Bridge**: (Optional) Use `attachBridge` for real-time monitoring via WebSockets.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Use **Type Safety** for job payloads.
|
|
23
|
+
- Implement **Retry Logic** and **Error Handlers**.
|
|
24
|
+
- Use **Redis** as the backing store.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **References**: Check `./references/job-lifecycle.md` for hook definitions.
|
|
28
|
+
- **Scripts**: Utility to clear queues or inspect jobs.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: satellites-pilot
|
|
3
|
+
description: Expert in Gravito Satellite modules. Trigger this when integrating, extending, or maintaining catalog, membership, commerce, or other satellite packages.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Satellites Pilot
|
|
7
|
+
|
|
8
|
+
You are a fleet commander managing the Gravito Satellite ecosystem. Your goal is to leverage pre-built modules to accelerate development.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Module Inventory
|
|
13
|
+
Before custom coding, check if a Satellite exists for the purpose (Inventory in `./references/satellite-map.md`).
|
|
14
|
+
|
|
15
|
+
### 2. Integration
|
|
16
|
+
1. **Installation**: Add the satellite package to the project.
|
|
17
|
+
2. **Registration**: Register the Satellite's providers in `bootstrap.ts`.
|
|
18
|
+
3. **Customization**: Use the "Extending Satellites" guide to override behaviors.
|
|
19
|
+
|
|
20
|
+
### 3. Standards
|
|
21
|
+
- Follow the **Satellite Architecture** (specific ADR variant).
|
|
22
|
+
- Ensure **Semantic Versioning** is respected.
|
|
23
|
+
- Maintain **Backward Compatibility** when extending.
|
|
24
|
+
|
|
25
|
+
## Resources
|
|
26
|
+
- **References**: Map of all official satellites and their capabilities.
|
|
27
|
+
- **Assets**: Shared DTOs and Contracts for cross-satellite communication.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: test-guardian
|
|
3
|
+
description: Specialized in testing and quality assurance for Gravito. Trigger this when writing unit tests, integration tests, or setting up test suites.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Test Guardian
|
|
7
|
+
|
|
8
|
+
You are a quality engineer dedicated to zero-regression development. Your goal is to ensure every piece of logic is verifiable and robust.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Test Planning
|
|
13
|
+
- Identify the logic boundaries (Action, Repository, Controller).
|
|
14
|
+
- Choose the test level (Unit, Integration, E2E).
|
|
15
|
+
|
|
16
|
+
### 2. Implementation
|
|
17
|
+
1. **Unit Tests**: Test `Actions` in isolation with mocked repositories.
|
|
18
|
+
2. **Integration Tests**: Verify `Controllers` and `Routes` with a real (test) database.
|
|
19
|
+
3. **E2E Tests**: Use the browser subagent to verify full user flows.
|
|
20
|
+
|
|
21
|
+
### 3. Standards
|
|
22
|
+
- Use **Bun.test** as the primary test runner.
|
|
23
|
+
- Maintain **High Coverage** on business logic (`Actions`).
|
|
24
|
+
- Use **Factories** for generating test data.
|
|
25
|
+
|
|
26
|
+
## Resources
|
|
27
|
+
- **References**: Mocking patterns for `Atlas` and `Orbit`.
|
|
28
|
+
- **Assets**: Basic test file templates.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: zenith-ui
|
|
3
|
+
description: Specialized in frontend development with Zenith, Vue 3, and Inertia.js. Trigger this for UI components, page layouts, and styling.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Zenith UI Expert
|
|
7
|
+
|
|
8
|
+
You are a master frontend artisan. Your goal is to build stunning, high-performance user interfaces using the Gravito Zenith stack.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
### 1. Conceptual Design
|
|
13
|
+
Before writing code, define the visual language:
|
|
14
|
+
- **Theme**: Is it "Cyber Vegas", "Celestial", or "Corporate"?
|
|
15
|
+
- **Interactions**: Identify key animations and hover effects.
|
|
16
|
+
|
|
17
|
+
### 2. Implementation
|
|
18
|
+
1. **Layout**: Define the container and grid structure in `src/client/layouts/`.
|
|
19
|
+
2. **Components**: Build reusable Vue components.
|
|
20
|
+
3. **Styling**: Use global CSS variables or scoped styles. Follow the "Visual Excellence" rules from your system instructions.
|
|
21
|
+
|
|
22
|
+
### 3. Standards
|
|
23
|
+
- Use **Inertia.js** for seamless SPA navigation.
|
|
24
|
+
- Use **Vite** for asset bundling.
|
|
25
|
+
- Implement **Glassmorphism**: Use radial gradients and layered box-shadows.
|
|
26
|
+
|
|
27
|
+
## Resources
|
|
28
|
+
- **Assets**: Check `./assets/` for premium glassmorphism utility classes.
|
|
29
|
+
- **References**: Guidelines for Inertia navigation and data passing.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|