From de7944e65ba282164434ff4f97ff80876eee84ee Mon Sep 17 00:00:00 2001 From: Evert De Spiegeleer Date: Wed, 8 May 2024 23:41:06 +0200 Subject: [PATCH] =?UTF-8?q?docs:=20=F0=9F=93=9A=EF=B8=8F=20add=20base=20st?= =?UTF-8?q?ructure=20to=20docs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/package.json | 13 +++++------- docs/pages/_meta.json | 21 +++++++++---------- docs/pages/about.mdx | 3 --- docs/pages/docs/_meta.json | 5 +++++ docs/pages/{ => docs}/advanced.mdx | 0 docs/pages/{ => docs}/advanced/satori.mdx | 0 docs/pages/{ => docs}/another.mdx | 4 ++-- docs/pages/docs/index.mdx | 11 ++++++++++ docs/pages/index.mdx | 12 +---------- docs/theme.config.tsx | 25 +++++++++++++++++------ 10 files changed, 53 insertions(+), 41 deletions(-) delete mode 100644 docs/pages/about.mdx create mode 100644 docs/pages/docs/_meta.json rename docs/pages/{ => docs}/advanced.mdx (100%) rename docs/pages/{ => docs}/advanced/satori.mdx (100%) rename docs/pages/{ => docs}/another.mdx (80%) create mode 100644 docs/pages/docs/index.mdx diff --git a/docs/package.json b/docs/package.json index 0a47d27..3b8cfa2 100644 --- a/docs/package.json +++ b/docs/package.json @@ -1,7 +1,7 @@ { - "name": "nextra-docs-template", - "version": "0.0.1", - "description": "Nextra docs template", + "name": "@zhttp/docs", + "private": true, + "version": "0.0.0", "scripts": { "dev": "next dev", "build": "next build", @@ -9,14 +9,11 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/shuding/nextra-docs-template.git" + "url": "git+https://github.com/evertdespiegeleer/zhttp" }, - "author": "Shu Ding ", - "license": "MIT", "bugs": { - "url": "https://github.com/shuding/nextra-docs-template/issues" + "url": "https://github.com/evertdespiegeleer/zhttp" }, - "homepage": "https://github.com/shuding/nextra-docs-template#readme", "dependencies": { "next": "^13.0.6", "nextra": "latest", diff --git a/docs/pages/_meta.json b/docs/pages/_meta.json index 164927d..3eb8df6 100644 --- a/docs/pages/_meta.json +++ b/docs/pages/_meta.json @@ -1,15 +1,14 @@ { - "index": "Introduction", - "another": "Another Page", - "advanced": "Advanced (A Folder)", - "about": { - "title": "About", - "type": "page" + "index": { + "type": "page", + "title": "Nextra", + "display": "hidden", + "theme": { + "layout": "raw" + } }, - "contact": { - "title": "Contact ↗", + "docs": { "type": "page", - "href": "https://twitter.com/shuding_", - "newWindow": true + "title": "Documentation" } -} +} \ No newline at end of file diff --git a/docs/pages/about.mdx b/docs/pages/about.mdx deleted file mode 100644 index ec6faed..0000000 --- a/docs/pages/about.mdx +++ /dev/null @@ -1,3 +0,0 @@ -# About - -This is the about page! This page is shown on the navbar. diff --git a/docs/pages/docs/_meta.json b/docs/pages/docs/_meta.json new file mode 100644 index 0000000..ba7e20a --- /dev/null +++ b/docs/pages/docs/_meta.json @@ -0,0 +1,5 @@ +{ + "index": "Introduction", + "another": "Another Page", + "advanced": "Advanced (A Folder)" +} \ No newline at end of file diff --git a/docs/pages/advanced.mdx b/docs/pages/docs/advanced.mdx similarity index 100% rename from docs/pages/advanced.mdx rename to docs/pages/docs/advanced.mdx diff --git a/docs/pages/advanced/satori.mdx b/docs/pages/docs/advanced/satori.mdx similarity index 100% rename from docs/pages/advanced/satori.mdx rename to docs/pages/docs/advanced/satori.mdx diff --git a/docs/pages/another.mdx b/docs/pages/docs/another.mdx similarity index 80% rename from docs/pages/another.mdx rename to docs/pages/docs/another.mdx index 7fb6a02..77f7403 100644 --- a/docs/pages/another.mdx +++ b/docs/pages/docs/another.mdx @@ -11,7 +11,7 @@ console.log(a); import { useState } from 'react' {/* Import CSS modules */} -import styles from '../components/counters.module.css' +import styles from '../../components/counters.module.css' export const Counter = () => { const [count, setCount] = useState(0); @@ -26,6 +26,6 @@ export const Counter = () => { ## External Component -import Counters from '../components/counters' +import Counters from '../../components/counters' diff --git a/docs/pages/docs/index.mdx b/docs/pages/docs/index.mdx new file mode 100644 index 0000000..058465c --- /dev/null +++ b/docs/pages/docs/index.mdx @@ -0,0 +1,11 @@ +# Introduction + +Welcome to Nextra! This is a basic docs template. You can use it as a starting point for your own project :) + +## What is Nextra? + +A **simple**, **powerful** and **flexible** site generation framework with everything you love from Next.js. + +## Documentation + +The documentation is available at [https://nextra.site](https://nextra.site). diff --git a/docs/pages/index.mdx b/docs/pages/index.mdx index 058465c..6b380cd 100644 --- a/docs/pages/index.mdx +++ b/docs/pages/index.mdx @@ -1,11 +1 @@ -# Introduction - -Welcome to Nextra! This is a basic docs template. You can use it as a starting point for your own project :) - -## What is Nextra? - -A **simple**, **powerful** and **flexible** site generation framework with everything you love from Next.js. - -## Documentation - -The documentation is available at [https://nextra.site](https://nextra.site). +Splash page goes here \ No newline at end of file diff --git a/docs/theme.config.tsx b/docs/theme.config.tsx index 88b8e2b..f7abc16 100644 --- a/docs/theme.config.tsx +++ b/docs/theme.config.tsx @@ -2,17 +2,30 @@ import React from 'react' import { DocsThemeConfig } from 'nextra-theme-docs' const config: DocsThemeConfig = { - logo: My Project, + logo: zhttp, project: { - link: 'https://github.com/shuding/nextra-docs-template', + link: 'https://github.com/evertdespiegeleer/zhttp', }, - chat: { - link: 'https://discord.com', + docsRepositoryBase: 'https://github.com/evertdespiegeleer/zhttp/docs', + feedback: { + useLink: () => 'https://github.com/evertdespiegeleer/zhttp/issues', + }, + editLink: { + text: 'Edit this page on GitHub →', }, - docsRepositoryBase: 'https://github.com/shuding/nextra-docs-template', footer: { - text: 'Nextra Docs Template', + text:
+

zhttp built with ❤️ by Evert De Spiegeleer

+

Docs generated with Nextra

+
}, + toc: { + backToTop: true + } } export default config