Some modernizations.
[redakcja.git] / src / redakcja / static / js / wiki / view_sidebar.js
diff --git a/src/redakcja/static/js/wiki/view_sidebar.js b/src/redakcja/static/js/wiki/view_sidebar.js
new file mode 100644 (file)
index 0000000..e9e712b
--- /dev/null
@@ -0,0 +1,18 @@
+(function($) {
+
+    class SidebarPerspective extends $.wiki.Perspective {
+        constructor(options) {
+            super(options);
+            this.noupdate_hash_onenter = true;
+        }
+
+        onEnter(success, failure) {
+            super.onEnter();
+
+            $('#vsplitbar').not('.active').trigger('click');
+            $(".vsplitbar-title").text(this.vsplitbar);
+        }
+    }
+    $.wiki.SidebarPerspective = SidebarPerspective;
+
+})(jQuery);