Skip to content

Commit 13e529f

Browse files
committed
updated skip to to fix dialog naming bug
1 parent 2fa84d2 commit 13e529f

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

content/shared/js/skipto.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1664,18 +1664,18 @@ dialog button:hover {
16641664
this.dialogElem.close();
16651665
}
16661666

1667-
openDialog (content) {
1667+
openDialog (content, title) {
16681668
this.content = content;
16691669

16701670
if (content === 'shortcuts') {
16711671
this.shortcutContentElem.style.display = 'block';
16721672
this.aboutContentElem.style.display = 'none';
1673-
this.titleElem.textContent = 'Keyboard Shortcuts';
1673+
this.titleElem.textContent = title;
16741674
}
16751675
else {
16761676
this.shortcutContentElem.style.display = 'none';
16771677
this.aboutContentElem.style.display = 'block';
1678-
this.titleElem.textContent = 'About SkipTo.js';
1678+
this.titleElem.textContent = title;
16791679
}
16801680
this.dialogElem.showModal();
16811681
this.closeButtonElem2.focus();
@@ -5059,12 +5059,12 @@ dialog button:hover {
50595059
}
50605060

50615061
if (tgt.hasAttribute('data-shortcuts-info')) {
5062-
this.infoDialog.openDialog('shortcuts');
5062+
this.infoDialog.openDialog('shortcuts', this.config.shortcutsInfoLabel);
50635063
this.closePopup();
50645064
}
50655065

50665066
if (tgt.hasAttribute('data-about-info')) {
5067-
this.infoDialog.openDialog('about');
5067+
this.infoDialog.openDialog('about', this.config.aboutInfoLabel);
50685068
this.closePopup();
50695069
}
50705070

@@ -5336,11 +5336,11 @@ dialog button:hover {
53365336
shortcutRegionNavigation: 'n',
53375337
shortcutRegionComplementary: 'c',
53385338

5339+
shortcutsInfoLabel: 'Keyboard Shortcuts',
53395340
shortcutsGroupEnabledLabel: 'Shortcuts: Enabled',
53405341
shortcutsGroupDisabledLabel: 'Shortcuts: Disabled',
53415342
shortcutsToggleEnableLabel: 'Enable shortcuts',
53425343
shortcutsToggleDisableLabel: 'Disable shortcuts',
5343-
shortcutsInfoLabel: 'Shortcut Information',
53445344

53455345
aboutSupported: 'true',
53465346
aboutInfoLabel: `About SkipTo.js`,

0 commit comments

Comments
 (0)