You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
wiki/server/views/legacy/page.pug

61 lines
2.1 KiB

extends master.pug
block head
if injectCode.css
style(type='text/css')!= injectCode.css
if injectCode.head
!= injectCode.head
block body
#root
.header
span.header-title= siteConfig.title
span.header-deprecated!= t('outdatedBrowserWarning', { modernBrowser: '<a href="https://bestvpn.org/outdatedbrowser/en" rel="nofollow">' + t('modernBrowser') + '</a>', interpolation: { escapeValue: false } })
span.header-login
if !isAuthenticated
a(href='/login', title='Login')
i.mdi.mdi-account-circle
else
a(href='/logout', title='Logout')
i.mdi.mdi-logout
.main
.sidebar
each navItem in sidebar
if navItem.k === 'link'
a.sidebar-link(href=navItem.t)
i.mdi(class=navItem.c)
span= navItem.l
else if navItem.k === 'divider'
.sidebar-divider
else if navItem.k === 'header'
.sidebar-title= navItem.l
.main-container
.page-header
.page-header-left
h1= page.title
h2= page.description
//- .page-header-right
//- .page-header-right-title Last edited by
//- .page-header-right-author= page.authorName
//- .page-header-right-updated= page.updatedAt
.page-contents.v-content
.contents
div!= page.render
if page.toc.length
.toc
.toc-title= t('page.toc')
each tocItem, tocIdx in page.toc
a.toc-tile(href=tocItem.anchor)
i.mdi.mdi-chevron-right
span= tocItem.title
if tocIdx < page.toc.length - 1 || tocItem.children.length
.toc-divider
each tocSubItem in tocItem.children
a.toc-tile.inset(href=tocSubItem.anchor)
i.mdi.mdi-chevron-right
span= tocSubItem.title
if tocIdx < page.toc.length - 1
.toc-divider.inset
if injectCode.body
!= injectCode.body