mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-18 03:26:57 +02:00
feat(content-docs): sidebar item type "html" for rendering pure markup (#6519)
Co-authored-by: sebastienlorber <lorber.sebastien@gmail.com>
This commit is contained in:
parent
65ba551f5b
commit
6ec0db4722
9 changed files with 172 additions and 3 deletions
|
@ -71,6 +71,33 @@ const sidebars = {
|
|||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
type: 'category',
|
||||
label: 'HTML items tests',
|
||||
items: [
|
||||
// title
|
||||
{
|
||||
type: 'html',
|
||||
value: 'Some Text',
|
||||
defaultStyle: true,
|
||||
},
|
||||
// Divider
|
||||
{
|
||||
type: 'html',
|
||||
value:
|
||||
'<span style="border-top: 1px solid var(--ifm-color-gray-500); display: block;margin: 0.5rem 0 0.25rem 1rem;" />',
|
||||
},
|
||||
// Image
|
||||
{
|
||||
type: 'html',
|
||||
defaultStyle: true,
|
||||
value: `
|
||||
<span style="font-size: 0.5rem; color: lightgrey;">Powered by</span>
|
||||
<img style="width: 100px; height: 100px; display: block;" src="/img/docusaurus.png" alt="Docusaurus Logo" />
|
||||
`,
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
anotherSidebar: ['dummy'],
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue