Skip to content

An open-source, self-hosted system for apps built with web technologies.

Remove blur from Program loading

zohayrslileh30e4b17ad04f
diff --git a/source/client/view/components/loading.tsx b/source/client/view/components/loading.tsx
index 0083991..a242f61 100644
--- a/source/client/view/components/loading.tsx
+++ b/source/client/view/components/loading.tsx
@@ -1,15 +1,23 @@
import { type ComponentProps } from "react"
import Spinner from "./spinner"
+const loadingBackground = "bg-white/10"
+
/** The shared treatment for content obscured by an unresolved system state. */
-export const obscuredBackground = "bg-white/10 backdrop-blur-md"
+export const obscuredBackground = `${loadingBackground} backdrop-blur-md`
+
+interface LoadingProps extends ComponentProps<"div"> {
+
+ /** Whether content behind the loading layer is blurred. */
+ blur?: boolean
+}
-/** A loading surface that keeps the content behind it softly obscured. */
-export default function ({ className, ...props }: ComponentProps<"div">) {
+/** A loading surface that obscures unresolved content, with blur by default. */
+export default function ({ blur = true, className, ...props }: LoadingProps) {
return <div
- className={`absolute inset-0 z-10 grid rounded-[inherit] ${obscuredBackground} ${className ?? ""}`}
+ className={`absolute inset-0 z-10 grid rounded-[inherit] ${blur ? obscuredBackground : loadingBackground} ${className ?? ""}`}
{...props}
diff --git a/source/client/view/desktop/window-manager/process-window.tsx b/source/client/view/desktop/window-manager/process-window.tsx
index 6aeca47..97da959 100644
--- a/source/client/view/desktop/window-manager/process-window.tsx
+++ b/source/client/view/desktop/window-manager/process-window.tsx
@@ -156,7 +156,13 @@ export default memo(function ({ identity, record, client, title, icon, position,
{/* Bare layers are only the Program's content. Loading is system paint,
so it belongs exclusively to an ordinary window. */}
- {!bare && loadingVisible && <Loading className={!closing && loading.source === frameSource && loading.phase === "leaving" ? "pointer-events-none opacity-0 transition-opacity duration-200 ease-out" : ""} />}
+ {!bare && loadingVisible && <Loading
+
+ blur={false}
+
+ className={!closing && loading.source === frameSource && loading.phase === "leaving" ? "pointer-events-none opacity-0 transition-opacity duration-200 ease-out" : ""}
+
+ />}
{/* First press focuses an inactive window before its program can
receive input. Bare layers have no system click-catcher. */}