diff options
author | Volpeon <git@volpeon.ink> | 2024-06-26 21:53:25 +0200 |
---|---|---|
committer | Volpeon <git@volpeon.ink> | 2024-06-26 21:53:25 +0200 |
commit | 1ae122fd45f1508287b8a0ea49b07ffc5d3abf85 (patch) | |
tree | c3ca5e09bdb8ed49b01110d64f0580147fb8deeb | |
parent | Menus (diff) | |
download | iro-design-1ae122fd45f1508287b8a0ea49b07ffc5d3abf85.tar.gz iro-design-1ae122fd45f1508287b8a0ea49b07ffc5d3abf85.tar.bz2 iro-design-1ae122fd45f1508287b8a0ea49b07ffc5d3abf85.zip |
Update
-rw-r--r-- | src/objects/_menu.scss | 3 | ||||
-rw-r--r-- | tpl/index.pug | 2 | ||||
-rw-r--r-- | tpl/views/action-menu.pug | 20 | ||||
-rw-r--r-- | tpl/views/menu.pug | 68 |
4 files changed, 19 insertions, 74 deletions
diff --git a/src/objects/_menu.scss b/src/objects/_menu.scss index 091098d..b1350ba 100644 --- a/src/objects/_menu.scss +++ b/src/objects/_menu.scss | |||
@@ -10,7 +10,7 @@ | |||
10 | --header: ( | 10 | --header: ( |
11 | --font-size: fn.global-dim(--font-size --50), | 11 | --font-size: fn.global-dim(--font-size --50), |
12 | ), | 12 | ), |
13 | --separator: fn.global-dim(--size --85), | 13 | --separator: fn.global-dim(--size --100), |
14 | --item: ( | 14 | --item: ( |
15 | --pad-i: fn.global-dim(--size --150), | 15 | --pad-i: fn.global-dim(--size --150), |
16 | --pad-b: fn.global-dim(--size --100), | 16 | --pad-b: fn.global-dim(--size --100), |
@@ -106,6 +106,7 @@ | |||
106 | @include iro.bem-elem('separator') { | 106 | @include iro.bem-elem('separator') { |
107 | block-size: 1px; | 107 | block-size: 1px; |
108 | margin-block: fn.dim(--separator); | 108 | margin-block: fn.dim(--separator); |
109 | margin-inline: fn.dim(--item --pad-i); | ||
109 | background-color: fn.color(--separator); | 110 | background-color: fn.color(--separator); |
110 | } | 111 | } |
111 | 112 | ||
diff --git a/tpl/index.pug b/tpl/index.pug index 7b419b3..d3e9daf 100644 --- a/tpl/index.pug +++ b/tpl/index.pug | |||
@@ -73,7 +73,6 @@ include views/overflow-button.pug | |||
73 | include views/status-indicator.pug | 73 | include views/status-indicator.pug |
74 | include views/avatar.pug | 74 | include views/avatar.pug |
75 | include views/popover.pug | 75 | include views/popover.pug |
76 | include views/action-menu.pug | ||
77 | include views/menu.pug | 76 | include views/menu.pug |
78 | include views/side-nav.pug | 77 | include views/side-nav.pug |
79 | include views/icon-nav.pug | 78 | include views/icon-nav.pug |
@@ -122,7 +121,6 @@ html | |||
122 | +view-side-nav | 121 | +view-side-nav |
123 | +view-popover | 122 | +view-popover |
124 | +view-menu | 123 | +view-menu |
125 | +view-action-menu | ||
126 | +view-icon-nav | 124 | +view-icon-nav |
127 | +view-backdrop | 125 | +view-backdrop |
128 | +view-dialog | 126 | +view-dialog |
diff --git a/tpl/views/action-menu.pug b/tpl/views/action-menu.pug deleted file mode 100644 index 0546463..0000000 --- a/tpl/views/action-menu.pug +++ /dev/null | |||
@@ -1,20 +0,0 @@ | |||
1 | mixin view-action-menu | ||
2 | +view('action-menu', 'Action menu') | ||
3 | .c-box | ||
4 | div(style={ display: 'flex', 'flex-direction': 'column', 'align-items': 'flex-start' }) | ||
5 | +action-button(quiet=true selected=true)= 'Menu' | ||
6 | +popover | ||
7 | +menu | ||
8 | +menu-slot(class='l-media l-media--flush') | ||
9 | +avatar(block=true circle=true size='100' src='avatar.png' class='l-media__block') | ||
10 | .l-media__block.l-media__block--main | ||
11 | strong.u-d-block= 'Volpeon' | ||
12 | small.u-d-block= '@volpeon@mk.vulpes.one' | ||
13 | +menu-separator | ||
14 | +menu-item(icon='user')= 'View profile' | ||
15 | +menu-item(icon='red' iconIsStatus=true)= 'Mark as away' | ||
16 | +menu-separator | ||
17 | +menu-item(icon='trash' disabled=true)= 'Delete' | ||
18 | +menu-item(icon='bookmark')= 'Bookmark' | ||
19 | +menu-item(icon='tags')= 'Tags' | ||
20 | +menu-item(postIcon='chevron-right')= 'More' | ||
diff --git a/tpl/views/menu.pug b/tpl/views/menu.pug index c61cb92..34a15ce 100644 --- a/tpl/views/menu.pug +++ b/tpl/views/menu.pug | |||
@@ -1,54 +1,20 @@ | |||
1 | mixin view-menu | 1 | mixin view-menu |
2 | +view('menu', 'Menu') | 2 | +view('menu', 'Menu') |
3 | .c-box | 3 | .c-box |
4 | div(style={ display: 'flex', gap: '3rem' }) | 4 | div(style={ display: 'flex', 'flex-direction': 'column', 'align-items': 'flex-start' }) |
5 | +menu | 5 | +action-button(quiet=true selected=true)= 'Menu' |
6 | +menu-header= 'Category 1' | 6 | +popover |
7 | +menu-item= 'Mark as away' | 7 | +menu |
8 | +menu-item= 'Delete' | 8 | +menu-slot(class='l-media l-media--flush') |
9 | 9 | +avatar(block=true circle=true size='100' src='avatar.png' class='l-media__block') | |
10 | +menu-header= 'Category 2' | 10 | .l-media__block.l-media__block--main |
11 | +menu-item(icon='bookmark')= 'Bookmark' | 11 | strong.u-d-block= 'Volpeon' |
12 | +menu-item(icon='tags')= 'Tags' | 12 | small.u-d-block= '@volpeon@mk.vulpes.one' |
13 | 13 | +menu-separator | |
14 | +menu | 14 | +menu-item(icon='user')= 'View profile' |
15 | +menu-item(header=true) | 15 | +menu-item(icon='red' iconIsStatus=true)= 'Mark as away' |
16 | = 'Bouncer' | 16 | +menu-separator |
17 | 17 | +menu-item(icon='trash' disabled=true)= 'Delete' | |
18 | +menu-separator | 18 | +menu-item(icon='bookmark')= 'Bookmark' |
19 | 19 | +menu-item(icon='tags')= 'Tags' | |
20 | +menu-item(header=true) | 20 | +menu-item(postIcon='chevron-right')= 'More' |
21 | = 'Libera' | ||
22 | +menu-item(icon='hash') | ||
23 | = 'achannel ' | ||
24 | +badge('primary')(size='sm')= '12 ' | ||
25 | +menu-item(icon='hash') | ||
26 | = 'kitsuneirc ' | ||
27 | +badge(size='sm')= '31 ' | ||
28 | +menu-item(icon='green' iconIsStatus=true) | ||
29 | = 'volpeon' | ||
30 | +menu-item(icon='red' iconIsStatus=true) | ||
31 | = 'someone' | ||
32 | |||
33 | +menu-separator | ||
34 | |||
35 | +menu-item(header=true) | ||
36 | = 'Ergo Testnet' | ||
37 | |||
38 | +menu-separator | ||
39 | |||
40 | +menu-item(header=true) | ||
41 | = 'NixNet' | ||
42 | |||
43 | +menu | ||
44 | +menu-header= 'Operators' | ||
45 | +menu-item | ||
46 | +user-card('volpeon', 0) | ||
47 | +menu-item | ||
48 | +user-card('curiousfox', 90) | ||
49 | |||
50 | +menu-header= 'Moderators' | ||
51 | +menu-item | ||
52 | +user-card('user3567', 135) | ||
53 | +menu-item | ||
54 | +user-card('johndoe', 270) | ||