aboutsummaryrefslogtreecommitdiffhomepage
path: root/frontend/js
diff options
context:
space:
mode:
authorJohannes Zellner <johannes@cloudron.io>2017-02-05 06:14:47 -0800
committerJohannes Zellner <johannes@cloudron.io>2017-02-05 06:14:47 -0800
commit95e5eb9f0fa59001bc6ffd2baa4ddfd861e40122 (patch)
tree9187aab36843c95213ce8af3f4b336df9af5b383 /frontend/js
parent89f67d31a2be9a504c3f8215952c31ef1d72e20d (diff)
downloadSurfer-95e5eb9f0fa59001bc6ffd2baa4ddfd861e40122.tar.gz
Surfer-95e5eb9f0fa59001bc6ffd2baa4ddfd861e40122.tar.zst
Surfer-95e5eb9f0fa59001bc6ffd2baa4ddfd861e40122.zip
Rename app/ to frontend/
Diffstat (limited to 'frontend/js')
-rw-r--r--frontend/js/app.js276
-rw-r--r--frontend/js/bootstrap.js2363
-rw-r--r--frontend/js/bootstrap.min.js7
-rw-r--r--frontend/js/filesize.min.js6
-rw-r--r--frontend/js/jquery-1.12.1.min.js5
-rw-r--r--frontend/js/npm.js13
-rw-r--r--frontend/js/superagent.js1383
-rw-r--r--frontend/js/vue.min.js8
8 files changed, 4061 insertions, 0 deletions
diff --git a/frontend/js/app.js b/frontend/js/app.js
new file mode 100644
index 0000000..9a2e532
--- /dev/null
+++ b/frontend/js/app.js
@@ -0,0 +1,276 @@
1(function () {
2'use strict';
3
4function login(username, password) {
5 username = username || app.loginData.username;
6 password = password || app.loginData.password;
7
8 app.busy = true;
9
10 superagent.get('/api/files/').query({ username: username, password: password }).end(function (error, result) {
11 app.busy = false;
12
13 if (error) return console.error(error);
14 if (result.statusCode === 401) return console.error('Invalid credentials');
15
16 app.session.valid = true;
17 app.session.username = username;
18 app.session.password = password;
19
20 // clearly not the best option
21 localStorage.username = username;
22 localStorage.password = password;
23
24 loadDirectory(window.location.hash.slice(1));
25 });
26}
27
28function logout() {
29 app.session.valid = false;
30 app.session.username = null;
31 app.session.password = null;
32
33 delete localStorage.username;
34 delete localStorage.password;
35}
36
37function sanitize(filePath) {
38 filePath = '/' + filePath;
39 return filePath.replace(/\/+/g, '/');
40}
41
42function encode(filePath) {
43 return filePath.split('/').map(encodeURIComponent).join('/');
44}
45
46function decode(filePath) {
47 return filePath.split('/').map(decodeURIComponent).join('/');
48}
49
50var mimeTypes = {
51 images: [ '.png', '.jpg', '.jpeg', '.tiff', '.gif' ],
52 text: [ '.txt', '.md' ],
53 pdf: [ '.pdf' ],
54 html: [ '.html', '.htm', '.php' ],
55 video: [ '.mp4', '.mpg', '.mpeg', '.ogg', '.mkv' ]
56};
57
58function getPreviewUrl(entry, basePath) {
59 var path = '/_admin/img/';
60
61 if (entry.isDirectory) return path + 'directory.png';
62 if (mimeTypes.images.some(function (e) { return entry.filePath.endsWith(e); })) return sanitize(basePath + '/' + entry.filePath);
63 if (mimeTypes.text.some(function (e) { return entry.filePath.endsWith(e); })) return path +'text.png';
64 if (mimeTypes.pdf.some(function (e) { return entry.filePath.endsWith(e); })) return path + 'pdf.png';
65 if (mimeTypes.html.some(function (e) { return entry.filePath.endsWith(e); })) return path + 'html.png';
66 if (mimeTypes.video.some(function (e) { return entry.filePath.endsWith(e); })) return path + 'video.png';
67
68 return path + 'unknown.png';
69}
70
71function refresh() {
72 loadDirectory(app.path);
73}
74
75function loadDirectory(filePath) {
76 app.busy = true;
77
78 filePath = filePath ? sanitize(filePath) : '/';
79
80 superagent.get('/api/files/' + encode(filePath)).query({ username: app.session.username, password: app.session.password }).end(function (error, result) {
81 app.busy = false;
82
83 if (result && result.statusCode === 401) return logout();
84 if (error) return console.error(error);
85
86 result.body.entries.sort(function (a, b) { return a.isDirectory && b.isFile ? -1 : 1; });
87 app.entries = result.body.entries.map(function (entry) {
88 entry.previewUrl = getPreviewUrl(entry, filePath);
89 return entry;
90 });
91 app.path = filePath;
92 app.pathParts = decode(filePath).split('/').filter(function (e) { return !!e; }).map(function (e, i, a) {
93 return {
94 name: e,
95 link: '#' + sanitize('/' + a.slice(0, i).join('/') + '/' + e)
96 };
97 });
98
99 // update in case this was triggered from code
100 window.location.hash = app.path;
101
102 Vue.nextTick(function () {
103 $(function () {
104 $('[data-toggle="tooltip"]').tooltip();
105 });
106 });
107 });
108}
109
110function open(entry) {
111 var path = sanitize(app.path + '/' + entry.filePath);
112
113 if (entry.isDirectory) {
114 window.location.hash = path;
115 return;
116 }
117
118 window.open(encode(path));
119}
120
121function up() {
122 window.location.hash = sanitize(app.path.split('/').slice(0, -1).filter(function (p) { return !!p; }).join('/'));
123}
124
125function upload() {
126 $(app.$els.upload).on('change', function () {
127 app.busy = true;
128
129 // detach event handler
130 $(app.$els.upload).off('change');
131
132 var length = app.$els.upload.files.length;
133 var done = 0;
134
135 function uploadFile(file) {
136 var path = encode(sanitize(app.path + '/' + file.name));
137
138 var formData = new FormData();
139 formData.append('file', file);
140
141 superagent.put('/api/files' + path).query({ username: app.session.username, password: app.session.password }).send(formData).end(function (error, result) {
142 if (result && result.statusCode === 401) return logout();
143 if (result && result.statusCode !== 201) console.error('Error uploading file: ', result.statusCode);
144 if (error) console.error(error);
145
146 ++done;
147
148 if (done >= length) {
149 app.busy = false;
150 refresh();
151 }
152 });
153 }
154
155 for(var i = 0; i < length; i++) {
156 uploadFile(app.$els.upload.files[i]);
157 }
158 });
159
160 // reset the form first to make the change handler retrigger even on the same file selected
161 $('#fileUploadForm')[0].reset();
162
163 app.$els.upload.click();
164}
165
166function delAsk(entry) {
167 $('#modalDelete').modal('show');
168 app.deleteData = entry;
169}
170
171function del(entry) {
172 app.busy = true;
173
174 var path = encode(sanitize(app.path + '/' + entry.filePath));
175
176 superagent.del('/api/files' + path).query({ username: app.session.username, password: app.session.password, recursive: true }).end(function (error, result) {
177 app.busy = false;
178
179 if (result && result.statusCode === 401) return logout();
180 if (result && result.statusCode !== 200) return console.error('Error deleting file: ', result.statusCode);
181 if (error) return console.error(error);
182
183 refresh();
184
185 $('#modalDelete').modal('hide');
186 });
187}
188
189function createDirectoryAsk() {
190 $('#modalcreateDirectory').modal('show');
191 app.createDirectoryData = '';
192 app.createDirectoryError = null;
193}
194
195function createDirectory(name) {
196 app.busy = true;
197 app.createDirectoryError = null;
198
199 var path = encode(sanitize(app.path + '/' + name));
200
201 superagent.put('/api/files' + path).query({ username: app.session.username, password: app.session.password, directory: true }).end(function (error, result) {
202 app.busy = false;
203
204 if (result && result.statusCode === 401) return logout();
205 if (result && result.statusCode === 403) {
206 app.createDirectoryError = 'Name not allowed';
207 return;
208 }
209 if (result && result.statusCode === 409) {
210 app.createDirectoryError = 'Directory already exists';
211 return;
212 }
213 if (result && result.statusCode !== 201) return console.error('Error creating directory: ', result.statusCode);
214 if (error) return console.error(error);
215
216 app.createDirectoryData = '';
217 refresh();
218
219 $('#modalcreateDirectory').modal('hide');
220 });
221}
222
223Vue.filter('prettyDate', function (value) {
224 var d = new Date(value);
225 return d.toDateString();
226});
227
228Vue.filter('prettyFileSize', function (value) {
229 return filesize(value);
230});
231
232var app = new Vue({
233 el: '#app',
234 data: {
235 busy: true,
236 path: '/',
237 pathParts: [],
238 session: {
239 valid: false
240 },
241 loginData: {},
242 deleteData: {},
243 createDirectoryData: '',
244 createDirectoryError: null,
245 entries: []
246 },
247 methods: {
248 login: login,
249 logout: logout,
250 loadDirectory: loadDirectory,
251 open: open,
252 up: up,
253 upload: upload,
254 delAsk: delAsk,
255 del: del,
256 createDirectoryAsk: createDirectoryAsk,
257 createDirectory: createDirectory
258 }
259});
260
261window.app = app;
262
263login(localStorage.username, localStorage.password);
264
265$(window).on('hashchange', function () {
266 loadDirectory(window.location.hash.slice(1));
267});
268
269// setup all the dialog focus handling
270['modalcreateDirectory'].forEach(function (id) {
271 $('#' + id).on('shown.bs.modal', function () {
272 $(this).find("[autofocus]:first").focus();
273 });
274});
275
276})();
diff --git a/frontend/js/bootstrap.js b/frontend/js/bootstrap.js
new file mode 100644
index 0000000..01fbbcb
--- /dev/null
+++ b/frontend/js/bootstrap.js
@@ -0,0 +1,2363 @@
1/*!
2 * Bootstrap v3.3.6 (http://getbootstrap.com)
3 * Copyright 2011-2015 Twitter, Inc.
4 * Licensed under the MIT license
5 */
6
7if (typeof jQuery === 'undefined') {
8 throw new Error('Bootstrap\'s JavaScript requires jQuery')
9}
10
11+function ($) {
12 'use strict';
13 var version = $.fn.jquery.split(' ')[0].split('.')
14 if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1) || (version[0] > 2)) {
15 throw new Error('Bootstrap\'s JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3')
16 }
17}(jQuery);
18
19/* ========================================================================
20 * Bootstrap: transition.js v3.3.6
21 * http://getbootstrap.com/javascript/#transitions
22 * ========================================================================
23 * Copyright 2011-2015 Twitter, Inc.
24 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
25 * ======================================================================== */
26
27
28+function ($) {
29 'use strict';
30
31 // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
32 // ============================================================
33
34 function transitionEnd() {
35 var el = document.createElement('bootstrap')
36
37 var transEndEventNames = {
38 WebkitTransition : 'webkitTransitionEnd',
39 MozTransition : 'transitionend',
40 OTransition : 'oTransitionEnd otransitionend',
41 transition : 'transitionend'
42 }
43
44 for (var name in transEndEventNames) {
45 if (el.style[name] !== undefined) {
46 return { end: transEndEventNames[name] }
47 }
48 }
49
50 return false // explicit for ie8 ( ._.)
51 }
52
53 // http://blog.alexmaccaw.com/css-transitions
54 $.fn.emulateTransitionEnd = function (duration) {
55 var called = false
56 var $el = this
57 $(this).one('bsTransitionEnd', function () { called = true })
58 var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
59 setTimeout(callback, duration)
60 return this
61 }
62
63 $(function () {
64 $.support.transition = transitionEnd()
65
66 if (!$.support.transition) return
67
68 $.event.special.bsTransitionEnd = {
69 bindType: $.support.transition.end,
70 delegateType: $.support.transition.end,
71 handle: function (e) {
72 if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments)
73 }
74 }
75 })
76
77}(jQuery);
78
79/* ========================================================================
80 * Bootstrap: alert.js v3.3.6
81 * http://getbootstrap.com/javascript/#alerts
82 * ========================================================================
83 * Copyright 2011-2015 Twitter, Inc.
84 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
85 * ======================================================================== */
86
87
88+function ($) {
89 'use strict';
90
91 // ALERT CLASS DEFINITION
92 // ======================
93
94 var dismiss = '[data-dismiss="alert"]'
95 var Alert = function (el) {
96 $(el).on('click', dismiss, this.close)
97 }
98
99 Alert.VERSION = '3.3.6'
100
101 Alert.TRANSITION_DURATION = 150
102
103 Alert.prototype.close = function (e) {
104 var $this = $(this)
105 var selector = $this.attr('data-target')
106
107 if (!selector) {
108 selector = $this.attr('href')
109 selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
110 }
111
112 var $parent = $(selector)
113
114 if (e) e.preventDefault()
115
116 if (!$parent.length) {
117 $parent = $this.closest('.alert')
118 }
119
120 $parent.trigger(e = $.Event('close.bs.alert'))
121
122 if (e.isDefaultPrevented()) return
123
124 $parent.removeClass('in')
125
126 function removeElement() {
127 // detach from parent, fire event then clean up data
128 $parent.detach().trigger('closed.bs.alert').remove()
129 }
130
131 $.support.transition && $parent.hasClass('fade') ?
132 $parent
133 .one('bsTransitionEnd', removeElement)
134 .emulateTransitionEnd(Alert.TRANSITION_DURATION) :
135 removeElement()
136 }
137
138
139 // ALERT PLUGIN DEFINITION
140 // =======================
141
142 function Plugin(option) {
143 return this.each(function () {
144 var $this = $(this)
145 var data = $this.data('bs.alert')
146
147 if (!data) $this.data('bs.alert', (data = new Alert(this)))
148 if (typeof option == 'string') data[option].call($this)
149 })
150 }
151
152 var old = $.fn.alert
153
154 $.fn.alert = Plugin
155 $.fn.alert.Constructor = Alert
156
157
158 // ALERT NO CONFLICT
159 // =================
160
161 $.fn.alert.noConflict = function () {
162 $.fn.alert = old
163 return this
164 }
165
166
167 // ALERT DATA-API
168 // ==============
169
170 $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close)
171
172}(jQuery);
173
174/* ========================================================================
175 * Bootstrap: button.js v3.3.6
176 * http://getbootstrap.com/javascript/#buttons
177 * ========================================================================
178 * Copyright 2011-2015 Twitter, Inc.
179 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
180 * ======================================================================== */
181
182
183+function ($) {
184 'use strict';
185
186 // BUTTON PUBLIC CLASS DEFINITION
187 // ==============================
188
189 var Button = function (element, options) {
190 this.$element = $(element)
191 this.options = $.extend({}, Button.DEFAULTS, options)
192 this.isLoading = false
193 }
194
195 Button.VERSION = '3.3.6'
196
197 Button.DEFAULTS = {
198 loadingText: 'loading...'
199 }
200
201 Button.prototype.setState = function (state) {
202 var d = 'disabled'
203 var $el = this.$element
204 var val = $el.is('input') ? 'val' : 'html'
205 var data = $el.data()
206
207 state += 'Text'
208
209 if (data.resetText == null) $el.data('resetText', $el[val]())
210
211 // push to event loop to allow forms to submit
212 setTimeout($.proxy(function () {
213 $el[val](data[state] == null ? this.options[state] : data[state])
214
215 if (state == 'loadingText') {
216 this.isLoading = true
217 $el.addClass(d).attr(d, d)
218 } else if (this.isLoading) {
219 this.isLoading = false
220 $el.removeClass(d).removeAttr(d)
221 }
222 }, this), 0)
223 }
224
225 Button.prototype.toggle = function () {
226 var changed = true
227 var $parent = this.$element.closest('[data-toggle="buttons"]')
228
229 if ($parent.length) {
230 var $input = this.$element.find('input')
231 if ($input.prop('type') == 'radio') {
232 if ($input.prop('checked')) changed = false
233 $parent.find('.active').removeClass('active')
234 this.$element.addClass('active')
235 } else if ($input.prop('type') == 'checkbox') {
236 if (($input.prop('checked')) !== this.$element.hasClass('active')) changed = false
237 this.$element.toggleClass('active')
238 }
239 $input.prop('checked', this.$element.hasClass('active'))
240 if (changed) $input.trigger('change')
241 } else {
242 this.$element.attr('aria-pressed', !this.$element.hasClass('active'))
243 this.$element.toggleClass('active')
244 }
245 }
246
247
248 // BUTTON PLUGIN DEFINITION
249 // ========================
250
251 function Plugin(option) {
252 return this.each(function () {
253 var $this = $(this)
254 var data = $this.data('bs.button')
255 var options = typeof option == 'object' && option
256
257 if (!data) $this.data('bs.button', (data = new Button(this, options)))
258
259 if (option == 'toggle') data.toggle()
260 else if (option) data.setState(option)
261 })
262 }
263
264 var old = $.fn.button
265
266 $.fn.button = Plugin
267 $.fn.button.Constructor = Button
268
269
270 // BUTTON NO CONFLICT
271 // ==================
272
273 $.fn.button.noConflict = function () {
274 $.fn.button = old
275 return this
276 }
277
278
279 // BUTTON DATA-API
280 // ===============
281
282 $(document)
283 .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) {
284 var $btn = $(e.target)
285 if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
286 Plugin.call($btn, 'toggle')
287 if (!($(e.target).is('input[type="radio"]') || $(e.target).is('input[type="checkbox"]'))) e.preventDefault()
288 })
289 .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) {
290 $(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type))
291 })
292
293}(jQuery);
294
295/* ========================================================================
296 * Bootstrap: carousel.js v3.3.6
297 * http://getbootstrap.com/javascript/#carousel
298 * ========================================================================
299 * Copyright 2011-2015 Twitter, Inc.
300 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
301 * ======================================================================== */
302
303
304+function ($) {
305 'use strict';
306
307 // CAROUSEL CLASS DEFINITION
308 // =========================
309
310 var Carousel = function (element, options) {
311 this.$element = $(element)
312 this.$indicators = this.$element.find('.carousel-indicators')
313 this.options = options
314 this.paused = null
315 this.sliding = null
316 this.interval = null
317 this.$active = null
318 this.$items = null
319
320 this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this))
321
322 this.options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element
323 .on('mouseenter.bs.carousel', $.proxy(this.pause, this))
324 .on('mouseleave.bs.carousel', $.proxy(this.cycle, this))
325 }
326
327 Carousel.VERSION = '3.3.6'
328
329 Carousel.TRANSITION_DURATION = 600
330
331 Carousel.DEFAULTS = {
332 interval: 5000,
333 pause: 'hover',
334 wrap: true,
335 keyboard: true
336 }
337
338 Carousel.prototype.keydown = function (e) {
339 if (/input|textarea/i.test(e.target.tagName)) return
340 switch (e.which) {
341 case 37: this.prev(); break
342 case 39: this.next(); break
343 default: return
344 }
345
346 e.preventDefault()
347 }
348
349 Carousel.prototype.cycle = function (e) {
350 e || (this.paused = false)
351
352 this.interval && clearInterval(this.interval)
353
354 this.options.interval
355 && !this.paused
356 && (this.interval = setInterval($.proxy(this.next, this), this.options.interval))
357
358 return this
359 }
360
361 Carousel.prototype.getItemIndex = function (item) {
362 this.$items = item.parent().children('.item')
363 return this.$items.index(item || this.$active)
364 }
365
366 Carousel.prototype.getItemForDirection = function (direction, active) {
367 var activeIndex = this.getItemIndex(active)
368 var willWrap = (direction == 'prev' && activeIndex === 0)
369 || (direction == 'next' && activeIndex == (this.$items.length - 1))
370 if (willWrap && !this.options.wrap) return active
371 var delta = direction == 'prev' ? -1 : 1
372 var itemIndex = (activeIndex + delta) % this.$items.length
373 return this.$items.eq(itemIndex)
374 }
375
376 Carousel.prototype.to = function (pos) {
377 var that = this
378 var activeIndex = this.getItemIndex(this.$active = this.$element.find('.item.active'))
379
380 if (pos > (this.$items.length - 1) || pos < 0) return
381
382 if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid"
383 if (activeIndex == pos) return this.pause().cycle()
384
385 return this.slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos))
386 }
387
388 Carousel.prototype.pause = function (e) {
389 e || (this.paused = true)
390
391 if (this.$element.find('.next, .prev').length && $.support.transition) {
392 this.$element.trigger($.support.transition.end)
393 this.cycle(true)
394 }
395
396 this.interval = clearInterval(this.interval)
397
398 return this
399 }
400
401 Carousel.prototype.next = function () {
402 if (this.sliding) return
403 return this.slide('next')
404 }
405
406 Carousel.prototype.prev = function () {
407 if (this.sliding) return
408 return this.slide('prev')
409 }
410
411 Carousel.prototype.slide = function (type, next) {
412 var $active = this.$element.find('.item.active')
413 var $next = next || this.getItemForDirection(type, $active)
414 var isCycling = this.interval
415 var direction = type == 'next' ? 'left' : 'right'
416 var that = this
417
418 if ($next.hasClass('active')) return (this.sliding = false)
419
420 var relatedTarget = $next[0]
421 var slideEvent = $.Event('slide.bs.carousel', {
422 relatedTarget: relatedTarget,
423 direction: direction
424 })
425 this.$element.trigger(slideEvent)
426 if (slideEvent.isDefaultPrevented()) return
427
428 this.sliding = true
429
430 isCycling && this.pause()
431
432 if (this.$indicators.length) {
433 this.$indicators.find('.active').removeClass('active')
434 var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)])
435 $nextIndicator && $nextIndicator.addClass('active')
436 }
437
438 var slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) // yes, "slid"
439 if ($.support.transition && this.$element.hasClass('slide')) {
440 $next.addClass(type)
441 $next[0].offsetWidth // force reflow
442 $active.addClass(direction)
443 $next.addClass(direction)
444 $active
445 .one('bsTransitionEnd', function () {
446 $next.removeClass([type, direction].join(' ')).addClass('active')
447 $active.removeClass(['active', direction].join(' '))
448 that.sliding = false
449 setTimeout(function () {
450 that.$element.trigger(slidEvent)
451 }, 0)
452 })
453 .emulateTransitionEnd(Carousel.TRANSITION_DURATION)
454 } else {
455 $active.removeClass('active')
456 $next.addClass('active')
457 this.sliding = false
458 this.$element.trigger(slidEvent)
459 }
460
461 isCycling && this.cycle()
462
463 return this
464 }
465
466
467 // CAROUSEL PLUGIN DEFINITION
468 // ==========================
469
470 function Plugin(option) {
471 return this.each(function () {
472 var $this = $(this)
473 var data = $this.data('bs.carousel')
474 var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option)
475 var action = typeof option == 'string' ? option : options.slide
476
477 if (!data) $this.data('bs.carousel', (data = new Carousel(this, options)))
478 if (typeof option == 'number') data.to(option)
479 else if (action) data[action]()
480 else if (options.interval) data.pause().cycle()
481 })
482 }
483
484 var old = $.fn.carousel
485
486 $.fn.carousel = Plugin
487 $.fn.carousel.Constructor = Carousel
488
489
490 // CAROUSEL NO CONFLICT
491 // ====================
492
493 $.fn.carousel.noConflict = function () {
494 $.fn.carousel = old
495 return this
496 }
497
498
499 // CAROUSEL DATA-API
500 // =================
501
502 var clickHandler = function (e) {
503 var href
504 var $this = $(this)
505 var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7
506 if (!$target.hasClass('carousel')) return
507 var options = $.extend({}, $target.data(), $this.data())
508 var slideIndex = $this.attr('data-slide-to')
509 if (slideIndex) options.interval = false
510
511 Plugin.call($target, options)
512
513 if (slideIndex) {
514 $target.data('bs.carousel').to(slideIndex)
515 }
516
517 e.preventDefault()
518 }
519
520 $(document)
521 .on('click.bs.carousel.data-api', '[data-slide]', clickHandler)
522 .on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler)
523
524 $(window).on('load', function () {
525 $('[data-ride="carousel"]').each(function () {
526 var $carousel = $(this)
527 Plugin.call($carousel, $carousel.data())
528 })
529 })
530
531}(jQuery);
532
533/* ========================================================================
534 * Bootstrap: collapse.js v3.3.6
535 * http://getbootstrap.com/javascript/#collapse
536 * ========================================================================
537 * Copyright 2011-2015 Twitter, Inc.
538 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
539 * ======================================================================== */
540
541
542+function ($) {
543 'use strict';
544
545 // COLLAPSE PUBLIC CLASS DEFINITION
546 // ================================
547
548 var Collapse = function (element, options) {
549 this.$element = $(element)
550 this.options = $.extend({}, Collapse.DEFAULTS, options)
551 this.$trigger = $('[data-toggle="collapse"][href="#' + element.id + '"],' +
552 '[data-toggle="collapse"][data-target="#' + element.id + '"]')
553 this.transitioning = null
554
555 if (this.options.parent) {
556 this.$parent = this.getParent()
557 } else {
558 this.addAriaAndCollapsedClass(this.$element, this.$trigger)
559 }
560
561 if (this.options.toggle) this.toggle()
562 }
563
564 Collapse.VERSION = '3.3.6'
565
566 Collapse.TRANSITION_DURATION = 350
567
568 Collapse.DEFAULTS = {
569 toggle: true
570 }
571
572 Collapse.prototype.dimension = function () {
573 var hasWidth = this.$element.hasClass('width')
574 return hasWidth ? 'width' : 'height'
575 }
576
577 Collapse.prototype.show = function () {
578 if (this.transitioning || this.$element.hasClass('in')) return
579
580 var activesData
581 var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing')
582
583 if (actives && actives.length) {
584 activesData = actives.data('bs.collapse')
585 if (activesData && activesData.transitioning) return
586 }
587
588 var startEvent = $.Event('show.bs.collapse')
589 this.$element.trigger(startEvent)
590 if (startEvent.isDefaultPrevented()) return
591
592 if (actives && actives.length) {
593 Plugin.call(actives, 'hide')
594 activesData || actives.data('bs.collapse', null)
595 }
596
597 var dimension = this.dimension()
598
599 this.$element
600 .removeClass('collapse')
601 .addClass('collapsing')[dimension](0)
602 .attr('aria-expanded', true)
603
604 this.$trigger
605 .removeClass('collapsed')
606 .attr('aria-expanded', true)
607
608 this.transitioning = 1
609
610 var complete = function () {
611 this.$element
612 .removeClass('collapsing')
613 .addClass('collapse in')[dimension]('')
614 this.transitioning = 0
615 this.$element
616 .trigger('shown.bs.collapse')
617 }
618
619 if (!$.support.transition) return complete.call(this)
620
621 var scrollSize = $.camelCase(['scroll', dimension].join('-'))
622
623 this.$element
624 .one('bsTransitionEnd', $.proxy(complete, this))
625 .emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize])
626 }
627
628 Collapse.prototype.hide = function () {
629 if (this.transitioning || !this.$element.hasClass('in')) return
630
631 var startEvent = $.Event('hide.bs.collapse')
632 this.$element.trigger(startEvent)
633 if (startEvent.isDefaultPrevented()) return
634
635 var dimension = this.dimension()
636
637 this.$element[dimension](this.$element[dimension]())[0].offsetHeight
638
639 this.$element
640 .addClass('collapsing')
641 .removeClass('collapse in')
642 .attr('aria-expanded', false)
643
644 this.$trigger
645 .addClass('collapsed')
646 .attr('aria-expanded', false)
647
648 this.transitioning = 1
649
650 var complete = function () {
651 this.transitioning = 0
652 this.$element
653 .removeClass('collapsing')
654 .addClass('collapse')
655 .trigger('hidden.bs.collapse')
656 }
657
658 if (!$.support.transition) return complete.call(this)
659
660 this.$element
661 [dimension](0)
662 .one('bsTransitionEnd', $.proxy(complete, this))
663 .emulateTransitionEnd(Collapse.TRANSITION_DURATION)
664 }
665
666 Collapse.prototype.toggle = function () {
667 this[this.$element.hasClass('in') ? 'hide' : 'show']()
668 }
669
670 Collapse.prototype.getParent = function () {
671 return $(this.options.parent)
672 .find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
673 .each($.proxy(function (i, element) {
674 var $element = $(element)
675 this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element)
676 }, this))
677 .end()
678 }
679
680 Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) {
681 var isOpen = $element.hasClass('in')
682
683 $element.attr('aria-expanded', isOpen)
684 $trigger
685 .toggleClass('collapsed', !isOpen)
686 .attr('aria-expanded', isOpen)
687 }
688
689 function getTargetFromTrigger($trigger) {
690 var href
691 var target = $trigger.attr('data-target')
692 || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7
693
694 return $(target)
695 }
696
697
698 // COLLAPSE PLUGIN DEFINITION
699 // ==========================
700
701 function Plugin(option) {
702 return this.each(function () {
703 var $this = $(this)
704 var data = $this.data('bs.collapse')
705 var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option)
706
707 if (!data && options.toggle && /show|hide/.test(option)) options.toggle = false
708 if (!data) $this.data('bs.collapse', (data = new Collapse(this, options)))
709 if (typeof option == 'string') data[option]()
710 })
711 }
712
713 var old = $.fn.collapse
714
715 $.fn.collapse = Plugin
716 $.fn.collapse.Constructor = Collapse
717
718
719 // COLLAPSE NO CONFLICT
720 // ====================
721
722 $.fn.collapse.noConflict = function () {
723 $.fn.collapse = old
724 return this
725 }
726
727
728 // COLLAPSE DATA-API
729 // =================
730
731 $(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) {
732 var $this = $(this)
733
734 if (!$this.attr('data-target')) e.preventDefault()
735
736 var $target = getTargetFromTrigger($this)
737 var data = $target.data('bs.collapse')
738 var option = data ? 'toggle' : $this.data()
739
740 Plugin.call($target, option)
741 })
742
743}(jQuery);
744
745/* ========================================================================
746 * Bootstrap: dropdown.js v3.3.6
747 * http://getbootstrap.com/javascript/#dropdowns
748 * ========================================================================
749 * Copyright 2011-2015 Twitter, Inc.
750 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
751 * ======================================================================== */
752
753
754+function ($) {
755 'use strict';
756
757 // DROPDOWN CLASS DEFINITION
758 // =========================
759
760 var backdrop = '.dropdown-backdrop'
761 var toggle = '[data-toggle="dropdown"]'
762 var Dropdown = function (element) {
763 $(element).on('click.bs.dropdown', this.toggle)
764 }
765
766 Dropdown.VERSION = '3.3.6'
767
768 function getParent($this) {
769 var selector = $this.attr('data-target')
770
771 if (!selector) {
772 selector = $this.attr('href')
773 selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
774 }
775
776 var $parent = selector && $(selector)
777
778 return $parent && $parent.length ? $parent : $this.parent()
779 }
780
781 function clearMenus(e) {
782 if (e && e.which === 3) return
783 $(backdrop).remove()
784 $(toggle).each(function () {
785 var $this = $(this)
786 var $parent = getParent($this)
787 var relatedTarget = { relatedTarget: this }
788
789 if (!$parent.hasClass('open')) return
790
791 if (e && e.type == 'click' && /input|textarea/i.test(e.target.tagName) && $.contains($parent[0], e.target)) return
792
793 $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget))
794
795 if (e.isDefaultPrevented()) return
796
797 $this.attr('aria-expanded', 'false')
798 $parent.removeClass('open').trigger($.Event('hidden.bs.dropdown', relatedTarget))
799 })
800 }
801
802 Dropdown.prototype.toggle = function (e) {
803 var $this = $(this)
804
805 if ($this.is('.disabled, :disabled')) return
806
807 var $parent = getParent($this)
808 var isActive = $parent.hasClass('open')
809
810 clearMenus()
811
812 if (!isActive) {
813 if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) {
814 // if mobile we use a backdrop because click events don't delegate
815 $(document.createElement('div'))
816 .addClass('dropdown-backdrop')
817 .insertAfter($(this))
818 .on('click', clearMenus)
819 }
820
821 var relatedTarget = { relatedTarget: this }
822 $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget))
823
824 if (e.isDefaultPrevented()) return
825
826 $this
827 .trigger('focus')
828 .attr('aria-expanded', 'true')
829
830 $parent
831 .toggleClass('open')
832 .trigger($.Event('shown.bs.dropdown', relatedTarget))
833 }
834
835 return false
836 }
837
838 Dropdown.prototype.keydown = function (e) {
839 if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return
840
841 var $this = $(this)
842
843 e.preventDefault()
844 e.stopPropagation()
845
846 if ($this.is('.disabled, :disabled')) return
847
848 var $parent = getParent($this)
849 var isActive = $parent.hasClass('open')
850
851 if (!isActive && e.which != 27 || isActive && e.which == 27) {
852 if (e.which == 27) $parent.find(toggle).trigger('focus')
853 return $this.trigger('click')
854 }
855
856 var desc = ' li:not(.disabled):visible a'
857 var $items = $parent.find('.dropdown-menu' + desc)
858
859 if (!$items.length) return
860
861 var index = $items.index(e.target)
862
863 if (e.which == 38 && index > 0) index-- // up
864 if (e.which == 40 && index < $items.length - 1) index++ // down
865 if (!~index) index = 0
866
867 $items.eq(index).trigger('focus')
868 }
869
870
871 // DROPDOWN PLUGIN DEFINITION
872 // ==========================
873
874 function Plugin(option) {
875 return this.each(function () {
876 var $this = $(this)
877 var data = $this.data('bs.dropdown')
878
879 if (!data) $this.data('bs.dropdown', (data = new Dropdown(this)))
880 if (typeof option == 'string') data[option].call($this)
881 })
882 }
883
884 var old = $.fn.dropdown
885
886 $.fn.dropdown = Plugin
887 $.fn.dropdown.Constructor = Dropdown
888
889
890 // DROPDOWN NO CONFLICT
891 // ====================
892
893 $.fn.dropdown.noConflict = function () {
894 $.fn.dropdown = old
895 return this
896 }
897
898
899 // APPLY TO STANDARD DROPDOWN ELEMENTS
900 // ===================================
901
902 $(document)
903 .on('click.bs.dropdown.data-api', clearMenus)
904 .on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
905 .on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle)
906 .on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown)
907 .on('keydown.bs.dropdown.data-api', '.dropdown-menu', Dropdown.prototype.keydown)
908
909}(jQuery);
910
911/* ========================================================================
912 * Bootstrap: modal.js v3.3.6
913 * http://getbootstrap.com/javascript/#modals
914 * ========================================================================
915 * Copyright 2011-2015 Twitter, Inc.
916 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
917 * ======================================================================== */
918
919
920+function ($) {
921 'use strict';
922
923 // MODAL CLASS DEFINITION
924 // ======================
925
926 var Modal = function (element, options) {
927 this.options = options
928 this.$body = $(document.body)
929 this.$element = $(element)
930 this.$dialog = this.$element.find('.modal-dialog')
931 this.$backdrop = null
932 this.isShown = null
933 this.originalBodyPad = null
934 this.scrollbarWidth = 0
935 this.ignoreBackdropClick = false
936
937 if (this.options.remote) {
938 this.$element
939 .find('.modal-content')
940 .load(this.options.remote, $.proxy(function () {
941 this.$element.trigger('loaded.bs.modal')
942 }, this))
943 }
944 }
945
946 Modal.VERSION = '3.3.6'
947
948 Modal.TRANSITION_DURATION = 300
949 Modal.BACKDROP_TRANSITION_DURATION = 150
950
951 Modal.DEFAULTS = {
952 backdrop: true,
953 keyboard: true,
954 show: true
955 }
956
957 Modal.prototype.toggle = function (_relatedTarget) {
958 return this.isShown ? this.hide() : this.show(_relatedTarget)
959 }
960
961 Modal.prototype.show = function (_relatedTarget) {
962 var that = this
963 var e = $.Event('show.bs.modal', { relatedTarget: _relatedTarget })
964
965 this.$element.trigger(e)
966
967 if (this.isShown || e.isDefaultPrevented()) return
968
969 this.isShown = true
970
971 this.checkScrollbar()
972 this.setScrollbar()
973 this.$body.addClass('modal-open')
974
975 this.escape()
976 this.resize()
977
978 this.$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this))
979
980 this.$dialog.on('mousedown.dismiss.bs.modal', function () {
981 that.$element.one('mouseup.dismiss.bs.modal', function (e) {
982 if ($(e.target).is(that.$element)) that.ignoreBackdropClick = true
983 })
984 })
985
986 this.backdrop(function () {
987 var transition = $.support.transition && that.$element.hasClass('fade')
988
989 if (!that.$element.parent().length) {
990 that.$element.appendTo(that.$body) // don't move modals dom position
991 }
992
993 that.$element
994 .show()
995 .scrollTop(0)
996
997 that.adjustDialog()
998
999 if (transition) {
1000 that.$element[0].offsetWidth // force reflow
1001 }
1002
1003 that.$element.addClass('in')
1004
1005 that.enforceFocus()
1006
1007 var e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget })
1008
1009 transition ?
1010 that.$dialog // wait for modal to slide in
1011 .one('bsTransitionEnd', function () {
1012 that.$element.trigger('focus').trigger(e)
1013 })
1014 .emulateTransitionEnd(Modal.TRANSITION_DURATION) :
1015 that.$element.trigger('focus').trigger(e)
1016 })
1017 }
1018
1019 Modal.prototype.hide = function (e) {
1020 if (e) e.preventDefault()
1021
1022 e = $.Event('hide.bs.modal')
1023
1024 this.$element.trigger(e)
1025
1026 if (!this.isShown || e.isDefaultPrevented()) return
1027
1028 this.isShown = false
1029
1030 this.escape()
1031 this.resize()
1032
1033 $(document).off('focusin.bs.modal')
1034
1035 this.$element
1036 .removeClass('in')
1037 .off('click.dismiss.bs.modal')
1038 .off('mouseup.dismiss.bs.modal')
1039
1040 this.$dialog.off('mousedown.dismiss.bs.modal')
1041
1042 $.support.transition && this.$element.hasClass('fade') ?
1043 this.$element
1044 .one('bsTransitionEnd', $.proxy(this.hideModal, this))
1045 .emulateTransitionEnd(Modal.TRANSITION_DURATION) :
1046 this.hideModal()
1047 }
1048
1049 Modal.prototype.enforceFocus = function () {
1050 $(document)
1051 .off('focusin.bs.modal') // guard against infinite focus loop
1052 .on('focusin.bs.modal', $.proxy(function (e) {
1053 if (this.$element[0] !== e.target && !this.$element.has(e.target).length) {
1054 this.$element.trigger('focus')
1055 }
1056 }, this))
1057 }
1058
1059 Modal.prototype.escape = function () {
1060 if (this.isShown && this.options.keyboard) {
1061 this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) {
1062 e.which == 27 && this.hide()
1063 }, this))
1064 } else if (!this.isShown) {
1065 this.$element.off('keydown.dismiss.bs.modal')
1066 }
1067 }
1068
1069 Modal.prototype.resize = function () {
1070 if (this.isShown) {
1071 $(window).on('resize.bs.modal', $.proxy(this.handleUpdate, this))
1072 } else {
1073 $(window).off('resize.bs.modal')
1074 }
1075 }
1076
1077 Modal.prototype.hideModal = function () {
1078 var that = this
1079 this.$element.hide()
1080 this.backdrop(function () {
1081 that.$body.removeClass('modal-open')
1082 that.resetAdjustments()
1083 that.resetScrollbar()
1084 that.$element.trigger('hidden.bs.modal')
1085 })
1086 }
1087
1088 Modal.prototype.removeBackdrop = function () {
1089 this.$backdrop && this.$backdrop.remove()
1090 this.$backdrop = null
1091 }
1092
1093 Modal.prototype.backdrop = function (callback) {
1094 var that = this
1095 var animate = this.$element.hasClass('fade') ? 'fade' : ''
1096
1097 if (this.isShown && this.options.backdrop) {
1098 var doAnimate = $.support.transition && animate
1099
1100 this.$backdrop = $(document.createElement('div'))
1101 .addClass('modal-backdrop ' + animate)
1102 .appendTo(this.$body)
1103
1104 this.$element.on('click.dismiss.bs.modal', $.proxy(function (e) {
1105 if (this.ignoreBackdropClick) {
1106 this.ignoreBackdropClick = false
1107 return
1108 }
1109 if (e.target !== e.currentTarget) return
1110 this.options.backdrop == 'static'
1111 ? this.$element[0].focus()
1112 : this.hide()
1113 }, this))
1114
1115 if (doAnimate) this.$backdrop[0].offsetWidth // force reflow
1116
1117 this.$backdrop.addClass('in')
1118
1119 if (!callback) return
1120
1121 doAnimate ?
1122 this.$backdrop
1123 .one('bsTransitionEnd', callback)
1124 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
1125 callback()
1126
1127 } else if (!this.isShown && this.$backdrop) {
1128 this.$backdrop.removeClass('in')
1129
1130 var callbackRemove = function () {
1131 that.removeBackdrop()
1132 callback && callback()
1133 }
1134 $.support.transition && this.$element.hasClass('fade') ?
1135 this.$backdrop
1136 .one('bsTransitionEnd', callbackRemove)
1137 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
1138 callbackRemove()
1139
1140 } else if (callback) {
1141 callback()
1142 }
1143 }
1144
1145 // these following methods are used to handle overflowing modals
1146
1147 Modal.prototype.handleUpdate = function () {
1148 this.adjustDialog()
1149 }
1150
1151 Modal.prototype.adjustDialog = function () {
1152 var modalIsOverflowing = this.$element[0].scrollHeight > document.documentElement.clientHeight
1153
1154 this.$element.css({
1155 paddingLeft: !this.bodyIsOverflowing && modalIsOverflowing ? this.scrollbarWidth : '',
1156 paddingRight: this.bodyIsOverflowing && !modalIsOverflowing ? this.scrollbarWidth : ''
1157 })
1158 }
1159
1160 Modal.prototype.resetAdjustments = function () {
1161 this.$element.css({
1162 paddingLeft: '',
1163 paddingRight: ''
1164 })
1165 }
1166
1167 Modal.prototype.checkScrollbar = function () {
1168 var fullWindowWidth = window.innerWidth
1169 if (!fullWindowWidth) { // workaround for missing window.innerWidth in IE8
1170 var documentElementRect = document.documentElement.getBoundingClientRect()
1171 fullWindowWidth = documentElementRect.right - Math.abs(documentElementRect.left)
1172 }
1173 this.bodyIsOverflowing = document.body.clientWidth < fullWindowWidth
1174 this.scrollbarWidth = this.measureScrollbar()
1175 }
1176
1177 Modal.prototype.setScrollbar = function () {
1178 var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10)
1179 this.originalBodyPad = document.body.style.paddingRight || ''
1180 if (this.bodyIsOverflowing) this.$body.css('padding-right', bodyPad + this.scrollbarWidth)
1181 }
1182
1183 Modal.prototype.resetScrollbar = function () {
1184 this.$body.css('padding-right', this.originalBodyPad)
1185 }
1186
1187 Modal.prototype.measureScrollbar = function () { // thx walsh
1188 var scrollDiv = document.createElement('div')
1189 scrollDiv.className = 'modal-scrollbar-measure'
1190 this.$body.append(scrollDiv)
1191 var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth
1192 this.$body[0].removeChild(scrollDiv)
1193 return scrollbarWidth
1194 }
1195
1196
1197 // MODAL PLUGIN DEFINITION
1198 // =======================
1199
1200 function Plugin(option, _relatedTarget) {
1201 return this.each(function () {
1202 var $this = $(this)
1203 var data = $this.data('bs.modal')
1204 var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option)
1205
1206 if (!data) $this.data('bs.modal', (data = new Modal(this, options)))
1207 if (typeof option == 'string') data[option](_relatedTarget)
1208 else if (options.show) data.show(_relatedTarget)
1209 })
1210 }
1211
1212 var old = $.fn.modal
1213
1214 $.fn.modal = Plugin
1215 $.fn.modal.Constructor = Modal
1216
1217
1218 // MODAL NO CONFLICT
1219 // =================
1220
1221 $.fn.modal.noConflict = function () {
1222 $.fn.modal = old
1223 return this
1224 }
1225
1226
1227 // MODAL DATA-API
1228 // ==============
1229
1230 $(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) {
1231 var $this = $(this)
1232 var href = $this.attr('href')
1233 var $target = $($this.attr('data-target') || (href && href.replace(/.*(?=#[^\s]+$)/, ''))) // strip for ie7
1234 var option = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data())
1235
1236 if ($this.is('a')) e.preventDefault()
1237
1238 $target.one('show.bs.modal', function (showEvent) {
1239 if (showEvent.isDefaultPrevented()) return // only register focus restorer if modal will actually get shown
1240 $target.one('hidden.bs.modal', function () {
1241 $this.is(':visible') && $this.trigger('focus')
1242 })
1243 })
1244 Plugin.call($target, option, this)
1245 })
1246
1247}(jQuery);
1248
1249/* ========================================================================
1250 * Bootstrap: tooltip.js v3.3.6
1251 * http://getbootstrap.com/javascript/#tooltip
1252 * Inspired by the original jQuery.tipsy by Jason Frame
1253 * ========================================================================
1254 * Copyright 2011-2015 Twitter, Inc.
1255 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
1256 * ======================================================================== */
1257
1258
1259+function ($) {
1260 'use strict';
1261
1262 // TOOLTIP PUBLIC CLASS DEFINITION
1263 // ===============================
1264
1265 var Tooltip = function (element, options) {
1266 this.type = null
1267 this.options = null
1268 this.enabled = null
1269 this.timeout = null
1270 this.hoverState = null
1271 this.$element = null
1272 this.inState = null
1273
1274 this.init('tooltip', element, options)
1275 }
1276
1277 Tooltip.VERSION = '3.3.6'
1278
1279 Tooltip.TRANSITION_DURATION = 150
1280
1281 Tooltip.DEFAULTS = {
1282 animation: true,
1283 placement: 'top',
1284 selector: false,
1285 template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
1286 trigger: 'hover focus',
1287 title: '',
1288 delay: 0,
1289 html: false,
1290 container: false,
1291 viewport: {
1292 selector: 'body',
1293 padding: 0
1294 }
1295 }
1296
1297 Tooltip.prototype.init = function (type, element, options) {
1298 this.enabled = true
1299 this.type = type
1300 this.$element = $(element)
1301 this.options = this.getOptions(options)
1302 this.$viewport = this.options.viewport && $($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
1303 this.inState = { click: false, hover: false, focus: false }
1304
1305 if (this.$element[0] instanceof document.constructor && !this.options.selector) {
1306 throw new Error('`selector` option must be specified when initializing ' + this.type + ' on the window.document object!')
1307 }
1308
1309 var triggers = this.options.trigger.split(' ')
1310
1311 for (var i = triggers.length; i--;) {
1312 var trigger = triggers[i]
1313
1314 if (trigger == 'click') {
1315 this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
1316 } else if (trigger != 'manual') {
1317 var eventIn = trigger == 'hover' ? 'mouseenter' : 'focusin'
1318 var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout'
1319
1320 this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
1321 this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
1322 }
1323 }
1324
1325 this.options.selector ?
1326 (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
1327 this.fixTitle()
1328 }
1329
1330 Tooltip.prototype.getDefaults = function () {
1331 return Tooltip.DEFAULTS
1332 }
1333
1334 Tooltip.prototype.getOptions = function (options) {
1335 options = $.extend({}, this.getDefaults(), this.$element.data(), options)
1336
1337 if (options.delay && typeof options.delay == 'number') {
1338 options.delay = {
1339 show: options.delay,
1340 hide: options.delay
1341 }
1342 }
1343
1344 return options
1345 }
1346
1347 Tooltip.prototype.getDelegateOptions = function () {
1348 var options = {}
1349 var defaults = this.getDefaults()
1350
1351 this._options && $.each(this._options, function (key, value) {
1352 if (defaults[key] != value) options[key] = value
1353 })
1354
1355 return options
1356 }
1357
1358 Tooltip.prototype.enter = function (obj) {
1359 var self = obj instanceof this.constructor ?
1360 obj : $(obj.currentTarget).data('bs.' + this.type)
1361
1362 if (!self) {
1363 self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
1364 $(obj.currentTarget).data('bs.' + this.type, self)
1365 }
1366
1367 if (obj instanceof $.Event) {
1368 self.inState[obj.type == 'focusin' ? 'focus' : 'hover'] = true
1369 }
1370
1371 if (self.tip().hasClass('in') || self.hoverState == 'in') {
1372 self.hoverState = 'in'
1373 return
1374 }
1375
1376 clearTimeout(self.timeout)
1377
1378 self.hoverState = 'in'
1379
1380 if (!self.options.delay || !self.options.delay.show) return self.show()
1381
1382 self.timeout = setTimeout(function () {
1383 if (self.hoverState == 'in') self.show()
1384 }, self.options.delay.show)
1385 }
1386
1387 Tooltip.prototype.isInStateTrue = function () {
1388 for (var key in this.inState) {
1389 if (this.inState[key]) return true
1390 }
1391
1392 return false
1393 }
1394
1395 Tooltip.prototype.leave = function (obj) {
1396 var self = obj instanceof this.constructor ?
1397 obj : $(obj.currentTarget).data('bs.' + this.type)
1398
1399 if (!self) {
1400 self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
1401 $(obj.currentTarget).data('bs.' + this.type, self)
1402 }
1403
1404 if (obj instanceof $.Event) {
1405 self.inState[obj.type == 'focusout' ? 'focus' : 'hover'] = false
1406 }
1407
1408 if (self.isInStateTrue()) return
1409
1410 clearTimeout(self.timeout)
1411
1412 self.hoverState = 'out'
1413
1414 if (!self.options.delay || !self.options.delay.hide) return self.hide()
1415
1416 self.timeout = setTimeout(function () {
1417 if (self.hoverState == 'out') self.hide()
1418 }, self.options.delay.hide)
1419 }
1420
1421 Tooltip.prototype.show = function () {
1422 var e = $.Event('show.bs.' + this.type)
1423
1424 if (this.hasContent() && this.enabled) {
1425 this.$element.trigger(e)
1426
1427 var inDom = $.contains(this.$element[0].ownerDocument.documentElement, this.$element[0])
1428 if (e.isDefaultPrevented() || !inDom) return
1429 var that = this
1430
1431 var $tip = this.tip()
1432
1433 var tipId = this.getUID(this.type)
1434
1435 this.setContent()
1436 $tip.attr('id', tipId)
1437 this.$element.attr('aria-describedby', tipId)
1438
1439 if (this.options.animation) $tip.addClass('fade')
1440
1441 var placement = typeof this.options.placement == 'function' ?
1442 this.options.placement.call(this, $tip[0], this.$element[0]) :
1443 this.options.placement
1444
1445 var autoToken = /\s?auto?\s?/i
1446 var autoPlace = autoToken.test(placement)
1447 if (autoPlace) placement = placement.replace(autoToken, '') || 'top'
1448
1449 $tip
1450 .detach()
1451 .css({ top: 0, left: 0, display: 'block' })
1452 .addClass(placement)
1453 .data('bs.' + this.type, this)
1454
1455 this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
1456 this.$element.trigger('inserted.bs.' + this.type)
1457
1458 var pos = this.getPosition()
1459 var actualWidth = $tip[0].offsetWidth
1460 var actualHeight = $tip[0].offsetHeight
1461
1462 if (autoPlace) {
1463 var orgPlacement = placement
1464 var viewportDim = this.getPosition(this.$viewport)
1465
1466 placement = placement == 'bottom' && pos.bottom + actualHeight > viewportDim.bottom ? 'top' :
1467 placement == 'top' && pos.top - actualHeight < viewportDim.top ? 'bottom' :
1468 placement == 'right' && pos.right + actualWidth > viewportDim.width ? 'left' :
1469 placement == 'left' && pos.left - actualWidth < viewportDim.left ? 'right' :
1470 placement
1471
1472 $tip
1473 .removeClass(orgPlacement)
1474 .addClass(placement)
1475 }
1476
1477 var calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight)
1478
1479 this.applyPlacement(calculatedOffset, placement)
1480
1481 var complete = function () {
1482 var prevHoverState = that.hoverState
1483 that.$element.trigger('shown.bs.' + that.type)
1484 that.hoverState = null
1485
1486 if (prevHoverState == 'out') that.leave(that)
1487 }
1488
1489 $.support.transition && this.$tip.hasClass('fade') ?
1490 $tip
1491 .one('bsTransitionEnd', complete)
1492 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
1493 complete()
1494 }
1495 }
1496
1497 Tooltip.prototype.applyPlacement = function (offset, placement) {
1498 var $tip = this.tip()
1499 var width = $tip[0].offsetWidth
1500 var height = $tip[0].offsetHeight
1501
1502 // manually read margins because getBoundingClientRect includes difference
1503 var marginTop = parseInt($tip.css('margin-top'), 10)
1504 var marginLeft = parseInt($tip.css('margin-left'), 10)
1505
1506 // we must check for NaN for ie 8/9
1507 if (isNaN(marginTop)) marginTop = 0
1508 if (isNaN(marginLeft)) marginLeft = 0
1509
1510 offset.top += marginTop
1511 offset.left += marginLeft
1512
1513 // $.fn.offset doesn't round pixel values
1514 // so we use setOffset directly with our own function B-0
1515 $.offset.setOffset($tip[0], $.extend({
1516 using: function (props) {
1517 $tip.css({
1518 top: Math.round(props.top),
1519 left: Math.round(props.left)
1520 })
1521 }
1522 }, offset), 0)
1523
1524 $tip.addClass('in')
1525
1526 // check to see if placing tip in new offset caused the tip to resize itself
1527 var actualWidth = $tip[0].offsetWidth
1528 var actualHeight = $tip[0].offsetHeight
1529
1530 if (placement == 'top' && actualHeight != height) {
1531 offset.top = offset.top + height - actualHeight
1532 }
1533
1534 var delta = this.getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight)
1535
1536 if (delta.left) offset.left += delta.left
1537 else offset.top += delta.top
1538
1539 var isVertical = /top|bottom/.test(placement)
1540 var arrowDelta = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight
1541 var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight'
1542
1543 $tip.offset(offset)
1544 this.replaceArrow(arrowDelta, $tip[0][arrowOffsetPosition], isVertical)
1545 }
1546
1547 Tooltip.prototype.replaceArrow = function (delta, dimension, isVertical) {
1548 this.arrow()
1549 .css(isVertical ? 'left' : 'top', 50 * (1 - delta / dimension) + '%')
1550 .css(isVertical ? 'top' : 'left', '')
1551 }
1552
1553 Tooltip.prototype.setContent = function () {
1554 var $tip = this.tip()
1555 var title = this.getTitle()
1556
1557 $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
1558 $tip.removeClass('fade in top bottom left right')
1559 }
1560
1561 Tooltip.prototype.hide = function (callback) {
1562 var that = this
1563 var $tip = $(this.$tip)
1564 var e = $.Event('hide.bs.' + this.type)
1565
1566 function complete() {
1567 if (that.hoverState != 'in') $tip.detach()
1568 that.$element
1569 .removeAttr('aria-describedby')
1570 .trigger('hidden.bs.' + that.type)
1571 callback && callback()
1572 }
1573
1574 this.$element.trigger(e)
1575
1576 if (e.isDefaultPrevented()) return
1577
1578 $tip.removeClass('in')
1579
1580 $.support.transition && $tip.hasClass('fade') ?
1581 $tip
1582 .one('bsTransitionEnd', complete)
1583 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
1584 complete()
1585
1586 this.hoverState = null
1587
1588 return this
1589 }
1590
1591 Tooltip.prototype.fixTitle = function () {
1592 var $e = this.$element
1593 if ($e.attr('title') || typeof $e.attr('data-original-title') != 'string') {
1594 $e.attr('data-original-title', $e.attr('title') || '').attr('title', '')
1595 }
1596 }
1597
1598 Tooltip.prototype.hasContent = function () {
1599 return this.getTitle()
1600 }
1601
1602 Tooltip.prototype.getPosition = function ($element) {
1603 $element = $element || this.$element
1604
1605 var el = $element[0]
1606 var isBody = el.tagName == 'BODY'
1607
1608 var elRect = el.getBoundingClientRect()
1609 if (elRect.width == null) {
1610 // width and height are missing in IE8, so compute them manually; see https://github.com/twbs/bootstrap/issues/14093
1611 elRect = $.extend({}, elRect, { width: elRect.right - elRect.left, height: elRect.bottom - elRect.top })
1612 }
1613 var elOffset = isBody ? { top: 0, left: 0 } : $element.offset()
1614 var scroll = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : $element.scrollTop() }
1615 var outerDims = isBody ? { width: $(window).width(), height: $(window).height() } : null
1616
1617 return $.extend({}, elRect, scroll, outerDims, elOffset)
1618 }
1619
1620 Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) {
1621 return placement == 'bottom' ? { top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2 } :
1622 placement == 'top' ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } :
1623 placement == 'left' ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } :
1624 /* placement == 'right' */ { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width }
1625
1626 }
1627
1628 Tooltip.prototype.getViewportAdjustedDelta = function (placement, pos, actualWidth, actualHeight) {
1629 var delta = { top: 0, left: 0 }
1630 if (!this.$viewport) return delta
1631
1632 var viewportPadding = this.options.viewport && this.options.viewport.padding || 0
1633 var viewportDimensions = this.getPosition(this.$viewport)
1634
1635 if (/right|left/.test(placement)) {
1636 var topEdgeOffset = pos.top - viewportPadding - viewportDimensions.scroll
1637 var bottomEdgeOffset = pos.top + viewportPadding - viewportDimensions.scroll + actualHeight
1638 if (topEdgeOffset < viewportDimensions.top) { // top overflow
1639 delta.top = viewportDimensions.top - topEdgeOffset
1640 } else if (bottomEdgeOffset > viewportDimensions.top + viewportDimensions.height) { // bottom overflow
1641 delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset
1642 }
1643 } else {
1644 var leftEdgeOffset = pos.left - viewportPadding
1645 var rightEdgeOffset = pos.left + viewportPadding + actualWidth
1646 if (leftEdgeOffset < viewportDimensions.left) { // left overflow
1647 delta.left = viewportDimensions.left - leftEdgeOffset
1648 } else if (rightEdgeOffset > viewportDimensions.right) { // right overflow
1649 delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset
1650 }
1651 }
1652
1653 return delta
1654 }
1655
1656 Tooltip.prototype.getTitle = function () {
1657 var title
1658 var $e = this.$element
1659 var o = this.options
1660
1661 title = $e.attr('data-original-title')
1662 || (typeof o.title == 'function' ? o.title.call($e[0]) : o.title)
1663
1664 return title
1665 }
1666
1667 Tooltip.prototype.getUID = function (prefix) {
1668 do prefix += ~~(Math.random() * 1000000)
1669 while (document.getElementById(prefix))
1670 return prefix
1671 }
1672
1673 Tooltip.prototype.tip = function () {
1674 if (!this.$tip) {
1675 this.$tip = $(this.options.template)
1676 if (this.$tip.length != 1) {
1677 throw new Error(this.type + ' `template` option must consist of exactly 1 top-level element!')
1678 }
1679 }
1680 return this.$tip
1681 }
1682
1683 Tooltip.prototype.arrow = function () {
1684 return (this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow'))
1685 }
1686
1687 Tooltip.prototype.enable = function () {
1688 this.enabled = true
1689 }
1690
1691 Tooltip.prototype.disable = function () {
1692 this.enabled = false
1693 }
1694
1695 Tooltip.prototype.toggleEnabled = function () {
1696 this.enabled = !this.enabled
1697 }
1698
1699 Tooltip.prototype.toggle = function (e) {
1700 var self = this
1701 if (e) {
1702 self = $(e.currentTarget).data('bs.' + this.type)
1703 if (!self) {
1704 self = new this.constructor(e.currentTarget, this.getDelegateOptions())
1705 $(e.currentTarget).data('bs.' + this.type, self)
1706 }
1707 }
1708
1709 if (e) {
1710 self.inState.click = !self.inState.click
1711 if (self.isInStateTrue()) self.enter(self)
1712 else self.leave(self)
1713 } else {
1714 self.tip().hasClass('in') ? self.leave(self) : self.enter(self)
1715 }
1716 }
1717
1718 Tooltip.prototype.destroy = function () {
1719 var that = this
1720 clearTimeout(this.timeout)
1721 this.hide(function () {
1722 that.$element.off('.' + that.type).removeData('bs.' + that.type)
1723 if (that.$tip) {
1724 that.$tip.detach()
1725 }
1726 that.$tip = null
1727 that.$arrow = null
1728 that.$viewport = null
1729 })
1730 }
1731
1732
1733 // TOOLTIP PLUGIN DEFINITION
1734 // =========================
1735
1736 function Plugin(option) {
1737 return this.each(function () {
1738 var $this = $(this)
1739 var data = $this.data('bs.tooltip')
1740 var options = typeof option == 'object' && option
1741
1742 if (!data && /destroy|hide/.test(option)) return
1743 if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options)))
1744 if (typeof option == 'string') data[option]()
1745 })
1746 }
1747
1748 var old = $.fn.tooltip
1749
1750 $.fn.tooltip = Plugin
1751 $.fn.tooltip.Constructor = Tooltip
1752
1753
1754 // TOOLTIP NO CONFLICT
1755 // ===================
1756
1757 $.fn.tooltip.noConflict = function () {
1758 $.fn.tooltip = old
1759 return this
1760 }
1761
1762}(jQuery);
1763
1764/* ========================================================================
1765 * Bootstrap: popover.js v3.3.6
1766 * http://getbootstrap.com/javascript/#popovers
1767 * ========================================================================
1768 * Copyright 2011-2015 Twitter, Inc.
1769 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
1770 * ======================================================================== */
1771
1772
1773+function ($) {
1774 'use strict';
1775
1776 // POPOVER PUBLIC CLASS DEFINITION
1777 // ===============================
1778
1779 var Popover = function (element, options) {
1780 this.init('popover', element, options)
1781 }
1782
1783 if (!$.fn.tooltip) throw new Error('Popover requires tooltip.js')
1784
1785 Popover.VERSION = '3.3.6'
1786
1787 Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, {
1788 placement: 'right',
1789 trigger: 'click',
1790 content: '',
1791 template: '<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
1792 })
1793
1794
1795 // NOTE: POPOVER EXTENDS tooltip.js
1796 // ================================
1797
1798 Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype)
1799
1800 Popover.prototype.constructor = Popover
1801
1802 Popover.prototype.getDefaults = function () {
1803 return Popover.DEFAULTS
1804 }
1805
1806 Popover.prototype.setContent = function () {
1807 var $tip = this.tip()
1808 var title = this.getTitle()
1809 var content = this.getContent()
1810
1811 $tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
1812 $tip.find('.popover-content').children().detach().end()[ // we use append for html objects to maintain js events
1813 this.options.html ? (typeof content == 'string' ? 'html' : 'append') : 'text'
1814 ](content)
1815
1816 $tip.removeClass('fade top bottom left right in')
1817
1818 // IE8 doesn't accept hiding via the `:empty` pseudo selector, we have to do
1819 // this manually by checking the contents.
1820 if (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide()
1821 }
1822
1823 Popover.prototype.hasContent = function () {
1824 return this.getTitle() || this.getContent()
1825 }
1826
1827 Popover.prototype.getContent = function () {
1828 var $e = this.$element
1829 var o = this.options
1830
1831 return $e.attr('data-content')
1832 || (typeof o.content == 'function' ?
1833 o.content.call($e[0]) :
1834 o.content)
1835 }
1836
1837 Popover.prototype.arrow = function () {
1838 return (this.$arrow = this.$arrow || this.tip().find('.arrow'))
1839 }
1840
1841
1842 // POPOVER PLUGIN DEFINITION
1843 // =========================
1844
1845 function Plugin(option) {
1846 return this.each(function () {
1847 var $this = $(this)
1848 var data = $this.data('bs.popover')
1849 var options = typeof option == 'object' && option
1850
1851 if (!data && /destroy|hide/.test(option)) return
1852 if (!data) $this.data('bs.popover', (data = new Popover(this, options)))
1853 if (typeof option == 'string') data[option]()
1854 })
1855 }
1856
1857 var old = $.fn.popover
1858
1859 $.fn.popover = Plugin
1860 $.fn.popover.Constructor = Popover
1861
1862
1863 // POPOVER NO CONFLICT
1864 // ===================
1865
1866 $.fn.popover.noConflict = function () {
1867 $.fn.popover = old
1868 return this
1869 }
1870
1871}(jQuery);
1872
1873/* ========================================================================
1874 * Bootstrap: scrollspy.js v3.3.6
1875 * http://getbootstrap.com/javascript/#scrollspy
1876 * ========================================================================
1877 * Copyright 2011-2015 Twitter, Inc.
1878 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
1879 * ======================================================================== */
1880
1881
1882+function ($) {
1883 'use strict';
1884
1885 // SCROLLSPY CLASS DEFINITION
1886 // ==========================
1887
1888 function ScrollSpy(element, options) {
1889 this.$body = $(document.body)
1890 this.$scrollElement = $(element).is(document.body) ? $(window) : $(element)
1891 this.options = $.extend({}, ScrollSpy.DEFAULTS, options)
1892 this.selector = (this.options.target || '') + ' .nav li > a'
1893 this.offsets = []
1894 this.targets = []
1895 this.activeTarget = null
1896 this.scrollHeight = 0
1897
1898 this.$scrollElement.on('scroll.bs.scrollspy', $.proxy(this.process, this))
1899 this.refresh()
1900 this.process()
1901 }
1902
1903 ScrollSpy.VERSION = '3.3.6'
1904
1905 ScrollSpy.DEFAULTS = {
1906 offset: 10
1907 }
1908
1909 ScrollSpy.prototype.getScrollHeight = function () {
1910 return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight)
1911 }
1912
1913 ScrollSpy.prototype.refresh = function () {
1914 var that = this
1915 var offsetMethod = 'offset'
1916 var offsetBase = 0
1917
1918 this.offsets = []
1919 this.targets = []
1920 this.scrollHeight = this.getScrollHeight()
1921
1922 if (!$.isWindow(this.$scrollElement[0])) {
1923 offsetMethod = 'position'
1924 offsetBase = this.$scrollElement.scrollTop()
1925 }
1926
1927 this.$body
1928 .find(this.selector)
1929 .map(function () {
1930 var $el = $(this)
1931 var href = $el.data('target') || $el.attr('href')
1932 var $href = /^#./.test(href) && $(href)
1933
1934 return ($href
1935 && $href.length
1936 && $href.is(':visible')
1937 && [[$href[offsetMethod]().top + offsetBase, href]]) || null
1938 })
1939 .sort(function (a, b) { return a[0] - b[0] })
1940 .each(function () {
1941 that.offsets.push(this[0])
1942 that.targets.push(this[1])
1943 })
1944 }
1945
1946 ScrollSpy.prototype.process = function () {
1947 var scrollTop = this.$scrollElement.scrollTop() + this.options.offset
1948 var scrollHeight = this.getScrollHeight()
1949 var maxScroll = this.options.offset + scrollHeight - this.$scrollElement.height()
1950 var offsets = this.offsets
1951 var targets = this.targets
1952 var activeTarget = this.activeTarget
1953 var i
1954
1955 if (this.scrollHeight != scrollHeight) {
1956 this.refresh()
1957 }
1958
1959 if (scrollTop >= maxScroll) {
1960 return activeTarget != (i = targets[targets.length - 1]) && this.activate(i)
1961 }
1962
1963 if (activeTarget && scrollTop < offsets[0]) {
1964 this.activeTarget = null
1965 return this.clear()
1966 }
1967
1968 for (i = offsets.length; i--;) {
1969 activeTarget != targets[i]
1970 && scrollTop >= offsets[i]
1971 && (offsets[i + 1] === undefined || scrollTop < offsets[i + 1])
1972 && this.activate(targets[i])
1973 }
1974 }
1975
1976 ScrollSpy.prototype.activate = function (target) {
1977 this.activeTarget = target
1978
1979 this.clear()
1980
1981 var selector = this.selector +
1982 '[data-target="' + target + '"],' +
1983 this.selector + '[href="' + target + '"]'
1984
1985 var active = $(selector)
1986 .parents('li')
1987 .addClass('active')
1988
1989 if (active.parent('.dropdown-menu').length) {
1990 active = active
1991 .closest('li.dropdown')
1992 .addClass('active')
1993 }
1994
1995 active.trigger('activate.bs.scrollspy')
1996 }
1997
1998 ScrollSpy.prototype.clear = function () {
1999 $(this.selector)
2000 .parentsUntil(this.options.target, '.active')
2001 .removeClass('active')
2002 }
2003
2004
2005 // SCROLLSPY PLUGIN DEFINITION
2006 // ===========================
2007
2008 function Plugin(option) {
2009 return this.each(function () {
2010 var $this = $(this)
2011 var data = $this.data('bs.scrollspy')
2012 var options = typeof option == 'object' && option
2013
2014 if (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options)))
2015 if (typeof option == 'string') data[option]()
2016 })
2017 }
2018
2019 var old = $.fn.scrollspy
2020
2021 $.fn.scrollspy = Plugin
2022 $.fn.scrollspy.Constructor = ScrollSpy
2023
2024
2025 // SCROLLSPY NO CONFLICT
2026 // =====================
2027
2028 $.fn.scrollspy.noConflict = function () {
2029 $.fn.scrollspy = old
2030 return this
2031 }
2032
2033
2034 // SCROLLSPY DATA-API
2035 // ==================
2036
2037 $(window).on('load.bs.scrollspy.data-api', function () {
2038 $('[data-spy="scroll"]').each(function () {
2039 var $spy = $(this)
2040 Plugin.call($spy, $spy.data())
2041 })
2042 })
2043
2044}(jQuery);
2045
2046/* ========================================================================
2047 * Bootstrap: tab.js v3.3.6
2048 * http://getbootstrap.com/javascript/#tabs
2049 * ========================================================================
2050 * Copyright 2011-2015 Twitter, Inc.
2051 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
2052 * ======================================================================== */
2053
2054
2055+function ($) {
2056 'use strict';
2057
2058 // TAB CLASS DEFINITION
2059 // ====================
2060
2061 var Tab = function (element) {
2062 // jscs:disable requireDollarBeforejQueryAssignment
2063 this.element = $(element)
2064 // jscs:enable requireDollarBeforejQueryAssignment
2065 }
2066
2067 Tab.VERSION = '3.3.6'
2068
2069 Tab.TRANSITION_DURATION = 150
2070
2071 Tab.prototype.show = function () {
2072 var $this = this.element
2073 var $ul = $this.closest('ul:not(.dropdown-menu)')
2074 var selector = $this.data('target')
2075
2076 if (!selector) {
2077 selector = $this.attr('href')
2078 selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
2079 }
2080
2081 if ($this.parent('li').hasClass('active')) return
2082
2083 var $previous = $ul.find('.active:last a')
2084 var hideEvent = $.Event('hide.bs.tab', {
2085 relatedTarget: $this[0]
2086 })
2087 var showEvent = $.Event('show.bs.tab', {
2088 relatedTarget: $previous[0]
2089 })
2090
2091 $previous.trigger(hideEvent)
2092 $this.trigger(showEvent)
2093
2094 if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return
2095
2096 var $target = $(selector)
2097
2098 this.activate($this.closest('li'), $ul)
2099 this.activate($target, $target.parent(), function () {
2100 $previous.trigger({
2101 type: 'hidden.bs.tab',
2102 relatedTarget: $this[0]
2103 })
2104 $this.trigger({
2105 type: 'shown.bs.tab',
2106 relatedTarget: $previous[0]
2107 })
2108 })
2109 }
2110
2111 Tab.prototype.activate = function (element, container, callback) {
2112 var $active = container.find('> .active')
2113 var transition = callback
2114 && $.support.transition
2115 && ($active.length && $active.hasClass('fade') || !!container.find('> .fade').length)
2116
2117 function next() {
2118 $active
2119 .removeClass('active')
2120 .find('> .dropdown-menu > .active')
2121 .removeClass('active')
2122 .end()
2123 .find('[data-toggle="tab"]')
2124 .attr('aria-expanded', false)
2125
2126 element
2127 .addClass('active')
2128 .find('[data-toggle="tab"]')
2129 .attr('aria-expanded', true)
2130
2131 if (transition) {
2132 element[0].offsetWidth // reflow for transition
2133 element.addClass('in')
2134 } else {
2135 element.removeClass('fade')
2136 }
2137
2138 if (element.parent('.dropdown-menu').length) {
2139 element
2140 .closest('li.dropdown')
2141 .addClass('active')
2142 .end()
2143 .find('[data-toggle="tab"]')
2144 .attr('aria-expanded', true)
2145 }
2146
2147 callback && callback()
2148 }
2149
2150 $active.length && transition ?
2151 $active
2152 .one('bsTransitionEnd', next)
2153 .emulateTransitionEnd(Tab.TRANSITION_DURATION) :
2154 next()
2155
2156 $active.removeClass('in')
2157 }
2158
2159
2160 // TAB PLUGIN DEFINITION
2161 // =====================
2162
2163 function Plugin(option) {
2164 return this.each(function () {
2165 var $this = $(this)
2166 var data = $this.data('bs.tab')
2167
2168 if (!data) $this.data('bs.tab', (data = new Tab(this)))
2169 if (typeof option == 'string') data[option]()
2170 })
2171 }
2172
2173 var old = $.fn.tab
2174
2175 $.fn.tab = Plugin
2176 $.fn.tab.Constructor = Tab
2177
2178
2179 // TAB NO CONFLICT
2180 // ===============
2181
2182 $.fn.tab.noConflict = function () {
2183 $.fn.tab = old
2184 return this
2185 }
2186
2187
2188 // TAB DATA-API
2189 // ============
2190
2191 var clickHandler = function (e) {
2192 e.preventDefault()
2193 Plugin.call($(this), 'show')
2194 }
2195
2196 $(document)
2197 .on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler)
2198 .on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler)
2199
2200}(jQuery);
2201
2202/* ========================================================================
2203 * Bootstrap: affix.js v3.3.6
2204 * http://getbootstrap.com/javascript/#affix
2205 * ========================================================================
2206 * Copyright 2011-2015 Twitter, Inc.
2207 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
2208 * ======================================================================== */
2209
2210
2211+function ($) {
2212 'use strict';
2213
2214 // AFFIX CLASS DEFINITION
2215 // ======================
2216
2217 var Affix = function (element, options) {
2218 this.options = $.extend({}, Affix.DEFAULTS, options)
2219
2220 this.$target = $(this.options.target)
2221 .on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
2222 .on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this))
2223
2224 this.$element = $(element)
2225 this.affixed = null
2226 this.unpin = null
2227 this.pinnedOffset = null
2228
2229 this.checkPosition()
2230 }
2231
2232 Affix.VERSION = '3.3.6'
2233
2234 Affix.RESET = 'affix affix-top affix-bottom'
2235
2236 Affix.DEFAULTS = {
2237 offset: 0,
2238 target: window
2239 }
2240
2241 Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) {
2242 var scrollTop = this.$target.scrollTop()
2243 var position = this.$element.offset()
2244 var targetHeight = this.$target.height()
2245
2246 if (offsetTop != null && this.affixed == 'top') return scrollTop < offsetTop ? 'top' : false
2247
2248 if (this.affixed == 'bottom') {
2249 if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom'
2250 return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom'
2251 }
2252
2253 var initializing = this.affixed == null
2254 var colliderTop = initializing ? scrollTop : position.top
2255 var colliderHeight = initializing ? targetHeight : height
2256
2257 if (offsetTop != null && scrollTop <= offsetTop) return 'top'
2258 if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom'
2259
2260 return false
2261 }
2262
2263 Affix.prototype.getPinnedOffset = function () {
2264 if (this.pinnedOffset) return this.pinnedOffset
2265 this.$element.removeClass(Affix.RESET).addClass('affix')
2266 var scrollTop = this.$target.scrollTop()
2267 var position = this.$element.offset()
2268 return (this.pinnedOffset = position.top - scrollTop)
2269 }
2270
2271 Affix.prototype.checkPositionWithEventLoop = function () {
2272 setTimeout($.proxy(this.checkPosition, this), 1)
2273 }
2274
2275 Affix.prototype.checkPosition = function () {
2276 if (!this.$element.is(':visible')) return
2277
2278 var height = this.$element.height()
2279 var offset = this.options.offset
2280 var offsetTop = offset.top
2281 var offsetBottom = offset.bottom
2282 var scrollHeight = Math.max($(document).height(), $(document.body).height())
2283
2284 if (typeof offset != 'object') offsetBottom = offsetTop = offset
2285 if (typeof offsetTop == 'function') offsetTop = offset.top(this.$element)
2286 if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element)
2287
2288 var affix = this.getState(scrollHeight, height, offsetTop, offsetBottom)
2289
2290 if (this.affixed != affix) {
2291 if (this.unpin != null) this.$element.css('top', '')
2292
2293 var affixType = 'affix' + (affix ? '-' + affix : '')
2294 var e = $.Event(affixType + '.bs.affix')
2295
2296 this.$element.trigger(e)
2297
2298 if (e.isDefaultPrevented()) return
2299
2300 this.affixed = affix
2301 this.unpin = affix == 'bottom' ? this.getPinnedOffset() : null
2302
2303 this.$element
2304 .removeClass(Affix.RESET)
2305 .addClass(affixType)
2306 .trigger(affixType.replace('affix', 'affixed') + '.bs.affix')
2307 }
2308
2309 if (affix == 'bottom') {
2310 this.$element.offset({
2311 top: scrollHeight - height - offsetBottom
2312 })
2313 }
2314 }
2315
2316
2317 // AFFIX PLUGIN DEFINITION
2318 // =======================
2319
2320 function Plugin(option) {
2321 return this.each(function () {
2322 var $this = $(this)
2323 var data = $this.data('bs.affix')
2324 var options = typeof option == 'object' && option
2325
2326 if (!data) $this.data('bs.affix', (data = new Affix(this, options)))
2327 if (typeof option == 'string') data[option]()
2328 })
2329 }
2330
2331 var old = $.fn.affix
2332
2333 $.fn.affix = Plugin
2334 $.fn.affix.Constructor = Affix
2335
2336
2337 // AFFIX NO CONFLICT
2338 // =================
2339
2340 $.fn.affix.noConflict = function () {
2341 $.fn.affix = old
2342 return this
2343 }
2344
2345
2346 // AFFIX DATA-API
2347 // ==============
2348
2349 $(window).on('load', function () {
2350 $('[data-spy="affix"]').each(function () {
2351 var $spy = $(this)
2352 var data = $spy.data()
2353
2354 data.offset = data.offset || {}
2355
2356 if (data.offsetBottom != null) data.offset.bottom = data.offsetBottom
2357 if (data.offsetTop != null) data.offset.top = data.offsetTop
2358
2359 Plugin.call($spy, data)
2360 })
2361 })
2362
2363}(jQuery);
diff --git a/frontend/js/bootstrap.min.js b/frontend/js/bootstrap.min.js
new file mode 100644
index 0000000..e79c065
--- /dev/null
+++ b/frontend/js/bootstrap.min.js
@@ -0,0 +1,7 @@
1/*!
2 * Bootstrap v3.3.6 (http://getbootstrap.com)
3 * Copyright 2011-2015 Twitter, Inc.
4 * Licensed under the MIT license
5 */
6if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1||b[0]>2)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.6",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a(f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.6",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")?(c.prop("checked")&&(a=!1),b.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==c.prop("type")&&(c.prop("checked")!==this.$element.hasClass("active")&&(a=!1),this.$element.toggleClass("active")),c.prop("checked",this.$element.hasClass("active")),a&&c.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),a(c.target).is('input[type="radio"]')||a(c.target).is('input[type="checkbox"]')||c.preventDefault()}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c=this.getItemIndex(b),d="prev"==a&&0===c||"next"==a&&c==this.$items.length-1;if(d&&!this.options.wrap)return b;var e="prev"==a?-1:1,f=(c+e)%this.$items.length;return this.$items.eq(f)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));return a>this.$items.length-1||0>a?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i=this;if(f.hasClass("active"))return this.sliding=!1;var j=f[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:h});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(f)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(m)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&/show|hide/.test(b)&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a('[data-toggle="collapse"][href="#'+b.id+'"],[data-toggle="collapse"][data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.6",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":e.data();c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function c(c){c&&3===c.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=b(d),f={relatedTarget:this};e.hasClass("open")&&(c&&"click"==c.type&&/input|textarea/i.test(c.target.tagName)&&a.contains(e[0],c.target)||(e.trigger(c=a.Event("hide.bs.dropdown",f)),c.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger(a.Event("hidden.bs.dropdown",f)))))}))}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.6",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=b(e),g=f.hasClass("open");if(c(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",c);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger(a.Event("shown.bs.dropdown",h))}return!1}},g.prototype.keydown=function(c){if(/(38|40|27|32)/.test(c.which)&&!/input|textarea/i.test(c.target.tagName)){var d=a(this);if(c.preventDefault(),c.stopPropagation(),!d.is(".disabled, :disabled")){var e=b(d),g=e.hasClass("open");if(!g&&27!=c.which||g&&27==c.which)return 27==c.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.disabled):visible a",i=e.find(".dropdown-menu"+h);if(i.length){var j=i.index(c.target);38==c.which&&j>0&&j--,40==c.which&&j<i.length-1&&j++,~j||(j=0),i.eq(j).trigger("focus")}}}};var h=a.fn.dropdown;a.fn.dropdown=d,a.fn.dropdown.Constructor=g,a.fn.dropdown.noConflict=function(){return a.fn.dropdown=h,this},a(document).on("click.bs.dropdown.data-api",c).on("click.bs.dropdown.data-api",".dropdown form",function(a){a.stopPropagation()}).on("click.bs.dropdown.data-api",f,g.prototype.toggle).on("keydown.bs.dropdown.data-api",f,g.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",g.prototype.keydown)}(jQuery),+function(a){"use strict";function b(b,d){return this.each(function(){var e=a(this),f=e.data("bs.modal"),g=a.extend({},c.DEFAULTS,e.data(),"object"==typeof b&&b);f||e.data("bs.modal",f=new c(this,g)),"string"==typeof b?f[b](d):g.show&&f.show(d)})}var c=function(b,c){this.options=c,this.$body=a(document.body),this.$element=a(b),this.$dialog=this.$element.find(".modal-dialog"),this.$backdrop=null,this.isShown=null,this.originalBodyPad=null,this.scrollbarWidth=0,this.ignoreBackdropClick=!1,this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,a.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=300,c.BACKDROP_TRANSITION_DURATION=150,c.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},c.prototype.toggle=function(a){return this.isShown?this.hide():this.show(a)},c.prototype.show=function(b){var d=this,e=a.Event("show.bs.modal",{relatedTarget:b});this.$element.trigger(e),this.isShown||e.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',a.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){d.$element.one("mouseup.dismiss.bs.modal",function(b){a(b.target).is(d.$element)&&(d.ignoreBackdropClick=!0)})}),this.backdrop(function(){var e=a.support.transition&&d.$element.hasClass("fade");d.$element.parent().length||d.$element.appendTo(d.$body),d.$element.show().scrollTop(0),d.adjustDialog(),e&&d.$element[0].offsetWidth,d.$element.addClass("in"),d.enforceFocus();var f=a.Event("shown.bs.modal",{relatedTarget:b});e?d.$dialog.one("bsTransitionEnd",function(){d.$element.trigger("focus").trigger(f)}).emulateTransitionEnd(c.TRANSITION_DURATION):d.$element.trigger("focus").trigger(f)}))},c.prototype.hide=function(b){b&&b.preventDefault(),b=a.Event("hide.bs.modal"),this.$element.trigger(b),this.isShown&&!b.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),a(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),a.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",a.proxy(this.hideModal,this)).emulateTransitionEnd(c.TRANSITION_DURATION):this.hideModal())},c.prototype.enforceFocus=function(){a(document).off("focusin.bs.modal").on("focusin.bs.modal",a.proxy(function(a){this.$element[0]===a.target||this.$element.has(a.target).length||this.$element.trigger("focus")},this))},c.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",a.proxy(function(a){27==a.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},c.prototype.resize=function(){this.isShown?a(window).on("resize.bs.modal",a.proxy(this.handleUpdate,this)):a(window).off("resize.bs.modal")},c.prototype.hideModal=function(){var a=this;this.$element.hide(),this.backdrop(function(){a.$body.removeClass("modal-open"),a.resetAdjustments(),a.resetScrollbar(),a.$element.trigger("hidden.bs.modal")})},c.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},c.prototype.backdrop=function(b){var d=this,e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var f=a.support.transition&&e;if(this.$backdrop=a(document.createElement("div")).addClass("modal-backdrop "+e).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){return this.ignoreBackdropClick?void(this.ignoreBackdropClick=!1):void(a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide()))},this)),f&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;f?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var g=function(){d.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",g).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):g()}else b&&b()},c.prototype.handleUpdate=function(){this.adjustDialog()},c.prototype.adjustDialog=function(){var a=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){var a=window.innerWidth;if(!a){var b=document.documentElement.getBoundingClientRect();a=b.right-Math.abs(b.left)}this.bodyIsOverflowing=document.body.clientWidth<a,this.scrollbarWidth=this.measureScrollbar()},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"",this.bodyIsOverflowing&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad)},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",a,b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){if(this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(a.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusin"==b.type?"focus":"hover"]=!0),c.tip().hasClass("in")||"in"==c.hoverState?void(c.hoverState="in"):(clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.isInStateTrue=function(){for(var a in this.inState)if(this.inState[a])return!0;return!1},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusout"==b.type?"focus":"hover"]=!1),c.isInStateTrue()?void 0:(clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide())},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.getPosition(this.$viewport);h="bottom"==h&&k.bottom+m>o.bottom?"top":"top"==h&&k.top-m<o.top?"bottom":"right"==h&&k.right+l>o.width?"left":"left"==h&&k.left-l<o.left?"right":h,f.removeClass(n).addClass(h)}var p=this.getCalculatedOffset(h,k,l,m);this.applyPlacement(p,h);var q=function(){var a=e.hoverState;e.$element.trigger("shown.bs."+e.type),e.hoverState=null,"out"==a&&e.leave(e)};a.support.transition&&this.$tip.hasClass("fade")?f.one("bsTransitionEnd",q).emulateTransitionEnd(c.TRANSITION_DURATION):q()}},c.prototype.applyPlacement=function(b,c){var d=this.tip(),e=d[0].offsetWidth,f=d[0].offsetHeight,g=parseInt(d.css("margin-top"),10),h=parseInt(d.css("margin-left"),10);isNaN(g)&&(g=0),isNaN(h)&&(h=0),b.top+=g,b.left+=h,a.offset.setOffset(d[0],a.extend({using:function(a){d.css({top:Math.round(a.top),left:Math.round(a.left)})}},b),0),d.addClass("in");var i=d[0].offsetWidth,j=d[0].offsetHeight;"top"==c&&j!=f&&(b.top=b.top+f-j);var k=this.getViewportAdjustedDelta(c,b,i,j);k.left?b.left+=k.left:b.top+=k.top;var l=/top|bottom/.test(c),m=l?2*k.left-e+i:2*k.top-f+j,n=l?"offsetWidth":"offsetHeight";d.offset(b),this.replaceArrow(m,d[0][n],l)},c.prototype.replaceArrow=function(a,b,c){this.arrow().css(c?"left":"top",50*(1-a/b)+"%").css(c?"top":"left","")},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},c.prototype.hide=function(b){function d(){"in"!=e.hoverState&&f.detach(),e.$element.removeAttr("aria-describedby").trigger("hidden.bs."+e.type),b&&b()}var e=this,f=a(this.$tip),g=a.Event("hide.bs."+this.type);return this.$element.trigger(g),g.isDefaultPrevented()?void 0:(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one("bsTransitionEnd",d).emulateTransitionEnd(c.TRANSITION_DURATION):d(),this.hoverState=null,this)},c.prototype.fixTitle=function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},c.prototype.hasContent=function(){return this.getTitle()},c.prototype.getPosition=function(b){b=b||this.$element;var c=b[0],d="BODY"==c.tagName,e=c.getBoundingClientRect();null==e.width&&(e=a.extend({},e,{width:e.right-e.left,height:e.bottom-e.top}));var f=d?{top:0,left:0}:b.offset(),g={scroll:d?document.documentElement.scrollTop||document.body.scrollTop:b.scrollTop()},h=d?{width:a(window).width(),height:a(window).height()}:null;return a.extend({},e,g,h,f)},c.prototype.getCalculatedOffset=function(a,b,c,d){return"bottom"==a?{top:b.top+b.height,left:b.left+b.width/2-c/2}:"top"==a?{top:b.top-d,left:b.left+b.width/2-c/2}:"left"==a?{top:b.top+b.height/2-d/2,left:b.left-c}:{top:b.top+b.height/2-d/2,left:b.left+b.width}},c.prototype.getViewportAdjustedDelta=function(a,b,c,d){var e={top:0,left:0};if(!this.$viewport)return e;var f=this.options.viewport&&this.options.viewport.padding||0,g=this.getPosition(this.$viewport);if(/right|left/.test(a)){var h=b.top-f-g.scroll,i=b.top+f-g.scroll+d;h<g.top?e.top=g.top-h:i>g.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;j<g.left?e.left=g.left-j:k>g.right&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){if(!this.$tip&&(this.$tip=a(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),b?(c.inState.click=!c.inState.click,c.isInStateTrue()?c.enter(c):c.leave(c)):c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type),a.$tip&&a.$tip.detach(),a.$tip=null,a.$arrow=null,a.$viewport=null})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.6",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){this.$body=a(document.body),this.$scrollElement=a(a(c).is(document.body)?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",a.proxy(this.process,this)),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.6",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b=this,c="offset",d=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),a.isWindow(this.$scrollElement[0])||(c="position",d=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var b=a(this),e=b.data("target")||b.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[c]().top+d,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){b.offsets.push(this[0]),b.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<e[0])return this.activeTarget=null,this.clear();for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(void 0===e[a+1]||b<e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,this.clear();var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");
7d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")},b.prototype.clear=function(){a(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a"),f=a.Event("hide.bs.tab",{relatedTarget:b[0]}),g=a.Event("show.bs.tab",{relatedTarget:e[0]});if(e.trigger(f),b.trigger(g),!g.isDefaultPrevented()&&!f.isDefaultPrevented()){var h=a(d);this.activate(b.closest("li"),c),this.activate(h,h.parent(),function(){e.trigger({type:"hidden.bs.tab",relatedTarget:b[0]}),b.trigger({type:"shown.bs.tab",relatedTarget:e[0]})})}}},c.prototype.activate=function(b,d,e){function f(){g.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu").length&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.6",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return c>e?"top":!1;if("bottom"==this.affixed)return null!=c?e+this.unpin<=f.top?!1:"bottom":a-d>=e+g?!1:"bottom";var h=null==this.affixed,i=h?e:f.top,j=h?g:b;return null!=c&&c>=e?"top":null!=d&&i+j>=a-d?"bottom":!1},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=Math.max(a(document).height(),a(document.body).height());"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery); \ No newline at end of file
diff --git a/frontend/js/filesize.min.js b/frontend/js/filesize.min.js
new file mode 100644
index 0000000..9e0d3df
--- /dev/null
+++ b/frontend/js/filesize.min.js
@@ -0,0 +1,6 @@
1/*
2 2016
3 @version 3.2.1
4 */
5"use strict";!function(a){function b(a){var b=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],e=[],f=0,g=void 0,h=void 0,i=void 0,j=void 0,k=void 0,l=void 0,m=void 0,n=void 0,o=void 0,p=void 0,q=void 0;if(isNaN(a))throw new Error("Invalid arguments");return i=b.bits===!0,o=b.unix===!0,h=b.base||2,n=void 0!==b.round?b.round:o?1:2,p=void 0!==b.spacer?b.spacer:o?"":" ",q=b.symbols||b.suffixes||{},m=b.output||"string",g=void 0!==b.exponent?b.exponent:-1,l=Number(a),k=0>l,j=h>2?1e3:1024,k&&(l=-l),0===l?(e[0]=0,e[1]=o?"":i?"b":"B"):((-1===g||isNaN(g))&&(g=Math.floor(Math.log(l)/Math.log(j)),0>g&&(g=0)),g>8&&(g=8),f=2===h?l/Math.pow(2,10*g):l/Math.pow(1e3,g),i&&(f=8*f,f>j&&8>g&&(f/=j,g++)),e[0]=Number(f.toFixed(g>0?n:0)),e[1]=10===h&&1===g?i?"kb":"kB":d[i?"bits":"bytes"][g],o&&(e[1]=e[1].charAt(0),c.test(e[1])&&(e[0]=Math.floor(e[0]),e[1]=""))),k&&(e[0]=-e[0]),e[1]=q[e[1]]||e[1],"array"===m?e:"exponent"===m?g:"object"===m?{value:e[0],suffix:e[1],symbol:e[1]}:e.join(p)}var c=/^(b|B)$/,d={bits:["b","Kb","Mb","Gb","Tb","Pb","Eb","Zb","Yb"],bytes:["B","KB","MB","GB","TB","PB","EB","ZB","YB"]};"undefined"!=typeof exports?module.exports=b:"function"==typeof define&&define.amd?define(function(){return b}):a.filesize=b}("undefined"!=typeof window?window:global);
6//# sourceMappingURL=filesize.min.js.map \ No newline at end of file
diff --git a/frontend/js/jquery-1.12.1.min.js b/frontend/js/jquery-1.12.1.min.js
new file mode 100644
index 0000000..a5195a3
--- /dev/null
+++ b/frontend/js/jquery-1.12.1.min.js
@@ -0,0 +1,5 @@
1/*! jQuery v1.12.1 | (c) jQuery Foundation | jquery.org/license */
2!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="1.12.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:g,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(n.isPlainObject(c)||(b=n.isArray(c)))?(b?(b=!1,f=a&&n.isArray(a)?a:[]):f=a&&n.isPlainObject(a)?a:{},g[d]=n.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray||function(a){return"array"===n.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){var b=a&&a.toString();return!n.isArray(a)&&b-parseFloat(b)+1>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(!l.ownFirst)for(b in a)return k.call(a,b);for(b in a);return void 0===b||k.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;c>d;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):g.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(h)return h.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,g=0,h=[];if(s(a))for(d=a.length;d>g;g++)e=b(a[g],g,c),null!=e&&h.push(e);else for(g in a)e=b(a[g],g,c),null!=e&&h.push(e);return f.apply([],h)},guid:1,proxy:function(a,b){var c,d,f;return"string"==typeof b&&(f=a[b],b=a,a=f),n.isFunction(a)?(c=e.call(arguments,2),d=function(){return a.apply(b||this,c.concat(e.call(arguments)))},d.guid=a.guid=a.guid||n.guid++,d):void 0},now:function(){return+new Date},support:l}),"function"==typeof Symbol&&(n.fn[Symbol.iterator]=c[Symbol.iterator]),n.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){i["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=!!a&&"length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ga(),z=ga(),A=ga(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",O=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+N+")*)|.*)\\)|)",P=new RegExp(L+"+","g"),Q=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),R=new RegExp("^"+L+"*,"+L+"*"),S=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(ea){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fa(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+qa(r[h]);s=r.join(","),w=_.test(a)&&oa(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function ga(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ha(a){return a[u]=!0,a}function ia(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ja(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ka(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function la(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function na(a){return ha(function(b){return b=+b,ha(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function oa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=fa.support={},f=fa.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fa.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ia(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ia(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ia(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return"undefined"!=typeof b.getElementsByClassName&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ia(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\r\\' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ia(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ia(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ka(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ka(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},fa.matches=function(a,b){return fa(a,null,null,b)},fa.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fa(b,n,null,[a]).length>0},fa.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fa.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fa.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fa.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fa.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fa.selectors={cacheLength:50,createPseudo:ha,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fa.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fa.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fa.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fa.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ha(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ha(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ha(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ha(function(a){return function(b){return fa(a,b).length>0}}),contains:ha(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ha(function(a){return V.test(a||"")||fa.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:na(function(){return[0]}),last:na(function(a,b){return[b-1]}),eq:na(function(a,b,c){return[0>c?c+b:c]}),even:na(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:na(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:na(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:na(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=la(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=ma(b);function pa(){}pa.prototype=d.filters=d.pseudos,d.setFilters=new pa,g=fa.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=R.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=S.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(Q," ")}),h=h.slice(c.length));for(g in d.filter)!(e=W[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fa.error(a):z(a,i).slice(0)};function qa(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function ra(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j,k=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(j=b[u]||(b[u]={}),i=j[b.uniqueID]||(j[b.uniqueID]={}),(h=i[d])&&h[0]===w&&h[1]===f)return k[2]=h[2];if(i[d]=k,k[2]=a(b,c,g))return!0}}}function sa(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ta(a,b,c){for(var d=0,e=b.length;e>d;d++)fa(a,b[d],c);return c}function ua(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function va(a,b,c,d,e,f){return d&&!d[u]&&(d=va(d)),e&&!e[u]&&(e=va(e,f)),ha(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ta(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ua(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ua(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ua(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function wa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ra(function(a){return a===b},h,!0),l=ra(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[ra(sa(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return va(i>1&&sa(m),i>1&&qa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,e>i&&wa(a.slice(i,e)),f>e&&wa(a=a.slice(e)),f>e&&qa(a))}m.push(c)}return sa(m)}function xa(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ua(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&fa.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ha(f):f}return h=fa.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xa(e,d)),f.selector=a}return f},i=fa.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&oa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qa(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&oa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ia(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ia(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ja("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ia(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ja("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ia(function(a){return null==a.getAttribute("disabled")})||ja(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fa}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;e>b;b++)if(n.contains(d[b],this))return!0}));for(b=0;e>b;b++)n.find(a,d[b],c);return c=this.pushStack(e>1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:B.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}if(f=d.getElementById(e[2]),f&&f.parentNode){if(f.id!==e[2])return A.find(a);this.length=1,this[0]=f}return this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};C.prototype=n.fn,A=n(d);var D=/^(?:parents|prev(?:Until|All))/,E={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(n.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=w.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function F(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return F(a,"nextSibling")},prev:function(a){return F(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(E[a]||(e=n.uniqueSort(e)),D.test(a)&&(e=e.reverse())),this.pushStack(e)}});var G=/\S+/g;function H(a){var b={};return n.each(a.match(G)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?H(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h<f.length)f[h].apply(c[0],c[1])===!1&&a.stopOnFalse&&(h=f.length,c=!1)}a.memory||(c=!1),b=!1,e&&(f=c?[]:"")},j={add:function(){return f&&(c&&!b&&(h=f.length-1,g.push(c)),function d(b){n.each(b,function(b,c){n.isFunction(c)?a.unique&&j.has(c)||f.push(c):c&&c.length&&"string"!==n.type(c)&&d(c)})}(arguments),c&&!b&&i()),this},remove:function(){return n.each(arguments,function(a,b){var c;while((c=n.inArray(b,f,c))>-1)f.splice(c,1),h>=c&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=!0,c||j.disable(),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);d>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().progress(h(b,j,i)).done(h(b,k,c)).fail(g.reject):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function J(){d.addEventListener?(d.removeEventListener("DOMContentLoaded",K),a.removeEventListener("load",K)):(d.detachEvent("onreadystatechange",K),a.detachEvent("onload",K))}function K(){(d.addEventListener||"load"===a.event.type||"complete"===d.readyState)&&(J(),n.ready())}n.ready.promise=function(b){if(!I)if(I=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll)a.setTimeout(n.ready);else if(d.addEventListener)d.addEventListener("DOMContentLoaded",K),a.addEventListener("load",K);else{d.attachEvent("onreadystatechange",K),a.attachEvent("onload",K);var c=!1;try{c=null==a.frameElement&&d.documentElement}catch(e){}c&&c.doScroll&&!function f(){if(!n.isReady){try{c.doScroll("left")}catch(b){return a.setTimeout(f,50)}J(),n.ready()}}()}return I.promise(b)},n.ready.promise();var L;for(L in n(l))break;l.ownFirst="0"===L,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c,e;c=d.getElementsByTagName("body")[0],c&&c.style&&(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),"undefined"!=typeof b.style.zoom&&(b.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",l.inlineBlockNeedsLayout=a=3===b.offsetWidth,a&&(c.style.zoom=1)),c.removeChild(e))}),function(){var a=d.createElement("div");l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}a=null}();var M=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b},N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(O,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}n.data(a,b,c)}else c=void 0;
3}return c}function Q(a){var b;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function R(a,b,d,e){if(M(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),("object"==typeof b||"function"==typeof b)&&(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[n.camelCase(b)])):f=g,f}}function S(a,b,c){if(M(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!Q(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,Q(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=void 0)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?n.cache[a[n.expando]]:a[n.expando],!!a&&!Q(a)},data:function(a,b,c){return R(a,b,c)},removeData:function(a,b){return S(a,b)},_data:function(a,b,c){return R(a,b,c,!0)},_removeData:function(a,b){return S(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?P(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=n._data(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}}),function(){var a;l.shrinkWrapBlocks=function(){if(null!=a)return a;a=!1;var b,c,e;return c=d.getElementsByTagName("body")[0],c&&c.style?(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),"undefined"!=typeof b.style.zoom&&(b.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",b.appendChild(d.createElement("div")).style.width="5px",a=3!==b.offsetWidth),c.removeChild(e),a):void 0}}();var T=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,U=new RegExp("^(?:([+-])=|)("+T+")([a-z%]*)$","i"),V=["Top","Right","Bottom","Left"],W=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)};function X(a,b,c,d){var e,f=1,g=20,h=d?function(){return d.cur()}:function(){return n.css(a,b,"")},i=h(),j=c&&c[3]||(n.cssNumber[b]?"":"px"),k=(n.cssNumber[b]||"px"!==j&&+i)&&U.exec(n.css(a,b));if(k&&k[3]!==j){j=j||k[3],c=c||[],k=+i||1;do f=f||".5",k/=f,n.style(a,b,k+j);while(f!==(f=h()/i)&&1!==f&&--g)}return c&&(k=+k||+i||0,e=c[1]?k+(c[1]+1)*c[2]:+c[2],d&&(d.unit=j,d.start=k,d.end=e)),e}var Y=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)Y(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},Z=/^(?:checkbox|radio)$/i,$=/<([\w:-]+)/,_=/^$|\/(?:java|ecma)script/i,aa=/^\s+/,ba="abbr|article|aside|audio|bdi|canvas|data|datalist|details|dialog|figcaption|figure|footer|header|hgroup|main|mark|meter|nav|output|picture|progress|section|summary|template|time|video";function ca(a){var b=ba.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}!function(){var a=d.createElement("div"),b=d.createDocumentFragment(),c=d.createElement("input");a.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",l.leadingWhitespace=3===a.firstChild.nodeType,l.tbody=!a.getElementsByTagName("tbody").length,l.htmlSerialize=!!a.getElementsByTagName("link").length,l.html5Clone="<:nav></:nav>"!==d.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,b.appendChild(c),l.appendChecked=c.checked,a.innerHTML="<textarea>x</textarea>",l.noCloneChecked=!!a.cloneNode(!0).lastChild.defaultValue,b.appendChild(a),c=d.createElement("input"),c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),a.appendChild(c),l.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!!a.addEventListener,a[n.expando]=1,l.attributes=!a.getAttribute(n.expando)}();var da={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:l.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]};da.optgroup=da.option,da.tbody=da.tfoot=da.colgroup=da.caption=da.thead,da.th=da.td;function ea(a,b){var c,d,e=0,f="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,ea(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function fa(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}var ga=/<|&#?\w+;/,ha=/<tbody/i;function ia(a){Z.test(a.type)&&(a.defaultChecked=a.checked)}function ja(a,b,c,d,e){for(var f,g,h,i,j,k,m,o=a.length,p=ca(b),q=[],r=0;o>r;r++)if(g=a[r],g||0===g)if("object"===n.type(g))n.merge(q,g.nodeType?[g]:g);else if(ga.test(g)){i=i||p.appendChild(b.createElement("div")),j=($.exec(g)||["",""])[1].toLowerCase(),m=da[j]||da._default,i.innerHTML=m[1]+n.htmlPrefilter(g)+m[2],f=m[0];while(f--)i=i.lastChild;if(!l.leadingWhitespace&&aa.test(g)&&q.push(b.createTextNode(aa.exec(g)[0])),!l.tbody){g="table"!==j||ha.test(g)?"<table>"!==m[1]||ha.test(g)?0:i:i.firstChild,f=g&&g.childNodes.length;while(f--)n.nodeName(k=g.childNodes[f],"tbody")&&!k.childNodes.length&&g.removeChild(k)}n.merge(q,i.childNodes),i.textContent="";while(i.firstChild)i.removeChild(i.firstChild);i=p.lastChild}else q.push(b.createTextNode(g));i&&p.removeChild(i),l.appendChecked||n.grep(ea(q,"input"),ia),r=0;while(g=q[r++])if(d&&n.inArray(g,d)>-1)e&&e.push(g);else if(h=n.contains(g.ownerDocument,g),i=ea(p.appendChild(g),"script"),h&&fa(i),c){f=0;while(g=i[f++])_.test(g.type||"")&&c.push(g)}return i=null,p}!function(){var b,c,e=d.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b]=c in a)||(e.setAttribute(c,"t"),l[b]=e.attributes[c].expando===!1);e=null}();var ka=/^(?:input|select|textarea)$/i,la=/^key/,ma=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,na=/^(?:focusinfocus|focusoutblur)$/,oa=/^([^.]*)(?:\.(.+)|)/;function pa(){return!0}function qa(){return!1}function ra(){try{return d.activeElement}catch(a){}}function sa(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)sa(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=qa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return"undefined"==typeof n||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(G)||[""],h=b.length;while(h--)f=oa.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(G)||[""],j=b.length;while(j--)if(h=oa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,e,f){var g,h,i,j,l,m,o,p=[e||d],q=k.call(b,"type")?b.type:b,r=k.call(b,"namespace")?b.namespace.split("."):[];if(i=m=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!na.test(q+n.event.triggered)&&(q.indexOf(".")>-1&&(r=q.split("."),q=r.shift(),r.sort()),h=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=r.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:n.makeArray(c,[b]),l=n.event.special[q]||{},f||!l.trigger||l.trigger.apply(e,c)!==!1)){if(!f&&!l.noBubble&&!n.isWindow(e)){for(j=l.delegateType||q,na.test(j+q)||(i=i.parentNode);i;i=i.parentNode)p.push(i),m=i;m===(e.ownerDocument||d)&&p.push(m.defaultView||m.parentWindow||a)}o=0;while((i=p[o++])&&!b.isPropagationStopped())b.type=o>1?j:l.bindType||q,g=(n._data(i,"events")||{})[b.type]&&n._data(i,"handle"),g&&g.apply(i,c),g=h&&i[h],g&&g.apply&&M(i)&&(b.result=g.apply(i,c),b.result===!1&&b.preventDefault());if(b.type=q,!f&&!b.isDefaultPrevented()&&(!l._default||l._default.apply(p.pop(),c)===!1)&&M(e)&&h&&e[q]&&!n.isWindow(e)){m=e[h],m&&(e[h]=null),n.event.triggered=q;try{e[q]()}catch(s){}n.event.triggered=void 0,m&&(e[h]=m)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.rnamespace||a.rnamespace.test(g.namespace))&&(a.handleObj=g,a.data=g.data,d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==d&&(a.result=d)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},fix:function(a){if(a[n.expando])return a;var b,c,e,f=a.type,g=a,h=this.fixHooks[f];h||(this.fixHooks[f]=h=ma.test(f)?this.mouseHooks:la.test(f)?this.keyHooks:{}),e=h.props?this.props.concat(h.props):this.props,a=new n.Event(g),b=e.length;while(b--)c=e[b],a[c]=g[c];return a.target||(a.target=g.srcElement||d),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,h.filter?h.filter(a,g):a},props:"altKey bubbles cancelable ctrlKey currentTarget detail eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,e,f,g=b.button,h=b.fromElement;return null==a.pageX&&null!=b.clientX&&(e=a.target.ownerDocument||d,f=e.documentElement,c=e.body,a.pageX=b.clientX+(f&&f.scrollLeft||c&&c.scrollLeft||0)-(f&&f.clientLeft||c&&c.clientLeft||0),a.pageY=b.clientY+(f&&f.scrollTop||c&&c.scrollTop||0)-(f&&f.clientTop||c&&c.clientTop||0)),!a.relatedTarget&&h&&(a.relatedTarget=h===a.target?b.toElement:h),a.which||void 0===g||(a.which=1&g?1:2&g?3:4&g?2:0),a}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==ra()&&this.focus)try{return this.focus(),!1}catch(a){}},delegateType:"focusin"},blur:{trigger:function(){return this===ra()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return n.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c){var d=n.extend(new n.Event,c,{type:a,isSimulated:!0});n.event.trigger(d,null,b),d.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=d.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c)}:function(a,b,c){var d="on"+b;a.detachEvent&&("undefined"==typeof a[d]&&(a[d]=null),a.detachEvent(d,c))},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?pa:qa):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={constructor:n.Event,isDefaultPrevented:qa,isPropagationStopped:qa,isImmediatePropagationStopped:qa,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=pa,a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=pa,a&&!this.isSimulated&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=pa,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),l.submit||(n.event.special.submit={setup:function(){return n.nodeName(this,"form")?!1:void n.event.add(this,"click._submit keypress._submit",function(a){var b=a.target,c=n.nodeName(b,"input")||n.nodeName(b,"button")?n.prop(b,"form"):void 0;c&&!n._data(c,"submit")&&(n.event.add(c,"submit._submit",function(a){a._submitBubble=!0}),n._data(c,"submit",!0))})},postDispatch:function(a){a._submitBubble&&(delete a._submitBubble,this.parentNode&&!a.isTrigger&&n.event.simulate("submit",this.parentNode,a))},teardown:function(){return n.nodeName(this,"form")?!1:void n.event.remove(this,"._submit")}}),l.change||(n.event.special.change={setup:function(){return ka.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(n.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._justChanged=!0)}),n.event.add(this,"click._change",function(a){this._justChanged&&!a.isTrigger&&(this._justChanged=!1),n.event.simulate("change",this,a)})),!1):void n.event.add(this,"beforeactivate._change",function(a){var b=a.target;ka.test(b.nodeName)&&!n._data(b,"change")&&(n.event.add(b,"change._change",function(a){!this.parentNode||a.isSimulated||a.isTrigger||n.event.simulate("change",this.parentNode,a)}),n._data(b,"change",!0))})},handle:function(a){var b=a.target;return this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type?a.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return n.event.remove(this,"._change"),!ka.test(this.nodeName)}}),l.focusin||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a))};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=n._data(d,b);e||d.addEventListener(a,c,!0),n._data(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=n._data(d,b)-1;e?n._data(d,b,e):(d.removeEventListener(a,c,!0),n._removeData(d,b))}}}),n.fn.extend({on:function(a,b,c,d){return sa(this,a,b,c,d)},one:function(a,b,c,d){return sa(this,a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=qa),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ta=/ jQuery\d+="(?:null|\d+)"/g,ua=new RegExp("<(?:"+ba+")[\\s/>]","i"),va=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,wa=/<script|<style|<link/i,xa=/checked\s*(?:[^=]|=\s*.checked.)/i,ya=/^true\/(.*)/,za=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Aa=ca(d),Ba=Aa.appendChild(d.createElement("div"));function Ca(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function Da(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function Ea(a){var b=ya.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Fa(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)n.event.add(b,c,h[c][d])}g.data&&(g.data=n.extend({},g.data))}}function Ga(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!l.noCloneEvent&&b[n.expando]){e=n._data(b);for(d in e.events)n.removeEvent(b,d,e.handle);b.removeAttribute(n.expando)}"script"===c&&b.text!==a.text?(Da(b).text=a.text,Ea(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),l.html5Clone&&a.innerHTML&&!n.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Z.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}}function Ha(a,b,c,d){b=f.apply([],b);var e,g,h,i,j,k,m=0,o=a.length,p=o-1,q=b[0],r=n.isFunction(q);if(r||o>1&&"string"==typeof q&&!l.checkClone&&xa.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),Ha(f,b,c,d)});if(o&&(k=ja(b,a[0].ownerDocument,!1,a,d),e=k.firstChild,1===k.childNodes.length&&(k=e),e||d)){for(i=n.map(ea(k,"script"),Da),h=i.length;o>m;m++)g=k,m!==p&&(g=n.clone(g,!0,!0),h&&n.merge(i,ea(g,"script"))),c.call(a[m],g,m);if(h)for(j=i[i.length-1].ownerDocument,n.map(i,Ea),m=0;h>m;m++)g=i[m],_.test(g.type||"")&&!n._data(g,"globalEval")&&n.contains(j,g)&&(g.src?n._evalUrl&&n._evalUrl(g.src):n.globalEval((g.text||g.textContent||g.innerHTML||"").replace(za,"")));k=e=null}return a}function Ia(a,b,c){for(var d,e=b?n.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||n.cleanData(ea(d)),d.parentNode&&(c&&n.contains(d.ownerDocument,d)&&fa(ea(d,"script")),d.parentNode.removeChild(d));return a}n.extend({htmlPrefilter:function(a){return a.replace(va,"<$1></$2>")},clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!ua.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(Ba.innerHTML=a.outerHTML,Ba.removeChild(f=Ba.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=ea(f),h=ea(a),g=0;null!=(e=h[g]);++g)d[g]&&Ga(e,d[g]);if(b)if(c)for(h=h||ea(a),d=d||ea(f),g=0;null!=(e=h[g]);g++)Fa(e,d[g]);else Fa(a,f);return d=ea(f,"script"),d.length>0&&fa(d,!i&&ea(a,"script")),d=h=e=null,f},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.attributes,m=n.event.special;null!=(d=a[h]);h++)if((b||M(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k||"undefined"==typeof d.removeAttribute?d[i]=void 0:d.removeAttribute(i),c.push(f))}}}),n.fn.extend({domManip:Ha,detach:function(a){return Ia(this,a,!0)},remove:function(a){return Ia(this,a)},text:function(a){return Y(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||d).createTextNode(a))},null,a,arguments.length)},append:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.appendChild(a)}})},prepend:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(ea(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return Y(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(ta,""):void 0;if("string"==typeof a&&!wa.test(a)&&(l.htmlSerialize||!ua.test(a))&&(l.leadingWhitespace||!aa.test(a))&&!da[($.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ea(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return Ha(this,arguments,function(b){var c=this.parentNode;n.inArray(this,a)<0&&(n.cleanData(ea(this)),c&&c.replaceChild(b,this))},a)}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=0,e=[],f=n(a),h=f.length-1;h>=d;d++)c=d===h?this:this.clone(!0),n(f[d])[b](c),g.apply(e,c.get());return this.pushStack(e)}});var Ja,Ka={HTML:"block",BODY:"block"};function La(a,b){var c=n(b.createElement(a)).appendTo(b.body),d=n.css(c[0],"display");return c.detach(),d}function Ma(a){var b=d,c=Ka[a];return c||(c=La(a,b),"none"!==c&&c||(Ja=(Ja||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=(Ja[0].contentWindow||Ja[0].contentDocument).document,b.write(),b.close(),c=La(a,b),Ja.detach()),Ka[a]=c),c}var Na=/^margin/,Oa=new RegExp("^("+T+")(?!px)[a-z%]+$","i"),Pa=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e},Qa=d.documentElement;!function(){var b,c,e,f,g,h,i=d.createElement("div"),j=d.createElement("div");if(j.style){j.style.cssText="float:left;opacity:.5",l.opacity="0.5"===j.style.opacity,l.cssFloat=!!j.style.cssFloat,j.style.backgroundClip="content-box",j.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===j.style.backgroundClip,i=d.createElement("div"),i.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",j.innerHTML="",i.appendChild(j),l.boxSizing=""===j.style.boxSizing||""===j.style.MozBoxSizing||""===j.style.WebkitBoxSizing,n.extend(l,{reliableHiddenOffsets:function(){return null==b&&k(),f},boxSizingReliable:function(){return null==b&&k(),e},pixelMarginRight:function(){return null==b&&k(),c},pixelPosition:function(){return null==b&&k(),b},reliableMarginRight:function(){return null==b&&k(),g},reliableMarginLeft:function(){return null==b&&k(),h}});function k(){var k,l,m=d.documentElement;m.appendChild(i),j.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",b=e=h=!1,c=g=!0,a.getComputedStyle&&(l=a.getComputedStyle(j),b="1%"!==(l||{}).top,h="2px"===(l||{}).marginLeft,e="4px"===(l||{width:"4px"}).width,j.style.marginRight="50%",c="4px"===(l||{marginRight:"4px"}).marginRight,k=j.appendChild(d.createElement("div")),k.style.cssText=j.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",k.style.marginRight=k.style.width="0",j.style.width="1px",g=!parseFloat((a.getComputedStyle(k)||{}).marginRight),j.removeChild(k)),j.style.display="none",f=0===j.getClientRects().length,f&&(j.style.display="",j.innerHTML="<table><tr><td></td><td>t</td></tr></table>",k=j.getElementsByTagName("td"),k[0].style.cssText="margin:0;border:0;padding:0;display:none",f=0===k[0].offsetHeight,f&&(k[0].style.display="",k[1].style.display="none",f=0===k[0].offsetHeight)),m.removeChild(i)}}}();var Ra,Sa,Ta=/^(top|right|bottom|left)$/;a.getComputedStyle?(Ra=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)},Sa=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ra(a),g=c?c.getPropertyValue(b)||c[b]:void 0,""!==g&&void 0!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),c&&!l.pixelMarginRight()&&Oa.test(g)&&Na.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f),void 0===g?g:g+""}):Qa.currentStyle&&(Ra=function(a){return a.currentStyle},Sa=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ra(a),g=c?c[b]:void 0,null==g&&h&&h[b]&&(g=h[b]),Oa.test(g)&&!Ta.test(b)&&(d=h.left,e=a.runtimeStyle,f=e&&e.left,f&&(e.left=a.currentStyle.left),h.left="fontSize"===b?"1em":g,g=h.pixelLeft+"px",h.left=d,f&&(e.left=f)),void 0===g?g:g+""||"auto"});function Ua(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Va=/alpha\([^)]*\)/i,Wa=/opacity\s*=\s*([^)]*)/i,Xa=/^(none|table(?!-c[ea]).+)/,Ya=new RegExp("^("+T+")(.*)$","i"),Za={position:"absolute",visibility:"hidden",display:"block"},$a={letterSpacing:"0",fontWeight:"400"},_a=["Webkit","O","Moz","ms"],ab=d.createElement("div").style;function bb(a){if(a in ab)return a;var b=a.charAt(0).toUpperCase()+a.slice(1),c=_a.length;while(c--)if(a=_a[c]+b,a in ab)return a}function cb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=n._data(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&W(d)&&(f[g]=n._data(d,"olddisplay",Ma(d.nodeName)))):(e=W(d),(c&&"none"!==c||!e)&&n._data(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}function db(a,b,c){var d=Ya.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function eb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+V[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+V[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+V[f]+"Width",!0,e))):(g+=n.css(a,"padding"+V[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+V[f]+"Width",!0,e)));return g}function fb(b,c,e){var f=!0,g="width"===c?b.offsetWidth:b.offsetHeight,h=Ra(b),i=l.boxSizing&&"border-box"===n.css(b,"boxSizing",!1,h);if(d.msFullscreenElement&&a.top!==a&&b.getClientRects().length&&(g=Math.round(100*b.getBoundingClientRect()[c])),0>=g||null==g){if(g=Sa(b,c,h),(0>g||null==g)&&(g=b.style[c]),Oa.test(g))return g;f=i&&(l.boxSizingReliable()||g===b.style[c]),g=parseFloat(g)||0}return g+eb(b,c,e||(i?"border":"content"),f,h)+"px"}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Sa(a,"opacity");return""===c?"1":c}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":l.cssFloat?"cssFloat":"styleFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;if(b=n.cssProps[h]||(n.cssProps[h]=bb(h)||h),g=n.cssHooks[b]||n.cssHooks[h],void 0===c)return g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b];if(f=typeof c,"string"===f&&(e=U.exec(c))&&e[1]&&(c=X(a,b,e),f="number"),null!=c&&c===c&&("number"===f&&(c+=e&&e[3]||(n.cssNumber[h]?"":"px")),l.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),!(g&&"set"in g&&void 0===(c=g.set(a,c,d)))))try{i[b]=c}catch(j){}}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=bb(h)||h),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(f=g.get(a,!0,c)),void 0===f&&(f=Sa(a,b,d)),"normal"===f&&b in $a&&(f=$a[b]),""===c||c?(e=parseFloat(f),c===!0||isFinite(e)?e||0:f):f}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?Xa.test(n.css(a,"display"))&&0===a.offsetWidth?Pa(a,Za,function(){return fb(a,b,d)}):fb(a,b,d):void 0},set:function(a,c,d){var e=d&&Ra(a);return db(a,c,d?eb(a,b,d,l.boxSizing&&"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),l.opacity||(n.cssHooks.opacity={get:function(a,b){return Wa.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=n.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,(b>=1||""===b)&&""===n.trim(f.replace(Va,""))&&c.removeAttribute&&(c.removeAttribute("filter"),""===b||d&&!d.filter)||(c.filter=Va.test(f)?f.replace(Va,e):f+" "+e)}}),n.cssHooks.marginRight=Ua(l.reliableMarginRight,function(a,b){return b?Pa(a,{display:"inline-block"},Sa,[a,"marginRight"]):void 0}),n.cssHooks.marginLeft=Ua(l.reliableMarginLeft,function(a,b){
4return b?(parseFloat(Sa(a,"marginLeft"))||(n.contains(a.ownerDocument,a)?a.getBoundingClientRect().left-Pa(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}):0))+"px":void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+V[d]+b]=f[d]||f[d-2]||f[0];return e}},Na.test(a)||(n.cssHooks[a+b].set=db)}),n.fn.extend({css:function(a,b){return Y(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=Ra(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return cb(this,!0)},hide:function(){return cb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){W(this)?n(this).show():n(this).hide()})}});function gb(a,b,c,d,e){return new gb.prototype.init(a,b,c,d,e)}n.Tween=gb,gb.prototype={constructor:gb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||n.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=gb.propHooks[this.prop];return a&&a.get?a.get(this):gb.propHooks._default.get(this)},run:function(a){var b,c=gb.propHooks[this.prop];return this.options.duration?this.pos=b=n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):gb.propHooks._default.set(this),this}},gb.prototype.init.prototype=gb.prototype,gb.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[n.cssProps[a.prop]]&&!n.cssHooks[a.prop]?a.elem[a.prop]=a.now:n.style(a.elem,a.prop,a.now+a.unit)}}},gb.propHooks.scrollTop=gb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},n.fx=gb.prototype.init,n.fx.step={};var hb,ib,jb=/^(?:toggle|show|hide)$/,kb=/queueHooks$/;function lb(){return a.setTimeout(function(){hb=void 0}),hb=n.now()}function mb(a,b){var c,d={height:a},e=0;for(b=b?1:0;4>e;e+=2-b)c=V[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function nb(a,b,c){for(var d,e=(qb.tweeners[b]||[]).concat(qb.tweeners["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function ob(a,b,c){var d,e,f,g,h,i,j,k,m=this,o={},p=a.style,q=a.nodeType&&W(a),r=n._data(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,m.always(function(){m.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[p.overflow,p.overflowX,p.overflowY],j=n.css(a,"display"),k="none"===j?n._data(a,"olddisplay")||Ma(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(l.inlineBlockNeedsLayout&&"inline"!==Ma(a.nodeName)?p.zoom=1:p.display="inline-block")),c.overflow&&(p.overflow="hidden",l.shrinkWrapBlocks()||m.always(function(){p.overflow=c.overflow[0],p.overflowX=c.overflow[1],p.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],jb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(q?"hide":"show")){if("show"!==e||!r||void 0===r[d])continue;q=!0}o[d]=r&&r[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(o))"inline"===("none"===j?Ma(a.nodeName):j)&&(p.display=j);else{r?"hidden"in r&&(q=r.hidden):r=n._data(a,"fxshow",{}),f&&(r.hidden=!q),q?n(a).show():m.done(function(){n(a).hide()}),m.done(function(){var b;n._removeData(a,"fxshow");for(b in o)n.style(a,b,o[b])});for(d in o)g=nb(q?r[d]:0,d,m),d in r||(r[d]=g.start,q&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function pb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function qb(a,b,c){var d,e,f=0,g=qb.prefilters.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=hb||lb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{},easing:n.easing._default},c),originalProperties:b,originalOptions:c,startTime:hb||lb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?(h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j,b])):h.rejectWith(a,[j,b]),this}}),k=j.props;for(pb(k,j.opts.specialEasing);g>f;f++)if(d=qb.prefilters[f].call(j,a,k,j.opts))return n.isFunction(d.stop)&&(n._queueHooks(j.elem,j.opts.queue).stop=n.proxy(d.stop,d)),d;return n.map(k,nb,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(qb,{tweeners:{"*":[function(a,b){var c=this.createTween(a,b);return X(c.elem,a,U.exec(b),c),c}]},tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.match(G);for(var c,d=0,e=a.length;e>d;d++)c=a[d],qb.tweeners[c]=qb.tweeners[c]||[],qb.tweeners[c].unshift(b)},prefilters:[ob],prefilter:function(a,b){b?qb.prefilters.unshift(a):qb.prefilters.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(W).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=qb(this,n.extend({},a),f);(e||n._data(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=n._data(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&kb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=n._data(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(mb(b,!0),a,d,e)}}),n.each({slideDown:mb("show"),slideUp:mb("hide"),slideToggle:mb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=n.timers,c=0;for(hb=n.now();c<b.length;c++)a=b[c],a()||b[c]!==a||b.splice(c--,1);b.length||n.fx.stop(),hb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){ib||(ib=a.setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){a.clearInterval(ib),ib=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(b,c){return b=n.fx?n.fx.speeds[b]||b:b,c=c||"fx",this.queue(c,function(c,d){var e=a.setTimeout(c,b);d.stop=function(){a.clearTimeout(e)}})},function(){var a,b=d.createElement("input"),c=d.createElement("div"),e=d.createElement("select"),f=e.appendChild(d.createElement("option"));c=d.createElement("div"),c.setAttribute("className","t"),c.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",a=c.getElementsByTagName("a")[0],b.setAttribute("type","checkbox"),c.appendChild(b),a=c.getElementsByTagName("a")[0],a.style.cssText="top:1px",l.getSetAttribute="t"!==c.className,l.style=/top/.test(a.getAttribute("style")),l.hrefNormalized="/a"===a.getAttribute("href"),l.checkOn=!!b.value,l.optSelected=f.selected,l.enctype=!!d.createElement("form").enctype,e.disabled=!0,l.optDisabled=!f.disabled,b=d.createElement("input"),b.setAttribute("value",""),l.input=""===b.getAttribute("value"),b.value="t",b.setAttribute("type","radio"),l.radioValue="t"===b.value}();var rb=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(rb,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],(c.selected||i===e)&&(l.optDisabled?!c.disabled:null===c.getAttribute("disabled"))&&(!c.parentNode.disabled||!n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)if(d=e[g],n.inArray(n.valHooks.option.get(d),f)>=0)try{d.selected=c=!0}catch(h){d.scrollHeight}else d.selected=!1;return c||(a.selectedIndex=-1),e}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>-1:void 0}},l.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var sb,tb,ub=n.expr.attrHandle,vb=/^(?:checked|selected)$/i,wb=l.getSetAttribute,xb=l.input;n.fn.extend({attr:function(a,b){return Y(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return"undefined"==typeof a.getAttribute?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),e=n.attrHooks[b]||(n.expr.match.bool.test(b)?tb:sb)),void 0!==c?null===c?void n.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=n.find.attr(a,b),null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!l.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(G);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)?xb&&wb||!vb.test(c)?a[d]=!1:a[n.camelCase("default-"+c)]=a[d]=!1:n.attr(a,c,""),a.removeAttribute(wb?c:d)}}),tb={set:function(a,b,c){return b===!1?n.removeAttr(a,c):xb&&wb||!vb.test(c)?a.setAttribute(!wb&&n.propFix[c]||c,c):a[n.camelCase("default-"+c)]=a[c]=!0,c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=ub[b]||n.find.attr;xb&&wb||!vb.test(b)?ub[b]=function(a,b,d){var e,f;return d||(f=ub[b],ub[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,ub[b]=f),e}:ub[b]=function(a,b,c){return c?void 0:a[n.camelCase("default-"+b)]?b.toLowerCase():null}}),xb&&wb||(n.attrHooks.value={set:function(a,b,c){return n.nodeName(a,"input")?void(a.defaultValue=b):sb&&sb.set(a,b,c)}}),wb||(sb={set:function(a,b,c){var d=a.getAttributeNode(c);return d||a.setAttributeNode(d=a.ownerDocument.createAttribute(c)),d.value=b+="","value"===c||b===a.getAttribute(c)?b:void 0}},ub.id=ub.name=ub.coords=function(a,b,c){var d;return c?void 0:(d=a.getAttributeNode(b))&&""!==d.value?d.value:null},n.valHooks.button={get:function(a,b){var c=a.getAttributeNode(b);return c&&c.specified?c.value:void 0},set:sb.set},n.attrHooks.contenteditable={set:function(a,b,c){sb.set(a,""===b?!1:b,c)}},n.each(["width","height"],function(a,b){n.attrHooks[b]={set:function(a,c){return""===c?(a.setAttribute(b,"auto"),c):void 0}}})),l.style||(n.attrHooks.style={get:function(a){return a.style.cssText||void 0},set:function(a,b){return a.style.cssText=b+""}});var yb=/^(?:input|select|textarea|button|object)$/i,zb=/^(?:a|area)$/i;n.fn.extend({prop:function(a,b){return Y(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return a=n.propFix[a]||a,this.each(function(){try{this[a]=void 0,delete this[a]}catch(b){}})}}),n.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&n.isXMLDoc(a)||(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=n.find.attr(a,"tabindex");return b?parseInt(b,10):yb.test(a.nodeName)||zb.test(a.nodeName)&&a.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),l.hrefNormalized||n.each(["href","src"],function(a,b){n.propHooks[b]={get:function(a){return a.getAttribute(b,4)}}}),l.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this}),l.enctype||(n.propFix.enctype="encoding");var Ab=/[\t\r\n\f]/g;function Bb(a){return n.attr(a,"class")||""}n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,Bb(this)))});if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=Bb(c),d=1===c.nodeType&&(" "+e+" ").replace(Ab," ")){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,Bb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=Bb(c),d=1===c.nodeType&&(" "+e+" ").replace(Ab," ")){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):n.isFunction(a)?this.each(function(c){n(this).toggleClass(a.call(this,c,Bb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=n(this),f=a.match(G)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(void 0===a||"boolean"===c)&&(b=Bb(this),b&&n._data(this,"__className__",b),n.attr(this,"class",b||a===!1?"":n._data(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+Bb(c)+" ").replace(Ab," ").indexOf(b)>-1)return!0;return!1}}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var Cb=a.location,Db=n.now(),Eb=/\?/,Fb=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;n.parseJSON=function(b){if(a.JSON&&a.JSON.parse)return a.JSON.parse(b+"");var c,d=null,e=n.trim(b+"");return e&&!n.trim(e.replace(Fb,function(a,b,e,f){return c&&b&&(d=0),0===d?a:(c=e||b,d+=!f-!e,"")}))?Function("return "+e)():n.error("Invalid JSON: "+b)},n.parseXML=function(b){var c,d;if(!b||"string"!=typeof b)return null;try{a.DOMParser?(d=new a.DOMParser,c=d.parseFromString(b,"text/xml")):(c=new a.ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b))}catch(e){c=void 0}return c&&c.documentElement&&!c.getElementsByTagName("parsererror").length||n.error("Invalid XML: "+b),c};var Gb=/#.*$/,Hb=/([?&])_=[^&]*/,Ib=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Jb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Kb=/^(?:GET|HEAD)$/,Lb=/^\/\//,Mb=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Nb={},Ob={},Pb="*/".concat("*"),Qb=Cb.href,Rb=Mb.exec(Qb.toLowerCase())||[];function Sb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(G)||[];if(n.isFunction(c))while(d=f[e++])"+"===d.charAt(0)?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Tb(a,b,c,d){var e={},f=a===Ob;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Ub(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(d in b)void 0!==b[d]&&((e[d]?a:c||(c={}))[d]=b[d]);return c&&n.extend(!0,a,c),a}function Vb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===e&&(e=a.mimeType||b.getResponseHeader("Content-Type"));if(e)for(g in h)if(h[g]&&h[g].test(e)){i.unshift(g);break}if(i[0]in c)f=i[0];else{for(g in c){if(!i[0]||a.converters[g+" "+i[0]]){f=g;break}d||(d=g)}f=f||d}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function Wb(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Qb,type:"GET",isLocal:Jb.test(Rb[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Pb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Ub(Ub(a,n.ajaxSettings),b):Ub(n.ajaxSettings,a)},ajaxPrefilter:Sb(Nb),ajaxTransport:Sb(Ob),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var d,e,f,g,h,i,j,k,l=n.ajaxSetup({},c),m=l.context||l,o=l.context&&(m.nodeType||m.jquery)?n(m):n.event,p=n.Deferred(),q=n.Callbacks("once memory"),r=l.statusCode||{},s={},t={},u=0,v="canceled",w={readyState:0,getResponseHeader:function(a){var b;if(2===u){if(!k){k={};while(b=Ib.exec(g))k[b[1].toLowerCase()]=b[2]}b=k[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===u?g:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return u||(a=t[c]=t[c]||a,s[a]=b),this},overrideMimeType:function(a){return u||(l.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>u)for(b in a)r[b]=[r[b],a[b]];else w.always(a[w.status]);return this},abort:function(a){var b=a||v;return j&&j.abort(b),y(0,b),this}};if(p.promise(w).complete=q.add,w.success=w.done,w.error=w.fail,l.url=((b||l.url||Qb)+"").replace(Gb,"").replace(Lb,Rb[1]+"//"),l.type=c.method||c.type||l.method||l.type,l.dataTypes=n.trim(l.dataType||"*").toLowerCase().match(G)||[""],null==l.crossDomain&&(d=Mb.exec(l.url.toLowerCase()),l.crossDomain=!(!d||d[1]===Rb[1]&&d[2]===Rb[2]&&(d[3]||("http:"===d[1]?"80":"443"))===(Rb[3]||("http:"===Rb[1]?"80":"443")))),l.data&&l.processData&&"string"!=typeof l.data&&(l.data=n.param(l.data,l.traditional)),Tb(Nb,l,c,w),2===u)return w;i=n.event&&l.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),l.type=l.type.toUpperCase(),l.hasContent=!Kb.test(l.type),f=l.url,l.hasContent||(l.data&&(f=l.url+=(Eb.test(f)?"&":"?")+l.data,delete l.data),l.cache===!1&&(l.url=Hb.test(f)?f.replace(Hb,"$1_="+Db++):f+(Eb.test(f)?"&":"?")+"_="+Db++)),l.ifModified&&(n.lastModified[f]&&w.setRequestHeader("If-Modified-Since",n.lastModified[f]),n.etag[f]&&w.setRequestHeader("If-None-Match",n.etag[f])),(l.data&&l.hasContent&&l.contentType!==!1||c.contentType)&&w.setRequestHeader("Content-Type",l.contentType),w.setRequestHeader("Accept",l.dataTypes[0]&&l.accepts[l.dataTypes[0]]?l.accepts[l.dataTypes[0]]+("*"!==l.dataTypes[0]?", "+Pb+"; q=0.01":""):l.accepts["*"]);for(e in l.headers)w.setRequestHeader(e,l.headers[e]);if(l.beforeSend&&(l.beforeSend.call(m,w,l)===!1||2===u))return w.abort();v="abort";for(e in{success:1,error:1,complete:1})w[e](l[e]);if(j=Tb(Ob,l,c,w)){if(w.readyState=1,i&&o.trigger("ajaxSend",[w,l]),2===u)return w;l.async&&l.timeout>0&&(h=a.setTimeout(function(){w.abort("timeout")},l.timeout));try{u=1,j.send(s,y)}catch(x){if(!(2>u))throw x;y(-1,x)}}else y(-1,"No Transport");function y(b,c,d,e){var k,s,t,v,x,y=c;2!==u&&(u=2,h&&a.clearTimeout(h),j=void 0,g=e||"",w.readyState=b>0?4:0,k=b>=200&&300>b||304===b,d&&(v=Vb(l,w,d)),v=Wb(l,v,w,k),k?(l.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(n.lastModified[f]=x),x=w.getResponseHeader("etag"),x&&(n.etag[f]=x)),204===b||"HEAD"===l.type?y="nocontent":304===b?y="notmodified":(y=v.state,s=v.data,t=v.error,k=!t)):(t=y,(b||!y)&&(y="error",0>b&&(b=0))),w.status=b,w.statusText=(c||y)+"",k?p.resolveWith(m,[s,y,w]):p.rejectWith(m,[w,y,t]),w.statusCode(r),r=void 0,i&&o.trigger(k?"ajaxSuccess":"ajaxError",[w,l,k?s:t]),q.fireWith(m,[w,y]),i&&(o.trigger("ajaxComplete",[w,l]),--n.active||n.event.trigger("ajaxStop")))}return w},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax(n.extend({url:a,type:b,dataType:e,data:c,success:d},n.isPlainObject(a)&&a))}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){if(n.isFunction(a))return this.each(function(b){n(this).wrapAll(a.call(this,b))});if(this[0]){var b=n(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&1===a.firstChild.nodeType)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return n.isFunction(a)?this.each(function(b){n(this).wrapInner(a.call(this,b))}):this.each(function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}});function Xb(a){return a.style&&a.style.display||n.css(a,"display")}function Yb(a){while(a&&1===a.nodeType){if("none"===Xb(a)||"hidden"===a.type)return!0;a=a.parentNode}return!1}n.expr.filters.hidden=function(a){return l.reliableHiddenOffsets()?a.offsetWidth<=0&&a.offsetHeight<=0&&!a.getClientRects().length:Yb(a)},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var Zb=/%20/g,$b=/\[\]$/,_b=/\r?\n/g,ac=/^(?:submit|button|image|reset|file)$/i,bc=/^(?:input|select|textarea|keygen)/i;function cc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||$b.test(a)?d(a,e):cc(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)cc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)cc(c,a[c],b,e);return d.join("&").replace(Zb,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&bc.test(this.nodeName)&&!ac.test(a)&&(this.checked||!Z.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(_b,"\r\n")}}):{name:b.name,value:c.replace(_b,"\r\n")}}).get()}}),n.ajaxSettings.xhr=void 0!==a.ActiveXObject?function(){return this.isLocal?hc():d.documentMode>8?gc():/^(get|post|head|put|delete|options)$/i.test(this.type)&&gc()||hc()}:gc;var dc=0,ec={},fc=n.ajaxSettings.xhr();a.attachEvent&&a.attachEvent("onunload",function(){for(var a in ec)ec[a](void 0,!0)}),l.cors=!!fc&&"withCredentials"in fc,fc=l.ajax=!!fc,fc&&n.ajaxTransport(function(b){if(!b.crossDomain||l.cors){var c;return{send:function(d,e){var f,g=b.xhr(),h=++dc;if(g.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(f in b.xhrFields)g[f]=b.xhrFields[f];b.mimeType&&g.overrideMimeType&&g.overrideMimeType(b.mimeType),b.crossDomain||d["X-Requested-With"]||(d["X-Requested-With"]="XMLHttpRequest");for(f in d)void 0!==d[f]&&g.setRequestHeader(f,d[f]+"");g.send(b.hasContent&&b.data||null),c=function(a,d){var f,i,j;if(c&&(d||4===g.readyState))if(delete ec[h],c=void 0,g.onreadystatechange=n.noop,d)4!==g.readyState&&g.abort();else{j={},f=g.status,"string"==typeof g.responseText&&(j.text=g.responseText);try{i=g.statusText}catch(k){i=""}f||!b.isLocal||b.crossDomain?1223===f&&(f=204):f=j.text?200:404}j&&e(f,i,j,g.getAllResponseHeaders())},b.async?4===g.readyState?a.setTimeout(c):g.onreadystatechange=ec[h]=c:c()},abort:function(){c&&c(void 0,!0)}}}});function gc(){try{return new a.XMLHttpRequest}catch(b){}}function hc(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}n.ajaxPrefilter(function(a){a.crossDomain&&(a.contents.script=!1)}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c=d.head||n("head")[0]||d.documentElement;return{send:function(e,f){b=d.createElement("script"),b.async=!0,a.scriptCharset&&(b.charset=a.scriptCharset),b.src=a.url,b.onload=b.onreadystatechange=function(a,c){(c||!b.readyState||/loaded|complete/.test(b.readyState))&&(b.onload=b.onreadystatechange=null,b.parentNode&&b.parentNode.removeChild(b),b=null,c||f(200,"success"))},c.insertBefore(b,c.firstChild)},abort:function(){b&&b.onload(void 0,!0)}}}});var ic=[],jc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=ic.pop()||n.expando+"_"+Db++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(jc.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&jc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(jc,"$1"+e):b.jsonp!==!1&&(b.url+=(Eb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?n(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,ic.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),l.createHTMLDocument=function(){if(!d.implementation.createHTMLDocument)return!1;var a=d.implementation.createHTMLDocument("");return a.body.innerHTML="<form></form><form></form>",2===a.body.childNodes.length}(),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||(l.createHTMLDocument?d.implementation.createHTMLDocument(""):d);var e=x.exec(a),f=!c&&[];return e?[b.createElement(e[1])]:(e=ja([a],b,f),f&&f.length&&n(f).remove(),n.merge([],e.childNodes))};var kc=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&kc)return kc.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=n.trim(a.slice(h,a.length)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(g,f||[a.responseText,b,a])})}),this},n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};function lc(a){return n.isWindow(a)?a:9===a.nodeType?a.defaultView||a.parentWindow:!1}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&n.inArray("auto",[f,i])>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,n.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d={top:0,left:0},e=this[0],f=e&&e.ownerDocument;if(f)return b=f.documentElement,n.contains(b,e)?("undefined"!=typeof e.getBoundingClientRect&&(d=e.getBoundingClientRect()),c=lc(f),{top:d.top+(c.pageYOffset||b.scrollTop)-(b.clientTop||0),left:d.left+(c.pageXOffset||b.scrollLeft)-(b.clientLeft||0)}):d},position:function(){if(this[0]){var a,b,c={top:0,left:0},d=this[0];return"fixed"===n.css(d,"position")?b=d.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(c=a.offset()),c.top+=n.css(a[0],"borderTopWidth",!0),c.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-c.top-n.css(d,"marginTop",!0),left:b.left-c.left-n.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Qa})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c=/Y/.test(b);n.fn[a]=function(d){return Y(this,function(a,d,e){var f=lc(a);return void 0===e?f?b in f?f[b]:f.document.documentElement[d]:a[d]:void(f?f.scrollTo(c?n(f).scrollLeft():e,c?e:n(f).scrollTop()):a[d]=e);
5},a,d,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=Ua(l.pixelPosition,function(a,c){return c?(c=Sa(a,b),Oa.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return Y(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var mc=a.jQuery,nc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=nc),b&&a.jQuery===n&&(a.jQuery=mc),n},b||(a.jQuery=a.$=n),n});
diff --git a/frontend/js/npm.js b/frontend/js/npm.js
new file mode 100644
index 0000000..bf6aa80
--- /dev/null
+++ b/frontend/js/npm.js
@@ -0,0 +1,13 @@
1// This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment.
2require('../../js/transition.js')
3require('../../js/alert.js')
4require('../../js/button.js')
5require('../../js/carousel.js')
6require('../../js/collapse.js')
7require('../../js/dropdown.js')
8require('../../js/modal.js')
9require('../../js/tooltip.js')
10require('../../js/popover.js')
11require('../../js/scrollspy.js')
12require('../../js/tab.js')
13require('../../js/affix.js') \ No newline at end of file
diff --git a/frontend/js/superagent.js b/frontend/js/superagent.js
new file mode 100644
index 0000000..140bc4d
--- /dev/null
+++ b/frontend/js/superagent.js
@@ -0,0 +1,1383 @@
1!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.superagent=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
2
3/**
4 * Expose `Emitter`.
5 */
6
7module.exports = Emitter;
8
9/**
10 * Initialize a new `Emitter`.
11 *
12 * @api public
13 */
14
15function Emitter(obj) {
16 if (obj) return mixin(obj);
17};
18
19/**
20 * Mixin the emitter properties.
21 *
22 * @param {Object} obj
23 * @return {Object}
24 * @api private
25 */
26
27function mixin(obj) {
28 for (var key in Emitter.prototype) {
29 obj[key] = Emitter.prototype[key];
30 }
31 return obj;
32}
33
34/**
35 * Listen on the given `event` with `fn`.
36 *
37 * @param {String} event
38 * @param {Function} fn
39 * @return {Emitter}
40 * @api public
41 */
42
43Emitter.prototype.on =
44Emitter.prototype.addEventListener = function(event, fn){
45 this._callbacks = this._callbacks || {};
46 (this._callbacks['$' + event] = this._callbacks['$' + event] || [])
47 .push(fn);
48 return this;
49};
50
51/**
52 * Adds an `event` listener that will be invoked a single
53 * time then automatically removed.
54 *
55 * @param {String} event
56 * @param {Function} fn
57 * @return {Emitter}
58 * @api public
59 */
60
61Emitter.prototype.once = function(event, fn){
62 function on() {
63 this.off(event, on);
64 fn.apply(this, arguments);
65 }
66
67 on.fn = fn;
68 this.on(event, on);
69 return this;
70};
71
72/**
73 * Remove the given callback for `event` or all
74 * registered callbacks.
75 *
76 * @param {String} event
77 * @param {Function} fn
78 * @return {Emitter}
79 * @api public
80 */
81
82Emitter.prototype.off =
83Emitter.prototype.removeListener =
84Emitter.prototype.removeAllListeners =
85Emitter.prototype.removeEventListener = function(event, fn){
86 this._callbacks = this._callbacks || {};
87
88 // all
89 if (0 == arguments.length) {
90 this._callbacks = {};
91 return this;
92 }
93
94 // specific event
95 var callbacks = this._callbacks['$' + event];
96 if (!callbacks) return this;
97
98 // remove all handlers
99 if (1 == arguments.length) {
100 delete this._callbacks['$' + event];
101 return this;
102 }
103
104 // remove specific handler
105 var cb;
106 for (var i = 0; i < callbacks.length; i++) {
107 cb = callbacks[i];
108 if (cb === fn || cb.fn === fn) {
109 callbacks.splice(i, 1);
110 break;
111 }
112 }
113 return this;
114};
115
116/**
117 * Emit `event` with the given args.
118 *
119 * @param {String} event
120 * @param {Mixed} ...
121 * @return {Emitter}
122 */
123
124Emitter.prototype.emit = function(event){
125 this._callbacks = this._callbacks || {};
126 var args = [].slice.call(arguments, 1)
127 , callbacks = this._callbacks['$' + event];
128
129 if (callbacks) {
130 callbacks = callbacks.slice(0);
131 for (var i = 0, len = callbacks.length; i < len; ++i) {
132 callbacks[i].apply(this, args);
133 }
134 }
135
136 return this;
137};
138
139/**
140 * Return array of callbacks for `event`.
141 *
142 * @param {String} event
143 * @return {Array}
144 * @api public
145 */
146
147Emitter.prototype.listeners = function(event){
148 this._callbacks = this._callbacks || {};
149 return this._callbacks['$' + event] || [];
150};
151
152/**
153 * Check if this emitter has `event` handlers.
154 *
155 * @param {String} event
156 * @return {Boolean}
157 * @api public
158 */
159
160Emitter.prototype.hasListeners = function(event){
161 return !! this.listeners(event).length;
162};
163
164},{}],2:[function(require,module,exports){
165
166/**
167 * Reduce `arr` with `fn`.
168 *
169 * @param {Array} arr
170 * @param {Function} fn
171 * @param {Mixed} initial
172 *
173 * TODO: combatible error handling?
174 */
175
176module.exports = function(arr, fn, initial){
177 var idx = 0;
178 var len = arr.length;
179 var curr = arguments.length == 3
180 ? initial
181 : arr[idx++];
182
183 while (idx < len) {
184 curr = fn.call(null, curr, arr[idx], ++idx, arr);
185 }
186
187 return curr;
188};
189},{}],3:[function(require,module,exports){
190/**
191 * Module dependencies.
192 */
193
194var Emitter = require('emitter');
195var reduce = require('reduce');
196
197/**
198 * Root reference for iframes.
199 */
200
201var root;
202if (typeof window !== 'undefined') { // Browser window
203 root = window;
204} else if (typeof self !== 'undefined') { // Web Worker
205 root = self;
206} else { // Other environments
207 root = this;
208}
209
210/**
211 * Noop.
212 */
213
214function noop(){};
215
216/**
217 * Check if `obj` is a host object,
218 * we don't want to serialize these :)
219 *
220 * TODO: future proof, move to compoent land
221 *
222 * @param {Object} obj
223 * @return {Boolean}
224 * @api private
225 */
226
227function isHost(obj) {
228 var str = {}.toString.call(obj);
229
230 switch (str) {
231 case '[object File]':
232 case '[object Blob]':
233 case '[object FormData]':
234 return true;
235 default:
236 return false;
237 }
238}
239
240/**
241 * Determine XHR.
242 */
243
244request.getXHR = function () {
245 if (root.XMLHttpRequest
246 && (!root.location || 'file:' != root.location.protocol
247 || !root.ActiveXObject)) {
248 return new XMLHttpRequest;
249 } else {
250 try { return new ActiveXObject('Microsoft.XMLHTTP'); } catch(e) {}
251 try { return new ActiveXObject('Msxml2.XMLHTTP.6.0'); } catch(e) {}
252 try { return new ActiveXObject('Msxml2.XMLHTTP.3.0'); } catch(e) {}
253 try { return new ActiveXObject('Msxml2.XMLHTTP'); } catch(e) {}
254 }
255 return false;
256};
257
258/**
259 * Removes leading and trailing whitespace, added to support IE.
260 *
261 * @param {String} s
262 * @return {String}
263 * @api private
264 */
265
266var trim = ''.trim
267 ? function(s) { return s.trim(); }
268 : function(s) { return s.replace(/(^\s*|\s*$)/g, ''); };
269
270/**
271 * Check if `obj` is an object.
272 *
273 * @param {Object} obj
274 * @return {Boolean}
275 * @api private
276 */
277
278function isObject(obj) {
279 return obj === Object(obj);
280}
281
282/**
283 * Serialize the given `obj`.
284 *
285 * @param {Object} obj
286 * @return {String}
287 * @api private
288 */
289
290function serialize(obj) {
291 if (!isObject(obj)) return obj;
292 var pairs = [];
293 for (var key in obj) {
294 if (null != obj[key]) {
295 pushEncodedKeyValuePair(pairs, key, obj[key]);
296 }
297 }
298 return pairs.join('&');
299}
300
301/**
302 * Helps 'serialize' with serializing arrays.
303 * Mutates the pairs array.
304 *
305 * @param {Array} pairs
306 * @param {String} key
307 * @param {Mixed} val
308 */
309
310function pushEncodedKeyValuePair(pairs, key, val) {
311 if (Array.isArray(val)) {
312 return val.forEach(function(v) {
313 pushEncodedKeyValuePair(pairs, key, v);
314 });
315 }
316 pairs.push(encodeURIComponent(key)
317 + '=' + encodeURIComponent(val));
318}
319
320/**
321 * Expose serialization method.
322 */
323
324 request.serializeObject = serialize;
325
326 /**
327 * Parse the given x-www-form-urlencoded `str`.
328 *
329 * @param {String} str
330 * @return {Object}
331 * @api private
332 */
333
334function parseString(str) {
335 var obj = {};
336 var pairs = str.split('&');
337 var parts;
338 var pair;
339
340 for (var i = 0, len = pairs.length; i < len; ++i) {
341 pair = pairs[i];
342 parts = pair.split('=');
343 obj[decodeURIComponent(parts[0])] = decodeURIComponent(parts[1]);
344 }
345
346 return obj;
347}
348
349/**
350 * Expose parser.
351 */
352
353request.parseString = parseString;
354
355/**
356 * Default MIME type map.
357 *
358 * superagent.types.xml = 'application/xml';
359 *
360 */
361
362request.types = {
363 html: 'text/html',
364 json: 'application/json',
365 xml: 'application/xml',
366 urlencoded: 'application/x-www-form-urlencoded',
367 'form': 'application/x-www-form-urlencoded',
368 'form-data': 'application/x-www-form-urlencoded'
369};
370
371/**
372 * Default serialization map.
373 *
374 * superagent.serialize['application/xml'] = function(obj){
375 * return 'generated xml here';
376 * };
377 *
378 */
379
380 request.serialize = {
381 'application/x-www-form-urlencoded': serialize,
382 'application/json': JSON.stringify
383 };
384
385 /**
386 * Default parsers.
387 *
388 * superagent.parse['application/xml'] = function(str){
389 * return { object parsed from str };
390 * };
391 *
392 */
393
394request.parse = {
395 'application/x-www-form-urlencoded': parseString,
396 'application/json': JSON.parse
397};
398
399/**
400 * Parse the given header `str` into
401 * an object containing the mapped fields.
402 *
403 * @param {String} str
404 * @return {Object}
405 * @api private
406 */
407
408function parseHeader(str) {
409 var lines = str.split(/\r?\n/);
410 var fields = {};
411 var index;
412 var line;
413 var field;
414 var val;
415
416 lines.pop(); // trailing CRLF
417
418 for (var i = 0, len = lines.length; i < len; ++i) {
419 line = lines[i];
420 index = line.indexOf(':');
421 field = line.slice(0, index).toLowerCase();
422 val = trim(line.slice(index + 1));
423 fields[field] = val;
424 }
425
426 return fields;
427}
428
429/**
430 * Check if `mime` is json or has +json structured syntax suffix.
431 *
432 * @param {String} mime
433 * @return {Boolean}
434 * @api private
435 */
436
437function isJSON(mime) {
438 return /[\/+]json\b/.test(mime);
439}
440
441/**
442 * Return the mime type for the given `str`.
443 *
444 * @param {String} str
445 * @return {String}
446 * @api private
447 */
448
449function type(str){
450 return str.split(/ *; */).shift();
451};
452
453/**
454 * Return header field parameters.
455 *
456 * @param {String} str
457 * @return {Object}
458 * @api private
459 */
460
461function params(str){
462 return reduce(str.split(/ *; */), function(obj, str){
463 var parts = str.split(/ *= */)
464 , key = parts.shift()
465 , val = parts.shift();
466
467 if (key && val) obj[key] = val;
468 return obj;
469 }, {});
470};
471
472/**
473 * Initialize a new `Response` with the given `xhr`.
474 *
475 * - set flags (.ok, .error, etc)
476 * - parse header
477 *
478 * Examples:
479 *
480 * Aliasing `superagent` as `request` is nice:
481 *
482 * request = superagent;
483 *
484 * We can use the promise-like API, or pass callbacks:
485 *
486 * request.get('/').end(function(res){});
487 * request.get('/', function(res){});
488 *
489 * Sending data can be chained:
490 *
491 * request
492 * .post('/user')
493 * .send({ name: 'tj' })
494 * .end(function(res){});
495 *
496 * Or passed to `.send()`:
497 *
498 * request
499 * .post('/user')
500 * .send({ name: 'tj' }, function(res){});
501 *
502 * Or passed to `.post()`:
503 *
504 * request
505 * .post('/user', { name: 'tj' })
506 * .end(function(res){});
507 *
508 * Or further reduced to a single call for simple cases:
509 *
510 * request
511 * .post('/user', { name: 'tj' }, function(res){});
512 *
513 * @param {XMLHTTPRequest} xhr
514 * @param {Object} options
515 * @api private
516 */
517
518function Response(req, options) {
519 options = options || {};
520 this.req = req;
521 this.xhr = this.req.xhr;
522 // responseText is accessible only if responseType is '' or 'text' and on older browsers
523 this.text = ((this.req.method !='HEAD' && (this.xhr.responseType === '' || this.xhr.responseType === 'text')) || typeof this.xhr.responseType === 'undefined')
524 ? this.xhr.responseText
525 : null;
526 this.statusText = this.req.xhr.statusText;
527 this.setStatusProperties(this.xhr.status);
528 this.header = this.headers = parseHeader(this.xhr.getAllResponseHeaders());
529 // getAllResponseHeaders sometimes falsely returns "" for CORS requests, but
530 // getResponseHeader still works. so we get content-type even if getting
531 // other headers fails.
532 this.header['content-type'] = this.xhr.getResponseHeader('content-type');
533 this.setHeaderProperties(this.header);
534 this.body = this.req.method != 'HEAD'
535 ? this.parseBody(this.text ? this.text : this.xhr.response)
536 : null;
537}
538
539/**
540 * Get case-insensitive `field` value.
541 *
542 * @param {String} field
543 * @return {String}
544 * @api public
545 */
546
547Response.prototype.get = function(field){
548 return this.header[field.toLowerCase()];
549};
550
551/**
552 * Set header related properties:
553 *
554 * - `.type` the content type without params
555 *
556 * A response of "Content-Type: text/plain; charset=utf-8"
557 * will provide you with a `.type` of "text/plain".
558 *
559 * @param {Object} header
560 * @api private
561 */
562
563Response.prototype.setHeaderProperties = function(header){
564 // content-type
565 var ct = this.header['content-type'] || '';
566 this.type = type(ct);
567
568 // params
569 var obj = params(ct);
570 for (var key in obj) this[key] = obj[key];
571};
572
573/**
574 * Parse the given body `str`.
575 *
576 * Used for auto-parsing of bodies. Parsers
577 * are defined on the `superagent.parse` object.
578 *
579 * @param {String} str
580 * @return {Mixed}
581 * @api private
582 */
583
584Response.prototype.parseBody = function(str){
585 var parse = request.parse[this.type];
586 return parse && str && (str.length || str instanceof Object)
587 ? parse(str)
588 : null;
589};
590
591/**
592 * Set flags such as `.ok` based on `status`.
593 *
594 * For example a 2xx response will give you a `.ok` of __true__
595 * whereas 5xx will be __false__ and `.error` will be __true__. The
596 * `.clientError` and `.serverError` are also available to be more
597 * specific, and `.statusType` is the class of error ranging from 1..5
598 * sometimes useful for mapping respond colors etc.
599 *
600 * "sugar" properties are also defined for common cases. Currently providing:
601 *
602 * - .noContent
603 * - .badRequest
604 * - .unauthorized
605 * - .notAcceptable
606 * - .notFound
607 *
608 * @param {Number} status
609 * @api private
610 */
611
612Response.prototype.setStatusProperties = function(status){
613 // handle IE9 bug: http://stackoverflow.com/questions/10046972/msie-returns-status-code-of-1223-for-ajax-request
614 if (status === 1223) {
615 status = 204;
616 }
617
618 var type = status / 100 | 0;
619
620 // status / class
621 this.status = this.statusCode = status;
622 this.statusType = type;
623
624 // basics
625 this.info = 1 == type;
626 this.ok = 2 == type;
627 this.clientError = 4 == type;
628 this.serverError = 5 == type;
629 this.error = (4 == type || 5 == type)
630 ? this.toError()
631 : false;
632
633 // sugar
634 this.accepted = 202 == status;
635 this.noContent = 204 == status;
636 this.badRequest = 400 == status;
637 this.unauthorized = 401 == status;
638 this.notAcceptable = 406 == status;
639 this.notFound = 404 == status;
640 this.forbidden = 403 == status;
641};
642
643/**
644 * Return an `Error` representative of this response.
645 *
646 * @return {Error}
647 * @api public
648 */
649
650Response.prototype.toError = function(){
651 var req = this.req;
652 var method = req.method;
653 var url = req.url;
654
655 var msg = 'cannot ' + method + ' ' + url + ' (' + this.status + ')';
656 var err = new Error(msg);
657 err.status = this.status;
658 err.method = method;
659 err.url = url;
660
661 return err;
662};
663
664/**
665 * Expose `Response`.
666 */
667
668request.Response = Response;
669
670/**
671 * Initialize a new `Request` with the given `method` and `url`.
672 *
673 * @param {String} method
674 * @param {String} url
675 * @api public
676 */
677
678function Request(method, url) {
679 var self = this;
680 Emitter.call(this);
681 this._query = this._query || [];
682 this.method = method;
683 this.url = url;
684 this.header = {};
685 this._header = {};
686 this.on('end', function(){
687 var err = null;
688 var res = null;
689
690 try {
691 res = new Response(self);
692 } catch(e) {
693 err = new Error('Parser is unable to parse the response');
694 err.parse = true;
695 err.original = e;
696 // issue #675: return the raw response if the response parsing fails
697 err.rawResponse = self.xhr && self.xhr.responseText ? self.xhr.responseText : null;
698 return self.callback(err);
699 }
700
701 self.emit('response', res);
702
703 if (err) {
704 return self.callback(err, res);
705 }
706
707 if (res.status >= 200 && res.status < 300) {
708 return self.callback(err, res);
709 }
710
711 var new_err = new Error(res.statusText || 'Unsuccessful HTTP response');
712 new_err.original = err;
713 new_err.response = res;
714 new_err.status = res.status;
715
716 self.callback(new_err, res);
717 });
718}
719
720/**
721 * Mixin `Emitter`.
722 */
723
724Emitter(Request.prototype);
725
726/**
727 * Allow for extension
728 */
729
730Request.prototype.use = function(fn) {
731 fn(this);
732 return this;
733}
734
735/**
736 * Set timeout to `ms`.
737 *
738 * @param {Number} ms
739 * @return {Request} for chaining
740 * @api public
741 */
742
743Request.prototype.timeout = function(ms){
744 this._timeout = ms;
745 return this;
746};
747
748/**
749 * Clear previous timeout.
750 *
751 * @return {Request} for chaining
752 * @api public
753 */
754
755Request.prototype.clearTimeout = function(){
756 this._timeout = 0;
757 clearTimeout(this._timer);
758 return this;
759};
760
761/**
762 * Abort the request, and clear potential timeout.
763 *
764 * @return {Request}
765 * @api public
766 */
767
768Request.prototype.abort = function(){
769 if (this.aborted) return;
770 this.aborted = true;
771 this.xhr.abort();
772 this.clearTimeout();
773 this.emit('abort');
774 return this;
775};
776
777/**
778 * Set header `field` to `val`, or multiple fields with one object.
779 *
780 * Examples:
781 *
782 * req.get('/')
783 * .set('Accept', 'application/json')
784 * .set('X-API-Key', 'foobar')
785 * .end(callback);
786 *
787 * req.get('/')
788 * .set({ Accept: 'application/json', 'X-API-Key': 'foobar' })
789 * .end(callback);
790 *
791 * @param {String|Object} field
792 * @param {String} val
793 * @return {Request} for chaining
794 * @api public
795 */
796
797Request.prototype.set = function(field, val){
798 if (isObject(field)) {
799 for (var key in field) {
800 this.set(key, field[key]);
801 }
802 return this;
803 }
804 this._header[field.toLowerCase()] = val;
805 this.header[field] = val;
806 return this;
807};
808
809/**
810 * Remove header `field`.
811 *
812 * Example:
813 *
814 * req.get('/')
815 * .unset('User-Agent')
816 * .end(callback);
817 *
818 * @param {String} field
819 * @return {Request} for chaining
820 * @api public
821 */
822
823Request.prototype.unset = function(field){
824 delete this._header[field.toLowerCase()];
825 delete this.header[field];
826 return this;
827};
828
829/**
830 * Get case-insensitive header `field` value.
831 *
832 * @param {String} field
833 * @return {String}
834 * @api private
835 */
836
837Request.prototype.getHeader = function(field){
838 return this._header[field.toLowerCase()];
839};
840
841/**
842 * Set Content-Type to `type`, mapping values from `request.types`.
843 *
844 * Examples:
845 *
846 * superagent.types.xml = 'application/xml';
847 *
848 * request.post('/')
849 * .type('xml')
850 * .send(xmlstring)
851 * .end(callback);
852 *
853 * request.post('/')
854 * .type('application/xml')
855 * .send(xmlstring)
856 * .end(callback);
857 *
858 * @param {String} type
859 * @return {Request} for chaining
860 * @api public
861 */
862
863Request.prototype.type = function(type){
864 this.set('Content-Type', request.types[type] || type);
865 return this;
866};
867
868/**
869 * Force given parser
870 *
871 * Sets the body parser no matter type.
872 *
873 * @param {Function}
874 * @api public
875 */
876
877Request.prototype.parse = function(fn){
878 this._parser = fn;
879 return this;
880};
881
882/**
883 * Set Accept to `type`, mapping values from `request.types`.
884 *
885 * Examples:
886 *
887 * superagent.types.json = 'application/json';
888 *
889 * request.get('/agent')
890 * .accept('json')
891 * .end(callback);
892 *
893 * request.get('/agent')
894 * .accept('application/json')
895 * .end(callback);
896 *
897 * @param {String} accept
898 * @return {Request} for chaining
899 * @api public
900 */
901
902Request.prototype.accept = function(type){
903 this.set('Accept', request.types[type] || type);
904 return this;
905};
906
907/**
908 * Set Authorization field value with `user` and `pass`.
909 *
910 * @param {String} user
911 * @param {String} pass
912 * @return {Request} for chaining
913 * @api public
914 */
915
916Request.prototype.auth = function(user, pass){
917 var str = btoa(user + ':' + pass);
918 this.set('Authorization', 'Basic ' + str);
919 return this;
920};
921
922/**
923* Add query-string `val`.
924*
925* Examples:
926*
927* request.get('/shoes')
928* .query('size=10')
929* .query({ color: 'blue' })
930*
931* @param {Object|String} val
932* @return {Request} for chaining
933* @api public
934*/
935
936Request.prototype.query = function(val){
937 if ('string' != typeof val) val = serialize(val);
938 if (val) this._query.push(val);
939 return this;
940};
941
942/**
943 * Write the field `name` and `val` for "multipart/form-data"
944 * request bodies.
945 *
946 * ``` js
947 * request.post('/upload')
948 * .field('foo', 'bar')
949 * .end(callback);
950 * ```
951 *
952 * @param {String} name
953 * @param {String|Blob|File} val
954 * @return {Request} for chaining
955 * @api public
956 */
957
958Request.prototype.field = function(name, val){
959 if (!this._formData) this._formData = new root.FormData();
960 this._formData.append(name, val);
961 return this;
962};
963
964/**
965 * Queue the given `file` as an attachment to the specified `field`,
966 * with optional `filename`.
967 *
968 * ``` js
969 * request.post('/upload')
970 * .attach(new Blob(['<a id="a"><b id="b">hey!</b></a>'], { type: "text/html"}))
971 * .end(callback);
972 * ```
973 *
974 * @param {String} field
975 * @param {Blob|File} file
976 * @param {String} filename
977 * @return {Request} for chaining
978 * @api public
979 */
980
981Request.prototype.attach = function(field, file, filename){
982 if (!this._formData) this._formData = new root.FormData();
983 this._formData.append(field, file, filename || file.name);
984 return this;
985};
986
987/**
988 * Send `data` as the request body, defaulting the `.type()` to "json" when
989 * an object is given.
990 *
991 * Examples:
992 *
993 * // manual json
994 * request.post('/user')
995 * .type('json')
996 * .send('{"name":"tj"}')
997 * .end(callback)
998 *
999 * // auto json
1000 * request.post('/user')
1001 * .send({ name: 'tj' })
1002 * .end(callback)
1003 *
1004 * // manual x-www-form-urlencoded
1005 * request.post('/user')
1006 * .type('form')
1007 * .send('name=tj')
1008 * .end(callback)
1009 *
1010 * // auto x-www-form-urlencoded
1011 * request.post('/user')
1012 * .type('form')
1013 * .send({ name: 'tj' })
1014 * .end(callback)
1015 *
1016 * // defaults to x-www-form-urlencoded
1017 * request.post('/user')
1018 * .send('name=tobi')
1019 * .send('species=ferret')
1020 * .end(callback)
1021 *
1022 * @param {String|Object} data
1023 * @return {Request} for chaining
1024 * @api public
1025 */
1026
1027Request.prototype.send = function(data){
1028 var obj = isObject(data);
1029 var type = this.getHeader('Content-Type');
1030
1031 // merge
1032 if (obj && isObject(this._data)) {
1033 for (var key in data) {
1034 this._data[key] = data[key];
1035 }
1036 } else if ('string' == typeof data) {
1037 if (!type) this.type('form');
1038 type = this.getHeader('Content-Type');
1039 if ('application/x-www-form-urlencoded' == type) {
1040 this._data = this._data
1041 ? this._data + '&' + data
1042 : data;
1043 } else {
1044 this._data = (this._data || '') + data;
1045 }
1046 } else {
1047 this._data = data;
1048 }
1049
1050 if (!obj || isHost(data)) return this;
1051 if (!type) this.type('json');
1052 return this;
1053};
1054
1055/**
1056 * Invoke the callback with `err` and `res`
1057 * and handle arity check.
1058 *
1059 * @param {Error} err
1060 * @param {Response} res
1061 * @api private
1062 */
1063
1064Request.prototype.callback = function(err, res){
1065 var fn = this._callback;
1066 this.clearTimeout();
1067 fn(err, res);
1068};
1069
1070/**
1071 * Invoke callback with x-domain error.
1072 *
1073 * @api private
1074 */
1075
1076Request.prototype.crossDomainError = function(){
1077 var err = new Error('Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.');
1078 err.crossDomain = true;
1079
1080 err.status = this.status;
1081 err.method = this.method;
1082 err.url = this.url;
1083
1084 this.callback(err);
1085};
1086
1087/**
1088 * Invoke callback with timeout error.
1089 *
1090 * @api private
1091 */
1092
1093Request.prototype.timeoutError = function(){
1094 var timeout = this._timeout;
1095 var err = new Error('timeout of ' + timeout + 'ms exceeded');
1096 err.timeout = timeout;
1097 this.callback(err);
1098};
1099
1100/**
1101 * Enable transmission of cookies with x-domain requests.
1102 *
1103 * Note that for this to work the origin must not be
1104 * using "Access-Control-Allow-Origin" with a wildcard,
1105 * and also must set "Access-Control-Allow-Credentials"
1106 * to "true".
1107 *
1108 * @api public
1109 */
1110
1111Request.prototype.withCredentials = function(){
1112 this._withCredentials = true;
1113 return this;
1114};
1115
1116/**
1117 * Initiate request, invoking callback `fn(res)`
1118 * with an instanceof `Response`.
1119 *
1120 * @param {Function} fn
1121 * @return {Request} for chaining
1122 * @api public
1123 */
1124
1125Request.prototype.end = function(fn){
1126 var self = this;
1127 var xhr = this.xhr = request.getXHR();
1128 var query = this._query.join('&');
1129 var timeout = this._timeout;
1130 var data = this._formData || this._data;
1131
1132 // store callback
1133 this._callback = fn || noop;
1134
1135 // state change
1136 xhr.onreadystatechange = function(){
1137 if (4 != xhr.readyState) return;
1138
1139 // In IE9, reads to any property (e.g. status) off of an aborted XHR will
1140 // result in the error "Could not complete the operation due to error c00c023f"
1141 var status;
1142 try { status = xhr.status } catch(e) { status = 0; }
1143
1144 if (0 == status) {
1145 if (self.timedout) return self.timeoutError();
1146 if (self.aborted) return;
1147 return self.crossDomainError();
1148 }
1149 self.emit('end');
1150 };
1151
1152 // progress
1153 var handleProgress = function(e){
1154 if (e.total > 0) {
1155 e.percent = e.loaded / e.total * 100;
1156 }
1157 e.direction = 'download';
1158 self.emit('progress', e);
1159 };
1160 if (this.hasListeners('progress')) {
1161 xhr.onprogress = handleProgress;
1162 }
1163 try {
1164 if (xhr.upload && this.hasListeners('progress')) {
1165 xhr.upload.onprogress = handleProgress;
1166 }
1167 } catch(e) {
1168 // Accessing xhr.upload fails in IE from a web worker, so just pretend it doesn't exist.
1169 // Reported here:
1170 // https://connect.microsoft.com/IE/feedback/details/837245/xmlhttprequest-upload-throws-invalid-argument-when-used-from-web-worker-context
1171 }
1172
1173 // timeout
1174 if (timeout && !this._timer) {
1175 this._timer = setTimeout(function(){
1176 self.timedout = true;
1177 self.abort();
1178 }, timeout);
1179 }
1180
1181 // querystring
1182 if (query) {
1183 query = request.serializeObject(query);
1184 this.url += ~this.url.indexOf('?')
1185 ? '&' + query
1186 : '?' + query;
1187 }
1188
1189 // initiate request
1190 xhr.open(this.method, this.url, true);
1191
1192 // CORS
1193 if (this._withCredentials) xhr.withCredentials = true;
1194
1195 // body
1196 if ('GET' != this.method && 'HEAD' != this.method && 'string' != typeof data && !isHost(data)) {
1197 // serialize stuff
1198 var contentType = this.getHeader('Content-Type');
1199 var serialize = this._parser || request.serialize[contentType ? contentType.split(';')[0] : ''];
1200 if (!serialize && isJSON(contentType)) serialize = request.serialize['application/json'];
1201 if (serialize) data = serialize(data);
1202 }
1203
1204 // set header fields
1205 for (var field in this.header) {
1206 if (null == this.header[field]) continue;
1207 xhr.setRequestHeader(field, this.header[field]);
1208 }
1209
1210 // send stuff
1211 this.emit('request', this);
1212
1213 // IE11 xhr.send(undefined) sends 'undefined' string as POST payload (instead of nothing)
1214 // We need null here if data is undefined
1215 xhr.send(typeof data !== 'undefined' ? data : null);
1216 return this;
1217};
1218
1219/**
1220 * Faux promise support
1221 *
1222 * @param {Function} fulfill
1223 * @param {Function} reject
1224 * @return {Request}
1225 */
1226
1227Request.prototype.then = function (fulfill, reject) {
1228 return this.end(function(err, res) {
1229 err ? reject(err) : fulfill(res);
1230 });
1231}
1232
1233/**
1234 * Expose `Request`.
1235 */
1236
1237request.Request = Request;
1238
1239/**
1240 * Issue a request:
1241 *
1242 * Examples:
1243 *
1244 * request('GET', '/users').end(callback)
1245 * request('/users').end(callback)
1246 * request('/users', callback)
1247 *
1248 * @param {String} method
1249 * @param {String|Function} url or callback
1250 * @return {Request}
1251 * @api public
1252 */
1253
1254function request(method, url) {
1255 // callback
1256 if ('function' == typeof url) {
1257 return new Request('GET', method).end(url);
1258 }
1259
1260 // url first
1261 if (1 == arguments.length) {
1262 return new Request('GET', method);
1263 }
1264
1265 return new Request(method, url);
1266}
1267
1268/**
1269 * GET `url` with optional callback `fn(res)`.
1270 *
1271 * @param {String} url
1272 * @param {Mixed|Function} data or fn
1273 * @param {Function} fn
1274 * @return {Request}
1275 * @api public
1276 */
1277
1278request.get = function(url, data, fn){
1279 var req = request('GET', url);
1280 if ('function' == typeof data) fn = data, data = null;
1281 if (data) req.query(data);
1282 if (fn) req.end(fn);
1283 return req;
1284};
1285
1286/**
1287 * HEAD `url` with optional callback `fn(res)`.
1288 *
1289 * @param {String} url
1290 * @param {Mixed|Function} data or fn
1291 * @param {Function} fn
1292 * @return {Request}
1293 * @api public
1294 */
1295
1296request.head = function(url, data, fn){
1297 var req = request('HEAD', url);
1298 if ('function' == typeof data) fn = data, data = null;
1299 if (data) req.send(data);
1300 if (fn) req.end(fn);
1301 return req;
1302};
1303
1304/**
1305 * DELETE `url` with optional callback `fn(res)`.
1306 *
1307 * @param {String} url
1308 * @param {Function} fn
1309 * @return {Request}
1310 * @api public
1311 */
1312
1313function del(url, fn){
1314 var req = request('DELETE', url);
1315 if (fn) req.end(fn);
1316 return req;
1317};
1318
1319request['del'] = del;
1320request['delete'] = del;
1321
1322/**
1323 * PATCH `url` with optional `data` and callback `fn(res)`.
1324 *
1325 * @param {String} url
1326 * @param {Mixed} data
1327 * @param {Function} fn
1328 * @return {Request}
1329 * @api public
1330 */
1331
1332request.patch = function(url, data, fn){
1333 var req = request('PATCH', url);
1334 if ('function' == typeof data) fn = data, data = null;
1335 if (data) req.send(data);
1336 if (fn) req.end(fn);
1337 return req;
1338};
1339
1340/**
1341 * POST `url` with optional `data` and callback `fn(res)`.
1342 *
1343 * @param {String} url
1344 * @param {Mixed} data
1345 * @param {Function} fn
1346 * @return {Request}
1347 * @api public
1348 */
1349
1350request.post = function(url, data, fn){
1351 var req = request('POST', url);
1352 if ('function' == typeof data) fn = data, data = null;
1353 if (data) req.send(data);
1354 if (fn) req.end(fn);
1355 return req;
1356};
1357
1358/**
1359 * PUT `url` with optional `data` and callback `fn(res)`.
1360 *
1361 * @param {String} url
1362 * @param {Mixed|Function} data or fn
1363 * @param {Function} fn
1364 * @return {Request}
1365 * @api public
1366 */
1367
1368request.put = function(url, data, fn){
1369 var req = request('PUT', url);
1370 if ('function' == typeof data) fn = data, data = null;
1371 if (data) req.send(data);
1372 if (fn) req.end(fn);
1373 return req;
1374};
1375
1376/**
1377 * Expose `request`.
1378 */
1379
1380module.exports = request;
1381
1382},{"emitter":1,"reduce":2}]},{},[3])(3)
1383}); \ No newline at end of file
diff --git a/frontend/js/vue.min.js b/frontend/js/vue.min.js
new file mode 100644
index 0000000..83ebfd7
--- /dev/null
+++ b/frontend/js/vue.min.js
@@ -0,0 +1,8 @@
1/*!
2 * Vue.js v1.0.17
3 * (c) 2016 Evan You
4 * Released under the MIT License.
5 */
6!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.Vue=e()}(this,function(){"use strict";function t(e,n,r){if(i(e,n))return void(e[n]=r);if(e._isVue)return void t(e._data,n,r);var s=e.__ob__;if(!s)return void(e[n]=r);if(s.convert(n,r),s.dep.notify(),s.vms)for(var o=s.vms.length;o--;){var a=s.vms[o];a._proxy(n),a._digest()}return r}function e(t,e){if(i(t,e)){delete t[e];var n=t.__ob__;if(n&&(n.dep.notify(),n.vms))for(var r=n.vms.length;r--;){var s=n.vms[r];s._unproxy(e),s._digest()}}}function i(t,e){return yi.call(t,e)}function n(t){return Ci.test(t)}function r(t){var e=(t+"").charCodeAt(0);return 36===e||95===e}function s(t){return null==t?"":t.toString()}function o(t){if("string"!=typeof t)return t;var e=Number(t);return isNaN(e)?t:e}function a(t){return"true"===t?!0:"false"===t?!1:t}function h(t){var e=t.charCodeAt(0),i=t.charCodeAt(t.length-1);return e!==i||34!==e&&39!==e?t:t.slice(1,-1)}function l(t){return t.replace(wi,c)}function c(t,e){return e?e.toUpperCase():""}function u(t){return t.replace($i,"$1-$2").toLowerCase()}function f(t){return t.replace(ki,c)}function p(t,e){return function(i){var n=arguments.length;return n?n>1?t.apply(e,arguments):t.call(e,i):t.call(e)}}function d(t,e){e=e||0;for(var i=t.length-e,n=new Array(i);i--;)n[i]=t[i+e];return n}function v(t,e){for(var i=Object.keys(e),n=i.length;n--;)t[i[n]]=e[i[n]];return t}function m(t){return null!==t&&"object"==typeof t}function g(t){return xi.call(t)===Ai}function _(t,e,i,n){Object.defineProperty(t,e,{value:i,enumerable:!!n,writable:!0,configurable:!0})}function b(t,e){var i,n,r,s,o,a=function h(){var a=Date.now()-s;e>a&&a>=0?i=setTimeout(h,e-a):(i=null,o=t.apply(r,n),i||(r=n=null))};return function(){return r=this,n=arguments,s=Date.now(),i||(i=setTimeout(a,e)),o}}function y(t,e){for(var i=t.length;i--;)if(t[i]===e)return i;return-1}function C(t){var e=function i(){return i.cancelled?void 0:t.apply(this,arguments)};return e.cancel=function(){e.cancelled=!0},e}function w(t,e){return t==e||(m(t)&&m(e)?JSON.stringify(t)===JSON.stringify(e):!1)}function $(t){this.size=0,this.limit=t,this.head=this.tail=void 0,this._keymap=Object.create(null)}function k(){var t,e=Vi.slice(Qi,qi).trim();if(e){t={};var i=e.match(en);t.name=i[0],i.length>1&&(t.args=i.slice(1).map(x))}t&&(zi.filters=zi.filters||[]).push(t),Qi=qi+1}function x(t){if(nn.test(t))return{value:o(t),dynamic:!1};var e=h(t),i=e===t;return{value:i?t:e,dynamic:i}}function A(t){var e=tn.get(t);if(e)return e;for(Vi=t,Gi=Ki=!1,Zi=Xi=Yi=0,Qi=0,zi={},qi=0,Ji=Vi.length;Ji>qi;qi++)if(Ui=Ii,Ii=Vi.charCodeAt(qi),Gi)39===Ii&&92!==Ui&&(Gi=!Gi);else if(Ki)34===Ii&&92!==Ui&&(Ki=!Ki);else if(124===Ii&&124!==Vi.charCodeAt(qi+1)&&124!==Vi.charCodeAt(qi-1))null==zi.expression?(Qi=qi+1,zi.expression=Vi.slice(0,qi).trim()):k();else switch(Ii){case 34:Ki=!0;break;case 39:Gi=!0;break;case 40:Yi++;break;case 41:Yi--;break;case 91:Xi++;break;case 93:Xi--;break;case 123:Zi++;break;case 125:Zi--}return null==zi.expression?zi.expression=Vi.slice(0,qi).trim():0!==Qi&&k(),tn.put(t,zi),zi}function O(t){return t.replace(sn,"\\$&")}function T(){var t=O(pn.delimiters[0]),e=O(pn.delimiters[1]),i=O(pn.unsafeDelimiters[0]),n=O(pn.unsafeDelimiters[1]);an=new RegExp(i+"(.+?)"+n+"|"+t+"(.+?)"+e,"g"),hn=new RegExp("^"+i+".*"+n+"$"),on=new $(1e3)}function N(t){on||T();var e=on.get(t);if(e)return e;if(t=t.replace(/\n/g,""),!an.test(t))return null;for(var i,n,r,s,o,a,h=[],l=an.lastIndex=0;i=an.exec(t);)n=i.index,n>l&&h.push({value:t.slice(l,n)}),r=hn.test(i[0]),s=r?i[1]:i[2],o=s.charCodeAt(0),a=42===o,s=a?s.slice(1):s,h.push({tag:!0,value:s.trim(),html:r,oneTime:a}),l=n+i[0].length;return l<t.length&&h.push({value:t.slice(l)}),on.put(t,h),h}function j(t,e){return t.length>1?t.map(function(t){return E(t,e)}).join("+"):E(t[0],e,!0)}function E(t,e,i){return t.tag?t.oneTime&&e?'"'+e.$eval(t.value)+'"':S(t.value,i):'"'+t.value+'"'}function S(t,e){if(ln.test(t)){var i=A(t);return i.filters?"this._applyFilters("+i.expression+",null,"+JSON.stringify(i.filters)+",false)":"("+t+")"}return e?t:"("+t+")"}function F(t,e,i,n){R(t,1,function(){e.appendChild(t)},i,n)}function P(t,e,i,n){R(t,1,function(){V(t,e)},i,n)}function D(t,e,i){R(t,-1,function(){I(t)},e,i)}function R(t,e,i,n,r){var s=t.__v_trans;if(!s||!s.hooks&&!Di||!n._isCompiled||n.$parent&&!n.$parent._isCompiled)return i(),void(r&&r());var o=e>0?"enter":"leave";s[o](i,r)}function H(t){if("string"==typeof t){t=document.querySelector(t)}return t}function L(t){var e=document.documentElement,i=t&&t.parentNode;return e===t||e===i||!(!i||1!==i.nodeType||!e.contains(i))}function M(t,e){var i=t.getAttribute(e);return null!==i&&t.removeAttribute(e),i}function W(t,e){var i=M(t,":"+e);return null===i&&(i=M(t,"v-bind:"+e)),i}function B(t,e){return t.hasAttribute(e)||t.hasAttribute(":"+e)||t.hasAttribute("v-bind:"+e)}function V(t,e){e.parentNode.insertBefore(t,e)}function z(t,e){e.nextSibling?V(t,e.nextSibling):e.parentNode.appendChild(t)}function I(t){t.parentNode.removeChild(t)}function U(t,e){e.firstChild?V(t,e.firstChild):e.appendChild(t)}function q(t,e){var i=t.parentNode;i&&i.replaceChild(e,t)}function J(t,e,i,n){t.addEventListener(e,i,n)}function Q(t,e,i){t.removeEventListener(e,i)}function G(t,e){Si&&!/svg$/.test(t.namespaceURI)?t.className=e:t.setAttribute("class",e)}function K(t,e){if(t.classList)t.classList.add(e);else{var i=" "+(t.getAttribute("class")||"")+" ";i.indexOf(" "+e+" ")<0&&G(t,(i+e).trim())}}function Z(t,e){if(t.classList)t.classList.remove(e);else{for(var i=" "+(t.getAttribute("class")||"")+" ",n=" "+e+" ";i.indexOf(n)>=0;)i=i.replace(n," ");G(t,i.trim())}t.className||t.removeAttribute("class")}function X(t,e){var i,n;if(et(t)&&ot(t.content)&&(t=t.content),t.hasChildNodes())for(Y(t),n=e?document.createDocumentFragment():document.createElement("div");i=t.firstChild;)n.appendChild(i);return n}function Y(t){for(var e;e=t.firstChild,tt(e);)t.removeChild(e);for(;e=t.lastChild,tt(e);)t.removeChild(e)}function tt(t){return t&&(3===t.nodeType&&!t.data.trim()||8===t.nodeType)}function et(t){return t.tagName&&"template"===t.tagName.toLowerCase()}function it(t,e){var i=pn.debug?document.createComment(t):document.createTextNode(e?" ":"");return i.__v_anchor=!0,i}function nt(t){if(t.hasAttributes())for(var e=t.attributes,i=0,n=e.length;n>i;i++){var r=e[i].name;if(mn.test(r))return l(r.replace(mn,""))}}function rt(t,e,i){for(var n;t!==e;)n=t.nextSibling,i(t),t=n;i(e)}function st(t,e,i,n,r){function s(){if(a++,o&&a>=h.length){for(var t=0;t<h.length;t++)n.appendChild(h[t]);r&&r()}}var o=!1,a=0,h=[];rt(t,e,function(t){t===e&&(o=!0),h.push(t),D(t,i,s)})}function ot(t){return t&&11===t.nodeType}function at(t){if(t.outerHTML)return t.outerHTML;var e=document.createElement("div");return e.appendChild(t.cloneNode(!0)),e.innerHTML}function ht(t,e){var i=t.tagName.toLowerCase(),n=t.hasAttributes();if(gn.test(i)||_n.test(i)){if(n)return lt(t)}else{if(bt(e,"components",i))return{id:i};var r=n&&lt(t);if(r)return r}}function lt(t){var e=M(t,"is");return null!=e?{id:e}:(e=W(t,"is"),null!=e?{id:e,dynamic:!0}:void 0)}function ct(t,e,i){var n=e.path;i=ft(e,i),t[n]=t._data[n]=ut(e,i)?i:void 0}function ut(t,e){if(!t.options.required&&(null===t.raw||null==e))return!0;var i,n=t.options,r=n.type,s=!0;if(r&&(r===String?(i="string",s=typeof e===i):r===Number?(i="number",s="number"==typeof e):r===Boolean?(i="boolean",s="boolean"==typeof e):r===Function?(i="function",s="function"==typeof e):r===Object?(i="object",s=g(e)):r===Array?(i="array",s=Oi(e)):s=e instanceof r),!s)return!1;var o=n.validator;return!o||o(e)}function ft(t,e){var i=t.options.coerce;return i?i(e):e}function pt(e,n){var r,s,o;for(r in n)s=e[r],o=n[r],i(e,r)?m(s)&&m(o)&&pt(s,o):t(e,r,o);return e}function dt(t,e){var i=Object.create(t);return e?v(i,gt(e)):i}function vt(t){if(t.components)for(var e,i=t.components=gt(t.components),n=Object.keys(i),r=0,s=n.length;s>r;r++){var o=n[r];gn.test(o)||_n.test(o)||(e=i[o],g(e)&&(i[o]=di.extend(e)))}}function mt(t){var e,i,n=t.props;if(Oi(n))for(t.props={},e=n.length;e--;)i=n[e],"string"==typeof i?t.props[i]=null:i.name&&(t.props[i.name]=i);else if(g(n)){var r=Object.keys(n);for(e=r.length;e--;)i=n[r[e]],"function"==typeof i&&(n[r[e]]={type:i})}}function gt(t){if(Oi(t)){for(var e,i={},n=t.length;n--;){e=t[n];var r="function"==typeof e?e.options&&e.options.name||e.id:e.name||e.id;r&&(i[r]=e)}return i}return t}function _t(t,e,n){function r(i){var r=bn[i]||yn;o[i]=r(t[i],e[i],n,i)}vt(e),mt(e);var s,o={};if(e.mixins)for(var a=0,h=e.mixins.length;h>a;a++)t=_t(t,e.mixins[a],n);for(s in t)r(s);for(s in e)i(t,s)||r(s);return o}function bt(t,e,i){if("string"==typeof i){var n,r=t[e];return r[i]||r[n=l(i)]||r[n.charAt(0).toUpperCase()+n.slice(1)]}}function yt(t,e,i){}function Ct(){this.id=Cn++,this.subs=[]}function wt(t){if(this.value=t,this.dep=new Ct,_(t,"__ob__",this),Oi(t)){var e=Ti?$t:kt;e(t,$n,kn),this.observeArray(t)}else this.walk(t)}function $t(t,e){t.__proto__=e}function kt(t,e,i){for(var n=0,r=i.length;r>n;n++){var s=i[n];_(t,s,e[s])}}function xt(t,e){if(t&&"object"==typeof t){var n;return i(t,"__ob__")&&t.__ob__ instanceof wt?n=t.__ob__:(Oi(t)||g(t))&&Object.isExtensible(t)&&!t._isVue&&(n=new wt(t)),n&&e&&n.addVm(e),n}}function At(t,e,i){var n=new Ct,r=Object.getOwnPropertyDescriptor(t,e);if(!r||r.configurable!==!1){var s=r&&r.get,o=r&&r.set,a=xt(i);Object.defineProperty(t,e,{enumerable:!0,configurable:!0,get:function(){var e=s?s.call(t):i;if(Ct.target&&(n.depend(),a&&a.dep.depend(),Oi(e)))for(var r,o=0,h=e.length;h>o;o++)r=e[o],r&&r.__ob__&&r.__ob__.dep.depend();return e},set:function(e){var r=s?s.call(t):i;e!==r&&(o?o.call(t,e):i=e,a=xt(e),n.notify())}})}}function Ot(t){t.prototype._init=function(t){t=t||{},this.$el=null,this.$parent=t.parent,this.$root=this.$parent?this.$parent.$root:this,this.$children=[],this.$refs={},this.$els={},this._watchers=[],this._directives=[],this._uid=An++,this._isVue=!0,this._events={},this._eventsCount={},this._isFragment=!1,this._fragment=this._fragmentStart=this._fragmentEnd=null,this._isCompiled=this._isDestroyed=this._isReady=this._isAttached=this._isBeingDestroyed=this._vForRemoving=!1,this._unlinkFn=null,this._context=t._context||this.$parent,this._scope=t._scope,this._frag=t._frag,this._frag&&this._frag.children.push(this),this.$parent&&this.$parent.$children.push(this),t=this.$options=_t(this.constructor.options,t,this),this._updateRef(),this._data={},this._callHook("init"),this._initState(),this._initEvents(),this._callHook("created"),t.el&&this.$mount(t.el)}}function Tt(t){if(void 0===t)return"eof";var e=t.charCodeAt(0);switch(e){case 91:case 93:case 46:case 34:case 39:case 48:return t;case 95:case 36:return"ident";case 32:case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"ws"}return e>=97&&122>=e||e>=65&&90>=e?"ident":e>=49&&57>=e?"number":"else"}function Nt(t){var e=t.trim();return"0"===t.charAt(0)&&isNaN(t)?!1:n(e)?h(e):"*"+e}function jt(t){function e(){var e=t[c+1];return u===Hn&&"'"===e||u===Ln&&'"'===e?(c++,n="\\"+e,p[Tn](),!0):void 0}var i,n,r,s,o,a,h,l=[],c=-1,u=Sn,f=0,p=[];for(p[Nn]=function(){void 0!==r&&(l.push(r),r=void 0)},p[Tn]=function(){void 0===r?r=n:r+=n},p[jn]=function(){p[Tn](),f++},p[En]=function(){if(f>0)f--,u=Rn,p[Tn]();else{if(f=0,r=Nt(r),r===!1)return!1;p[Nn]()}};null!=u;)if(c++,i=t[c],"\\"!==i||!e()){if(s=Tt(i),h=Bn[u],o=h[s]||h["else"]||Wn,o===Wn)return;if(u=o[0],a=p[o[1]],a&&(n=o[2],n=void 0===n?i:n,a()===!1))return;if(u===Mn)return l.raw=t,l}}function Et(t){var e=On.get(t);return e||(e=jt(t),e&&On.put(t,e)),e}function St(t,e){return Wt(e).get(t)}function Ft(e,i,n){var r=e;if("string"==typeof i&&(i=jt(i)),!i||!m(e))return!1;for(var s,o,a=0,h=i.length;h>a;a++)s=e,o=i[a],"*"===o.charAt(0)&&(o=Wt(o.slice(1)).get.call(r,r)),h-1>a?(e=e[o],m(e)||(e={},t(s,o,e))):Oi(e)?e.$set(o,n):o in e?e[o]=n:t(e,o,n);return!0}function Pt(t,e){var i=er.length;return er[i]=e?t.replace(Gn,"\\n"):t,'"'+i+'"'}function Dt(t){var e=t.charAt(0),i=t.slice(1);return Un.test(i)?t:(i=i.indexOf('"')>-1?i.replace(Zn,Rt):i,e+"scope."+i)}function Rt(t,e){return er[e]}function Ht(t){Jn.test(t),er.length=0;var e=t.replace(Kn,Pt).replace(Qn,"");return e=(" "+e).replace(Yn,Dt).replace(Zn,Rt),Lt(e)}function Lt(t){try{return new Function("scope","return "+t+";")}catch(e){}}function Mt(t){var e=Et(t);return e?function(t,i){Ft(t,e,i)}:void 0}function Wt(t,e){t=t.trim();var i=zn.get(t);if(i)return e&&!i.set&&(i.set=Mt(i.exp)),i;var n={exp:t};return n.get=Bt(t)&&t.indexOf("[")<0?Lt("scope."+t):Ht(t),e&&(n.set=Mt(t)),zn.put(t,n),n}function Bt(t){return Xn.test(t)&&!tr.test(t)&&"Math."!==t.slice(0,5)}function Vt(){nr=[],rr=[],sr={},or={},ar=hr=!1}function zt(){It(nr),hr=!0,It(rr),ji&&ji.emit("flush"),Vt()}function It(t){for(var e=0;e<t.length;e++){var i=t[e],n=i.id;sr[n]=null,i.run()}}function Ut(t){var e=t.id;if(null==sr[e]){if(hr&&!t.user)return void t.run();var i=t.user?rr:nr;sr[e]=i.length,i.push(t),ar||(ar=!0,Wi(zt))}}function qt(t,e,i,n){n&&v(this,n);var r="function"==typeof e;if(this.vm=t,t._watchers.push(this),this.expression=r?e.toString():e,this.cb=i,this.id=++lr,this.active=!0,this.dirty=this.lazy,this.deps=Object.create(null),this.newDeps=null,this.prevError=null,r)this.getter=e,this.setter=void 0;else{var s=Wt(e,this.twoWay);this.getter=s.get,this.setter=s.set}this.value=this.lazy?void 0:this.get(),this.queued=this.shallow=!1}function Jt(t){var e,i;if(Oi(t))for(e=t.length;e--;)Jt(t[e]);else if(m(t))for(i=Object.keys(t),e=i.length;e--;)Jt(t[i[e]])}function Qt(t){return et(t)&&ot(t.content)}function Gt(t,e){var i=e?t:t.trim(),n=ur.get(i);if(n)return n;var r=document.createDocumentFragment(),s=t.match(dr),o=vr.test(t);if(s||o){var a=s&&s[1],h=pr[a]||pr.efault,l=h[0],c=h[1],u=h[2],f=document.createElement("div");for(f.innerHTML=c+t+u;l--;)f=f.lastChild;for(var p;p=f.firstChild;)r.appendChild(p)}else r.appendChild(document.createTextNode(t));return e||Y(r),ur.put(i,r),r}function Kt(t){if(Qt(t))return Y(t.content),t.content;if("SCRIPT"===t.tagName)return Gt(t.textContent);for(var e,i=Zt(t),n=document.createDocumentFragment();e=i.firstChild;)n.appendChild(e);return Y(n),n}function Zt(t){if(!t.querySelectorAll)return t.cloneNode();var e,i,n,r=t.cloneNode(!0);if(mr){var s=r;if(Qt(t)&&(t=t.content,s=r.content),i=t.querySelectorAll("template"),i.length)for(n=s.querySelectorAll("template"),e=n.length;e--;)n[e].parentNode.replaceChild(Zt(i[e]),n[e])}if(gr)if("TEXTAREA"===t.tagName)r.value=t.value;else if(i=t.querySelectorAll("textarea"),i.length)for(n=r.querySelectorAll("textarea"),e=n.length;e--;)n[e].value=i[e].value;return r}function Xt(t,e,i){var n,r;return ot(t)?(Y(t),e?Zt(t):t):("string"==typeof t?i||"#"!==t.charAt(0)?r=Gt(t,i):(r=fr.get(t),r||(n=document.getElementById(t.slice(1)),n&&(r=Kt(n),fr.put(t,r)))):t.nodeType&&(r=Kt(t)),r&&e?Zt(r):r)}function Yt(t,e,i,n,r,s){this.children=[],this.childFrags=[],this.vm=e,this.scope=r,this.inserted=!1,this.parentFrag=s,s&&s.childFrags.push(this),this.unlink=t(e,i,n,r,this);var o=this.single=1===i.childNodes.length&&!i.childNodes[0].__v_anchor;o?(this.node=i.childNodes[0],this.before=te,this.remove=ee):(this.node=it("fragment-start"),this.end=it("fragment-end"),this.frag=i,U(this.node,i),i.appendChild(this.end),this.before=ie,this.remove=ne),this.node.__v_frag=this}function te(t,e){this.inserted=!0;var i=e!==!1?P:V;i(this.node,t,this.vm),L(this.node)&&this.callHook(re)}function ee(){this.inserted=!1;var t=L(this.node),e=this;this.beforeRemove(),D(this.node,this.vm,function(){t&&e.callHook(se),e.destroy()})}function ie(t,e){this.inserted=!0;var i=this.vm,n=e!==!1?P:V;rt(this.node,this.end,function(e){n(e,t,i)}),L(this.node)&&this.callHook(re)}function ne(){this.inserted=!1;var t=this,e=L(this.node);this.beforeRemove(),st(this.node,this.end,this.vm,this.frag,function(){e&&t.callHook(se),t.destroy()})}function re(t){t._isAttached||t._callHook("attached")}function se(t){t._isAttached&&t._callHook("detached")}function oe(t,e){this.vm=t;var i,n="string"==typeof e;n||et(e)?i=Xt(e,!0):(i=document.createDocumentFragment(),i.appendChild(e)),this.template=i;var r,s=t.constructor.cid;if(s>0){var o=s+(n?e:at(e));r=yr.get(o),r||(r=Te(i,t.$options,!0),yr.put(o,r))}else r=Te(i,t.$options,!0);this.linker=r}function ae(t,e,i){var n=t.node.previousSibling;if(n){for(t=n.__v_frag;!(t&&t.forId===i&&t.inserted||n===e);){if(n=n.previousSibling,!n)return;t=n.__v_frag}return t}}function he(t){var e=t.node;if(t.end)for(;!e.__vue__&&e!==t.end&&e.nextSibling;)e=e.nextSibling;return e.__vue__}function le(t){for(var e=-1,i=new Array(Math.floor(t));++e<t;)i[e]=e;return i}function ce(t,e,i){for(var n,r,s,o=e?[]:null,a=0,h=t.options.length;h>a;a++)if(n=t.options[a],s=i?n.hasAttribute("selected"):n.selected){if(r=n.hasOwnProperty("_value")?n._value:n.value,!e)return r;o.push(r)}return o}function ue(t,e){for(var i=t.length;i--;)if(w(t[i],e))return i;return-1}function fe(t,e){var i=e.map(function(t){var e=t.charCodeAt(0);return e>47&&58>e?parseInt(t,10):1===t.length&&(e=t.toUpperCase().charCodeAt(0),e>64&&91>e)?e:Br[t]});return i=[].concat.apply([],i),function(e){return i.indexOf(e.keyCode)>-1?t.call(this,e):void 0}}function pe(t){return function(e){return e.stopPropagation(),t.call(this,e)}}function de(t){return function(e){return e.preventDefault(),t.call(this,e)}}function ve(t){return function(e){return e.target===e.currentTarget?t.call(this,e):void 0}}function me(t){if(qr[t])return qr[t];var e=ge(t);return qr[t]=qr[e]=e,e}function ge(t){t=u(t);var e=l(t),i=e.charAt(0).toUpperCase()+e.slice(1);Jr||(Jr=document.createElement("div"));for(var n,r=zr.length;r--;)if(n=Ir[r]+i,n in Jr.style)return zr[r]+t;return e in Jr.style?t:void 0}function _e(t){for(var e={},i=t.trim().split(/\s+/),n=i.length;n--;)e[i[n]]=!0;return e}function be(t,e){return Oi(t)?t.indexOf(e)>-1:i(t,e)}function ye(t,e,i){function n(){++s>=r?i():t[s].call(e,n)}var r=t.length,s=0;t[0].call(e,n)}function Ce(t){cs.push(t),us||(us=!0,Wi(we))}function we(){for(var t=document.documentElement.offsetHeight,e=0;e<cs.length;e++)cs[e]();return cs=[],us=!1,t}function $e(t,e,i,n){this.id=e,this.el=t,this.enterClass=i&&i.enterClass||e+"-enter",this.leaveClass=i&&i.leaveClass||e+"-leave",this.hooks=i,this.vm=n,this.pendingCssEvent=this.pendingCssCb=this.cancel=this.pendingJsCb=this.op=this.cb=null,this.justEntered=!1,this.entered=this.left=!1,this.typeCache={},this.type=i&&i.type;var r=this;["enterNextTick","enterDone","leaveNextTick","leaveDone"].forEach(function(t){r[t]=p(r[t],r)})}function ke(t){if(/svg$/.test(t.namespaceURI)){var e=t.getBoundingClientRect();return!(e.width||e.height)}return!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)}function xe(t,e){for(var i,r,s,o,a,h,c,f=[],p=Object.keys(e),d=p.length;d--;)r=p[d],i=e[r]||ys,a=l(r),Cs.test(a)&&(c={name:r,path:a,options:i,mode:bs.ONE_WAY,raw:null},s=u(r),null===(o=W(t,s))&&(null!==(o=W(t,s+".sync"))?c.mode=bs.TWO_WAY:null!==(o=W(t,s+".once"))&&(c.mode=bs.ONE_TIME)),null!==o?(c.raw=o,h=A(o),o=h.expression,c.filters=h.filters,n(o)&&!h.filters?c.optimizedLiteral=!0:c.dynamic=!0,c.parentPath=o):null!==(o=M(t,s))&&(c.raw=o),f.push(c));return Ae(f)}function Ae(t){return function(e,i){e._props={};for(var n,r,s,l,c,u=t.length;u--;)if(n=t[u],c=n.raw,r=n.path,s=n.options,e._props[r]=n,null===c)ct(e,n,Oe(e,s));else if(n.dynamic)n.mode===bs.ONE_TIME?(l=(i||e._context||e).$get(n.parentPath),ct(e,n,l)):e._context?e._bindDir({name:"prop",def:ls,prop:n},null,null,i):ct(e,n,e.$get(n.parentPath));else if(n.optimizedLiteral){var f=h(c);l=f===c?a(o(c)):f,ct(e,n,l)}else l=s.type===Boolean&&""===c?!0:c,ct(e,n,l)}}function Oe(t,e){if(!i(e,"default"))return e.type===Boolean?!1:void 0;var n=e["default"];return m(n),"function"==typeof n&&e.type!==Function?n.call(t):n}function Te(t,e,i){var n=i||!e._asComponent?De(t,e):null,r=n&&n.terminal||"SCRIPT"===t.tagName||!t.hasChildNodes()?null:Be(t.childNodes,e);return function(t,e,i,s,o){var a=d(e.childNodes),h=Ne(function(){n&&n(t,e,i,s,o),r&&r(t,a,i,s,o)},t);return Ee(t,h)}}function Ne(t,e){e._directives=[];var i=e._directives.length;t();var n=e._directives.slice(i);n.sort(je);for(var r=0,s=n.length;s>r;r++)n[r]._bind();return n}function je(t,e){return t=t.descriptor.def.priority||Ts,e=e.descriptor.def.priority||Ts,t>e?-1:t===e?0:1}function Ee(t,e,i,n){function r(r){Se(t,e,r),i&&n&&Se(i,n)}return r.dirs=e,r}function Se(t,e,i){for(var n=e.length;n--;)e[n]._teardown()}function Fe(t,e,i,n){var r=xe(e,i),s=Ne(function(){r(t,n)},t);return Ee(t,s)}function Pe(t,e,i){var n,r,s=e._containerAttrs,o=e._replacerAttrs;return 11!==t.nodeType&&(e._asComponent?(s&&i&&(n=Qe(s,i)),o&&(r=Qe(o,e))):r=Qe(t.attributes,e)),e._containerAttrs=e._replacerAttrs=null,function(t,e,i){var s,o=t._context;o&&n&&(s=Ne(function(){n(o,e,null,i)},o));var a=Ne(function(){r&&r(t,e)},t);return Ee(t,a,o,s)}}function De(t,e){var i=t.nodeType;return 1===i&&"SCRIPT"!==t.tagName?Re(t,e):3===i&&t.data.trim()?He(t,e):null}function Re(t,e){if("TEXTAREA"===t.tagName){var i=N(t.value);i&&(t.setAttribute(":value",j(i)),t.value="")}var n,r=t.hasAttributes();return r&&(n=Ue(t,e)),n||(n=ze(t,e)),n||(n=Ie(t,e)),!n&&r&&(n=Qe(t.attributes,e)),n}function He(t,e){if(t._skip)return Le;var i=N(t.wholeText);if(!i)return null;for(var n=t.nextSibling;n&&3===n.nodeType;)n._skip=!0,n=n.nextSibling;for(var r,s,o=document.createDocumentFragment(),a=0,h=i.length;h>a;a++)s=i[a],r=s.tag?Me(s,e):document.createTextNode(s.value),o.appendChild(r);return We(i,o,e)}function Le(t,e){I(e)}function Me(t,e){function i(e){if(!t.descriptor){var i=A(t.value);t.descriptor={name:e,def:ss[e],expression:i.expression,filters:i.filters}}}var n;return t.oneTime?n=document.createTextNode(t.value):t.html?(n=document.createComment("v-html"),i("html")):(n=document.createTextNode(" "),i("text")),n}function We(t,e){return function(i,n,r,s){for(var o,a,h,l=e.cloneNode(!0),c=d(l.childNodes),u=0,f=t.length;f>u;u++)o=t[u],a=o.value,o.tag&&(h=c[u],o.oneTime?(a=(s||i).$eval(a),o.html?q(h,Xt(a,!0)):h.data=a):i._bindDir(o.descriptor,h,r,s));q(n,l)}}function Be(t,e){for(var i,n,r,s=[],o=0,a=t.length;a>o;o++)r=t[o],i=De(r,e),n=i&&i.terminal||"SCRIPT"===r.tagName||!r.hasChildNodes()?null:Be(r.childNodes,e),s.push(i,n);return s.length?Ve(s):null}function Ve(t){return function(e,i,n,r,s){for(var o,a,h,l=0,c=0,u=t.length;u>l;c++){o=i[c],a=t[l++],h=t[l++];var f=d(o.childNodes);a&&a(e,o,n,r,s),h&&h(e,f,n,r,s)}}}function ze(t,e){var i=t.tagName.toLowerCase();if(!gn.test(i)){var n=bt(e,"elementDirectives",i);return n?Je(t,i,"",e,n):void 0}}function Ie(t,e){var i=ht(t,e);if(i){var n=nt(t),r={name:"component",ref:n,expression:i.id,def:_s.component,modifiers:{literal:!i.dynamic}},s=function(t,e,i,s,o){n&&At((s||t).$refs,n,null),t._bindDir(r,e,i,s,o)};return s.terminal=!0,s}}function Ue(t,e){if(null!==M(t,"v-pre"))return qe;if(t.hasAttribute("v-else")){var i=t.previousElementSibling;if(i&&i.hasAttribute("v-if"))return qe}for(var n,r,s=0,o=Os.length;o>s;s++)if(r=Os[s],n=t.getAttribute("v-"+r),null!=n)return Je(t,r,n,e)}function qe(){}function Je(t,e,i,n,r){var s=A(i),o={name:e,expression:s.expression,filters:s.filters,raw:i,def:r||bt(n,"directives",e)};"for"!==e&&"router-view"!==e||(o.ref=nt(t));var a=function(t,e,i,n,r){o.ref&&At((n||t).$refs,o.ref,null),t._bindDir(o,e,i,n,r)};return a.terminal=!0,a}function Qe(t,e){function i(t,e,i){var n=i&&Ze(i),r=!n&&A(s);v.push({name:t,attr:o,raw:a,def:e,arg:l,modifiers:c,expression:r&&r.expression,filters:r&&r.filters,interp:i,hasOneTime:n})}for(var n,r,s,o,a,h,l,c,u,f,p,d=t.length,v=[];d--;)if(n=t[d],r=o=n.name,s=a=n.value,f=N(s),l=null,c=Ge(r),r=r.replace(xs,""),f)s=j(f),l=r,i("bind",ss.bind,f);else if(As.test(r))c.literal=!ws.test(r),i("transition",_s.transition);else if($s.test(r))l=r.replace($s,""),i("on",ss.on);else if(ws.test(r))h=r.replace(ws,""),"style"===h||"class"===h?i(h,_s[h]):(l=h,i("bind",ss.bind));else if(p=r.match(ks)){if(h=p[1],l=p[2],"else"===h)continue;u=bt(e,"directives",h),u&&i(h,u)}return v.length?Ke(v):void 0}function Ge(t){var e=Object.create(null),i=t.match(xs);if(i)for(var n=i.length;n--;)e[i[n].slice(1)]=!0;return e}function Ke(t){return function(e,i,n,r,s){for(var o=t.length;o--;)e._bindDir(t[o],i,n,r,s)}}function Ze(t){for(var e=t.length;e--;)if(t[e].oneTime)return!0}function Xe(t,e){return e&&(e._containerAttrs=ti(t)),et(t)&&(t=Xt(t)),e&&(e._asComponent&&!e.template&&(e.template="<slot></slot>"),e.template&&(e._content=X(t),t=Ye(t,e))),ot(t)&&(U(it("v-start",!0),t),t.appendChild(it("v-end",!0))),t}function Ye(t,e){var i=e.template,n=Xt(i,!0);if(n){var r=n.firstChild,s=r.tagName&&r.tagName.toLowerCase();return e.replace?(t===document.body,n.childNodes.length>1||1!==r.nodeType||"component"===s||bt(e,"components",s)||B(r,"is")||bt(e,"elementDirectives",s)||r.hasAttribute("v-for")||r.hasAttribute("v-if")?n:(e._replacerAttrs=ti(r),ei(t,r),r)):(t.appendChild(n),t)}}function ti(t){return 1===t.nodeType&&t.hasAttributes()?d(t.attributes):void 0}function ei(t,e){for(var i,n,r=t.attributes,s=r.length;s--;)i=r[s].name,n=r[s].value,e.hasAttribute(i)||Ns.test(i)?"class"!==i||N(n)||n.split(/\s+/).forEach(function(t){K(e,t)}):e.setAttribute(i,n)}function ii(t,e,i){function n(t,i){var n='[slot="'+i+'"]',s=e.querySelectorAll(n);s.length&&(r[i]=ni(s,e))}if(e){var r=i._slotContents={},s=t.querySelectorAll("slot");if(s.length){for(var o,a,h,l=0,c=s.length;c>l;l++)a=s[l],(h=a.getAttribute("name"))?n(a,h):o=!0;o&&(r["default"]=ni(e.childNodes,e))}}}function ni(t,e){var i=document.createDocumentFragment();t=d(t);for(var n=0,r=t.length;r>n;n++){var s=t[n];s.parentNode===e&&(!et(s)||s.hasAttribute("v-if")||s.hasAttribute("v-for")||(e.removeChild(s),s=Xt(s)),i.appendChild(s))}return i}function ri(e){function n(){}function s(t,e){var i=new qt(e,t,null,{lazy:!0});return function(){return i.dirty&&i.evaluate(),Ct.target&&i.depend(),i.value}}Object.defineProperty(e.prototype,"$data",{get:function(){return this._data},set:function(t){t!==this._data&&this._setData(t)}}),e.prototype._initState=function(){this._initProps(),this._initMeta(),this._initMethods(),this._initData(),this._initComputed()},e.prototype._initProps=function(){var t=this.$options,e=t.el,i=t.props;e=t.el=H(e),this._propsUnlinkFn=e&&1===e.nodeType&&i?Fe(this,e,i,this._scope):null},e.prototype._initData=function(){var e=this._data,n=this.$options.data,r=n&&n();if(r){this._data=r;for(var s in e)null===this._props[s].raw&&i(r,s)||t(r,s,e[s])}var o,a,h=this._data,l=Object.keys(h);for(o=l.length;o--;)a=l[o],this._proxy(a);xt(h,this)},e.prototype._setData=function(t){t=t||{};var e=this._data;this._data=t;var n,r,s;for(n=Object.keys(e),s=n.length;s--;)r=n[s],r in t||this._unproxy(r);for(n=Object.keys(t),s=n.length;s--;)r=n[s],i(this,r)||this._proxy(r);e.__ob__.removeVm(this),xt(t,this),this._digest()},e.prototype._proxy=function(t){if(!r(t)){var e=this;Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return e._data[t]},set:function(i){e._data[t]=i}})}},e.prototype._unproxy=function(t){r(t)||delete this[t]},e.prototype._digest=function(){for(var t=0,e=this._watchers.length;e>t;t++)this._watchers[t].update(!0)},e.prototype._initComputed=function(){var t=this.$options.computed;if(t)for(var e in t){var i=t[e],r={enumerable:!0,configurable:!0};"function"==typeof i?(r.get=s(i,this),r.set=n):(r.get=i.get?i.cache!==!1?s(i.get,this):p(i.get,this):n,r.set=i.set?p(i.set,this):n),Object.defineProperty(this,e,r)}},e.prototype._initMethods=function(){var t=this.$options.methods;if(t)for(var e in t)this[e]=p(t[e],this)},e.prototype._initMeta=function(){var t=this.$options._meta;if(t)for(var e in t)At(this,e,t[e])}}function si(t){function e(t,e){for(var i,n,r=e.attributes,s=0,o=r.length;o>s;s++)i=r[s].name,Es.test(i)&&(i=i.replace(Es,""),n=(t._scope||t._context).$eval(r[s].value,!0),"function"==typeof n&&(n._fromParent=!0,t.$on(i.replace(Es),n)))}function i(t,e,i){if(i){var r,s,o,a;for(s in i)if(r=i[s],Oi(r))for(o=0,a=r.length;a>o;o++)n(t,e,s,r[o]);else n(t,e,s,r)}}function n(t,e,i,r,s){var o=typeof r;if("function"===o)t[e](i,r,s);else if("string"===o){var a=t.$options.methods,h=a&&a[r];h&&t[e](i,h,s)}else r&&"object"===o&&n(t,e,i,r.handler,r)}function r(){this._isAttached||(this._isAttached=!0,this.$children.forEach(s))}function s(t){!t._isAttached&&L(t.$el)&&t._callHook("attached")}function o(){this._isAttached&&(this._isAttached=!1,this.$children.forEach(a))}function a(t){t._isAttached&&!L(t.$el)&&t._callHook("detached")}t.prototype._initEvents=function(){var t=this.$options;t._asComponent&&e(this,t.el),i(this,"$on",t.events),i(this,"$watch",t.watch)},t.prototype._initDOMHooks=function(){this.$on("hook:attached",r),this.$on("hook:detached",o)},t.prototype._callHook=function(t){this.$emit("pre-hook:"+t);var e=this.$options[t];if(e)for(var i=0,n=e.length;n>i;i++)e[i].call(this);this.$emit("hook:"+t)}}function oi(){}function ai(t,e,i,n,r,s){this.vm=e,this.el=i,this.descriptor=t,this.name=t.name,this.expression=t.expression,this.arg=t.arg,this.modifiers=t.modifiers,this.filters=t.filters,this.literal=this.modifiers&&this.modifiers.literal,this._locked=!1,this._bound=!1,this._listeners=null,this._host=n,this._scope=r,this._frag=s}function hi(t){t.prototype._updateRef=function(t){var e=this.$options._ref;if(e){var i=(this._scope||this._context).$refs;t?i[e]===this&&(i[e]=null):i[e]=this}},t.prototype._compile=function(t){var e=this.$options,i=t;if(t=Xe(t,e),this._initElement(t),1!==t.nodeType||null===M(t,"v-pre")){var n=this._context&&this._context.$options,r=Pe(t,e,n);ii(t,e._content,this);var s,o=this.constructor;e._linkerCachable&&(s=o.linker,s||(s=o.linker=Te(t,e)));var a=r(this,t,this._scope),h=s?s(this,t):Te(t,e)(this,t);this._unlinkFn=function(){a(),h(!0)},e.replace&&q(i,t),this._isCompiled=!0,this._callHook("compiled")}},t.prototype._initElement=function(t){ot(t)?(this._isFragment=!0,this.$el=this._fragmentStart=t.firstChild,this._fragmentEnd=t.lastChild,3===this._fragmentStart.nodeType&&(this._fragmentStart.data=this._fragmentEnd.data=""),this._fragment=t):this.$el=t,this.$el.__vue__=this,this._callHook("beforeCompile")},t.prototype._bindDir=function(t,e,i,n,r){this._directives.push(new ai(t,this,e,i,n,r))},t.prototype._destroy=function(t,e){if(this._isBeingDestroyed)return void(e||this._cleanup());var i,n,r=this,s=function(){!i||n||e||r._cleanup()};t&&this.$el&&(n=!0,this.$remove(function(){n=!1,s()})),this._callHook("beforeDestroy"),this._isBeingDestroyed=!0;var o,a=this.$parent;for(a&&!a._isBeingDestroyed&&(a.$children.$remove(this),this._updateRef(!0)),o=this.$children.length;o--;)this.$children[o].$destroy();for(this._propsUnlinkFn&&this._propsUnlinkFn(),this._unlinkFn&&this._unlinkFn(),o=this._watchers.length;o--;)this._watchers[o].teardown();this.$el&&(this.$el.__vue__=null),i=!0,s()},t.prototype._cleanup=function(){this._isDestroyed||(this._frag&&this._frag.children.$remove(this),this._data.__ob__&&this._data.__ob__.removeVm(this),this.$el=this.$parent=this.$root=this.$children=this._watchers=this._context=this._scope=this._directives=null,this._isDestroyed=!0,this._callHook("destroyed"),this.$off())}}function li(t){t.prototype._applyFilters=function(t,e,i,n){var r,s,o,a,h,l,c,u,f;for(l=0,c=i.length;c>l;l++)if(r=i[l],s=bt(this.$options,"filters",r.name),s&&(s=n?s.write:s.read||s,"function"==typeof s)){if(o=n?[t,e]:[t],h=n?2:1,r.args)for(u=0,f=r.args.length;f>u;u++)a=r.args[u],o[u+h]=a.dynamic?this.$get(a.value):a.value;t=s.apply(this,o)}return t},t.prototype._resolveComponent=function(e,i){var n=bt(this.$options,"components",e);if(n)if(n.options)i(n);else if(n.resolved)i(n.resolved);else if(n.requested)n.pendingCallbacks.push(i);else{n.requested=!0;var r=n.pendingCallbacks=[i];n.call(this,function(e){g(e)&&(e=t.extend(e)),n.resolved=e;for(var i=0,s=r.length;s>i;i++)r[i](e)},function(t){})}}}function ci(t){function i(t){return JSON.parse(JSON.stringify(t))}t.prototype.$get=function(t,e){var i=Wt(t);if(i){if(e&&!Bt(t)){var n=this;return function(){n.$arguments=d(arguments);var t=i.get.call(n,n);return n.$arguments=null,
7t}}try{return i.get.call(this,this)}catch(r){}}},t.prototype.$set=function(t,e){var i=Wt(t,!0);i&&i.set&&i.set.call(this,this,e)},t.prototype.$delete=function(t){e(this._data,t)},t.prototype.$watch=function(t,e,i){var n,r=this;"string"==typeof t&&(n=A(t),t=n.expression);var s=new qt(r,t,e,{deep:i&&i.deep,sync:i&&i.sync,filters:n&&n.filters,user:!i||i.user!==!1});return i&&i.immediate&&e.call(r,s.value),function(){s.teardown()}},t.prototype.$eval=function(t,e){if(Ss.test(t)){var i=A(t),n=this.$get(i.expression,e);return i.filters?this._applyFilters(n,null,i.filters):n}return this.$get(t,e)},t.prototype.$interpolate=function(t){var e=N(t),i=this;return e?1===e.length?i.$eval(e[0].value)+"":e.map(function(t){return t.tag?i.$eval(t.value):t.value}).join(""):t},t.prototype.$log=function(t){var e=t?St(this._data,t):this._data;if(e&&(e=i(e)),!t)for(var n in this.$options.computed)e[n]=i(this[n]);console.log(e)}}function ui(t){function e(t,e,n,r,s,o){e=i(e);var a=!L(e),h=r===!1||a?s:o,l=!a&&!t._isAttached&&!L(t.$el);return t._isFragment?(rt(t._fragmentStart,t._fragmentEnd,function(i){h(i,e,t)}),n&&n()):h(t.$el,e,t,n),l&&t._callHook("attached"),t}function i(t){return"string"==typeof t?document.querySelector(t):t}function n(t,e,i,n){e.appendChild(t),n&&n()}function r(t,e,i,n){V(t,e),n&&n()}function s(t,e,i){I(t),i&&i()}t.prototype.$nextTick=function(t){Wi(t,this)},t.prototype.$appendTo=function(t,i,r){return e(this,t,i,r,n,F)},t.prototype.$prependTo=function(t,e,n){return t=i(t),t.hasChildNodes()?this.$before(t.firstChild,e,n):this.$appendTo(t,e,n),this},t.prototype.$before=function(t,i,n){return e(this,t,i,n,r,P)},t.prototype.$after=function(t,e,n){return t=i(t),t.nextSibling?this.$before(t.nextSibling,e,n):this.$appendTo(t.parentNode,e,n),this},t.prototype.$remove=function(t,e){if(!this.$el.parentNode)return t&&t();var i=this._isAttached&&L(this.$el);i||(e=!1);var n=this,r=function(){i&&n._callHook("detached"),t&&t()};if(this._isFragment)st(this._fragmentStart,this._fragmentEnd,this,this._fragment,r);else{var o=e===!1?s:D;o(this.$el,this,r)}return this}}function fi(t){function e(t,e,n){var r=t.$parent;if(r&&n&&!i.test(e))for(;r;)r._eventsCount[e]=(r._eventsCount[e]||0)+n,r=r.$parent}t.prototype.$on=function(t,i){return(this._events[t]||(this._events[t]=[])).push(i),e(this,t,1),this},t.prototype.$once=function(t,e){function i(){n.$off(t,i),e.apply(this,arguments)}var n=this;return i.fn=e,this.$on(t,i),this},t.prototype.$off=function(t,i){var n;if(!arguments.length){if(this.$parent)for(t in this._events)n=this._events[t],n&&e(this,t,-n.length);return this._events={},this}if(n=this._events[t],!n)return this;if(1===arguments.length)return e(this,t,-n.length),this._events[t]=null,this;for(var r,s=n.length;s--;)if(r=n[s],r===i||r.fn===i){e(this,t,-1),n.splice(s,1);break}return this},t.prototype.$emit=function(t){var e="string"==typeof t;t=e?t:t.name;var i=this._events[t],n=e||!i;if(i){i=i.length>1?d(i):i;var r=e&&i.some(function(t){return t._fromParent});r&&(n=!1);for(var s=d(arguments,1),o=0,a=i.length;a>o;o++){var h=i[o],l=h.apply(this,s);l!==!0||r&&!h._fromParent||(n=!0)}}return n},t.prototype.$broadcast=function(t){var e="string"==typeof t;if(t=e?t:t.name,this._eventsCount[t]){var i=this.$children,n=d(arguments);e&&(n[0]={name:t,source:this});for(var r=0,s=i.length;s>r;r++){var o=i[r],a=o.$emit.apply(o,n);a&&o.$broadcast.apply(o,n)}return this}},t.prototype.$dispatch=function(t){var e=this.$emit.apply(this,arguments);if(e){var i=this.$parent,n=d(arguments);for(n[0]={name:t,source:this};i;)e=i.$emit.apply(i,n),i=e?i.$parent:null;return this}};var i=/^hook:/}function pi(t){function e(){this._isAttached=!0,this._isReady=!0,this._callHook("ready")}t.prototype.$mount=function(t){return this._isCompiled?void 0:(t=H(t),t||(t=document.createElement("div")),this._compile(t),this._initDOMHooks(),L(this.$el)?(this._callHook("attached"),e.call(this)):this.$once("hook:attached",e),this)},t.prototype.$destroy=function(t,e){this._destroy(t,e)},t.prototype.$compile=function(t,e,i,n){return Te(t,this.$options,!0)(this,t,e,i,n)}}function di(t){this._init(t)}function vi(t,e,i){return i=i?parseInt(i,10):0,e=o(e),"number"==typeof e?t.slice(i,i+e):t}function mi(t,e,i){if(t=Rs(t),null==e)return t;if("function"==typeof e)return t.filter(e);e=(""+e).toLowerCase();for(var n,r,s,o,a="in"===i?3:2,h=d(arguments,a).reduce(function(t,e){return t.concat(e)},[]),l=[],c=0,u=t.length;u>c;c++)if(n=t[c],s=n&&n.$value||n,o=h.length){for(;o--;)if(r=h[o],"$key"===r&&_i(n.$key,e)||_i(St(s,r),e)){l.push(n);break}}else _i(n,e)&&l.push(n);return l}function gi(t,e,i){if(t=Rs(t),!e)return t;var n=i&&0>i?-1:1;return t.slice().sort(function(t,i){return"$key"!==e&&(m(t)&&"$value"in t&&(t=t.$value),m(i)&&"$value"in i&&(i=i.$value)),t=m(t)?St(t,e):t,i=m(i)?St(i,e):i,t===i?0:t>i?n:-n})}function _i(t,e){var i;if(g(t)){var n=Object.keys(t);for(i=n.length;i--;)if(_i(t[n[i]],e))return!0}else if(Oi(t)){for(i=t.length;i--;)if(_i(t[i],e))return!0}else if(null!=t)return t.toString().toLowerCase().indexOf(e)>-1}function bi(i){function n(t){return new Function("return function "+f(t)+" (options) { this._init(options) }")()}i.options={directives:ss,elementDirectives:Ds,filters:Ls,transitions:{},components:{},partials:{},replace:!0},i.util=xn,i.config=pn,i.set=t,i["delete"]=e,i.nextTick=Wi,i.compiler=js,i.FragmentFactory=oe,i.internalDirectives=_s,i.parsers={path:Vn,text:cn,template:_r,directive:rn,expression:ir},i.cid=0;var r=1;i.extend=function(t){t=t||{};var e=this,i=0===e.cid;if(i&&t._Ctor)return t._Ctor;var s=t.name||e.options.name,o=n(s||"VueComponent");return o.prototype=Object.create(e.prototype),o.prototype.constructor=o,o.cid=r++,o.options=_t(e.options,t),o["super"]=e,o.extend=e.extend,pn._assetTypes.forEach(function(t){o[t]=e[t]}),s&&(o.options.components[s]=o),i&&(t._Ctor=o),o},i.use=function(t){if(!t.installed){var e=d(arguments,1);return e.unshift(this),"function"==typeof t.install?t.install.apply(t,e):t.apply(null,e),t.installed=!0,this}},i.mixin=function(t){i.options=_t(i.options,t)},pn._assetTypes.forEach(function(t){i[t]=function(e,n){return n?("component"===t&&g(n)&&(n.name=e,n=i.extend(n)),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}),v(i.transition,vn)}var yi=Object.prototype.hasOwnProperty,Ci=/^\s?(true|false|-?[\d\.]+|'[^']*'|"[^"]*")\s?$/,wi=/-(\w)/g,$i=/([a-z\d])([A-Z])/g,ki=/(?:^|[-_\/])(\w)/g,xi=Object.prototype.toString,Ai="[object Object]",Oi=Array.isArray,Ti="__proto__"in{},Ni="undefined"!=typeof window&&"[object Object]"!==Object.prototype.toString.call(window),ji=Ni&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,Ei=Ni&&window.navigator.userAgent.toLowerCase(),Si=Ei&&Ei.indexOf("msie 9.0")>0,Fi=Ei&&Ei.indexOf("android")>0,Pi=void 0,Di=void 0,Ri=void 0,Hi=void 0;if(Ni&&!Si){var Li=void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend,Mi=void 0===window.onanimationend&&void 0!==window.onwebkitanimationend;Pi=Li?"WebkitTransition":"transition",Di=Li?"webkitTransitionEnd":"transitionend",Ri=Mi?"WebkitAnimation":"animation",Hi=Mi?"webkitAnimationEnd":"animationend"}var Wi=function(){function t(){n=!1;var t=i.slice(0);i=[];for(var e=0;e<t.length;e++)t[e]()}var e,i=[],n=!1;if("undefined"!=typeof MutationObserver){var r=1,s=new MutationObserver(t),o=document.createTextNode(r);s.observe(o,{characterData:!0}),e=function(){r=(r+1)%2,o.data=r}}else{var a=Ni?window:"undefined"!=typeof global?global:{};e=a.setImmediate||setTimeout}return function(r,s){var o=s?function(){r.call(s)}:r;i.push(o),n||(n=!0,e(t,0))}}(),Bi=$.prototype;Bi.put=function(t,e){var i;this.size===this.limit&&(i=this.shift());var n=this.get(t,!0);return n||(n={key:t},this._keymap[t]=n,this.tail?(this.tail.newer=n,n.older=this.tail):this.head=n,this.tail=n,this.size++),n.value=e,i},Bi.shift=function(){var t=this.head;return t&&(this.head=this.head.newer,this.head.older=void 0,t.newer=t.older=void 0,this._keymap[t.key]=void 0,this.size--),t},Bi.get=function(t,e){var i=this._keymap[t];if(void 0!==i)return i===this.tail?e?i:i.value:(i.newer&&(i===this.head&&(this.head=i.newer),i.newer.older=i.older),i.older&&(i.older.newer=i.newer),i.newer=void 0,i.older=this.tail,this.tail&&(this.tail.newer=i),this.tail=i,e?i:i.value)};var Vi,zi,Ii,Ui,qi,Ji,Qi,Gi,Ki,Zi,Xi,Yi,tn=new $(1e3),en=/[^\s'"]+|'[^']*'|"[^"]*"/g,nn=/^in$|^-?\d+/,rn=Object.freeze({parseDirective:A}),sn=/[-.*+?^${}()|[\]\/\\]/g,on=void 0,an=void 0,hn=void 0,ln=/[^|]\|[^|]/,cn=Object.freeze({compileRegex:T,parseText:N,tokensToExp:j}),un=["{{","}}"],fn=["{{{","}}}"],pn=Object.defineProperties({debug:!1,silent:!1,async:!0,warnExpressionErrors:!0,_delimitersChanged:!0,_assetTypes:["component","directive","elementDirective","filter","transition","partial"],_propBindingModes:{ONE_WAY:0,TWO_WAY:1,ONE_TIME:2},_maxUpdateCount:100},{delimiters:{get:function(){return un},set:function(t){un=t,T()},configurable:!0,enumerable:!0},unsafeDelimiters:{get:function(){return fn},set:function(t){fn=t,T()},configurable:!0,enumerable:!0}}),dn=void 0,vn=Object.freeze({appendWithTransition:F,beforeWithTransition:P,removeWithTransition:D,applyTransition:R}),mn=/^v-ref:/,gn=/^(div|p|span|img|a|b|i|br|ul|ol|li|h1|h2|h3|h4|h5|h6|code|pre|table|th|td|tr|form|label|input|select|option|nav|article|section|header|footer)$/,_n=/^(slot|partial|component)$/,bn=pn.optionMergeStrategies=Object.create(null);bn.data=function(t,e,i){return i?t||e?function(){var n="function"==typeof e?e.call(i):e,r="function"==typeof t?t.call(i):void 0;return n?pt(n,r):r}:void 0:e?"function"!=typeof e?t:t?function(){return pt(e.call(this),t.call(this))}:e:t},bn.el=function(t,e,i){if(i||!e||"function"==typeof e){var n=e||t;return i&&"function"==typeof n?n.call(i):n}},bn.init=bn.created=bn.ready=bn.attached=bn.detached=bn.beforeCompile=bn.compiled=bn.beforeDestroy=bn.destroyed=bn.activate=function(t,e){return e?t?t.concat(e):Oi(e)?e:[e]:t},bn.paramAttributes=function(){},pn._assetTypes.forEach(function(t){bn[t+"s"]=dt}),bn.watch=bn.events=function(t,e){if(!e)return t;if(!t)return e;var i={};v(i,t);for(var n in e){var r=i[n],s=e[n];r&&!Oi(r)&&(r=[r]),i[n]=r?r.concat(s):[s]}return i},bn.props=bn.methods=bn.computed=function(t,e){if(!e)return t;if(!t)return e;var i=Object.create(null);return v(i,t),v(i,e),i};var yn=function(t,e){return void 0===e?t:e},Cn=0;Ct.target=null,Ct.prototype.addSub=function(t){this.subs.push(t)},Ct.prototype.removeSub=function(t){this.subs.$remove(t)},Ct.prototype.depend=function(){Ct.target.addDep(this)},Ct.prototype.notify=function(){for(var t=d(this.subs),e=0,i=t.length;i>e;e++)t[e].update()};var wn=Array.prototype,$n=Object.create(wn);["push","pop","shift","unshift","splice","sort","reverse"].forEach(function(t){var e=wn[t];_($n,t,function(){for(var i=arguments.length,n=new Array(i);i--;)n[i]=arguments[i];var r,s=e.apply(this,n),o=this.__ob__;switch(t){case"push":r=n;break;case"unshift":r=n;break;case"splice":r=n.slice(2)}return r&&o.observeArray(r),o.dep.notify(),s})}),_(wn,"$set",function(t,e){return t>=this.length&&(this.length=Number(t)+1),this.splice(t,1,e)[0]}),_(wn,"$remove",function(t){if(this.length){var e=y(this,t);return e>-1?this.splice(e,1):void 0}});var kn=Object.getOwnPropertyNames($n);wt.prototype.walk=function(t){for(var e=Object.keys(t),i=0,n=e.length;n>i;i++)this.convert(e[i],t[e[i]])},wt.prototype.observeArray=function(t){for(var e=0,i=t.length;i>e;e++)xt(t[e])},wt.prototype.convert=function(t,e){At(this.value,t,e)},wt.prototype.addVm=function(t){(this.vms||(this.vms=[])).push(t)},wt.prototype.removeVm=function(t){this.vms.$remove(t)};var xn=Object.freeze({defineReactive:At,set:t,del:e,hasOwn:i,isLiteral:n,isReserved:r,_toString:s,toNumber:o,toBoolean:a,stripQuotes:h,camelize:l,hyphenate:u,classify:f,bind:p,toArray:d,extend:v,isObject:m,isPlainObject:g,def:_,debounce:b,indexOf:y,cancellable:C,looseEqual:w,isArray:Oi,hasProto:Ti,inBrowser:Ni,devtools:ji,isIE9:Si,isAndroid:Fi,get transitionProp(){return Pi},get transitionEndEvent(){return Di},get animationProp(){return Ri},get animationEndEvent(){return Hi},nextTick:Wi,query:H,inDoc:L,getAttr:M,getBindAttr:W,hasBindAttr:B,before:V,after:z,remove:I,prepend:U,replace:q,on:J,off:Q,setClass:G,addClass:K,removeClass:Z,extractContent:X,trimNode:Y,isTemplate:et,createAnchor:it,findRef:nt,mapNodeRange:rt,removeNodeRange:st,isFragment:ot,getOuterHTML:at,mergeOptions:_t,resolveAsset:bt,assertAsset:yt,checkComponentAttr:ht,initProp:ct,assertProp:ut,coerceProp:ft,commonTagRE:gn,reservedTagRE:_n,warn:dn}),An=0,On=new $(1e3),Tn=0,Nn=1,jn=2,En=3,Sn=0,Fn=1,Pn=2,Dn=3,Rn=4,Hn=5,Ln=6,Mn=7,Wn=8,Bn=[];Bn[Sn]={ws:[Sn],ident:[Dn,Tn],"[":[Rn],eof:[Mn]},Bn[Fn]={ws:[Fn],".":[Pn],"[":[Rn],eof:[Mn]},Bn[Pn]={ws:[Pn],ident:[Dn,Tn]},Bn[Dn]={ident:[Dn,Tn],0:[Dn,Tn],number:[Dn,Tn],ws:[Fn,Nn],".":[Pn,Nn],"[":[Rn,Nn],eof:[Mn,Nn]},Bn[Rn]={"'":[Hn,Tn],'"':[Ln,Tn],"[":[Rn,jn],"]":[Fn,En],eof:Wn,"else":[Rn,Tn]},Bn[Hn]={"'":[Rn,Tn],eof:Wn,"else":[Hn,Tn]},Bn[Ln]={'"':[Rn,Tn],eof:Wn,"else":[Ln,Tn]};var Vn=Object.freeze({parsePath:Et,getPath:St,setPath:Ft}),zn=new $(1e3),In="Math,Date,this,true,false,null,undefined,Infinity,NaN,isNaN,isFinite,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,parseInt,parseFloat",Un=new RegExp("^("+In.replace(/,/g,"\\b|")+"\\b)"),qn="break,case,class,catch,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,in,instanceof,let,return,super,switch,throw,try,var,while,with,yield,enum,await,implements,package,proctected,static,interface,private,public",Jn=new RegExp("^("+qn.replace(/,/g,"\\b|")+"\\b)"),Qn=/\s/g,Gn=/\n/g,Kn=/[\{,]\s*[\w\$_]+\s*:|('(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"|`(?:[^`\\]|\\.)*\$\{|\}(?:[^`\\]|\\.)*`|`(?:[^`\\]|\\.)*`)|new |typeof |void /g,Zn=/"(\d+)"/g,Xn=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['.*?'\]|\[".*?"\]|\[\d+\]|\[[A-Za-z_$][\w$]*\])*$/,Yn=/[^\w$\.](?:[A-Za-z_$][\w$]*)/g,tr=/^(?:true|false)$/,er=[],ir=Object.freeze({parseExpression:Wt,isSimplePath:Bt}),nr=[],rr=[],sr={},or={},ar=!1,hr=!1,lr=0;qt.prototype.addDep=function(t){var e=t.id;this.newDeps[e]||(this.newDeps[e]=t,this.deps[e]||(this.deps[e]=t,t.addSub(this)))},qt.prototype.get=function(){this.beforeGet();var t,e=this.scope||this.vm;try{t=this.getter.call(e,e)}catch(i){}return this.deep&&Jt(t),this.preProcess&&(t=this.preProcess(t)),this.filters&&(t=e._applyFilters(t,null,this.filters,!1)),this.postProcess&&(t=this.postProcess(t)),this.afterGet(),t},qt.prototype.set=function(t){var e=this.scope||this.vm;this.filters&&(t=e._applyFilters(t,this.value,this.filters,!0));try{this.setter.call(e,e,t)}catch(i){}var n=e.$forContext;if(n&&n.alias===this.expression){if(n.filters)return;n._withLock(function(){e.$key?n.rawValue[e.$key]=t:n.rawValue.$set(e.$index,t)})}},qt.prototype.beforeGet=function(){Ct.target=this,this.newDeps=Object.create(null)},qt.prototype.afterGet=function(){Ct.target=null;for(var t=Object.keys(this.deps),e=t.length;e--;){var i=t[e];this.newDeps[i]||this.deps[i].removeSub(this)}this.deps=this.newDeps},qt.prototype.update=function(t){this.lazy?this.dirty=!0:this.sync||!pn.async?this.run():(this.shallow=this.queued?t?this.shallow:!1:!!t,this.queued=!0,Ut(this))},qt.prototype.run=function(){if(this.active){var t=this.get();if(t!==this.value||(m(t)||this.deep)&&!this.shallow){var e=this.value;this.value=t;this.prevError;this.cb.call(this.vm,t,e)}this.queued=this.shallow=!1}},qt.prototype.evaluate=function(){var t=Ct.target;this.value=this.get(),this.dirty=!1,Ct.target=t},qt.prototype.depend=function(){for(var t=Object.keys(this.deps),e=t.length;e--;)this.deps[t[e]].depend()},qt.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||this.vm._vForRemoving||this.vm._watchers.$remove(this);for(var t=Object.keys(this.deps),e=t.length;e--;)this.deps[t[e]].removeSub(this);this.active=!1,this.vm=this.cb=this.value=null}};var cr={bind:function(){this.attr=3===this.el.nodeType?"data":"textContent"},update:function(t){this.el[this.attr]=s(t)}},ur=new $(1e3),fr=new $(1e3),pr={efault:[0,"",""],legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]};pr.td=pr.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],pr.option=pr.optgroup=[1,'<select multiple="multiple">',"</select>"],pr.thead=pr.tbody=pr.colgroup=pr.caption=pr.tfoot=[1,"<table>","</table>"],pr.g=pr.defs=pr.symbol=pr.use=pr.image=pr.text=pr.circle=pr.ellipse=pr.line=pr.path=pr.polygon=pr.polyline=pr.rect=[1,'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:ev="http://www.w3.org/2001/xml-events"version="1.1">',"</svg>"];var dr=/<([\w:]+)/,vr=/&#?\w+?;/,mr=function(){if(Ni){var t=document.createElement("div");return t.innerHTML="<template>1</template>",!t.cloneNode(!0).firstChild.innerHTML}return!1}(),gr=function(){if(Ni){var t=document.createElement("textarea");return t.placeholder="t","t"===t.cloneNode(!0).value}return!1}(),_r=Object.freeze({cloneNode:Zt,parseTemplate:Xt}),br={bind:function(){8===this.el.nodeType&&(this.nodes=[],this.anchor=it("v-html"),q(this.el,this.anchor))},update:function(t){t=s(t),this.nodes?this.swap(t):this.el.innerHTML=t},swap:function(t){for(var e=this.nodes.length;e--;)I(this.nodes[e]);var i=Xt(t,!0,!0);this.nodes=d(i.childNodes),V(i,this.anchor)}};Yt.prototype.callHook=function(t){var e,i;for(e=0,i=this.childFrags.length;i>e;e++)this.childFrags[e].callHook(t);for(e=0,i=this.children.length;i>e;e++)t(this.children[e])},Yt.prototype.beforeRemove=function(){var t,e;for(t=0,e=this.childFrags.length;e>t;t++)this.childFrags[t].beforeRemove(!1);for(t=0,e=this.children.length;e>t;t++)this.children[t].$destroy(!1,!0);var i=this.unlink.dirs;for(t=0,e=i.length;e>t;t++)i[t]._watcher&&i[t]._watcher.teardown()},Yt.prototype.destroy=function(){this.parentFrag&&this.parentFrag.childFrags.$remove(this),this.node.__v_frag=null,this.unlink()};var yr=new $(5e3);oe.prototype.create=function(t,e,i){var n=Zt(this.template);return new Yt(this.linker,this.vm,n,t,e,i)};var Cr=700,wr=800,$r=850,kr=1100,xr=1500,Ar=1500,Or=1750,Tr=2e3,Nr=2e3,jr=2100,Er=0,Sr={priority:Tr,params:["track-by","stagger","enter-stagger","leave-stagger"],bind:function(){var t=this.expression.match(/(.*) (?:in|of) (.*)/);if(t){var e=t[1].match(/\((.*),(.*)\)/);e?(this.iterator=e[1].trim(),this.alias=e[2].trim()):this.alias=t[1].trim(),this.expression=t[2]}if(this.alias){this.id="__v-for__"+ ++Er;var i=this.el.tagName;this.isOption=("OPTION"===i||"OPTGROUP"===i)&&"SELECT"===this.el.parentNode.tagName,this.start=it("v-for-start"),this.end=it("v-for-end"),q(this.el,this.end),V(this.start,this.end),this.cache=Object.create(null),this.factory=new oe(this.vm,this.el)}},update:function(t){this.diff(t),this.updateRef(),this.updateModel()},diff:function(t){var e,n,r,s,o,a,h=t[0],l=this.fromObject=m(h)&&i(h,"$key")&&i(h,"$value"),c=this.params.trackBy,u=this.frags,f=this.frags=new Array(t.length),p=this.alias,d=this.iterator,v=this.start,g=this.end,_=L(v),b=!u;for(e=0,n=t.length;n>e;e++)h=t[e],s=l?h.$key:null,o=l?h.$value:h,a=!m(o),r=!b&&this.getCachedFrag(o,e,s),r?(r.reused=!0,r.scope.$index=e,s&&(r.scope.$key=s),d&&(r.scope[d]=null!==s?s:e),(c||l||a)&&(r.scope[p]=o)):(r=this.create(o,p,e,s),r.fresh=!b),f[e]=r,b&&r.before(g);if(!b){var y=0,C=u.length-f.length;for(this.vm._vForRemoving=!0,e=0,n=u.length;n>e;e++)r=u[e],r.reused||(this.deleteCachedFrag(r),this.remove(r,y++,C,_));this.vm._vForRemoving=!1,y&&(this.vm._watchers=this.vm._watchers.filter(function(t){return t.active}));var w,$,k,x=0;for(e=0,n=f.length;n>e;e++)r=f[e],w=f[e-1],$=w?w.staggerCb?w.staggerAnchor:w.end||w.node:v,r.reused&&!r.staggerCb?(k=ae(r,v,this.id),k===w||k&&ae(k,v,this.id)===w||this.move(r,$)):this.insert(r,x++,$,_),r.reused=r.fresh=!1}},create:function(t,e,i,n){var r=this._host,s=this._scope||this.vm,o=Object.create(s);o.$refs=Object.create(s.$refs),o.$els=Object.create(s.$els),o.$parent=s,o.$forContext=this,At(o,e,t),At(o,"$index",i),n?At(o,"$key",n):o.$key&&_(o,"$key",null),this.iterator&&At(o,this.iterator,null!==n?n:i);var a=this.factory.create(r,o,this._frag);return a.forId=this.id,this.cacheFrag(t,a,i,n),a},updateRef:function(){var t=this.descriptor.ref;if(t){var e,i=(this._scope||this.vm).$refs;this.fromObject?(e={},this.frags.forEach(function(t){e[t.scope.$key]=he(t)})):e=this.frags.map(he),i[t]=e}},updateModel:function(){if(this.isOption){var t=this.start.parentNode,e=t&&t.__v_model;e&&e.forceUpdate()}},insert:function(t,e,i,n){t.staggerCb&&(t.staggerCb.cancel(),t.staggerCb=null);var r=this.getStagger(t,e,null,"enter");if(n&&r){var s=t.staggerAnchor;s||(s=t.staggerAnchor=it("stagger-anchor"),s.__v_frag=t),z(s,i);var o=t.staggerCb=C(function(){t.staggerCb=null,t.before(s),I(s)});setTimeout(o,r)}else t.before(i.nextSibling)},remove:function(t,e,i,n){if(t.staggerCb)return t.staggerCb.cancel(),void(t.staggerCb=null);var r=this.getStagger(t,e,i,"leave");if(n&&r){var s=t.staggerCb=C(function(){t.staggerCb=null,t.remove()});setTimeout(s,r)}else t.remove()},move:function(t,e){e.nextSibling||this.end.parentNode.appendChild(this.end),t.before(e.nextSibling,!1)},cacheFrag:function(t,e,n,r){var s,o=this.params.trackBy,a=this.cache,h=!m(t);r||o||h?(s=o?"$index"===o?n:t[o]:r||t,a[s]||(a[s]=e)):(s=this.id,i(t,s)?null===t[s]&&(t[s]=e):_(t,s,e)),e.raw=t},getCachedFrag:function(t,e,i){var n,r=this.params.trackBy,s=!m(t);if(i||r||s){var o=r?"$index"===r?e:t[r]:i||t;n=this.cache[o]}else n=t[this.id];return n&&(n.reused||n.fresh),n},deleteCachedFrag:function(t){var e=t.raw,n=this.params.trackBy,r=t.scope,s=r.$index,o=i(r,"$key")&&r.$key,a=!m(e);if(n||o||a){var h=n?"$index"===n?s:e[n]:o||e;this.cache[h]=null}else e[this.id]=null,t.raw=null},getStagger:function(t,e,i,n){n+="Stagger";var r=t.node.__v_trans,s=r&&r.hooks,o=s&&(s[n]||s.stagger);return o?o.call(t,e,i):e*parseInt(this.params[n]||this.params.stagger,10)},_preProcess:function(t){return this.rawValue=t,t},_postProcess:function(t){if(Oi(t))return t;if(g(t)){for(var e,i=Object.keys(t),n=i.length,r=new Array(n);n--;)e=i[n],r[n]={$key:e,$value:t[e]};return r}return"number"!=typeof t||isNaN(t)||(t=le(t)),t||[]},unbind:function(){if(this.descriptor.ref&&((this._scope||this.vm).$refs[this.descriptor.ref]=null),this.frags)for(var t,e=this.frags.length;e--;)t=this.frags[e],this.deleteCachedFrag(t),t.destroy()}},Fr={priority:Nr,bind:function(){var t=this.el;if(t.__vue__)this.invalid=!0;else{var e=t.nextElementSibling;e&&null!==M(e,"v-else")&&(I(e),this.elseFactory=new oe(e._context||this.vm,e)),this.anchor=it("v-if"),q(t,this.anchor),this.factory=new oe(this.vm,t)}},update:function(t){this.invalid||(t?this.frag||this.insert():this.remove())},insert:function(){this.elseFrag&&(this.elseFrag.remove(),this.elseFrag=null),this.frag=this.factory.create(this._host,this._scope,this._frag),this.frag.before(this.anchor)},remove:function(){this.frag&&(this.frag.remove(),this.frag=null),this.elseFactory&&!this.elseFrag&&(this.elseFrag=this.elseFactory.create(this._host,this._scope,this._frag),this.elseFrag.before(this.anchor))},unbind:function(){this.frag&&this.frag.destroy(),this.elseFrag&&this.elseFrag.destroy()}},Pr={bind:function(){var t=this.el.nextElementSibling;t&&null!==M(t,"v-else")&&(this.elseEl=t)},update:function(t){this.apply(this.el,t),this.elseEl&&this.apply(this.elseEl,!t)},apply:function(t,e){function i(){t.style.display=e?"":"none"}L(t)?R(t,e?1:-1,i,this.vm):i()}},Dr={bind:function(){var t=this,e=this.el,i="range"===e.type,n=this.params.lazy,r=this.params.number,s=this.params.debounce,a=!1;if(Fi||i||(this.on("compositionstart",function(){a=!0}),this.on("compositionend",function(){a=!1,n||t.listener()})),this.focused=!1,i||n||(this.on("focus",function(){t.focused=!0}),this.on("blur",function(){t.focused=!1})),this.listener=this.rawListener=function(){if(!a&&t._bound){var n=r||i?o(e.value):e.value;t.set(n),Wi(function(){t._bound&&!t.focused&&t.update(t._watcher.value)})}},s&&(this.listener=b(this.listener,s)),this.hasjQuery="function"==typeof jQuery,this.hasjQuery){var h=jQuery.fn.on?"on":"bind";jQuery(e)[h]("change",this.rawListener),n||jQuery(e)[h]("input",this.listener)}else this.on("change",this.rawListener),n||this.on("input",this.listener);!n&&Si&&(this.on("cut",function(){Wi(t.listener)}),this.on("keyup",function(e){46!==e.keyCode&&8!==e.keyCode||t.listener()})),(e.hasAttribute("value")||"TEXTAREA"===e.tagName&&e.value.trim())&&(this.afterBind=this.listener)},update:function(t){this.el.value=s(t)},unbind:function(){var t=this.el;if(this.hasjQuery){var e=jQuery.fn.off?"off":"unbind";jQuery(t)[e]("change",this.listener),jQuery(t)[e]("input",this.listener)}}},Rr={bind:function(){var t=this,e=this.el;this.getValue=function(){if(e.hasOwnProperty("_value"))return e._value;var i=e.value;return t.params.number&&(i=o(i)),i},this.listener=function(){t.set(t.getValue())},this.on("change",this.listener),e.hasAttribute("checked")&&(this.afterBind=this.listener)},update:function(t){this.el.checked=w(t,this.getValue())}},Hr={bind:function(){var t=this,e=this.el;this.forceUpdate=function(){t._watcher&&t.update(t._watcher.get())};var i=this.multiple=e.hasAttribute("multiple");this.listener=function(){var n=ce(e,i);n=t.params.number?Oi(n)?n.map(o):o(n):n,t.set(n)},this.on("change",this.listener);var n=ce(e,i,!0);(i&&n.length||!i&&null!==n)&&(this.afterBind=this.listener),this.vm.$on("hook:attached",this.forceUpdate)},update:function(t){var e=this.el;e.selectedIndex=-1;for(var i,n,r=this.multiple&&Oi(t),s=e.options,o=s.length;o--;)i=s[o],n=i.hasOwnProperty("_value")?i._value:i.value,i.selected=r?ue(t,n)>-1:w(t,n)},unbind:function(){this.vm.$off("hook:attached",this.forceUpdate)}},Lr={bind:function(){function t(){var t=i.checked;return t&&i.hasOwnProperty("_trueValue")?i._trueValue:!t&&i.hasOwnProperty("_falseValue")?i._falseValue:t}var e=this,i=this.el;this.getValue=function(){return i.hasOwnProperty("_value")?i._value:e.params.number?o(i.value):i.value},this.listener=function(){var n=e._watcher.value;if(Oi(n)){var r=e.getValue();i.checked?y(n,r)<0&&n.push(r):n.$remove(r)}else e.set(t())},this.on("change",this.listener),i.hasAttribute("checked")&&(this.afterBind=this.listener)},update:function(t){var e=this.el;Oi(t)?e.checked=y(t,this.getValue())>-1:e.hasOwnProperty("_trueValue")?e.checked=w(t,e._trueValue):e.checked=!!t}},Mr={text:Dr,radio:Rr,select:Hr,checkbox:Lr},Wr={priority:wr,twoWay:!0,handlers:Mr,params:["lazy","number","debounce"],bind:function(){this.checkFilters(),this.hasRead&&!this.hasWrite;var t,e=this.el,i=e.tagName;if("INPUT"===i)t=Mr[e.type]||Mr.text;else if("SELECT"===i)t=Mr.select;else{if("TEXTAREA"!==i)return;t=Mr.text}e.__v_model=this,t.bind.call(this),this.update=t.update,this._unbind=t.unbind},checkFilters:function(){var t=this.filters;if(t)for(var e=t.length;e--;){var i=bt(this.vm.$options,"filters",t[e].name);("function"==typeof i||i.read)&&(this.hasRead=!0),i.write&&(this.hasWrite=!0)}},unbind:function(){this.el.__v_model=null,this._unbind&&this._unbind()}},Br={esc:27,tab:9,enter:13,space:32,"delete":[8,46],up:38,left:37,right:39,down:40},Vr={priority:Cr,acceptStatement:!0,keyCodes:Br,bind:function(){if("IFRAME"===this.el.tagName&&"load"!==this.arg){var t=this;this.iframeBind=function(){J(t.el.contentWindow,t.arg,t.handler,t.modifiers.capture)},this.on("load",this.iframeBind)}},update:function(t){if(this.descriptor.raw||(t=function(){}),"function"==typeof t){this.modifiers.stop&&(t=pe(t)),this.modifiers.prevent&&(t=de(t)),this.modifiers.self&&(t=ve(t));var e=Object.keys(this.modifiers).filter(function(t){return"stop"!==t&&"prevent"!==t});e.length&&(t=fe(t,e)),this.reset(),this.handler=t,this.iframeBind?this.iframeBind():J(this.el,this.arg,this.handler,this.modifiers.capture)}},reset:function(){var t=this.iframeBind?this.el.contentWindow:this.el;this.handler&&Q(t,this.arg,this.handler)},unbind:function(){this.reset()}},zr=["-webkit-","-moz-","-ms-"],Ir=["Webkit","Moz","ms"],Ur=/!important;?$/,qr=Object.create(null),Jr=null,Qr={deep:!0,update:function(t){"string"==typeof t?this.el.style.cssText=t:Oi(t)?this.handleObject(t.reduce(v,{})):this.handleObject(t||{})},handleObject:function(t){var e,i,n=this.cache||(this.cache={});for(e in n)e in t||(this.handleSingle(e,null),delete n[e]);for(e in t)i=t[e],i!==n[e]&&(n[e]=i,this.handleSingle(e,i))},handleSingle:function(t,e){if(t=me(t))if(null!=e&&(e+=""),e){var i=Ur.test(e)?"important":"";i&&(e=e.replace(Ur,"").trim()),this.el.style.setProperty(t,e,i)}else this.el.style.removeProperty(t)}},Gr="http://www.w3.org/1999/xlink",Kr=/^xlink:/,Zr=/^v-|^:|^@|^(?:is|transition|transition-mode|debounce|track-by|stagger|enter-stagger|leave-stagger)$/,Xr=/^(?:value|checked|selected|muted)$/,Yr=/^(?:draggable|contenteditable|spellcheck)$/,ts={value:"_value","true-value":"_trueValue","false-value":"_falseValue"},es={priority:$r,bind:function(){var t=this.arg,e=this.el.tagName;t||(this.deep=!0);var i=this.descriptor,n=i.interp;n&&(i.hasOneTime&&(this.expression=j(n,this._scope||this.vm)),(Zr.test(t)||"name"===t&&("PARTIAL"===e||"SLOT"===e))&&(this.el.removeAttribute(t),this.invalid=!0))},update:function(t){if(!this.invalid){var e=this.arg;this.arg?this.handleSingle(e,t):this.handleObject(t||{})}},handleObject:Qr.handleObject,handleSingle:function(t,e){var i=this.el,n=this.descriptor.interp;this.modifiers.camel&&(t=l(t)),!n&&Xr.test(t)&&t in i&&(i[t]="value"===t&&null==e?"":e);var r=ts[t];if(!n&&r){i[r]=e;var s=i.__v_model;s&&s.listener()}return"value"===t&&"TEXTAREA"===i.tagName?void i.removeAttribute(t):void(Yr.test(t)?i.setAttribute(t,e?"true":"false"):null!=e&&e!==!1?"class"===t?(i.__v_trans&&(e+=" "+i.__v_trans.id+"-transition"),G(i,e)):Kr.test(t)?i.setAttributeNS(Gr,t,e===!0?"":e):i.setAttribute(t,e===!0?"":e):i.removeAttribute(t))}},is={priority:xr,bind:function(){if(this.arg){var t=this.id=l(this.arg),e=(this._scope||this.vm).$els;i(e,t)?e[t]=this.el:At(e,t,this.el)}},unbind:function(){var t=(this._scope||this.vm).$els;t[this.id]===this.el&&(t[this.id]=null)}},ns={bind:function(){}},rs={bind:function(){var t=this.el;this.vm.$once("pre-hook:compiled",function(){t.removeAttribute("v-cloak")})}},ss={text:cr,html:br,"for":Sr,"if":Fr,show:Pr,model:Wr,on:Vr,bind:es,el:is,ref:ns,cloak:rs},os={deep:!0,update:function(t){t&&"string"==typeof t?this.handleObject(_e(t)):g(t)?this.handleObject(t):Oi(t)?this.handleArray(t):this.cleanup()},handleObject:function(t){this.cleanup(t);for(var e=this.prevKeys=Object.keys(t),i=0,n=e.length;n>i;i++){var r=e[i];t[r]?K(this.el,r):Z(this.el,r)}},handleArray:function(t){this.cleanup(t);for(var e=0,i=t.length;i>e;e++)t[e]&&K(this.el,t[e]);this.prevKeys=t.slice()},cleanup:function(t){if(this.prevKeys)for(var e=this.prevKeys.length;e--;){var i=this.prevKeys[e];!i||t&&be(t,i)||Z(this.el,i)}}},as={priority:Ar,params:["keep-alive","transition-mode","inline-template"],bind:function(){this.el.__vue__||(this.keepAlive=this.params.keepAlive,this.keepAlive&&(this.cache={}),this.params.inlineTemplate&&(this.inlineTemplate=X(this.el,!0)),this.pendingComponentCb=this.Component=null,this.pendingRemovals=0,this.pendingRemovalCb=null,this.anchor=it("v-component"),q(this.el,this.anchor),this.el.removeAttribute("is"),this.descriptor.ref&&this.el.removeAttribute("v-ref:"+u(this.descriptor.ref)),this.literal&&this.setComponent(this.expression))},update:function(t){this.literal||this.setComponent(t)},setComponent:function(t,e){if(this.invalidatePending(),t){var i=this;this.resolveComponent(t,function(){i.mountComponent(e)})}else this.unbuild(!0),this.remove(this.childVM,e),this.childVM=null},resolveComponent:function(t,e){var i=this;this.pendingComponentCb=C(function(n){i.ComponentName=n.options.name||t,i.Component=n,e()}),this.vm._resolveComponent(t,this.pendingComponentCb)},mountComponent:function(t){this.unbuild(!0);var e=this,i=this.Component.options.activate,n=this.getCached(),r=this.build();i&&!n?(this.waitingFor=r,ye(i,r,function(){e.waitingFor===r&&(e.waitingFor=null,e.transition(r,t))})):(n&&r._updateRef(),this.transition(r,t))},invalidatePending:function(){this.pendingComponentCb&&(this.pendingComponentCb.cancel(),
8this.pendingComponentCb=null)},build:function(t){var e=this.getCached();if(e)return e;if(this.Component){var i={name:this.ComponentName,el:Zt(this.el),template:this.inlineTemplate,parent:this._host||this.vm,_linkerCachable:!this.inlineTemplate,_ref:this.descriptor.ref,_asComponent:!0,_isRouterView:this._isRouterView,_context:this.vm,_scope:this._scope,_frag:this._frag};t&&v(i,t);var n=new this.Component(i);return this.keepAlive&&(this.cache[this.Component.cid]=n),n}},getCached:function(){return this.keepAlive&&this.cache[this.Component.cid]},unbuild:function(t){this.waitingFor&&(this.waitingFor.$destroy(),this.waitingFor=null);var e=this.childVM;return!e||this.keepAlive?void(e&&e._updateRef(!0)):void e.$destroy(!1,t)},remove:function(t,e){var i=this.keepAlive;if(t){this.pendingRemovals++,this.pendingRemovalCb=e;var n=this;t.$remove(function(){n.pendingRemovals--,i||t._cleanup(),!n.pendingRemovals&&n.pendingRemovalCb&&(n.pendingRemovalCb(),n.pendingRemovalCb=null)})}else e&&e()},transition:function(t,e){var i=this,n=this.childVM;switch(this.childVM=t,i.params.transitionMode){case"in-out":t.$before(i.anchor,function(){i.remove(n,e)});break;case"out-in":i.remove(n,function(){t.$before(i.anchor,e)});break;default:i.remove(n),t.$before(i.anchor,e)}},unbind:function(){if(this.invalidatePending(),this.unbuild(),this.cache){for(var t in this.cache)this.cache[t].$destroy();this.cache=null}}},hs=pn._propBindingModes,ls={bind:function(){var t=this.vm,e=t._context,i=this.descriptor.prop,n=i.path,r=i.parentPath,s=i.mode===hs.TWO_WAY,o=this.parentWatcher=new qt(e,r,function(e){e=ft(i,e),ut(i,e)&&(t[n]=e)},{twoWay:s,filters:i.filters,scope:this._scope});if(ct(t,i,o.value),s){var a=this;t.$once("pre-hook:created",function(){a.childWatcher=new qt(t,n,function(t){o.set(t)},{sync:!0})})}},unbind:function(){this.parentWatcher.teardown(),this.childWatcher&&this.childWatcher.teardown()}},cs=[],us=!1,fs="transition",ps="animation",ds=Pi+"Duration",vs=Ri+"Duration",ms=$e.prototype;ms.enter=function(t,e){this.cancelPending(),this.callHook("beforeEnter"),this.cb=e,K(this.el,this.enterClass),t(),this.entered=!1,this.callHookWithCb("enter"),this.entered||(this.cancel=this.hooks&&this.hooks.enterCancelled,Ce(this.enterNextTick))},ms.enterNextTick=function(){this.justEntered=!0;var t=this;setTimeout(function(){t.justEntered=!1},17);var e=this.enterDone,i=this.getCssTransitionType(this.enterClass);this.pendingJsCb?i===fs&&Z(this.el,this.enterClass):i===fs?(Z(this.el,this.enterClass),this.setupCssCb(Di,e)):i===ps?this.setupCssCb(Hi,e):e()},ms.enterDone=function(){this.entered=!0,this.cancel=this.pendingJsCb=null,Z(this.el,this.enterClass),this.callHook("afterEnter"),this.cb&&this.cb()},ms.leave=function(t,e){this.cancelPending(),this.callHook("beforeLeave"),this.op=t,this.cb=e,K(this.el,this.leaveClass),this.left=!1,this.callHookWithCb("leave"),this.left||(this.cancel=this.hooks&&this.hooks.leaveCancelled,this.op&&!this.pendingJsCb&&(this.justEntered?this.leaveDone():Ce(this.leaveNextTick)))},ms.leaveNextTick=function(){var t=this.getCssTransitionType(this.leaveClass);if(t){var e=t===fs?Di:Hi;this.setupCssCb(e,this.leaveDone)}else this.leaveDone()},ms.leaveDone=function(){this.left=!0,this.cancel=this.pendingJsCb=null,this.op(),Z(this.el,this.leaveClass),this.callHook("afterLeave"),this.cb&&this.cb(),this.op=null},ms.cancelPending=function(){this.op=this.cb=null;var t=!1;this.pendingCssCb&&(t=!0,Q(this.el,this.pendingCssEvent,this.pendingCssCb),this.pendingCssEvent=this.pendingCssCb=null),this.pendingJsCb&&(t=!0,this.pendingJsCb.cancel(),this.pendingJsCb=null),t&&(Z(this.el,this.enterClass),Z(this.el,this.leaveClass)),this.cancel&&(this.cancel.call(this.vm,this.el),this.cancel=null)},ms.callHook=function(t){this.hooks&&this.hooks[t]&&this.hooks[t].call(this.vm,this.el)},ms.callHookWithCb=function(t){var e=this.hooks&&this.hooks[t];e&&(e.length>1&&(this.pendingJsCb=C(this[t+"Done"])),e.call(this.vm,this.el,this.pendingJsCb))},ms.getCssTransitionType=function(t){if(!(!Di||document.hidden||this.hooks&&this.hooks.css===!1||ke(this.el))){var e=this.type||this.typeCache[t];if(e)return e;var i=this.el.style,n=window.getComputedStyle(this.el),r=i[ds]||n[ds];if(r&&"0s"!==r)e=fs;else{var s=i[vs]||n[vs];s&&"0s"!==s&&(e=ps)}return e&&(this.typeCache[t]=e),e}},ms.setupCssCb=function(t,e){this.pendingCssEvent=t;var i=this,n=this.el,r=this.pendingCssCb=function(s){s.target===n&&(Q(n,t,r),i.pendingCssEvent=i.pendingCssCb=null,!i.pendingJsCb&&e&&e())};J(n,t,r)};var gs={priority:kr,update:function(t,e){var i=this.el,n=bt(this.vm.$options,"transitions",t);t=t||"v",i.__v_trans=new $e(i,t,n,this.vm),e&&Z(i,e+"-transition"),K(i,t+"-transition")}},_s={style:Qr,"class":os,component:as,prop:ls,transition:gs},bs=pn._propBindingModes,ys={},Cs=/^[$_a-zA-Z]+[\w$]*$/,ws=/^v-bind:|^:/,$s=/^v-on:|^@/,ks=/^v-([^:]+)(?:$|:(.*)$)/,xs=/\.[^\.]+/g,As=/^(v-bind:|:)?transition$/,Os=["for","if"],Ts=1e3;qe.terminal=!0;var Ns=/[^\w\-:\.]/,js=Object.freeze({compile:Te,compileAndLinkProps:Fe,compileRoot:Pe,terminalDirectives:Os,transclude:Xe,scanSlots:ii}),Es=/^v-on:|^@/;ai.prototype._bind=function(){var t=this.name,e=this.descriptor;if(("cloak"!==t||this.vm._isCompiled)&&this.el&&this.el.removeAttribute){var i=e.attr||"v-"+t;this.el.removeAttribute(i)}var n=e.def;if("function"==typeof n?this.update=n:v(this,n),this._setupParams(),this.bind&&this.bind(),this._bound=!0,this.literal)this.update&&this.update(e.raw);else if((this.expression||this.modifiers)&&(this.update||this.twoWay)&&!this._checkStatement()){var r=this;this.update?this._update=function(t,e){r._locked||r.update(t,e)}:this._update=oi;var s=this._preProcess?p(this._preProcess,this):null,o=this._postProcess?p(this._postProcess,this):null,a=this._watcher=new qt(this.vm,this.expression,this._update,{filters:this.filters,twoWay:this.twoWay,deep:this.deep,preProcess:s,postProcess:o,scope:this._scope});this.afterBind?this.afterBind():this.update&&this.update(a.value)}},ai.prototype._setupParams=function(){if(this.params){var t=this.params;this.params=Object.create(null);for(var e,i,n,r=t.length;r--;)e=t[r],n=l(e),i=W(this.el,e),null!=i?this._setupParamWatcher(n,i):(i=M(this.el,e),null!=i&&(this.params[n]=""===i?!0:i))}},ai.prototype._setupParamWatcher=function(t,e){var i=this,n=!1,r=(this._scope||this.vm).$watch(e,function(e,r){if(i.params[t]=e,n){var s=i.paramWatchers&&i.paramWatchers[t];s&&s.call(i,e,r)}else n=!0},{immediate:!0,user:!1});(this._paramUnwatchFns||(this._paramUnwatchFns=[])).push(r)},ai.prototype._checkStatement=function(){var t=this.expression;if(t&&this.acceptStatement&&!Bt(t)){var e=Wt(t).get,i=this._scope||this.vm,n=function(t){i.$event=t,e.call(i,i),i.$event=null};return this.filters&&(n=i._applyFilters(n,null,this.filters)),this.update(n),!0}},ai.prototype.set=function(t){this.twoWay&&this._withLock(function(){this._watcher.set(t)})},ai.prototype._withLock=function(t){var e=this;e._locked=!0,t.call(e),Wi(function(){e._locked=!1})},ai.prototype.on=function(t,e,i){J(this.el,t,e,i),(this._listeners||(this._listeners=[])).push([t,e])},ai.prototype._teardown=function(){if(this._bound){this._bound=!1,this.unbind&&this.unbind(),this._watcher&&this._watcher.teardown();var t,e=this._listeners;if(e)for(t=e.length;t--;)Q(this.el,e[t][0],e[t][1]);var i=this._paramUnwatchFns;if(i)for(t=i.length;t--;)i[t]();this.vm=this.el=this._watcher=this._listeners=null}};var Ss=/[^|]\|[^|]/;Ot(di),ri(di),si(di),hi(di),li(di),ci(di),ui(di),fi(di),pi(di);var Fs={priority:jr,params:["name"],bind:function(){var t=this.params.name||"default",e=this.vm._slotContents&&this.vm._slotContents[t];e&&e.hasChildNodes()?this.compile(e.cloneNode(!0),this.vm._context,this.vm):this.fallback()},compile:function(t,e,i){if(t&&e){if(this.el.hasChildNodes()&&1===t.childNodes.length&&1===t.childNodes[0].nodeType&&t.childNodes[0].hasAttribute("v-if")){var n=document.createElement("template");n.setAttribute("v-else",""),n.innerHTML=this.el.innerHTML,n._context=this.vm,t.appendChild(n)}var r=i?i._scope:this._scope;this.unlink=e.$compile(t,i,r,this._frag)}t?q(this.el,t):I(this.el)},fallback:function(){this.compile(X(this.el,!0),this.vm)},unbind:function(){this.unlink&&this.unlink()}},Ps={priority:Or,params:["name"],paramWatchers:{name:function(t){Fr.remove.call(this),t&&this.insert(t)}},bind:function(){this.anchor=it("v-partial"),q(this.el,this.anchor),this.insert(this.params.name)},insert:function(t){var e=bt(this.vm.$options,"partials",t);e&&(this.factory=new oe(this.vm,e),Fr.insert.call(this))},unbind:function(){this.frag&&this.frag.destroy()}},Ds={slot:Fs,partial:Ps},Rs=Sr._postProcess,Hs=/(\d{3})(?=\d)/g,Ls={orderBy:gi,filterBy:mi,limitBy:vi,json:{read:function(t,e){return"string"==typeof t?t:JSON.stringify(t,null,Number(e)||2)},write:function(t){try{return JSON.parse(t)}catch(e){return t}}},capitalize:function(t){return t||0===t?(t=t.toString(),t.charAt(0).toUpperCase()+t.slice(1)):""},uppercase:function(t){return t||0===t?t.toString().toUpperCase():""},lowercase:function(t){return t||0===t?t.toString().toLowerCase():""},currency:function(t,e){if(t=parseFloat(t),!isFinite(t)||!t&&0!==t)return"";e=null!=e?e:"$";var i=Math.abs(t).toFixed(2),n=i.slice(0,-3),r=n.length%3,s=r>0?n.slice(0,r)+(n.length>3?",":""):"",o=i.slice(-3),a=0>t?"-":"";return a+e+s+n.slice(r).replace(Hs,"$1,")+o},pluralize:function(t){var e=d(arguments,1);return e.length>1?e[t%10-1]||e[e.length-1]:e[0]+(1===t?"":"s")},debounce:function(t,e){return t?(e||(e=300),b(t,e)):void 0}};return bi(di),di.version="1.0.17",ji&&ji.emit("init",di),di}); \ No newline at end of file