Files: 5b50cf4764591456ca0e705aba348269bf6c3268 / app / html / topNav / zz_topNavBack.js
707 bytesRaw
1 | const nest = require('depnest') |
2 | const { h, computed, when } = require('mutant') |
3 | const get = require('lodash/get') |
4 | |
5 | exports.gives = nest('app.html.topNav') |
6 | |
7 | exports.needs = nest({ |
8 | 'history.sync.push': 'first', |
9 | 'history.sync.back': 'first', |
10 | 'translations.sync.strings': 'first', |
11 | }) |
12 | |
13 | exports.create = (api) => { |
14 | return nest('app.html.topNav', (location) => { |
15 | // const strings = api.translations.sync.strings() |
16 | const back = () => api.history.sync.back() |
17 | |
18 | return h('TopNav -back', [ |
19 | h('div.left', [ |
20 | h('div', { 'ev-click': back }, [ |
21 | h('i.fa.fa-chevron-left'), |
22 | // strings.blogIndex.title |
23 | ]), |
24 | ]), |
25 | h('div.right', [ |
26 | ]) |
27 | ]) |
28 | }) |
29 | } |
30 | |
31 |
Built with git-ssb-web