GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(app): add an independent Side bar mode by joe-ieta · Pull Request #60867 · anomalyco/opencode

feat(app): add an independent Side bar mode #60867

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.

Sign up for GitHub

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

Closed
joe-ieta wants to merge 18 commits into anomalyco:dev from joe-ieta:sidebar-mode

Uh oh!

There was an error while loading. Please reload this page.

Closed

feat(app): add an independent Side bar mode #60867

Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
a18285f
feat(app): add independent Side bar mode
joe-ieta Oct 31, 2026
a64180f
Merge branch 'dev' into sidebar-mode
joe-ieta Nov 1, 2026
af04a8b
chore(app): sync Side bar contribution with dev
joe-ieta Nov 2, 2026
b88b94a
fix(app): preserve Side bar project and descendant activity state
joe-ieta Nov 2, 2026
6d53576
chore(app): sync Side bar contribution with upstream dev
joe-ieta Nov 3, 2026
703db47
fix(app): stabilize Side bar projects and background Shell activity
joe-ieta Nov 3, 2026
9776be7
chore(app): merge Side bar contribution with upstream dev
joe-ieta Nov 5, 2026
01e4361
feat(app): keep active and completed sessions visible in Side bar
joe-ieta Nov 5, 2026
fa28727
chore(app): bring Side bar contribution up to date with upstream dev
joe-ieta Nov 5, 2026
839a681
fix(app): preserve Side bar close actions with upstream tabs
joe-ieta Nov 5, 2026
9e0207d
test(app): retain one busy field in session fixtures
joe-ieta Nov 5, 2026
50555d9
chore(app): merge latest upstream dev into Side bar candidate
joe-ieta Nov 5, 2026
7315a1d
fix(app): keep Side bar activity prefetch out of Inbox startup
joe-ieta Nov 5, 2026
f8d1660
fix(app): wait for initial session activity in Inbox
joe-ieta Nov 5, 2026
ad6923e
Merge branch 'dev' into sidebar-mode
joe-ieta Nov 5, 2026
2de04af
fix(app): preserve Inbox activity readiness on upstream dev
joe-ieta Nov 5, 2026
ac3d33d
chore(app): sync Side bar with upstream dev
joe-ieta Nov 9, 2026
98a9638
feat(app): integrate Home project actions into Side bar
joe-ieta Nov 8, 2026
File filter
Filter by extension

Clear filters
Conversations
Failed to load comments.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Jump to
Jump to file
Failed to load files.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Diff view
Diff view
Prev Previous commit
feat(app): integrate Home project actions into Side bar
Always group Side bar sessions by project and label the section Projects. Share project menus and folder selection with Home, support closing and reopening projects, and expose session export.

Register new draft tabs before asynchronous navigation so cold page loads cannot skip persistence. Adapt the useful project-management ideas from PR #2 to the current Home implementation.

Co-authored-by: Francesco Boes <[email protected]>
(cherry picked from commit ca61e33)
  • Loading branch information

Uh oh!

There was an error while loading. Please reload this page.

@joe-ieta Francesco Boes
joe-ieta and Francesco Boes committed Nov 9, 2026
commit 98a9638743d03be530e0c3b525692a86178008c5

There are no files selected for viewing

166 changes: 138 additions & 28 deletions 166 packages/app/e2e/regression/tabs.spec.ts
Show comments
View file
Open in desktop

Large diffs are not rendered by default.

Oops, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

