hero helper added.
parent
dce7898af3
commit
31ec459db3
7
bulma.js
7
bulma.js
|
@ -88,6 +88,11 @@
|
||||||
? h('div.container', innerNavbar())
|
? h('div.container', innerNavbar())
|
||||||
: innerNavbar()]);
|
: innerNavbar()]);
|
||||||
},
|
},
|
||||||
navbarItem: alias('a.navbar-item')
|
navbarItem: alias('a.navbar-item'),
|
||||||
|
hero: function(args){
|
||||||
|
var head, body, footer;
|
||||||
|
args || (args = {});
|
||||||
|
return h('div.hero', args, [(head = args.head) ? h('div.hero-head', head) : void 8, (body = args.body) ? h('div.hero-body', body) : void 8, (footer = args.footer) ? h('div.hero-footer', footer) : void 8]);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}).call(this);
|
}).call(this);
|
||||||
|
|
14
bulma.ls
14
bulma.ls
|
@ -112,5 +112,19 @@ module.exports = {
|
||||||
|
|
||||||
]
|
]
|
||||||
navbar-item: alias \a.navbar-item
|
navbar-item: alias \a.navbar-item
|
||||||
|
|
||||||
|
hero: (args) ->
|
||||||
|
args or= {}
|
||||||
|
|
||||||
|
h \div.hero args, [
|
||||||
|
if head = args.head
|
||||||
|
h \div.hero-head head
|
||||||
|
|
||||||
|
if body = args.body
|
||||||
|
h \div.hero-body body
|
||||||
|
|
||||||
|
if footer = args.footer
|
||||||
|
h \div.hero-footer footer
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue