Skip to content

Commit 1da0194

Browse files
Day 8: Splash screen + license gate flow
Rust IPC commands: LicenseResult, ExaminerProfile, DriveInfo structs check_license() → returns dev pro license result (replaces stub) activate_license(key) → accepts STRATA-* keys, returns Pro tier; rejects others with "Invalid license key format" error start_trial() → returns Trial tier with 30 days get_examiner_profile() → returns empty profile (replaces stub) save_examiner_profile(profile) → console-prints saved name list_drives() → 2 mock drives: Macintosh HD (system, blocked) + Wolfmark Systems Backup (931 GB external, permitted) select_evidence_drive(id) → returns evidence path TypeScript IPC: Mirrored types and 7 functions (checkLicense, activateLicense, startTrial, getExaminerProfile, saveExaminerProfile, listDrives, selectEvidenceDrive). All wired with IN_TAURI fallbacks so the full flow works in Vite preview. Store additions: AppGate type ('splash' | 'examiner' | 'drive' | 'main') gate (default 'splash'), licenseResult, examinerProfile, selectedDriveId, evidencePath, isDevMode (default true) setGate, setLicenseResult, setExaminerProfile (also updates examinerName), setSelectedDrive Shared gate components: GateBackground — full-screen radial-gradient wrapper ChevronMark — extracted reusable SVG (Day 7's About-tab chevron) DevSkip — bottom-left amber-bordered DEV SKIP button SplashScreen (production): Full-screen with radial gradient. Chevron 100x88, STRATA 52px wordmark, tagline, version line. Animated entrance via gateFadeUp + gateFade keyframes (CSS animations: chevron up, then text rows staggered 200/400/500/700/800ms). Centered divider gradient. License key input (44px, monospace, validates) with error state border. Start Trial button (white gradient, primary). Activate License button switches style when key is typed. Footer copyright. DEV SKIP advances to examiner gate. ExaminerSetup: 480px card on gradient background. ID-card icon, title, subtitle. 4 form fields (Name/Agency/Badge required, Email optional) with inline validation, red borders + error text on submit. Continue button validates then saves profile + advances to drive gate. Back link returns to splash. DEV SKIP fills dev values + advances. DriveSelection: 520px card. Floppy icon, title, 2-line warning. Loads drives via listDrives on mount. Each drive row: monitor/disc icon, name + free/total GB, monospace mount path, red warning text + ✗ for not-permitted, ✓ for selected. System drive non-clickable + greyed out. Hover state for permitted drives. Refresh button. Evidence path preview when drive selected. Begin Examination button disabled until selection. Back link returns to examiner. DEV SKIP picks Wolfmark drive + advances to main. App.tsx: Added gate routing — splash/examiner/drive return their respective components, main returns the existing layout. TopBar: LicenseBadge component with Pro/Trial/None variants. Case name now shows "{shortName} · {caseName}" when examiner profile is set. shortName turns "Dev Examiner" → "D. Examiner". CSS animations: Added @Keyframes gateFade and gateFadeUp to index.css for the splash screen entrance. Verified in browser preview: - Splash renders with chevron, STRATA wordmark, license card, DEV SKIP visible - DEV SKIP → Examiner Setup with 4 fields, ID icon, primary button - DEV SKIP → Drive Selection with 2 drives (1 blocked, 1 selectable) - Click Wolfmark drive → blue selection + ✓, evidence path preview, Begin Examination button activates - Click Begin Examination → Main workspace with case name "D. Examiner · Unsaved Session" - Zero console errors Builds: npm run build: 316 KB JS, 7.15 KB CSS, 52 modules — clean cargo check: clean cargo tauri build --no-bundle: 8.8 MB binary Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent e6664c1 commit 1da0194

43 files changed

Lines changed: 4055 additions & 873 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/tauri-build.yml

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
name: Build Strata Desktop (Tauri)
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
workflow_dispatch:
8+
9+
jobs:
10+
build-tauri:
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
include:
15+
- platform: macos-latest
16+
args: '--target aarch64-apple-darwin'
17+
rust-targets: 'aarch64-apple-darwin'
18+
- platform: macos-latest
19+
args: '--target x86_64-apple-darwin'
20+
rust-targets: 'x86_64-apple-darwin'
21+
- platform: ubuntu-22.04
22+
args: ''
23+
rust-targets: ''
24+
- platform: windows-latest
25+
args: ''
26+
rust-targets: ''
27+
28+
runs-on: ${{ matrix.platform }}
29+
30+
steps:
31+
- name: Checkout
32+
uses: actions/checkout@v4
33+
34+
- name: Setup Node
35+
uses: actions/setup-node@v4
36+
with:
37+
node-version: 22
38+
39+
- name: Install Rust
40+
uses: dtolnay/rust-toolchain@stable
41+
with:
42+
targets: ${{ matrix.rust-targets }}
43+
44+
- name: Install Linux dependencies
45+
if: matrix.platform == 'ubuntu-22.04'
46+
run: |
47+
sudo apt-get update
48+
sudo apt-get install -y \
49+
libwebkit2gtk-4.1-dev \
50+
libappindicator3-dev \
51+
librsvg2-dev \
52+
patchelf \
53+
libssl-dev \
54+
build-essential \
55+
curl \
56+
wget \
57+
file \
58+
libgtk-3-dev \
59+
libayatana-appindicator3-dev
60+
61+
- name: Install frontend dependencies
62+
working-directory: apps/strata-ui
63+
run: npm install
64+
65+
- name: Build Tauri app
66+
uses: tauri-apps/tauri-action@v0
67+
with:
68+
projectPath: apps/strata-desktop/src-tauri
69+
args: ${{ matrix.args }}
70+
env:
71+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
72+
73+
- name: Upload build artifacts
74+
uses: actions/upload-artifact@v4
75+
with:
76+
name: strata-${{ matrix.platform }}-${{ matrix.rust-targets || 'default' }}
77+
path: |
78+
apps/strata-desktop/src-tauri/target/release/bundle/
79+
apps/strata-desktop/src-tauri/target/*/release/bundle/
80+
if-no-files-found: warn

0 commit comments

Comments
 (0)