Skip to content

Commit 10444d2

Browse files
tellahonpub1223z34hd7vtwc6qj4s7flsxkj644nlre2nthu7lrrmkumhu3xddsrx9r6w
andauthored
fix(desktop): render black static boot screen (#1570)
Signed-off-by: Taylor Ho <[email protected]> Co-authored-by: npub1223z34hd7vtwc6qj4s7flsxkj644nlre2nthu7lrrmkumhu3xddsrx9r6w <52a228d6edf316ec6812ac3c9fc0d696ab59fc7954d77e7be31eedcddf91335b@sprout-oss.stage.blox.sqprod.co>
1 parent 426f044 commit 10444d2

7 files changed

Lines changed: 114 additions & 291 deletions

File tree

‎desktop/index.html‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,19 @@
55
<link rel="icon" type="image/svg+xml" href="/buzz.svg?v=20260610" />
66
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
77
<title></title>
8+
<!--
9+
Boot background: the document must be black from its very first paint,
10+
before the app bundle (and its stylesheets) load, so cold boot never
11+
flashes white ahead of the loading gate. The window itself is also
12+
black pre-document via `backgroundColor` in tauri.conf.json. The body
13+
paints its own themed background once the app CSS loads, so this never
14+
shows through after boot.
15+
-->
16+
<style>
17+
html {
18+
background-color: #000;
19+
}
20+
</style>
821
</head>
922

1023
<body>

‎desktop/src-tauri/tauri.conf.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"height": 600,
2222
"maximized": true,
2323
"visible": false,
24+
"backgroundColor": "#000000",
2425
"titleBarStyle": "Overlay",
2526
"hiddenTitle": true,
2627
"dragDropEnabled": false,

‎desktop/src/app/App.tsx‎

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import {
1212
} from "react";
1313

1414
import { router } from "@/app/router";
15-
import { ThemeGrainientBackground } from "@/app/ThemeGrainientBackground";
1615
import { useReloadShortcut } from "@/app/useReloadShortcut";
1716
import { useAppOnboardingState } from "@/features/onboarding/hooks";
1817
import { OnboardingSlideTransition } from "@/features/onboarding/ui/OnboardingSlideTransition";
@@ -27,31 +26,26 @@ import { isSharedIdentity as isSharedIdentityCmd } from "@/shared/api/tauri";
2726
import { listenForDeepLinks } from "@/shared/deep-link";
2827
import { useSystemColorScheme } from "@/shared/theme/useSystemColorScheme";
2928
import { Button } from "@/shared/ui/button";
29+
import { BuzzMark } from "@/shared/ui/buzz-logo/BuzzMark";
3030
import { Spinner } from "@/shared/ui/spinner";
3131
import { StartupWindowDragRegion } from "@/shared/ui/StartupWindowDragRegion";
3232
import { StepProgress } from "@/shared/ui/step-progress";
3333

3434
const LOADING_TEXT = "Setting up your workspace...";
3535

36+
// Cold boot gate: a plain static Buzz mark (#D7D72E) on solid black. No
37+
// animation machinery, no gradient — the mark must paint complete on the very
38+
// first frame, even in webviews that render before scripting or SMIL start.
3639
function AppLoadingGate() {
3740
return (
3841
<div
39-
className="buzz-setup-loading-shell flex min-h-dvh flex-col items-center justify-center overflow-hidden px-6 py-10"
42+
className="flex min-h-dvh flex-col items-center justify-center overflow-hidden bg-black px-6 py-10 text-[#d7d72e]"
4043
data-testid="app-loading-gate"
4144
role="status"
4245
>
4346
<StartupWindowDragRegion />
44-
<ThemeGrainientBackground />
45-
46-
<h1
47-
aria-live="polite"
48-
className="relative z-10 mt-6 text-center text-3xl font-semibold text-foreground"
49-
>
50-
<span className="sr-only">{LOADING_TEXT}</span>
51-
<span aria-hidden="true" className="buzz-setup-loading-text">
52-
{LOADING_TEXT}
53-
</span>
54-
</h1>
47+
<span className="sr-only">{LOADING_TEXT}</span>
48+
<BuzzMark className="h-auto w-28" />
5549
</div>
5650
);
5751
}

‎desktop/src/app/ThemeGrainientBackground.tsx‎

Lines changed: 0 additions & 12 deletions
This file was deleted.

‎desktop/src/shared/styles/globals/animations.css‎

Lines changed: 0 additions & 228 deletions
Original file line numberDiff line numberDiff line change
@@ -338,234 +338,6 @@
338338
}
339339
}
340340

