Fixed redirects

This commit is contained in:
Nikolay Rozhkov
2024-01-05 19:33:15 +03:00
parent e0bd684248
commit 6d5f33856c
5 changed files with 25 additions and 15 deletions

View File

@@ -8,7 +8,7 @@
You decided to take part in the development? Welcome! You decided to take part in the development? Welcome!
We were trying to make our guidelines for you as explicit and detailed as possible. We are trying to make our guidelines for you as explicit and detailed as possible.
## Initial Setup ## Initial Setup
@@ -111,7 +111,7 @@ pnpm test
**Docker** **Docker**
```bash ```bash
./run pnpm test ./run pnpm vitest
``` ```
The `test` script and others are in the top-level `package.json` file. The `test` script and others are in the top-level `package.json` file.

View File

@@ -84,8 +84,8 @@ function nav() {
}, },
{ {
text: 'Contributing', text: 'Contributing',
link: '/comminuty/intro', link: '/community/intro',
activeMatch: '/comminuty/', activeMatch: '/community/',
}, },
{ {
text: 'Latest News', text: 'Latest News',
@@ -200,11 +200,11 @@ function sidebarCommunity() {
text: '🙌 Contributing', text: '🙌 Contributing',
collapsed: false, collapsed: false,
items: [ items: [
{ text: 'Getting Started', link: '/contributing/intro' }, { text: 'Getting Started', link: '/community/intro' },
{ text: 'Contributing to Mermaid', link: '/contributing/contributing' }, { text: 'Contributing to Mermaid', link: '/community/contributing' },
{ text: 'Adding Diagrams', link: '/contributing/new-diagram' }, { text: 'Adding Diagrams', link: '/community/new-diagram' },
{ text: 'Questions and Suggestions', link: '/contributing/questions-and-suggestions' }, { text: 'Questions and Suggestions', link: '/community/questions-and-suggestions' },
{ text: 'Security', link: '/contributing/security' }, { text: 'Security', link: '/community/security' },
], ],
}, },
]; ];

View File

@@ -38,6 +38,11 @@ test.each([
['https://mermaid.js.org/#/flowchart.md', 'syntax/flowchart.html'], ['https://mermaid.js.org/#/flowchart.md', 'syntax/flowchart.html'],
// New docs, without base path, new domain // New docs, without base path, new domain
['https://mermaid.js.org/misc/faq.html', 'configure/faq.html'], ['https://mermaid.js.org/misc/faq.html', 'configure/faq.html'],
['https://mermaid.js.org/community/newDiagram.html', 'community/new-diagram.html'],
['https://mermaid.js.org/community/development.html', 'community/contributing.html#initial-setup'],
['https://mermaid.js.org/community/docker-development.html', 'community/contributing.html#initial-setup'],
['https://mermaid.js.org/community/code.html', 'community/contributing.html#contributing-code'],
['https://mermaid.js.org/community/documentation.html', 'community/contributing.html#contributing-documentation'],
[ [
'https://mermaid.js.org/misc/faq.html#frequently-asked-questions', 'https://mermaid.js.org/misc/faq.html#frequently-asked-questions',
'configure/faq.html#frequently-asked-questions', 'configure/faq.html#frequently-asked-questions',

View File

@@ -58,7 +58,7 @@ const idRedirectMap: Record<string, string> = {
'n00b-gettingstarted': 'intro/getting-started', 'n00b-gettingstarted': 'intro/getting-started',
'n00b-overview': 'intro/getting-started', 'n00b-overview': 'intro/getting-started',
'n00b-syntaxreference': 'intro/syntax-reference', 'n00b-syntaxreference': 'intro/syntax-reference',
newdiagram: 'community/newDiagram', newdiagram: 'community/new-diagram',
pie: 'syntax/pie', pie: 'syntax/pie',
plugins: '', plugins: '',
quickstart: 'intro/getting-started', quickstart: 'intro/getting-started',
@@ -88,10 +88,15 @@ const urlRedirectMap: Record<string, string> = {
'/syntax/c4c.html': 'syntax/c4.html', '/syntax/c4c.html': 'syntax/c4.html',
'/ecosystem/integrations.html': 'ecosystem/integrations-community.html', '/ecosystem/integrations.html': 'ecosystem/integrations-community.html',
'/ecosystem/showcases.html': 'ecosystem/integrations-create', '/ecosystem/showcases.html': 'ecosystem/integrations-create',
'/config/n00b-advanced.html': 'config/advanced', '/config/n00b-advanced.html': 'config/configuration.html',
'/intro/n00b-gettingStarted.html': 'intro/getting-started', '/intro/n00b-gettingStarted.html': 'intro/getting-started.html',
'/intro/n00b-syntaxReference.html': 'intro/syntax-reference', '/intro/n00b-syntaxReference.html': 'intro/syntax-reference.html',
'/community/n00b-overview.html': 'intro/getting-started', '/community/n00b-overview.html': 'intro/getting-started.html',
'/community/newDiagram.html': 'community/new-diagram.html',
'/community/development.html': 'community/contributing.html#initial-setup',
'/community/docker-development.html': 'community/contributing.html#initial-setup',
'/community/code.html': 'community/contributing.html#contributing-code',
'/community/documentation.html': 'community/contributing.html#contributing-documentation',
}; };
/** /**

View File

@@ -2,7 +2,7 @@
You decided to take part in the development? Welcome! You decided to take part in the development? Welcome!
We were trying to make our guidelines for you as explicit and detailed as possible. We are trying to make our guidelines for you as explicit and detailed as possible.
## Initial Setup ## Initial Setup