├── next.config.js ├── scripts └── install.sh ├── pages ├── terminal.tsx ├── api │ ├── auth │ │ └── [...nextauth].ts │ └── ai │ │ └── suggest.ts ├── plans.tsx ├── settings.tsx ├── tasks.tsx └── editor.tsx ├── prisma └── schema.prisma ├── styles ├── CodeEditor.module.css ├── PlanEditor.module.css └── TaskList.module.css ├── components ├── Sidebar.tsx ├── PlanEditor.tsx ├── CodeEditor.tsx └── TaskList.tsx ├── tsconfig.json ├── server.js ├── package.json ├── implementation.md ├── .gitignore ├── LICENSE └── README.md /next.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | reactStrictMode: true, 3 | images: { 4 | domains: ['avatars.githubusercontent.com'], 5 | }, 6 | }; 7 | -------------------------------------------------------------------------------- /scripts/install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Install dependencies 4 | npm install 5 | 6 | # Set up Prisma 7 | npx prisma generate 8 | 9 | # Run database migrations 10 | npx prisma migrate deploy 11 | 12 | # Start the development server 13 | npm run dev 14 | -------------------------------------------------------------------------------- /pages/terminal.tsx: -------------------------------------------------------------------------------- 1 | import dynamic from 'next/dynamic'; 2 | import styles from '../styles/Terminal.module.css'; 3 | 4 | const XTerm = dynamic(() => import('react-xterm'), { ssr: false }); 5 | 6 | const Terminal = () => ( 7 |
8 |

Terminal

9 | 10 |
11 | ); 12 | 13 | export default Terminal; 14 | -------------------------------------------------------------------------------- /pages/api/auth/[...nextauth].ts: -------------------------------------------------------------------------------- 1 | import NextAuth from 'next-auth'; 2 | import Providers from 'next-auth/providers'; 3 | 4 | export default NextAuth({ 5 | providers: [ 6 | Providers.GitHub({ 7 | clientId: process.env.GITHUB_CLIENT_ID, 8 | clientSecret: process.env.GITHUB_CLIENT_SECRET, 9 | }), 10 | ], 11 | database: process.env.DATABASE_URL, 12 | }); 13 | -------------------------------------------------------------------------------- /prisma/schema.prisma: -------------------------------------------------------------------------------- 1 | // prisma/schema.prisma 2 | datasource db { 3 | provider = "postgresql" 4 | url = env("DATABASE_URL") 5 | } 6 | 7 | generator client { 8 | provider = "prisma-client-js" 9 | } 10 | 11 | model Task { 12 | id Int @id @default(autoincrement()) 13 | description String 14 | status String 15 | createdAt DateTime @default(now()) 16 | } 17 | -------------------------------------------------------------------------------- /styles/CodeEditor.module.css: -------------------------------------------------------------------------------- 1 | .codeEditor { 2 | position: relative; 3 | width: 100%; 4 | height: 100%; 5 | border: 1px solid #ddd; 6 | border-radius: 4px; 7 | background-color: #f5f5f5; 8 | } 9 | 10 | .editorContainer { 11 | position: absolute; 12 | top: 0; 13 | right: 0; 14 | bottom: 0; 15 | left: 0; 16 | } 17 | 18 | .monaco-editor { 19 | height: 100% !important; 20 | } 21 | -------------------------------------------------------------------------------- /styles/PlanEditor.module.css: -------------------------------------------------------------------------------- 1 | .planEditor { 2 | display: flex; 3 | flex-direction: column; 4 | padding: 20px; 5 | background-color: #f0f0f0; 6 | border-radius: 8px; 7 | box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); 8 | } 9 | 10 | .planEditor h2 { 11 | margin: 0; 12 | margin-bottom: 20px; 13 | color: #333; 14 | } 15 | 16 | .planEditor textarea { 17 | width: 100%; 18 | height: 150px; 19 | padding: 10px; 20 | border: 1px solid #ccc; 21 | border-radius: 4px; 22 | resize: vertical; 23 | } 24 | -------------------------------------------------------------------------------- /components/Sidebar.tsx: -------------------------------------------------------------------------------- 1 | import Link from 'next/link'; 2 | import styles from './Sidebar.module.css'; 3 | 4 | const Sidebar = () => ( 5 | 14 | ); 15 | 16 | export default Sidebar; 17 | -------------------------------------------------------------------------------- /pages/plans.tsx: -------------------------------------------------------------------------------- 1 | import { useState } from 'react'; 2 | import styles from '../styles/Plans.module.css'; 3 | 4 | const Plans = () => { 5 | const [spec, setSpec] = useState(""); 6 | const [plan, setPlan] = useState(""); 7 | 8 | return ( 9 |
10 |

Plans

11 |