mirror of
https://github.com/stefanpejcic/openpanel
synced 2025-06-26 18:28:26 +00:00
Delete documentation/src/pages/translations directory
This commit is contained in:
parent
3f64f3dd00
commit
37bbc0c0bb
@ -1,38 +0,0 @@
|
|||||||
import React, { useEffect, useState } from "react";
|
|
||||||
import Head from "@docusaurus/Head";
|
|
||||||
import { BlogFooter } from "@site/src/refine-theme/blog-footer";
|
|
||||||
import { CommonHeader } from "@site/src/refine-theme/common-header";
|
|
||||||
import { CommonLayout } from "@site/src/refine-theme/common-layout";
|
|
||||||
import clsx from "clsx";
|
|
||||||
import marked from "marked"; // Import the marked library for parsing Markdown
|
|
||||||
|
|
||||||
const Translations: React.FC = () => {
|
|
||||||
const [readmeContent, setReadmeContent] = useState<string>("");
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
const fetchReadme = async () => {
|
|
||||||
try {
|
|
||||||
const response = await fetch("https://raw.githubusercontent.com/stefanpejcic/openpanel-translations/main/README.md");
|
|
||||||
const data = await response.text();
|
|
||||||
setReadmeContent(data);
|
|
||||||
} catch (error) {
|
|
||||||
console.error("Error fetching README:", error);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
fetchReadme();
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
const renderMarkdown = (content: string) => {
|
|
||||||
// Use marked library to parse Markdown content
|
|
||||||
return {__html: marked(content)};
|
|
||||||
};
|
|
||||||
|
|
||||||
return (
|
|
||||||
<CommonLayout>
|
|
||||||
|
|
||||||
</CommonLayout>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
export default Translations;
|
|
Loading…
Reference in New Issue
Block a user