File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import { FileRoutes } from "@solidjs/start/router"
33import { Font } from "@opencode-ai/ui/font"
44import { MetaProvider } from "@solidjs/meta"
55import { MarkedProvider } from "@opencode-ai/ui/context/marked"
6+ import { DialogProvider } from "@opencode-ai/ui/context/dialog"
67import { Suspense } from "solid-js"
78import "./app.css"
89import { Favicon } from "@opencode-ai/ui/favicon"
@@ -12,11 +13,13 @@ export default function App() {
1213 < Router
1314 root = { ( props ) => (
1415 < MetaProvider >
15- < MarkedProvider >
16- < Favicon />
17- < Font />
18- < Suspense > { props . children } </ Suspense >
19- </ MarkedProvider >
16+ < DialogProvider >
17+ < MarkedProvider >
18+ < Favicon />
19+ < Font />
20+ < Suspense > { props . children } </ Suspense >
21+ </ MarkedProvider >
22+ </ DialogProvider >
2023 </ MetaProvider >
2124 ) }
2225 >
Original file line number Diff line number Diff line change @@ -162,11 +162,20 @@ export default function () {
162162
163163 return (
164164 < ErrorBoundary
165- fallback = { ( e ) => {
165+ fallback = { ( error ) => {
166+ if ( SessionDataMissingError . isInstance ( error ) ) {
167+ return < NotFound />
168+ }
169+ console . error ( error )
170+ const details = error instanceof Error ? ( error . stack ?? error . message ) : String ( error )
166171 return (
167- < Show when = { e . message === "SessionDataMissingError" } >
168- < NotFound />
169- </ Show >
172+ < div class = "min-h-screen w-full bg-background-base text-text-base flex flex-col items-center justify-center gap-4 p-6 text-center" >
173+ < p class = "text-16-medium" > Unable to render this share.</ p >
174+ < p class = "text-14-regular text-text-weaker" > Check the console for more details.</ p >
175+ < pre class = "text-12-mono text-left whitespace-pre-wrap break-words w-full max-w-200 bg-background-stronger rounded-md p-4" >
176+ { details }
177+ </ pre >
178+ </ div >
170179 )
171180 } }
172181 >
You can’t perform that action at this time.
0 commit comments