diff options
Fix Docs hash linking bug
4 files changed, 43 insertions, 6 deletions
| -rw-r--r-- | docs/src/_docs-layout.pug | 2 | ||||
| -rw-r--r-- | docs/src/_mixins.pug | 4 | ||||
| -rw-r--r-- | docs/src/elements.pug | 4 | ||||
| -rw-r--r-- | docs/src/layout.pug | 39 |
diff --git a/docs/src/_docs-layout.pug b/docs/src/_docs-layout.pug index 7ae771c..ae2da02 100644 --- a/docs/src/_docs-layout.pug +++ b/docs/src/_docs-layout.pug @@ -32,7 +32,7 @@ block content {url: '#forms', name: 'Forms'}, {url: '#icons', name: 'Icons'}, {url: '#labels', name: 'Labels'}, - {url: '#codes', name: 'Codes'}, + {url: '#code', name: 'Code'}, {url: '#media', name: 'Media'} ) +docs-accordion( diff --git a/docs/src/_mixins.pug b/docs/src/_mixins.pug index 54e76d7..ccbe89e 100644 --- a/docs/src/_mixins.pug +++ b/docs/src/_mixins.pug @@ -9,8 +9,8 @@ mixin docs-accordion(id, name, ...pages) a(href=id + '.html' + page.url)= page.name mixin docs-heading(id, name) - .container - h3.s-title(id=id) + .container(id=id) + h3.s-title a.anchor(href='#'+id aria-hidden='true') # | #{name} if block diff --git a/docs/src/elements.pug b/docs/src/elements.pug index 809fe0f..3f1e270 100644 --- a/docs/src/elements.pug +++ b/docs/src/elements.pug @@ -36,6 +36,4 @@ block docs-content //- Media +docs-heading('media', 'Media') - include contents/media.pug - -
\ No newline at end of file + include contents/media.pug
\ No newline at end of file diff --git a/docs/src/layout.pug b/docs/src/layout.pug new file mode 100644 index 0000000..3f1e270 --- /dev/null +++ b/docs/src/layout.pug @@ -0,0 +1,39 @@ +extends _docs-layout.pug + +block variables + - var title = 'Elements - Spectre.css CSS Framework' + - var description = '' + - var current = 'elements' + +block docs-content + //- Typography + +docs-heading('typography', 'Typography') + include contents/typography.pug + + //- Tables + +docs-heading('tables', 'Tables') + include contents/tables.pug + + //- Buttons + +docs-heading('buttons', 'Buttons') + include contents/buttons.pug + + //- Forms + +docs-heading('forms', 'Forms') + include contents/forms.pug + + //- Icons + +docs-heading('icons', 'Icons') + include contents/icons.pug + + //- Labels + +docs-heading('labels', 'Labels') + include contents/labels.pug + + //- Codes + +docs-heading('code', 'Code') + include contents/code.pug + + //- Media + +docs-heading('media', 'Media') + include contents/media.pug
\ No newline at end of file |