mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Fix suggestions
This commit is contained in:
parent
4fce7f8be5
commit
161488616f
1 changed files with 31 additions and 28 deletions
|
@ -98,13 +98,12 @@ function centerOnFocus(e, scrollSlider, horizontal) {
|
||||||
function centerOnFocusHorizontal(e) {
|
function centerOnFocusHorizontal(e) {
|
||||||
centerOnFocus(e, this, true);
|
centerOnFocus(e, this, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
function centerOnFocusVertical(e) {
|
function centerOnFocusVertical(e) {
|
||||||
centerOnFocus(e, this, false);
|
centerOnFocus(e, this, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
export default {
|
export const centerFocus = {
|
||||||
getPosition: getPosition,
|
|
||||||
centerFocus: {
|
|
||||||
on: function (element, horizontal) {
|
on: function (element, horizontal) {
|
||||||
if (horizontal) {
|
if (horizontal) {
|
||||||
dom.addEventListener(element, 'focus', centerOnFocusHorizontal, {
|
dom.addEventListener(element, 'focus', centerOnFocusHorizontal, {
|
||||||
|
@ -131,7 +130,11 @@ export default {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
|
|
||||||
|
export default {
|
||||||
|
getPosition: getPosition,
|
||||||
|
centerFocus: centerFocus,
|
||||||
toCenter: toCenter,
|
toCenter: toCenter,
|
||||||
toStart: toStart
|
toStart: toStart
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue