- Move the Tauri app (React frontend + Rust backend) into desktop/ via git mv — configs unchanged (relative paths: tauri.conf.json, vite.config.ts) - Root package.json becomes a private bun workspace container with orchestration scripts; desktop package renamed gridline-desktop - Scaffold www/ with Astro 7 + Tailwind v4 (hand-wired vite plugin, static output, ready for Dokploy) - Update release.yml for the new layout: projectPath: desktop, desktop/src-tauri resource paths, rust-cache workspace path - Update README + AGENTS.md structure trees and dev commands - Verified: vitest (1074), cargo test (354), desktop build, tauri dev (window launches), tauri build (dmg + app bundles), Astro build
9 lines
522 B
TypeScript
9 lines
522 B
TypeScript
/** True only on macOS (the macOS "Overlay" drag strip is gated on this). Uses
|
|
* navigator.platform/userAgent (the established pattern in BackupPage.tsx);
|
|
* @tauri-apps/plugin-os is not installed and getCurrentWindow() has no osLabel(). */
|
|
export function isMacOS(): boolean {
|
|
if (typeof navigator === "undefined") return false;
|
|
const p = (navigator.platform || "").toLowerCase();
|
|
const u = (navigator.userAgent || "").toLowerCase();
|
|
return p.includes("mac") || u.includes("macintosh") || u.includes("mac os");
|
|
} |