summaryrefslogtreecommitdiff
path: root/ext/js/display/search-display-controller.js
diff options
context:
space:
mode:
authorJames Maa <jmaa@berkeley.edu>2024-05-31 08:06:52 -0700
committerGitHub <noreply@github.com>2024-05-31 15:06:52 +0000
commit76ca08bd59f0e8bfa1bb20ac813f48e7ab241265 (patch)
treebdba43d9ba704885383c7f308c6fe3f574c647c5 /ext/js/display/search-display-controller.js
parentb3f54747eb2694bdc90bce72e5532e99d374ef08 (diff)
Allow trailing commas in ESLint (#1013)
* Update comma-dangle rule * Fix dangling commas
Diffstat (limited to 'ext/js/display/search-display-controller.js')
-rw-r--r--ext/js/display/search-display-controller.js22
1 files changed, 11 insertions, 11 deletions
diff --git a/ext/js/display/search-display-controller.js b/ext/js/display/search-display-controller.js
index 62dbf343..8dad19d7 100644
--- a/ext/js/display/search-display-controller.js
+++ b/ext/js/display/search-display-controller.js
@@ -67,7 +67,7 @@ export class SearchDisplayController {
this._clipboardMonitorEnabled = false;
/** @type {import('clipboard-monitor').ClipboardReaderLike} */
this._clipboardReaderLike = {
- getText: this._display.application.api.clipboardGet.bind(this._display.application.api)
+ getText: this._display.application.api.clipboardGet.bind(this._display.application.api),
};
/** @type {ClipboardMonitor} */
this._clipboardMonitor = new ClipboardMonitor(this._clipboardReaderLike);
@@ -75,7 +75,7 @@ export class SearchDisplayController {
this._apiMap = createApiMap([
['searchDisplayControllerGetMode', this._onMessageGetMode.bind(this)],
['searchDisplayControllerSetMode', this._onMessageSetMode.bind(this)],
- ['searchDisplayControllerUpdateSearchQuery', this._onExternalSearchUpdate.bind(this)]
+ ['searchDisplayControllerUpdateSearchQuery', this._onExternalSearchUpdate.bind(this)],
]);
}
@@ -92,7 +92,7 @@ export class SearchDisplayController {
this._display.on('contentUpdateStart', this._onContentUpdateStart.bind(this));
this._display.hotkeyHandler.registerActions([
- ['focusSearchBox', this._onActionFocusSearchBox.bind(this)]
+ ['focusSearchBox', this._onActionFocusSearchBox.bind(this)],
]);
this._updateClipboardMonitorEnabled();
@@ -317,7 +317,7 @@ export class SearchDisplayController {
path: 'general.enableWanakana',
value,
scope: 'profile',
- optionsContext: this._display.getOptionsContext()
+ optionsContext: this._display.getOptionsContext(),
};
void this._display.application.api.modifySettings([modification], 'search');
}
@@ -358,7 +358,7 @@ export class SearchDisplayController {
path: 'profileCurrent',
value,
scope: 'global',
- optionsContext: null
+ optionsContext: null,
};
await this._display.application.api.modifySettings([modification], 'search');
}
@@ -477,7 +477,7 @@ export class SearchDisplayController {
path: 'clipboard.enableSearchPageMonitor',
value,
scope: 'profile',
- optionsContext: this._display.getOptionsContext()
+ optionsContext: this._display.getOptionsContext(),
};
await this._display.application.api.modifySettings([modification], 'search');
}
@@ -516,7 +516,7 @@ export class SearchDisplayController {
(granted) => {
const e = chrome.runtime.lastError;
resolve(!e && granted);
- }
+ },
);
});
}
@@ -543,20 +543,20 @@ export class SearchDisplayController {
focus: false,
historyMode,
params: {
- query
+ query,
},
state: {
focusEntry: 0,
optionsContext,
url,
sentence: {text: query, offset: 0},
- documentTitle
+ documentTitle,
},
content: {
dictionaryEntries: void 0,
animate,
- contentOrigin: {tabId, frameId}
- }
+ contentOrigin: {tabId, frameId},
+ },
};
if (!lookup) { details.params.lookup = 'false'; }
this._display.setContent(details);