feat: complete ShiftCraft — AI-powered shift scheduling SaaS

Complete implementation including:
- Landing page with hero, features, how-it-works, pricing
- Employee management (CRUD with soft delete)
- AI constraint parser (Anthropic Claude API)
- German labor law templates (ArbZG §3, §5, §9)
- HiGHS ILP solver for optimal fair schedules
- Schedule calendar result view (employee × date grid)
- Shift framework configuration (periods + shifts)
- Subscription tiers: Free / Pro / Business
- PocketBase setup script with collection creation + seed data
- .env.example with all required variables documented

Pages: employees, constraints (list/new/templates), schedules (list/new/[id]),
       settings (organization/shifts/billing), dashboard

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-18 07:47:31 +02:00
parent 2ea4ca5d52
commit 36e0946ee4
38 changed files with 4254 additions and 133 deletions

View File

@@ -0,0 +1,35 @@
export type ConstraintType =
| 'max_hours_per_day'
| 'max_hours_per_week'
| 'min_rest_between_shifts'
| 'max_consecutive_shifts'
| 'max_consecutive_shift_type'
| 'min_consecutive_days_off'
| 'max_shifts_per_period_per_week'
| 'forbidden_shift_sequence'
| 'employee_unavailable'
| 'employee_prefers_period'
| 'employee_avoids_period'
| 'require_role_per_shift'
| 'max_weekend_shifts_per_month'
| 'fair_distribution'
export type ConstraintScope =
| { type: 'global' }
| { type: 'employee'; employee_id: string }
| { type: 'role'; role: string }
| { type: 'period'; period_id: string }
export interface ConstraintJSON {
type: ConstraintType
scope: ConstraintScope
params: Record<string, unknown>
hard: boolean
weight?: number
natural_language_summary: string
}
export interface ParsedConstraintResult {
constraints: ConstraintJSON[]
ambiguities: string[]
}