Compare commits

...

1 Commits

Author SHA1 Message Date
76b64716c2 fix: home md not shown 2024-12-10 13:25:17 +00:00
3 changed files with 50 additions and 7 deletions

View File

@@ -13,7 +13,6 @@ import {useHomeMarkdown} from "./utils/markdown-queries";
const App = () => {
const {home, isLoading, error} = useHomeMarkdown();
return (
<Router>
<div className="app-container">
@@ -24,12 +23,9 @@ const App = () => {
<Routes>
<Route
path="/"
element={
(home && home.id)
? <Navigate to = {`/markdown/${home.id}`}/>
: <p>HOME</p>
}
element={<Navigate to = "/markdown/1"/>}
/>
<Route path="/testx" element={<h2>test2</h2>}/>
<Route path="/markdown/:id" element={<MarkdownContent />} />
<Route path="/callback" element={<Callback />} />
<Route path="/test" element={<h1>TEST</h1>}></Route>

View File

@@ -32,6 +32,7 @@ const Footer = () => {
<a href="https://git.hangman-lab.top/hzhang/HangmanLab">git</a>
&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;
v0.0.6
</span>
)}</p>
{

View File

@@ -46,4 +46,50 @@ pre {
.markdown-preview li {
margin-bottom: 0.5rem;
}
}
.markdown-preview h1 {
font-size: 2em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #333;
}
.markdown-preview h2 {
font-size: 1.75em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #444;
}
.markdown-preview h3 {
font-size: 1.5em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #555;
}
.markdown-preview h4 {
font-size: 1.25em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #666;
}
.markdown-preview h5 {
font-size: 1.1em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #777;
}
.markdown-preview h6 {
font-size: 1em;
font-weight: bold;
margin-bottom: 0.5rem;
color: #888;
}