mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 19:04:02 +00:00
feat(voice): harden Gemini Live provider integration
This commit is contained in:
1 parent
d4492d8f8c
commit
4fde920665
102 files changed
+28528
-1581
No files matched your search
@@ -384,10 +384,17 @@
|
||||
|
||||
/* ── Toast Notification ──────────────────────── */
|
||||
#toast {
|
||||
--toast-safe-top: 74px;
|
||||
position: fixed;
|
||||
bottom: 100px;
|
||||
left: 50%;
|
||||
transform: translateX(-50%) translateY(20px);
|
||||
left: 0;
|
||||
right: 0;
|
||||
margin-inline: auto;
|
||||
width: max-content;
|
||||
max-width: calc(100vw - 32px);
|
||||
box-sizing: border-box;
|
||||
overflow-wrap: anywhere;
|
||||
transform: translateY(20px);
|
||||
z-index: 200;
|
||||
padding: 10px 24px;
|
||||
background: var(--glass-bg);
|
||||
@@ -413,5 +420,41 @@
|
||||
#toast.visible {
|
||||
opacity: 1;
|
||||
visibility: visible;
|
||||
transform: translateX(-50%) translateY(0);
|
||||
transform: translateY(0);
|
||||
}
|
||||
|
||||
/* Keep transient feedback clear of the raised voice chooser and bottom dock. */
|
||||
body:has(#gev-voice-control:hover) #toast,
|
||||
body:has(#gev-voice-control:focus-within) #toast,
|
||||
body:has(#command-dock.dock-has-pinned-tray) #toast {
|
||||
top: calc(env(safe-area-inset-top, 0px) + var(--toast-safe-top));
|
||||
bottom: auto;
|
||||
transform: translateY(-20px);
|
||||
}
|
||||
|
||||
body:has(#gev-voice-control:hover) #toast.visible,
|
||||
body:has(#gev-voice-control:focus-within) #toast.visible,
|
||||
body:has(#command-dock.dock-has-pinned-tray) #toast.visible {
|
||||
transform: translateY(0);
|
||||
}
|
||||
|
||||
@media (max-width: 900px), (max-height: 640px) {
|
||||
#toast {
|
||||
top: calc(env(safe-area-inset-top, 0px) + var(--toast-safe-top));
|
||||
bottom: auto;
|
||||
letter-spacing: 1px;
|
||||
transform: translateY(-20px);
|
||||
}
|
||||
|
||||
#toast.visible {
|
||||
transform: translateY(0);
|
||||
}
|
||||
}
|
||||
|
||||
/* On a narrow portrait viewport the collapsed layer and scene headers occupy
|
||||
the first two rows. Keep feedback below them, clear of the voice controls. */
|
||||
@media (max-width: 600px) and (orientation: portrait) {
|
||||
#toast {
|
||||
--toast-safe-top: 214px;
|
||||
}
|
||||
}
|
||||
@@ -82,3 +82,88 @@
|
||||
.gev-voice-cost-value[hidden] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#command-dock #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: 0px;
|
||||
}
|
||||
|
||||
/* Provider choice belongs to the existing voice control, not a separate panel. */
|
||||
.gev-voice-provider-field {
|
||||
position: absolute;
|
||||
bottom: calc(100% + var(--gev-provider-lift, 0px));
|
||||
z-index: 9;
|
||||
left: 0;
|
||||
right: 0;
|
||||
display: grid;
|
||||
gap: 4px;
|
||||
padding: 8px 6px;
|
||||
border: 1px solid var(--glass-border);
|
||||
border-radius: 8px;
|
||||
background: var(--bg-panel, #09121b);
|
||||
color: var(--text-secondary);
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.5rem;
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
}
|
||||
.gev-voice-provider-field[hidden] {
|
||||
display: none;
|
||||
}
|
||||
.gev-voice-provider-field select {
|
||||
min-width: 0;
|
||||
width: 100%;
|
||||
min-height: 30px;
|
||||
color: var(--text-primary);
|
||||
background: #09121b;
|
||||
border: 1px solid var(--glass-border);
|
||||
border-radius: 4px;
|
||||
font: inherit;
|
||||
font-size: 0.65rem;
|
||||
}
|
||||
#gev-voice-control:hover .gev-voice-provider-field,
|
||||
#gev-voice-control:focus-within .gev-voice-provider-field {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
}
|
||||
#command-dock #gev-voice-control[data-provider] .gev-voice-help-tray,
|
||||
#command-dock #gev-voice-control[data-provider] .gev-voice-card,
|
||||
#command-dock #gev-voice-control[data-provider] .gev-voice-error-tray {
|
||||
bottom: calc(100% + 4.8rem + var(--gev-provider-lift));
|
||||
}
|
||||
#command-dock.dock-has-pinned-tray #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: calc(1.7rem + var(--dock-pinned-stack-height));
|
||||
}
|
||||
/* Pinned trays separate the chooser from its hover owner. Keep it reachable
|
||||
across that gap without requiring keyboard focus to hold it open. */
|
||||
#command-dock.dock-has-pinned-tray .gev-voice-provider-field {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
}
|
||||
@media (max-width: 900px) {
|
||||
/* The attribution clearance also creates a gap for mouse users in a
|
||||
narrow window, so the raised chooser must not depend on root hover. */
|
||||
.gev-voice-provider-field {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
}
|
||||
#command-dock #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: 3rem;
|
||||
}
|
||||
#command-dock.dock-has-pinned-tray #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: calc(3.5rem + var(--dock-pinned-stack-height));
|
||||
}
|
||||
}
|
||||
@media (max-width: 720px) {
|
||||
#command-dock #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: calc(2vh + 2.5rem);
|
||||
}
|
||||
#command-dock.dock-has-pinned-tray #gev-voice-control[data-provider] {
|
||||
--gev-provider-lift: calc(2vh + 3rem + var(--dock-pinned-stack-height));
|
||||
}
|
||||
}
|
||||
@media (hover: none) {
|
||||
.gev-voice-provider-field {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user