summaryrefslogtreecommitdiffstats
path: root/tpl/objects
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2022-02-08 10:52:55 +0100
committerVolpeon <git@volpeon.ink>2022-02-08 10:52:55 +0100
commit0cd81a322b92ede51d0da1f8227a3828f08eebdf (patch)
tree80b9a18d9c4442bf0a9ed3797bfad7d6c0ce4c3e /tpl/objects
parentAdd border to action menu (diff)
downloadiro-design-0cd81a322b92ede51d0da1f8227a3828f08eebdf.tar.gz
iro-design-0cd81a322b92ede51d0da1f8227a3828f08eebdf.tar.bz2
iro-design-0cd81a322b92ede51d0da1f8227a3828f08eebdf.zip
Improved action menu
Diffstat (limited to 'tpl/objects')
-rw-r--r--tpl/objects/action-menu.pug11
-rw-r--r--tpl/objects/avatar.pug7
2 files changed, 16 insertions, 2 deletions
diff --git a/tpl/objects/action-menu.pug b/tpl/objects/action-menu.pug
index 0f690ce..55ceacb 100644
--- a/tpl/objects/action-menu.pug
+++ b/tpl/objects/action-menu.pug
@@ -30,3 +30,14 @@ mixin action-menu-item
30 30
31mixin action-menu-separator 31mixin action-menu-separator
32 .o-action-menu__separator 32 .o-action-menu__separator
33
34mixin action-menu-slot
35 -
36 let classes = {
37 'o-action-menu__slot ': true,
38 }
39 if (attributes.class) {
40 classes[attributes.class] = true;
41 }
42 div(class=classes)
43 block
diff --git a/tpl/objects/avatar.pug b/tpl/objects/avatar.pug
index 83c0f7c..16de7c5 100644
--- a/tpl/objects/avatar.pug
+++ b/tpl/objects/avatar.pug
@@ -4,9 +4,12 @@ mixin avatar
4 - 4 -
5 let classes = { 5 let classes = {
6 'o-avatar': true, 6 'o-avatar': true,
7 'o-avatar--circle': attributes.circle 7 'o-avatar--circle': attributes.circle,
8 'u-db': attributes.block
9 }
10 if (attributes.class) {
11 classes[attributes.class] = true;
8 } 12 }
9
10 if (attributes.size) { 13 if (attributes.size) {
11 classes['o-avatar--' + attributes.size] = true; 14 classes['o-avatar--' + attributes.size] = true;
12 } 15 }