Skip to content

feat: byot.#21

Merged
knightedcodemonkey merged 3 commits intomainfrom
bananas
Mar 21, 2026
Merged

feat: byot.#21
knightedcodemonkey merged 3 commits intomainfrom
bananas

Conversation

@knightedcodemonkey
Copy link
Owner

First step at #18

Copilot AI review requested due to automatic review settings March 21, 2026 17:00
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds the first slice of the BYOT (Bring Your Own Token) groundwork for the planned AI side panel feature (#18): a feature-flagged UI for entering a GitHub PAT, persisting it locally, and using it to list writable repositories via the GitHub API.

Changes:

  • Adds a feature flag (?feature-ai=true / localStorage) to show/hide BYOT controls.
  • Implements PAT storage/masking + GitHub API repo discovery and selection persistence.
  • Adds Playwright coverage and a BYOT setup guide in docs.

Reviewed changes

Copilot reviewed 11 out of 13 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src/styles/ai-controls.css Adds styling for the BYOT controls (token input/buttons + repo select).
src/styles.css Imports the new AI/BYOT controls stylesheet.
src/modules/github-token-store.js localStorage-backed token load/save/clear + masking helper.
src/modules/github-byot-controls.js BYOT UI controller: token validation via repo listing, repo selection persistence.
src/modules/github-api.js GitHub API client to list writable repositories (pagination + normalization).
src/modules/feature-flags.js Feature flag for enabling the AI/BYOT UI via query param/localStorage.
src/index.html Adds the BYOT controls markup (token input, add/delete, repo selector).
src/app.js Wires feature flag + creates BYOT controls in the main app.
playwright/app.spec.ts Adds tests for feature-flag visibility and persistence across reload.
docs/media/byot-model-perms.png Adds screenshot asset for PAT model permissions.
docs/byot.md Adds BYOT setup guide (fine-grained PAT permissions + enablement).
README.md Links to the BYOT guide.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@knightedcodemonkey knightedcodemonkey merged commit f38a0dc into main Mar 21, 2026
1 check passed
@knightedcodemonkey knightedcodemonkey deleted the bananas branch March 21, 2026 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants