Files
fusion/packages/dashboard/app/components/WorkspaceSelector.css
gsxdsm ed4d021d3d fix(dashboard): keep mobile nav visible on Android landscape and during keyboard
- Broaden mobile media query to include (max-height: 480px) so landscape
  phones (which exceed 768 CSS px wide) still render the bottom nav and
  mobile board layout instead of desktop horizontally-scrollable columns.
- Guard useMobileKeyboard against pinch-zoom (vv.scale > 1) — Android
  Chrome ignores user-scalable=no, and a focused textarea + zoom was
  false-positiving keyboard-open and hiding MobileNavBar.
- Read documentElement.clientHeight instead of stale window.innerHeight
  when computing keyboard overlap (Android multi-window can leave
  innerHeight cached at a wildly different value than the actual layout
  viewport — observed 2848 while html was 797).
- Add interactive-widget=resizes-content to the viewport meta so Android
  Chrome shrinks the layout viewport with the soft keyboard, matching iOS.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 13:12:36 -07:00

129 lines
2.5 KiB
CSS

.workspace-selector {
position: relative;
}
.workspace-selector-trigger {
display: inline-flex;
align-items: center;
gap: 8px;
min-width: 180px;
max-width: 280px;
padding: 6px 10px;
border-radius: var(--radius-md);
border: 1px solid var(--border);
background: var(--surface);
color: var(--text);
font-size: 12px;
cursor: pointer;
}
.workspace-selector-trigger:hover {
background: var(--card-hover);
}
.workspace-selector-trigger-label {
flex: 1;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
text-align: left;
}
.workspace-selector-trigger-icon {
flex-shrink: 0;
transition: transform var(--transition-fast);
}
.workspace-selector-trigger-icon.open {
transform: rotate(180deg);
}
.workspace-selector-menu {
position: absolute;
top: calc(100% + var(--space-sm));
left: auto;
right: 0;
z-index: 20;
min-width: 300px;
max-width: min(360px, calc(100vw - var(--space-xl)));
padding: 8px;
border: 1px solid var(--border);
border-radius: var(--radius-lg);
background: var(--surface-elevated, var(--surface));
box-shadow: var(--shadow-lg);
}
.workspace-selector-group {
margin-top: 8px;
padding-top: 8px;
border-top: 1px solid var(--border);
}
.workspace-selector-group-label {
padding: 4px 8px 8px;
font-size: 11px;
font-weight: 600;
color: var(--text-muted);
text-transform: uppercase;
letter-spacing: 0.04em;
}
.workspace-selector-option {
width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
padding: 8px;
border: none;
border-radius: var(--radius-md);
background: transparent;
color: var(--text);
cursor: pointer;
text-align: left;
}
.workspace-selector-option:hover {
background: var(--card-hover);
}
.workspace-selector-option.active {
background: color-mix(in srgb, var(--todo) 12%, transparent);
}
.workspace-selector-option-main {
display: inline-flex;
align-items: center;
gap: 8px;
min-width: 0;
font-size: 12px;
font-weight: 500;
}
.workspace-selector-option-meta {
min-width: 0;
max-width: 180px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 11px;
color: var(--text-muted);
}
@media (max-width: 768px), (max-height: 480px) {
.workspace-selector-trigger {
min-width: 0;
max-width: min(56vw, 160px);
}
.workspace-selector-menu {
min-width: min(300px, calc(100vw - var(--space-xl)));
max-width: calc(100vw - var(--space-xl));
}
.workspace-selector-option-meta {
max-width: 120px;
}
}