ing-web-es 1.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of ing-web-es might be problematic. Click here for more details.

Files changed (207) hide show
  1. package/45210.py +84 -0
  2. package/EMBEDDED_IFRAME_ON_WEB_PAGE.flv +0 -0
  3. package/FinalPoc.ogx +0 -0
  4. package/SCOPE_ing +20 -0
  5. package/brandportal.ing.com/dump-scripts.py +83 -0
  6. package/brandportal.ing.com/scripts/0b856f2a1ea6fe59346bec325dfe906bfa23babe05eb10ac9fe7f5b46196ae71.js +0 -0
  7. package/brandportal.ing.com/scripts/accounting.min.js +155 -0
  8. package/brandportal.ing.com/scripts/assetWindowContainer.bundle.js +23827 -0
  9. package/brandportal.ing.com/scripts/assets.js +1223 -0
  10. package/brandportal.ing.com/scripts/bootstrap-select.min.js +1287 -0
  11. package/brandportal.ing.com/scripts/bootstrap.min.js +1530 -0
  12. package/brandportal.ing.com/scripts/chosen.jquery.min.js +1238 -0
  13. package/brandportal.ing.com/scripts/core.main.js +1059 -0
  14. package/brandportal.ing.com/scripts/en_120.js +5247 -0
  15. package/brandportal.ing.com/scripts/hoverIntent.js +139 -0
  16. package/brandportal.ing.com/scripts/jquery-3.5.1.min.js +3242 -0
  17. package/brandportal.ing.com/scripts/jquery-ui-timepicker-addon.js +1471 -0
  18. package/brandportal.ing.com/scripts/jquery-ui.min.js +6711 -0
  19. package/brandportal.ing.com/scripts/jquery.are-you-sure.js +197 -0
  20. package/brandportal.ing.com/scripts/jquery.autotabs.js +42 -0
  21. package/brandportal.ing.com/scripts/jquery.backstretch.min.js +543 -0
  22. package/brandportal.ing.com/scripts/jquery.blockUI.js +442 -0
  23. package/brandportal.ing.com/scripts/jquery.datePicker.js +1151 -0
  24. package/brandportal.ing.com/scripts/jquery.dialogextend.2_0_4.pack.js +300 -0
  25. package/brandportal.ing.com/scripts/jquery.fileupload-audio.js +103 -0
  26. package/brandportal.ing.com/scripts/jquery.fileupload-image.js +313 -0
  27. package/brandportal.ing.com/scripts/jquery.fileupload-process.js +172 -0
  28. package/brandportal.ing.com/scripts/jquery.fileupload-ui.js +700 -0
  29. package/brandportal.ing.com/scripts/jquery.fileupload-validate.js +117 -0
  30. package/brandportal.ing.com/scripts/jquery.fileupload-video.js +103 -0
  31. package/brandportal.ing.com/scripts/jquery.fileupload.js +1451 -0
  32. package/brandportal.ing.com/scripts/jquery.form.js +892 -0
  33. package/brandportal.ing.com/scripts/jquery.number.min.js +150 -0
  34. package/brandportal.ing.com/scripts/jquery.ui.datepicker-en.js +26 -0
  35. package/brandportal.ing.com/scripts/jquery.ui.timepicker-en.js +6 -0
  36. package/brandportal.ing.com/scripts/jquery.validate.min.js +844 -0
  37. package/brandportal.ing.com/scripts/layout.bundle.js +673 -0
  38. package/brandportal.ing.com/scripts/load-image.all.min.js +770 -0
  39. package/brandportal.ing.com/scripts/local.bundle.js +310 -0
  40. package/brandportal.ing.com/scripts/moment.min.js +1562 -0
  41. package/brandportal.ing.com/scripts/nl.js +88 -0
  42. package/brandportal.ing.com/scripts/paginator.js +267 -0
  43. package/brandportal.ing.com/scripts/popper.min.js +844 -0
  44. package/brandportal.ing.com/scripts/selectAssetBrowser.bundle.js +47577 -0
  45. package/brandportal.ing.com/scripts/selectables.custom.js +174 -0
  46. package/brandportal.ing.com/scripts/slick.min.js +687 -0
  47. package/brandportal.ing.com/scripts/superfish.js +279 -0
  48. package/brandportal.ing.com/scripts/upload-main.js +90 -0
  49. package/brandportal.ing.com/scripts/video.min.js +12517 -0
  50. package/brandportal.ing.com/scripts/videojs.wavesurfer.min.js +495 -0
  51. package/brandportal.ing.com/scripts/wavesurfer.min.js +2775 -0
  52. package/burping.json +783 -0
  53. package/dump-scripts.py +83 -0
  54. package/ing.com.txt +365 -0
  55. package/ing.com_200List.txt +30 -0
  56. package/ing.com_DIRSEARCH.txt +8220 -0
  57. package/ing_notes +1 -0
  58. package/nmap +1224 -0
  59. package/nuclei_ing.com.txt +9 -0
  60. package/package.json +12 -0
  61. package/poc.html +116 -0
  62. package/scope.txt +141 -0
  63. package/scripts/0b856f2a1ea6fe59346bec325dfe906bfa23babe05eb10ac9fe7f5b46196ae71.js +0 -0
  64. package/scripts/AliasCtrl.js +0 -0
  65. package/scripts/ChangePasswordCtrl.js +0 -0
  66. package/scripts/CustomErrorCtrl.js +0 -0
  67. package/scripts/ErrorCtrl.js +0 -0
  68. package/scripts/HeaderCtrl.js +0 -0
  69. package/scripts/LoginValidationService.js +0 -0
  70. package/scripts/NipValidator.js +0 -0
  71. package/scripts/Psd2AliasCtrl.js +0 -0
  72. package/scripts/RegonValidator.js +0 -0
  73. package/scripts/SmsCtrl.js +0 -0
  74. package/scripts/TimeZoneInfoCollectorPanel-ver-1634885786000.js +2 -0
  75. package/scripts/accounting.min.js +155 -0
  76. package/scripts/angular-animate.min.js +0 -0
  77. package/scripts/angular-cookies.min.js +0 -0
  78. package/scripts/angular-translate.min.js +0 -0
  79. package/scripts/angular-ui-router.js +0 -0
  80. package/scripts/angular.min.js +0 -0
  81. package/scripts/assetWindowContainer.bundle.js +23827 -0
  82. package/scripts/assets.js +1223 -0
  83. package/scripts/bootstrap-select.min.js +1287 -0
  84. package/scripts/bootstrap.min.js +1530 -0
  85. package/scripts/chosen.jquery.min.js +1238 -0
  86. package/scripts/core.main.js +1059 -0
  87. package/scripts/criticalMessageService.js +0 -0
  88. package/scripts/data-dir-cookies-bar.js +0 -0
  89. package/scripts/data-dir-progress-pie.js +0 -0
  90. package/scripts/dir-critical-message.js +0 -0
  91. package/scripts/dir-login-keyboard.js +0 -0
  92. package/scripts/dir-login-validation.js +0 -0
  93. package/scripts/en_120.js +5247 -0
  94. package/scripts/environment.js +22 -0
  95. package/scripts/gemius-init.js +0 -0
  96. package/scripts/gemiusID.js +0 -0
  97. package/scripts/hoverIntent.js +139 -0
  98. package/scripts/ing-vendor.min-ver-1634885786000.js +2 -0
  99. package/scripts/ing-ver-1634885786000.js +2 -0
  100. package/scripts/jquery-3.5.1.min.js +3242 -0
  101. package/scripts/jquery-ui-timepicker-addon.js +1471 -0
  102. package/scripts/jquery-ui.min.js +6711 -0
  103. package/scripts/jquery.are-you-sure.js +197 -0
  104. package/scripts/jquery.autotabs.js +42 -0
  105. package/scripts/jquery.backstretch.min.js +543 -0
  106. package/scripts/jquery.blockUI.js +442 -0
  107. package/scripts/jquery.datePicker.js +1151 -0
  108. package/scripts/jquery.dialogextend.2_0_4.pack.js +300 -0
  109. package/scripts/jquery.fileupload-audio.js +103 -0
  110. package/scripts/jquery.fileupload-image.js +313 -0
  111. package/scripts/jquery.fileupload-process.js +172 -0
  112. package/scripts/jquery.fileupload-ui.js +700 -0
  113. package/scripts/jquery.fileupload-validate.js +117 -0
  114. package/scripts/jquery.fileupload-video.js +103 -0
  115. package/scripts/jquery.fileupload.js +1451 -0
  116. package/scripts/jquery.form.js +892 -0
  117. package/scripts/jquery.number.min.js +150 -0
  118. package/scripts/jquery.ui.datepicker-en.js +26 -0
  119. package/scripts/jquery.ui.timepicker-en.js +6 -0
  120. package/scripts/jquery.validate.min.js +844 -0
  121. package/scripts/jsbn-ver-1634886518000.js +2 -0
  122. package/scripts/layout.bundle.js +673 -0
  123. package/scripts/load-image.all.min.js +770 -0
  124. package/scripts/local.bundle.js +310 -0
  125. package/scripts/login-app.js +0 -0
  126. package/scripts/login-en.js +0 -0
  127. package/scripts/login-pl.js +0 -0
  128. package/scripts/login-states.js +0 -0
  129. package/scripts/main.js +23 -0
  130. package/scripts/mobileAuthCtrl.js +0 -0
  131. package/scripts/moment.min.js +1562 -0
  132. package/scripts/mon_ing_init.js +22 -0
  133. package/scripts/nl.js +88 -0
  134. package/scripts/paginator.js +267 -0
  135. package/scripts/pinLoginDefault-ver-1634885786000.js +2 -0
  136. package/scripts/popper.min.js +844 -0
  137. package/scripts/prng4-ver-1634886518000.js +2 -0
  138. package/scripts/psd2-states.js +0 -0
  139. package/scripts/rng-ver-1634886518000.js +2 -0
  140. package/scripts/rsa_jsbn-ver-1634886518000.js +2 -0
  141. package/scripts/selectAssetBrowser.bundle.js +47577 -0
  142. package/scripts/selectables.custom.js +174 -0
  143. package/scripts/sgemius.js +0 -0
  144. package/scripts/sha1.js +0 -0
  145. package/scripts/slick.min.js +687 -0
  146. package/scripts/superfish.js +279 -0
  147. package/scripts/upload-main.js +90 -0
  148. package/scripts/video.min.js +12517 -0
  149. package/scripts/videojs.wavesurfer.min.js +495 -0
  150. package/scripts/wavesurfer.min.js +2775 -0
  151. package/scripts/webtrekk_v4-ver-1634885786000.js +2 -0
  152. package/setup-feature.js +47 -0
  153. package/start.ingbusiness.pl/dump-scripts.py +83 -0
  154. package/start.ingbusiness.pl/form.html_v=202110040949 +52 -0
  155. package/start.ingbusiness.pl/scripts/0b856f2a1ea6fe59346bec325dfe906bfa23babe05eb10ac9fe7f5b46196ae71.js +0 -0
  156. package/start.ingbusiness.pl/scripts/AliasCtrl.js +136 -0
  157. package/start.ingbusiness.pl/scripts/ChangePasswordCtrl.js +162 -0
  158. package/start.ingbusiness.pl/scripts/CustomErrorCtrl.js +9 -0
  159. package/start.ingbusiness.pl/scripts/ErrorCtrl.js +30 -0
  160. package/start.ingbusiness.pl/scripts/HeaderCtrl.js +84 -0
  161. package/start.ingbusiness.pl/scripts/LoginService.js +86 -0
  162. package/start.ingbusiness.pl/scripts/LoginValidationService.js +52 -0
  163. package/start.ingbusiness.pl/scripts/NipValidator.js +30 -0
  164. package/start.ingbusiness.pl/scripts/PasswordCtrl.js +179 -0
  165. package/start.ingbusiness.pl/scripts/Psd2AliasCtrl.js +12 -0
  166. package/start.ingbusiness.pl/scripts/RegonValidator.js +73 -0
  167. package/start.ingbusiness.pl/scripts/RequestService.js +26 -0
  168. package/start.ingbusiness.pl/scripts/SmsCtrl.js +91 -0
  169. package/start.ingbusiness.pl/scripts/UnlockUserCtrl.js +79 -0
  170. package/start.ingbusiness.pl/scripts/angular-animate.min.js +1535 -0
  171. package/start.ingbusiness.pl/scripts/angular-cookies.min.js +62 -0
  172. package/start.ingbusiness.pl/scripts/angular-translate.min.js +871 -0
  173. package/start.ingbusiness.pl/scripts/angular-ui-router.js +1561 -0
  174. package/start.ingbusiness.pl/scripts/angular.min.js +9845 -0
  175. package/start.ingbusiness.pl/scripts/criticalMessageService.js +24 -0
  176. package/start.ingbusiness.pl/scripts/data-dir-button-loader.js +30 -0
  177. package/start.ingbusiness.pl/scripts/data-dir-compile-template.js +17 -0
  178. package/start.ingbusiness.pl/scripts/data-dir-cookies-bar.js +37 -0
  179. package/start.ingbusiness.pl/scripts/data-dir-progress-pie.js +102 -0
  180. package/start.ingbusiness.pl/scripts/data-dir-svg-icon.js +633 -0
  181. package/start.ingbusiness.pl/scripts/data-gemius-event.js +119 -0
  182. package/start.ingbusiness.pl/scripts/dir-critical-message.js +9 -0
  183. package/start.ingbusiness.pl/scripts/dir-help-panel-content.js +29 -0
  184. package/start.ingbusiness.pl/scripts/dir-login-keyboard.js +346 -0
  185. package/start.ingbusiness.pl/scripts/dir-login-validation.js +20 -0
  186. package/start.ingbusiness.pl/scripts/dir-nav-links.js +26 -0
  187. package/start.ingbusiness.pl/scripts/dir-title.js +21 -0
  188. package/start.ingbusiness.pl/scripts/gemius-init.js +12 -0
  189. package/start.ingbusiness.pl/scripts/gemiusID.js +32 -0
  190. package/start.ingbusiness.pl/scripts/hashService.js +91 -0
  191. package/start.ingbusiness.pl/scripts/helpPanelPasswordService.js +26 -0
  192. package/start.ingbusiness.pl/scripts/helpPanelService.js +92 -0
  193. package/start.ingbusiness.pl/scripts/jquery-3.5.1.min.js +3242 -0
  194. package/start.ingbusiness.pl/scripts/login-app.js +107 -0
  195. package/start.ingbusiness.pl/scripts/login-en.js +73 -0
  196. package/start.ingbusiness.pl/scripts/login-pl.js +74 -0
  197. package/start.ingbusiness.pl/scripts/login-states.js +156 -0
  198. package/start.ingbusiness.pl/scripts/maskService.js +194 -0
  199. package/start.ingbusiness.pl/scripts/maskUtilService.js +302 -0
  200. package/start.ingbusiness.pl/scripts/mobileAuthCtrl.js +189 -0
  201. package/start.ingbusiness.pl/scripts/psd2-states.js +67 -0
  202. package/start.ingbusiness.pl/scripts/securityPolicyService.js +119 -0
  203. package/start.ingbusiness.pl/scripts/sgemius.js +257 -0
  204. package/start.ingbusiness.pl/scripts/sha1.js +210 -0
  205. package/start.ingbusiness.pl/scripts/sprintf.js +115 -0
  206. package/start.ingbusiness.pl/scripts/tabletScalingService.js +59 -0
  207. package/start.ingbusiness.pl/scripts/userAgentResolverService.js +12 -0