341-
@property --buzz-grainient-x-0 {
342-
syntax: "<percentage>";
343-
inherits: false;
344-
initial-value: 85%;
345-
}
346-
347-
@property --buzz-grainient-y-0 {
348-
syntax: "<percentage>";
349-
inherits: false;
350-
initial-value: 80%;
351-
}
352-
353-
@property --buzz-grainient-x-1 {
354-
syntax: "<percentage>";
355-
inherits: false;
356-
initial-value: 60%;
357-
}
358-
359-
@property --buzz-grainient-y-1 {
360-
syntax: "<percentage>";
361-
inherits: false;
362-
initial-value: 24%;
363-
}
364-
365-
@property --buzz-grainient-x-2 {
366-
syntax: "<percentage>";
367-
inherits: false;
368-
initial-value: 13%;
369-
}
370-
371-
@property --buzz-grainient-y-2 {
372-
syntax: "<percentage>";
373-
inherits: false;
374-
initial-value: 82%;
375-
}
376-
377-
@property --buzz-grainient-x-3 {
378-
syntax: "<percentage>";
379-
inherits: false;
380-
initial-value: 24%;
381-
}
382-
383-
@property --buzz-grainient-y-3 {
384-
syntax: "<percentage>";
385-
inherits: false;
386-
initial-value: 7%;
387-
}
388-
389-
.buzz-setup-loading-shell {
390-
--buzz-grainient-alpha-strong: 0.46;
391-
--buzz-grainient-alpha-medium: 0.34;
392-
--buzz-grainient-alpha-soft: 0.24;
393-
--buzz-setup-loading-text-color: color-mix(
394-
in srgb,
395-
hsl(var(--foreground)) 88%,
396-
hsl(var(--background)) 12%
397-
);
398-
--buzz-grainient-color-0: hsl(
399-
var(--chart-5) /
400-
var(--buzz-grainient-alpha-strong)
401-
);
402-
--buzz-grainient-color-1: hsl(
403-
var(--chart-3) /
404-
var(--buzz-grainient-alpha-strong)
405-
);
406-
--buzz-grainient-color-2: hsl(
407-
var(--primary) /
408-
var(--buzz-grainient-alpha-medium)
409-
);
410-
--buzz-grainient-color-3: hsl(
411-
var(--chart-2) /
412-
var(--buzz-grainient-alpha-strong)
413-
);
414-
background-color: hsl(var(--background));
415-
color: hsl(var(--foreground));
416-
isolation: isolate;
417-
position: relative;
418-
}
419-
420-
.dark .buzz-setup-loading-shell {
421-
--buzz-grainient-alpha-strong: 0.68;
422-
--buzz-grainient-alpha-medium: 0.5;
423-
--buzz-grainient-alpha-soft: 0.34;
424-
--buzz-setup-loading-text-color: color-mix(
425-
in srgb,
426-
hsl(var(--foreground)) 94%,
427-
hsl(var(--background)) 6%
428-
);
429-
}
430-
431-
.buzz-setup-grainient {
432-
inset: 0;
433-
overflow: hidden;
434-
pointer-events: none;
435-
position: absolute;
436-
z-index: 0;
437-
}
438-
439-
.buzz-setup-grainient__wash,
440-
.buzz-setup-grainient__veil {
441-
inset: 0;
442-
position: absolute;
443-
}
444-
445-
.buzz-setup-grainient__wash {
446-
--buzz-grainient-s-start-0: 9%;
447-
--buzz-grainient-s-end-0: 55%;
448-
--buzz-grainient-s-start-1: 5%;
449-
--buzz-grainient-s-end-1: 72%;
450-
--buzz-grainient-s-start-2: 5%;
451-
--buzz-grainient-s-end-2: 52%;
452-
--buzz-grainient-s-start-3: 13%;
453-
--buzz-grainient-s-end-3: 68%;
454-
--buzz-grainient-x-0: 85%;
455-
--buzz-grainient-y-0: 80%;
456-
--buzz-grainient-x-1: 60%;
457-
--buzz-grainient-y-1: 24%;
458-
--buzz-grainient-x-2: 13%;
459-
--buzz-grainient-y-2: 82%;
460-
--buzz-grainient-x-3: 24%;
461-
--buzz-grainient-y-3: 7%;
462-
animation: buzz-grainient-orbit 10s linear infinite alternate;
463-
background-color: hsl(var(--background));
464-
background-image:
465-
radial-gradient(
466-
circle at var(--buzz-grainient-x-0) var(--buzz-grainient-y-0),
467-
var(--buzz-grainient-color-0) var(--buzz-grainient-s-start-0),
468-
transparent var(--buzz-grainient-s-end-0)
469-
),
470-
radial-gradient(
471-
circle at var(--buzz-grainient-x-1) var(--buzz-grainient-y-1),
472-
var(--buzz-grainient-color-1) var(--buzz-grainient-s-start-1),
473-
transparent var(--buzz-grainient-s-end-1)
474-
),
475-
radial-gradient(
476-
circle at var(--buzz-grainient-x-2) var(--buzz-grainient-y-2),
477-
var(--buzz-grainient-color-2) var(--buzz-grainient-s-start-2),
478-
transparent var(--buzz-grainient-s-end-2)
479-
),
480-
radial-gradient(
481-
circle at var(--buzz-grainient-x-3) var(--buzz-grainient-y-3),
482-
var(--buzz-grainient-color-3) var(--buzz-grainient-s-start-3),
483-
transparent var(--buzz-grainient-s-end-3)
484-
);
485-
background-blend-mode: normal, normal, normal, normal;
486-
contain: paint;
487-
filter: saturate(1.08);
488-
transform: translateZ(0);
489-
will-change: transform, opacity;
490-
}
491-
492-
.buzz-setup-grainient__veil {
493-
background:
494-
radial-gradient(
495-
ellipse 74% 54% at 50% 52%,
496-
transparent 0%,
497-
hsl(var(--background) / 0.04) 72%,
498-
hsl(var(--background) / 0.16) 100%
499-
),
500-
linear-gradient(
501-
180deg,
502-
hsl(var(--background) / 0.04),
503-
hsl(var(--background) / 0.12)
504-
);
505-
}
506-
507-
.buzz-setup-loading-text {
508-
animation: buzz-setup-character-rise 700ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
509-
backface-visibility: hidden;
510-
color: var(--buzz-setup-loading-text-color);
511-
display: inline-block;
512-
opacity: 0;
513-
text-shadow:
514-
0 1px 2px hsl(var(--background) / 0.62),
515-
0 14px 34px hsl(var(--background) / 0.5);
516-
transform: translate3d(0, 32px, 0);
517-
transform-origin: 50% 55%;
518-
will-change: transform, opacity;
519-
}
520-
521-
@keyframes buzz-grainient-orbit {
522-
0% {
523-
--buzz-grainient-x-0: 85%;
524-
--buzz-grainient-y-0: 80%;
525-
--buzz-grainient-x-1: 60%;
526-
--buzz-grainient-y-1: 24%;
527-
--buzz-grainient-x-2: 13%;
528-
--buzz-grainient-y-2: 82%;
529-
--buzz-grainient-x-3: 24%;
530-
--buzz-grainient-y-3: 7%;
531-
}
532-
533-
100% {
534-
--buzz-grainient-x-0: 31%;
535-
--buzz-grainient-y-0: 94%;
536-
--buzz-grainient-x-1: 2%;
537-
--buzz-grainient-y-1: 25%;
538-
--buzz-grainient-x-2: 98%;
539-
--buzz-grainient-y-2: 20%;
540-
--buzz-grainient-x-3: 95%;
541-
--buzz-grainient-y-3: 92%;
542-
}
543-
}
544-
545-
@keyframes buzz-setup-character-rise {
546-
from {
547-
opacity: 0;
548-
transform: translate3d(0, 32px, 0);
549-
}
550-
551-
to {
552-
opacity: 1;
553-
transform: translate3d(0, 0, 0);
554-
}
555-
}
556-
557-
@media (prefers-reduced-motion: reduce) {
558-
.buzz-setup-grainient__wash {
559-
animation: none;
560-
}
561-
562-
.buzz-setup-loading-text {
563-
animation: none;
564-
opacity: 1;
565-
transform: none;
566-
}
567-
}
568-
569341
.buzz-avatar-hue-scrubber {
570342
background: linear-gradient(
571343
90deg,
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
import { useId } from "react";
2+
3+
/**
4+
* The finished Buzz mark as a plain static SVG — no SMIL, no scripting, no
5+
* animation machinery. Geometry matches the final keyframe of the
6+
* BuzzLogoAnimation morph (v8 variant), rendered in `currentColor`, so it
7+
* paints complete on the very first frame regardless of animation support.
8+
*/
9+
export function BuzzMark({ className }: { className?: string }) {
10+
const maskId = `buzz-mark-cutouts-${useId().replace(/[^a-zA-Z0-9_-]/g, "")}`;
11+
12+
return (
13+
<svg
14+
aria-hidden="true"
15+
className={["buzz-mark", className].filter(Boolean).join(" ")}
16+
viewBox="0 0 466 309"
17+
fill="currentColor"
18+
>
19+
<defs>
20+
<mask
21+
id={maskId}
22+
x="-80"
23+
y="-80"
24+
width="626"
25+
height="469"
26+
maskUnits="userSpaceOnUse"
27+
maskContentUnits="userSpaceOnUse"
28+
>
29+
<rect x="-80" y="-80" width="626" height="469" fill="#fff" />
30+
<ellipse cx="193.3" cy="84.4" rx="27" ry="27" fill="#000" />
31+
<ellipse cx="276" cy="84.4" rx="27" ry="27" fill="#000" />
32+
<rect
33+
x="166.3"
34+
y="157.2"
35+
width="136.9"
36+
height="38.3"
37+
rx="5"
38+
fill="#000"
39+
/>
40+
<rect
41+
x="166.9"
42+
y="235.1"
43+
width="136.2"
44+
height="37.6"
45+
rx="5"
46+
fill="#000"
47+
/>
48+
</mask>
49+
</defs>
50+
<g mask={`url(#${maskId})`}>
51+
<circle cx="91.7" cy="154.5" r="91.7" />
52+
<circle cx="374.3" cy="154.5" r="91.7" />
53+
<rect x="128" y="0" width="210" height="309" rx="34" />
54+
</g>
55+
</svg>
56+
);
57+
}

0 commit comments

Comments
 (0)