From 640f14441787d695feb3fb6047a8fb01ea09f420 Mon Sep 17 00:00:00 2001 From: Julien Oculi Date: Tue, 2 Jul 2024 13:56:47 +0200 Subject: [PATCH] refactor: :art: deno fmt --- components/Markdown.tsx | 46 ++++++++++++++++------------------ routes/_app.tsx | 2 +- routes/imports/markdown_css.ts | 18 ++++++------- 3 files changed, 32 insertions(+), 34 deletions(-) diff --git a/components/Markdown.tsx b/components/Markdown.tsx index ada8c5a..a57e55a 100644 --- a/components/Markdown.tsx +++ b/components/Markdown.tsx @@ -3,29 +3,27 @@ import { render, RenderOptions } from 'gfm' export type MarkdownTheme = 'light' | 'dark' | 'auto' export function Markdown( - { children, theme, options }: { - children?: SignalLike | string - theme?: SignalLike | MarkdownTheme - options?: RenderOptions - }, + { children, theme, options }: { + children?: SignalLike | string + theme?: SignalLike | MarkdownTheme + options?: RenderOptions + }, ) { - return ( -
-
- ) + return ( +
+
+ ) } diff --git a/routes/_app.tsx b/routes/_app.tsx index a73fc70..9b8dec6 100644 --- a/routes/_app.tsx +++ b/routes/_app.tsx @@ -38,7 +38,7 @@ export default function App({ Component }: PageProps) { type='image/x-icon' /> - +
diff --git a/routes/imports/markdown_css.ts b/routes/imports/markdown_css.ts index 134c45b..660a34d 100644 --- a/routes/imports/markdown_css.ts +++ b/routes/imports/markdown_css.ts @@ -2,13 +2,13 @@ import { Handlers } from '$fresh/server.ts' import { CSS, KATEX_CSS } from 'gfm' export const handler: Handlers = { - GET() { - const styles = CSS + KATEX_CSS - return new Response(styles, { - headers: { - 'Content-Type': 'text/css; charset=utf-8', - // TODO add cache headers and eTag - }, - }) - }, + GET() { + const styles = CSS + KATEX_CSS + return new Response(styles, { + headers: { + 'Content-Type': 'text/css; charset=utf-8', + // TODO add cache headers and eTag + }, + }) + }, }