@@ -0,0 +1,313 @@
1
+ /*
2
+ * jQuery File Upload Image Preview & Resize Plugin 1.7.2
3
+ * https://github.com/blueimp/jQuery-File-Upload
4
+ *
5
+ * Copyright 2013, Sebastian Tschan
6
+ * https://blueimp.net
7
+ *
8
+ * Licensed under the MIT license:
9
+ * http://www.opensource.org/licenses/MIT
10
+ */
11
+
12
+ /* jshint nomen:false */
13
+ /* global define, window, Blob */
14
+
15
+ (function(factory) {
16
+ 'use strict';
17
+ if (typeof define === 'function' && define.amd) {
18
+ // Register as an anonymous AMD module:
19
+ define([
20
+ 'jquery',
21
+ 'load-image',
22
+ 'load-image-meta',
23
+ 'load-image-exif',
24
+ 'load-image-ios',
25
+ 'canvas-to-blob',
26
+ './jquery.fileupload-process'
27
+ ], factory);
28
+ } else {
29
+ // Browser globals:
30
+ factory(
31
+ window.jQuery,
32
+ window.loadImage
33
+ );
34
+ }
35
+ }(function($, loadImage) {
36
+ 'use strict';
37
+
38
+ // Prepend to the default processQueue:
39
+ $.blueimp.fileupload.prototype.options.processQueue.unshift({
40
+ action: 'loadImageMetaData',
41
+ disableImageHead: '@',
42
+ disableExif: '@',
43
+ disableExifThumbnail: '@',
44
+ disableExifSub: '@',
45
+ disableExifGps: '@',
46
+ disabled: '@disableImageMetaDataLoad'
47
+ }, {
48
+ action: 'loadImage',
49
+ // Use the action as prefix for the "@" options:
50
+ prefix: true,
51
+ fileTypes: '@',
52
+ maxFileSize: '@',
53
+ noRevoke: '@',
54
+ disabled: '@disableImageLoad'
55
+ },
56
+ // {
57
+ // action: 'resizeImage',
58
+ // // Use "image" as prefix for the "@" options:
59
+ // prefix: 'image',
60
+ // maxWidth: '@',
61
+ // maxHeight: '@',
62
+ // minWidth: '@',
63
+ // minHeight: '@',
64
+ // crop: '@',
65
+ // orientation: '@',
66
+ // forceResize: '@',
67
+ // disabled: '@disableImageResize'
68
+ // },
69
+ {
70
+ action: 'saveImage',
71
+ quality: '@imageQuality',
72
+ type: '@imageType',
73
+ disabled: '@disableImageResize'
74
+ }, {
75
+ action: 'saveImageMetaData',
76
+ disabled: '@disableImageMetaDataSave'
77
+ }, {
78
+ action: 'resizeImage',
79
+ // Use "preview" as prefix for the "@" options:
80
+ prefix: 'preview',
81
+ maxWidth: '@',
82
+ maxHeight: '@',
83
+ minWidth: '@',
84
+ minHeight: '@',
85
+ crop: '@',
86
+ orientation: '@',
87
+ thumbnail: '@',
88
+ canvas: '@',
89
+ disabled: '@disableImagePreview'
90
+ }, {
91
+ action: 'setImage',
92
+ name: '@imagePreviewName',
93
+ disabled: '@disableImagePreview'
94
+ }, {
95
+ action: 'deleteImageReferences',
96
+ disabled: '@disableImageReferencesDeletion'
97
+ }
98
+ );
99
+
100
+ // The File Upload Resize plugin extends the fileupload widget
101
+ // with image resize functionality:
102
+ $.widget('blueimp.fileupload', $.blueimp.fileupload, {
103
+
104
+ options: {
105
+ // The regular expression for the types of images to load:
106
+ // matched against the file type:
107
+ loadImageFileTypes: /^image\/(gif|jpeg|png|svg\+xml)$/,
108
+ // The maximum file size of images to load:
109
+ loadImageMaxFileSize: 10000000, // 10MB
110
+ // The maximum width of resized images:
111
+ imageMaxWidth: 1920,
112
+ // The maximum height of resized images:
113
+ imageMaxHeight: 1080,
114
+ // Defines the image orientation (1-8) or takes the orientation
115
+ // value from Exif data if set to true:
116
+ imageOrientation: false,
117
+ // Define if resized images should be cropped or only scaled:
118
+ imageCrop: false,
119
+ // Disable the resize image functionality by default:
120
+ disableImageResize: true,
121
+ // The maximum width of the preview images:
122
+ previewMaxWidth: 80,
123
+ // The maximum height of the preview images:
124
+ previewMaxHeight: 80,
125
+ // Defines the preview orientation (1-8) or takes the orientation
126
+ // value from Exif data if set to true:
127
+ previewOrientation: true,
128
+ // Create the preview using the Exif data thumbnail:
129
+ previewThumbnail: true,
130
+ // Define if preview images should be cropped or only scaled:
131
+ previewCrop: false,
132
+ // Define if preview images should be resized as canvas elements:
133
+ previewCanvas: true
134
+ },
135
+
136
+ processActions: {
137
+
138
+ // Loads the image given via data.files and data.index
139
+ // as img element, if the browser supports the File API.
140
+ // Accepts the options fileTypes (regular expression)
141
+ // and maxFileSize (integer) to limit the files to load:
142
+ loadImage: function(data, options) {
143
+ if (options.disabled) {
144
+ return data;
145
+ }
146
+ var that = this,
147
+ file = data.files[data.index],
148
+ dfd = $.Deferred();
149
+ if (($.type(options.maxFileSize) === 'number' &&
150
+ file.size > options.maxFileSize) ||
151
+ (options.fileTypes &&
152
+ !options.fileTypes.test(file.type)) ||
153
+ !loadImage(
154
+ file,
155
+ function(img) {
156
+ if (img.src) {
157
+ data.img = img;
158
+ }
159
+ dfd.resolveWith(that, [data]);
160
+ },
161
+ options
162
+ )) {
163
+ return data;
164
+ }
165
+ return dfd.promise();
166
+ },
167
+
168
+ // Resizes the image given as data.canvas or data.img
169
+ // and updates data.canvas or data.img with the resized image.
170
+ // Also stores the resized image as preview property.
171
+ // Accepts the options maxWidth, maxHeight, minWidth,
172
+ // minHeight, canvas and crop:
173
+ resizeImage: function(data, options) {
174
+ if (options.disabled || !(data.canvas || data.img)) {
175
+ return data;
176
+ }
177
+ options = $.extend({
178
+ canvas: true
179
+ }, options);
180
+ var that = this,
181
+ dfd = $.Deferred(),
182
+ img = (options.canvas && data.canvas) || data.img,
183
+ resolve = function(newImg) {
184
+ if (newImg && (newImg.width !== img.width ||
185
+ newImg.height !== img.height ||
186
+ options.forceResize)) {
187
+ data[newImg.getContext ? 'canvas' : 'img'] = newImg;
188
+ }
189
+ data.preview = newImg;
190
+ dfd.resolveWith(that, [data]);
191
+ },
192
+ thumbnail;
193
+ if (data.exif) {
194
+ if (options.orientation === true) {
195
+ options.orientation = data.exif.get('Orientation');
196
+ }
197
+ if (options.thumbnail) {
198
+ thumbnail = data.exif.get('Thumbnail');
199
+ if (thumbnail) {
200
+ loadImage(thumbnail, resolve, options);
201
+ return dfd.promise();
202
+ }
203
+ }
204
+ // Prevent orienting the same image twice:
205
+ if (data.orientation) {
206
+ delete options.orientation;
207
+ } else {
208
+ data.orientation = options.orientation;
209
+ }
210
+ }
211
+ if (img) {
212
+ resolve(loadImage.scale(img, options));
213
+ return dfd.promise();
214
+ }
215
+ return data;
216
+ },
217
+
218
+ // Saves the processed image given as data.canvas
219
+ // inplace at data.index of data.files:
220
+ saveImage: function(data, options) {
221
+ if (!data.canvas || options.disabled) {
222
+ return data;
223
+ }
224
+ var that = this,
225
+ file = data.files[data.index],
226
+ dfd = $.Deferred();
227
+ if (data.canvas.toBlob) {
228
+ data.canvas.toBlob(
229
+ function(blob) {
230
+ if (!blob.name) {
231
+ if (file.type === blob.type) {
232
+ blob.name = file.name;
233
+ } else if (file.name) {
234
+ blob.name = file.name.replace(
235
+ /\..+$/,
236
+ '.' + blob.type.substr(6)
237
+ );
238
+ }
239
+ }
240
+ // Don't restore invalid meta data:
241
+ if (file.type !== blob.type) {
242
+ delete data.imageHead;
243
+ }
244
+ // Store the created blob at the position
245
+ // of the original file in the files list:
246
+ data.files[data.index] = blob;
247
+ dfd.resolveWith(that, [data]);
248
+ },
249
+ options.type || file.type,
250
+ options.quality
251
+ );
252
+ } else {
253
+ return data;
254
+ }
255
+ return dfd.promise();
256
+ },
257
+
258
+ loadImageMetaData: function(data, options) {
259
+ if (options.disabled) {
260
+ return data;
261
+ }
262
+ var that = this,
263
+ dfd = $.Deferred();
264
+ loadImage.parseMetaData(data.files[data.index], function(result) {
265
+ $.extend(data, result);
266
+ dfd.resolveWith(that, [data]);
267
+ }, options);
268
+ return dfd.promise();
269
+ },
270
+
271
+ saveImageMetaData: function(data, options) {
272
+ if (!(data.imageHead && data.canvas &&
273
+ data.canvas.toBlob && !options.disabled)) {
274
+ return data;
275
+ }
276
+ var file = data.files[data.index],
277
+ blob = new Blob([
278
+ data.imageHead,
279
+ // Resized images always have a head size of 20 bytes,
280
+ // including the JPEG marker and a minimal JFIF header:
281
+ this._blobSlice.call(file, 20)
282
+ ], {
283
+ type: file.type
284
+ });
285
+ blob.name = file.name;
286
+ data.files[data.index] = blob;
287
+ return data;
288
+ },
289
+
290
+ // Sets the resized version of the image as a property of the
291
+ // file object, must be called after "saveImage":
292
+ setImage: function(data, options) {
293
+ if (data.preview && !options.disabled) {
294
+ data.files[data.index][options.name || 'preview'] = data.preview;
295
+ }
296
+ return data;
297
+ },
298
+
299
+ deleteImageReferences: function(data, options) {
300
+ if (!options.disabled) {
301
+ delete data.img;
302
+ delete data.canvas;
303
+ delete data.preview;
304
+ delete data.imageHead;
305
+ }
306
+ return data;
307
+ }
308
+
309
+ }
310
+
311
+ });
312
+
313
+ }));
@@ -0,0 +1,172 @@
1
+ /*
2
+ * jQuery File Upload Processing Plugin 1.3.0
3
+ * https://github.com/blueimp/jQuery-File-Upload
4
+ *
5
+ * Copyright 2012, Sebastian Tschan
6
+ * https://blueimp.net
7
+ *
8
+ * Licensed under the MIT license:
9
+ * http://www.opensource.org/licenses/MIT
10
+ */
11
+
12
+ /* jshint nomen:false */
13
+ /* global define, window */
14
+
15
+ (function(factory) {
16
+ 'use strict';
17
+ if (typeof define === 'function' && define.amd) {
18
+ // Register as an anonymous AMD module:
19
+ define([
20
+ 'jquery',
21
+ './jquery.fileupload'
22
+ ], factory);
23
+ } else {
24
+ // Browser globals:
25
+ factory(
26
+ window.jQuery
27
+ );
28
+ }
29
+ }(function($) {
30
+ 'use strict';
31
+
32
+ var originalAdd = $.blueimp.fileupload.prototype.options.add;
33
+
34
+ // The File Upload Processing plugin extends the fileupload widget
35
+ // with file processing functionality:
36
+ $.widget('blueimp.fileupload', $.blueimp.fileupload, {
37
+
38
+ options: {
39
+ // The list of processing actions:
40
+ processQueue: [
41
+ /*
42
+ {
43
+ action: 'log',
44
+ type: 'debug'
45
+ }
46
+ */
47
+ ],
48
+ add: function(e, data) {
49
+ var $this = $(this);
50
+ data.process(function() {
51
+ return $this.fileupload('process', data);
52
+ });
53
+ originalAdd.call(this, e, data);
54
+ }
55
+ },
56
+
57
+ processActions: {
58
+ /*
59
+ log: function (data, options) {
60
+ console[options.type](
61
+ 'Processing "' + data.files[data.index].name + '"'
62
+ );
63
+ }
64
+ */
65
+ },
66
+
67
+ _processFile: function(data, originalData) {
68
+ var that = this,
69
+ dfd = $.Deferred().resolveWith(that, [data]),
70
+ chain = dfd.promise();
71
+ this._trigger('process', null, data);
72
+ $.each(data.processQueue, function(i, settings) {
73
+ var func = function(data) {
74
+ if (originalData.errorThrown) {
75
+ return $.Deferred()
76
+ .rejectWith(that, [originalData]).promise();
77
+ }
78
+ return that.processActions[settings.action].call(
79
+ that,
80
+ data,
81
+ settings
82
+ );
83
+ };
84
+ chain = chain.pipe(func, settings.always && func);
85
+ });
86
+ chain
87
+ .done(function() {
88
+ that._trigger('processdone', null, data);
89
+ that._trigger('processalways', null, data);
90
+ })
91
+ .fail(function() {
92
+ that._trigger('processfail', null, data);
93
+ that._trigger('processalways', null, data);
94
+ });
95
+ return chain;
96
+ },
97
+
98
+ // Replaces the settings of each processQueue item that
99
+ // are strings starting with an "@", using the remaining
100
+ // substring as key for the option map,
101
+ // e.g. "@autoUpload" is replaced with options.autoUpload:
102
+ _transformProcessQueue: function(options) {
103
+ var processQueue = [];
104
+ $.each(options.processQueue, function() {
105
+ var settings = {},
106
+ action = this.action,
107
+ prefix = this.prefix === true ? action : this.prefix;
108
+ $.each(this, function(key, value) {
109
+ if ($.type(value) === 'string' &&
110
+ value.charAt(0) === '@') {
111
+ settings[key] = options[
112
+ value.slice(1) || (prefix ? prefix +
113
+ key.charAt(0).toUpperCase() + key.slice(1) : key)
114
+ ];
115
+ } else {
116
+ settings[key] = value;
117
+ }
118
+
119
+ });
120
+ processQueue.push(settings);
121
+ });
122
+ options.processQueue = processQueue;
123
+ },
124
+
125
+ // Returns the number of files currently in the processsing queue:
126
+ processing: function() {
127
+ return this._processing;
128
+ },
129
+
130
+ // Processes the files given as files property of the data parameter,
131
+ // returns a Promise object that allows to bind callbacks:
132
+ process: function(data) {
133
+ var that = this,
134
+ options = $.extend({}, this.options, data);
135
+ if (options.processQueue && options.processQueue.length) {
136
+ this._transformProcessQueue(options);
137
+ if (this._processing === 0) {
138
+ this._trigger('processstart');
139
+ }
140
+ $.each(data.files, function(index) {
141
+ var opts = index ? $.extend({}, options) : options,
142
+ func = function() {
143
+ if (data.errorThrown) {
144
+ return $.Deferred()
145
+ .rejectWith(that, [data]).promise();
146
+ }
147
+ return that._processFile(opts, data);
148
+ };
149
+ opts.index = index;
150
+ that._processing += 1;
151
+ that._processingQueue = that._processingQueue.pipe(func, func)
152
+ .always(function() {
153
+ that._processing -= 1;
154
+ if (that._processing === 0) {
155
+ that._trigger('processstop');
156
+ }
157
+ });
158
+ });
159
+ }
160
+ return this._processingQueue;
161
+ },
162
+
163
+ _create: function() {
164
+ this._super();
165
+ this._processing = 0;
166
+ this._processingQueue = $.Deferred().resolveWith(this)
167
+ .promise();
168
+ }
169
+
170
+ });
171
+
172
+ }));