Version 4.7.0
This commit is contained in:
1 parent
517a5e1f70
commit
8ba7d43898
1933 files changed
+65613
-11332
No files matched your search
Binary file not shown.
@@ -1,2 +1,2 @@
|
||||
// German (de)
|
||||
plupload.addI18n({"Stop Upload":"Hochladen stoppen","Upload URL might be wrong or doesn't exist.":"Upload-URL ist falsch oder existiert nicht.","tb":"TB","Size":"Größe","Close":"Schließen","You must specify either browse_button or drop_element.":"","Init error.":"Initialisierungsfehler","Add files to the upload queue and click the start button.":"Dateien hinzufügen und auf 'Hochladen' klicken.","List":"","Filename":"Dateiname","%s specified, but cannot be found.":"","Image format either wrong or not supported.":"Bildformat falsch oder nicht unterstützt.","Status":"Status","HTTP Error.":"HTTP-Fehler","Start Upload":"Hochladen beginnen","Error: File too large:":"Fehler: Datei zu groß:","kb":"KB","Duplicate file error.":"Datei bereits hochgeladen","File size error.":"Fehler bei Dateigröße","N/A":"Nicht verfügbar","gb":"GB","Error: Invalid file extension:":"Fehler: Ungültige Dateiendung:","Select files":"Dateien auswählen","%s already present in the queue.":"%s ist bereits in der Warteschlange","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"","File: %s":"Datei: %s","b":"B","Uploaded %d/%d files":"%d/%d Dateien wurden hochgeladen","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Pro Durchgang können nur %d Datei(en) akzeptiert werden. Überzählige Dateien wurden ignoriert.","%d files queued":"%d Dateien in der Warteschlange","File: %s, size: %d, max file size: %d":"Datei: %s, Größe: %d, maximale Dateigröße: %d","Thumbnails":"","Drag files here.":"Dateien hier hin ziehen.","Runtime ran out of available memory.":"Nicht genügend Speicher verfügbar.","File count error.":"Fehlerhafte Dateianzahl.","File extension error.":"Fehler bei Dateiendung","mb":"MB","Add Files":"Dateien hinzufügen"});
|
||||
plupload.addI18n({"Stop Upload":"Hochladen abbrechen","Upload URL might be wrong or doesn't exist.":"Upload-URL ist falsch oder existiert nicht.","tb":"TB","Size":"Größe","Close":"Schließen","You must specify either browse_button or drop_element.":"","Init error.":"Initialisierungsfehler","Add files to the upload queue and click the start button.":"Dateien hinzufügen und auf 'Hochladen' klicken.","List":"Liste","Filename":"Dateiname","%s specified, but cannot be found.":"","Image format either wrong or not supported.":"Bildformat falsch oder nicht unterstützt.","Status":"Status","HTTP Error.":"HTTP-Fehler","Start Upload":"Hochladen beginnen","Error: File too large:":"Fehler: Datei zu groß:","kb":"KB","Duplicate file error.":"Datei bereits hochgeladen","File size error.":"Fehler bei Dateigröße","N/A":"Nicht verfügbar","gb":"GB","Error: Invalid file extension:":"Fehler: Ungültige Dateiendung:","Select files":"Dateien auswählen","%s already present in the queue.":"%s ist bereits in der Warteschlange","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"","File: %s":"Datei: %s","b":"B","Uploaded %d/%d files":"%d/%d Dateien wurden hochgeladen","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Pro Durchgang können nur %d Datei(en) akzeptiert werden. Überzählige Dateien wurden ignoriert.","%d files queued":"%d Dateien in der Warteschlange","File: %s, size: %d, max file size: %d":"Datei: %s, Größe: %d, maximale Dateigröße: %d","Thumbnails":"Vorschaubilder","Drag files here.":"Dateien auf diese Fläche bewegen.","Runtime ran out of available memory.":"Nicht genügend Speicher verfügbar.","File count error.":"Fehlerhafte Dateianzahl.","File extension error.":"Fehler bei Dateiendung","mb":"MB","Add Files":"Dateien hinzufügen"});
|
||||
Whitespace-only changes.
@@ -1,2 +1,2 @@
|
||||
// Latvian (lv)
|
||||
plupload.addI18n({"Stop Upload":"Apturēt augšupielādi","Upload URL might be wrong or doesn't exist.":"Augšupielādes saite neeksistē vai ir nepareiza.","tb":"terabaiti","Size":"Izmērs","Close":"Aizvērt","You must specify either browse_button or drop_element.":"","Init error.":"Inicializācijas kļūda.","Add files to the upload queue and click the start button.":"Pievienojiet failus rindai un klikšķiniet uz pogas \"Sākt augšupielādi\".","List":"","Filename":"Faila nosaukums","%s specified, but cannot be found.":"","Image format either wrong or not supported.":"Attēla formāts ir nepareizs vai arī netiek atbalstīts.","Status":"Statuss","HTTP Error.":"HTTP kļūda.","Start Upload":"Sākt augšupielādi","Error: File too large:":"Kļūda: Fails pārāk liels:","kb":"kilobaiti","Duplicate file error.":"Atkārtota faila kļūda","File size error.":"Faila izmēra kļūda.","N/A":"N/A","gb":"gigabaiti","Error: Invalid file extension:":"Kļūda: Nepareizs faila paplašinājums:","Select files":"Izvēlieties failus","%s already present in the queue.":"%s jau ir atrodams rindā.","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"","File: %s":"Fails: %s","b":"baiti","Uploaded %d/%d files":"Augšupielādēti %d/%d faili","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Iespējams ielādēt tikai %d failus vienā reizē. Atlikušie faili netika pievienoti","%d files queued":"%d faili pievienoti rindai","File: %s, size: %d, max file size: %d":"Fails: %s, izmērs: %d, max faila izmērs: %d","Thumbnails":"","Drag files here.":"Ievelciet failus šeit","Runtime ran out of available memory.":"Pietrūkst izmantojamās atmiņas.","File count error.":"Failu skaita kļūda","File extension error.":"Faila paplašinājuma kļūda.","mb":"megabaiti","Add Files":"Pievienot failus"});
|
||||
plupload.addI18n({"Stop Upload":"Apturēt augšupielādi","Upload URL might be wrong or doesn't exist.":"Augšupielādes saite neeksistē vai ir nepareiza.","tb":"terabaiti","Size":"Izmērs","Close":"Aizvērt","You must specify either browse_button or drop_element.":"Jums ir jānorāda vainu browse_button vai drop_element.","Init error.":"Inicializācijas kļūda.","Add files to the upload queue and click the start button.":"Pievienojiet failus rindai un klikšķiniet uz pogas \"Sākt augšupielādi\".","List":"Saraksts","Filename":"Faila nosaukums","%s specified, but cannot be found.":"%s norādīts, bet nevar tikt atrasts.","Image format either wrong or not supported.":"Attēla formāts ir nepareizs vai arī netiek atbalstīts.","Status":"Statuss","HTTP Error.":"HTTP kļūda.","Start Upload":"Sākt augšupielādi","Error: File too large:":"Kļūda: Fails pārāk liels:","kb":"kilobaiti","Duplicate file error.":"Atkārtota faila kļūda","File size error.":"Faila izmēra kļūda.","N/A":"N/A","gb":"gigabaiti","Error: Invalid file extension:":"Kļūda: Nepareizs faila paplašinājums:","Select files":"Izvēlieties failus","%s already present in the queue.":"%s jau ir atrodams rindā.","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"Izšķirtspēja ārpus robežām! <b>%s</b> atbalsta attēlus tikai līdz %wx%hpx","File: %s":"Fails: %s","b":"baiti","Uploaded %d/%d files":"Augšupielādēti %d/%d faili","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Iespējams ielādēt tikai %d failus vienā reizē. Atlikušie faili netika pievienoti","%d files queued":"%d faili pievienoti rindai","File: %s, size: %d, max file size: %d":"Fails: %s, izmērs: %d, max faila izmērs: %d","Thumbnails":"Ikonas","Drag files here.":"Ievelciet failus šeit","Runtime ran out of available memory.":"Pietrūkst izmantojamās atmiņas.","File count error.":"Failu skaita kļūda","File extension error.":"Faila paplašinājuma kļūda.","mb":"megabaiti","Add Files":"Pievienot failus"});
|
||||
@@ -1,2 +1,2 @@
|
||||
// Russian (ru)
|
||||
plupload.addI18n({"Stop Upload":"Остановить Загрузку","Upload URL might be wrong or doesn't exist.":"Адрес заргузки неправильный или он не существует.","tb":"тб","Size":"Размер","Close":"Закрыть","You must specify either browse_button or drop_element.":"Вы должны указать browse_button или drop_element.","Init error.":"Ошибка инициализации.","Add files to the upload queue and click the start button.":"Добавьте файлы в очередь и нажмите кнопку \"Загрузить файлы\".","List":"Список","Filename":"Имя файла","%s specified, but cannot be found.":"","Image format either wrong or not supported.":"Формат картинки неправильный или он не поддерживается.","Status":"Статус","HTTP Error.":"Ошибка HTTP.","Start Upload":"Начать загрузку","Error: File too large:":"Ошибка: Файл слишком большой:","kb":"кб","Duplicate file error.":"Такой файл уже присутствует в очереди.","File size error.":"Неправильный размер файла.","N/A":"N/A","gb":"гб","Error: Invalid file extension:":"Ошибка: У файла неправильное расширение:","Select files":"Выберите файлы","%s already present in the queue.":"%s уже присутствует в очереди.","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"","File: %s":"Файл: %s","b":"б","Uploaded %d/%d files":"Загружено %d/%d файлов","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Загрузочный элемент за раз принимает только %d файл(ов). Лишние файлы были отброшены.","%d files queued":"В очереди %d файл(ов)","File: %s, size: %d, max file size: %d":"Файл: %s, размер: %d, макс. размер файла: %d","Thumbnails":"Хлебные крошки","Drag files here.":"Перетащите файлы сюда.","Runtime ran out of available memory.":"Рабочая среда превысила лимит достуной памяти.","File count error.":"Слишком много файлов.","File extension error.":"Неправильное расширение файла.","mb":"мб","Add Files":"Добавьте файлы"});
|
||||
plupload.addI18n({"Stop Upload":"Остановить Загрузку","Upload URL might be wrong or doesn't exist.":"Адрес заргузки неправильный или он не существует.","tb":"тб","Size":"Размер","Close":"Закрыть","You must specify either browse_button or drop_element.":"Вы должны указать browse_button или drop_element.","Init error.":"Ошибка инициализации.","Add files to the upload queue and click the start button.":"Добавьте файлы в очередь и нажмите кнопку \"Загрузить файлы\".","List":"Список","Filename":"Имя файла","%s specified, but cannot be found.":"%s существует, но не может быть найден.","Image format either wrong or not supported.":"Формат картинки неправильный или он не поддерживается.","Status":"Статус","HTTP Error.":"Ошибка HTTP.","Start Upload":"Начать загрузку","Error: File too large:":"Ошибка: Файл слишком большой:","kb":"кб","Duplicate file error.":"Такой файл уже присутствует в очереди.","File size error.":"Неправильный размер файла.","N/A":"N/A","gb":"гб","Error: Invalid file extension:":"Ошибка: У файла неправильное расширение:","Select files":"Выберите файлы","%s already present in the queue.":"%s уже присутствует в очереди.","Resoultion out of boundaries! <b>%s</b> runtime supports images only up to %wx%hpx.":"Слишком большое разрешение! <b>%s</b> поддерживаются изображения с размером не более %wx%hpx","File: %s":"Файл: %s","b":"б","Uploaded %d/%d files":"Загружено %d/%d файлов","Upload element accepts only %d file(s) at a time. Extra files were stripped.":"Загрузочный элемент за раз принимает только %d файл(ов). Лишние файлы были отброшены.","%d files queued":"В очереди %d файл(ов)","File: %s, size: %d, max file size: %d":"Файл: %s, размер: %d, макс. размер файла: %d","Thumbnails":"Миниатюра","Drag files here.":"Перетащите файлы сюда.","Runtime ran out of available memory.":"Рабочая среда превысила лимит достуной памяти.","File count error.":"Слишком много файлов.","File extension error.":"Неправильное расширение файла.","mb":"мб","Add Files":"Добавьте файлы"});
|
||||
Whitespace-only changes.
Whitespace-only changes.
Whitespace-only changes.
@@ -223,7 +223,7 @@ used as it is.
|
||||
|
||||
fileList.append(
|
||||
'<li id="' + file.id + '">' +
|
||||
'<div class="plupload_file_name"><span>' + file.name + '</span></div>' +
|
||||
'<div class="plupload_file_name"><span>' + plupload.xmlEncode(file.name) + '</span></div>' +
|
||||
'<div class="plupload_file_action"><a href="#"></a></div>' +
|
||||
'<div class="plupload_file_status">' + file.percent + '%</div>' +
|
||||
'<div class="plupload_file_size">' + plupload.formatSize(file.size) + '</div>' +
|
||||
@@ -306,7 +306,7 @@ used as it is.
|
||||
|
||||
// Rename file and glue extension back on
|
||||
file.name = targetInput.val() + ext;
|
||||
targetSpan.html(file.name);
|
||||
targetSpan.text(file.name);
|
||||
targetInput.blur();
|
||||
}
|
||||
});
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
!function(e,t){function i(e){return t.translate(e)||e}function s(t,s){s.contents().each(function(t,i){i=e(i),i.is(".plupload")||i.remove()}),s.prepend('<div class="plupload_wrapper plupload_scroll"><div id="'+t+'_container" class="plupload_container">'+'<div class="plupload">'+'<div class="plupload_header">'+'<div class="plupload_header_content">'+'<div class="plupload_header_title">'+i("Select files")+"</div>"+'<div class="plupload_header_text">'+i("Add files to the upload queue and click the start button.")+"</div>"+"</div>"+"</div>"+'<div class="plupload_content">'+'<div class="plupload_filelist_header">'+'<div class="plupload_file_name">'+i("Filename")+"</div>"+'<div class="plupload_file_action"> </div>'+'<div class="plupload_file_status"><span>'+i("Status")+"</span></div>"+'<div class="plupload_file_size">'+i("Size")+"</div>"+'<div class="plupload_clearer"> </div>'+"</div>"+'<ul id="'+t+'_filelist" class="plupload_filelist"></ul>'+'<div class="plupload_filelist_footer">'+'<div class="plupload_file_name">'+'<div class="plupload_buttons">'+'<a href="#" class="plupload_button plupload_add" id="'+t+'_browse">'+i("Add Files")+"</a>"+'<a href="#" class="plupload_button plupload_start">'+i("Start Upload")+"</a>"+"</div>"+'<span class="plupload_upload_status"></span>'+"</div>"+'<div class="plupload_file_action"></div>'+'<div class="plupload_file_status"><span class="plupload_total_status">0%</span></div>'+'<div class="plupload_file_size"><span class="plupload_total_file_size">0 b</span></div>'+'<div class="plupload_progress">'+'<div class="plupload_progress_container">'+'<div class="plupload_progress_bar"></div>'+"</div>"+"</div>"+'<div class="plupload_clearer"> </div>'+"</div>"+"</div>"+"</div>"+"</div>"+'<input type="hidden" id="'+t+'_count" name="'+t+'_count" value="0" />'+"</div>")}var l={};e.fn.pluploadQueue=function(a){return a?(this.each(function(){function n(i){var s;i.status==t.DONE&&(s="plupload_done"),i.status==t.FAILED&&(s="plupload_failed"),i.status==t.QUEUED&&(s="plupload_delete"),i.status==t.UPLOADING&&(s="plupload_uploading");var l=e("#"+i.id).attr("class",s).find("a").css("display","block");i.hint&&l.attr("title",i.hint)}function o(){e("span.plupload_total_status",p).html(u.total.percent+"%"),e("div.plupload_progress_bar",p).css("width",u.total.percent+"%"),e("span.plupload_upload_status",p).html(t.sprintf(i("Uploaded %d/%d files"),u.total.uploaded,u.files.length))}function r(){var s,l=e("ul.plupload_filelist",p).html(""),a=0;e.each(u.files,function(i,o){s="",o.status==t.DONE&&(o.target_name&&(s+='<input type="hidden" name="'+c+"_"+a+'_tmpname" value="'+t.xmlEncode(o.target_name)+'" />'),s+='<input type="hidden" name="'+c+"_"+a+'_name" value="'+t.xmlEncode(o.name)+'" />',s+='<input type="hidden" name="'+c+"_"+a+'_status" value="'+(o.status==t.DONE?"done":"failed")+'" />',a++,e("#"+c+"_count").val(a)),l.append('<li id="'+o.id+'">'+'<div class="plupload_file_name"><span>'+o.name+"</span></div>"+'<div class="plupload_file_action"><a href="#"></a></div>'+'<div class="plupload_file_status">'+o.percent+"%</div>"+'<div class="plupload_file_size">'+t.formatSize(o.size)+"</div>"+'<div class="plupload_clearer"> </div>'+s+"</li>"),n(o),e("#"+o.id+".plupload_delete a").click(function(t){e("#"+o.id).remove(),u.removeFile(o),t.preventDefault()})}),e("span.plupload_total_file_size",p).html(t.formatSize(u.total.size)),0===u.total.queued?e("span.plupload_add_text",p).html(i("Add Files")):e("span.plupload_add_text",p).html(t.sprintf(i("%d files queued"),u.total.queued)),e("a.plupload_start",p).toggleClass("plupload_disabled",u.files.length==u.total.uploaded+u.total.failed),l[0].scrollTop=l[0].scrollHeight,o(),!u.files.length&&u.features.dragdrop&&u.settings.dragdrop&&e("#"+c+"_filelist").append('<li class="plupload_droptext">'+i("Drag files here.")+"</li>")}function d(){delete l[c],u.destroy(),p.html(_),u=p=_=null}var u,p,c,_;p=e(this),c=p.attr("id"),c||(c=t.guid(),p.attr("id",c)),_=p.html(),s(c,p),a=e.extend({dragdrop:!0,browse_button:c+"_browse",container:c},a),a.dragdrop&&(a.drop_element=c+"_filelist"),u=new t.Uploader(a),l[c]=u,u.bind("UploadFile",function(t,i){e("#"+i.id).addClass("plupload_current_file")}),u.bind("Init",function(t,i){!a.unique_names&&a.rename&&p.on("click","#"+c+"_filelist div.plupload_file_name span",function(i){var s,l,a,n=e(i.target),o="",r=n.closest("li");r.hasClass("plupload_delete")&&(s=t.getFile(n.parents("li")[0].id),a=s.name,l=/^(.+)(\.[^.]+)$/.exec(a),l&&(a=l[1],o=l[2]),n.hide().after('<input type="text" />'),n.next().val(a).focus().blur(function(){n.show().next().remove()}).keydown(function(t){var i=e(this);13==t.keyCode&&(t.preventDefault(),s.name=i.val()+o,n.html(s.name),i.blur())}))}),e("#"+c+"_container").attr("title","Using runtime: "+i.runtime),e("a.plupload_start",p).click(function(t){e(this).hasClass("plupload_disabled")||u.start(),t.preventDefault()}),e("a.plupload_stop",p).click(function(e){e.preventDefault(),u.stop()}),e("a.plupload_start",p).addLine truncated
|
||||
!function (e, t) { function i(e) { return t.translate(e) || e } function s(t, s) { s.contents().each(function (t, i) { i = e(i), i.is(".plupload") || i.remove() }), s.prepend('<div class="plupload_wrapper plupload_scroll"><div id="' + t + '_container" class="plupload_container">' + '<div class="plupload">' + '<div class="plupload_header">' + '<div class="plupload_header_content">' + '<div class="plupload_header_title">' + i("Select files") + "</div>" + '<div class="plupload_header_text">' + i("Add files to the upload queue and click the start button.") + "</div>" + "</div>" + "</div>" + '<div class="plupload_content">' + '<div class="plupload_filelist_header">' + '<div class="plupload_file_name">' + i("Filename") + "</div>" + '<div class="plupload_file_action"> </div>' + '<div class="plupload_file_status"><span>' + i("Status") + "</span></div>" + '<div class="plupload_file_size">' + i("Size") + "</div>" + '<div class="plupload_clearer"> </div>' + "</div>" + '<ul id="' + t + '_filelist" class="plupload_filelist"></ul>' + '<div class="plupload_filelist_footer">' + '<div class="plupload_file_name">' + '<div class="plupload_buttons">' + '<a href="#" class="plupload_button plupload_add" id="' + t + '_browse">' + i("Add Files") + "</a>" + '<a href="#" class="plupload_button plupload_start">' + i("Start Upload") + "</a>" + "</div>" + '<span class="plupload_upload_status"></span>' + "</div>" + '<div class="plupload_file_action"></div>' + '<div class="plupload_file_status"><span class="plupload_total_status">0%</span></div>' + '<div class="plupload_file_size"><span class="plupload_total_file_size">0 b</span></div>' + '<div class="plupload_progress">' + '<div class="plupload_progress_container">' + '<div class="plupload_progress_bar"></div>' + "</div>" + "</div>" + '<div class="plupload_clearer"> </div>' + "</div>" + "</div>" + "</div>" + "</div>" + '<input type="hidden" id="' + t + '_count" name="' + t + '_count" value="0" />' + "</div>") } var l = {}; e.fn.pluploadQueue = function (a) { return a ? (this.each(function () { function n(i) { var s; i.status == t.DONE && (s = "plupload_done"), i.status == t.FAILED && (s = "plupload_failed"), i.status == t.QUEUED && (s = "plupload_delete"), i.status == t.UPLOADING && (s = "plupload_uploading"); var l = e("#" + i.id).attr("class", s).find("a").css("display", "block"); i.hint && l.attr("title", i.hint) } function o() { e("span.plupload_total_status", p).html(u.total.percent + "%"), e("div.plupload_progress_bar", p).css("width", u.total.percent + "%"), e("span.plupload_upload_status", p).html(t.sprintf(i("Uploaded %d/%d files"), u.total.uploaded, u.files.length)) } function r() { var s, l = e("ul.plupload_filelist", p).html(""), a = 0; e.each(u.files, function (i, o) { s = "", o.status == t.DONE && (o.target_name && (s += '<input type="hidden" name="' + c + "_" + a + '_tmpname" value="' + t.xmlEncode(o.target_name) + '" />'), s += '<input type="hidden" name="' + c + "_" + a + '_name" value="' + t.xmlEncode(o.name) + '" />', s += '<input type="hidden" name="' + c + "_" + a + '_status" value="' + (o.status == t.DONE ? "done" : "failed") + '" />', a++, e("#" + c + "_count").val(a)), l.append('<li id="' + o.id + '">' + '<div class="plupload_file_name"><span>' + t.xmlEncode(o.name) + "</span></div>" + '<div class="plupload_file_action"><a href="#"></a></div>' + '<div class="plupload_file_status">' + o.percent + "%</div>" + '<div class="plupload_file_size">' + t.formatSize(o.size) + "</div>" + '<div class="plupload_clearer"> </div>' + s + "</li>"), n(o), e("#" + o.id + ".plupload_delete a").click(function (t) { e("#" + o.id).remove(), u.removeFile(o), t.preventDefault() }) }), e("span.plupload_total_file_size", p).html(t.formatSize(u.total.size)), 0 === u.total.queued ? e("span.plupload_add_text", p).html(i("Add Files")) : e("span.plupload_add_text", p).html(t.sprintf(i("%d files queued"), u.total.queued)), e("a.plupload_start", p).toggleClass("plupload_disabled", u.files.length == u.total.uploaded + u.total.failed), l[0].scrollTop = l[0].scrollHeight, o(), !u.files.length && u.features.dragdrop && u.settings.dragdrop && e("#" + c + "_filelist").append('<li class="plupload_droptext">' + i("Drag files here.") + "</li>") } function d() { delete l[c], u.destroy(), p.html(_), u = p = _ = null } var u, p, c, _; p = e(this), c = p.attr("id"), c || (c = t.guid(), p.attr("id", c)), _ = p.html(), s(c, p), a = e.extend({ dragdrop: !0, browse_button: c + "_browse", container: c }, a), a.dragdrop && (a.drop_element = c + "_filelist"), u = new t.Uploader(a), l[c] = u, u.bind("UploadFile", function (t, i) { e("#" + i.id).addClass("plupload_current_file") }), u.bind("Init", function (t, i) { !a.unique_names && a.rename && p.on("click", "#" + c + "_filelist div.plupload_file_name span", function (i) { var s, l, a, n = e(i.target), o = "", r = n.closest("li"); r.hasClass("plupload_delete") && (s = t.getFile(n.parents("li")[0].id), a = s.name, l = /^(.+)(\.[^.]+)$/.exec(a), l
Line truncated
|
||||
Whitespace-only changes.
+19
-15
@@ -28,10 +28,10 @@
|
||||
.plupload_file {border-width: 0 0 1px 0}
|
||||
.plupload_container .plupload_header {border-width: 0 0 1px 0; position: relative;}
|
||||
|
||||
.plupload_delete .ui-icon,
|
||||
.plupload_delete .ui-icon,
|
||||
.plupload_done .ui-icon,
|
||||
.plupload_failed .ui-icon {
|
||||
cursor:pointer;
|
||||
cursor:pointer;
|
||||
}
|
||||
|
||||
.plupload_header_content {
|
||||
@@ -144,7 +144,7 @@
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.plupload_buttons {
|
||||
.plupload_buttons {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
@@ -160,7 +160,7 @@
|
||||
_clear: left;
|
||||
}
|
||||
|
||||
.plupload_view_list div.plupload_file_size,
|
||||
.plupload_view_list div.plupload_file_size,
|
||||
.plupload_view_list div.plupload_file_status,
|
||||
.plupload_view_list div.plupload_file_action {
|
||||
padding: 8px 6px;
|
||||
@@ -187,11 +187,11 @@
|
||||
margin-left: -2px;
|
||||
}
|
||||
|
||||
.plupload_view_list .plupload_file_size,
|
||||
.plupload_view_list .plupload_file_size,
|
||||
.plupload_view_list .plupload_file_status,
|
||||
.plupload_filelist_footer .plupload_file_size,
|
||||
.plupload_filelist_footer .plupload_file_size,
|
||||
.plupload_filelist_footer .plupload_file_status {
|
||||
text-align: right;
|
||||
text-align: right;
|
||||
width: 52px;
|
||||
}
|
||||
|
||||
@@ -262,7 +262,7 @@
|
||||
}
|
||||
|
||||
.plupload_view_thumbs div.plupload_file_status {
|
||||
position: relative;
|
||||
position: relative;
|
||||
height: 3px;
|
||||
overflow: hidden;
|
||||
text-indent: -999px;
|
||||
@@ -276,7 +276,7 @@
|
||||
|
||||
.plupload .ui-sortable-helper,
|
||||
.plupload .ui-sortable .plupload_file {
|
||||
cursor:move;
|
||||
cursor:move;
|
||||
}
|
||||
|
||||
.plupload_file_action {width: 16px;}
|
||||
@@ -330,12 +330,16 @@
|
||||
display: block;
|
||||
}
|
||||
|
||||
.plupload_files_queued .plupload_droptext {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.plupload_buttons, .plupload_upload_status {float: left}
|
||||
|
||||
.plupload_message {
|
||||
position: absolute;
|
||||
top: -1px;
|
||||
left: -1px;
|
||||
left: -1px;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
@@ -346,28 +350,28 @@
|
||||
}
|
||||
|
||||
.plupload_message strong {
|
||||
font-weight: bold;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.plupload_message i {
|
||||
font-style: italic;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.plupload_message p span.ui-icon {
|
||||
float: left;
|
||||
margin-right: 0.3em;
|
||||
margin-right: 0.3em;
|
||||
}
|
||||
|
||||
.plupload_header_content .ui-state-error,
|
||||
.plupload_header_content .ui-state-highlight {
|
||||
border:none;
|
||||
border:none;
|
||||
}
|
||||
|
||||
.plupload_message_close {
|
||||
position:absolute;
|
||||
top:5px;
|
||||
right:5px;
|
||||
cursor:pointer;
|
||||
cursor:pointer;
|
||||
}
|
||||
|
||||
.plupload .ui-sortable-placeholder {
|
||||
|
||||
Whitespace-only changes.
Whitespace-only changes.
+6
-3
@@ -491,7 +491,7 @@ $.widget("ui.plupload", {
|
||||
break;
|
||||
}
|
||||
|
||||
message += " <br /><i>" + details + "</i>";
|
||||
message += " <br /><i>" + plupload.xmlEncode(details) + "</i>";
|
||||
|
||||
self._trigger('error', null, { up: up, error: err } );
|
||||
|
||||
@@ -902,6 +902,9 @@ $.widget("ui.plupload", {
|
||||
$('.ui-button-text', this.browse_button).html(plupload.sprintf(_('%d files queued'), up.total.queued));
|
||||
}
|
||||
|
||||
// have a helper class on a container expressing whether it has files queued or not
|
||||
this.container.toggleClass('plupload_files_queued', up.files.length);
|
||||
|
||||
up.refresh();
|
||||
},
|
||||
|
||||
@@ -1164,7 +1167,7 @@ $.widget("ui.plupload", {
|
||||
return ext;
|
||||
|
||||
default:
|
||||
return file[$1] || '';
|
||||
return plupload.xmlEncode(file[$1] || '');
|
||||
}
|
||||
});
|
||||
});
|
||||
@@ -1310,7 +1313,7 @@ $.widget("ui.plupload", {
|
||||
// Rename file and glue extension back on
|
||||
if (e.keyCode === 13) {
|
||||
file.name = nameInput.val() + ext;
|
||||
nameSpan.html(file.name);
|
||||
nameSpan.text(file.name);
|
||||
}
|
||||
nameInput.blur();
|
||||
}
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
!function(e,t,i,s,n){function l(e){return i.translate(e)||e}function o(e){e.id=e.attr("id"),e.html('<div class="plupload_wrapper"><div class="ui-widget-content plupload_container"><div class="ui-state-default ui-widget-header plupload_header"><div class="plupload_header_content"><div class="plupload_logo"> </div><div class="plupload_header_title">'+l("Select files")+"</div>"+'<div class="plupload_header_text">'+l("Add files to the upload queue and click the start button.")+"</div>"+'<div class="plupload_view_switch">'+'<input type="radio" id="'+e.id+'_view_list" name="view_mode_'+e.id+'" checked="checked" /><label class="plupload_button" for="'+e.id+'_view_list" data-view="list">'+l("List")+"</label>"+'<input type="radio" id="'+e.id+'_view_thumbs" name="view_mode_'+e.id+'" /><label class="plupload_button" for="'+e.id+'_view_thumbs" data-view="thumbs">'+l("Thumbnails")+"</label>"+"</div>"+"</div>"+"</div>"+'<table class="plupload_filelist plupload_filelist_header ui-widget-header">'+"<tr>"+'<td class="plupload_cell plupload_file_name">'+l("Filename")+"</td>"+'<td class="plupload_cell plupload_file_status">'+l("Status")+"</td>"+'<td class="plupload_cell plupload_file_size">'+l("Size")+"</td>"+'<td class="plupload_cell plupload_file_action"> </td>'+"</tr>"+"</table>"+'<div class="plupload_content">'+'<div class="plupload_droptext">'+l("Drag files here.")+"</div>"+'<ul class="plupload_filelist_content"> </ul>'+'<div class="plupload_clearer"> </div>'+"</div>"+'<table class="plupload_filelist plupload_filelist_footer ui-widget-header">'+"<tr>"+'<td class="plupload_cell plupload_file_name">'+'<div class="plupload_buttons"><!-- Visible -->'+'<a class="plupload_button plupload_add">'+l("Add Files")+"</a> "+'<a class="plupload_button plupload_start">'+l("Start Upload")+"</a> "+'<a class="plupload_button plupload_stop plupload_hidden">'+l("Stop Upload")+"</a> "+"</div>"+'<div class="plupload_started plupload_hidden"><!-- Hidden -->'+'<div class="plupload_progress plupload_right">'+'<div class="plupload_progress_container"></div>'+"</div>"+'<div class="plupload_cell plupload_upload_status"></div>'+'<div class="plupload_clearer"> </div>'+"</div>"+"</td>"+'<td class="plupload_file_status"><span class="plupload_total_status">0%</span></td>'+'<td class="plupload_file_size"><span class="plupload_total_file_size">0 kb</span></td>'+'<td class="plupload_file_action"></td>'+"</tr>"+"</table>"+"</div>"+'<input class="plupload_count" value="0" type="hidden">'+"</div>")}var a={};n.widget("ui.plupload",{widgetEventPrefix:"",contents_bak:"",options:{browse_button_hover:"ui-state-hover",browse_button_active:"ui-state-active",filters:{},buttons:{browse:!0,start:!0,stop:!0},views:{list:!0,thumbs:!1,active:"list",remember:!0},thumb_width:100,thumb_height:60,multiple_queues:!0,dragdrop:!0,autostart:!1,sortable:!1,rename:!1},FILE_COUNT_ERROR:-9001,_create:function(){var e=this.element.attr("id");e||(e=i.guid(),this.element.attr("id",e)),this.id=e,this.contents_bak=this.element.html(),o(this.element),this.container=n(".plupload_container",this.element).attr("id",e+"_container"),this.content=n(".plupload_content",this.element),n.fn.resizable&&this.container.resizable({handles:"s",minHeight:300}),this.filelist=n(".plupload_filelist_content",this.container).attr({id:e+"_filelist",unselectable:"on"}),this.browse_button=n(".plupload_add",this.container).attr("id",e+"_browse"),this.start_button=n(".plupload_start",this.container).attr("id",e+"_start"),this.stop_button=n(".plupload_stop",this.container).attr("id",e+"_stop"),this.thumbs_switcher=n("#"+e+"_view_thumbs"),this.list_switcher=n("#"+e+"_view_list"),n.ui.button&&(this.browse_button.button({icons:{primary:"ui-icon-circle-plus"},disabled:!0}),this.start_button.button({icons:{primary:"ui-icon-circle-arrow-e"},disabled:!0}),this.stop_button.button({icons:{primary:"ui-icon-circle-close"}}),this.list_switcher.button({text:!1,icons:{secondary:"ui-icon-grip-dotted-horizontal"}}),this.thumbs_switcher.button({text:!1,icons:{secondary:"ui-icon-image"}})),this.progressbar=n(".plupload_progress_container",this.container),n.ui.progressbar&&this.progressbar.progressbar(),this.counter=n(".plupload_count",this.element).attr({id:e+"_count",name:e+"_count"}),this._initUploader()},_initUploader:function(){var e,t=this,s=this.id,o={container:s+"_buttons",browse_button:s+"_browse"};n(".plupload_buttons",this.element).attr("id",s+"_buttons"),t.options.dragdrop&&(this.filelist.parent().attr("id",this.id+"_dropbox"),o.drop_element=this.id+"_dropbox"),this.filelist.on("click",function(e){var i,s=n(e.target);s.hasClass("plupload_action_icon")&&(i=s.closest(".plupload_file"),i.hasClass("plupload_delete")&&(t.removeFile(i.attr("id")),e.preventDefault()))}),e=this.uploader=a[s]=new i.Uploader(n.extend(this.options,o)),this.options=e.getOption(),t.options.views.thumbs&&(e.settings.required_features.display_media=!0),t.options.max_file_count&&i.extend(e.getOption("filters"),{max_file_couLine truncated
|
||||
!function(e,t,i,s,n){function l(e){return i.translate(e)||e}function o(e){e.id=e.attr("id"),e.html('<div class="plupload_wrapper"><div class="ui-widget-content plupload_container"><div class="ui-state-default ui-widget-header plupload_header"><div class="plupload_header_content"><div class="plupload_logo"> </div><div class="plupload_header_title">'+l("Select files")+"</div>"+'<div class="plupload_header_text">'+l("Add files to the upload queue and click the start button.")+"</div>"+'<div class="plupload_view_switch">'+'<input type="radio" id="'+e.id+'_view_list" name="view_mode_'+e.id+'" checked="checked" /><label class="plupload_button" for="'+e.id+'_view_list" data-view="list">'+l("List")+"</label>"+'<input type="radio" id="'+e.id+'_view_thumbs" name="view_mode_'+e.id+'" /><label class="plupload_button" for="'+e.id+'_view_thumbs" data-view="thumbs">'+l("Thumbnails")+"</label>"+"</div>"+"</div>"+"</div>"+'<table class="plupload_filelist plupload_filelist_header ui-widget-header">'+"<tr>"+'<td class="plupload_cell plupload_file_name">'+l("Filename")+"</td>"+'<td class="plupload_cell plupload_file_status">'+l("Status")+"</td>"+'<td class="plupload_cell plupload_file_size">'+l("Size")+"</td>"+'<td class="plupload_cell plupload_file_action"> </td>'+"</tr>"+"</table>"+'<div class="plupload_content">'+'<div class="plupload_droptext">'+l("Drag files here.")+"</div>"+'<ul class="plupload_filelist_content"> </ul>'+'<div class="plupload_clearer"> </div>'+"</div>"+'<table class="plupload_filelist plupload_filelist_footer ui-widget-header">'+"<tr>"+'<td class="plupload_cell plupload_file_name">'+'<div class="plupload_buttons"><!-- Visible -->'+'<a class="plupload_button plupload_add">'+l("Add Files")+"</a> "+'<a class="plupload_button plupload_start">'+l("Start Upload")+"</a> "+'<a class="plupload_button plupload_stop plupload_hidden">'+l("Stop Upload")+"</a> "+"</div>"+'<div class="plupload_started plupload_hidden"><!-- Hidden -->'+'<div class="plupload_progress plupload_right">'+'<div class="plupload_progress_container"></div>'+"</div>"+'<div class="plupload_cell plupload_upload_status"></div>'+'<div class="plupload_clearer"> </div>'+"</div>"+"</td>"+'<td class="plupload_file_status"><span class="plupload_total_status">0%</span></td>'+'<td class="plupload_file_size"><span class="plupload_total_file_size">0 kb</span></td>'+'<td class="plupload_file_action"></td>'+"</tr>"+"</table>"+"</div>"+'<input class="plupload_count" value="0" type="hidden">'+"</div>")}var a={};n.widget("ui.plupload",{widgetEventPrefix:"",contents_bak:"",options:{browse_button_hover:"ui-state-hover",browse_button_active:"ui-state-active",filters:{},buttons:{browse:!0,start:!0,stop:!0},views:{list:!0,thumbs:!1,active:"list",remember:!0},thumb_width:100,thumb_height:60,multiple_queues:!0,dragdrop:!0,autostart:!1,sortable:!1,rename:!1},FILE_COUNT_ERROR:-9001,_create:function(){var e=this.element.attr("id");e||(e=i.guid(),this.element.attr("id",e)),this.id=e,this.contents_bak=this.element.html(),o(this.element),this.container=n(".plupload_container",this.element).attr("id",e+"_container"),this.content=n(".plupload_content",this.element),n.fn.resizable&&this.container.resizable({handles:"s",minHeight:300}),this.filelist=n(".plupload_filelist_content",this.container).attr({id:e+"_filelist",unselectable:"on"}),this.browse_button=n(".plupload_add",this.container).attr("id",e+"_browse"),this.start_button=n(".plupload_start",this.container).attr("id",e+"_start"),this.stop_button=n(".plupload_stop",this.container).attr("id",e+"_stop"),this.thumbs_switcher=n("#"+e+"_view_thumbs"),this.list_switcher=n("#"+e+"_view_list"),n.ui.button&&(this.browse_button.button({icons:{primary:"ui-icon-circle-plus"},disabled:!0}),this.start_button.button({icons:{primary:"ui-icon-circle-arrow-e"},disabled:!0}),this.stop_button.button({icons:{primary:"ui-icon-circle-close"}}),this.list_switcher.button({text:!1,icons:{secondary:"ui-icon-grip-dotted-horizontal"}}),this.thumbs_switcher.button({text:!1,icons:{secondary:"ui-icon-image"}})),this.progressbar=n(".plupload_progress_container",this.container),n.ui.progressbar&&this.progressbar.progressbar(),this.counter=n(".plupload_count",this.element).attr({id:e+"_count",name:e+"_count"}),this._initUploader()},_initUploader:function(){var e,t=this,s=this.id,o={container:s+"_buttons",browse_button:s+"_browse"};n(".plupload_buttons",this.element).attr("id",s+"_buttons"),t.options.dragdrop&&(this.filelist.parent().attr("id",this.id+"_dropbox"),o.drop_element=this.id+"_dropbox"),this.filelist.on("click",function(e){var i,s=n(e.target);s.hasClass("plupload_action_icon")&&(i=s.closest(".plupload_file"),i.hasClass("plupload_delete")&&(t.removeFile(i.attr("id")),e.preventDefault()))}),e=this.uploader=a[s]=new i.Uploader(n.extend(this.options,o)),this.options=e.getOption(),t.options.views.thumbs&&(e.settings.required_features.display_media=!0),t.options.max_file_count&&i.extend(e.getOption("filters"),{max_file_couLine truncated
|
||||
File diff suppressed because it is too large.
Load diff
+12
-1
@@ -1 +1,12 @@
|
||||
var MXI_DEBUG=!0;!function(e){function t(){var e={};return function(){(function(a,w){"use strict";var s={};function n(e,t){var i,n=[];for(var r=0;r<e.length;++r){i=s[e[r]]||o(e[r]);if(!i){throw"module definition dependecy not found: "+e[r]}n.push(i)}t.apply(null,n)}function e(e,t,i){if(typeof e!=="string"){throw"invalid module definition, module id must be defined and be a string"}if(t===w){throw"invalid module definition, dependencies must be specified"}if(i===w){throw"invalid module definition, definition function must be specified"}n(t,function(){s[e]=i.apply(null,arguments)})}function d(e){return!!s[e]}function o(e){var t=a;var i=e.split(/[.\/]/);for(var n=0;n<i.length;++n){if(!t[i[n]]){return}t=t[i[n]]}return t}function t(e){for(var t=0;t<e.length;t++){var i=a;var n=e[t];var r=n.split(/[.\/]/);for(var o=0;o<r.length-1;++o){if(i[r[o]]===w){i[r[o]]={}}i=i[r[o]]}i[r[r.length-1]]=s[n]}}e("moxie/core/utils/Basic",[],function(){function s(e){var t;if(e===t){return"undefined"}else if(e===null){return"null"}else if(e.nodeType){return"node"}return{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()}function t(){return l(false,false,arguments)}function e(){return l(true,false,arguments)}function i(){return l(false,true,arguments)}function n(){return l(true,true,arguments)}function u(e){switch(s(e)){case"array":return Array.prototype.slice.call(e);case"object":return t({},e)}return e}function l(n,r,e){var o;var a=e[0];c(e,function(e,t){if(t>0){c(e,function(e,t){var i=d(s(e),["array","object"])!==-1;if(e===o||n&&a[t]===o){return true}if(i&&r){e=u(e)}if(s(a[t])===s(e)&&i){l(n,r,[a[t],e])}else{a[t]=e}})}});return a}function r(e,t){for(var i in t){if({}.hasOwnProperty.call(t,i)){e[i]=t[i]}}function n(){this.constructor=e}n.prototype=t.prototype;e.prototype=new n;e.__parent__=t.prototype;return e}function c(e,t){var i,n,r,o;if(e){try{i=e.length}catch(e){i=o}if(i===o||typeof i!=="number"){for(n in e){if(e.hasOwnProperty(n)){if(t(e[n],n)===false){return}}}}else{for(r=0;r<i;r++){if(t(e[r],r)===false){return}}}}}function o(e){var t;if(!e||s(e)!=="object"){return true}for(t in e){return false}return true}function a(e,i){var t=0,n=e.length;if(s(i)!=="function"){i=function(){}}if(!e||!e.length){i()}function r(t){if(s(e[t])==="function"){e[t](function(e){++t<n&&!e?r(t):i(e)})}}r(t)}function f(e,n){var r=0,o=e.length,a=new Array(o);c(e,function(e,i){e(function(e){if(e){return n(e)}var t=[].slice.call(arguments);t.shift();a[i]=t;r++;if(r===o){a.unshift(null);n.apply(this,a)}})})}function d(e,t){if(t){if(Array.prototype.indexOf){return Array.prototype.indexOf.call(t,e)}for(var i=0,n=t.length;i<n;i++){if(t[i]===e){return i}}}return-1}function m(e,t){var i=[];if(s(e)!=="array"){e=[e]}if(s(t)!=="array"){t=[t]}for(var n in e){if(d(e[n],t)===-1){i.push(e[n])}}return i.length?i:false}function h(e,t){var i=[];c(e,function(e){if(d(e,t)!==-1){i.push(e)}});return i.length?i:null}function p(e){var t,i=[];for(t=0;t<e.length;t++){i[t]=e[t]}return i}var g=function(){var n=0;return function(e){var t=(new Date).getTime().toString(32),i;for(i=0;i<5;i++){t+=Math.floor(Math.random()*65535).toString(32)}return(e||"o_")+t+(n++).toString(32)}}();function x(e){if(!e){return e}return String.prototype.trim?String.prototype.trim.call(e):e.toString().replace(/^\s*/,"").replace(/\s*$/,"")}function v(e){if(typeof e!=="string"){return e}var t={t:1099511627776,g:1073741824,m:1048576,k:1024},i;e=/^([0-9\.]+)([tmgk]?)$/.exec(e.toLowerCase().replace(/[^0-9\.tmkg]/g,""));i=e[2];e=+e[1];if(t.hasOwnProperty(i)){e*=t[i]}return Math.floor(e)}function w(e){var t=[].slice.call(arguments,1);return e.replace(/%[a-z]/g,function(){var e=t.shift();return s(e)!=="undefined"?e:""})}function y(e,t){var i=this;setTimeout(function(){e.call(i)},t||1)}return{guid:g,typeOf:s,extend:t,extendIf:e,extendImmutable:i,extendImmutableIf:n,inherit:r,each:c,isEmptyObj:o,inSeries:a,inParallel:f,inArray:d,arrayDiff:m,arrayIntersect:h,toArray:p,trim:x,sprintf:w,parseSizeStr:v,delay:y}});e("moxie/core/utils/Encode",[],function(){var g=function(e){return unescape(encodeURIComponent(e))};var p=function(e){return decodeURIComponent(escape(e))};var e=function(e,t){if(typeof window.atob==="function"){return t?p(window.atob(e)):window.atob(e)}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,a,s,u,l,c,f=0,d=0,m="",h=[];if(!e){return e}e+="";do{a=i.indexOf(e.charAt(f++));s=i.indexOf(e.charAt(f++));u=i.indexOf(e.charAt(f++));l=i.indexOf(e.charAt(f++));c=a<<18|s<<12|u<<6|l;n=c>>16&255;r=c>>8&255;o=c&255;if(u==64){h[d++]=String.fromCharCode(n)}else if(l==64){h[d++]=String.fromCharCode(n,r)}else{h[d++]=String.fromCharCode(n,r,o)}}while(f<e.length);m=h.join("");return t?p(m):m};var t=function(e,t){if(t){e=g(e)}if(typeof window.btoa==="function"){return window.btoa(e)}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,a,s,u,l,c,f=0,d=0,m="",h=[];if(!e){return e}do{n=e.charCodeAt(f++);r=e.charCodeAt(f++);o=e.charCodeAt(f++);c=n<<16|rLine truncated
|
||||
/**
|
||||
* mOxie - multi-runtime File API & XMLHttpRequest L2 Polyfill - IPS modified to prevent double image rotation
|
||||
* v1.5.7
|
||||
*
|
||||
* Copyright 2013, Moxiecode Systems AB
|
||||
* Released under GPL License.
|
||||
*
|
||||
* License: http://www.plupload.com/license
|
||||
* Contributing: http://www.plupload.com/contributing
|
||||
*
|
||||
* Date: 2017-11-03
|
||||
*/var MXI_DEBUG=!0;!function(e){function t(){var e={};return function(){(function(a,w){"use strict";var s={};function n(e,t){var i,n=[];for(var r=0;r<e.length;++r){i=s[e[r]]||o(e[r]);if(!i)throw"module definition dependecy not found: "+e[r];n.push(i)}t.apply(null,n)}function e(e,t,i){if(typeof e!=="string")throw"invalid module definition, module id must be defined and be a string";if(t===w)throw"invalid module definition, dependencies must be specified";if(i===w)throw"invalid module definition, definition function must be specified";n(t,function(){s[e]=i.apply(null,arguments)})}function d(e){return!!s[e]}function o(e){var t=a;var i=e.split(/[.\/]/);for(var n=0;n<i.length;++n){if(!t[i[n]])return;t=t[i[n]]}return t}function t(e){for(var t=0;t<e.length;t++){var i=a;var n=e[t];var r=n.split(/[.\/]/);for(var o=0;o<r.length-1;++o){if(i[r[o]]===w)i[r[o]]={};i=i[r[o]]}i[r[r.length-1]]=s[n]}}e("moxie/core/utils/Basic",[],function(){function s(e){var t;if(e===t)return"undefined";else if(e===null)return"null";else if(e.nodeType)return"node";return{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()}function t(){return l(false,false,arguments)}function e(){return l(true,false,arguments)}function i(){return l(false,true,arguments)}function n(){return l(true,true,arguments)}function r(e){switch(s(e)){case"array":return l(false,true,[[],e]);case"object":return l(false,true,[{},e]);default:return e}}function u(e){switch(s(e)){case"array":return Array.prototype.slice.call(e);case"object":return t({},e)}return e}function l(n,r,e){var o;var a=e[0];c(e,function(e,t){if(t>0)c(e,function(e,t){var i=m(s(e),["array","object"])!==-1;if(e===o||n&&a[t]===o)return true;if(i&&r)e=u(e);if(s(a[t])===s(e)&&i)l(n,r,[a[t],e]);else a[t]=e})});return a}function o(t,e){for(var i in e)if({}.hasOwnProperty.call(e,i))t[i]=e[i];function n(){this.constructor=t;if(MXI_DEBUG){var e=function(e){var t=e.toString().match(/^function\s([^\(\s]+)/);return t?t[1]:false};this.ctorName=e(t)}}n.prototype=e.prototype;t.prototype=new n;t.parent=e.prototype;return t}function c(e,t){var i,n,r,o;if(e){try{i=e.length}catch(e){i=o}if(i===o||typeof i!=="number"){for(n in e)if(e.hasOwnProperty(n))if(t(e[n],n)===false)return}else for(r=0;r<i;r++)if(t(e[r],r)===false)return}}function a(e){var t;if(!e||s(e)!=="object")return true;for(t in e)return false;return true}function f(e,i){var t=0,n=e.length;if(s(i)!=="function")i=function(){};if(!e||!e.length)i();function r(t){if(s(e[t])==="function")e[t](function(e){++t<n&&!e?r(t):i(e)})}r(t)}function d(e,n){var r=0,o=e.length,a=new Array(o);c(e,function(e,i){e(function(e){if(e)return n(e);var t=[].slice.call(arguments);t.shift();a[i]=t;r++;if(r===o){a.unshift(null);n.apply(this,a)}})})}function m(e,t){if(t){if(Array.prototype.indexOf)return Array.prototype.indexOf.call(t,e);for(var i=0,n=t.length;i<n;i++)if(t[i]===e)return i}return-1}function h(e,t){var i=[];if(s(e)!=="array")e=[e];if(s(t)!=="array")t=[t];for(var n in e)if(m(e[n],t)===-1)i.push(e[n]);return i.length?i:false}function p(e,t){var i=[];c(e,function(e){if(m(e,t)!==-1)i.push(e)});return i.length?i:null}function g(e){var t,i=[];for(t=0;t<e.length;t++)i[t]=e[t];return i}var v=function(){var n=0;return function(e){var t=(new Date).getTime().toString(32),i;for(i=0;i<5;i++)t+=Math.floor(Math.random()*65535).toString(32);return(e||"o_")+t+(n++).toString(32)}}();function x(e){if(!e)return e;return String.prototype.trim?String.prototype.trim.call(e):e.toString().replace(/^\s*/,"").replace(/\s*$/,"")}function w(e){if(typeof e!=="string")return e;var t={t:1099511627776,g:1073741824,m:1048576,k:1024},i;e=/^([0-9\.]+)([tmgk]?)$/.exec(e.toLowerCase().replace(/[^0-9\.tmkg]/g,""));i=e[2];e=+e[1];if(t.hasOwnProperty(i))e*=t[i];return Math.floor(e)}function y(e){var n=[].slice.call(arguments,1);return e.replace(/%([a-z])/g,function(e,t){var i=n.shift();switch(t){case"s":return i+"";case"d":return parseInt(i,10);case"f":return parseFloat(i);case"c":return"";default:return i}})}function E(e,t){var i=this;setTimeout(function(){e.call(i)},t||1)}return{guid:v,typeOf:s,extend:t,extendIf:e,extendImmutable:i,extendImmutableIf:n,clone:r,inherit:o,each:c,isEmptyObj:a,inSeries:f,inParallel:d,inArray:m,arrayDiff:h,arrayIntersect:p,toArray:g,trim:x,sprintf:y,parseSizeStr:w,delay:E}});e("moxie/core/utils/Encode",[],function(){var g=function(e){return unescape(encodeURIComponent(e))};var p=function(e){return decodeURIComponent(escape(e))};var e=function(e,t){if(typeof window.atob==="function")return t?p(window.atob(e)):window.atob(e);var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,a,s,u,l,c,f=0,d=0,m="",h=[];if(!e)return e;e+="";do{a=i.indexOf(e.charAt(f++));s=i.indexOf(e.charAt(f++));u=i.indexOf(e.charAt(f++));l=i.indexOf(e.charAt(f++));c=a<<18|s<<12|u<<6|l;n=c>>16&255;r=c>>8&255;o=c&255;if(u==64)h[d++]=String.fromCharCode(n);else if(l==64)h[d++]=String.fromCharCode(n,r);else h[d++]=String.fromCharCode(n,r,o)}while(f<e.length);m=h.join("");return t?p(mLine truncated
|
||||
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* Plupload - multi-runtime File Uploader
|
||||
* v2.3.1
|
||||
* v2.3.6
|
||||
*
|
||||
* Copyright 2013, Moxiecode Systems AB
|
||||
* Released under GPL License.
|
||||
@@ -8,7 +8,7 @@
|
||||
* License: http://www.plupload.com/license
|
||||
* Contributing: http://www.plupload.com/contributing
|
||||
*
|
||||
* Date: 2017-02-06
|
||||
* Date: 2017-11-03
|
||||
*/
|
||||
;(function (global, factory) {
|
||||
var extract = function() {
|
||||
@@ -112,7 +112,7 @@ var plupload = {
|
||||
* @static
|
||||
* @final
|
||||
*/
|
||||
VERSION : '2.3.1',
|
||||
VERSION : '2.3.6',
|
||||
|
||||
/**
|
||||
* The state of the queue before it has started and after it has finished
|
||||
@@ -214,7 +214,8 @@ var plupload = {
|
||||
INIT_ERROR : -500,
|
||||
|
||||
/**
|
||||
* File size error. If the user selects a file that is too large it will be blocked and an error of this type will be triggered.
|
||||
* File size error. If the user selects a file that is too large or is empty it will be blocked and
|
||||
* an error of this type will be triggered.
|
||||
*
|
||||
* @property FILE_SIZE_ERROR
|
||||
* @static
|
||||
@@ -268,6 +269,15 @@ var plupload = {
|
||||
*/
|
||||
IMAGE_DIMENSIONS_ERROR : -702,
|
||||
|
||||
/**
|
||||
* Expose whole moxie (#1469).
|
||||
*
|
||||
* @property moxie
|
||||
* @type Object
|
||||
* @final
|
||||
*/
|
||||
moxie: o,
|
||||
|
||||
/**
|
||||
* Mime type lookup table.
|
||||
*
|
||||
@@ -749,6 +759,19 @@ plupload.addFileFilter('prevent_duplicates', function(value, file, cb) {
|
||||
cb(true);
|
||||
});
|
||||
|
||||
plupload.addFileFilter('prevent_empty', function(value, file, cb) {
|
||||
if (value && !file.size && file.size !== undef) {
|
||||
this.trigger('Error', {
|
||||
code : plupload.FILE_SIZE_ERROR,
|
||||
message : plupload.translate('File size error.'),
|
||||
file : file
|
||||
});
|
||||
cb(false);
|
||||
} else {
|
||||
cb(true);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
@class Uploader
|
||||
@@ -764,6 +787,7 @@ plupload.addFileFilter('prevent_duplicates', function(value, file, cb) {
|
||||
@param {String|Number} [settings.filters.max_file_size=0] Maximum file size that the user can pick, in bytes. Optionally supports b, kb, mb, gb, tb suffixes. `e.g. "10mb" or "1gb"`. By default - not set. Dispatches `plupload.FILE_SIZE_ERROR`.
|
||||
@param {Array} [settings.filters.mime_types=[]] List of file types to accept, each one defined by title and list of extensions. `e.g. {title : "Image files", extensions : "jpg,jpeg,gif,png"}`. Dispatches `plupload.FILE_EXTENSION_ERROR`
|
||||
@param {Boolean} [settings.filters.prevent_duplicates=false] Do not let duplicates into the queue. Dispatches `plupload.FILE_DUPLICATE_ERROR`.
|
||||
@param {Boolean} [settings.filters.prevent_empty=true] Do not let empty files into the queue (IE10 is known to hang for example when trying to upload such). Dispatches `plupload.FILE_SIZE_ERROR`.
|
||||
@param {String} [settings.flash_swf_url] URL of the Flash swf.
|
||||
@param {Object} [settings.headers] Custom headers to send with the upload. Hash of name/value pairs.
|
||||
@param {String} [settings.http_method="POST"] HTTP method to use during upload (only PUT or POST allowed).
|
||||
@@ -1058,17 +1082,6 @@ plupload.Uploader = function(options) {
|
||||
}
|
||||
|
||||
|
||||
function runtimeCan(file, cap) {
|
||||
if (file.ruid) {
|
||||
var info = Runtime.getInfo(file.ruid);
|
||||
if (info) {
|
||||
return info.can(cap);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
function bindEventListeners() {
|
||||
this.bind('FilesAdded FilesRemoved', function(up) {
|
||||
up.trigger('QueueChanged');
|
||||
@@ -1225,7 +1238,7 @@ plupload.Uploader = function(options) {
|
||||
}
|
||||
|
||||
|
||||
function resizeImage(blob, params, cb) {
|
||||
function resizeImage(blob, params, runtimeOptions, cb) {
|
||||
var img = new o.image.Image();
|
||||
|
||||
try {
|
||||
@@ -1238,22 +1251,25 @@ plupload.Uploader = function(options) {
|
||||
!params.crop
|
||||
) {
|
||||
this.destroy();
|
||||
return cb(blob);
|
||||
cb(blob);
|
||||
} else {
|
||||
// otherwise downsize
|
||||
img.downsize(params.width, params.height, params.crop, params.preserve_headers);
|
||||
}
|
||||
// otherwise downsize
|
||||
img.downsize(params.width, params.height, params.crop, params.preserve_headers);
|
||||
};
|
||||
|
||||
img.onresize = function() {
|
||||
cb(this.getAsBlob(blob.type, params.quality));
|
||||
var resizedBlob = this.getAsBlob(blob.type, params.quality);
|
||||
this.destroy();
|
||||
cb(resizedBlob);
|
||||
};
|
||||
|
||||
img.onerror = function() {
|
||||
img.bind('error runtimeerror', function() {
|
||||
this.destroy();
|
||||
cb(blob);
|
||||
};
|
||||
});
|
||||
|
||||
img.load(blob);
|
||||
img.load(blob, runtimeOptions);
|
||||
} catch(ex) {
|
||||
cb(blob);
|
||||
}
|
||||
@@ -1430,13 +1446,20 @@ plupload.Uploader = function(options) {
|
||||
|
||||
|
||||
function onUploadFile(up, file) {
|
||||
var url = up.settings.url
|
||||
, chunkSize = up.settings.chunk_size
|
||||
, retries = up.settings.max_retries
|
||||
, features = up.features
|
||||
, offset = 0
|
||||
, blob
|
||||
;
|
||||
var url = up.settings.url;
|
||||
var chunkSize = up.settings.chunk_size;
|
||||
var retries = up.settings.max_retries;
|
||||
var features = up.features;
|
||||
var offset = 0;
|
||||
var blob;
|
||||
|
||||
var runtimeOptions = {
|
||||
runtime_order: up.settings.runtimes,
|
||||
required_caps: up.settings.required_features,
|
||||
preferred_caps: preferred_caps,
|
||||
swf_url: up.settings.flash_swf_url,
|
||||
xap_url: up.settings.silverlight_xap_url
|
||||
};
|
||||
|
||||
// make sure we start at a predictable offset
|
||||
if (file.loaded) {
|
||||
@@ -1513,7 +1536,7 @@ plupload.Uploader = function(options) {
|
||||
|
||||
xhr.onload = function() {
|
||||
// check if upload made itself through
|
||||
if (xhr.status >= 400) {
|
||||
if (xhr.status < 200 || xhr.status >= 400) {
|
||||
handleError();
|
||||
return;
|
||||
}
|
||||
@@ -1576,7 +1599,6 @@ plupload.Uploader = function(options) {
|
||||
|
||||
xhr.onloadend = function() {
|
||||
this.destroy();
|
||||
xhr = null;
|
||||
};
|
||||
|
||||
// Build multipart request
|
||||
@@ -1597,13 +1619,7 @@ plupload.Uploader = function(options) {
|
||||
|
||||
// Add file and send it
|
||||
formData.append(up.settings.file_data_name, chunkBlob);
|
||||
xhr.send(formData, {
|
||||
runtime_order: up.settings.runtimes,
|
||||
required_caps: up.settings.required_features,
|
||||
preferred_caps: preferred_caps,
|
||||
swf_url: up.settings.flash_swf_url,
|
||||
xap_url: up.settings.silverlight_xap_url
|
||||
});
|
||||
xhr.send(formData, runtimeOptions);
|
||||
} else {
|
||||
// if no multipart, send as binary stream
|
||||
url = plupload.buildUrl(up.settings.url, plupload.extend(args, up.settings.multipart_params));
|
||||
@@ -1620,13 +1636,7 @@ plupload.Uploader = function(options) {
|
||||
xhr.setRequestHeader('Content-Type', 'application/octet-stream'); // Binary stream header
|
||||
}
|
||||
|
||||
xhr.send(chunkBlob, {
|
||||
runtime_order: up.settings.runtimes,
|
||||
required_caps: up.settings.required_features,
|
||||
preferred_caps: preferred_caps,
|
||||
swf_url: up.settings.flash_swf_url,
|
||||
xap_url: up.settings.silverlight_xap_url
|
||||
});
|
||||
xhr.send(chunkBlob, runtimeOptions);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1634,9 +1644,9 @@ plupload.Uploader = function(options) {
|
||||
blob = file.getSource();
|
||||
|
||||
// Start uploading chunks
|
||||
if (!plupload.isEmptyObj(up.settings.resize) && runtimeCan(blob, 'send_binary_string') && plupload.inArray(blob.type, ['image/jpeg', 'image/png']) !== -1) {
|
||||
if (!plupload.isEmptyObj(up.settings.resize) && plupload.inArray(blob.type, ['image/jpeg', 'image/png']) !== -1) {
|
||||
// Resize if required
|
||||
resizeImage.call(this, blob, up.settings.resize, function(resizedBlob) {
|
||||
resizeImage(blob, up.settings.resize, runtimeOptions, function(resizedBlob) {
|
||||
blob = resizedBlob;
|
||||
file.size = resizedBlob.size;
|
||||
uploadNextChunk();
|
||||
@@ -1744,8 +1754,9 @@ plupload.Uploader = function(options) {
|
||||
file_data_name: 'file',
|
||||
filters: {
|
||||
mime_types: [],
|
||||
max_file_size: 0,
|
||||
prevent_duplicates: false,
|
||||
max_file_size: 0
|
||||
prevent_empty: true
|
||||
},
|
||||
flash_swf_url: 'js/Moxie.swf',
|
||||
http_method: 'POST',
|
||||
@@ -2123,11 +2134,12 @@ plupload.Uploader = function(options) {
|
||||
},
|
||||
|
||||
/**
|
||||
* Removes part of the queue and returns the files removed. This will also trigger the FilesRemoved and QueueChanged events.
|
||||
* Removes part of the queue and returns the files removed. This will also trigger the
|
||||
* FilesRemoved and QueueChanged events.
|
||||
*
|
||||
* @method splice
|
||||
* @param {Number} start (Optional) Start index to remove from.
|
||||
* @param {Number} length (Optional) Lengh of items to remove.
|
||||
* @param {Number} [start=0] Start index to remove from.
|
||||
* @param {Number} [length] Number of files to remove (defaults to number of files in the queue).
|
||||
* @return {Array} Array of files that was removed.
|
||||
*/
|
||||
splice : function(start, length) {
|
||||
@@ -2291,13 +2303,22 @@ plupload.File = (function() {
|
||||
*/
|
||||
type: file.type || '',
|
||||
|
||||
/**
|
||||
* Relative path to the file inside a directory
|
||||
*
|
||||
* @property relativePath
|
||||
* @type String
|
||||
* @default ''
|
||||
*/
|
||||
relativePath: file.relativePath || '',
|
||||
|
||||
/**
|
||||
* File size in bytes (may change after client-side manupilation).
|
||||
*
|
||||
* @property size
|
||||
* @type Number
|
||||
*/
|
||||
size: file.size || file.fileSize,
|
||||
size: file.fileSize || file.size,
|
||||
|
||||
/**
|
||||
* Original file size in bytes.
|
||||
@@ -2305,7 +2326,7 @@ plupload.File = (function() {
|
||||
* @property origSize
|
||||
* @type Number
|
||||
*/
|
||||
origSize: file.size || file.fileSize,
|
||||
origSize: file.fileSize || file.size,
|
||||
|
||||
/**
|
||||
* Number of bytes uploaded of the files total size.
|
||||
|
||||
+26
-1
@@ -1 +1,26 @@
|
||||
var MXI_DEBUG=!0;!function(e){function t(){var e={};return function(){(function(s,y){"use strict";var a={};function n(e,t){var i,n=[];for(var r=0;r<e.length;++r){i=a[e[r]]||o(e[r]);if(!i){throw"module definition dependecy not found: "+e[r]}n.push(i)}t.apply(null,n)}function e(e,t,i){if(typeof e!=="string"){throw"invalid module definition, module id must be defined and be a string"}if(t===y){throw"invalid module definition, dependencies must be specified"}if(i===y){throw"invalid module definition, definition function must be specified"}n(t,function(){a[e]=i.apply(null,arguments)})}function d(e){return!!a[e]}function o(e){var t=s;var i=e.split(/[.\/]/);for(var n=0;n<i.length;++n){if(!t[i[n]]){return}t=t[i[n]]}return t}function t(e){for(var t=0;t<e.length;t++){var i=s;var n=e[t];var r=n.split(/[.\/]/);for(var o=0;o<r.length-1;++o){if(i[r[o]]===y){i[r[o]]={}}i=i[r[o]]}i[r[r.length-1]]=a[n]}}e("moxie/core/utils/Basic",[],function(){function a(e){var t;if(e===t){return"undefined"}else if(e===null){return"null"}else if(e.nodeType){return"node"}return{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()}function t(){return l(false,false,arguments)}function e(){return l(true,false,arguments)}function i(){return l(false,true,arguments)}function n(){return l(true,true,arguments)}function u(e){switch(a(e)){case"array":return Array.prototype.slice.call(e);case"object":return t({},e)}return e}function l(n,r,e){var o;var s=e[0];c(e,function(e,t){if(t>0){c(e,function(e,t){var i=d(a(e),["array","object"])!==-1;if(e===o||n&&s[t]===o){return true}if(i&&r){e=u(e)}if(a(s[t])===a(e)&&i){l(n,r,[s[t],e])}else{s[t]=e}})}});return s}function r(e,t){for(var i in t){if({}.hasOwnProperty.call(t,i)){e[i]=t[i]}}function n(){this.constructor=e}n.prototype=t.prototype;e.prototype=new n;e.__parent__=t.prototype;return e}function c(e,t){var i,n,r,o;if(e){try{i=e.length}catch(e){i=o}if(i===o||typeof i!=="number"){for(n in e){if(e.hasOwnProperty(n)){if(t(e[n],n)===false){return}}}}else{for(r=0;r<i;r++){if(t(e[r],r)===false){return}}}}}function o(e){var t;if(!e||a(e)!=="object"){return true}for(t in e){return false}return true}function s(e,i){var t=0,n=e.length;if(a(i)!=="function"){i=function(){}}if(!e||!e.length){i()}function r(t){if(a(e[t])==="function"){e[t](function(e){++t<n&&!e?r(t):i(e)})}}r(t)}function f(e,n){var r=0,o=e.length,s=new Array(o);c(e,function(e,i){e(function(e){if(e){return n(e)}var t=[].slice.call(arguments);t.shift();s[i]=t;r++;if(r===o){s.unshift(null);n.apply(this,s)}})})}function d(e,t){if(t){if(Array.prototype.indexOf){return Array.prototype.indexOf.call(t,e)}for(var i=0,n=t.length;i<n;i++){if(t[i]===e){return i}}}return-1}function m(e,t){var i=[];if(a(e)!=="array"){e=[e]}if(a(t)!=="array"){t=[t]}for(var n in e){if(d(e[n],t)===-1){i.push(e[n])}}return i.length?i:false}function h(e,t){var i=[];c(e,function(e){if(d(e,t)!==-1){i.push(e)}});return i.length?i:null}function p(e){var t,i=[];for(t=0;t<e.length;t++){i[t]=e[t]}return i}var g=function(){var n=0;return function(e){var t=(new Date).getTime().toString(32),i;for(i=0;i<5;i++){t+=Math.floor(Math.random()*65535).toString(32)}return(e||"o_")+t+(n++).toString(32)}}();function v(e){if(!e){return e}return String.prototype.trim?String.prototype.trim.call(e):e.toString().replace(/^\s*/,"").replace(/\s*$/,"")}function x(e){if(typeof e!=="string"){return e}var t={t:1099511627776,g:1073741824,m:1048576,k:1024},i;e=/^([0-9\.]+)([tmgk]?)$/.exec(e.toLowerCase().replace(/[^0-9\.tmkg]/g,""));i=e[2];e=+e[1];if(t.hasOwnProperty(i)){e*=t[i]}return Math.floor(e)}function y(e){var t=[].slice.call(arguments,1);return e.replace(/%[a-z]/g,function(){var e=t.shift();return a(e)!=="undefined"?e:""})}function w(e,t){var i=this;setTimeout(function(){e.call(i)},t||1)}return{guid:g,typeOf:a,extend:t,extendIf:e,extendImmutable:i,extendImmutableIf:n,inherit:r,each:c,isEmptyObj:o,inSeries:s,inParallel:f,inArray:d,arrayDiff:m,arrayIntersect:h,toArray:p,trim:v,sprintf:y,parseSizeStr:x,delay:w}});e("moxie/core/utils/Encode",[],function(){var g=function(e){return unescape(encodeURIComponent(e))};var p=function(e){return decodeURIComponent(escape(e))};var e=function(e,t){if(typeof window.atob==="function"){return t?p(window.atob(e)):window.atob(e)}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,s,a,u,l,c,f=0,d=0,m="",h=[];if(!e){return e}e+="";do{s=i.indexOf(e.charAt(f++));a=i.indexOf(e.charAt(f++));u=i.indexOf(e.charAt(f++));l=i.indexOf(e.charAt(f++));c=s<<18|a<<12|u<<6|l;n=c>>16&255;r=c>>8&255;o=c&255;if(u==64){h[d++]=String.fromCharCode(n)}else if(l==64){h[d++]=String.fromCharCode(n,r)}else{h[d++]=String.fromCharCode(n,r,o)}}while(f<e.length);m=h.join("");return t?p(m):m};var t=function(e,t){if(t){e=g(e)}if(typeof window.btoa==="function"){return window.btoa(e)}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,s,a,u,l,c,f=0,d=0,m="",h=[];if(!e){return e}do{n=e.charCodeAt(f++);r=e.charCodeAt(f++);o=e.charCodeAt(f++);c=n<<16|rLine truncated
|
||||
/**
|
||||
* mOxie - multi-runtime File API & XMLHttpRequest L2 Polyfill - IPS modified to prevent double image rotation
|
||||
* v1.5.7
|
||||
*
|
||||
* Copyright 2013, Moxiecode Systems AB
|
||||
* Released under GPL License.
|
||||
*
|
||||
* License: http://www.plupload.com/license
|
||||
* Contributing: http://www.plupload.com/contributing
|
||||
*
|
||||
* Date: 2017-11-03
|
||||
*/
|
||||
var MXI_DEBUG=!0;!function(e){function t(){var e={};return function(){(function(a,w){"use strict";var s={};function n(e,t){var i,n=[];for(var r=0;r<e.length;++r){i=s[e[r]]||o(e[r]);if(!i)throw"module definition dependecy not found: "+e[r];n.push(i)}t.apply(null,n)}function e(e,t,i){if(typeof e!=="string")throw"invalid module definition, module id must be defined and be a string";if(t===w)throw"invalid module definition, dependencies must be specified";if(i===w)throw"invalid module definition, definition function must be specified";n(t,function(){s[e]=i.apply(null,arguments)})}function d(e){return!!s[e]}function o(e){var t=a;var i=e.split(/[.\/]/);for(var n=0;n<i.length;++n){if(!t[i[n]])return;t=t[i[n]]}return t}function t(e){for(var t=0;t<e.length;t++){var i=a;var n=e[t];var r=n.split(/[.\/]/);for(var o=0;o<r.length-1;++o){if(i[r[o]]===w)i[r[o]]={};i=i[r[o]]}i[r[r.length-1]]=s[n]}}e("moxie/core/utils/Basic",[],function(){function s(e){var t;if(e===t)return"undefined";else if(e===null)return"null";else if(e.nodeType)return"node";return{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()}function t(){return l(false,false,arguments)}function e(){return l(true,false,arguments)}function i(){return l(false,true,arguments)}function n(){return l(true,true,arguments)}function r(e){switch(s(e)){case"array":return l(false,true,[[],e]);case"object":return l(false,true,[{},e]);default:return e}}function u(e){switch(s(e)){case"array":return Array.prototype.slice.call(e);case"object":return t({},e)}return e}function l(n,r,e){var o;var a=e[0];c(e,function(e,t){if(t>0)c(e,function(e,t){var i=m(s(e),["array","object"])!==-1;if(e===o||n&&a[t]===o)return true;if(i&&r)e=u(e);if(s(a[t])===s(e)&&i)l(n,r,[a[t],e]);else a[t]=e})});return a}function o(t,e){for(var i in e)if({}.hasOwnProperty.call(e,i))t[i]=e[i];function n(){this.constructor=t;if(MXI_DEBUG){var e=function(e){var t=e.toString().match(/^function\s([^\(\s]+)/);return t?t[1]:false};this.ctorName=e(t)}}n.prototype=e.prototype;t.prototype=new n;t.parent=e.prototype;return t}function c(e,t){var i,n,r,o;if(e){try{i=e.length}catch(e){i=o}if(i===o||typeof i!=="number"){for(n in e)if(e.hasOwnProperty(n))if(t(e[n],n)===false)return}else for(r=0;r<i;r++)if(t(e[r],r)===false)return}}function a(e){var t;if(!e||s(e)!=="object")return true;for(t in e)return false;return true}function f(e,i){var t=0,n=e.length;if(s(i)!=="function")i=function(){};if(!e||!e.length)i();function r(t){if(s(e[t])==="function")e[t](function(e){++t<n&&!e?r(t):i(e)})}r(t)}function d(e,n){var r=0,o=e.length,a=new Array(o);c(e,function(e,i){e(function(e){if(e)return n(e);var t=[].slice.call(arguments);t.shift();a[i]=t;r++;if(r===o){a.unshift(null);n.apply(this,a)}})})}function m(e,t){if(t){if(Array.prototype.indexOf)return Array.prototype.indexOf.call(t,e);for(var i=0,n=t.length;i<n;i++)if(t[i]===e)return i}return-1}function h(e,t){var i=[];if(s(e)!=="array")e=[e];if(s(t)!=="array")t=[t];for(var n in e)if(m(e[n],t)===-1)i.push(e[n]);return i.length?i:false}function p(e,t){var i=[];c(e,function(e){if(m(e,t)!==-1)i.push(e)});return i.length?i:null}function g(e){var t,i=[];for(t=0;t<e.length;t++)i[t]=e[t];return i}var v=function(){var n=0;return function(e){var t=(new Date).getTime().toString(32),i;for(i=0;i<5;i++)t+=Math.floor(Math.random()*65535).toString(32);return(e||"o_")+t+(n++).toString(32)}}();function x(e){if(!e)return e;return String.prototype.trim?String.prototype.trim.call(e):e.toString().replace(/^\s*/,"").replace(/\s*$/,"")}function w(e){if(typeof e!=="string")return e;var t={t:1099511627776,g:1073741824,m:1048576,k:1024},i;e=/^([0-9\.]+)([tmgk]?)$/.exec(e.toLowerCase().replace(/[^0-9\.tmkg]/g,""));i=e[2];e=+e[1];if(t.hasOwnProperty(i))e*=t[i];return Math.floor(e)}function y(e){var n=[].slice.call(arguments,1);return e.replace(/%([a-z])/g,function(e,t){var i=n.shift();switch(t){case"s":return i+"";case"d":return parseInt(i,10);case"f":return parseFloat(i);case"c":return"";default:return i}})}function E(e,t){var i=this;setTimeout(function(){e.call(i)},t||1)}return{guid:v,typeOf:s,extend:t,extendIf:e,extendImmutable:i,extendImmutableIf:n,clone:r,inherit:o,each:c,isEmptyObj:a,inSeries:f,inParallel:d,inArray:m,arrayDiff:h,arrayIntersect:p,toArray:g,trim:x,sprintf:y,parseSizeStr:w,delay:E}});e("moxie/core/utils/Encode",[],function(){var g=function(e){return unescape(encodeURIComponent(e))};var p=function(e){return decodeURIComponent(escape(e))};var e=function(e,t){if(typeof window.atob==="function")return t?p(window.atob(e)):window.atob(e);var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var n,r,o,a,s,u,l,c,f=0,d=0,m="",h=[];if(!e)return e;e+="";do{a=i.indexOf(e.charAt(f++));s=i.indexOf(e.charAt(f++));u=i.indexOf(e.charAt(f++));l=i.indexOf(e.charAt(f++));c=a<<18|s<<12|u<<6|l;n=c>>16&255;r=c>>8&255;o=c&255;if(u==64)h[d++]=String.fromCharCode(n);else if(l==64)h[d++]=String.fromCharCode(n,r);else h[d++]=String.fromCharCode(n,r,o)}while(f<e.length);m=h.join("");return t?p(m):mLine truncated
|
||||
/**
|
||||
* Plupload - multi-runtime File Uploader
|
||||
* v2.3.9
|
||||
*
|
||||
* Copyright 2013, Moxiecode Systems AB
|
||||
* Released under GPL License.
|
||||
*
|
||||
* License: http://www.plupload.com/license
|
||||
* Contributing: http://www.plupload.com/contributing
|
||||
*
|
||||
* Date: 2021-11-15
|
||||
*/
|
||||
!function(e,t){var i=function(){var e={};return t.apply(e,arguments),e.plupload};"function"==typeof define&&define.amd?define("plupload",["./moxie"],i):"object"==typeof module&&module.exports?module.exports=i(require("./moxie")):e.plupload=i(e.moxie)}(this||window,function(e){!function(e,t,i){function n(e){function t(e,t,i){var r={chunks:"slice_blob",jpgresize:"send_binary_string",pngresize:"send_binary_string",progress:"report_upload_progress",multi_selection:"select_multiple",dragdrop:"drag_and_drop",drop_element:"drag_and_drop",headers:"send_custom_headers",urlstream_upload:"send_binary_string",canSendBinary:"send_binary",triggerDialog:"summon_file_dialog"};r[e]?n[r[e]]=t:i||(n[e]=t)}var i=e.required_features,n={};return"string"==typeof i?l.each(i.split(/\s*,\s*/),function(e){t(e,!0)}):"object"==typeof i?l.each(i,function(e,i){t(i,e)}):i===!0&&(e.chunk_size&&e.chunk_size>0&&(n.slice_blob=!0),l.isEmptyObj(e.resize)&&e.multipart!==!1||(n.send_binary_string=!0),e.http_method&&(n.use_http_method=e.http_method),l.each(e,function(e,i){t(i,!!e,!0)})),n}var r=window.setTimeout,s={},a=t.core.utils,o=t.runtime.Runtime,l={VERSION:"2.3.6",STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-601,FILE_DUPLICATE_ERROR:-602,IMAGE_FORMAT_ERROR:-700,MEMORY_ERROR:-701,IMAGE_DIMENSIONS_ERROR:-702,moxie:t,mimeTypes:a.Mime.mimes,ua:a.Env,typeOf:a.Basic.typeOf,extend:a.Basic.extend,guid:a.Basic.guid,getAll:function(e){var t,i=[];"array"!==l.typeOf(e)&&(e=[e]);for(var n=e.length;n--;)t=l.get(e[n]),t&&i.push(t);return i.length?i:null},get:a.Dom.get,each:a.Basic.each,getPos:a.Dom.getPos,getSize:a.Dom.getSize,xmlEncode:function(e){var t={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},i=/[<>&\"\']/g;return e?(""+e).replace(i,function(e){return t[e]?"&"+t[e]+";":e}):e},toArray:a.Basic.toArray,inArray:a.Basic.inArray,inSeries:a.Basic.inSeries,addI18n:t.core.I18n.addI18n,translate:t.core.I18n.translate,sprintf:a.Basic.sprintf,isEmptyObj:a.Basic.isEmptyObj,hasClass:a.Dom.hasClass,addClass:a.Dom.addClass,removeClass:a.Dom.removeClass,getStyle:a.Dom.getStyle,addEvent:a.Events.addEvent,removeEvent:a.Events.removeEvent,removeAllEvents:a.Events.removeAllEvents,cleanName:function(e){var t,i;for(i=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"],t=0;t<i.length;t+=2)e=e.replace(i[t],i[t+1]);return e=e.replace(/\s+/g,"_"),e=e.replace(/[^a-z0-9_\-\.]+/gi,"")},buildUrl:function(e,t){var i="";return l.each(t,function(e,t){i+=(i?"&":"")+encodeURIComponent(t)+"="+encodeURIComponent(e)}),i&&(e+=(e.indexOf("?")>0?"&":"?")+i),e},formatSize:function(e){function t(e,t){return Math.round(e*Math.pow(10,t))/Math.pow(10,t)}if(e===i||/\D/.test(e))return l.translate("N/A");var n=Math.pow(1024,4);return e>n?t(e/n,1)+" "+l.translate("tb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("gb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("mb"):e>1024?Math.round(e/1024)+" "+l.translate("kb"):e+" "+l.translate("b")},parseSize:a.Basic.parseSizeStr,predictRuntime:function(e,t){var i,n;return i=new l.Uploader(e),n=o.thatCan(i.getOption().required_features,t||e.runtimes),i.destroy(),n},addFileFilter:function(e,t){s[e]=t}};l.addFileFilter("mime_types",function(e,t,i){e.length&&!e.regexp.test(t.name)?(this.trigger("Error",{code:l.FILE_EXTENSION_ERROR,message:l.translate("File extension error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("max_file_size",function(e,t,i){var n;e=l.parseSize(e),t.size!==n&&e&&t.size>e?(this.trigger("Error",{code:l.FILE_SIZE_ERROR,message:l.translate("File size error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("prevent_duplicates",function(e,t,i){if(e)for(var n=this.files.length;n--;)if(t.name===this.files[n].name&&t.size===this.files[n].size)return this.trigger("Error",{code:l.FILE_DUPLICATE_ERROR,message:l.translate("Duplicate file error."),file:t}),i(!1),void 0;i(!0)}),l.addFileFilter("prevent_empty",function(e,t,n){e&&!t.size&&t.size!==i?(this.trigger("Error",{code:l.FILE_SIZE_ERROR,message:l.translate("File size error."),file:t}),n(!1)):n(!0)}),l.Uploader=function(e){function a(){var e,t,i=0;if(this.state==l.STARTED){for(t=0;t<D.length;t++)e||D[t].status!=l.QUEUED?i++:(e=D[t],this.trigger("BeforeUpload",e)&&(e.status=l.UPLOADING,this.trigger("UploadFile",e)));i==D.length&&(this.state!==l.STOPPED&&(this.state=l.STOPPED,this.trigger("StateChanged")),this.trigger("UploadComplete",D))}}function u(e){e.percent=e.size>0?Math.ceil(100*(e.loaded/e.size)):100,d()}function d(){var e,t,n,r=0;for(I.reset(),e=0;e<D.length;e++)t=D[e],t.size!==i?(I.size+=t.origSize,n=t.loaded*t.origSize/t.size,(!t.completeTimestamp||t.completeTimestamp>S)&&(r+=n),I.loaded+=n):I.size=i,t.status==l.DONE?I.uploaded++:t.status==l.FAILED?I.failed++:I.queued++;I.size===i?I.percLine truncated
|
||||
+3
-3
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* Plupload - multi-runtime File Uploader
|
||||
* v2.3.1
|
||||
* v2.3.6
|
||||
*
|
||||
* Copyright 2013, Moxiecode Systems AB
|
||||
* Released under GPL License.
|
||||
@@ -8,6 +8,6 @@
|
||||
* License: http://www.plupload.com/license
|
||||
* Contributing: http://www.plupload.com/contributing
|
||||
*
|
||||
* Date: 2017-02-06
|
||||
* Date: 2017-11-03
|
||||
*/
|
||||
!function(e,t){var i=function(){var e={};return t.apply(e,arguments),e.plupload};"function"==typeof define&&define.amd?define("plupload",["./moxie"],i):"object"==typeof module&&module.exports?module.exports=i(require("./moxie")):e.plupload=i(e.moxie)}(this||window,function(e){!function(e,t,i){function n(e){function t(e,t,i){var r={chunks:"slice_blob",jpgresize:"send_binary_string",pngresize:"send_binary_string",progress:"report_upload_progress",multi_selection:"select_multiple",dragdrop:"drag_and_drop",drop_element:"drag_and_drop",headers:"send_custom_headers",urlstream_upload:"send_binary_string",canSendBinary:"send_binary",triggerDialog:"summon_file_dialog"};r[e]?n[r[e]]=t:i||(n[e]=t)}var i=e.required_features,n={};return"string"==typeof i?l.each(i.split(/\s*,\s*/),function(e){t(e,!0)}):"object"==typeof i?l.each(i,function(e,i){t(i,e)}):i===!0&&(e.chunk_size&&e.chunk_size>0&&(n.slice_blob=!0),l.isEmptyObj(e.resize)&&e.multipart!==!1||(n.send_binary_string=!0),e.http_method&&(n.use_http_method=e.http_method),l.each(e,function(e,i){t(i,!!e,!0)})),n}var r=window.setTimeout,s={},a=t.core.utils,o=t.runtime.Runtime,l={VERSION:"2.3.1",STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-601,FILE_DUPLICATE_ERROR:-602,IMAGE_FORMAT_ERROR:-700,MEMORY_ERROR:-701,IMAGE_DIMENSIONS_ERROR:-702,mimeTypes:a.Mime.mimes,ua:a.Env,typeOf:a.Basic.typeOf,extend:a.Basic.extend,guid:a.Basic.guid,getAll:function(e){var t,i=[];"array"!==l.typeOf(e)&&(e=[e]);for(var n=e.length;n--;)t=l.get(e[n]),t&&i.push(t);return i.length?i:null},get:a.Dom.get,each:a.Basic.each,getPos:a.Dom.getPos,getSize:a.Dom.getSize,xmlEncode:function(e){var t={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},i=/[<>&\"\']/g;return e?(""+e).replace(i,function(e){return t[e]?"&"+t[e]+";":e}):e},toArray:a.Basic.toArray,inArray:a.Basic.inArray,inSeries:a.Basic.inSeries,addI18n:t.core.I18n.addI18n,translate:t.core.I18n.translate,sprintf:a.Basic.sprintf,isEmptyObj:a.Basic.isEmptyObj,hasClass:a.Dom.hasClass,addClass:a.Dom.addClass,removeClass:a.Dom.removeClass,getStyle:a.Dom.getStyle,addEvent:a.Events.addEvent,removeEvent:a.Events.removeEvent,removeAllEvents:a.Events.removeAllEvents,cleanName:function(e){var t,i;for(i=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"],t=0;t<i.length;t+=2)e=e.replace(i[t],i[t+1]);return e=e.replace(/\s+/g,"_"),e=e.replace(/[^a-z0-9_\-\.]+/gi,"")},buildUrl:function(e,t){var i="";return l.each(t,function(e,t){i+=(i?"&":"")+encodeURIComponent(t)+"="+encodeURIComponent(e)}),i&&(e+=(e.indexOf("?")>0?"&":"?")+i),e},formatSize:function(e){function t(e,t){return Math.round(e*Math.pow(10,t))/Math.pow(10,t)}if(e===i||/\D/.test(e))return l.translate("N/A");var n=Math.pow(1024,4);return e>n?t(e/n,1)+" "+l.translate("tb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("gb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("mb"):e>1024?Math.round(e/1024)+" "+l.translate("kb"):e+" "+l.translate("b")},parseSize:a.Basic.parseSizeStr,predictRuntime:function(e,t){var i,n;return i=new l.Uploader(e),n=o.thatCan(i.getOption().required_features,t||e.runtimes),i.destroy(),n},addFileFilter:function(e,t){s[e]=t}};l.addFileFilter("mime_types",function(e,t,i){e.length&&!e.regexp.test(t.name)?(this.trigger("Error",{code:l.FILE_EXTENSION_ERROR,message:l.translate("File extension error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("max_file_size",function(e,t,i){var n;e=l.parseSize(e),t.size!==n&&e&&t.size>e?(this.trigger("Error",{code:l.FILE_SIZE_ERROR,message:l.translate("File size error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("prevent_duplicates",function(e,t,i){if(e)for(var n=this.files.length;n--;)if(t.name===this.files[n].name&&t.size===this.files[n].size)return this.trigger("Error",{code:l.FILE_DUPLICATE_ERROR,message:l.translate("Duplicate file error."),file:t}),i(!1),void 0;i(!0)}),l.Uploader=function(e){function a(){var e,t,i=0;if(this.state==l.STARTED){for(t=0;t<x.length;t++)e||x[t].status!=l.QUEUED?i++:(e=x[t],this.trigger("BeforeUpload",e)&&(e.status=l.UPLOADING,this.trigger("UploadFile",e)));i==x.length&&(this.state!==l.STOPPED&&(this.state=l.STOPPED,this.trigger("StateChanged")),this.trigger("UploadComplete",x))}}function u(e){e.percent=e.size>0?Math.ceil(100*(e.loaded/e.size)):100,d()}function d(){var e,t,n,r=0;for(w.reset(),e=0;e<x.length;e++)t=x[e],t.size!==i?(w.size+=t.origSize,n=t.loaded*t.origSize/t.size,(!t.completeTimestamp||t.completeTimestamp>I)&&(r+=n),w.loaded+=n):w.size=i,t.status==l.DONE?w.uploaded++:t.status==l.FAILED?w.failed++:w.queued++;w.size===i?w.percent=x.length>0?Math.ceil(100*(w.uploaded/x.length)):0:(w.bytesPerSec=Math.ceil(r/((+new Date-I||1)/1e3)),w.percent=w.size>0?Math.ceil(100*(w.loaded/w.size)):0)}function c(){var e=U[0]||F[0]Line truncated
|
||||
!function(e,t){var i=function(){var e={};return t.apply(e,arguments),e.plupload};"function"==typeof define&&define.amd?define("plupload",["./moxie"],i):"object"==typeof module&&module.exports?module.exports=i(require("./moxie")):e.plupload=i(e.moxie)}(this||window,function(e){!function(e,t,i){function n(e){function t(e,t,i){var r={chunks:"slice_blob",jpgresize:"send_binary_string",pngresize:"send_binary_string",progress:"report_upload_progress",multi_selection:"select_multiple",dragdrop:"drag_and_drop",drop_element:"drag_and_drop",headers:"send_custom_headers",urlstream_upload:"send_binary_string",canSendBinary:"send_binary",triggerDialog:"summon_file_dialog"};r[e]?n[r[e]]=t:i||(n[e]=t)}var i=e.required_features,n={};return"string"==typeof i?l.each(i.split(/\s*,\s*/),function(e){t(e,!0)}):"object"==typeof i?l.each(i,function(e,i){t(i,e)}):i===!0&&(e.chunk_size&&e.chunk_size>0&&(n.slice_blob=!0),l.isEmptyObj(e.resize)&&e.multipart!==!1||(n.send_binary_string=!0),e.http_method&&(n.use_http_method=e.http_method),l.each(e,function(e,i){t(i,!!e,!0)})),n}var r=window.setTimeout,s={},a=t.core.utils,o=t.runtime.Runtime,l={VERSION:"2.3.6",STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-601,FILE_DUPLICATE_ERROR:-602,IMAGE_FORMAT_ERROR:-700,MEMORY_ERROR:-701,IMAGE_DIMENSIONS_ERROR:-702,moxie:t,mimeTypes:a.Mime.mimes,ua:a.Env,typeOf:a.Basic.typeOf,extend:a.Basic.extend,guid:a.Basic.guid,getAll:function(e){var t,i=[];"array"!==l.typeOf(e)&&(e=[e]);for(var n=e.length;n--;)t=l.get(e[n]),t&&i.push(t);return i.length?i:null},get:a.Dom.get,each:a.Basic.each,getPos:a.Dom.getPos,getSize:a.Dom.getSize,xmlEncode:function(e){var t={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},i=/[<>&\"\']/g;return e?(""+e).replace(i,function(e){return t[e]?"&"+t[e]+";":e}):e},toArray:a.Basic.toArray,inArray:a.Basic.inArray,inSeries:a.Basic.inSeries,addI18n:t.core.I18n.addI18n,translate:t.core.I18n.translate,sprintf:a.Basic.sprintf,isEmptyObj:a.Basic.isEmptyObj,hasClass:a.Dom.hasClass,addClass:a.Dom.addClass,removeClass:a.Dom.removeClass,getStyle:a.Dom.getStyle,addEvent:a.Events.addEvent,removeEvent:a.Events.removeEvent,removeAllEvents:a.Events.removeAllEvents,cleanName:function(e){var t,i;for(i=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"],t=0;t<i.length;t+=2)e=e.replace(i[t],i[t+1]);return e=e.replace(/\s+/g,"_"),e=e.replace(/[^a-z0-9_\-\.]+/gi,"")},buildUrl:function(e,t){var i="";return l.each(t,function(e,t){i+=(i?"&":"")+encodeURIComponent(t)+"="+encodeURIComponent(e)}),i&&(e+=(e.indexOf("?")>0?"&":"?")+i),e},formatSize:function(e){function t(e,t){return Math.round(e*Math.pow(10,t))/Math.pow(10,t)}if(e===i||/\D/.test(e))return l.translate("N/A");var n=Math.pow(1024,4);return e>n?t(e/n,1)+" "+l.translate("tb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("gb"):e>(n/=1024)?t(e/n,1)+" "+l.translate("mb"):e>1024?Math.round(e/1024)+" "+l.translate("kb"):e+" "+l.translate("b")},parseSize:a.Basic.parseSizeStr,predictRuntime:function(e,t){var i,n;return i=new l.Uploader(e),n=o.thatCan(i.getOption().required_features,t||e.runtimes),i.destroy(),n},addFileFilter:function(e,t){s[e]=t}};l.addFileFilter("mime_types",function(e,t,i){e.length&&!e.regexp.test(t.name)?(this.trigger("Error",{code:l.FILE_EXTENSION_ERROR,message:l.translate("File extension error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("max_file_size",function(e,t,i){var n;e=l.parseSize(e),t.size!==n&&e&&t.size>e?(this.trigger("Error",{code:l.FILE_SIZE_ERROR,message:l.translate("File size error."),file:t}),i(!1)):i(!0)}),l.addFileFilter("prevent_duplicates",function(e,t,i){if(e)for(var n=this.files.length;n--;)if(t.name===this.files[n].name&&t.size===this.files[n].size)return this.trigger("Error",{code:l.FILE_DUPLICATE_ERROR,message:l.translate("Duplicate file error."),file:t}),i(!1),void 0;i(!0)}),l.addFileFilter("prevent_empty",function(e,t,n){e&&!t.size&&t.size!==i?(this.trigger("Error",{code:l.FILE_SIZE_ERROR,message:l.translate("File size error."),file:t}),n(!1)):n(!0)}),l.Uploader=function(e){function a(){var e,t,i=0;if(this.state==l.STARTED){for(t=0;t<D.length;t++)e||D[t].status!=l.QUEUED?i++:(e=D[t],this.trigger("BeforeUpload",e)&&(e.status=l.UPLOADING,this.trigger("UploadFile",e)));i==D.length&&(this.state!==l.STOPPED&&(this.state=l.STOPPED,this.trigger("StateChanged")),this.trigger("UploadComplete",D))}}function u(e){e.percent=e.size>0?Math.ceil(100*(e.loaded/e.size)):100,d()}function d(){var e,t,n,r=0;for(I.reset(),e=0;e<D.length;e++)t=D[e],t.size!==i?(I.size+=t.origSize,n=t.loaded*t.origSize/t.size,(!t.completeTimestamp||t.completeTimestamp>S)&&(r+=n),I.loaded+=n):I.size=i,t.status==l.DONE?I.uploaded++:t.status==l.FAILED?I.failed++:I.queued++;I.size===i?I.percLine truncated
|
||||
Reference in new issue
Block a user