forked from dyad-sh/dyad
-
Notifications
You must be signed in to change notification settings - Fork 0
BuildOrbit: Improve bry92/vibe-code-forge #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
bry92
wants to merge
80
commits into
main
Choose a base branch
from
buildorbit/716abee0
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
80 commits
Select commit
Hold shift + click to select a range
9e3eba0
Add app.js
bry92 231f3ea
Add app.jsx
bry92 897e489
Add server.js
bry92 d0b0e4f
Add db/pool.js
bry92 264135f
Add index.html
bry92 3f8fad9
Add migrate.js
bry92 ea79d9f
Add styles.css
bry92 60ecd9f
Add .env.example
bry92 05d67f5
Add package.json
bry92 8affe58
Add db/queries.js
bry92 33416d9
Add routes/api.js
bry92 cff8080
Add routes/auth.js
bry92 c34a361
Add middleware/auth.js
bry92 d1c2bb8
Add components/auth-form.jsx
bry92 c569da5
Add components/dashboard.jsx
bry92 d17654e
Add migrations/001_schema.js
bry92 1b69cc1
Add components/data-table.jsx
bry92 e2d5602
Add components/navigation.jsx
bry92 78b6540
Add components/create-form.jsx
bry92 5589b32
Add README.md (generated by BuildOrbit)
bry92 9a9e3a6
Add server.js
bry92 e4ebfa1
Add routes/api.js
bry92 76c7b33
Add db/pool.js
bry92 ef6a11a
Add migrations/001_schema.js
bry92 7f7c7e3
Add package.json
bry92 a3fd6ca
Add index.html
bry92 8f998dd
Add styles.css
bry92 d9d7d91
Add app.js
bry92 fa35b85
Add app.jsx
bry92 028372d
Add components/auth-form.jsx
bry92 f51473b
Add components/dashboard.jsx
bry92 95f5aa2
Add components/data-table.jsx
bry92 805a988
Add components/create-form.jsx
bry92 60a9911
Add components/navigation.jsx
bry92 bb1e5f7
Add .env.example
bry92 7c86759
Add migrate.js
bry92 ca3405a
Add routes/auth.js
bry92 5b3a5e1
Add middleware/auth.js
bry92 fcbd2f2
Add db/queries.js
bry92 116b6f9
Add README.md (generated by BuildOrbit)
bry92 5955ba1
Add server.js
bry92 8f8c0ec
Add routes/api.js
bry92 f8449aa
Add db/pool.js
bry92 0bf0cfa
Add migrations/001_schema.js
bry92 b0930f5
Add package.json
bry92 a1bc572
Add index.html
bry92 11e3d77
Add styles.css
bry92 4064f9f
Add app.js
bry92 f8fbd44
Add app.jsx
bry92 4917e0f
Add components/auth-form.jsx
bry92 9fd1e0c
Add components/dashboard.jsx
bry92 13362ff
Add components/data-table.jsx
bry92 efff921
Add components/create-form.jsx
bry92 38430a2
Add components/navigation.jsx
bry92 078a39e
Add .env.example
bry92 842b990
Add migrate.js
bry92 981d716
Add routes/auth.js
bry92 5feda5c
Add middleware/auth.js
bry92 a3f733a
Add db/queries.js
bry92 59351fd
Add README.md (generated by BuildOrbit)
bry92 c4df06a
Add server.js
bry92 0f50ce0
Add routes/api.js
bry92 3803225
Add db/pool.js
bry92 2be1725
Add migrations/001_schema.js
bry92 d828181
Add package.json
bry92 87ee143
Add index.html
bry92 379d524
Add styles.css
bry92 e37cc32
Add app.js
bry92 005827a
Add app.jsx
bry92 246a76f
Add components/auth-form.jsx
bry92 d571e9b
Add components/dashboard.jsx
bry92 908e179
Add components/data-table.jsx
bry92 fdcef3c
Add components/create-form.jsx
bry92 4b9e865
Add components/navigation.jsx
bry92 65b3c26
Add .env.example
bry92 d83e987
Add migrate.js
bry92 69789e8
Add routes/auth.js
bry92 6bf7745
Add middleware/auth.js
bry92 e6c6b27
Add db/queries.js
bry92 0b3cfa3
Add README.md (generated by BuildOrbit)
bry92 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,37 +1,4 @@ | ||
| # Environment variables needed for dyad local development. | ||
| # To use, copy this file to a new file named ".env" and fill in your private keys and settings. | ||
| # Your actual .env file should NOT be committed. | ||
|
|
||
| # AI Provider API Keys(Optional) | ||
| OPENAI_API_KEY= | ||
| ANTHROPIC_API_KEY= | ||
| GOOGLE_API_KEY= | ||
|
|
||
|
|
||
| # Local AI Model Configuration (Optional) | ||
| # Set these if you are running local AI models like Ollama or LM Studio. | ||
| # Default for Ollama is http://127.0.0.1:11434 | ||
| OLLAMA_HOST= | ||
|
|
||
| # GitHub Integration (Optional) | ||
| # Needed for features that interact with GitHub repositories. | ||
| GITHUB_CLIENT_ID= | ||
| GITHUB_CLIENT_SECRET= | ||
| GITHUB_TOKEN= | ||
|
|
||
|
|
||
| # Apple Notarization (macOS Build Only) | ||
| # Only required if you are building and signing a release version for macOS. | ||
| APPLE_ID= | ||
| APPLE_PASSWORD= | ||
| APPLE_TEAM_ID= | ||
| SM_CODE_SIGNING_CERT_SHA1= | ||
|
|
||
|
|
||
| # Development & Testing Variables (Advanced) | ||
| # These are typically not needed for standard contribution. | ||
| # NODE_ENV=development | ||
| # E2E_TEST_BUILD= | ||
| # CI= | ||
| # DYAD_ENGINE_URL= | ||
| # DYAD_GATEWAY_URL= | ||
| DATABASE_URL=./app.db | ||
| JWT_SECRET=change-me-in-production | ||
| PORT=3000 | ||
| NODE_ENV=development | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,34 +1,52 @@ | ||
| # Dyad | ||
|
|
||
| Dyad is a local, open-source AI app builder. It's fast, private, and fully under your control β like Lovable, v0, or Bolt, but running right on your machine. | ||
|
|
||
| [](https://dyad.sh/) | ||
|
|
||
| More info at: [https://dyad.sh/](https://dyad.sh/) | ||
|
|
||
| ## π Features | ||
|
|
||
| - β‘οΈ **Local**: Fast, private and no lock-in. | ||
| - π **Bring your own keys**: Use your own AI API keys β no vendor lock-in. | ||
| - π₯οΈ **Cross-platform**: Easy to run on Mac or Windows. | ||
|
|
||
| ## π¦ Download | ||
|
|
||
| No sign-up required. Just download and go. | ||
|
|
||
| ### [π Download for your platform](https://www.dyad.sh/#download) | ||
|
|
||
| ## π€ Community | ||
|
|
||
| Join our growing community of AI app builders on **Reddit**: [r/dyadbuilders](https://www.reddit.com/r/dyadbuilders/) - share your projects and get help from the community! | ||
|
|
||
| ## π οΈ Contributing | ||
|
|
||
| **Dyad** is open-source (see License info below). | ||
|
|
||
| If you're interested in contributing to dyad, please read our [contributing](./CONTRIBUTING.md) doc. | ||
|
|
||
| ## License | ||
|
|
||
| - All the code in this repo outside of `src/pro` is open-source and licensed under Apache 2.0 - see [LICENSE](./LICENSE). | ||
| - All the code in this repo within `src/pro` is fair-source and licensed under [Functional Source License 1.1 Apache 2.0](https://fsl.software/) - see [LICENSE](./src/pro/LICENSE). | ||
| # Improve bry92/vibe-code-forge | ||
|
|
||
| > Generated by [BuildOrbit](https://buildorbit.polsia.app) β the autonomous app builder that shows its work. | ||
|
|
||
| ## About | ||
|
|
||
| **Prompt:** Improve bry92/vibe-code-forge | ||
| **Archetype:** INTERACTIVE LIGHT APP | ||
| **Run ID:** `716abee0-8367-46d0-8960-8adcc7e220cd` | ||
|
|
||
| ## Files | ||
|
|
||
| - `server.js` | ||
| - `routes/api.js` | ||
| - `db/pool.js` | ||
| - `migrations/001_schema.js` | ||
| - `package.json` | ||
| - `index.html` | ||
| - `styles.css` | ||
| - `app.js` | ||
| - `app.jsx` | ||
| - `components/auth-form.jsx` | ||
| - `components/dashboard.jsx` | ||
| - `components/data-table.jsx` | ||
| - `components/create-form.jsx` | ||
| - `components/navigation.jsx` | ||
| - `.env.example` | ||
| - `migrate.js` | ||
| - `routes/auth.js` | ||
| - `middleware/auth.js` | ||
| - `db/queries.js` | ||
|
|
||
|
|
||
| ## Run Locally | ||
|
|
||
| ```bash | ||
| npm install | ||
| npm start | ||
| ``` | ||
|
|
||
| The app starts on port 3000 by default. Set the `DATABASE_URL` environment variable for database-backed features. | ||
|
|
||
| ## Pipeline | ||
|
|
||
| This app was generated through BuildOrbit's 6-phase glass-box pipeline: | ||
|
|
||
| 1. **Intent Gate** β Classifies intent, locks constraint contract | ||
| 2. **Plan** β Deterministic execution plan with task breakdown | ||
| 3. **Scaffold** β File structure and dependency manifest | ||
| 4. **Code** β Full implementation across all files | ||
| 5. **Save** β Artifact persistence with audit hash | ||
| 6. **Verify** β Automated quality checks (React wiring, DOM patterns, error handling) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,100 @@ | ||
| // === CONTRACT MARKERS (auto-injected for traceability) === | ||
| // CONTRACT: primary-action-button | ||
| // === END CONTRACT MARKERS === | ||
|
|
||
| (function() { | ||
| var messageInput = document.getElementById("messageInput"); | ||
| var sendBtn = document.getElementById("sendBtn"); | ||
| var messageList = document.getElementById("messageList"); | ||
| var emptyState = document.getElementById("emptyState"); | ||
| var formError = document.getElementById("formError"); | ||
| var usernameInput = document.getElementById("usernameInput"); | ||
| var roomSelect = document.getElementById("roomSelect"); | ||
| var currentRoomLabel = document.getElementById("currentRoom"); | ||
| var currentRoom = "general"; | ||
| var pollTimer = null; | ||
|
|
||
| function getUsername() { | ||
| return (usernameInput.value || "").trim() || "Anonymous"; | ||
| } | ||
|
|
||
| function showError(msg) { | ||
| formError.textContent = msg; | ||
| formError.style.display = "block"; | ||
| setTimeout(function() { formError.style.display = "none"; }, 3000); | ||
| } | ||
|
|
||
| function escHtml(str) { | ||
| var d = document.createElement("div"); | ||
| d.textContent = str; | ||
| return d.innerHTML; | ||
| } | ||
|
|
||
| function formatTime(ts) { | ||
| var d = new Date(ts); | ||
| return d.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" }); | ||
| } | ||
|
|
||
| function renderMessages(messages) { | ||
| if (!messages || messages.length === 0) { | ||
| messageList.innerHTML = ""; | ||
| messageList.appendChild(emptyState); | ||
| emptyState.style.display = "flex"; | ||
| return; | ||
| } | ||
| emptyState.style.display = "none"; | ||
| var myName = getUsername(); | ||
| messageList.innerHTML = messages.map(function(msg) { | ||
| var isSelf = msg.username === myName; | ||
| return '<div class="flex flex-col ' + (isSelf ? "items-end" : "items-start") + '">' + | ||
| '<div class="msg-username ' + (isSelf ? "text-indigo-600" : "text-gray-700") + '">' + escHtml(msg.username || "Anonymous") + '</div>' + | ||
| '<div class="msg-bubble ' + (isSelf ? "self" : "other") + '">' + escHtml(msg.content) + '</div>' + | ||
| '<div class="msg-meta">' + formatTime(msg.created_at) + '</div>' + | ||
| '</div>'; | ||
| }).join(""); | ||
| messageList.scrollTop = messageList.scrollHeight; | ||
| } | ||
|
|
||
| function loadMessages() { | ||
| fetch("/api/messages?room=" + encodeURIComponent(currentRoom)) | ||
| .then(function(r) { return r.json(); }) | ||
| .then(function(data) { if (data.success) renderMessages(data.messages); }) | ||
| .catch(function() {}); | ||
| } | ||
|
|
||
| function sendMessage() { | ||
| var content = messageInput.value.trim(); | ||
| if (!content) { showError("Message cannot be empty"); messageInput.focus(); return; } | ||
| sendBtn.disabled = true; | ||
| fetch("/api/messages", { | ||
| method: "POST", | ||
| headers: { "Content-Type": "application/json" }, | ||
| body: JSON.stringify({ content: content, room: currentRoom, username: getUsername() }) | ||
| }) | ||
| .then(function(r) { return r.json(); }) | ||
| .then(function(data) { | ||
| if (data.success) { messageInput.value = ""; loadMessages(); } | ||
| else { showError(data.message || "Failed to send"); } | ||
| }) | ||
| .catch(function() { showError("Network error"); }) | ||
| .finally(function() { sendBtn.disabled = false; messageInput.focus(); }); | ||
| } | ||
|
|
||
| sendBtn.addEventListener("click", sendMessage); | ||
| messageInput.addEventListener("keydown", function(e) { if (e.key === "Enter") sendMessage(); }); | ||
|
|
||
| roomSelect.addEventListener("change", function() { | ||
| currentRoom = roomSelect.value; | ||
| currentRoomLabel.textContent = currentRoom; | ||
| loadMessages(); | ||
| }); | ||
|
|
||
| // Poll for new messages every 3 seconds | ||
| function startPolling() { | ||
| if (pollTimer) clearInterval(pollTimer); | ||
| pollTimer = setInterval(loadMessages, 3000); | ||
| } | ||
|
|
||
| loadMessages(); | ||
| startPolling(); | ||
| })(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| // React app β compiled by Babel standalone in browser (no import/export/require) | ||
| const { useState, useEffect, useCallback, useRef } = React; | ||
|
|
||
| // Reusable Card component | ||
| const Card = ({ children, className = "" }) => ( | ||
| <div className={`bg-white rounded-xl shadow-sm border border-gray-200 p-6 ${className}`}>{children}</div> | ||
| ); | ||
|
|
||
| // Reusable Button component | ||
| const Button = ({ children, onClick, variant = "primary", className = "" }) => { | ||
| const variants = { | ||
| primary: "bg-blue-600 hover:bg-blue-700 text-white", | ||
| secondary: "bg-gray-100 hover:bg-gray-200 text-gray-700", | ||
| danger: "bg-red-600 hover:bg-red-700 text-white", | ||
| ghost: "hover:bg-gray-100 text-gray-600" | ||
| }; | ||
| return <button onClick={onClick} className={`px-4 py-2 rounded-lg font-medium transition-colors cursor-pointer ${variants[variant]} ${className}`}>{children}</button>; | ||
| }; | ||
|
|
||
| const App = () => { | ||
| const [items, setItems] = useState([]); | ||
| return ( | ||
| <div className="min-h-screen bg-gray-50"> | ||
| <div className="p-8 max-w-5xl mx-auto"> | ||
| <h1 className="text-2xl font-bold text-gray-900 mb-6">Improve Bry92/vibe- -forge</h1> | ||
| <Card> | ||
| <p className="text-gray-500">Loading messages...</p> | ||
| </Card> | ||
| </div> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| ReactDOM.createRoot(document.getElementById("root")).render(<App />); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| // React app β compiled by Babel standalone in browser (no import/export/require) | ||
| const { useState, useEffect, useCallback, useRef } = React; | ||
|
|
||
| // Reusable Card component | ||
| const Card = ({ children, className = "" }) => ( | ||
| <div className={`bg-white rounded-xl shadow-sm border border-gray-200 p-6 ${className}`}>{children}</div> | ||
| ); | ||
|
|
||
| // Reusable Button component | ||
| const Button = ({ children, onClick, variant = "primary", className = "" }) => { | ||
| const variants = { | ||
| primary: "bg-blue-600 hover:bg-blue-700 text-white", | ||
| secondary: "bg-gray-100 hover:bg-gray-200 text-gray-700", | ||
| danger: "bg-red-600 hover:bg-red-700 text-white", | ||
| ghost: "hover:bg-gray-100 text-gray-600" | ||
| }; | ||
| return <button onClick={onClick} className={`px-4 py-2 rounded-lg font-medium transition-colors cursor-pointer ${variants[variant]} ${className}`}>{children}</button>; | ||
| }; | ||
|
|
||
| const App = () => { | ||
| const [items, setItems] = useState([]); | ||
| return ( | ||
| <div className="min-h-screen bg-gray-50"> | ||
| <div className="p-8 max-w-5xl mx-auto"> | ||
| <h1 className="text-2xl font-bold text-gray-900 mb-6">Improve Bry92/vibe- -forge</h1> | ||
| <Card> | ||
| <p className="text-gray-500">Loading messages...</p> | ||
| </Card> | ||
| </div> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| ReactDOM.createRoot(document.getElementById("root")).render(<App />); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| // React app β compiled by Babel standalone in browser (no import/export/require) | ||
| const { useState, useEffect, useCallback, useRef } = React; | ||
|
|
||
| // Reusable Card component | ||
| const Card = ({ children, className = "" }) => ( | ||
| <div className={`bg-white rounded-xl shadow-sm border border-gray-200 p-6 ${className}`}>{children}</div> | ||
| ); | ||
|
|
||
| // Reusable Button component | ||
| const Button = ({ children, onClick, variant = "primary", className = "" }) => { | ||
| const variants = { | ||
| primary: "bg-blue-600 hover:bg-blue-700 text-white", | ||
| secondary: "bg-gray-100 hover:bg-gray-200 text-gray-700", | ||
| danger: "bg-red-600 hover:bg-red-700 text-white", | ||
| ghost: "hover:bg-gray-100 text-gray-600" | ||
| }; | ||
| return <button onClick={onClick} className={`px-4 py-2 rounded-lg font-medium transition-colors cursor-pointer ${variants[variant]} ${className}`}>{children}</button>; | ||
| }; | ||
|
|
||
| const App = () => { | ||
| const [items, setItems] = useState([]); | ||
| return ( | ||
| <div className="min-h-screen bg-gray-50"> | ||
| <div className="p-8 max-w-5xl mx-auto"> | ||
| <h1 className="text-2xl font-bold text-gray-900 mb-6">Improve Bry92/vibe- -forge</h1> | ||
| <Card> | ||
| <p className="text-gray-500">Loading messages...</p> | ||
| </Card> | ||
| </div> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| ReactDOM.createRoot(document.getElementById("root")).render(<App />); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| // React app β compiled by Babel standalone in browser (no import/export/require) | ||
| const { useState, useEffect, useCallback, useRef } = React; | ||
|
|
||
| // Reusable Card component | ||
| const Card = ({ children, className = "" }) => ( | ||
| <div className={`bg-white rounded-xl shadow-sm border border-gray-200 p-6 ${className}`}>{children}</div> | ||
| ); | ||
|
|
||
| // Reusable Button component | ||
| const Button = ({ children, onClick, variant = "primary", className = "" }) => { | ||
| const variants = { | ||
| primary: "bg-blue-600 hover:bg-blue-700 text-white", | ||
| secondary: "bg-gray-100 hover:bg-gray-200 text-gray-700", | ||
| danger: "bg-red-600 hover:bg-red-700 text-white", | ||
| ghost: "hover:bg-gray-100 text-gray-600" | ||
| }; | ||
| return <button onClick={onClick} className={`px-4 py-2 rounded-lg font-medium transition-colors cursor-pointer ${variants[variant]} ${className}`}>{children}</button>; | ||
| }; | ||
|
|
||
| const App = () => { | ||
| const [items, setItems] = useState([]); | ||
| return ( | ||
| <div className="min-h-screen bg-gray-50"> | ||
| <div className="p-8 max-w-5xl mx-auto"> | ||
| <h1 className="text-2xl font-bold text-gray-900 mb-6">Improve Bry92/vibe- -forge</h1> | ||
| <Card> | ||
| <p className="text-gray-500">Loading messages...</p> | ||
| </Card> | ||
| </div> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| ReactDOM.createRoot(document.getElementById("root")).render(<App />); |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The provided example
DATABASE_URL=./app.dbis a SQLite-style file path, but the app usespgPoolwithconnectionStringin bothserver.jsandmigrate.js. Following this template causes DB-backed routes/migrations to fail at runtime because the connection value is not a valid PostgreSQL connection URI.Useful? React with πΒ / π.