Fixes ESLint errors (#9668)

* fix: apply automatic eslint fixes

* lint: allow hashbang comment for tiddlywiki.js

* lint: first back of manual lint fixes for unused vars

* lint: added more fixes for unused vars

* lint: missed files

* lint: updated eslint config with selected rules from #9669
This commit is contained in:
Saq Imtiaz
2026-02-20 09:38:42 +01:00
committed by GitHub
parent 08f2b8bdf4
commit 785086e0a5
270 changed files with 3827 additions and 3970 deletions

View File

@@ -28,7 +28,6 @@ DynannotateWidget.prototype = new Widget();
Render this widget into the DOM
*/
DynannotateWidget.prototype.render = function(parent,nextSibling) {
var self = this;
this.parentDomNode = parent;
this.computeAttributes();
this.execute();
@@ -57,7 +56,7 @@ DynannotateWidget.prototype.render = function(parent,nextSibling) {
"class": "tc-dynannotation-wrapper",
children: [this.domContent,this.domAnnotations,this.domSnippets,this.domSearches],
document: this.document
})
});
parent.insertBefore(this.domWrapper,nextSibling);
this.domNodes.push(this.domWrapper);
// Apply the selection tracker data to the DOM
@@ -93,7 +92,7 @@ DynannotateWidget.prototype.execute = function() {
DynannotateWidget.prototype.isSnippetMode = function() {
return this.getAttribute("searchDisplay") === "snippet";
}
};
/*
Save the data attributes required by the selection tracker
@@ -202,8 +201,8 @@ DynannotateWidget.prototype.applyAnnotations = function() {
if(self.hasAttribute("popup")) {
$tw.popup.triggerPopup({
domNode: domOverlay,
title: self.getAttribute("popup"),
floating: self.getAttribute("floating"),
title: self.getAttribute("popup"),
floating: self.getAttribute("floating"),
wiki: self.wiki
});
}
@@ -261,8 +260,6 @@ DynannotateWidget.prototype.applySearch = function() {
this.removeSearch();
// Gather parameters
var searchString = this.getAttribute("search",""),
searchMode = this.getAttribute("searchMode"),
searchCaseSensitive = this.getAttribute("searchCaseSensitive","yes") === "yes",
searchMinLength = parseInt(this.getAttribute("searchMinLength","1"),10) || 1;
// Bail if search string too short
if(searchString.length < searchMinLength) {
@@ -301,11 +298,6 @@ DynannotateWidget.prototype.applySnippets = function() {
var textMap = new TextMap(this.domContent);
// Remove any previous snippets
this.removeSnippets();
// Gather parameters
var searchString = this.getAttribute("search",""),
searchMode = this.getAttribute("searchMode"),
searchCaseSensitive = this.getAttribute("searchCaseSensitive","yes") === "yes",
searchMinLength = parseInt(this.getAttribute("searchMinLength","1"),10) || 1;
// Build the map of the text content
var textMap = new TextMap(this.domContent);
// Search for the string