Files: 9e4b77aeb7181a93a9ee3ceb1c21d11841a35f57 / tmpl / tabs.part.js
598 bytesRaw
1 | function item (current, name, path, label) { |
2 | var cls = '' |
3 | if (current == name) |
4 | cls = 'class="current"' |
5 | return `<div ${cls}><a href="${path}" title="${label}">${label}</a></div>` |
6 | } |
7 | |
8 | module.exports = (c) => `<div class="tabs"> |
9 | ${item(c, 'basics', '/basics/install-the-database.html', 'Basics')} |
10 | ${item(c, 'social', '/social/social-network.html', 'Social')} |
11 | ${item(c, 'advanced', '/advanced/writing-applications.html', 'Advanced')} |
12 | ${item(c, 'whitepapers', '/whitepapers/secure-scuttlebutt.html', 'Whitepapers')} |
13 | ${item(c, 'modules', '/modules/ssb-client.html', 'Modules')} |
14 | </div>` |
Built with git-ssb-web