-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathdocusaurus.config.js
More file actions
129 lines (126 loc) · 3.91 KB
/
docusaurus.config.js
File metadata and controls
129 lines (126 loc) · 3.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
module.exports = {
title: 'SSN Docs',
tagline: 'The documentation source for the Session Smart Networking Platform',
url: 'https://docs.128technology.com',
baseUrl: process.env.OFFLINE_DOCS ? '/offline-docs/' : '/',
favicon: 'img/favicon.ico',
organizationName: '128technology', // Usually your GitHub org/user name.
projectName: 'docs', // Usually your repo name.
onBrokenAnchors: 'throw',
markdown: {
mermaid: true,
hooks: {
onBrokenMarkdownLinks: 'throw',
onBrokenMarkdownImages: 'throw',
},
},
themes: ['@docusaurus/theme-mermaid'],
themeConfig: {
colorMode: {
// "light" | "dark"
defaultMode: 'light',
// Hides the switch in the navbar
// Useful if you want to support a single color mode
disableSwitch: true,
// Should we use the prefers-color-scheme media-query,
// using user system preferences, instead of the hardcoded defaultMode
respectPrefersColorScheme: false,
},
navbar: {
title: '',
logo: {
alt: 'Juniper Logo',
src: 'img/logo.png',
srcDark: 'img/logo_dark.png',
},
items: [
{
to: 'docs/intro_getting_started',
label: 'Docs',
position: 'right',
},
{
to: 'kb',
label: 'Knowledge Base',
position: 'right',
},
{
href: 'https://community.juniper.net/answers/communities/community-home?CommunityKey=310d1a41-12fa-4627-9a99-880145a7c87c',
label: 'Community',
position: 'right',
},
{
href: 'https://www.juniper.net/',
label: 'Company',
position: 'right',
},
],
},
footer: {
copyright: `Copyright © ${new Date().getFullYear()} Juniper Networks, Inc.`,
},
},
presets: [
[
'@docusaurus/preset-classic',
{
docs: {
sidebarPath: require.resolve('./sidebars.js'),
showLastUpdateAuthor: false,
showLastUpdateTime: false,
},
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
blog: {
path: 'kb',
routeBasePath: 'kb',
blogTitle: 'Session Smart Router Knowledge Base Articles',
postsPerPage: 'ALL',
//blogSidebarTitle: 'Last 10 Posts',
blogSidebarCount: 0,
showReadingTime: false,
feedOptions: {
type: 'all',
title: 'SSR Knowledge Base Articles',
description: 'Session Smart Router Knowledge Base Articles',
limit: 20,
copyright: `Copyright © ${new Date().getFullYear()} Juniper Networks, Inc.`,
language: 'en-US',
createFeedItems: async (params) => {
const {blogPosts, defaultCreateFeedItems, ...rest} = params;
return defaultCreateFeedItems({
// keep only the 10 most recent blog posts in the feed
blogPosts: blogPosts.filter((item, index) => index < 10),
...rest,
});
},
},
},
},
],
],
plugins: process.env.OFFLINE_DOCS
? ['./src/plugins/release-notes-api.js', './src/plugins/search-index.js']
: ['./src/plugins/release-notes-api.js'],
customFields: {
offlineDocs: process.env.OFFLINE_DOCS === '1',
marvisSearch: {
docSource: '128t',
numResults: 15,
proxyURL:
'https://raq48a0wrg.execute-api.us-east-1.amazonaws.com/prod/marvis_docs_api_proxy',
},
},
};
if (process.env.OFFLINE_DOCS) {
module.exports.themeConfig.announcementBar = {
id: 'offline_docs',
content:
'You are viewing a local version of this documentation. ' +
'For the most up-to-date information please visit the <a target="_blank" href="https://docs.128technology.com/">online documentation</a>',
backgroundColor: '#eed202',
textColor: '#000',
isCloseable: true,
};
}