-
Notifications
You must be signed in to change notification settings - Fork 46
Expand file tree
/
Copy pathindex.jsx
More file actions
41 lines (38 loc) · 1.29 KB
/
index.jsx
File metadata and controls
41 lines (38 loc) · 1.29 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
import TableOfContents from '@node-core/ui-components/Common/TableOfContents';
import Article from '@node-core/ui-components/Containers/Article';
import RemoteLoadableBanner from '../AnnouncementBanner';
import Footer from '#theme/Footer';
import MetaBar from '#theme/Metabar';
import NavBar from '#theme/Navigation';
import SideBar from '#theme/Sidebar';
/**
* Default page Layout component.
*
* Renders the full page structure: navigation, sidebar, table of contents,
* main content, meta bar, and footer. Override via `#theme/Layout` in your
* configuration's `imports` to customize the entire page structure.
*
* @param {{ metadata: import('../../types').SerializedMetadata, headings: Array, readingTime: string, children: import('preact').ComponentChildren }} props
*/
export default ({ metadata, headings, readingTime, children }) => (
<>
<RemoteLoadableBanner />
<NavBar metadata={metadata} />
<Article>
<SideBar metadata={metadata} />
<div>
<div>
<TableOfContents headings={headings} summaryTitle="On this page" />
<br />
<main>{children}</main>
</div>
<MetaBar
metadata={metadata}
headings={headings}
readingTime={readingTime}
/>
</div>
</Article>
<Footer />
</>
);