aboutsummaryrefslogtreecommitdiff
path: root/ext/fg/js/frame.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/fg/js/frame.js')
-rw-r--r--ext/fg/js/frame.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/fg/js/frame.js b/ext/fg/js/frame.js
index 339958f2..9c4b9318 100644
--- a/ext/fg/js/frame.js
+++ b/ext/fg/js/frame.js
@@ -18,7 +18,7 @@
function registerKanjiLinks() {
- for (const link of [].slice.call(document.getElementsByClassName('kanji-link'))) {
+ for (let link of [].slice.call(document.getElementsByClassName('kanji-link'))) {
link.addEventListener('click', (e) => {
e.preventDefault();
window.parent.postMessage({action: 'displayKanji', params: e.target.innerHTML}, '*');
@@ -27,7 +27,7 @@ function registerKanjiLinks() {
}
function registerAddNoteLinks() {
- for (const link of [].slice.call(document.getElementsByClassName('action-add-note'))) {
+ for (let link of [].slice.call(document.getElementsByClassName('action-add-note'))) {
link.addEventListener('click', (e) => {
e.preventDefault();
const ds = e.currentTarget.dataset;
@@ -37,7 +37,7 @@ function registerAddNoteLinks() {
}
function registerPronounceLinks() {
- for (const link of [].slice.call(document.getElementsByClassName('action-pronounce'))) {
+ for (let link of [].slice.call(document.getElementsByClassName('action-pronounce'))) {
link.addEventListener('click', (e) => {
e.preventDefault();
const ds = e.currentTarget.dataset;
@@ -60,7 +60,7 @@ function onMessage(e) {
}
function api_setActionState({index, state, sequence}) {
- for (const mode in state) {
+ for (let mode in state) {
const matches = document.querySelectorAll(`.action-bar[data-sequence="${sequence}"] .action-add-note[data-index="${index}"][data-mode="${mode}"]`);
if (matches.length === 0) {
return;