git ssb

16+

Dominic / patchbay



Tree: 07678ab95020edf09925a491966765d79e086d0e

Files: 07678ab95020edf09925a491966765d79e086d0e / modules_basic / scroller.js

607 bytesRaw
1const fs = require('fs')
2const h = require('../h')
3
4exports.gives = {
5 build_scroller: true,
6 mcss: true
7}
8
9exports.create = function (api) {
10 return {
11 build_scroller,
12 mcss: () => fs.readFileSync(__filename.replace(/js$/, 'mcss'), 'utf8')
13 }
14
15 function build_scroller ({ prepend = [], append = [] } = {}) {
16 const content = h('section.content')
17
18 const container = h('Scroller', { style: { overflow: 'auto' } }, [
19 h('div.wrapper', [
20 h('header', prepend),
21 content,
22 h('footer', append)
23 ])
24 ])
25
26 return {
27 content,
28 container
29 }
30 }
31}
32
33

Built with git-ssb-web