From 1086a3c68132475fcaf5935e8329716e512d3320 Mon Sep 17 00:00:00 2001 From: RedrockJS Date: Wed, 19 Mar 2025 14:38:58 +0300 Subject: [PATCH] refactor docs --- docusaurus.config.ts | 46 +- src/components/HomepageFeatures/index.tsx | 37 +- src/pages/index.tsx | 2 +- static/img/favicon.ico | Bin 3626 -> 0 bytes static/img/favicon.png | Bin 0 -> 1584 bytes static/svg/developer-logo.svg | 1570 +++++++++++++++++++++ static/svg/js-logo.svg | 4 + static/svg/react-logo.svg | 9 + static/svg/ts-logo.svg | 1 + 9 files changed, 1643 insertions(+), 26 deletions(-) delete mode 100644 static/img/favicon.ico create mode 100644 static/img/favicon.png create mode 100644 static/svg/developer-logo.svg create mode 100644 static/svg/js-logo.svg create mode 100644 static/svg/react-logo.svg create mode 100644 static/svg/ts-logo.svg diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 4942aa1..249d9e7 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -6,19 +6,19 @@ import type * as Preset from '@docusaurus/preset-classic'; const config: Config = { title: 'Frontend Docs', - tagline: 'Dinosaurs are cool', - favicon: 'img/favicon.ico', + tagline: 'Made with Dinosaurs', + favicon: 'img/favicon.png', // Set the production url of your site here - url: 'https://your-docusaurus-site.example.com', + url: 'https://frontend-docs-azure.vercel.app/', // Set the // pathname under which your site is served // For GitHub pages deployment, it is often '//' baseUrl: '/', // GitHub pages deployment config. // If you aren't using GitHub pages, you don't need these. - organizationName: 'facebook', // Usually your GitHub org/user name. - projectName: 'docusaurus', // Usually your repo name. + organizationName: 'Redrock corp.', // Usually your GitHub org/user name. + projectName: 'fe-docs', // Usually your repo name. onBrokenLinks: 'throw', onBrokenMarkdownLinks: 'warn', @@ -66,19 +66,19 @@ const config: Config = { themeConfig: { // Replace with your project's social card - image: 'img/docusaurus-social-card.jpg', + image: 'svg/developer-logo.svg', navbar: { title: 'Frontend Docs', logo: { alt: 'Frontend Docs', - src: 'img/logo.svg', + src: 'svg/developer-logo.svg', }, items: [ { type: 'docSidebar', sidebarId: 'tutorialSidebar', position: 'left', - label: 'Questions', + label: 'Документация', }, // {to: '/blog', label: 'Blog', position: 'left'}, { @@ -92,14 +92,40 @@ const config: Config = { style: 'dark', links: [ { - title: 'Docs', + title: 'Frontend Docs', items: [ { - label: 'Questions', + label: 'Документация', to: '/docs/category/browser', } ], }, + { + title: 'Ссылки', + items: [ + { + label: 'Learn.javascript.ru', + to: 'https://learn.javascript.ru/', + }, + { + label: 'Typescript Lang', + to: 'https://www.typescriptlang.org/', + }, + { + label: 'React Dev', + to: 'https://ru.react.dev/learn', + }, + ], + }, + { + title: 'Справочники', + items: [ + { + label: 'Дока', + to: 'https://doka.guide/' + } + ] + } ], copyright: `Copyright © ${new Date().getFullYear()} My Project, Inc. Built with Docusaurus.`, }, diff --git a/src/components/HomepageFeatures/index.tsx b/src/components/HomepageFeatures/index.tsx index c2551fb..d064569 100644 --- a/src/components/HomepageFeatures/index.tsx +++ b/src/components/HomepageFeatures/index.tsx @@ -5,51 +5,58 @@ import styles from './styles.module.css'; type FeatureItem = { title: string; + link: string; Svg: React.ComponentType>; description: ReactNode; }; const FeatureList: FeatureItem[] = [ { - title: 'Easy to Use', - Svg: require('@site/static/img/undraw_docusaurus_mountain.svg').default, + title: 'JavaScript', + link: 'https://learn.javascript.ru/', + Svg: require('@site/static/svg/js-logo.svg').default, description: ( <> - Docusaurus was designed from the ground up to be easily installed and - used to get your website up and running quickly. + Современный учебник JavaScript
+ Перед вами учебник по JavaScript, начиная с основ, включающий в себя много тонкостей и фишек JavaScript/DOM. ), }, { - title: 'Focus on What Matters', - Svg: require('@site/static/img/undraw_docusaurus_tree.svg').default, + title: 'Typescript handbook', + link: 'https://typescript-handbook.ru/', + Svg: require('@site/static/svg/ts-logo.svg').default, description: ( <> - Docusaurus lets you focus on your docs, and we'll do the chores. Go - ahead and move your docs into the docs directory. + Руководство, шпаргалки, вопросы и другие материалы по TypeScript ), }, { - title: 'Powered by React', - Svg: require('@site/static/img/undraw_docusaurus_react.svg').default, + title: 'React.dev', + link: 'https://ru.react.dev/learn', + Svg: require('@site/static/svg/react-logo.svg').default, description: ( <> - Extend or customize your website layout by reusing React. Docusaurus can - be extended while reusing the same header and footer. + Добро пожаловать в документацию React!
+ Эта страница познакомит вас с большинством концепций React, которыми вы будете пользоваться каждый день. ), }, ]; -function Feature({title, Svg, description}: FeatureItem) { +function Feature({title, link, Svg, description}: FeatureItem) { return (
- + + +
- {title} + + {title} +

{description}

diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 00fb03e..8071ec0 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -32,7 +32,7 @@ export default function Home(): ReactNode { const {siteConfig} = useDocusaurusContext(); return (
diff --git a/static/img/favicon.ico b/static/img/favicon.ico deleted file mode 100644 index c01d54bcd39a5f853428f3cd5aa0f383d963c484..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3626 zcmb`Je@s(X6vrR`EK3%b%orErlDW({vnABqA zcfaS{d+xbU5JKp0*;0YOg+;Fl!eT)XRuapIwFLL`=imZCSon$`se`_<%@MB=M~KG+ z=EW^FL`w|Bo>*ktlaS^(fut!95`iG5u=SZ8nfDHO#GaTlH1-XG^;vsjUb^gWTVz0+ z^=WR1wv9-2oeR=_;fL0H7rNWqAzGtO(D;`~cX(RcN0w2v24Y8)6t`cS^_ghs`_ho? z{0ka~1Dgo8TfAP$r*ua?>$_V+kZ!-(TvEJ7O2f;Y#tezt$&R4 zLI}=-y@Z!grf*h3>}DUL{km4R>ya_I5Ag#{h_&?+HpKS!;$x3LC#CqUQ8&nM?X))Q zXAy2?`YL4FbC5CgJu(M&Q|>1st8XXLZ|5MgwgjP$m_2Vt0(J z&Gu7bOlkbGzGm2sh?X`){7w69Y$1#@P@7DF{ZE=4%T0NDS)iH`tiPSKpDNW)zmtn( zw;4$f>k)4$LBc>eBAaTZeCM2(iD+sHlj!qd z2GjRJ>f_Qes(+mnzdA^NH?^NB(^o-%G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kg%=eB5PxAX zPp!C3((I+PX8_5x(Mg|YgpoWdD^_?hr6wl<@vjE+^@o1GXvZ-?@{Q4o*27Dz4A6z} zl9ZZUV3;FK!rjqP-Cv?ISJk{~;?q?4=Mv)0g$XZd!SH6IDgnyc?q?>+gwdf}m&d>* zLGx_Q0Jo(UUb3R*#$*mv1l0iw8vP;i8YcrQT6oD5;+KuQh`O`T9#HejIA+%W(PtKG z-n}9DzOS9Ov+=GfnkGW)h>Qkl0Z1pj$QCC#Nu~uDBo~D8f@V-pgKHAIpg}o=8wSFQ zI-p&W`Vbz3Ff_0ryx0jt*Y$RjDiK5Zwv>q&@)|3`OOc6~+9W*_vCdM&_EME1YO3ZU zGuDKcqDm3QVwH-F%2bT2m-NPqc`k0@jd6lD6i&ew>&f8Xj~(cvzrr0|kSlFY$7s1_5HuZ{d%5oG`>f$)+}lsAZYOrh54 z+9asG2wP#Sby_8bmt<`z2I5OnD7?7+gBKPXvq&SnAioN>NYb8TEI%eiecerbUtX<= zR1)FEv^BA7jVEuApEW%FR~CHZW!jqXV&0tFuwYHxto5d$LFwaj;%7APo&Xz|w&&Q$ zhmtp{@?IdmCe>%4{NP-8Nz$H^Tf~#>PVSV!&iG_tg%^~y2Agauj*gt5TGso<#QYJ| zb{#vg!b>As03(=3L3P2Gl740000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/static/svg/js-logo.svg b/static/svg/js-logo.svg new file mode 100644 index 0000000..9650ca7 --- /dev/null +++ b/static/svg/js-logo.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/static/svg/react-logo.svg b/static/svg/react-logo.svg new file mode 100644 index 0000000..ea77a61 --- /dev/null +++ b/static/svg/react-logo.svg @@ -0,0 +1,9 @@ + + React Logo + + + + + + + diff --git a/static/svg/ts-logo.svg b/static/svg/ts-logo.svg new file mode 100644 index 0000000..a46d53d --- /dev/null +++ b/static/svg/ts-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file