mirror of
https://github.com/kiwix/kiwix-js.git
synced 2025-09-22 12:01:15 -04:00
Small fix on hyperlinks inside an article, so that the content does not "scroll" by one line at the moment you click
This commit is contained in:
parent
3f8162e377
commit
796d67880d
@ -185,7 +185,6 @@ define(function(require) {
|
||||
/**
|
||||
* Handle key input in the prefix input zone
|
||||
* @param {type} evt
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function onKeyUpPrefix(evt) {
|
||||
// Use a timeout, so that very quick typing does not cause a lot of overhead
|
||||
@ -398,14 +397,14 @@ define(function(require) {
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function goToArticle(titleName) {
|
||||
$("#articleName").html(titleName);
|
||||
$("#readingArticle").show();
|
||||
localArchive.getTitleByName(titleName, function(title) {
|
||||
if (title == null) {
|
||||
if (title === null || title === undefined) {
|
||||
$("#readingArticle").hide();
|
||||
alert("Article with title " + titleName + " not found in the archive");
|
||||
}
|
||||
else {
|
||||
$("#articleName").html(titleName);
|
||||
$("#readingArticle").show();
|
||||
$("#articleContent").html("");
|
||||
readArticle(title);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user