mirror of
https://github.com/seejohnrun/haste-server
synced 2025-08-21 04:23:09 -07:00
Center scrolled view
This commit is contained in:
parent
bd4a559d8b
commit
17fa8d400e
2 changed files with 2 additions and 2 deletions
|
@ -234,7 +234,7 @@ haste.prototype.loadDocument = function(key) {
|
||||||
const hash = window.location.hash.substring(1);
|
const hash = window.location.hash.substring(1);
|
||||||
highlightLine(hash)
|
highlightLine(hash)
|
||||||
document.getElementsByClassName("highlight")[0].scrollIntoView({
|
document.getElementsByClassName("highlight")[0].scrollIntoView({
|
||||||
behavior: 'auto',
|
behavior: 'smooth',
|
||||||
block: 'center'
|
block: 'center'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
2
static/application.min.js
vendored
2
static/application.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue