git ssb

16+

Dominic / patchbay



Tree: b1d27bb56f4c964bcfc04597ab5026aaaa9b57d5

Files: b1d27bb56f4c964bcfc04597ab5026aaaa9b57d5 / main / html / menu.js

522 bytesRaw
1const nest = require('depnest')
2const { h, Value } = require('mutant')
3
4exports.gives = nest('main.html.menu')
5
6exports.needs = nest('router.html.simpleRoute', 'map')
7
8exports.create = function (api) {
9 return nest('main.html.menu', menu)
10
11 function menu (handleClick) {
12 var state = Value('')
13
14 return h('Menu', {
15 classList: [ state ],
16 'ev-mouseover': () => state.set('-active'),
17 'ev-mouseout': () => state.set('')
18 }, [
19 h('div', api.router.html.simpleRoute(handleClick))
20 ])
21 }
22}
23
24

Built with git-ssb-web