mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-17 19:08:18 -07:00
17 lines
513 B
JavaScript
17 lines
513 B
JavaScript
define([], function () {
|
|
return function (options) {
|
|
|
|
var callback = function (result) {
|
|
|
|
if (result.buttonIndex == 1) {
|
|
options.callback(result.input1);
|
|
} else {
|
|
options.callback(null);
|
|
}
|
|
};
|
|
|
|
var buttonLabels = [Globalize.translate('ButtonOk'), Globalize.translate('ButtonCancel')];
|
|
|
|
navigator.notification.prompt(options.text, callback, options.title, buttonLabels, options.defaultText || '');
|
|
};
|
|
}); |