git ssb

2+

mixmix / ticktack



Commit 7458998a2a59e0edaf11b6ce83867a72f96577d6

app/html/nav.js no longer needed

Dominic Tarr committed on 8/16/2017, 4:54:01 AM
Parent: 8943d5337c4f14e8cf7746fafc3943d3ccc3b1f6

Files changed

app/html/nav.jsdeleted
app/index.jschanged
app/html/nav.jsView
@@ -1,31 +1,0 @@
1-const nest = require('depnest')
2-const { h } = require('mutant')
3-
4-exports.gives = nest('app.html.nav')
5-
6-exports.needs = nest({
7- 'app.html.link': 'first',
8- 'history.sync.push': 'first',
9- 'history.sync.back': 'first'
10-})
11-
12-exports.create = (api) => {
13- return nest('app.html.nav', nav)
14-
15- function nav (id) {
16- const { push, back } = api.history.sync
17-
18- const goHome = () => push({page: 'home'})
19- // CHANGE THIS : zero history
20- const Link = api.app.html.link
21-
22- return h('Nav', [
23- h('div.back', { 'ev-click': back }, '←'),
24- h('div', { 'ev-click': goHome }, 'Home'),
25- Link({ page: 'settings' }, 'Settings'),
26- Link({ page: 'userFind' }, 'Find a User'),
27- h('a', { href: '%YRhFXmsAwipgyiwuHSP+EBr9fGjSqrMpWXUxgWcHxkM=.sha256' }, 'A Thread')
28- ])
29- }
30-}
31-
app/index.jsView
@@ -5,11 +5,9 @@
55 html: {
66 app: require('./html/app'),
77 thread: require('./html/thread'),
88 link: require('./html/link'),
9- nav: require('./html/nav'),
109 threadCard: require('./html/thread-card'),
11- nav: require('./html/nav'),
1210 },
1311 page: {
1412 channel: require('./page/channel'),
1513 error: require('./page/error'),
@@ -28,4 +26,6 @@
2826 }
2927
3028
3129
30+
31+

Built with git-ssb-web