Skip to content

Commit

Permalink
one more
Browse files Browse the repository at this point in the history
  • Loading branch information
nasubi916 committed Apr 7, 2024
1 parent f63d52f commit 0fa8139
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 88 deletions.
75 changes: 0 additions & 75 deletions articles/uploaded/test.md

This file was deleted.

20 changes: 20 additions & 0 deletions src/components/Article.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import { type ReactElement } from "react";
import { styled as p } from "@panda/jsx";
import "./Layout.css";
import Test from "../../blogs/articles/uploaded/2.md";

/** @type {import('mdx/types.js').MDXComponents} */
const components = {
em(properties: any) {
return <i {...properties} />;
},
};
export default function Article(): ReactElement {
return (
<p.div w="full">
<div className="markdown-body">
<Test components={components} />
</div>
</p.div>
);
}
File renamed without changes.
15 changes: 2 additions & 13 deletions src/pages/blogs/+Page.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@
import { type ReactElement } from "react";
import { styled as p } from "@panda/jsx";
import "./Layout.css"
import Test from "../../../articles/uploaded/test.md";
import Article from "@/components/Article";

/** @type {import('mdx/types.js').MDXComponents} */
const components = {
em(properties: any) {
return <i {...properties} />;
},
};
export default function Blogs(): ReactElement {
return (
<p.div
Expand All @@ -18,11 +11,7 @@ export default function Blogs(): ReactElement {
justifyContent="center"
>
<h1>Blogs</h1>
<p.div w="full">
<div className="markdown-body">
<Test components={components} />
</div>
</p.div>
<Article />
</p.div>
);
}

0 comments on commit 0fa8139

Please sign in to comment.