pkp/immersion#134 Skip to content link not visible - adding SkipTo.JS component#159
Open
israelcefrin wants to merge 2 commits into
Open
pkp/immersion#134 Skip to content link not visible - adding SkipTo.JS component#159israelcefrin wants to merge 2 commits into
israelcefrin wants to merge 2 commits into
Conversation
kaitlinnewson
requested changes
Apr 14, 2026
kaitlinnewson
left a comment
Member
There was a problem hiding this comment.
Hi @israelcefrin, I've made a few suggestions here - let me know if anything is unclear!
| 'contexts' => 'backend-manageIssues', | ||
| ]); | ||
|
|
||
| HookRegistry::add('TemplateManager::display', [$this, 'addCustomHeader']); |
Member
There was a problem hiding this comment.
Rather than using the hook approach, I think you could instead add the js file path to gulpfile.js (under gulp.task('scripts', function()), then add the custom script here with something like:
$this->addScript(
'skip-to-js',
"var SkipToConfig = {
displayOption: 'popup',
landmarks: 'main search navigation header footer',
headings: ' h1 h2',
colorTheme: 'openweba11y',
highlightTarget: 'smooth'
};",
['inline' => true]
);... and then you could remove the addCustomHeader function below as well.
By adding it to the gulp file, it's included in the build packages (see the README with more info about that if needed).
Member
There was a problem hiding this comment.
This can be replaced with the minified version and moved to resources/dist/js.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixing the "skip to" hidden menu adding an open source Skipto.JS component to fix it.
This component has been already presented by @Godoy0722 to the Dev team for the ORE project.
Issue: #134