mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
fix sort menus
This commit is contained in:
parent
00b18fdc5f
commit
95d4c9bd78
4 changed files with 30 additions and 44 deletions
|
@ -32,14 +32,14 @@
|
||||||
"iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0"
|
"iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0"
|
||||||
},
|
},
|
||||||
"ignore": [],
|
"ignore": [],
|
||||||
"homepage": "https://github.com/polymerelements/paper-ripple",
|
"homepage": "https://github.com/PolymerElements/paper-ripple",
|
||||||
"_release": "1.0.5",
|
"_release": "1.0.5",
|
||||||
"_resolution": {
|
"_resolution": {
|
||||||
"type": "version",
|
"type": "version",
|
||||||
"tag": "v1.0.5",
|
"tag": "v1.0.5",
|
||||||
"commit": "d72e7a9a8ab518b901ed18dde492df3b87a93be5"
|
"commit": "d72e7a9a8ab518b901ed18dde492df3b87a93be5"
|
||||||
},
|
},
|
||||||
"_source": "git://github.com/polymerelements/paper-ripple.git",
|
"_source": "git://github.com/PolymerElements/paper-ripple.git",
|
||||||
"_target": "^1.0.0",
|
"_target": "^1.0.0",
|
||||||
"_originalSource": "polymerelements/paper-ripple"
|
"_originalSource": "PolymerElements/paper-ripple"
|
||||||
}
|
}
|
|
@ -131,15 +131,17 @@
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
dlg.classList.add('popupEditor');
|
if (options.size != 'auto') {
|
||||||
|
dlg.classList.add('popupEditor');
|
||||||
|
|
||||||
if (options.size == 'small') {
|
if (options.size == 'small') {
|
||||||
dlg.classList.add('small-paper-dialog');
|
dlg.classList.add('small-paper-dialog');
|
||||||
}
|
}
|
||||||
else if (options.size == 'medium') {
|
else if (options.size == 'medium') {
|
||||||
dlg.classList.add('medium-paper-dialog');
|
dlg.classList.add('medium-paper-dialog');
|
||||||
} else {
|
} else {
|
||||||
dlg.classList.add('fullscreen-paper-dialog');
|
dlg.classList.add('fullscreen-paper-dialog');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var theme = options.theme || 'b';
|
var theme = options.theme || 'b';
|
||||||
|
|
|
@ -105,8 +105,8 @@
|
||||||
}
|
}
|
||||||
document.body.appendChild(dlg);
|
document.body.appendChild(dlg);
|
||||||
|
|
||||||
// The animations flicker in IE and Firefox (probably wherever the polyfill is used)
|
// The animations flicker in IE
|
||||||
if (browserInfo.animate) {
|
if (!browserInfo.msie) {
|
||||||
dlg.animationConfig = {
|
dlg.animationConfig = {
|
||||||
// scale up
|
// scale up
|
||||||
'entry': {
|
'entry': {
|
||||||
|
|
|
@ -2831,31 +2831,12 @@
|
||||||
|
|
||||||
require(['components/paperdialoghelper', 'paper-dialog', 'paper-radio-button', 'paper-radio-group', 'scale-up-animation', 'fade-in-animation', 'fade-out-animation'], function (paperDialogHelper) {
|
require(['components/paperdialoghelper', 'paper-dialog', 'paper-radio-button', 'paper-radio-group', 'scale-up-animation', 'fade-in-animation', 'fade-out-animation'], function (paperDialogHelper) {
|
||||||
|
|
||||||
var dlg = document.createElement('paper-dialog');
|
var dlg = paperDialogHelper.createDialog({
|
||||||
|
removeOnClose: true,
|
||||||
dlg.setAttribute('with-backdrop', 'with-backdrop');
|
theme: 'a',
|
||||||
dlg.setAttribute('role', 'alertdialog');
|
size: 'auto',
|
||||||
|
modal: false
|
||||||
dlg.entryAnimation = 'fade-in-animation';
|
});
|
||||||
dlg.exitAnimation = 'fade-out-animation';
|
|
||||||
|
|
||||||
// The animations flicker in IE and Firefox (probably wherever the polyfill is used)
|
|
||||||
if (browserInfo.animate) {
|
|
||||||
dlg.animationConfig = {
|
|
||||||
// scale up
|
|
||||||
'entry': {
|
|
||||||
name: 'scale-up-animation',
|
|
||||||
node: dlg,
|
|
||||||
timing: { duration: 160, easing: 'ease-out' }
|
|
||||||
},
|
|
||||||
// fade out
|
|
||||||
'exit': {
|
|
||||||
name: 'fade-out-animation',
|
|
||||||
node: dlg,
|
|
||||||
timing: { duration: 200, easing: 'ease-in' }
|
|
||||||
}
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
var html = '';
|
var html = '';
|
||||||
|
|
||||||
|
@ -2902,11 +2883,14 @@
|
||||||
dlg.innerHTML = html;
|
dlg.innerHTML = html;
|
||||||
document.body.appendChild(dlg);
|
document.body.appendChild(dlg);
|
||||||
|
|
||||||
dlg.addEventListener('iron-overlay-closed', function () {
|
var fireCallbackOnClose = false;
|
||||||
dlg.parentNode.removeChild(dlg);
|
|
||||||
});
|
|
||||||
|
|
||||||
paperDialogHelper.open(dlg);
|
paperDialogHelper.open(dlg).then(function() {
|
||||||
|
|
||||||
|
if (options.callback && fireCallbackOnClose) {
|
||||||
|
options.callback();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
$('.groupSortBy', dlg).on('iron-select', function () {
|
$('.groupSortBy', dlg).on('iron-select', function () {
|
||||||
|
|
||||||
|
@ -2917,7 +2901,7 @@
|
||||||
options.query.StartIndex = 0;
|
options.query.StartIndex = 0;
|
||||||
|
|
||||||
if (options.callback && changed) {
|
if (options.callback && changed) {
|
||||||
options.callback();
|
fireCallbackOnClose = true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -2930,7 +2914,7 @@
|
||||||
options.query.StartIndex = 0;
|
options.query.StartIndex = 0;
|
||||||
|
|
||||||
if (options.callback && changed) {
|
if (options.callback && changed) {
|
||||||
options.callback();
|
fireCallbackOnClose = true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue