mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-18 11:28:23 -07:00
20 lines
388 B
JavaScript
20 lines
388 B
JavaScript
define([], function () {
|
|
|
|
return function (options) {
|
|
|
|
if (typeof options === 'string') {
|
|
options = {
|
|
title: '',
|
|
text: options
|
|
};
|
|
}
|
|
|
|
var result = confirm(options.text);
|
|
|
|
if (result) {
|
|
return Promise.resolve();
|
|
} else {
|
|
return Promise.reject();
|
|
}
|
|
};
|
|
}); |