( state: ThemeModeState, osScheme: "dark" | "light", )
| 117 | }; |
| 118 | |
| 119 | export const switchToSingle = ( |
| 120 | state: ThemeModeState, |
| 121 | osScheme: "dark" | "light", |
| 122 | ): SingleState => { |
| 123 | if (state.mode === "single") { |
| 124 | return state; |
| 125 | } |
| 126 | return { |
| 127 | mode: "single", |
| 128 | theme: osScheme === "dark" ? state.dark : state.light, |
| 129 | }; |
| 130 | }; |
| 131 | |
| 132 | /** |
| 133 | * Flat request shape sent to the backend. Kept in sync with |
no outgoing calls
no test coverage detected