jellyfish-web/dashboard-ui/bower_components/emby-webcomponents/alert/nativealert.js
2018-10-23 01:05:09 +03:00

14 lines
No EOL
381 B
JavaScript

define([], function() {
"use strict";
function replaceAll(str, find, replace) {
return str.split(find).join(replace)
}
return function(options) {
"string" == typeof options && (options = {
text: options
});
var text = replaceAll(options.text || "", "<br/>", "\n");
return alert(text), Promise.resolve()
}
});