update components

This commit is contained in:
Luke Pulverenti 2016-02-22 23:20:13 -05:00
parent 47a5078596
commit ecbff1ca26
12 changed files with 280 additions and 144 deletions

View file

@ -15,12 +15,12 @@
},
"devDependencies": {},
"ignore": [],
"version": "1.0.94",
"_release": "1.0.94",
"version": "1.0.95",
"_release": "1.0.95",
"_resolution": {
"type": "version",
"tag": "1.0.94",
"commit": "5a8fd76f8b8d8096f9aca548127e8d0c2bfe81f9"
"tag": "1.0.95",
"commit": "42219487ac4733e83807f9995433ec8485ad1c65"
},
"_source": "git://github.com/MediaBrowser/emby-webcomponents.git",
"_target": "~1.0.0",

View file

@ -1,5 +1,10 @@
define([], function () {
function replaceAll(str, find, replace) {
return str.split(find).join(replace);
}
return function (options) {
if (typeof options === 'string') {
@ -9,7 +14,8 @@ define([], function () {
};
}
var result = confirm(options.text);
var text = replaceAll(options.text || '', '<br/>', '\n');
var result = confirm(text);
if (result) {
return Promise.resolve();

View file

@ -1,5 +1,10 @@
define([], function () {
function replaceAll(str, find, replace) {
return str.split(find).join(replace);
}
return function (options) {
if (typeof options === 'string') {
@ -9,7 +14,9 @@ define([], function () {
};
}
var result = prompt(options.label || '', options.text || '');
var label = replaceAll(options.label || '', '<br/>', '\n');
var result = prompt(label, options.text || '');
if (result) {
return Promise.resolve(result);