authorgravatar for 91240327+shivamhwp@users.noreply.github.comshivam <91240327+shivamhwp@users.noreply.github.com> 2026-05-01 04:03:06+05:30
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-04-30 15:33:06-07:00
logf54f4385e518504f87001afef51bdf3b0be2a5be
tree6a14ec3ccd8ec07a39f6b7400ceadcff3d65825c
parente25ce07cc2501e317be78ff2690569734c224b0e
signature Signed by PGP key B5690EEEBB952194

Narrow the right sidebar and update task panel and diff panel (#2409)


3 files changed, 11 insertions(+), 9 deletions(-)

apps/web/src/components/settings/SettingsPanels.tsx+5-5
......@@ -434,7 +434,7 @@ export function useSettingsRestore(onRestored?: () => void) {
434434 ? ["Diff line wrapping"]
435435 : []),
436436 ...(settings.autoOpenPlanSidebar !== DEFAULT_UNIFIED_SETTINGS.autoOpenPlanSidebar
437 ? ["Task sidebar"]
437 ? ["Auto-open task panel"]
438438 : []),
439439 ...(settings.enableAssistantStreaming !== DEFAULT_UNIFIED_SETTINGS.enableAssistantStreaming
440440 ? ["Assistant output"]
......@@ -964,12 +964,12 @@ export function GeneralSettingsPanel() {
964964 />
965965
966966 <SettingsRow
967 title="Task sidebar"
968 description="Open the plan and task sidebar automatically when steps appear."
967 title="Auto-open task panel"
968 description="Open the right-side plan and task panel automatically when steps appear."
969969 resetAction={
970970 settings.autoOpenPlanSidebar !== DEFAULT_UNIFIED_SETTINGS.autoOpenPlanSidebar ? (
971971 <SettingResetButton
972 label="task sidebar"
972 label="auto-open task panel"
973973 onClick={() =>
974974 updateSettings({
975975 autoOpenPlanSidebar: DEFAULT_UNIFIED_SETTINGS.autoOpenPlanSidebar,
......@@ -984,7 +984,7 @@ export function GeneralSettingsPanel() {
984984 onCheckedChange={(checked) =>
985985 updateSettings({ autoOpenPlanSidebar: Boolean(checked) })
986986 }
987 aria-label="Open the task sidebar automatically"
987 aria-label="Open the task panel automatically"
988988 />
989989 }
990990 />
apps/web/src/rightPanelLayout.ts+2-2
......@@ -1,3 +1,3 @@
1export const RIGHT_PANEL_INLINE_LAYOUT_MEDIA_QUERY = "(max-width: 1180px)";
1export const RIGHT_PANEL_INLINE_LAYOUT_MEDIA_QUERY = "(max-width: 980px)";
22export const RIGHT_PANEL_SHEET_CLASS_NAME =
3 "w-[min(88vw,820px)] max-w-[820px] p-0 wco:mt-[env(titlebar-area-height)] wco:h-[calc(100%-env(titlebar-area-height))] wco:max-h-[calc(100%-env(titlebar-area-height))]";
3 "w-[min(42vw,28rem)] min-w-80 max-w-[28rem] p-0 max-[760px]:w-[min(88vw,24rem)] max-[760px]:min-w-0 wco:mt-[env(titlebar-area-height)] wco:h-[calc(100%-env(titlebar-area-height))] wco:max-h-[calc(100%-env(titlebar-area-height))]";
apps/web/src/routes/_chat.$environmentId.$threadId.tsx+4-2
......@@ -26,8 +26,9 @@ import { Sidebar, SidebarInset, SidebarProvider, SidebarRail } from "~/component
2626
2727const DiffPanel = lazy(() => import("../components/DiffPanel"));
2828const DIFF_INLINE_SIDEBAR_WIDTH_STORAGE_KEY = "chat_diff_sidebar_width";
29const DIFF_INLINE_DEFAULT_WIDTH = "clamp(28rem,48vw,44rem)";
30const DIFF_INLINE_SIDEBAR_MIN_WIDTH = 26 * 16;
29const DIFF_INLINE_DEFAULT_WIDTH = "clamp(24rem,34vw,36rem)";
30const DIFF_INLINE_SIDEBAR_MIN_WIDTH = 22 * 16;
31const DIFF_INLINE_SIDEBAR_MAX_WIDTH = 36 * 16;
3132const COMPOSER_COMPACT_MIN_LEFT_CONTROLS_WIDTH_PX = 208;
3233
3334const DiffLoadingFallback = (props: { mode: DiffPanelMode }) => {
......@@ -124,6 +125,7 @@ const DiffPanelInlineSidebar = (props: {
124125 collapsible="offcanvas"
125126 className="border-l border-border bg-card text-foreground"
126127 resizable={{
128 maxWidth: DIFF_INLINE_SIDEBAR_MAX_WIDTH,
127129 minWidth: DIFF_INLINE_SIDEBAR_MIN_WIDTH,
128130 shouldAcceptWidth: shouldAcceptInlineSidebarWidth,
129131 storageKey: DIFF_INLINE_SIDEBAR_WIDTH_STORAGE_KEY,