From 4ef7ba48a68980c126b89bf5ba5a9ddac804f88f Mon Sep 17 00:00:00 2001 From: Volpeon Date: Sun, 17 Nov 2024 15:51:24 +0100 Subject: Add navbar --- tpl/objects/navbar.pug | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 tpl/objects/navbar.pug (limited to 'tpl/objects') diff --git a/tpl/objects/navbar.pug b/tpl/objects/navbar.pug new file mode 100644 index 0000000..bca8c90 --- /dev/null +++ b/tpl/objects/navbar.pug @@ -0,0 +1,30 @@ +include icon.pug +include status-indicator.pug +include action-button.pug + +mixin navbar + - + let classes = { + 'o-navbar': true, + 'o-navbar--quiet': attributes.quiet, + } + if (attributes.class) { + classes[attributes.class] = true; + } + + div(class=classes)&attributes(attributes) + block + +mixin navbar-item + - + let classes = { + 'o-navbar__item': true, + 'is-selected': attributes.selected, + } + if (attributes.class) { + classes[attributes.class] = true; + } + + #{!!attributes.tag ? attributes.tag : 'button'}(class=classes)&attributes(attributes) + .o-navbar__item-label + block -- cgit v1.2.3-70-g09d2