From 93a11ddedf697c9b673dd59628cee3db48ac67d0 Mon Sep 17 00:00:00 2001
From: Israel Araújo de Oliveira <israelaraujodeoliveira@gmail.com>
Date: Mon, 9 Feb 2026 06:00:35 -0300
Subject: feat(desktop): add native Wayland toggle on Linux (#11971)

Co-authored-by: Brendan Allan <git@brendonovich.dev>
---
 packages/app/src/context/platform.tsx | 8 ++++++++
 1 file changed, 8 insertions(+)

(limited to 'packages/app/src/context/platform.tsx')

diff --git a/packages/app/src/context/platform.tsx b/packages/app/src/context/platform.tsx
index 3fca502ba..7aa6c6554 100644
--- a/packages/app/src/context/platform.tsx
+++ b/packages/app/src/context/platform.tsx
@@ -57,6 +57,12 @@ export type Platform = {
   /** Set the default server URL to use on app startup (platform-specific) */
   setDefaultServerUrl?(url: string | null): Promise<void> | void
 
+  /** Get the preferred display backend (desktop only) */
+  getDisplayBackend?(): Promise<DisplayBackend | null> | DisplayBackend | null
+
+  /** Set the preferred display backend (desktop only) */
+  setDisplayBackend?(backend: DisplayBackend): Promise<void>
+
   /** Parse markdown to HTML using native parser (desktop only, returns unprocessed code blocks) */
   parseMarkdown?(markdown: string): Promise<string>
 
@@ -70,6 +76,8 @@ export type Platform = {
   readClipboardImage?(): Promise<File | null>
 }
 
+export type DisplayBackend = "auto" | "wayland"
+
 export const { use: usePlatform, provider: PlatformProvider } = createSimpleContext({
   name: "Platform",
   init: (props: { value: Platform }) => {
-- 
cgit v1.2.3

