New formatting

This commit is contained in:
2023-10-19 16:50:21 -04:00
parent 0b5e82bfcc
commit 026d1ca06d
30 changed files with 76 additions and 76 deletions

View File

@ -15,5 +15,5 @@ export interface ClientStyleContextData {
}
export const ClientStyleContext = createContext<ClientStyleContextData | null>(
null
null,
);

View File

@ -34,5 +34,5 @@ hydrateRoot(
<ClientCacheProvider>
<RemixBrowser />
</ClientCacheProvider>
</StrictMode>
</StrictMode>,
);

View File

@ -10,7 +10,7 @@ export default function handleRequest(
request: Request,
responseStatusCode: number,
responseHeaders: Headers,
remixContext: EntryContext
remixContext: EntryContext,
) {
const cache = createEmotionCache();
const { extractCriticalToChunks } = createEmotionServer(cache);
@ -19,7 +19,7 @@ export default function handleRequest(
<CacheProvider value={cache}>
<RemixServer context={remixContext} url={request.url} />
</CacheProvider>
</ServerStyleContext.Provider>
</ServerStyleContext.Provider>,
);
const chunks = extractCriticalToChunks(html);
@ -29,7 +29,7 @@ export default function handleRequest(
<CacheProvider value={cache}>
<RemixServer context={remixContext} url={request.url} />
</CacheProvider>
</ServerStyleContext.Provider>
</ServerStyleContext.Provider>,
);
responseHeaders.set("content-type", "text/html;charset=utf-8");

View File

@ -46,7 +46,7 @@ export function ErrorBoundary() {
<Link color="#646cff" onClick={() => location.reload()}>
Refresh
</Link>
</Container>
</Container>,
);
const { status } = error;
@ -74,7 +74,7 @@ export function ErrorBoundary() {
<Link color="#646cff" onClick={() => history.go(-1)}>
Go back
</Link>
</Container>
</Container>,
);
default:
@ -90,7 +90,7 @@ export function ErrorBoundary() {
<Link color="#646cff" onClick={() => location.reload()}>
Reload
</Link>
</Container>
</Container>,
);
}
}
@ -124,7 +124,7 @@ export function meta() {
function getMarkup(
loaderData: { [k: string]: any },
child: ReactNode
child: ReactNode,
): JSX.Element {
const Document = withEmotionCache(
({ children }: { children: ReactNode }, emotionCache) => {
@ -149,7 +149,7 @@ function getMarkup(
colorModeManager={cookieStorageManagerSSR(
typeof document === "undefined"
? `chakra-ui-color-mode=${loaderData.theme}`
: document.cookie
: document.cookie,
)}
theme={theme}
>
@ -199,7 +199,7 @@ function getMarkup(
</body>
</html>
);
}
},
);
return <Document>{child}</Document>;

View File

@ -44,7 +44,7 @@ export async function loader({ context }: { context: RequestContext }) {
await dataKV.list({
prefix: `appeal_${currentUser.id}`,
})
).keys.length
).keys.length,
),
can_toggle:
currentUser.permissions & (1 << 0) || currentUser.permissions & (1 << 11),