45 changes: 41 additions & 4 deletions 45 packages/app/src/home/projects/actions.tsx
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,16 @@ import { toaster } from "@opencode/ui/toast"
import { useLanguage } from "@/runtime/i18n/language"
import { usePlatform } from "@/runtime/platform/platform"
import { ServerConnection } from "@/runtime/server/registry"
import { isServerUnauthorized } from "@/runtime/server/health-machine"
import { isServerFailed, isServerUnauthorized } from "@/runtime/server/health-machine"
import { useGlobal } from "@/runtime/server/runtime"
import { useSettingsSurface } from "@/settings/surface"
import { errorMessage } from "@/shell/layout/helpers"
import { errorMessage, homeProjectDirectories } from "@/shell/layout/helpers"
import { showToast } from "@/shell/notifications/toast"
import type { LocalProject } from "@/shell/state/layout"
import { createProjectSessionActions } from "@/shell/tabs/project-sessions"
import { useDirectoryPicker } from "@/workspaces/selection/picker"
import { displayName } from "@opencode/ui/project-avatar"
import { addProjects } from "./add"
import {
INITIAL_PROJECT_IMPORT_STATE,
selectProjectImporting,
Expand All @@ -39,6 +42,7 @@ export function createProjectActions() {
const sessions = createProjectSessionActions()

const revealProject = useRevealProject()
const pickDirectory = useDirectoryPicker()

function editServer(conn: ServerConnection.Http, onSave?: (saved: ServerConnection.Http) => void) {
void import("@/servers/connect/dialog").then(({ DialogServer }) => {
Expand All @@ -55,6 +59,26 @@ export function createProjectActions() {
return true
}

function choose(
conn: ServerConnection.Any,
onSelect?: (server: ServerConnection.Any, directories: string[]) => void,
) {
if (authenticate(conn, (next) => choose(next, onSelect))) return
if (isServerFailed(global.servers.health[ServerConnection.key(conn)])) return
pickDirectory({
server: conn,
title: language.t("command.project.open"),
multiple: true,
onSelect: (result) => {
const directories = homeProjectDirectories(result)
if (!directories.length) return
if (onSelect) return onSelect(conn, directories)
const ctx = global.serverCtx(ServerConnection.key(conn))
if (ctx) void addProjects(ctx, directories)
},
})
}

const directories = (project: LocalProject) => [project.worktree, ...(project.sandboxes ?? [])]

const currentPath = () => location.pathname + location.search
Expand Down Expand Up @@ -156,6 +180,7 @@ export function createProjectActions() {
return {
authenticate,
editServer,
choose,
openNewSession(conn: ServerConnection.Any, directory: string) {
if (authenticate(conn, (next) => sessions.openProjectNewSession(next, directory))) return
sessions.openProjectNewSession(conn, directory)
Expand All @@ -181,8 +206,20 @@ export function createProjectActions() {

directories(project).forEach((directory) => notification?.project.markViewed(directory))
},
hide: (conn: ServerConnection.Any, project: LocalProject) =>
global.serverCtx(ServerConnection.key(conn))?.projects.hide(project),
hide(conn: ServerConnection.Any, project: LocalProject) {
const ctx = global.serverCtx(ServerConnection.key(conn))
if (!ctx) return
ctx.projects.hide(project)
showToast({
title: language.t("sidebar.project.closed", { project: displayName(project) }),
actions: [
{
label: language.t("sidebar.project.reopen"),
onClick: () => global.serverCtx(ServerConnection.key(conn))?.projects.touch(project.worktree),
},
],
})
},
canReveal: revealProject.available,
reveal: revealProject.reveal,
}
Expand Down
21 changes: 1 addition & 20 deletions 21 packages/app/src/home/projects/controller.tsx
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
import { useDirectoryPicker } from "@/workspaces/selection/picker"
import { useServerActionsController } from "@/servers/registry/controller"
import { useSettingsCommand } from "@/settings/command"
import { useLanguage } from "@/runtime/i18n/language"
import { usePlatform } from "@/runtime/platform/platform"
import { ServerConnection } from "@/runtime/server/registry"
import { isServerFailed } from "@/runtime/server/health-machine"
import { homeProjectDirectories } from "@/shell/layout/helpers"
import { Persist, persisted } from "@/runtime/persistence/storage"
import { createResource } from "solid-js"
import { Schema } from "effect"
Expand All @@ -20,8 +17,6 @@ export const HomeServersSchema = Schema.Struct({
export function createHomeProjectsController(home: HomeController) {
const platform = usePlatform()

const pickDirectory = useDirectoryPicker()

const language = useLanguage()

const openSettings = useSettingsCommand()
Expand All @@ -38,15 +33,6 @@ export function createHomeProjectsController(home: HomeController) {
{ initialValue: _state },
)

function choose(conn: ServerConnection.Any) {
pickDirectory({
server: conn,
title: language.t("command.project.open"),
multiple: true,
onSelect: (result) => home.project.add(conn, homeProjectDirectories(result)),
})
}

return {
copy: {
language,
Expand Down Expand Up @@ -89,12 +75,7 @@ export function createHomeProjectsController(home: HomeController) {
edit: actions.edit,
hasUnread: actions.hasUnread,
clearNotifications: actions.clearNotifications,
choose: (conn: ServerConnection.Any) => {
if (actions.authenticate(conn, (next) => choose(next))) return

if (isServerFailed(home.server.health(conn))) return
choose(conn)
},
choose: (conn: ServerConnection.Any) => actions.choose(conn, home.project.add),
hide: actions.hide,
canReveal: actions.canReveal,
reveal: actions.reveal,
Expand Down
14 changes: 14 additions & 0 deletions 14 packages/app/src/home/projects/menu.tsx
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import { usePlatform } from "@/runtime/platform/platform"
import type { ServerConnection } from "@/runtime/server/registry"
import type { LocalProject } from "@/shell/state/layout"
import { fileManagerApp } from "./file-manager"
import { writeClipboard } from "@opencode/session-ui/copy"
import { showToast } from "@/shell/notifications/toast"

export function ProjectMenuItems(props: {
server: ServerConnection.Any
Expand All @@ -24,6 +26,17 @@ export function ProjectMenuItems(props: {

const platform = usePlatform()

const copyPath = () => {
const failed = () => showToast({ variant: "error", title: language.t("sidebar.project.copyPathFailed") })
void Promise.try(() =>
platform.writeClipboardText
? platform.writeClipboardText(props.project.worktree).then(() => true)
: writeClipboard(props.project.worktree),
).then((written) => {
if (!written) failed()
}, failed)
}

return (
<>
<Menu.Item onSelect={() => props.onOpenProjectNewSession(props.server, props.project.worktree)}>
Expand All @@ -40,6 +53,7 @@ export function ProjectMenuItems(props: {
<Menu.Item onSelect={() => props.onEditProject(props.server, props.project)}>
{language.t("dialog.project.edit.title")}
</Menu.Item>
<Menu.Item onSelect={copyPath}>{language.t("sidebar.project.copyPath")}</Menu.Item>
<Show when={props.canRevealProject(props.server)}>
<Menu.Item onSelect={() => props.onRevealProject(props.server, props.project)}>
{language.t(
Expand Down
5 changes: 5 additions & 0 deletions 5 packages/app/src/runtime/i18n/en.ts
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -852,6 +852,11 @@ export const dict = {
"sidebar.inbox.time.now": "now",
"sidebar.project.recentSessions": "Recent sessions",
"sidebar.project.clearNotifications": "Clear notifications",
"sidebar.project.moreOptions": "More options for project {{project}}",
"sidebar.project.closed": "Closed project {{project}}",
"sidebar.project.reopen": "Reopen",
"sidebar.project.copyPath": "Copy path",
"sidebar.project.copyPathFailed": "Failed to copy project path",

"settings.section.server": "Server",
"settings.backToApp": "Back to app",
Expand Down
11 changes: 6 additions & 5 deletions 11 packages/app/src/shell/tabs/tabs.tsx
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -526,13 +526,14 @@ export const { use: useTabs, provider: TabsProvider } = createSimpleContext({
const draftID = draft.draftID ?? uuid()
const tab = { ...draft, type: "draft" as const, draftID }
memory.ensure(tabKey(tab), "prompt", () => createDraftComposerState(draftID, { prompt, model }))
// A cold draft page can suspend past the persistence flush, so commit the tab before routing.
setStore(
produce((tabs) => {
tabs.push(tab)
}),
)
await startTransition(() => {
preview.clear()
setStore(
produce((tabs) => {
tabs.push(tab)
}),
)
navigate(draftHref(draftID))
})

Expand Down
Loading
Oops, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Loading
Oops, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

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.
You are visitor 01402809 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.