X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/c6c257380f1ff975db6a54e96f3ab2a34aa166c2..119bbb84ddb0e54bb3ffadda2df1920f45655ad5:/src/redakcja/static/js/wiki/base.js diff --git a/src/redakcja/static/js/wiki/base.js b/src/redakcja/static/js/wiki/base.js index 5262ab72..b4fee85f 100644 --- a/src/redakcja/static/js/wiki/base.js +++ b/src/redakcja/static/js/wiki/base.js @@ -104,6 +104,15 @@ return this.perspectives[ $(tab).attr('id')]; } + $.wiki.exitTab = function(tab){ + var self = this; + var $tab = $(tab); + if (!('.active', $tab)) return; + $('.active', $tab).removeClass('active'); + self.perspectives[$tab.attr('id')].onExit(); + $('#' + $tab.attr('data-ui-related')).hide(); + } + $.wiki.switchToTab = function(tab){ var self = this; var $tab = $(tab);