Update Compass QoL Enhancer to 1.17.2
- Fix viewing wiki on /Communicate/SchoolDocumentation.aspx
This commit is contained in:
		
							parent
							
								
									728e07e816
								
							
						
					
					
						commit
						88315b095b
					
				| 
						 | 
					@ -2,7 +2,7 @@
 | 
				
			||||||
// @name        Compass QoL Enhancer
 | 
					// @name        Compass QoL Enhancer
 | 
				
			||||||
// @namespace   blankie-scripts
 | 
					// @namespace   blankie-scripts
 | 
				
			||||||
// @match       http*://*.compass.education/*
 | 
					// @match       http*://*.compass.education/*
 | 
				
			||||||
// @version     1.17.1
 | 
					// @version     1.17.2
 | 
				
			||||||
// @author      blankie
 | 
					// @author      blankie
 | 
				
			||||||
// @description A userscript that adds small but useful features for Compass, such as the ability to close windows by clicking on the background
 | 
					// @description A userscript that adds small but useful features for Compass, such as the ability to close windows by clicking on the background
 | 
				
			||||||
// @inject-into page
 | 
					// @inject-into page
 | 
				
			||||||
| 
						 | 
					@ -229,10 +229,12 @@ function wikiNodeSort(lhs, rhs) {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
let WikiBrowserPanel = getExtClass("Compass.widgets.WikiBrowserPanel");
 | 
					let WikiBrowserPanel = getExtClass("Compass.widgets.WikiBrowserPanel");
 | 
				
			||||||
if (WikiBrowserPanel) {
 | 
					if (WikiBrowserPanel) {
 | 
				
			||||||
    let original = WikiBrowserPanel.prototype.renderLayout;
 | 
					    let original = WikiBrowserPanel.prototype.initComponent;
 | 
				
			||||||
    WikiBrowserPanel.prototype.renderLayout = function() {
 | 
					    WikiBrowserPanel.prototype.initComponent = function() {
 | 
				
			||||||
        original.apply(this, arguments);
 | 
					        original.apply(this, arguments);
 | 
				
			||||||
        this.treePanel.store.sort({sorterFn: wikiNodeSort});
 | 
					        this.on("treeDataLoaded", function() {
 | 
				
			||||||
 | 
					            this.treePanel.store.sort({sorterFn: wikiNodeSort});
 | 
				
			||||||
 | 
					        });
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue