card-mod-script 0.14.2 → 0.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/config/late/extend_ansi.rb +1 -0
- data/data/real.yml +50 -0
- data/lib/card/mod/script.rb +1 -0
- data/lib/cardio/utils/ansi2_html.rb +72 -0
- data/set/abstract/00_script.rb +4 -4
- data/set/abstract/02_coffee_script.rb +9 -1
- data/set/all/head_javascript.rb +13 -22
- data/set/right/script.rb +1 -1
- data/set/type/coffee_script.rb +6 -0
- data/set/type/java_script.rb +6 -0
- data/set/type/local_script_folder_group.rb +2 -0
- data/set/type/local_script_manifest_group.rb +2 -0
- data/set/type_plus_right/mod/script.rb +1 -5
- data/set/type_plus_right/set/script.rb +3 -1
- metadata +15 -120
- data/assets/script/decko/autosave.js.coffee +0 -30
- data/assets/script/decko/bridge.js.coffee +0 -31
- data/assets/script/decko/card_menu.js.coffee +0 -26
- data/assets/script/decko/components.js.coffee +0 -49
- data/assets/script/decko/decko.js.coffee +0 -82
- data/assets/script/decko/doubleclick.js.coffee +0 -30
- data/assets/script/decko/editor.js.coffee +0 -57
- data/assets/script/decko/filter.js.coffee +0 -183
- data/assets/script/decko/filter_items.js.coffee +0 -128
- data/assets/script/decko/filter_links.js.coffee +0 -81
- data/assets/script/decko/follow.js.coffee +0 -22
- data/assets/script/decko/layout.js.coffee +0 -76
- data/assets/script/decko/link_editor.js.coffee +0 -61
- data/assets/script/decko/mod.js.coffee +0 -79
- data/assets/script/decko/modal.js.coffee +0 -113
- data/assets/script/decko/name_editor.js.coffee +0 -40
- data/assets/script/decko/navbox.js.coffee +0 -74
- data/assets/script/decko/nest_editor.js.coffee +0 -166
- data/assets/script/decko/nest_editor_name.js.coffee +0 -102
- data/assets/script/decko/nest_editor_options.js.coffee +0 -93
- data/assets/script/decko/nest_editor_rules.js.coffee +0 -3
- data/assets/script/decko/overlay.js.coffee +0 -54
- data/assets/script/decko/pointer_config.js.coffee +0 -79
- data/assets/script/decko/pointer_list_editor.js.coffee +0 -67
- data/assets/script/decko/recaptcha.js.coffee +0 -19
- data/assets/script/decko/selectable_filtered_content.js.coffee +0 -12
- data/assets/script/decko/slot.js.coffee +0 -182
- data/assets/script/decko/slot_ready.js.coffee +0 -12
- data/assets/script/decko/slotter.js.coffee +0 -268
- data/assets/script/decko/type_editor.js.coffee +0 -21
- data/assets/script/decko/upload.js.coffee +0 -64
- data/assets/script/jquery-ui.min.js +0 -13
- data/assets/script/jquery.autosize.js +0 -274
- data/assets/script/manifest.yml +0 -57
- data/db/migrate_core_cards/20200804112348_add_mod_script_assets_type.rb +0 -30
- data/vendor/jquery_file_upload/LICENSE.txt +0 -20
- data/vendor/jquery_file_upload/README.md +0 -224
- data/vendor/jquery_file_upload/SECURITY.md +0 -227
- data/vendor/jquery_file_upload/VULNERABILITIES.md +0 -118
- data/vendor/jquery_file_upload/cors/postmessage.html +0 -85
- data/vendor/jquery_file_upload/cors/result.html +0 -26
- data/vendor/jquery_file_upload/css/jquery.fileupload-noscript.css +0 -22
- data/vendor/jquery_file_upload/css/jquery.fileupload-ui-noscript.css +0 -17
- data/vendor/jquery_file_upload/css/jquery.fileupload-ui.css +0 -68
- data/vendor/jquery_file_upload/css/jquery.fileupload.css +0 -36
- data/vendor/jquery_file_upload/docker-compose.yml +0 -55
- data/vendor/jquery_file_upload/img/loading.gif +0 -0
- data/vendor/jquery_file_upload/img/progressbar.gif +0 -0
- data/vendor/jquery_file_upload/index.html +0 -357
- data/vendor/jquery_file_upload/js/cors/jquery.postmessage-transport.js +0 -126
- data/vendor/jquery_file_upload/js/cors/jquery.xdr-transport.js +0 -97
- data/vendor/jquery_file_upload/js/demo.js +0 -75
- data/vendor/jquery_file_upload/js/jquery.fileupload-audio.js +0 -101
- data/vendor/jquery_file_upload/js/jquery.fileupload-image.js +0 -347
- data/vendor/jquery_file_upload/js/jquery.fileupload-process.js +0 -170
- data/vendor/jquery_file_upload/js/jquery.fileupload-ui.js +0 -759
- data/vendor/jquery_file_upload/js/jquery.fileupload-validate.js +0 -119
- data/vendor/jquery_file_upload/js/jquery.fileupload-video.js +0 -101
- data/vendor/jquery_file_upload/js/jquery.fileupload.js +0 -1604
- data/vendor/jquery_file_upload/js/jquery.iframe-transport.js +0 -227
- data/vendor/jquery_file_upload/js/vendor/jquery.ui.widget.js +0 -805
- data/vendor/jquery_file_upload/package-lock.json +0 -6853
- data/vendor/jquery_file_upload/package.json +0 -116
- data/vendor/jquery_file_upload/server/gae-python/app.yaml +0 -18
- data/vendor/jquery_file_upload/server/gae-python/main.py +0 -204
- data/vendor/jquery_file_upload/server/gae-python/static/favicon.ico +0 -0
- data/vendor/jquery_file_upload/server/gae-python/static/robots.txt +0 -2
- data/vendor/jquery_file_upload/server/php/Dockerfile +0 -44
- data/vendor/jquery_file_upload/server/php/UploadHandler.php +0 -1480
- data/vendor/jquery_file_upload/server/php/index.php +0 -15
- data/vendor/jquery_file_upload/server/php/php.ini +0 -5
- data/vendor/jquery_file_upload/test/index.html +0 -49
- data/vendor/jquery_file_upload/test/unit.js +0 -989
- data/vendor/jquery_file_upload/test/vendor/chai.js +0 -10854
- data/vendor/jquery_file_upload/test/vendor/mocha.css +0 -325
- data/vendor/jquery_file_upload/test/vendor/mocha.js +0 -18178
- data/vendor/jquery_file_upload/wdio/LICENSE.txt +0 -20
- data/vendor/jquery_file_upload/wdio/assets/black+white-3x2.jpg +0 -0
- data/vendor/jquery_file_upload/wdio/assets/black+white-60x40.gif +0 -0
- data/vendor/jquery_file_upload/wdio/conf/chrome.js +0 -40
- data/vendor/jquery_file_upload/wdio/conf/firefox.js +0 -25
- data/vendor/jquery_file_upload/wdio/hooks/index.js +0 -36
- data/vendor/jquery_file_upload/wdio/test/pages/file-upload.js +0 -79
- data/vendor/jquery_file_upload/wdio/test/specs/01-file-upload.js +0 -25
- data/vendor/jquery_file_upload/wdio/wdio.conf.js +0 -4
- data/vendor/jquery_rails/CHANGELOG.md +0 -359
- data/vendor/jquery_rails/CONTRIBUTING.md +0 -132
- data/vendor/jquery_rails/Gemfile +0 -22
- data/vendor/jquery_rails/MIT-LICENSE +0 -21
- data/vendor/jquery_rails/README.md +0 -75
- data/vendor/jquery_rails/Rakefile +0 -59
- data/vendor/jquery_rails/VERSIONS.md +0 -62
- data/vendor/jquery_rails/jquery-rails.gemspec +0 -26
- data/vendor/jquery_rails/lib/jquery/assert_select.rb +0 -149
- data/vendor/jquery_rails/lib/jquery/rails/engine.rb +0 -6
- data/vendor/jquery_rails/lib/jquery/rails/version.rb +0 -9
- data/vendor/jquery_rails/lib/jquery/rails.rb +0 -8
- data/vendor/jquery_rails/lib/jquery-rails.rb +0 -1
- data/vendor/jquery_rails/test/assert_select_jquery_test.rb +0 -85
- data/vendor/jquery_rails/test/test_helper.rb +0 -6
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery.js +0 -11008
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery.min.js +0 -5
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery.min.map +0 -1
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery2.js +0 -9814
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery2.min.js +0 -4
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery2.min.map +0 -1
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery3.js +0 -10364
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery3.min.js +0 -2
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery3.min.map +0 -1
- data/vendor/jquery_rails/vendor/assets/javascripts/jquery_ujs.js +0 -555
- /data/{init → config}/early/init_execjs.rb +0 -0
|
@@ -1,274 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
Autosize 1.18.13
|
|
3
|
-
license: MIT
|
|
4
|
-
http://www.jacklmoore.com/autosize
|
|
5
|
-
*/
|
|
6
|
-
(function ($) {
|
|
7
|
-
var
|
|
8
|
-
defaults = {
|
|
9
|
-
className: 'autosizejs',
|
|
10
|
-
id: 'autosizejs',
|
|
11
|
-
append: '\n',
|
|
12
|
-
callback: false,
|
|
13
|
-
resizeDelay: 10,
|
|
14
|
-
placeholder: true
|
|
15
|
-
},
|
|
16
|
-
|
|
17
|
-
// border:0 is unnecessary, but avoids a bug in Firefox on OSX
|
|
18
|
-
copy = '<textarea tabindex="-1" style="position:absolute; top:-999px; left:0; right:auto; bottom:auto; border:0; padding: 0; -moz-box-sizing:content-box; -webkit-box-sizing:content-box; box-sizing:content-box; word-wrap:break-word; height:0 !important; min-height:0 !important; overflow:hidden; transition:none; -webkit-transition:none; -moz-transition:none;"/>',
|
|
19
|
-
|
|
20
|
-
// line-height is conditionally included because IE7/IE8/old Opera do not return the correct value.
|
|
21
|
-
typographyStyles = [
|
|
22
|
-
'fontFamily',
|
|
23
|
-
'fontSize',
|
|
24
|
-
'fontWeight',
|
|
25
|
-
'fontStyle',
|
|
26
|
-
'letterSpacing',
|
|
27
|
-
'textTransform',
|
|
28
|
-
'wordSpacing',
|
|
29
|
-
'textIndent',
|
|
30
|
-
'whiteSpace'
|
|
31
|
-
],
|
|
32
|
-
|
|
33
|
-
// to keep track which textarea is being mirrored when adjust() is called.
|
|
34
|
-
mirrored,
|
|
35
|
-
|
|
36
|
-
// the mirror element, which is used to calculate what size the mirrored element should be.
|
|
37
|
-
mirror = $(copy).data('autosize', true)[0];
|
|
38
|
-
|
|
39
|
-
// test that line-height can be accurately copied.
|
|
40
|
-
mirror.style.lineHeight = '99px';
|
|
41
|
-
if ($(mirror).css('lineHeight') === '99px') {
|
|
42
|
-
typographyStyles.push('lineHeight');
|
|
43
|
-
}
|
|
44
|
-
mirror.style.lineHeight = '';
|
|
45
|
-
|
|
46
|
-
$.fn.autosize = function (options) {
|
|
47
|
-
if (!this.length) {
|
|
48
|
-
return this;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
options = $.extend({}, defaults, options || {});
|
|
52
|
-
|
|
53
|
-
if (mirror.parentNode !== document.body) {
|
|
54
|
-
$(document.body).append(mirror);
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
return this.each(function () {
|
|
58
|
-
var
|
|
59
|
-
ta = this,
|
|
60
|
-
$ta = $(ta),
|
|
61
|
-
maxHeight,
|
|
62
|
-
minHeight,
|
|
63
|
-
boxOffset = 0,
|
|
64
|
-
callback = $.isFunction(options.callback),
|
|
65
|
-
originalStyles = {
|
|
66
|
-
height: ta.style.height,
|
|
67
|
-
overflow: ta.style.overflow,
|
|
68
|
-
overflowY: ta.style.overflowY,
|
|
69
|
-
wordWrap: ta.style.wordWrap,
|
|
70
|
-
resize: ta.style.resize
|
|
71
|
-
},
|
|
72
|
-
timeout,
|
|
73
|
-
width = $ta.width(),
|
|
74
|
-
taResize = $ta.css('resize');
|
|
75
|
-
|
|
76
|
-
if ($ta.data('autosize')) {
|
|
77
|
-
// exit if autosize has already been applied, or if the textarea is the mirror element.
|
|
78
|
-
return;
|
|
79
|
-
}
|
|
80
|
-
$ta.data('autosize', true);
|
|
81
|
-
|
|
82
|
-
if ($ta.css('box-sizing') === 'border-box' || $ta.css('-moz-box-sizing') === 'border-box' || $ta.css('-webkit-box-sizing') === 'border-box'){
|
|
83
|
-
boxOffset = $ta.outerHeight() - $ta.height();
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
// IE8 and lower return 'auto', which parses to NaN, if no min-height is set.
|
|
87
|
-
minHeight = Math.max(parseInt($ta.css('minHeight'), 10) - boxOffset || 0, $ta.height());
|
|
88
|
-
|
|
89
|
-
$ta.css({
|
|
90
|
-
overflow: 'hidden',
|
|
91
|
-
overflowY: 'hidden',
|
|
92
|
-
wordWrap: 'break-word' // horizontal overflow is hidden, so break-word is necessary for handling words longer than the textarea width
|
|
93
|
-
});
|
|
94
|
-
|
|
95
|
-
if (taResize === 'vertical') {
|
|
96
|
-
$ta.css('resize','none');
|
|
97
|
-
} else if (taResize === 'both') {
|
|
98
|
-
$ta.css('resize', 'horizontal');
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
// The mirror width must exactly match the textarea width, so using getBoundingClientRect because it doesn't round the sub-pixel value.
|
|
102
|
-
// window.getComputedStyle, getBoundingClientRect returning a width are unsupported, but also unneeded in IE8 and lower.
|
|
103
|
-
function setWidth() {
|
|
104
|
-
var width;
|
|
105
|
-
var style = window.getComputedStyle ? window.getComputedStyle(ta, null) : false;
|
|
106
|
-
|
|
107
|
-
if (style) {
|
|
108
|
-
|
|
109
|
-
width = ta.getBoundingClientRect().width;
|
|
110
|
-
|
|
111
|
-
if (width === 0 || typeof width !== 'number') {
|
|
112
|
-
width = parseInt(style.width,10);
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
$.each(['paddingLeft', 'paddingRight', 'borderLeftWidth', 'borderRightWidth'], function(i,val){
|
|
116
|
-
width -= parseInt(style[val],10);
|
|
117
|
-
});
|
|
118
|
-
} else {
|
|
119
|
-
width = $ta.width();
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
mirror.style.width = Math.max(width,0) + 'px';
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
function initMirror() {
|
|
126
|
-
var styles = {};
|
|
127
|
-
|
|
128
|
-
mirrored = ta;
|
|
129
|
-
mirror.className = options.className;
|
|
130
|
-
mirror.id = options.id;
|
|
131
|
-
maxHeight = parseInt($ta.css('maxHeight'), 10);
|
|
132
|
-
|
|
133
|
-
// mirror is a duplicate textarea located off-screen that
|
|
134
|
-
// is automatically updated to contain the same text as the
|
|
135
|
-
// original textarea. mirror always has a height of 0.
|
|
136
|
-
// This gives a cross-browser supported way getting the actual
|
|
137
|
-
// height of the text, through the scrollTop property.
|
|
138
|
-
$.each(typographyStyles, function(i,val){
|
|
139
|
-
styles[val] = $ta.css(val);
|
|
140
|
-
});
|
|
141
|
-
|
|
142
|
-
$(mirror).css(styles).attr('wrap', $ta.attr('wrap'));
|
|
143
|
-
|
|
144
|
-
setWidth();
|
|
145
|
-
|
|
146
|
-
// Chrome-specific fix:
|
|
147
|
-
// When the textarea y-overflow is hidden, Chrome doesn't reflow the text to account for the space
|
|
148
|
-
// made available by removing the scrollbar. This workaround triggers the reflow for Chrome.
|
|
149
|
-
if (window.chrome) {
|
|
150
|
-
var width = ta.style.width;
|
|
151
|
-
ta.style.width = '0px';
|
|
152
|
-
var ignore = ta.offsetWidth;
|
|
153
|
-
ta.style.width = width;
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
// Using mainly bare JS in this function because it is going
|
|
158
|
-
// to fire very often while typing, and needs to very efficient.
|
|
159
|
-
function adjust() {
|
|
160
|
-
var height, original;
|
|
161
|
-
|
|
162
|
-
if (mirrored !== ta) {
|
|
163
|
-
initMirror();
|
|
164
|
-
} else {
|
|
165
|
-
setWidth();
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
if (!ta.value && options.placeholder) {
|
|
169
|
-
// If the textarea is empty, copy the placeholder text into
|
|
170
|
-
// the mirror control and use that for sizing so that we
|
|
171
|
-
// don't end up with placeholder getting trimmed.
|
|
172
|
-
mirror.value = ($ta.attr("placeholder") || '');
|
|
173
|
-
} else {
|
|
174
|
-
mirror.value = ta.value;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
mirror.value += options.append || '';
|
|
178
|
-
mirror.style.overflowY = ta.style.overflowY;
|
|
179
|
-
original = parseInt(ta.style.height,10);
|
|
180
|
-
|
|
181
|
-
// Setting scrollTop to zero is needed in IE8 and lower for the next step to be accurately applied
|
|
182
|
-
mirror.scrollTop = 0;
|
|
183
|
-
|
|
184
|
-
mirror.scrollTop = 9e4;
|
|
185
|
-
|
|
186
|
-
// Using scrollTop rather than scrollHeight because scrollHeight is non-standard and includes padding.
|
|
187
|
-
height = mirror.scrollTop;
|
|
188
|
-
|
|
189
|
-
if (maxHeight && height > maxHeight) {
|
|
190
|
-
ta.style.overflowY = 'scroll';
|
|
191
|
-
height = maxHeight;
|
|
192
|
-
} else {
|
|
193
|
-
ta.style.overflowY = 'hidden';
|
|
194
|
-
if (height < minHeight) {
|
|
195
|
-
height = minHeight;
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
height += boxOffset;
|
|
200
|
-
|
|
201
|
-
if (original !== height) {
|
|
202
|
-
ta.style.height = height + 'px';
|
|
203
|
-
if (callback) {
|
|
204
|
-
options.callback.call(ta,ta);
|
|
205
|
-
}
|
|
206
|
-
$ta.trigger('autosize.resized');
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
function resize () {
|
|
211
|
-
clearTimeout(timeout);
|
|
212
|
-
timeout = setTimeout(function(){
|
|
213
|
-
var newWidth = $ta.width();
|
|
214
|
-
|
|
215
|
-
if (newWidth !== width) {
|
|
216
|
-
width = newWidth;
|
|
217
|
-
adjust();
|
|
218
|
-
}
|
|
219
|
-
}, parseInt(options.resizeDelay,10));
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
if ('onpropertychange' in ta) {
|
|
223
|
-
if ('oninput' in ta) {
|
|
224
|
-
// Detects IE9. IE9 does not fire onpropertychange or oninput for deletions,
|
|
225
|
-
// so binding to onkeyup to catch most of those occasions. There is no way that I
|
|
226
|
-
// know of to detect something like 'cut' in IE9.
|
|
227
|
-
$ta.on('input.autosize keyup.autosize', adjust);
|
|
228
|
-
} else {
|
|
229
|
-
// IE7 / IE8
|
|
230
|
-
$ta.on('propertychange.autosize', function(){
|
|
231
|
-
if(event.propertyName === 'value'){
|
|
232
|
-
adjust();
|
|
233
|
-
}
|
|
234
|
-
});
|
|
235
|
-
}
|
|
236
|
-
} else {
|
|
237
|
-
// Modern Browsers
|
|
238
|
-
$ta.on('input.autosize', adjust);
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
// Set options.resizeDelay to false if using fixed-width textarea elements.
|
|
242
|
-
// Uses a timeout and width check to reduce the amount of times adjust needs to be called after window resize.
|
|
243
|
-
|
|
244
|
-
if (options.resizeDelay !== false) {
|
|
245
|
-
$(window).on('resize.autosize', resize);
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
// Event for manual triggering if needed.
|
|
249
|
-
// Should only be needed when the value of the textarea is changed through JavaScript rather than user input.
|
|
250
|
-
$ta.on('autosize.resize', adjust);
|
|
251
|
-
|
|
252
|
-
// Event for manual triggering that also forces the styles to update as well.
|
|
253
|
-
// Should only be needed if one of typography styles of the textarea change, and the textarea is already the target of the adjust method.
|
|
254
|
-
$ta.on('autosize.resizeIncludeStyle', function() {
|
|
255
|
-
mirrored = null;
|
|
256
|
-
adjust();
|
|
257
|
-
});
|
|
258
|
-
|
|
259
|
-
$ta.on('autosize.destroy', function(){
|
|
260
|
-
mirrored = null;
|
|
261
|
-
clearTimeout(timeout);
|
|
262
|
-
$(window).off('resize', resize);
|
|
263
|
-
$ta
|
|
264
|
-
.off('autosize')
|
|
265
|
-
.off('.autosize')
|
|
266
|
-
.css(originalStyles)
|
|
267
|
-
.removeData('autosize');
|
|
268
|
-
});
|
|
269
|
-
|
|
270
|
-
// Call adjust in case the textarea already contains text.
|
|
271
|
-
adjust();
|
|
272
|
-
});
|
|
273
|
-
};
|
|
274
|
-
}(jQuery || $)); // jQuery or jQuery-like library, such as Zepto
|
data/assets/script/manifest.yml
DELETED
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
remote:
|
|
2
|
-
items:
|
|
3
|
-
- src: https://code.jquery.com/jquery-3.6.0.min.js
|
|
4
|
-
integrity: sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=
|
|
5
|
-
crossorigin: anonymous
|
|
6
|
-
- src: https://cdnjs.cloudflare.com/ajax/libs/jquery-ujs/1.2.0/rails.min.js
|
|
7
|
-
integrity: sha512-7JCF1tm2gqb7ddeKwz64uEhSx9f/Eu+90/LQ26ymVJlkrrOI7C1JR0KUHLi4FASyVwkuAekBNsMfCWJm1l9bHQ==
|
|
8
|
-
crossorigin: anonymous
|
|
9
|
-
referrerpolicy: no-referrer
|
|
10
|
-
|
|
11
|
-
jquery:
|
|
12
|
-
items:
|
|
13
|
-
# - ../../vendor/jquery_rails/vendor/assets/javascripts/jquery3.js
|
|
14
|
-
# - ../../vendor/jquery_rails/vendor/assets/javascripts/jquery_ujs.js
|
|
15
|
-
# jquery-ui includes all interaction components, the dialog and the autocomplete widget
|
|
16
|
-
# and all dependencies for those
|
|
17
|
-
# decko depends on autocomplete, sortable, jquery.autosize and jquery.fileupload
|
|
18
|
-
# the dialog widget is not used in decko but in wikirate
|
|
19
|
-
# don't know if iframe-transport is needed but it used to be there
|
|
20
|
-
- jquery-ui.min.js
|
|
21
|
-
- jquery.autosize.js
|
|
22
|
-
- ../../vendor/jquery_file_upload/js/jquery.fileupload.js
|
|
23
|
-
- ../../vendor/jquery_file_upload/js/jquery.iframe-transport.js
|
|
24
|
-
|
|
25
|
-
decko:
|
|
26
|
-
items:
|
|
27
|
-
- decko/mod.js.coffee
|
|
28
|
-
- decko/editor.js.coffee
|
|
29
|
-
- decko/name_editor.js.coffee
|
|
30
|
-
- decko/autosave.js.coffee
|
|
31
|
-
- decko/doubleclick.js.coffee
|
|
32
|
-
- decko/layout.js.coffee
|
|
33
|
-
- decko/navbox.js.coffee
|
|
34
|
-
- decko/upload.js.coffee
|
|
35
|
-
- decko/slot.js.coffee
|
|
36
|
-
- decko/decko.js.coffee
|
|
37
|
-
- decko/type_editor.js.coffee
|
|
38
|
-
- decko/modal.js.coffee
|
|
39
|
-
- decko/overlay.js.coffee
|
|
40
|
-
- decko/recaptcha.js.coffee
|
|
41
|
-
- decko/slotter.js.coffee
|
|
42
|
-
- decko/bridge.js.coffee
|
|
43
|
-
- decko/nest_editor.js.coffee
|
|
44
|
-
- decko/nest_editor_rules.js.coffee
|
|
45
|
-
- decko/nest_editor_options.js.coffee
|
|
46
|
-
- decko/nest_editor_name.js.coffee
|
|
47
|
-
- decko/link_editor.js.coffee
|
|
48
|
-
- decko/components.js.coffee
|
|
49
|
-
- decko/follow.js.coffee
|
|
50
|
-
- decko/card_menu.js.coffee
|
|
51
|
-
- decko/slot_ready.js.coffee
|
|
52
|
-
- decko/pointer_config.js.coffee
|
|
53
|
-
- decko/pointer_list_editor.js.coffee
|
|
54
|
-
- decko/filter.js.coffee
|
|
55
|
-
- decko/filter_links.js.coffee
|
|
56
|
-
- decko/filter_items.js.coffee
|
|
57
|
-
- decko/selectable_filtered_content.js.coffee
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
|
2
|
-
|
|
3
|
-
class AddModScriptAssetsType < Cardio::Migration::Core
|
|
4
|
-
def up
|
|
5
|
-
add_cardtypes
|
|
6
|
-
delete_script_cards
|
|
7
|
-
card = Card[:all, :script]
|
|
8
|
-
["script: jquery", "script: decko", "script: libraries",
|
|
9
|
-
"script: editors", "script: mods"].each do |name|
|
|
10
|
-
card.drop_item name
|
|
11
|
-
end
|
|
12
|
-
puts card.item_names
|
|
13
|
-
card.save!
|
|
14
|
-
end
|
|
15
|
-
|
|
16
|
-
def add_cardtypes
|
|
17
|
-
ensure_code_card name: "Mod script assets", type_code: :cardtype
|
|
18
|
-
ensure_code_card name: "Local script folder group", type_code: :cardtype
|
|
19
|
-
ensure_code_card name: "Local script manifest group", type_code: :cardtype
|
|
20
|
-
end
|
|
21
|
-
|
|
22
|
-
def delete_script_cards
|
|
23
|
-
delete_code_card :script_decko
|
|
24
|
-
delete_code_card :script_editors
|
|
25
|
-
delete_code_card :script_pointer_config
|
|
26
|
-
delete_code_card :script_jquery
|
|
27
|
-
delete_code_card :script_mods
|
|
28
|
-
delete_code_card :script_rules
|
|
29
|
-
end
|
|
30
|
-
end
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright © 2010 Sebastian Tschan, https://blueimp.net
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
6
|
-
this software and associated documentation files (the "Software"), to deal in
|
|
7
|
-
the Software without restriction, including without limitation the rights to
|
|
8
|
-
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
9
|
-
the Software, and to permit persons to whom the Software is furnished to do so,
|
|
10
|
-
subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
17
|
-
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
18
|
-
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
19
|
-
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
20
|
-
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -1,224 +0,0 @@
|
|
|
1
|
-
# jQuery File Upload
|
|
2
|
-
|
|
3
|
-
## Contents
|
|
4
|
-
|
|
5
|
-
- [Description](#description)
|
|
6
|
-
- [Demo](#demo)
|
|
7
|
-
- [Features](#features)
|
|
8
|
-
- [Security](#security)
|
|
9
|
-
- [Setup](#setup)
|
|
10
|
-
- [Requirements](#requirements)
|
|
11
|
-
- [Mandatory requirements](#mandatory-requirements)
|
|
12
|
-
- [Optional requirements](#optional-requirements)
|
|
13
|
-
- [Cross-domain requirements](#cross-domain-requirements)
|
|
14
|
-
- [Browsers](#browsers)
|
|
15
|
-
- [Desktop browsers](#desktop-browsers)
|
|
16
|
-
- [Mobile browsers](#mobile-browsers)
|
|
17
|
-
- [Extended browser support information](#extended-browser-support-information)
|
|
18
|
-
- [Testing](#testing)
|
|
19
|
-
- [Support](#support)
|
|
20
|
-
- [License](#license)
|
|
21
|
-
|
|
22
|
-
## Description
|
|
23
|
-
|
|
24
|
-
> File Upload widget with multiple file selection, drag&drop support, progress
|
|
25
|
-
> bars, validation and preview images, audio and video for jQuery.
|
|
26
|
-
> Supports cross-domain, chunked and resumable file uploads and client-side
|
|
27
|
-
> image resizing.
|
|
28
|
-
> Works with any server-side platform (PHP, Python, Ruby on Rails, Java,
|
|
29
|
-
> Node.js, Go etc.) that supports standard HTML form file uploads.
|
|
30
|
-
|
|
31
|
-
## Demo
|
|
32
|
-
|
|
33
|
-
[Demo File Upload](https://blueimp.github.io/jQuery-File-Upload/)
|
|
34
|
-
|
|
35
|
-
## Features
|
|
36
|
-
|
|
37
|
-
- **Multiple file upload:**
|
|
38
|
-
Allows to select multiple files at once and upload them simultaneously.
|
|
39
|
-
- **Drag & Drop support:**
|
|
40
|
-
Allows to upload files by dragging them from your desktop or file manager and
|
|
41
|
-
dropping them on your browser window.
|
|
42
|
-
- **Upload progress bar:**
|
|
43
|
-
Shows a progress bar indicating the upload progress for individual files and
|
|
44
|
-
for all uploads combined.
|
|
45
|
-
- **Cancelable uploads:**
|
|
46
|
-
Individual file uploads can be canceled to stop the upload progress.
|
|
47
|
-
- **Resumable uploads:**
|
|
48
|
-
Aborted uploads can be resumed with browsers supporting the Blob API.
|
|
49
|
-
- **Chunked uploads:**
|
|
50
|
-
Large files can be uploaded in smaller chunks with browsers supporting the
|
|
51
|
-
Blob API.
|
|
52
|
-
- **Client-side image resizing:**
|
|
53
|
-
Images can be automatically resized on client-side with browsers supporting
|
|
54
|
-
the required JS APIs.
|
|
55
|
-
- **Preview images, audio and video:**
|
|
56
|
-
A preview of image, audio and video files can be displayed before uploading
|
|
57
|
-
with browsers supporting the required APIs.
|
|
58
|
-
- **No browser plugins (e.g. Adobe Flash) required:**
|
|
59
|
-
The implementation is based on open standards like HTML5 and JavaScript and
|
|
60
|
-
requires no additional browser plugins.
|
|
61
|
-
- **Graceful fallback for legacy browsers:**
|
|
62
|
-
Uploads files via XMLHttpRequests if supported and uses iframes as fallback
|
|
63
|
-
for legacy browsers.
|
|
64
|
-
- **HTML file upload form fallback:**
|
|
65
|
-
Allows progressive enhancement by using a standard HTML file upload form as
|
|
66
|
-
widget element.
|
|
67
|
-
- **Cross-site file uploads:**
|
|
68
|
-
Supports uploading files to a different domain with cross-site XMLHttpRequests
|
|
69
|
-
or iframe redirects.
|
|
70
|
-
- **Multiple plugin instances:**
|
|
71
|
-
Allows to use multiple plugin instances on the same webpage.
|
|
72
|
-
- **Customizable and extensible:**
|
|
73
|
-
Provides an API to set individual options and define callback methods for
|
|
74
|
-
various upload events.
|
|
75
|
-
- **Multipart and file contents stream uploads:**
|
|
76
|
-
Files can be uploaded as standard "multipart/form-data" or file contents
|
|
77
|
-
stream (HTTP PUT file upload).
|
|
78
|
-
- **Compatible with any server-side application platform:**
|
|
79
|
-
Works with any server-side platform (PHP, Python, Ruby on Rails, Java,
|
|
80
|
-
Node.js, Go etc.) that supports standard HTML form file uploads.
|
|
81
|
-
|
|
82
|
-
## Security
|
|
83
|
-
|
|
84
|
-
⚠️ Please read the [VULNERABILITIES](VULNERABILITIES.md) document for a list of
|
|
85
|
-
fixed vulnerabilities
|
|
86
|
-
|
|
87
|
-
Please also read the [SECURITY](SECURITY.md) document for instructions on how to
|
|
88
|
-
securely configure your Web server for file uploads.
|
|
89
|
-
|
|
90
|
-
## Setup
|
|
91
|
-
|
|
92
|
-
jQuery File Upload can be installed via [NPM](https://www.npmjs.com/):
|
|
93
|
-
|
|
94
|
-
```sh
|
|
95
|
-
npm install blueimp-file-upload
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
This allows you to include [jquery.fileupload.js](js/jquery.fileupload.js) and
|
|
99
|
-
its extensions via `node_modules`, e.g:
|
|
100
|
-
|
|
101
|
-
```html
|
|
102
|
-
<script src="node_modules/blueimp-file-upload/js/jquery.fileupload.js"></script>
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
The widget can then be initialized on a file upload form the following way:
|
|
106
|
-
|
|
107
|
-
```js
|
|
108
|
-
$('#fileupload').fileupload();
|
|
109
|
-
```
|
|
110
|
-
|
|
111
|
-
For further information, please refer to the following guides:
|
|
112
|
-
|
|
113
|
-
- [Main documentation page](https://github.com/blueimp/jQuery-File-Upload/wiki)
|
|
114
|
-
- [List of all available Options](https://github.com/blueimp/jQuery-File-Upload/wiki/Options)
|
|
115
|
-
- [The plugin API](https://github.com/blueimp/jQuery-File-Upload/wiki/API)
|
|
116
|
-
- [How to setup the plugin on your website](https://github.com/blueimp/jQuery-File-Upload/wiki/Setup)
|
|
117
|
-
- [How to use only the basic plugin.](https://github.com/blueimp/jQuery-File-Upload/wiki/Basic-plugin)
|
|
118
|
-
|
|
119
|
-
## Requirements
|
|
120
|
-
|
|
121
|
-
### Mandatory requirements
|
|
122
|
-
|
|
123
|
-
- [jQuery](https://jquery.com/) v1.7+
|
|
124
|
-
- [jQuery UI widget factory](https://api.jqueryui.com/jQuery.widget/) v1.9+
|
|
125
|
-
(included): Required for the basic File Upload plugin, but very lightweight
|
|
126
|
-
without any other dependencies from the jQuery UI suite.
|
|
127
|
-
- [jQuery Iframe Transport plugin](https://github.com/blueimp/jQuery-File-Upload/blob/master/js/jquery.iframe-transport.js)
|
|
128
|
-
(included): Required for
|
|
129
|
-
[browsers without XHR file upload support](https://github.com/blueimp/jQuery-File-Upload/wiki/Browser-support).
|
|
130
|
-
|
|
131
|
-
### Optional requirements
|
|
132
|
-
|
|
133
|
-
- [JavaScript Templates engine](https://github.com/blueimp/JavaScript-Templates)
|
|
134
|
-
v3+: Used to render the selected and uploaded files.
|
|
135
|
-
- [JavaScript Load Image library](https://github.com/blueimp/JavaScript-Load-Image)
|
|
136
|
-
v2+: Required for the image previews and resizing functionality.
|
|
137
|
-
- [JavaScript Canvas to Blob polyfill](https://github.com/blueimp/JavaScript-Canvas-to-Blob)
|
|
138
|
-
v3+:Required for the resizing functionality.
|
|
139
|
-
- [blueimp Gallery](https://github.com/blueimp/Gallery) v2+: Used to display the
|
|
140
|
-
uploaded images in a lightbox.
|
|
141
|
-
- [Bootstrap](https://getbootstrap.com/) v3+: Used for the demo design.
|
|
142
|
-
- [Glyphicons](https://glyphicons.com/) Icon set used by Bootstrap.
|
|
143
|
-
|
|
144
|
-
### Cross-domain requirements
|
|
145
|
-
|
|
146
|
-
[Cross-domain File Uploads](https://github.com/blueimp/jQuery-File-Upload/wiki/Cross-domain-uploads)
|
|
147
|
-
using the
|
|
148
|
-
[Iframe Transport plugin](https://github.com/blueimp/jQuery-File-Upload/blob/master/js/jquery.iframe-transport.js)
|
|
149
|
-
require a redirect back to the origin server to retrieve the upload results. The
|
|
150
|
-
[example implementation](https://github.com/blueimp/jQuery-File-Upload/blob/master/js/main.js)
|
|
151
|
-
makes use of
|
|
152
|
-
[result.html](https://github.com/blueimp/jQuery-File-Upload/blob/master/cors/result.html)
|
|
153
|
-
as a static redirect page for the origin server.
|
|
154
|
-
|
|
155
|
-
The repository also includes the
|
|
156
|
-
[jQuery XDomainRequest Transport plugin](https://github.com/blueimp/jQuery-File-Upload/blob/master/js/cors/jquery.xdr-transport.js),
|
|
157
|
-
which enables limited cross-domain AJAX requests in Microsoft Internet Explorer
|
|
158
|
-
8 and 9 (IE 10 supports cross-domain XHR requests).
|
|
159
|
-
The XDomainRequest object allows GET and POST requests only and doesn't support
|
|
160
|
-
file uploads. It is used on the
|
|
161
|
-
[Demo](https://blueimp.github.io/jQuery-File-Upload/) to delete uploaded files
|
|
162
|
-
from the cross-domain demo file upload service.
|
|
163
|
-
|
|
164
|
-
## Browsers
|
|
165
|
-
|
|
166
|
-
### Desktop browsers
|
|
167
|
-
|
|
168
|
-
The File Upload plugin is regularly tested with the latest browser versions and
|
|
169
|
-
supports the following minimal versions:
|
|
170
|
-
|
|
171
|
-
- Google Chrome
|
|
172
|
-
- Apple Safari 4.0+
|
|
173
|
-
- Mozilla Firefox 3.0+
|
|
174
|
-
- Opera 11.0+
|
|
175
|
-
- Microsoft Internet Explorer 6.0+
|
|
176
|
-
|
|
177
|
-
### Mobile browsers
|
|
178
|
-
|
|
179
|
-
The File Upload plugin has been tested with and supports the following mobile
|
|
180
|
-
browsers:
|
|
181
|
-
|
|
182
|
-
- Apple Safari on iOS 6.0+
|
|
183
|
-
- Google Chrome on iOS 6.0+
|
|
184
|
-
- Google Chrome on Android 4.0+
|
|
185
|
-
- Default Browser on Android 2.3+
|
|
186
|
-
- Opera Mobile 12.0+
|
|
187
|
-
|
|
188
|
-
### Extended browser support information
|
|
189
|
-
|
|
190
|
-
For a detailed overview of the features supported by each browser version and
|
|
191
|
-
known operating system / browser bugs, please have a look at the
|
|
192
|
-
[Extended browser support information](https://github.com/blueimp/jQuery-File-Upload/wiki/Browser-support).
|
|
193
|
-
|
|
194
|
-
## Testing
|
|
195
|
-
|
|
196
|
-
The project comes with three sets of tests:
|
|
197
|
-
|
|
198
|
-
1. Code linting using [ESLint](https://eslint.org/).
|
|
199
|
-
2. Unit tests using [Mocha](https://mochajs.org/).
|
|
200
|
-
3. End-to-end tests using [blueimp/wdio](https://github.com/blueimp/wdio).
|
|
201
|
-
|
|
202
|
-
To run the tests, follow these steps:
|
|
203
|
-
|
|
204
|
-
1. Start [Docker](https://docs.docker.com/).
|
|
205
|
-
2. Install development dependencies:
|
|
206
|
-
```sh
|
|
207
|
-
npm install
|
|
208
|
-
```
|
|
209
|
-
3. Run the tests:
|
|
210
|
-
```sh
|
|
211
|
-
npm test
|
|
212
|
-
```
|
|
213
|
-
|
|
214
|
-
## Support
|
|
215
|
-
|
|
216
|
-
This project is actively maintained, but there is no official support channel.
|
|
217
|
-
If you have a question that another developer might help you with, please post
|
|
218
|
-
to
|
|
219
|
-
[Stack Overflow](https://stackoverflow.com/questions/tagged/blueimp+jquery+file-upload)
|
|
220
|
-
and tag your question with `blueimp jquery file upload`.
|
|
221
|
-
|
|
222
|
-
## License
|
|
223
|
-
|
|
224
|
-
Released under the [MIT license](https://opensource.org/licenses/MIT).
|