website: support hidden pages in nav-data (#10180) (#10197)

* website: bump to docs-page prerelease with hidden page support

* website: replace hidden pages hot fix for /docs, /api-docs, and /commmands

* website: remove unused files for old hidden pages hotfix

* website: bump to stable docs-page, w next-mdx-remote bump

* website: bump to latest markdown-page
pull/10201/head
Zachary Shilton 2021-05-06 15:36:27 -04:00 committed by GitHub
parent 33fed292a2
commit e83f0166cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 2421 additions and 2000 deletions

View File

@ -60,6 +60,11 @@
} }
] ]
}, },
{
"title": "ACL (Legacy)",
"path": "acl-legacy",
"hidden": true
},
{ {
"title": "Agent", "title": "Agent",
"routes": [ "routes": [

View File

@ -295,6 +295,11 @@
"title": "get", "title": "get",
"path": "intention/get" "path": "intention/get"
}, },
{
"title": "list",
"path": "intention/list",
"hidden": true
},
{ {
"title": "match", "title": "match",
"path": "intention/match" "path": "intention/match"

View File

@ -64,6 +64,11 @@
"title": "Overview", "title": "Overview",
"path": "install" "path": "install"
}, },
{
"title": "Manual Bootstrap",
"path": "install/manual-bootstrap",
"hidden": true
},
{ {
"title": "Consul Agent", "title": "Consul Agent",
"href": "/docs/agent" "href": "/docs/agent"
@ -197,6 +202,11 @@
{ {
"title": "Proxy Integration", "title": "Proxy Integration",
"path": "connect/proxies/integrate" "path": "connect/proxies/integrate"
},
{
"title": "Managed (Deprecated)",
"path": "connect/proxies/managed-deprecated",
"hidden": true
} }
] ]
}, },
@ -334,6 +344,11 @@
{ {
"title": "Develop and Debug", "title": "Develop and Debug",
"path": "connect/dev" "path": "connect/dev"
},
{
"title": "Security",
"path": "connect/security",
"hidden": true
} }
] ]
}, },
@ -655,6 +670,11 @@
{ {
"title": "Sentinel", "title": "Sentinel",
"path": "agent/sentinel" "path": "agent/sentinel"
},
{
"title": "RPC",
"path": "agent/rpc",
"hidden": true
} }
] ]
}, },
@ -904,5 +924,24 @@
"path": "release-notes/1-9-0" "path": "release-notes/1-9-0"
} }
] ]
},
{
"title": "Internals",
"hidden": true,
"routes": [
{
"title": "Overview",
"path": "internals"
},
{
"title": "ACL",
"path": "internals/acl"
}
]
},
{
"title": "Guides",
"path": "guides",
"hidden": true
} }
] ]

View File

@ -1,7 +1,9 @@
const withHashicorp = require('@hashicorp/nextjs-scripts') const withHashicorp = require('@hashicorp/nextjs-scripts')
const redirects = require('./redirects.next') const redirects = require('./redirects.next')
module.exports = withHashicorp()({ module.exports = withHashicorp({
transpileModules: ['@hashicorp/versioned-docs'],
})({
svgo: { plugins: [{ removeViewBox: false }] }, svgo: { plugins: [{ removeViewBox: false }] },
rewrites: () => [ rewrites: () => [
{ {

4347
website/package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -12,7 +12,7 @@
"@hashicorp/react-call-to-action": "3.0.1", "@hashicorp/react-call-to-action": "3.0.1",
"@hashicorp/react-callouts": "7.0.2", "@hashicorp/react-callouts": "7.0.2",
"@hashicorp/react-content": "7.0.1", "@hashicorp/react-content": "7.0.1",
"@hashicorp/react-docs-page": "13.1.4", "@hashicorp/react-docs-page": "13.2.0",
"@hashicorp/react-featured-slider": "4.0.0", "@hashicorp/react-featured-slider": "4.0.0",
"@hashicorp/react-hashi-stack-menu": "2.0.3", "@hashicorp/react-hashi-stack-menu": "2.0.3",
"@hashicorp/react-head": "3.0.2", "@hashicorp/react-head": "3.0.2",
@ -20,7 +20,7 @@
"@hashicorp/react-image": "4.0.1", "@hashicorp/react-image": "4.0.1",
"@hashicorp/react-inline-svg": "6.0.1", "@hashicorp/react-inline-svg": "6.0.1",
"@hashicorp/react-learn-callout": "1.0.2", "@hashicorp/react-learn-callout": "1.0.2",
"@hashicorp/react-markdown-page": "1.1.2", "@hashicorp/react-markdown-page": "1.2.0",
"@hashicorp/react-product-downloads-page": "2.0.2", "@hashicorp/react-product-downloads-page": "2.0.2",
"@hashicorp/react-product-features-list": "4.0.1", "@hashicorp/react-product-features-list": "4.0.1",
"@hashicorp/react-section-header": "5.0.2", "@hashicorp/react-section-header": "5.0.2",
@ -32,7 +32,7 @@
"@hashicorp/react-use-cases": "3.0.2", "@hashicorp/react-use-cases": "3.0.2",
"@hashicorp/react-vertical-text-block-list": "6.0.2", "@hashicorp/react-vertical-text-block-list": "6.0.2",
"next": "10.1.3", "next": "10.1.3",
"next-mdx-remote": "2.1.4", "next-mdx-remote": "3.0.1",
"next-remote-watch": "1.0.0", "next-remote-watch": "1.0.0",
"nuka-carousel": "4.7.7", "nuka-carousel": "4.7.7",
"react": "16.13.1", "react": "16.13.1",

View File

@ -20,7 +20,10 @@ export default function ApiDocsLayout(props) {
} }
export async function getStaticPaths() { export async function getStaticPaths() {
const paths = await generateStaticPaths({ localContentDir, navDataFile }) const paths = await generateStaticPaths({
localContentDir,
navDataFile,
})
return { paths, fallback: false } return { paths, fallback: false }
} }

View File

@ -20,7 +20,10 @@ export default function CommandsLayout(props) {
} }
export async function getStaticPaths() { export async function getStaticPaths() {
const paths = await generateStaticPaths({ localContentDir, navDataFile }) const paths = await generateStaticPaths({
localContentDir,
navDataFile,
})
return { paths, fallback: false } return { paths, fallback: false }
} }

View File

@ -27,7 +27,10 @@ export default function DocsLayout(props) {
} }
export async function getStaticPaths() { export async function getStaticPaths() {
const paths = await generateStaticPaths({ localContentDir, navDataFile }) const paths = await generateStaticPaths({
localContentDir,
navDataFile,
})
return { paths, fallback: false } return { paths, fallback: false }
} }