Move show/hide deprecated from core to sample code
This commit is contained in:
@@ -6,6 +6,10 @@
|
||||
|
||||
-
|
||||
var content = [
|
||||
{
|
||||
name: "this-pattern-doesn't-exist",
|
||||
status: "deprecated",
|
||||
},
|
||||
{
|
||||
name: "colours",
|
||||
status: "complete",
|
||||
|
@@ -33,10 +33,14 @@ mixin show-content(items, path)
|
||||
data-status=items.status
|
||||
data-core= (items.core ? "true" : "false")
|
||||
)
|
||||
h1(class="status-" + items.status )
|
||||
span= items.name.toSentenceCase().toContent()
|
||||
tool-tip(role="tooltip" inert tip-position="right")= items.status.toSentenceCase().toContent()
|
||||
if items.files
|
||||
each item in items.files
|
||||
+show-content(item, path)
|
||||
|
||||
|
||||
doctype html
|
||||
html(lang= lang )
|
||||
head
|
||||
@@ -56,11 +60,6 @@ html(lang= lang )
|
||||
|
||||
block header
|
||||
|
||||
p.deprecated-switch
|
||||
span
|
||||
span#deprecated(role="switch")
|
||||
label(for="deprecated") Show deprecated patterns
|
||||
|
||||
main#main
|
||||
|
||||
h1= site
|
||||
|
@@ -16,4 +16,9 @@ block header
|
||||
a(href="./") Home
|
||||
each first in content
|
||||
li(class= navClass)
|
||||
a(href="./?p=" + first.name )= first.name.toContent().toSentenceCase()
|
||||
a(href="./?p=" + first.name )= first.name.toContent().toSentenceCase()
|
||||
|
||||
p.deprecated-switch
|
||||
span
|
||||
span#deprecated(role="switch")
|
||||
label(for="deprecated") Show deprecated patterns
|
Reference in New Issue
Block a user