mirror of
https://github.com/k1tbyte/Wand-Enhancer.git
synced 2026-08-28 17:01:04 +00:00
13759b1db6
- reduce ASAR IO overhead with streamed archive reads, buffered copies, faster relative-path handling and placeholder integrity records - fix in-place app.asar.unpacked packing/extraction self-copy cases that caused locked-file failures - tighten JS patch discovery with candidate bundle filters and search hints - require prebuilt remote-panel dist artifacts and clean up embedded bridge/script packaging - add unified build entrypoints for PowerShell, cmd and bash and move native CMake output under .tmp - add release metadata validation, changelog section extraction, pre-commit hook and GitHub Actions validation/release pipelines - make CHANGELOG the source of truth for release notes and document the tag-driven release flow - add updater release notes UI with latest/full changelog loading and localize the new update strings - modularize bridge renderer scripts, add installed apps and game status sync, and support remote launch/stop commands - centralize bridge protocol, IPC and WebSocket constants and improve LAN IP selection for QR pairing - refactor remote panel controls/state enums, persist accent color, polish library/session UI and refresh assets
40 lines
1.8 KiB
TypeScript
40 lines
1.8 KiB
TypeScript
import { Icon } from '@/components/ui/icon';
|
|
|
|
import type { LibraryGame } from '../game-library';
|
|
import type { TrainerSummary } from '../protocol';
|
|
import type { EConnectionStatus } from '../state';
|
|
import { StatusPill } from './StatusPill';
|
|
|
|
type TopBarProps = {
|
|
status: EConnectionStatus;
|
|
currentGame: LibraryGame | null;
|
|
runningTrainer: TrainerSummary | null;
|
|
onOpenSettings: () => void;
|
|
};
|
|
|
|
export const TopBar = ({ status, currentGame, runningTrainer, onOpenSettings }: TopBarProps) => {
|
|
return (
|
|
<header className="remote-glass-header sticky top-0 z-20 border-b px-3.5 pb-2.5 pt-3">
|
|
<div className="flex items-center gap-2.5">
|
|
<button type="button" aria-label="Settings" className="remote-glass-control flex size-[34px] shrink-0 items-center justify-center rounded-[9px] border text-(--deck-fg-2) hover:text-(--deck-fg)" onClick={onOpenSettings}>
|
|
<Icon className="size-[18px]" name="menu" />
|
|
</button>
|
|
<div className="min-w-0 flex-1">
|
|
<div className="font-mono text-[9.5px] font-bold tracking-[0.16em] text-(--deck-fg-4)">WAND · REMOTE DECK</div>
|
|
<div className="mt-0.5 flex min-w-0 items-center gap-1.5">
|
|
<span className="min-w-0 truncate text-sm font-semibold text-(--deck-fg)">
|
|
{currentGame ? currentGame.title : 'Idle · no game'}
|
|
</span>
|
|
{currentGame && runningTrainer?.gameVersion ? (
|
|
<span className="shrink-0 rounded-[4px] bg-[color-mix(in_oklab,var(--deck-accent)_12%,transparent)] px-1.5 py-0.5 font-mono text-[9.5px] font-bold tracking-[0.06em] text-(--deck-accent)">
|
|
v{runningTrainer.gameVersion}
|
|
</span>
|
|
) : null}
|
|
</div>
|
|
</div>
|
|
<StatusPill status={status} />
|
|
</div>
|
|
</header>
|
|
);
|
|
};
|