style/guide: add js to get rid of styles
This commit is contained in:
parent
a2667dd551
commit
d7a9a55ad6
|
@ -2,7 +2,7 @@
|
|||
<?= $this->tabs ?>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="content styleguide">
|
||||
<h1>Header h1</h1>
|
||||
<h2>Header h2</h2>
|
||||
<h3>Header h3</h3>
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
|
||||
(function(Icinga) {
|
||||
|
||||
var Doc = function(module) {
|
||||
this.module = module;
|
||||
this.initialize();
|
||||
this.module.icinga.logger.debug('Doc module loaded');
|
||||
};
|
||||
|
||||
Doc.prototype = {
|
||||
|
||||
initialize: function()
|
||||
{
|
||||
this.module.on('rendered', this.rendered);
|
||||
this.module.icinga.logger.debug('Doc module initialized');
|
||||
},
|
||||
|
||||
rendered: function(event) {
|
||||
var $container = $(event.currentTarget);
|
||||
if ($('> .content.styleguide', $container).length) {
|
||||
$container.removeClass('module-doc');
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Icinga.availableModules.doc = Doc;
|
||||
|
||||
}(Icinga));
|
||||
|
Loading…
Reference in New Issue