feat: harden local shell, SFTP, and desktop session reliability

Finder-launched terminals now inherit a login PATH so tools like ollama resolve, destructive SFTP/editor actions require confirmation, and terminal search plus window dragging work again. SSH forwards and RDP sessions keep listeners and survive reconnect without FastPath crashes.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Logan.LiandCursor committed 2026-08-16 16:08:11 +08:00
1 parent 188f3556ed
commit 08696896f9
223 files changed
+13493 -3423

No files matched your search

+68 -14
View File
@@ -81,22 +81,32 @@
--hairline: rgba(148, 163, 184, 0.10);
--hairline-strong: rgba(148, 163, 184, 0.16);
/* Accent */
/* Accent (+ RGB channels for Tailwind opacity modifiers) */
--color-accent-blue: #3b82f6;
--color-accent-blue-rgb: 59 130 246;
--color-accent-blue-hover: #60a5fa;
--color-accent-blue-hover-rgb: 96 165 250;
--color-accent-green: #10b981;
--color-accent-green-rgb: 16 185 129;
--color-accent-purple: #8b5cf6;
--color-accent-purple-rgb: 139 92 246;
--color-accent-orange: #f97316;
--color-accent-orange-rgb: 249 115 22;
--color-accent-red: #ef4444;
--color-accent-red-rgb: 239 68 68;
/* Feedback */
/* Feedback (+ RGB for Tailwind opacity) */
--color-feedback-success: #10b981;
--color-feedback-success-rgb: 16 185 129;
--color-feedback-success-bg: #064e3b;
--color-feedback-warning: #f59e0b;
--color-feedback-warning-rgb: 245 158 11;
--color-feedback-warning-bg: #78350f;
--color-feedback-error: #ef4444;
--color-feedback-error-rgb: 239 68 68;
--color-feedback-error-bg: #7f1d1d;
--color-feedback-info: #3b82f6;
--color-feedback-info-rgb: 59 130 246;
--color-feedback-info-bg: #1e3a5f;
/* Placeholder */
@@ -119,7 +129,7 @@
box-sizing: border-box;
}
/* Light theme hairlines (useTheme also sets these via tokens) */
/* Light theme hairlines + chrome tweaks (useTheme also sets tokens) */
[data-theme='light'] {
--color-border: rgba(15, 23, 42, 0.06);
--color-border-subtle: rgba(15, 23, 42, 0.04);
@@ -128,6 +138,16 @@
--hairline-soft: rgba(15, 23, 42, 0.05);
--hairline: rgba(15, 23, 42, 0.08);
--hairline-strong: rgba(15, 23, 42, 0.12);
/* Terminal chrome stays dark regardless of UI theme */
--color-terminal-bg: #0f172a;
}
[data-theme='light'] .ui-nav-item-active {
box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}
[data-theme='light'] .ui-select-pill {
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}
/*
@@ -224,6 +244,14 @@ html, body {
app-region: no-drag;
}
/* SFTP cross-pane pointer drag — block native text selection while dragging files */
body.sftp-pointer-dragging,
body.sftp-pointer-dragging * {
-webkit-user-select: none !important;
user-select: none !important;
cursor: grabbing !important;
}
/* Buttons/inputs inside drag regions stay clickable */
.titlebar-drag button,
.titlebar-drag a,
@@ -257,13 +285,14 @@ html, body {
background: var(--color-scrollbar-thumb-h);
}
/* Terminal styles */
.terminal-container {
/* Terminal styles — always dark canvas (independent of UI light/dark) */
.terminal-container,
.terminal-surface {
background-color: var(--color-terminal-bg);
padding: 8px;
border-radius: 4px;
height: 100%;
overflow: auto;
}
.terminal-overlay-scrim {
background-color: color-mix(in srgb, var(--color-terminal-bg) 92%, transparent);
}
/* XTerm.js styles */
@@ -482,8 +511,8 @@ button {
align-items: center;
justify-content: center;
flex-shrink: 0;
background-color: rgba(59, 130, 246, 0.12);
border: 1px solid rgba(59, 130, 246, 0.2);
background-color: color-mix(in srgb, var(--color-accent-blue) 12%, transparent);
border: 1px solid color-mix(in srgb, var(--color-accent-blue) 22%, transparent);
color: var(--color-accent-blue);
}
@@ -519,9 +548,9 @@ button {
}
.ui-nav-item-active {
background-color: rgba(59, 130, 246, 0.12);
background-color: color-mix(in srgb, var(--color-accent-blue) 12%, transparent);
color: var(--color-content-primary);
border-color: rgba(59, 130, 246, 0.25);
border-color: color-mix(in srgb, var(--color-accent-blue) 28%, transparent);
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
@@ -539,7 +568,7 @@ button {
.launcher-card:hover,
.launcher-row:hover {
border-color: rgba(59, 130, 246, 0.45);
border-color: color-mix(in srgb, var(--color-accent-blue) 45%, transparent);
background: var(--color-surface-overlay);
}
@@ -620,3 +649,28 @@ button {
background-size: 200% 100%;
animation: shimmer 1.5s ease-in-out infinite;
}
/* SFTP dual-pane: drop trailing meta first so ordinary names stay readable */
.sftp-file-panel {
container-type: inline-size;
container-name: sftp-panel;
}
.sftp-file-panel .sftp-col-name {
flex: 1 1 auto;
min-width: 8rem;
}
@container sftp-panel (max-width: 480px) {
.sftp-col-type {
display: none;
}
}
@container sftp-panel (max-width: 400px) {
.sftp-col-size {
display: none;
}
}
@container sftp-panel (max-width: 320px) {
.sftp-col-modified {
display: none;
}
}